/* ═══════════════════════════════════════════════════════════════════════════
   pages/about.css — about.html, "An Atlas of the Night" (both editions).
   Tokens only; builds on style.css + atlas.css; byte-identical TW / EN.

   Ten acts read as ten plates over one continuous night sky (atlas.js draws
   it). Motion comes from atlas.js: --p scene progress, --mx/--my pointer
   parallax, data-fill words, .is-visible on [data-inview], tilt, lantern.
   Without JS every act is static and complete; under prefers-reduced-motion
   nothing moves on its own.
   ═══════════════════════════════════════════════════════════════════════════ */

/* the acts own their rhythm; the side padding is already 0 from .container--full */
main:has(> .about-act) { padding-block: 0; }
/* the Alice ornaments of the app shell stay off this page: the engravings are its pictures */
body:has(main > .about-act) .theme-deco { display: none; }

.about-act {
    position: relative;      /* above the fixed sky, which lives inside <main> */
    z-index: 1;
    padding-block: clamp(96px, 12vw, 200px);
}
.about-act + .about-act { border-top: 1px solid color-mix(in srgb, var(--border) 70%, transparent); }

.about-in { width: min(100% - 2 * var(--gutter), 1200px); margin-inline: auto; }
.about-center { text-align: center; }
.about-head { max-width: 820px; margin: 0 auto clamp(56px, 7vw, 110px); text-align: center; }

.about-split {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(48px, 7vw, 128px);
    align-items: center;
}
.about-split--text { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
.about-split--text.about-split--flip { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); }
.about-col { max-width: 38rem; }

/* ─── type ──────────────────────────────────────────────────────────────── */
.about-chapter, .about-eyebrow {
    display: flex;
    align-items: center;
    gap: var(--s-4);
    margin-bottom: var(--s-6);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 500;
    letter-spacing: 0.24em;
    color: var(--gold);
}
.about-chapter::before { content: ''; width: 44px; height: 1px; background: currentColor; opacity: 0.6; }
.about-chapter--center, .about-eyebrow { justify-content: center; }
.about-chapter--center::after { content: ''; width: 44px; height: 1px; background: currentColor; opacity: 0.6; }
.about-eyebrow { letter-spacing: 0.42em; padding-left: 0.42em; }

.about-act .about-h2 {
    margin-bottom: var(--s-7);
    font-size: clamp(2rem, 1rem + 3.3vw, 4.4rem);
    line-height: 1.32;
    letter-spacing: var(--track-cjk);
    color: var(--text-strong);
    text-wrap: initial;
}
:lang(en) .about-act .about-h2 { line-height: 1.06; letter-spacing: -0.015em; }
.about-h2 em { font-style: normal; color: var(--gold); }
:lang(en) .about-h2 em { font-style: italic; }
/* CJK breaks between any two characters; a phrase that must stay whole wears this */
.ab-keep { white-space: nowrap; }

.about-body {
    font-family: var(--font-display);
    font-size: clamp(1.08rem, 0.96rem + 0.5vw, 1.32rem);
    line-height: 2;
    letter-spacing: var(--track-cjk);
    color: var(--text-muted);
}
:lang(en) .about-body { letter-spacing: 0; line-height: 1.75; }
.about-body--center { margin-inline: auto; max-width: 34em; }

.about-cap {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.2em;
    color: var(--text-dim);
}
.about-cap--gold { color: var(--gold); margin-bottom: var(--s-4); }

.about-orn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--s-4);
    max-width: 18rem;
    margin: var(--s-7) auto;
    font-size: 1.2rem;
    color: var(--gold);
}
.about-orn::before, .about-orn::after { content: ''; flex: 1; height: 1px; background: currentColor; opacity: 0.4; }
.about-orn--left { display: block; max-width: none; margin-left: 0; text-align: left; }
.about-orn--left::before, .about-orn--left::after { display: none; }

/* ═══ 1 · overture: the moon over the title ════════════════════════════════ */
.about-hero {
    display: grid;
    place-items: center;
    min-height: calc(100vh - var(--nav-h));
    min-height: calc(100svh - var(--nav-h));
    padding-block: clamp(64px, 8vw, 120px);
    overflow: clip;
}
.moon-stage {
    position: absolute;
    z-index: -1;
    left: 50%;
    top: 50%;
    width: min(100vh, 94vw);
    aspect-ratio: 1;
    pointer-events: none;
    translate: calc(-50% + var(--mx, 0) * -16px) calc(-50% + var(--my, 0) * -12px + var(--p, 0) * 22vh);
    scale: calc(1 + var(--p, 0) * 0.3);
    opacity: calc(1 - var(--p, 0) * 1.3);
}
.moon-stage svg, .compass-wrap svg, .closing-mark svg { width: 100%; height: 100%; overflow: visible; }
/* the animated SVG groups sit in stacked layers on one grid; the HTML wrapper is what turns or fades */
/* a turning HTML box leaves its corners in the page's scrollable overflow (a turning SVG group did not): the stack clips them */
.moon-stage, .compass-wrap, .ab-layer { overflow: clip; }
.ab-layer { position: absolute; inset: 0; }
.ab-layer > div:not(.ab-halo):not(.compass-star) { position: absolute; inset: 0; }
.ab-halo { position: absolute; left: 65.3846%; top: 30.7692%; width: 6.1538%; height: 6.1538%; }

.about-hero-copy { position: relative; }
.about-hero-title {
    margin-bottom: var(--s-6);
    font-size: clamp(3rem, 1rem + 7.4vw, 8.8rem);
    line-height: 0.98;
    letter-spacing: -0.02em;
    color: var(--text-strong);
    text-shadow: 0 0 48px var(--bg), 0 0 18px var(--bg);
    text-wrap: initial;
}
.about-hero-title em { color: var(--gold); font-style: italic; }
.ab-line { display: block; }
.about-hero-cj {
    font-family: var(--font-display);
    font-size: clamp(1.15rem, 1rem + 0.9vw, 1.7rem);
    letter-spacing: 0.5em;
    padding-left: 0.5em;
    color: var(--text);
    text-shadow: 0 0 24px var(--bg);
}
.ab-cue {
    position: absolute;
    left: 50%;
    bottom: clamp(18px, 3vh, 36px);
    display: grid;
    justify-items: center;
    gap: 10px;
    translate: -50% 0;
}
.ab-cue-line { width: 1px; height: 46px; background: linear-gradient(var(--gold), transparent); transform-origin: top; animation: ab-cue 2.6s var(--ease-out) infinite; }
@keyframes ab-cue { 0% { transform: scaleY(0); opacity: 1; } 70% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

/* first paint: the lines rise out of a blur, the moon draws in */
html.anim .about-hero .about-eyebrow,
html.anim .about-hero .ab-line,
html.anim .about-hero .about-hero-cj { animation: ab-rise 1.5s var(--ease-out) both; }
html.anim .about-hero .about-eyebrow { animation-delay: 0.15s; }
html.anim .about-hero .ab-line:first-child { animation-delay: 0.3s; }
html.anim .about-hero .ab-line + .ab-line { animation-delay: 0.48s; }
html.anim .about-hero .about-hero-cj { animation-delay: 0.75s; }
html.anim .moon-stage .ab-layer { animation: ab-moon-in 2.4s var(--ease-out) both; }
@keyframes ab-rise { from { opacity: 0; transform: translateY(0.45em); filter: blur(10px); } }
@keyframes ab-moon-in { from { opacity: 0; transform: scale(0.86) rotate(-14deg); } }

/* ═══ 2 · chapter I: the door, with light behind it ════════════════════════ */
.engraving {
    position: relative;
    isolation: isolate;
    justify-self: center;
    width: min(100%, 400px);
    margin: 0;
    padding: clamp(20px, 3vw, 36px);
}
/* light leaks through the door as the act scrolls past (--p from data-scene) */
.engraving-light {
    position: absolute;
    z-index: -1;
    inset: 12% 18% 22%;
    border-radius: 50%;
    background: radial-gradient(closest-side, color-mix(in srgb, var(--gold) 55%, transparent), color-mix(in srgb, var(--ember) 18%, transparent) 55%, transparent);
    filter: blur(18px);
    opacity: clamp(0.15, var(--p, 0.6) * 1.7 - 0.25, 0.95);
    scale: calc(0.7 + var(--p, 0.6) * 0.5);
    pointer-events: none;
}
/* The engravings are AI-generated copperplate plates shipped as alpha masks (design/about/PROMPTS.md):
   the mask carries the ink, the background colour is the ink colour, so they follow every theme. */
.engraving-ink {
    width: 100%;
    aspect-ratio: 3 / 4;
    background: var(--text);
    -webkit-mask-position: center;   mask-position: center;
    -webkit-mask-size: contain;      mask-size: contain;
    -webkit-mask-repeat: no-repeat;  mask-repeat: no-repeat;
}
.engraving-ink--door {
    -webkit-mask-image: url('../../images/about/door.webp?v=edda4cf1c1');
            mask-image: url('../../images/about/door.webp?v=edda4cf1c1');
}
.engraving .about-cap { margin-top: var(--s-5); text-align: center; }

/* ═══ 3 · chapter II: the fragments travel sideways ════════════════════════ */
.fragment-rail { padding-inline: var(--gutter); }
.fragment-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(16px, 2vw, 32px);
    max-width: 1200px;
    margin-inline: auto;
}
.fragment {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    aspect-ratio: 3 / 4;
    padding: var(--s-5);
    background: color-mix(in srgb, var(--bg-card) 72%, transparent);
    border: 1px solid var(--border-strong);
    transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    transition: transform 0.6s var(--ease-out), border-color var(--dur-2) var(--ease);
}
.fragment.is-tilting { transition-duration: 0.25s; }
.fragment:hover { border-color: color-mix(in srgb, var(--gold) 60%, transparent); }
/* engraved corner ticks, as on every plate */
.fragment::before, .fragment::after {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    border: 1px solid var(--gold);
    pointer-events: none;
}
.fragment::before { top: -5px; left: -5px; border-right: 0; border-bottom: 0; }
.fragment::after { right: -5px; bottom: -5px; border-left: 0; border-top: 0; }
.fragment-num {
    position: absolute;
    top: var(--s-4);
    left: var(--s-5);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.2em;
    color: var(--gold);
}
.fragment-art {
    position: absolute;
    inset: 12% 0 26%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    opacity: 0.78;
    transition: color var(--dur-3) var(--ease), opacity var(--dur-3) var(--ease);
}
.fragment:hover .fragment-art { color: var(--gold); opacity: 1; }
/* The four emblems are alpha masks like the door and the Hermit; currentColor is the plate's ink. */
.fragment-ink {
    width: 74%;
    height: 100%;
    background: currentColor;
    -webkit-mask-position: center;   mask-position: center;
    -webkit-mask-size: contain;      mask-size: contain;
    -webkit-mask-repeat: no-repeat;  mask-repeat: no-repeat;
}
.fragment-ink--sea       { -webkit-mask-image: url('../../images/about/frag-sea.webp?v=898ace116a');       mask-image: url('../../images/about/frag-sea.webp?v=898ace116a'); }
.fragment-ink--door      { -webkit-mask-image: url('../../images/about/frag-door.webp?v=e90792efe9');      mask-image: url('../../images/about/frag-door.webp?v=e90792efe9'); }
.fragment-ink--stranger  { -webkit-mask-image: url('../../images/about/frag-stranger.webp?v=2f4d616d0b');  mask-image: url('../../images/about/frag-stranger.webp?v=2f4d616d0b'); }
.fragment-ink--labyrinth { -webkit-mask-image: url('../../images/about/frag-labyrinth.webp?v=fb2e37482d'); mask-image: url('../../images/about/frag-labyrinth.webp?v=fb2e37482d'); }
.fragment h3 { position: relative; margin-bottom: var(--s-1); font-size: clamp(1.5rem, 1.1rem + 1vw, 2.1rem); letter-spacing: 0.12em; }
:lang(en) .fragment h3 { letter-spacing: -0.01em; font-style: italic; }
.fragment p {
    position: relative;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.2em;
    line-height: 1.4;
    color: var(--text-muted);
}

/* wide screens with JS: the act pins, the words hold the left third, and the four plates
   pass right to left through a window that fades at both edges. Scroll-driven sideways
   travel is exactly what reduced motion asks to avoid, so those readers get the still grid.
   Tablets held upright (700-899px wide, 900px and more tall: every iPad) get the same act.
   The phone strip's rules below still match them; the pinned rules win where they overlap,
   and the strip's top and bottom padding is reset so the act looks as it does wider. */
@media (min-width: 900px) and (prefers-reduced-motion: no-preference),
       (min-width: 700px) and (min-height: 900px) and (prefers-reduced-motion: no-preference) {
    html.atlas-js .about-frags { height: 280vh; padding-block: 0; }
    html.atlas-js .ab-pin {
        position: sticky;
        top: 0;
        display: grid;
        grid-template-columns: minmax(360px, 38vw) minmax(0, 1fr);
        align-items: center;
        height: 100vh;
        height: 100svh;
        padding-top: var(--nav-h);
        overflow: hidden;
    }
    html.atlas-js .about-frags .about-in {
        width: auto;
        margin: 0;
        padding-left: var(--gutter);
        padding-right: clamp(20px, 2.5vw, 40px);
    }
    html.atlas-js .about-frags .about-head { max-width: none; margin: 0; text-align: left; }
    html.atlas-js .about-frags .about-chapter--center { justify-content: flex-start; }
    html.atlas-js .about-frags .about-chapter--center::after { display: none; }
    html.atlas-js .about-frags .about-h2 { font-size: clamp(1.8rem, 0.5rem + 2.4vw, 3.4rem); }
    html.atlas-js .about-frags .about-body--center { margin-inline: 0; }
    /* a hairline that fills as the plates go by */
    html.atlas-js .about-frags .about-head::after {
        content: '';
        display: block;
        width: min(100%, 260px);
        height: 1px;
        margin-top: var(--s-7);
        background: linear-gradient(90deg,
            var(--gold) calc(clamp(0, (var(--p, 0) - 0.1) / 0.8, 1) * 100%),
            var(--border-strong) 0);
    }
    html.atlas-js .fragment-rail {
        container-type: inline-size;
        overflow: hidden;
        padding: 40px 0;
        -webkit-mask-image: linear-gradient(90deg, transparent, var(--bg) 7%, var(--bg) 93%, transparent);
                mask-image: linear-gradient(90deg, transparent, var(--bg) 7%, var(--bg) 93%, transparent);
    }
    html.atlas-js .fragment-strip {
        display: flex;
        align-items: flex-start;
        width: max-content;
        max-width: none;
        margin: 0;
        padding-block: 0;
        padding-inline: clamp(32px, 5vw, 80px) var(--gutter);
        gap: clamp(24px, 3vw, 56px);
        /* the strip travels its own overflow while the act holds still: the first and last
           tenth of the scroll rest, so each end can be read */
        translate: calc(clamp(0, (var(--p, 0) - 0.1) / 0.8, 1) * (62vw - 100%)) 0;
        translate: calc(clamp(0, (var(--p, 0) - 0.1) / 0.8, 1) * (100cqw - 100%)) 0;
    }
    html.atlas-js .fragment { flex: none; width: clamp(240px, min(26vw, 50vh), 420px); }
    html.atlas-js .fragment:nth-child(even) { margin-top: clamp(28px, 6vh, 72px); }
}
/* from 1100px the chapter rail (atlas.css) sits at the right edge, level with the plates:
   the window stops short of it, so the plates fade out before they reach the index */
@media (min-width: 1100px) and (prefers-reduced-motion: no-preference) {
    html.atlas-js .ab-pin { padding-right: calc(clamp(12px, 1.6vw, 28px) + 150px); }
    html.atlas-js .fragment-strip {
        translate: calc(clamp(0, (var(--p, 0) - 0.1) / 0.8, 1) * (50vw - 100%)) 0;
        translate: calc(clamp(0, (var(--p, 0) - 0.1) / 0.8, 1) * (100cqw - 100%)) 0;
    }
}
/* phones: a strip you swipe, one plate at a time */
@media (max-width: 899px) {
    .fragment-rail {
        padding-inline: 0;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }
    .fragment-rail::-webkit-scrollbar { display: none; }
    .fragment-strip { display: flex; width: max-content; max-width: none; padding: 8px var(--gutter) 12px; }
    .fragment { flex: none; width: min(66vw, 300px); scroll-snap-align: center; }
}

/* ═══ 4 · chapter III: the cards turn over ═════════════════════════════════ */
.tarot-stage {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: clamp(8px, 1.8vw, 28px);
    max-width: 1040px;
    margin: 0 auto;
    padding-bottom: var(--s-9);
    perspective: 1800px;
}
.tarot-slot { flex: 0 1 190px; --a: 0deg; --y: 0px; }
.tarot-slot--1 { --a: -9deg;   --y: 38px; }
.tarot-slot--2 { --a: -4.5deg; --y: 10px; }
.tarot-slot--3 { --a: 0deg;    --y: -22px; }
.tarot-slot--4 { --a: 4.5deg;  --y: 10px; }
.tarot-slot--5 { --a: 9deg;    --y: 38px; }
.tarot-fig {
    margin: 0;
    transform-origin: 50% 100%;
    transform: translateY(var(--y)) rotate(var(--a));
    transition: transform 1s var(--ease-out);
}
.tarot-flip {
    position: relative;
    transform-style: preserve-3d;
    transition: transform 1.2s var(--ease-out) calc(var(--i, 0) * 170ms);
}
.tarot-img {
    display: block;
    width: 100%;
    border-radius: 8px;
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-2);
    background: var(--bg-input);
    -webkit-backface-visibility: hidden;
            backface-visibility: hidden;
}
/* the back of the deck: a lattice, a ring and a star, all in the theme's gold */
.tarot-back {
    position: absolute;
    inset: 0;
    border-radius: 8px;
    border: 1px solid color-mix(in srgb, var(--gold) 60%, transparent);
    background:
        radial-gradient(circle at 50% 50%, var(--gold) 0 3px, transparent 3.5px),
        radial-gradient(circle at 50% 50%, transparent 0 21%, color-mix(in srgb, var(--gold) 60%, transparent) 21% calc(21% + 1px), transparent calc(21% + 1.5px)),
        repeating-linear-gradient(45deg, color-mix(in srgb, var(--gold) 16%, transparent) 0 1px, transparent 1px 11px),
        repeating-linear-gradient(-45deg, color-mix(in srgb, var(--gold) 16%, transparent) 0 1px, transparent 1px 11px),
        var(--bg-card);
    box-shadow: inset 0 0 0 7px var(--bg-card), inset 0 0 0 8px color-mix(in srgb, var(--gold) 45%, transparent), var(--shadow-2);
    transform: rotateY(180deg);
    -webkit-backface-visibility: hidden;
            backface-visibility: hidden;
}
.tarot-label {
    margin-top: var(--s-4);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.12em;
    line-height: 1.4;
    text-align: center;
    color: var(--text-muted);
}
.tarot-label--lead { color: var(--gold); }
.tarot-fig--lead .tarot-img {
    border-color: var(--gold);
    box-shadow: var(--shadow-2), 0 0 70px color-mix(in oklab, var(--gold) 38%, transparent);
}
/* face down until the spread is on stage, then turned one by one, the Moon last */
html.atlas-js .tarot-stage:not(.is-visible) .tarot-flip { transform: rotateY(180deg); }
html.atlas-js .tarot-stage:not(.is-visible) .tarot-fig { transform: translateY(48px) rotate(0deg); }
html.atlas-js .tarot-stage:not(.is-visible) .tarot-label { opacity: 0; }
.tarot-label { transition: opacity 0.8s var(--ease) calc(0.6s + var(--i, 0) * 170ms); }
@media (hover: hover) {
    .tarot-slot:hover .tarot-fig { transform: translateY(calc(var(--y) - 18px)) rotate(var(--a)); transition-duration: 0.45s; }
}
.tarot-cta { margin-top: var(--s-10); }
.tarot-cta-title { font-size: clamp(2rem, 1.2rem + 2.6vw, 3.6rem); font-style: italic; letter-spacing: -0.01em; }

/* ═══ 5 / 9 · steps + phone mocks ══════════════════════════════════════════ */
.about-steps { list-style: none; display: grid; gap: var(--s-5); margin-top: var(--s-8); counter-reset: none; }
.about-steps li {
    display: flex;
    gap: var(--s-4);
    align-items: flex-start;
    padding-top: var(--s-5);
    border-top: 1px solid var(--border);
    transition: opacity 0.8s var(--ease-out) calc(var(--i, 0) * 150ms), translate 0.8s var(--ease-out) calc(var(--i, 0) * 150ms);
}
html.atlas-js .about-steps:not(.is-visible) li { opacity: 0; translate: 0 16px; }
.about-step-num {
    min-width: 36px;
    padding-top: 0.35em;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.18em;
    color: var(--gold);
}
.about-step-name { font-family: var(--font-display); font-size: var(--fs-lg); letter-spacing: var(--track-cjk); color: var(--text-strong); }
.about-step-desc { font-size: var(--fs-sm); line-height: 1.8; letter-spacing: var(--track-cjk); color: var(--text-muted); }

.phone-stage { position: relative; isolation: isolate; }
.phone-stage::before {
    content: '';
    position: absolute;
    z-index: -1;
    inset: 8% 4%;
    border-radius: 50%;
    background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 32%, transparent), transparent);
    filter: blur(30px);
}
.phone {
    position: relative;
    width: min(330px, 100%);
    margin-inline: auto;
    aspect-ratio: 9 / 17.5;
    padding: 10px;
    border-radius: 46px;
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-2), 0 0 0 6px var(--border), 0 60px 90px -40px color-mix(in srgb, var(--bg) 90%, transparent);
    transform: perspective(1400px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, -8deg));
    transition: transform 0.9s var(--ease-out);
}
.about-split--flip .phone { --ry: 8deg; }
.phone.is-tilting { transition-duration: 0.3s; }
.phone-glare {
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: 46px;
    background: radial-gradient(circle at var(--gx, 30%) var(--gy, 20%), color-mix(in srgb, var(--text-strong) 18%, transparent), transparent 46%);
    mix-blend-mode: soft-light;
    pointer-events: none;
}
.phone-screen {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    border-radius: 36px;
    background: var(--bg);
    border: 1px solid var(--border);
    text-align: left;
}
.phone-screen::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 50%;
    width: 84px;
    height: 22px;
    translate: -50% 0;
    border-radius: var(--radius-pill);
    background: var(--bg-card);
    border: 1px solid var(--border);
}
.mock-top { padding: 44px var(--s-5) var(--s-3); border-bottom: 1px solid var(--border); }
.mock-brand { font-family: var(--font-display); font-size: var(--fs-lg); letter-spacing: 0.14em; color: var(--text-strong); }
.mock-body { flex: 1; min-height: 0; padding: var(--s-4) var(--s-5) 0; overflow: hidden; }
.mock-back { font-size: var(--fs-xs); color: var(--text-muted); margin-bottom: var(--s-3); }
.mock-card { display: grid; justify-items: center; gap: var(--s-2); margin: 0 0 var(--s-4); text-align: center; }
.mock-card-img {
    width: 124px;
    border-radius: 5px;
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-1);
    background: var(--bg-input);
}
.mock-card figcaption { display: grid; gap: 2px; }
.mock-label {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.16em;
    color: var(--gold);
}
.mock-card-name { font-family: var(--font-display); font-size: var(--fs-h3); line-height: 1.2; letter-spacing: var(--track-cjk); color: var(--text-strong); }
.mock-text { font-size: var(--fs-sm); line-height: 1.8; letter-spacing: 0.03em; color: var(--text); }
.mock-text + .mock-text { margin-top: var(--s-2); }
.mock-h { font-family: var(--font-display); font-size: var(--fs-lg); letter-spacing: var(--track-cjk); color: var(--text-strong); margin-bottom: var(--s-3); }
.mock-h--second { margin-top: var(--s-6); margin-bottom: var(--s-2); }
.mock-chips { list-style: none; display: flex; flex-wrap: wrap; gap: var(--s-2); }
.mock-chips .tag { padding: 6px 12px; font-size: var(--fs-sm); color: var(--text); background: transparent; border-color: var(--border-strong); }
.mock-majors { display: flex; gap: var(--s-2); margin-top: var(--s-3); }
.mock-thumb {
    width: 68px;
    border-radius: 4px;
    border: 1px solid var(--border-strong);
    background: var(--bg-input);
}
.mock-nav {
    display: flex;
    justify-content: space-around;
    padding: var(--s-3) var(--s-2) var(--s-5);
    border-top: 1px solid var(--border);
    background: var(--bg-elev);
}
.mock-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-size: var(--fs-xs);
    color: var(--text-muted);
}
.mock-nav-item svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mock-nav-item.is-on { color: var(--accent); }

/* ═══ 6 · chapter V: the compass turns as you pass ═════════════════════════ */
.compass-wrap { position: relative; width: min(720px, 100%); aspect-ratio: 1; margin: 0 auto var(--s-10); }
.compass-fn { font-family: var(--font-display); font-size: 20px; }
.compass-fn text { stroke: var(--bg); stroke-width: 8px; paint-order: stroke; stroke-linejoin: round; }
.compass-type { font-family: var(--font-mono); font-size: 11px; letter-spacing: 3px; }
.compass-dial {
    transform-origin: 50% 50%;
    transform: rotate(calc((var(--p, 0.5) - 0.5) * 150deg));
    transition: transform 0.25s linear;
}
.compass-star { position: absolute; animation: ab-twinkle 3.6s var(--ease) infinite; }
.compass-wrap > .ab-layer:nth-child(5) .compass-star { animation-delay: 0.7s; }
.compass-wrap > .ab-layer:nth-child(6) .compass-star { animation-delay: 1.4s; }
.compass-wrap > .ab-layer:nth-child(7) .compass-star { animation-delay: 2.1s; }
.compass-wrap > .ab-layer:nth-child(8) .compass-star { animation-delay: 2.8s; }
@keyframes ab-twinkle { 0%, 100% { opacity: 0.5; } 45% { opacity: 1; } }

/* ═══ 7 · chapter VI: three plates, each in its own colour ═════════════════ */
/* every .phase carries data-theme, so its tokens are that phase's palette whatever the page wears */
.triad-grid {
    display: flex;
    gap: clamp(12px, 1.6vw, 24px);
    min-height: clamp(480px, 70vh, 660px);
}
.phase {
    position: relative;
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    justify-content: flex-end;
    gap: var(--s-2);
    min-width: 0;
    padding: var(--s-7) clamp(20px, 2.4vw, 36px) clamp(24px, 3vw, 40px);
    overflow: hidden;
    color: var(--text);
    background:
        radial-gradient(120% 70% at 50% 0%, var(--glow-a), transparent 70%),
        var(--bg);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow-2);
    transition: flex-grow 0.8s var(--ease-out), opacity 0.9s var(--ease-out) calc(var(--i, 0) * 160ms), translate 0.9s var(--ease-out) calc(var(--i, 0) * 160ms);
}
html.atlas-js .triad-grid:not(.is-visible) .phase { opacity: 0; translate: 0 48px; }
@media (hover: hover) and (min-width: 901px) {
    .phase:hover { flex-grow: 1.6; }
}
.phase-num {
    position: absolute;
    top: var(--s-6);
    left: clamp(20px, 2.4vw, 36px);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: 0.2em;
    color: var(--gold);
}
.phase-symbol {
    position: absolute;
    top: 13%;
    left: 50%;
    width: min(240px, 72%);
    aspect-ratio: 1;
    translate: -50% 0;
    transition: scale 0.8s var(--ease-out);
}
.phase:hover .phase-symbol { scale: 1.06; }
/* The three birds are alpha masks like the door and the Hermit, in the panel's ink: stars -> moon -> sun. */
.phase-ink {
    width: 100%;
    height: 100%;
    background: var(--text);
    -webkit-mask-position: center;   mask-position: center;
    -webkit-mask-size: contain;      mask-size: contain;
    -webkit-mask-repeat: no-repeat;  mask-repeat: no-repeat;
}
.phase-ink--nigredo { -webkit-mask-image: url('../../images/about/triad-nigredo.webp?v=db568d4783'); mask-image: url('../../images/about/triad-nigredo.webp?v=db568d4783'); }
.phase-ink--albedo  { -webkit-mask-image: url('../../images/about/triad-albedo.webp?v=296d2ed03d');  mask-image: url('../../images/about/triad-albedo.webp?v=296d2ed03d'); }
.phase-ink--rubedo  { -webkit-mask-image: url('../../images/about/triad-rubedo.webp?v=9950b885cc');  mask-image: url('../../images/about/triad-rubedo.webp?v=9950b885cc'); }
.phase h3 { font-style: italic; font-size: clamp(2rem, 1.2rem + 1.8vw, 3.2rem); line-height: 1; color: var(--text-strong); }
.phase-cj { font-family: var(--font-display); font-size: var(--fs-lg); letter-spacing: 0.14em; color: var(--gold); }
.phase-desc { margin-top: var(--s-2); font-family: var(--font-display); line-height: 1.9; letter-spacing: var(--track-cjk); color: var(--text-muted); }
:lang(en) .phase-desc { letter-spacing: 0; line-height: 1.7; }

/* ═══ 8 · chapter VII: a lantern you carry over the Hermit ═════════════════ */
/* atlas.js moves --lx / --ly with the pointer (and sways them on touch); the defaults sit on the lantern */
.hermit-stage {
    --lx: 75%;
    --ly: 44%;
    position: relative;
    width: 100%;
    max-width: 580px;
    aspect-ratio: 1;
    justify-self: center;
}
.hermit-halo {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle clamp(120px, 22vw, 260px) at var(--lx) var(--ly), color-mix(in srgb, var(--gold) 30%, transparent), color-mix(in srgb, var(--ember) 8%, transparent) 55%, transparent);
    filter: blur(8px);
    pointer-events: none;
}
.hermit-ink, .hermit-lit {
    position: absolute;
    inset: 0;
    -webkit-mask: url('../../images/about/hermit.webp?v=6241a00690') center / 92% auto no-repeat;
            mask: url('../../images/about/hermit.webp?v=6241a00690') center / 92% auto no-repeat;
}
.hermit-ink { background: var(--text); opacity: 0.26; }
.hermit-lit {
    background: radial-gradient(circle clamp(130px, 24vw, 290px) at var(--lx) var(--ly), var(--text-strong), color-mix(in srgb, var(--gold) 70%, var(--text)) 38%, transparent 100%);
    pointer-events: none;
}

/* ═══ 10 · closing: the mark rises over a horizon ══════════════════════════ */
.about-closing {
    display: grid;
    place-items: center;
    min-height: 100vh;
    min-height: 100svh;
    overflow: clip;
}
.about-closing .about-in { position: relative; z-index: 1; }
.closing-mark {
    width: clamp(150px, 18vw, 240px);
    aspect-ratio: 1;
    margin: 0 auto var(--s-8);
    translate: 0 calc((1 - min(1, var(--p, 0.5) * 2)) * 60px);
}
.closing-title {
    font-size: clamp(4rem, 1.6rem + 9vw, 11rem);
    font-style: italic;
    letter-spacing: -0.03em;
    line-height: 0.95;
    color: var(--text-strong);
}
.closing-cj {
    margin-top: var(--s-3);
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.6rem);
    letter-spacing: 0.6em;
    padding-left: 0.6em;
    color: var(--text-strong);
}
.about-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-4); margin-top: var(--s-9); }
.about-cta-note { flex-basis: 100%; margin: 0; font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: 0.08em; color: var(--text-muted); }
.about-url { margin-top: var(--s-6); font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: 0.2em; color: var(--text-dim); }
.about-disclaimer {
    max-width: 30rem;
    margin: var(--s-10) auto 0;
    padding-top: var(--s-6);
    border-top: 1px solid var(--border);
    font-size: var(--fs-sm);
    line-height: 2;
    letter-spacing: var(--track-cjk);
    color: var(--text-dim);
}
.closing-horizon {
    position: absolute;
    inset: auto 0 0 0;
    height: 28%;
    border-top: 1px solid var(--border-strong);
    background: linear-gradient(to bottom, color-mix(in srgb, var(--bg) 70%, transparent), var(--bg) 60%);
    pointer-events: none;
}

/* ─── SVG colour hooks: illustrations follow the theme via these classes ──
   (CSS beats presentation attributes; stroke / fill inherit through <g>) */
.a-stroke-moon   { stroke: var(--moon); }
.a-stroke-lilac  { stroke: var(--lilac); }
.a-stroke-gold   { stroke: var(--gold); }
.a-stroke-dim    { stroke: var(--text-dim); }
.a-stroke-muted  { stroke: var(--text-muted); }
.a-stroke-ink    { stroke: var(--text); }
.a-stroke-strong { stroke: var(--text-strong); }
.a-stroke-border { stroke: var(--border-strong); }
.a-fill-moon     { fill: var(--moon); }
.a-fill-accent   { fill: var(--accent-strong); }
.a-fill-lilac    { fill: var(--lilac); }
.a-fill-gold     { fill: var(--gold); }
.a-fill-ember    { fill: var(--ember); }
.a-fill-ink      { fill: var(--text); }
.a-fill-muted    { fill: var(--text-muted); }
.a-fill-strong   { fill: var(--text-strong); }
.a-fill-card     { fill: var(--bg-card); }
.a-fill-bg       { fill: var(--bg); }
.stop-moon       { stop-color: var(--moon); }
.stop-gold       { stop-color: var(--gold); }

/* ─── motion: slow rings and one pulse ──────────────────────────────────── */
@keyframes about-spin   { to { transform: rotate(360deg); } }
@keyframes about-spin-r { to { transform: rotate(-360deg); } }
@keyframes about-pulse  { 0%, 100% { opacity: 0.85; } 50% { opacity: 1; } }

.spin-60, .spin-90r, .spin-slow, .spin-slower { transform-origin: 50% 50%; }
.spin-60     { animation: about-spin   120s linear infinite; }
.spin-90r    { animation: about-spin-r 180s linear infinite; }
.spin-slow   { animation: about-spin    60s linear infinite; }
.spin-slower { animation: about-spin   200s linear infinite; }
.pulse       { animation: about-pulse 4s ease-in-out infinite; }

/* ─── responsive ────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .triad-grid { flex-direction: column; min-height: 0; max-width: 460px; margin-inline: auto; }
    .phase { min-height: 440px; }
}
@media (max-width: 860px) {
    .about-split, .about-split--text, .about-split--text.about-split--flip { grid-template-columns: minmax(0, 1fr); }
    .about-split--flip > :first-child { order: 2; }
    .about-col { max-width: none; }
    .phone { --ry: 0deg; }
    .about-split--flip .phone { --ry: 0deg; }

    /* five cards become 3 + 2, still all visible */
    .tarot-stage { flex-wrap: wrap; row-gap: var(--s-7); max-width: 520px; }
    .tarot-slot { flex: 0 0 calc(33.333% - 12px); --y: 0px; }
    .tarot-slot--1 { --a: -4deg; }
    .tarot-slot--3 { --a: 0deg; --y: -10px; }
    .tarot-slot--2, .tarot-slot--4 { --a: 0deg; }
    .tarot-slot--5 { --a: 4deg; }
    .tarot-label { letter-spacing: 0.06em; }
}
@media (max-width: 600px) {
    .about-hero-title { font-size: clamp(2.8rem, 13vw, 4.4rem); }
    .moon-stage { width: 150vw; top: 44%; }
    .fragment { padding: var(--s-4); }
    .about-cta .btn { width: 100%; }
    .compass-fn { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
    .spin-60, .spin-90r, .spin-slow, .spin-slower, .pulse, .compass-star, .ab-cue-line { animation: none; }
    .moon-stage { translate: -50% -50%; scale: none; opacity: 1; }
    .compass-dial { transform: none; }
    .closing-mark { translate: none; }
    .tarot-flip, .tarot-fig, .phase, .about-steps li, .fragment { transition: none; }
}
@media print {
    .moon-stage, .closing-horizon, .ab-cue { display: none; }
    .about-act { padding-block: 32px; }
}
