/* =========================================================
   NAUE 2030 — layout.css
   Header, navegação (desktop + mobile) e footer
   ========================================================= */

/* ===== HEADER ===== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: var(--header-h);
    background: rgba(244, 247, 245, 0.82);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.site-header.scrolled {
    border-bottom-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
}

.brand {
    display: inline-flex;
    align-items: center;
    z-index: 1002;
}

.brand img {
    height: 46px;
    width: auto;
}

/* ===== NAV DESKTOP ===== */
.nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link {
    font-family: var(--font-display);
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--ink);
    padding: 10px 14px;
    border-radius: 999px;
    transition: background 0.2s ease, color 0.2s ease;
}

.nav-link:hover {
    background: var(--green-soft);
    color: var(--green);
}

.nav-link[aria-current="page"] {
    color: var(--green);
    font-weight: 600;
}

.nav-cta {
    background: var(--green);
    color: #fff !important;
    font-weight: 600;
    margin-left: 8px;
    padding: 11px 22px;
    box-shadow: 0 8px 20px rgba(31, 107, 70, 0.25);
}

.nav-cta:hover {
    background: var(--green-deep);
}

/* ===== TOGGLE MOBILE ===== */
.nav-toggle {
    display: none;
    width: 46px;
    height: 46px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--paper-2);
    cursor: pointer;
    z-index: 1002;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: var(--ink);
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.site-header.nav-open .nav-toggle span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.site-header.nav-open .nav-toggle span:nth-child(2) {
    opacity: 0;
}

.site-header.nav-open .nav-toggle span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== BACKDROP MOBILE ===== */
.nav-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(13, 20, 16, 0.55);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.site-header.nav-open .nav-backdrop {
    opacity: 1;
    pointer-events: auto;
}

/* ===== NAV MOBILE ===== */
@media (max-width: 920px) {
    .nav-toggle { display: flex; }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: min(320px, 86vw);
        height: 100dvh;
        background: var(--paper-2);
        box-shadow: -12px 0 40px rgba(13, 20, 16, 0.2);
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: calc(var(--header-h) + 16px) 20px 24px;
        transition: right 0.38s cubic-bezier(0.22, 1, 0.36, 1);
        overflow-y: auto;
        z-index: 1001;
    }

    .site-header.nav-open .nav { right: 0; }

    .nav-link {
        padding: 15px 18px;
        border-radius: var(--radius-sm);
        border: 1px solid var(--border);
        background: var(--paper);
        font-size: 1rem;
    }

    .nav-cta {
        margin-left: 0;
        margin-top: var(--sp-2);
        justify-content: center;
        text-align: center;
        display: flex;
    }
}

/* ===== FOOTER ===== */
.site-footer {
    background: var(--ink);
    color: var(--text-on-dark-muted);
    padding: var(--sp-12) 0 var(--sp-4);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: var(--sp-8);
    padding-bottom: var(--sp-8);
    border-bottom: 1px solid var(--border-on-dark);
}

.footer-brand img {
    height: 56px;
    width: auto;
    margin-bottom: var(--sp-2);
}

.footer-tagline {
    max-width: 340px;
    line-height: 1.7;
}

.footer-col h4 {
    color: var(--text-on-dark);
    font-size: 0.85rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: var(--sp-3);
}

.footer-col ul li { margin-bottom: 10px; }

.footer-col a {
    color: var(--text-on-dark-muted);
    transition: color 0.2s ease;
}

.footer-col a:hover { color: var(--green-bright); }

.footer-col address {
    font-style: normal;
    line-height: 1.8;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--sp-2);
    padding-top: var(--sp-4);
    font-size: var(--fs-small);
}

@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--sp-6);
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}
