/*--------------------------------------------------------------
# DotZeo "Inside the SEO Engine" — cinematic /experience page.
# A fixed WebGL stage renders behind tall, scrolling content panels.
# All copy lives in the DOM (SEO + a11y); the 3D is an enhancement.
--------------------------------------------------------------*/

/* The persistent 3D stage sits behind everything, ignores pointer events. */
.dz-stage {
    position: fixed;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    display: block;
    pointer-events: none;
}

/* This cinematic scrolls only vertically. Clip horizontal overflow on the root
   too (not just body) so a phone never gets a horizontal scrollbar from the
   full-viewport fixed layers or an off-screen projected chip. Page-scoped:
   experience.css is loaded only on /experience. */
html { overflow-x: hidden; }

/* Let the cinematic breathe: float the nav over the stage on this page only. */
body:has(.dz-stage) {
    background: #02060a;
}
body:has(.dz-stage) .site-nav {
    background: transparent;
    -webkit-backdrop-filter: none;
            backdrop-filter: none;
    border-bottom-color: transparent;
}
body:has(.dz-stage) .site-footer {
    position: relative;
    z-index: 1;
    background: rgba(2, 6, 10, .8);
    -webkit-backdrop-filter: blur(8px);
            backdrop-filter: blur(8px);
}

/* The cinematic page is dark-only (light theme is not built for the 3D scene),
   so hide the theme toggle here. */
body:has(.dz-stage) [data-theme-toggle] { display: none; }

/* Module tokens that track the 3D nodes orbiting the core. */
.xp-nodes {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    /* The chips are projected onto the 3D nodes; on narrow screens a node can
       project past the right edge. Clip so an off-screen chip never stretches
       the page into a horizontal scroll. */
    overflow: hidden;
}
.xp-node {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 13px 6px 10px;
    border-radius: 999px;
    font-family: var(--nav-font);
    font-size: .82rem;
    font-weight: 600;
    white-space: nowrap;
    color: #eafff4;
    background: rgba(7, 18, 13, .62);
    border: 1px solid rgba(53, 208, 122, .42);
    -webkit-backdrop-filter: blur(7px);
            backdrop-filter: blur(7px);
    box-shadow: 0 6px 22px rgba(0, 0, 0, .45), 0 0 16px rgba(53, 208, 122, .28);
    opacity: 0;
    will-change: transform, opacity;
}
.xp-node .icon {
    width: 15px;
    height: 15px;
    color: #4ade80;
    filter: drop-shadow(0 0 5px rgba(74, 222, 128, .6));
}

/* Auto-play control */
.xp-play {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 4;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 11px 18px 11px 14px;
    border-radius: 999px;
    border: 1px solid rgba(53, 208, 122, .45);
    background: rgba(7, 18, 13, .72);
    -webkit-backdrop-filter: blur(10px);
            backdrop-filter: blur(10px);
    color: #eafff4;
    font-family: var(--nav-font);
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 28px rgba(0, 0, 0, .5), 0 0 18px rgba(53, 208, 122, .25);
    transition: border-color .2s, transform .2s, box-shadow .2s;
}
.xp-play:hover { transform: translateY(-2px); border-color: rgba(53, 208, 122, .8); }
.xp-play .ico { width: 20px; height: 20px; color: #4ade80; }
.xp-play .ico-pause { display: none; }
.xp-play.playing .ico-play { display: none; }
.xp-play.playing .ico-pause { display: inline; }

/* Scrolling content layer above the stage. */
.xp {
    position: relative;
    z-index: 1;
}

.xp-sec {
    position: relative;
    min-height: 118vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 90px 0;
    text-align: center;
}
.xp-hero { min-height: 128vh; }
.xp-cta { min-height: 96vh; }

.xp-inner {
    position: relative;
    max-width: 820px;
    margin: 0 auto;
    padding: 0 24px;
    /* GSAP fades/translates these in; keep visible by default for the no-JS fallback. */
    will-change: opacity, transform;
}

/* Readability scrim: a soft, blurred dark halo behind the copy so the text
   stays legible over the bright 3D pages/scenes behind it. Soft-masked edges
   keep it from looking like a hard box over the cinematic. */
.xp-inner::before {
    content: "";
    position: absolute;
    inset: -38px -40px;
    z-index: -1;
    border-radius: 40px;
    background: rgba(3, 7, 12, .6);
    -webkit-backdrop-filter: blur(7px) brightness(.62);
            backdrop-filter: blur(7px) brightness(.62);
    -webkit-mask-image: radial-gradient(ellipse 75% 70% at center, #000 52%, transparent 92%);
            mask-image: radial-gradient(ellipse 75% 70% at center, #000 52%, transparent 92%);
}

/* Eyebrows + pills */
.xp-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--nav-font);
    font-size: .82rem;
    font-weight: 500;
    color: var(--emerald);
    padding: 7px 16px;
    border-radius: 999px;
    border: 1px solid rgba(34, 197, 94, .35);
    background: rgba(34, 197, 94, .08);
    margin-bottom: 26px;
}
.xp-eyebrow {
    display: block;
    font-family: var(--nav-font);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--text-faint);
    margin-bottom: 16px;
}

/* Headlines */
.xp-title {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: clamp(2.8rem, 9vw, 6.5rem);
    line-height: 1.02;
    letter-spacing: -.02em;
    margin: 0 0 20px;
    color: #fff;
    text-shadow: 0 2px 60px rgba(0, 0, 0, .6);
}
.xp-title .grad {
    background: linear-gradient(120deg, #79c32f, #22c55e 45%, #38bdf8);
    -webkit-background-clip: text;
            background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}
.xp-h2 {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: clamp(1.9rem, 4.4vw, 3.2rem);
    line-height: 1.1;
    margin: 0 0 18px;
    color: #fff;
    text-shadow: 0 2px 40px rgba(0, 0, 0, .55);
}
.xp-lede {
    font-size: clamp(1.02rem, 1.6vw, 1.25rem);
    color: var(--text-soft);
    max-width: 38rem;
    margin: 0 auto 30px;
    text-shadow: 0 1px 30px rgba(0, 0, 0, .5);
}

/* Live metric counters (Section 2) */
.xp-metrics {
    display: flex;
    gap: clamp(20px, 6vw, 64px);
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 36px;
}
.xp-metric b {
    display: block;
    font-family: var(--nav-font);
    font-weight: 700;
    font-size: clamp(2.4rem, 6vw, 4rem);
    line-height: 1;
    color: #fff;
    font-variant-numeric: tabular-nums;
}
.xp-metric.bad b { color: var(--status-bad); }
.xp-metric.good b { color: var(--status-good); }
.xp-metric span {
    display: block;
    margin-top: 10px;
    font-size: .82rem;
    color: var(--text-muted);
    letter-spacing: .04em;
}

/* Section 3: AI fix score + list */
.xp-fixwrap { display: flex; gap: clamp(24px, 6vw, 64px); align-items: center; justify-content: center; flex-wrap: wrap; margin-top: 30px; }
.xp-bigscore b { display: block; font-family: var(--nav-font); font-weight: 700; font-size: clamp(3.4rem, 9vw, 6rem); line-height: 1; color: var(--status-good); font-variant-numeric: tabular-nums; text-shadow: 0 0 40px rgba(34, 197, 94, .4); }
.xp-bigscore span { display: block; margin-top: 8px; font-size: .82rem; color: var(--text-muted); letter-spacing: .05em; }
.xp-fixlist { list-style: none; margin: 0; padding: 0; text-align: left; }
.xp-fixlist li { display: flex; align-items: center; gap: 10px; padding: 7px 0; color: var(--text-soft); font-size: .98rem; }
.xp-fixlist li::before { content: "\2713"; display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: rgba(34, 197, 94, .15); color: var(--status-good); font-size: .8rem; flex: 0 0 auto; }

/* Section 8: Ask Zeo chat */
.xp-chat { max-width: 32rem; margin: 26px auto 0; text-align: left; }
.xp-q { font-size: 1.15rem; color: #fff; background: rgba(255, 255, 255, .06); border: 1px solid var(--hairline-strong); border-radius: 14px 14px 14px 4px; padding: 14px 18px; display: inline-block; }
.xp-a { margin-top: 14px; font-size: 1.05rem; color: var(--text-soft); background: rgba(34, 197, 94, .1); border: 1px solid rgba(34, 197, 94, .3); border-radius: 14px 14px 4px 14px; padding: 14px 18px; }

/* CTA */
.xp-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 14px;
}

/* Scroll hint */
.xp-scroll-hint {
    margin-top: 44px;
    font-family: var(--nav-font);
    font-size: .8rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--text-faint);
}
.xp-scroll-hint .chev {
    display: block;
    margin: 10px auto 0;
    width: 22px;
    height: 22px;
    animation: xp-bob 1.8s ease-in-out infinite;
}
@keyframes xp-bob {
    0%, 100% { transform: translateY(0); opacity: .5; }
    50%      { transform: translateY(7px); opacity: 1; }
}

/* A faint vignette to seat the type over the bright 3D. */
.xp-veil {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: radial-gradient(120% 80% at 50% 50%, transparent 55%, rgba(2, 6, 10, .55) 100%);
}

@media (max-width: 575px) {
    .xp-sec, .xp-hero { min-height: 100vh; }
    .xp-metrics { gap: 26px; }
}

@media (prefers-reduced-motion: reduce) {
    .xp-scroll-hint .chev { animation: none; }
}
