/* ==================================================================
   roadmap.css — Roadmap de Evolução KMIZA27
   Página autônoma inspirada na prancheta tática do pitch.
   ================================================================== */

:root {
    --pitch-950: #041a15;
    --pitch-900: #06231c;
    --pitch-850: #082b22;
    --pitch-800: #0b352a;
    --chalk: #eef7ee;
    --chalk-dim: #b9d6c2;
    --chalk-faint: #86ab93;
    --line: rgba(222, 245, 228, 0.14);
    --line-strong: rgba(222, 245, 228, 0.28);
    --lime: #c5ef4b;
    --lime-ink: #131f04;
    --font-display: 'Chakra Petch', sans-serif;
    --font-body: 'Archivo', sans-serif;
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --wrap: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
}

body {
    overflow-x: hidden;
    background: var(--pitch-900);
    color: var(--chalk);
    font-family: var(--font-body);
    line-height: 1.6;
}

::selection { background: var(--lime); color: var(--lime-ink); }

.wrap,
.topbar-inner {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 clamp(20px, 4vw, 48px);
}

/* ---------------- Barra superior ---------------- */
.topbar {
    position: fixed;
    inset: 0 0 auto;
    z-index: 100;
    border-bottom: 1px solid transparent;
    transition: background 0.35s var(--ease-out), border-color 0.35s var(--ease-out);
}

.topbar.is-scrolled {
    border-bottom-color: var(--line);
    background: rgba(4, 26, 21, 0.9);
    backdrop-filter: blur(12px);
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    height: 68px;
}

.topbar-logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--chalk);
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-decoration: none;
}

.topbar-logo img { width: auto; height: 34px; }

.topbar-nav {
    display: flex;
    align-items: center;
    gap: clamp(0.9rem, 1.7vw, 1.5rem);
}

.topbar-nav a {
    color: var(--chalk-dim);
    font-size: 0.82rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.topbar-nav a:hover,
.topbar-nav a.is-active { color: var(--lime); }

.topbar-nav b {
    margin-right: 0.25rem;
    color: var(--lime);
    font-family: var(--font-display);
}

.topbar-pitch {
    padding: 0.42rem 0.9rem;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    color: var(--chalk) !important;
}

.topbar-pitch:hover { border-color: var(--lime); }

.topbar-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    border: 0;
    background: transparent;
    cursor: pointer;
    padding: 8px;
}

.topbar-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--chalk);
    transition: transform 0.3s var(--ease-out);
}

/* ---------------- Hero ---------------- */
.hero {
    position: relative;
    display: flex;
    align-items: end;
    min-height: min(78svh, 760px);
    padding: 140px 0 80px;
    overflow: hidden;
    background:
        radial-gradient(90% 115% at 88% -12%, #116046 0%, transparent 58%),
        linear-gradient(115deg, rgba(197, 239, 75, 0.025), transparent 45%),
        var(--pitch-950);
}

.hero-pitch {
    position: absolute;
    top: 50%;
    right: -110px;
    width: min(62vw, 720px);
    height: 135%;
    color: var(--chalk);
    opacity: 0.11;
    pointer-events: none;
    transform: translateY(-50%) rotate(8deg);
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(290px, 5fr);
    gap: clamp(2.5rem, 6vw, 5rem);
    align-items: end;
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
    color: var(--chalk-dim);
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0.04em;
}

.live-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--lime);
    box-shadow: 0 0 0 0 rgba(197, 239, 75, 0.55);
    animation: pulse 2.2s infinite;
}

@keyframes pulse {
    70% { box-shadow: 0 0 0 12px rgba(197, 239, 75, 0); }
    100% { box-shadow: 0 0 0 0 rgba(197, 239, 75, 0); }
}

.hero h1 {
    max-width: 10ch;
    margin-bottom: 1.5rem;
    font-family: var(--font-display);
    font-size: clamp(3.1rem, 7vw, 6.1rem);
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 0.92;
    text-transform: uppercase;
}

.hero h1 em {
    color: var(--lime);
    font-style: normal;
}

.hero-summary {
    max-width: 48ch;
    color: var(--chalk-dim);
    font-size: 1rem;
}

.hero-phases {
    list-style: none;
    padding: 0.4rem 1.35rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(238, 247, 238, 0.025);
    backdrop-filter: blur(8px);
}

.hero-phases li {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.95rem 0;
    border-top: 1px solid var(--line);
}

.hero-phases li:first-child { border-top: 0; }

.hero-phases strong {
    min-width: 1.3ch;
    color: var(--lime);
    font-family: var(--font-display);
    font-size: 1.45rem;
}

.hero-phases div { min-width: 0; }

.hero-phases span {
    display: block;
    color: var(--chalk);
    font-size: 0.94rem;
    font-weight: 600;
    line-height: 1.2;
}

.hero-phases small {
    display: block;
    margin-top: 0.16rem;
    color: var(--chalk-faint);
    font-size: 0.76rem;
}

/* ---------------- Conteúdo compartilhado ---------------- */
.sec { padding: clamp(80px, 9vw, 118px) 0; }

.sec-dark {
    background:
        linear-gradient(180deg, rgba(197, 239, 75, 0.018), transparent 22%),
        var(--pitch-950);
}

.sec-head {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: clamp(1.2rem, 3vw, 2.4rem);
    max-width: 920px;
    margin-bottom: clamp(3.2rem, 5.5vw, 4.6rem);
}

.sec-num {
    color: transparent;
    font-family: var(--font-display);
    font-size: clamp(3.6rem, 7vw, 5.6rem);
    font-weight: 700;
    line-height: 0.85;
    -webkit-text-stroke: 1.5px var(--lime);
}

.sec-head h2,
.phase-detail h2,
.vision-copy h2 {
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 3.6vw, 2.8rem);
    font-weight: 700;
    letter-spacing: 0.01em;
    line-height: 1.05;
    text-transform: uppercase;
}

.sec-head p {
    max-width: 62ch;
    margin-top: 0.8rem;
    color: var(--chalk-dim);
}

/* ---------------- Linha do tempo ---------------- */
.phase-timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    list-style: none;
}

.phase-timeline li {
    position: relative;
    min-height: 214px;
    padding: 1.9rem 1.4rem 1.2rem;
    border-top: 2px solid var(--line-strong);
    border-right: 1px solid var(--line);
}

.phase-timeline li:first-child { padding-left: 0; }
.phase-timeline li:last-child { border-right: 0; }

.phase-timeline li::before {
    position: absolute;
    top: -7px;
    left: 0;
    width: 11px;
    height: 11px;
    border: 2px solid var(--chalk-faint);
    border-radius: 50%;
    background: var(--pitch-900);
    content: "";
}

.phase-timeline li.is-complete { border-top-color: var(--lime); }
.phase-timeline li.is-focus { border-top-color: rgba(197, 239, 75, 0.6); }
.phase-timeline li.is-future { border-top-style: dashed; }

.phase-timeline li.is-complete::before {
    border-color: var(--lime);
    background: var(--lime);
    box-shadow: 0 0 14px rgba(197, 239, 75, 0.55);
}

.phase-timeline li.is-focus::before { border-color: var(--lime); }

.phase-period {
    display: block;
    margin-bottom: 0.45rem;
    color: var(--chalk-faint);
    font-family: var(--font-display);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.phase-timeline h3 {
    margin-bottom: 0.55rem;
    font-family: var(--font-display);
    font-size: 1.35rem;
    line-height: 1.1;
    text-transform: uppercase;
}

.phase-timeline p {
    color: var(--chalk-dim);
    font-size: 0.88rem;
}

.status {
    display: inline-block;
    margin-top: 0.9rem;
    padding: 0.25rem 0.7rem;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    color: var(--chalk-dim);
    font-family: var(--font-display);
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.is-complete .status {
    border-color: transparent;
    background: var(--lime);
    color: var(--lime-ink);
}

.is-focus .status {
    border-color: rgba(197, 239, 75, 0.45);
    color: var(--lime);
}

/* ---------------- Fase detalhada ---------------- */
.phase-detail {
    padding-bottom: clamp(56px, 7vw, 88px);
    border-bottom: 1px solid var(--line);
}

.phase-detail + .phase-detail { padding-top: clamp(56px, 7vw, 88px); }

.phase-detail-head {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: clamp(1.2rem, 3vw, 2.4rem);
    max-width: 820px;
    margin-bottom: 2.8rem;
}

.phase-label {
    color: var(--lime);
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}

.phase-detail h2 { margin-bottom: 0.7rem; }

.phase-detail-lead {
    max-width: 63ch;
    color: var(--chalk-dim);
    font-size: 1rem;
}

.initiative-grid,
.pillar-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    overflow: hidden;
    background: var(--line-strong);
}

.initiative {
    padding: clamp(1.5rem, 3.4vw, 2.4rem);
    background: var(--pitch-900);
}

.initiative--wide { grid-column: span 2; }

.initiative-number {
    display: block;
    margin-bottom: 1rem;
    color: var(--lime);
    font-family: var(--font-display);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.1em;
}

.initiative h3 {
    margin-bottom: 0.75rem;
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    line-height: 1.14;
}

.initiative p {
    margin-bottom: 1rem;
    color: var(--chalk-dim);
    font-size: 0.92rem;
}

.initiative p:last-child { margin-bottom: 0; }

.initiative h4 {
    margin: 1.15rem 0 0.55rem;
    color: var(--chalk);
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.initiative ul,
.pillar ul,
.vision-list {
    list-style: none;
}

.initiative li,
.pillar li,
.vision-list li {
    position: relative;
    padding-left: 1rem;
    color: var(--chalk-dim);
    font-size: 0.9rem;
}

.initiative li + li,
.pillar li + li,
.vision-list li + li { margin-top: 0.35rem; }

.initiative li::before,
.pillar li::before,
.vision-list li::before {
    position: absolute;
    top: 0.72em;
    left: 0;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--lime);
    content: "";
}

/* ---------------- Pilares ---------------- */
.pillar {
    padding: clamp(1.5rem, 3.4vw, 2.5rem);
    background: var(--pitch-950);
}

.pillar h3 {
    margin-bottom: 0.7rem;
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 2vw, 1.65rem);
    line-height: 1.12;
}

.pillar p {
    margin-bottom: 1rem;
    color: var(--chalk-dim);
    font-size: 0.92rem;
}

.pillar--accent {
    background: var(--lime);
    color: var(--lime-ink);
}

.pillar--accent p,
.pillar--accent li { color: rgba(19, 31, 4, 0.82); }
.pillar--accent li::before { background: var(--lime-ink); }

/* ---------------- Visão ---------------- */
.vision {
    background: var(--lime);
    color: var(--lime-ink);
}

.vision-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
    gap: clamp(2.5rem, 7vw, 7rem);
    align-items: start;
}

.vision-copy h2 {
    max-width: 10ch;
    margin-bottom: 1.25rem;
    font-size: clamp(2.9rem, 7vw, 5.7rem);
    line-height: 0.92;
}

.vision-copy p {
    max-width: 48ch;
    font-size: 1rem;
}

.vision-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem 1rem;
    padding-top: 0.5rem;
}

.vision-list li {
    color: var(--lime-ink);
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 600;
}

.vision-list li::before { background: var(--lime-ink); }

.foot {
    padding: 1.8rem 0;
    background: var(--pitch-950);
}

.foot p {
    color: var(--chalk-faint);
    font-size: 0.82rem;
}

/* ---------------- Animações ---------------- */
.reveal-1,
.reveal-2,
.reveal-3 {
    opacity: 0;
    transform: translateY(24px);
    animation: rise 0.8s var(--ease-out) forwards;
}

.reveal-2 { animation-delay: 0.12s; }
.reveal-3 { animation-delay: 0.24s; }

@keyframes rise {
    to { opacity: 1; transform: translateY(0); }
}

.js .observe {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.js .observe.in-view {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal-1, .reveal-2, .reveal-3, .observe, .js .observe {
        opacity: 1;
        transform: none;
        transition: none;
        animation: none;
    }
    .live-dot { animation: none; }
}

@media (max-width: 860px) {
    .hero {
        min-height: auto;
        padding: 112px 0 72px;
    }

    .hero-inner { grid-template-columns: 1fr; }

    .topbar-nav {
        position: fixed;
        top: 68px;
        right: 0;
        left: 0;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 0.6rem clamp(20px, 4vw, 48px) 1.2rem;
        border-bottom: 1px solid var(--line);
        background: var(--pitch-950);
        opacity: 0;
        pointer-events: none;
        transform: translateY(-12px);
        transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out);
    }

    .topbar.is-open .topbar-nav {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .topbar.is-open { background: var(--pitch-950); }

    .topbar-nav a {
        width: 100%;
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--line);
        font-size: 1rem;
    }

    .topbar-pitch {
        border: 0;
        border-radius: 0;
        color: var(--lime) !important;
    }

    .topbar-toggle { display: flex; }
    .topbar.is-open .topbar-toggle span:first-child { transform: translateY(4px) rotate(45deg); }
    .topbar.is-open .topbar-toggle span:last-child { transform: translateY(-4px) rotate(-45deg); }

    .phase-timeline {
        grid-template-columns: 1fr 1fr;
        gap: 2.3rem 0;
    }

    .phase-timeline li:nth-child(2) { border-right: 0; }
    .phase-timeline li:nth-child(3) { padding-left: 0; }
    .phase-timeline li { min-height: 185px; }
}

@media (max-width: 620px) {
    .hero {
        padding: 98px 0 58px;
    }

    .hero h1 { font-size: clamp(3rem, 15vw, 4.6rem); }
    .hero-summary { font-size: 0.93rem; }
    .hero-phases { padding: 0.25rem 0.9rem; }

    .sec { padding: 74px 0; }

    .sec-head {
        grid-template-columns: 1fr;
        gap: 0.8rem;
    }

    .phase-timeline { grid-template-columns: 1fr; }

    .phase-timeline li,
    .phase-timeline li:first-child,
    .phase-timeline li:nth-child(3) {
        min-height: 0;
        padding: 1.5rem 0 1.5rem 1rem;
        border-right: 0;
    }

    .phase-timeline li::before { left: 0; }

    .phase-detail-head {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .phase-label {
        writing-mode: horizontal-tb;
        transform: none;
    }

    .initiative-grid,
    .pillar-grid { grid-template-columns: 1fr; }

    .initiative--wide { grid-column: auto; }

    .vision-layout { grid-template-columns: 1fr; }

    .vision-list { grid-template-columns: 1fr; }
}
