/* Footer reference layout: navy background, four-column editorial structure. */

.footer-reference {
    position: relative;
    overflow: hidden;
    padding: 76px 0 24px;
    color: rgba(255, 255, 255, 0.82);
    background: #062f63 !important;
}

.footer-reference::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.25;
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 44px 44px;
}

.footer-reference-container {
    position: relative;
    z-index: 1;
    max-width: 1130px;
}

.footer-reference-grid {
    display: grid;
    grid-template-columns: minmax(255px, 1.3fr) minmax(145px, 0.7fr) minmax(155px, 0.8fr) minmax(230px, 1fr);
    gap: 58px;
    align-items: start;
}

.footer-reference-brand,
.footer-reference-links,
.footer-reference-qr {
    min-width: 0;
}

.footer-reference-logo {
    display: inline-flex;
    align-items: center;
    min-height: 58px;
    color: #fff !important;
    text-decoration: none;
}

.footer-reference-logo img {
    width: auto;
    max-width: 260px;
    height: 58px;
    object-fit: contain;
    object-position: left center;
}

.footer-reference-logo > .iconify {
    margin-right: 10px;
    color: var(--brand-yellow);
}

.footer-reference-logo > span:last-child {
    color: #fff;
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
}

.footer-reference-description {
    max-width: 300px;
    margin: 20px 0 22px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 13px;
    line-height: 1.8;
}

.footer-reference-contact-list {
    display: grid;
    gap: 11px;
}

.footer-reference-contact-list > a,
.footer-reference-contact-list > span {
    display: flex;
    align-items: center;
    gap: 11px;
    color: rgba(255, 255, 255, 0.84);
    font-size: 12px;
    line-height: 1.4;
    text-decoration: none;
}

.footer-reference-contact-list > a:hover {
    color: var(--brand-yellow);
}

.footer-contact-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 25px;
    height: 25px;
    flex: 0 0 25px;
    color: #fff;
    background: var(--brand-yellow);
    border-radius: 5px;
}

.footer-reference-links h3,
.footer-reference-qr h3 {
    position: relative;
    display: inline-block;
    margin: 7px 0 24px;
    padding-bottom: 13px;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.footer-reference-links h3::before,
.footer-reference-qr h3::before {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
}

.footer-reference-links h3::after,
.footer-reference-qr h3::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 28px;
    height: 2px;
    background: var(--brand-yellow);
}

.footer-reference-links ul {
    display: grid;
    gap: 13px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-reference-links li {
    position: relative;
    padding-left: 15px;
}

.footer-reference-links li::before {
    content: "";
    position: absolute;
    top: 0.58em;
    left: 0;
    width: 0;
    height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 5px solid var(--brand-yellow);
}

.footer-reference-links a {
    color: rgba(255, 255, 255, 0.82);
    font-size: 12px;
    text-decoration: none;
    transition: color 0.2s ease, transform 0.2s ease;
}

.footer-reference-links a:hover {
    color: var(--brand-yellow);
    transform: translateX(3px);
}

.footer-qr-pair {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding-top: 2px;
}

.footer-qr-pair figure {
    width: 106px;
    margin: 0;
    padding: 5px 5px 4px;
    color: #29313d;
    background: #fff;
    text-align: center;
}

.footer-qr-pair img {
    display: block;
    width: 96px;
    height: 96px;
    object-fit: cover;
}

.footer-qr-pair figcaption {
    padding-top: 4px;
    color: #29313d;
    font-size: 10px;
    line-height: 1.2;
}

.footer-reference-qr-empty {
    max-width: 220px;
    padding: 16px;
    color: rgba(255, 255, 255, 0.58);
    border: 1px dashed rgba(255, 255, 255, 0.25);
    font-size: 12px;
}

.footer-reference-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 38px;
    padding-top: 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-reference-bottom p,
.footer-reference-bottom span {
    margin: 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 11px;
}

.footer-reference-bottom span {
    color: var(--brand-yellow);
    font-weight: 800;
    letter-spacing: 0.08em;
}

[data-theme="dark"] .footer-reference {
    background: #041f43 !important;
}

@media (max-width: 991.98px) {
    .footer-reference {
        padding-top: 58px;
    }

    .footer-reference-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 38px 30px;
    }

    .footer-reference-brand {
        grid-column: 1 / -1;
    }

    .footer-reference-qr {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575.98px) {
    .footer-reference {
        padding-top: 48px;
    }

    .footer-reference-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .footer-reference-brand,
    .footer-reference-qr {
        grid-column: auto;
    }

    .footer-reference-logo img {
        max-width: 220px;
        height: 50px;
    }

    .footer-reference-bottom {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }
}
