/* ═══════════════════════════════════════════════════════════
   TP OS — The Personal Operating System
   Design System: "The Archive of a Lifetime"
   Dual-theme: Light (default) + Dark (toggle)
   ═══════════════════════════════════════════════════════════ */

/* ── LIGHT THEME (default) ── */
:root {
    /* Surfaces — warm cream, like aged paper */
    --bg-base:    #F7F4ED;
    --bg-soft:    #EFEAE0;
    --bg-elev:    #FFFFFF;
    --bg-card:    #FFFFFF;

    /* Text — ink on paper */
    --text:       #1A1A1C;
    --text-dim:   #5C5852;
    --text-mute:  #9A9590;

    /* Hairlines */
    --hair:           rgba(26, 26, 28, 0.08);
    --hair-bright:    rgba(26, 26, 28, 0.16);
    --hair-gold:      rgba(168, 136, 74, 0.30);

    /* Accent: Archival Gold (deeper for light contrast) */
    --gold:       #A8884A;
    --gold-bright:#B8954A;
    --gold-deep:  #7A5F2A;
    --gold-glow:  rgba(168, 136, 74, 0.15);
    --gold-soft:  rgba(168, 136, 74, 0.08);

    /* Ambient */
    --grain-opacity: 0.025;
    --grain-blend: multiply;
    --vignette-color: var(--bg-base);
    --vignette-opacity: 0.5;
    --aurora-gold: rgba(168, 136, 74, 0.18);
    --aurora-ember: rgba(180, 90, 50, 0.08);
    --aurora-dusk: rgba(120, 100, 140, 0.06);

    /* Nav & shadows */
    --nav-bg:        rgba(255, 255, 255, 0.72);
    --nav-border:    rgba(26, 26, 28, 0.08);
    --shadow-soft:   rgba(26, 26, 28, 0.06);
    --shadow-deep:   rgba(26, 26, 28, 0.12);
    --btn-icon-bg:   rgba(26, 26, 28, 0.08);
    --inset-highlight: rgba(255, 255, 255, 0.6);

    /* Type */
    --font-serif: 'Fraunces', 'Times New Roman', serif;
    --font-sans:  'Satoshi', 'Helvetica Neue', sans-serif;
    --font-mono:  'JetBrains Mono', 'Courier New', monospace;

    /* Motion */
    --ease-spring:  cubic-bezier(0.32, 0.72, 0, 1);
    --ease-out:     cubic-bezier(0.16, 1, 0.3, 1);
    --ease-smooth:  cubic-bezier(0.45, 0, 0.15, 1);

    /* Radii */
    --r-sm:  10px;
    --r-md:  16px;
    --r-lg:  24px;
    --r-xl:  32px;
    --r-pill: 9999px;

    color-scheme: light;
}

/* ── DARK THEME ── */
[data-theme="dark"] {
    /* Surfaces — OLED ink */
    --bg-base:    #0A0A0B;
    --bg-soft:    #0E0E10;
    --bg-elev:    #131316;
    --bg-card:    #161619;

    /* Text — warm off-white */
    --text:       #F5F1E8;
    --text-dim:   #A8A29A;
    --text-mute:  #6B665F;

    /* Hairlines */
    --hair:           rgba(245, 241, 232, 0.07);
    --hair-bright:    rgba(245, 241, 232, 0.14);
    --hair-gold:      rgba(201, 169, 97, 0.25);

    /* Accent: Archival Gold (brighter for dark) */
    --gold:       #C9A961;
    --gold-bright:#E0C485;
    --gold-deep:  #9A7E3F;
    --gold-glow:  rgba(201, 169, 97, 0.12);
    --gold-soft:  rgba(201, 169, 97, 0.06);

    /* Ambient */
    --grain-opacity: 0.035;
    --grain-blend: overlay;
    --vignette-color: var(--bg-base);
    --vignette-opacity: 0.6;
    --aurora-gold: rgba(201, 169, 97, 0.22);
    --aurora-ember: rgba(180, 90, 50, 0.14);
    --aurora-dusk: rgba(120, 100, 140, 0.12);

    /* Nav & shadows */
    --nav-bg:        rgba(14, 14, 16, 0.72);
    --nav-border:    rgba(245, 241, 232, 0.07);
    --shadow-soft:   rgba(0, 0, 0, 0.3);
    --shadow-deep:   rgba(0, 0, 0, 0.5);
    --btn-icon-bg:   rgba(245, 241, 232, 0.10);
    --inset-highlight: rgba(245, 241, 232, 0.04);

    color-scheme: dark;
}


/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    background: var(--bg-base);
    color: var(--text);
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    transition: background 0.6s var(--ease-smooth), color 0.6s var(--ease-smooth);
}

body {
    position: relative;
    overflow-x: hidden;
    line-height: 1.65;
    background: var(--bg-base);
    color: var(--text);
    transition: background 0.6s var(--ease-smooth), color 0.6s var(--ease-smooth);
}

::selection { background: var(--gold-glow); color: var(--gold-deep); }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--hair-bright); border-radius: var(--r-pill); }
::-webkit-scrollbar-thumb:hover { background: var(--gold); }


/* ═══════════════════ AMBIENT BACKGROUND LAYERS ═══════════════════ */

.grain {
    position: fixed;
    inset: 0;
    z-index: 60;
    pointer-events: none;
    opacity: var(--grain-opacity);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    mix-blend-mode: var(--grain-blend);
    transition: opacity 0.6s var(--ease-smooth);
}

.aurora {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}
.aurora__orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.5;
    will-change: transform;
    transition: background 0.8s var(--ease-smooth);
}
.aurora__orb--gold {
    width: 50vw; height: 50vw;
    top: -10%; left: -5%;
    background: radial-gradient(circle, var(--aurora-gold), transparent 65%);
    animation: drift-1 28s var(--ease-smooth) infinite alternate;
}
.aurora__orb--ember {
    width: 45vw; height: 45vw;
    top: 40%; right: -10%;
    background: radial-gradient(circle, var(--aurora-ember), transparent 65%);
    animation: drift-2 34s var(--ease-smooth) infinite alternate;
}
.aurora__orb--dusk {
    width: 40vw; height: 40vw;
    bottom: -5%; left: 30%;
    background: radial-gradient(circle, var(--aurora-dusk), transparent 65%);
    animation: drift-3 40s var(--ease-smooth) infinite alternate;
}

@keyframes drift-1 { to { transform: translate(8vw, 6vh) scale(1.1); } }
@keyframes drift-2 { to { transform: translate(-6vw, -4vh) scale(0.95); } }
@keyframes drift-3 { to { transform: translate(4vw, -8vh) scale(1.05); } }

.vignette {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(ellipse at center, transparent 40%, var(--vignette-color) 100%);
    opacity: var(--vignette-opacity);
    transition: opacity 0.6s var(--ease-smooth);
}

.scroll-progress {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 2px;
    z-index: 70;
    background: transparent;
}
#scroll-bar {
    display: block;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--gold-deep), var(--gold-bright));
    transition: width 0.1s linear;
}


/* ═══════════════════ LAYOUT PRIMITIVES ═══════════════════ */

.container {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2.5rem;
}
.container--narrow { max-width: 860px; }

.section {
    position: relative;
    z-index: 10;
    padding: clamp(6rem, 12vw, 11rem) 0;
}


/* ═══════════════════ NAVIGATION ═══════════════════ */

.nav {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    z-index: 80;
    padding: 1.25rem 2rem;
    display: flex;
    justify-content: center;
    pointer-events: none;
}

.nav__pill {
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.5rem 0.5rem 0.5rem 1.25rem;
    background: var(--nav-bg);
    backdrop-filter: blur(20px) saturate(1.4);
    -webkit-backdrop-filter: blur(20px) saturate(1.4);
    border: 1px solid var(--nav-border);
    border-radius: var(--r-pill);
    box-shadow: 0 8px 32px var(--shadow-soft), inset 0 1px 0 var(--inset-highlight);
    transition: transform 0.5s var(--ease-spring), border-color 0.4s var(--ease-out),
                background 0.6s var(--ease-smooth);
}
.nav.scrolled .nav__pill {
    transform: translateY(-0.25rem);
    border-color: var(--hair-bright);
}

.nav__brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    color: var(--text);
}
.nav__mark {
    display: flex;
    width: 24px; height: 24px;
    color: var(--gold);
}
.nav__mark svg { width: 100%; height: 100%; }
.nav__word {
    font-family: var(--font-serif);
    font-weight: 500;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
}

.nav__links {
    display: flex;
    align-items: center;
    gap: 1.75rem;
}
.nav__links a {
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-dim);
    text-decoration: none;
    transition: color 0.3s var(--ease-out);
    position: relative;
}
.nav__links a::after {
    content: '';
    position: absolute;
    bottom: -4px; left: 0;
    width: 0; height: 1px;
    background: var(--gold);
    transition: width 0.3s var(--ease-spring);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { width: 100%; }

/* Theme toggle */
.nav__theme {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px; height: 34px;
    border-radius: 50%;
    background: var(--btn-icon-bg);
    border: 1px solid var(--hair);
    cursor: pointer;
    color: var(--text-dim);
    transition: all 0.4s var(--ease-spring);
    flex-shrink: 0;
}
.nav__theme:hover {
    color: var(--gold);
    border-color: var(--hair-gold);
    background: var(--gold-soft);
}
.nav__theme svg {
    width: 16px; height: 16px;
    transition: transform 0.5s var(--ease-spring);
}
.nav__theme:hover svg { transform: rotate(30deg); }
.nav__theme .icon-sun { display: none; }
.nav__theme .icon-moon { display: block; }
[data-theme="dark"] .nav__theme .icon-sun { display: block; }
[data-theme="dark"] .nav__theme .icon-moon { display: none; }

.nav__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.55rem 0.55rem 1.1rem;
    background: var(--text);
    color: var(--bg-base);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    border-radius: var(--r-pill);
    transition: all 0.4s var(--ease-spring);
}
.nav__cta:hover {
    background: var(--gold);
    color: var(--bg-base);
    transform: scale(0.97);
}
.nav__cta-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px; height: 26px;
    border-radius: 50%;
    background: var(--btn-icon-bg);
    transition: transform 0.4s var(--ease-spring);
}
.nav__cta-icon svg { width: 14px; height: 14px; }
.nav__cta:hover .nav__cta-icon { transform: translate(2px, -1px); }


/* ═══════════════════ BUTTONS ═══════════════════ */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 0.85rem 0.85rem 1.6rem;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--r-pill);
    cursor: pointer;
    transition: all 0.5s var(--ease-spring);
    border: none;
}
.btn:active { transform: scale(0.97); }

.btn__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px; height: 30px;
    border-radius: 50%;
    background: var(--btn-icon-bg);
    transition: transform 0.5s var(--ease-spring);
}
.btn__icon svg { width: 15px; height: 15px; }
.btn:hover .btn__icon { transform: translate(3px, -1px) scale(1.05); }

.btn--primary {
    background: var(--text);
    color: var(--bg-base);
    box-shadow: 0 4px 20px var(--shadow-soft);
}
.btn--primary:hover {
    background: var(--gold);
    color: var(--bg-base);
    box-shadow: 0 8px 30px var(--gold-glow);
}
.btn--primary .btn__icon { background: rgba(255,255,255,0.15); }
[data-theme="light"] .btn--primary .btn__icon { background: rgba(255,255,255,0.2); }
[data-theme="dark"] .btn--primary .btn__icon { background: rgba(255,255,255,0.12); }

.btn--ghost {
    padding: 0.85rem 1.6rem;
    background: transparent;
    color: var(--text-dim);
    border: 1px solid var(--hair-bright);
}
.btn--ghost:hover {
    color: var(--text);
    border-color: var(--hair-gold);
    background: var(--gold-soft);
}

.btn--large {
    padding: 1.1rem 1.1rem 1.1rem 2rem;
    font-size: 1rem;
}
.btn--large .btn__icon { width: 36px; height: 36px; }
.btn--large .btn__icon svg { width: 17px; height: 17px; }


/* ═══════════════════ TYPOGRAPHY UTILITIES ═══════════════════ */

em {
    font-style: italic;
    font-family: var(--font-serif);
    font-weight: 400;
    color: var(--gold);
    font-variation-settings: "opsz" 144;
}

.dot {
    display: inline-block;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 8px var(--gold-glow);
    animation: pulse 2.4s var(--ease-smooth) infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.85); }
}

.section__index {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 3rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--hair);
}
.section__num {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--gold);
    letter-spacing: 0.1em;
}
.section__label {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 400;
    color: var(--text-mute);
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.section__title {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4.5vw, 3.5rem);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 1.5rem;
    font-variation-settings: "opsz" 96;
}
.section__lede {
    font-size: 1.05rem;
    color: var(--text-dim);
    max-width: 60ch;
    line-height: 1.75;
}


/* ═══════════════════ HERO ═══════════════════ */

.hero {
    position: relative;
    z-index: 10;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8rem 2.5rem 4rem;
    text-align: center;
}

.hero__inner {
    max-width: 900px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 1.1rem;
    background: var(--gold-soft);
    border: 1px solid var(--hair-gold);
    border-radius: var(--r-pill);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--gold-deep);
    letter-spacing: 0.12em;
    margin-bottom: 2.5rem;
}
[data-theme="dark"] .hero__eyebrow { color: var(--gold-bright); }

.hero__title {
    font-family: var(--font-serif);
    font-size: clamp(2.8rem, 7vw, 5.5rem);
    font-weight: 400;
    line-height: 1.08;
    letter-spacing: -0.035em;
    color: var(--text);
    margin-bottom: 2rem;
    font-variation-settings: "opsz" 144;
}
.hero__title .reveal-line {
    display: block;
    overflow: hidden;
}
.hero__title em { font-size: 1.02em; }

.hero__lede {
    font-size: clamp(1rem, 1.4vw, 1.2rem);
    color: var(--text-dim);
    line-height: 1.8;
    max-width: 52ch;
    margin-bottom: 2.75rem;
}

.hero__actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.hero__trio {
    display: flex;
    align-items: center;
    gap: clamp(1.5rem, 4vw, 3rem);
    padding-top: 2.5rem;
    border-top: 1px solid var(--hair);
    width: 100%;
    max-width: 640px;
    justify-content: center;
}
.hero__trio-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
}
.hero__trio-name {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 500;
    color: var(--text-dim);
    font-variation-settings: "opsz" 48;
}
.hero__trio-act {
    font-size: 0.78rem;
    color: var(--text-mute);
    letter-spacing: 0.02em;
}
.hero__trio-item--accent .hero__trio-name {
    color: var(--gold);
    font-style: italic;
}
.hero__trio-item--accent .hero__trio-act {
    color: var(--gold-deep);
}
[data-theme="dark"] .hero__trio-item--accent .hero__trio-act { color: var(--gold); }
.hero__trio-sep {
    width: 1px;
    height: 32px;
    background: var(--hair);
}

.hero__scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-mute);
    letter-spacing: 0.3em;
}
.hero__scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--gold), transparent);
    animation: scroll-pulse 2.5s var(--ease-smooth) infinite;
}
@keyframes scroll-pulse {
    0% { transform: scaleY(0); transform-origin: top; }
    50% { transform: scaleY(1); transform-origin: top; }
    51% { transform: scaleY(1); transform-origin: bottom; }
    100% { transform: scaleY(0); transform-origin: bottom; }
}


/* ═══════════════════ VISION SECTION ═══════════════════ */

.section--statement { padding-top: clamp(8rem, 14vw, 13rem); }

.statement {
    font-family: var(--font-serif);
    font-size: clamp(2.2rem, 5.5vw, 4.5rem);
    font-weight: 400;
    line-height: 1.12;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 3rem;
    font-variation-settings: "opsz" 144;
}
.statement__body { max-width: 56ch; }
.statement__body p {
    font-size: 1.1rem;
    color: var(--text-dim);
    line-height: 1.85;
    margin-bottom: 1.25rem;
}


/* ═══════════════════ BIRTH SECTION ═══════════════════ */

.section--birth {
    text-align: center;
    padding-top: clamp(7rem, 12vw, 11rem);
}

.birth__mark {
    width: 140px;
    height: 140px;
    margin: 0 auto 3rem;
    color: var(--gold);
    opacity: 0.85;
}
.birth__mark svg { width: 100%; height: 100%; }
.birth__mark .ring-outer { animation: birth-ring 6s var(--ease-smooth) infinite; }
.birth__mark .ring-mid { animation: birth-ring 6s var(--ease-smooth) infinite 0.5s; }
.birth__mark .ring-inner { animation: birth-ring 6s var(--ease-smooth) infinite 1s; }
@keyframes birth-ring {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 1; }
}

.birth__title {
    font-family: var(--font-serif);
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 0.75rem;
    font-variation-settings: "opsz" 96;
}
.birth__sub {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    color: var(--gold);
    margin-bottom: 3rem;
    font-variation-settings: "opsz" 72;
}

.birth__lines { max-width: 540px; margin: 0 auto; }
.birth__lines p {
    font-size: 1.1rem;
    color: var(--text-dim);
    line-height: 1.9;
    margin-bottom: 1rem;
}
.birth__lines p:nth-child(2) {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 1.75rem;
}


/* ═══════════════════ ARCHITECTURE / DATA SECTION ═══════════════════ */

.section--data .section__title { margin-bottom: 1.25rem; }

.data__grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr 1fr;
    gap: 1.5rem;
    margin-top: 4rem;
    align-items: stretch;
}

/* Double-bezel card system */
.bezel { position: relative; }
.bezel__shell {
    background: var(--hair);
    border: 1px solid var(--hair);
    border-radius: var(--r-xl);
    padding: 1.5px;
    height: 100%;
    box-shadow: 0 20px 50px var(--shadow-deep);
    transition: border-color 0.5s var(--ease-out), transform 0.5s var(--ease-spring),
                box-shadow 0.5s var(--ease-out);
}
.bezel:hover .bezel__shell {
    border-color: var(--hair-bright);
    transform: translateY(-4px);
}
.bezel__core {
    background: var(--bg-card);
    border-radius: calc(var(--r-xl) - 1.5px);
    padding: 2.5rem 2rem;
    height: 100%;
    box-shadow: inset 0 1px 0 var(--inset-highlight);
    position: relative;
    overflow: hidden;
}

.bezel--accent .bezel__shell {
    border-color: var(--hair-gold);
    background: var(--gold-soft);
}
.bezel--accent .bezel__core {
    background: linear-gradient(160deg, var(--bg-card), var(--bg-elev));
}
.bezel--accent:hover .bezel__shell {
    border-color: var(--gold);
    box-shadow: 0 20px 60px var(--gold-glow);
}

.bezel__core--center {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    justify-content: center;
}

.data__col-head {
    margin-bottom: 1.75rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--hair);
}
.data__col-tag {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--gold);
    letter-spacing: 0.18em;
    margin-bottom: 0.5rem;
}
.data__col-title {
    font-family: var(--font-serif);
    font-size: 1.35rem;
    font-weight: 500;
    color: var(--text);
    font-variation-settings: "opsz" 48;
}

.data__list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}
.data__list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.92rem;
    color: var(--text-dim);
    transition: color 0.3s var(--ease-out);
}
.data__list li:hover { color: var(--text); }
.data__dot {
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--gold);
    opacity: 0.6;
    flex-shrink: 0;
}

/* Core processor visual */
.core__pulse {
    position: relative;
    width: 80px;
    height: 80px;
    margin-bottom: 1.5rem;
}
.core__pulse span {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px solid var(--gold);
    opacity: 0;
    animation: core-pulse 3s var(--ease-smooth) infinite;
}
.core__pulse span:nth-child(2) { animation-delay: 1s; }
.core__pulse span:nth-child(3) { animation-delay: 2s; }
@keyframes core-pulse {
    0% { transform: scale(0.5); opacity: 0.8; }
    100% { transform: scale(1.4); opacity: 0; }
}

.core__mark {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 40px; height: 40px;
    color: var(--gold);
}
.core__mark svg { width: 100%; height: 100%; }

.core__label {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--gold);
    letter-spacing: 0.2em;
    margin-bottom: 0.35rem;
}
.core__sub {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 2rem;
    font-variation-settings: "opsz" 48;
}

.core__tasks {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    max-width: 240px;
}
.core__tasks li {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    padding: 0.35rem 0.7rem;
    background: var(--gold-soft);
    border: 1px solid var(--hair-gold);
    border-radius: var(--r-pill);
    color: var(--gold-deep);
}
[data-theme="dark"] .core__tasks li { color: var(--gold-bright); }


/* ═══════════════════ FIVE ERAS SECTION ═══════════════════ */

.section--eras .section__title { margin-bottom: 5rem; }

.eras__track {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.eras__line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom,
        transparent 0%,
        var(--hair-gold) 8%,
        var(--hair-gold) 92%,
        transparent 100%);
    transform: translateX(-50%);
}

.era {
    position: relative;
    width: 50%;
    padding: 0 3.5rem;
    margin-bottom: 4rem;
}
.eras__track > .era:nth-child(2) { margin-left: 0; text-align: right; padding: 0 3.5rem 0 0; }
.eras__track > .era:nth-child(3) { margin-left: 50%; text-align: left; padding: 0 0 0 3.5rem; }
.eras__track > .era:nth-child(4) { margin-left: 0; text-align: right; padding: 0 3.5rem 0 0; }
.eras__track > .era:nth-child(5) { margin-left: 50%; text-align: left; padding: 0 0 0 3.5rem; }
.eras__track > .era:nth-child(6) { margin-left: 0; text-align: right; padding: 0 3.5rem 0 0; }

.era__node {
    position: absolute;
    top: 0.5rem;
    width: 14px; height: 14px;
    border-radius: 50%;
    background: var(--bg-base);
    border: 1.5px solid var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: background 0.6s var(--ease-smooth);
}
.era__node span {
    width: 4px; height: 4px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 8px var(--gold-glow);
}
.eras__track > .era:nth-child(2) .era__node,
.eras__track > .era:nth-child(4) .era__node,
.eras__track > .era:nth-child(6) .era__node { right: -7px; }
.eras__track > .era:nth-child(3) .era__node,
.eras__track > .era:nth-child(5) .era__node { left: -7px; }

.era__node--final {
    border-color: var(--gold);
    box-shadow: 0 0 16px var(--gold-glow);
}
.era__node--final span {
    background: var(--gold);
    width: 6px; height: 6px;
}

/* Era function icon (from logo image 1) */
.era__icon {
    width: 36px; height: 36px;
    margin-bottom: 1rem;
    color: var(--gold);
    opacity: 0.7;
}
.era__icon svg { width: 100%; height: 100%; }
.eras__track > .era:nth-child(2) .era__icon,
.eras__track > .era:nth-child(4) .era__icon,
.eras__track > .era:nth-child(6) .era__icon { margin-left: auto; }

.era__num {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--gold);
    letter-spacing: 0.15em;
    margin-bottom: 0.5rem;
}
.era__name {
    font-family: var(--font-serif);
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 400;
    color: var(--text);
    line-height: 1.1;
    margin-bottom: 0.25rem;
    font-variation-settings: "opsz" 72;
}
.era__name-cn {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1rem;
    color: var(--gold);
    margin-bottom: 1rem;
    font-variation-settings: "opsz" 48;
}
.era__desc {
    font-size: 0.92rem;
    color: var(--text-dim);
    line-height: 1.75;
    max-width: 38ch;
}
.eras__track > .era:nth-child(2) .era__desc,
.eras__track > .era:nth-child(4) .era__desc,
.eras__track > .era:nth-child(6) .era__desc { margin-left: auto; }

.era--final { margin-bottom: 0; }
.era__seal {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    margin-top: 1.5rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid var(--hair-gold);
    border-radius: var(--r-pill);
    background: var(--gold-soft);
}
.era__seal span {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 0.95rem;
    color: var(--gold);
    font-variation-settings: "opsz" 48;
}
.era__seal-cn {
    font-family: var(--font-sans) !important;
    font-style: normal !important;
    font-size: 0.72rem !important;
    color: var(--text-mute) !important;
}


/* ═══════════════════ DIGITAL SELF SECTION ═══════════════════ */

.section--self {
    text-align: center;
    padding-top: clamp(8rem, 14vw, 12rem);
}

.self__visual {
    display: flex;
    justify-content: center;
    margin-bottom: 3rem;
}

.self__orb {
    position: relative;
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.self__ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--hair-gold);
}
.self__ring--1 {
    width: 100%; height: 100%;
    animation: self-rotate 20s linear infinite;
    border-style: dashed;
    border-color: var(--hair);
}
.self__ring--2 {
    width: 70%; height: 70%;
    animation: self-rotate 14s linear infinite reverse;
    border-color: var(--hair-gold);
}
.self__ring--3 {
    width: 45%; height: 45%;
    animation: self-pulse 4s var(--ease-smooth) infinite;
    border-color: var(--gold);
}
.self__core {
    width: 24px; height: 24px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--gold-bright), var(--gold-deep));
    box-shadow: 0 0 40px var(--gold-glow), 0 0 80px var(--gold-glow);
    animation: self-glow 3s var(--ease-smooth) infinite;
}
@keyframes self-rotate { to { transform: rotate(360deg); } }
@keyframes self-pulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50% { transform: scale(1.08); opacity: 1; }
}
@keyframes self-glow {
    0%, 100% { box-shadow: 0 0 40px var(--gold-glow), 0 0 80px var(--gold-glow); }
    50% { box-shadow: 0 0 60px var(--gold-glow), 0 0 120px var(--gold-glow); }
}

.self__title {
    font-family: var(--font-serif);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 0.5rem;
    font-variation-settings: "opsz" 144;
}
.self__sub {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: clamp(1.3rem, 2.5vw, 1.8rem);
    color: var(--gold);
    margin-bottom: 2.5rem;
    font-variation-settings: "opsz" 72;
}
.self__body {
    max-width: 540px;
    margin: 0 auto;
    font-size: 1.1rem;
    color: var(--text-dim);
    line-height: 1.9;
}


/* ═══════════════════ MANIFESTO SECTION ═══════════════════ */

.section--manifesto {
    text-align: center;
    padding-top: clamp(7rem, 12vw, 10rem);
}
.section--manifesto .section__index {
    justify-content: center;
    border-bottom: none;
    margin-bottom: 3.5rem;
}

.manifesto__lines p {
    font-family: var(--font-serif);
    font-size: clamp(1.5rem, 3.5vw, 2.6rem);
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
    font-variation-settings: "opsz" 96;
}
.manifesto__lines p:last-child {
    color: var(--text);
    margin-top: 1.5rem;
}


/* ═══════════════════ CTA SECTION ═══════════════════ */

.section--cta { padding-bottom: clamp(6rem, 10vw, 9rem); }

.cta__bezel { position: relative; }
.cta__bezel-shell {
    background: linear-gradient(135deg, var(--gold-soft), transparent 60%);
    border: 1px solid var(--hair-gold);
    border-radius: var(--r-xl);
    padding: 2px;
    box-shadow: 0 30px 80px var(--shadow-deep), 0 0 60px var(--gold-glow);
}
.cta__bezel-core {
    background: radial-gradient(ellipse at top, var(--gold-glow), transparent 70%), var(--bg-card);
    border-radius: calc(var(--r-xl) - 2px);
    padding: clamp(3rem, 7vw, 6rem) 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.cta__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 1.1rem;
    background: var(--gold-soft);
    border: 1px solid var(--hair-gold);
    border-radius: var(--r-pill);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--gold-deep);
    letter-spacing: 0.12em;
    margin-bottom: 2rem;
}
[data-theme="dark"] .cta__eyebrow { color: var(--gold-bright); }

.cta__title {
    font-family: var(--font-serif);
    font-size: clamp(2.2rem, 5vw, 4rem);
    font-weight: 400;
    line-height: 1.12;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 1.5rem;
    font-variation-settings: "opsz" 144;
}

.cta__lede {
    font-size: 1.05rem;
    color: var(--text-dim);
    line-height: 1.8;
    max-width: 48ch;
    margin-bottom: 2.5rem;
}

.cta__note {
    margin-top: 2.5rem;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-mute);
    letter-spacing: 0.12em;
}


/* ═══════════════════ FOOTER ═══════════════════ */

.footer {
    position: relative;
    z-index: 10;
    border-top: 1px solid var(--hair);
    padding: 3rem 0;
    background: var(--bg-soft);
    transition: background 0.6s var(--ease-smooth);
}
.footer__grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}
.footer__brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-serif);
    font-weight: 500;
    font-size: 1rem;
    color: var(--text);
}
.footer__mark {
    display: flex;
    width: 22px; height: 22px;
    color: var(--gold);
}
.footer__mark svg { width: 100%; height: 100%; }
.footer__links { display: flex; gap: 1.75rem; }
.footer__links a {
    font-size: 0.82rem;
    color: var(--text-mute);
    text-decoration: none;
    transition: color 0.3s var(--ease-out);
}
.footer__links a:hover { color: var(--gold); }
.footer__copy {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-mute);
    letter-spacing: 0.05em;
}


/* ═══════════════════ SCROLL REVEAL ═══════════════════ */

.reveal {
    opacity: 0;
    transform: translateY(40px);
    filter: blur(6px);
    transition: opacity 0.9s var(--ease-spring),
                transform 0.9s var(--ease-spring),
                filter 0.9s var(--ease-spring);
    transition-delay: var(--reveal-delay, 0s);
}
.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
}

.reveal-line {
    display: block;
    transform: translateY(110%);
    transition: transform 1s var(--ease-spring);
    transition-delay: var(--reveal-delay, 0s);
}
.reveal-line.is-visible { transform: translateY(0); }

.data__grid .bezel:nth-child(1) { --reveal-delay: 0s; }
.data__grid .bezel:nth-child(2) { --reveal-delay: 0.12s; }
.data__grid .bezel:nth-child(3) { --reveal-delay: 0.24s; }


/* ═══════════════════ RESPONSIVE ═══════════════════ */

@media (max-width: 1024px) {
    .data__grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    .bezel--accent { order: -1; }
}

@media (max-width: 768px) {
    .container { padding: 0 1.5rem; }
    .nav { padding: 0.75rem 1rem; }
    .nav__pill { gap: 0.75rem; padding: 0.4rem 0.4rem 0.4rem 1rem; }
    .nav__links { display: none; }

    .hero { padding: 7rem 1.5rem 3rem; }
    .hero__actions { flex-direction: column; width: 100%; max-width: 320px; }
    .hero__trio { flex-direction: column; gap: 1.25rem; }
    .hero__trio-sep { width: 32px; height: 1px; }
    .hero__scroll { display: none; }

    .section { padding: 5rem 0; }

    .eras__line { left: 14px; }
    .eras__track > .era,
    .eras__track > .era:nth-child(2),
    .eras__track > .era:nth-child(3),
    .eras__track > .era:nth-child(4),
    .eras__track > .era:nth-child(5),
    .eras__track > .era:nth-child(6) {
        width: 100%;
        margin-left: 0;
        text-align: left;
        padding: 0 0 0 2.75rem;
    }
    .eras__track > .era:nth-child(2) .era__node,
    .eras__track > .era:nth-child(3) .era__node,
    .eras__track > .era:nth-child(4) .era__node,
    .eras__track > .era:nth-child(5) .era__node,
    .eras__track > .era:nth-child(6) .era__node { left: 7px; right: auto; }
    .eras__track > .era:nth-child(2) .era__desc,
    .eras__track > .era:nth-child(4) .era__desc,
    .eras__track > .era:nth-child(6) .era__desc { margin-left: 0; }
    .eras__track > .era:nth-child(2) .era__icon,
    .eras__track > .era:nth-child(4) .era__icon,
    .eras__track > .era:nth-child(6) .era__icon { margin-left: 0; }

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

@media (max-width: 480px) {
    .hero__title { font-size: clamp(2.2rem, 9vw, 3rem); }
    .statement { font-size: 1.8rem; }
    .nav__cta span:first-child { display: none; }
    .nav__cta { padding: 0.5rem; }
    .nav__cta-icon { background: transparent; }
}


/* ═══════════════════ REDUCED MOTION ═══════════════════ */

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .aurora, .grain { display: none; }
    .reveal { opacity: 1; transform: none; filter: none; }
    .reveal-line { transform: none; }
}
