/* Zombicon site: "The Notice Wall".
   Tokens from projects/zombicon/DESIGN.md (ui/theme/ZombiconColors): Night = dark scheme (ground, card,
   raised, hairline, chalk/chalk-mid/chalk-low, flare + on-flare, moss, tape + on-tape, tape-text) and
   Dawn = light scheme (dawn-ground … dawn-tape-text). The hero and closing band stay Night in both
   schemes (the app is dark first and every store shot is Night). One Flare Rule: flare marks actions
   and "yours" only; moss = worked, tape = be careful, never colour alone.
   Type: Stardos Stencil Bold (SIL OFL, Reserved Font Names "Stardos" and "Stardos Stencil"), subset and
   renamed "Zombicon Stencil", for display only; body is the system sans; codes the system monospace. */

@font-face {
    font-family: "Zombicon Stencil";
    src: url("/zombicon/fonts/zombicon-stencil-700.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: light dark;
    /* Dawn (light) */
    --ground: #F3EEE4;
    --card: #FBF8F1;
    --raised: #E9E2D4;
    --hairline: #CFC6B5;
    --ink: #1F1A16;
    --ink-mid: #5C5347;
    --ink-low: #6B6254;
    --flare: #B8330C;
    --on-flare: #FFF4EC;
    --moss: #2F6B24;
    --tape-text: #7A5C00;
    /* Tape fill is the same in both schemes */
    --tape: #F5C400;
    --on-tape: #1E1700;
    /* Night band (hero, closing band) in both schemes */
    --night: #14110F;
    --night-card: #1D1916;
    --night-line: #3A332D;
    --chalk: #EFE8DA;
    --chalk-mid: #BDB4A4;
    --night-flare: #FF6A3D;
    --night-on-flare: #1A0A04;
    --display: "Zombicon Stencil", Georgia, serif;
    --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    --wrap: 70rem;
    --notice: 14px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --ground: #14110F;
        --card: #1D1916;
        --raised: #26211D;
        --hairline: #3A332D;
        --ink: #EFE8DA;
        --ink-mid: #BDB4A4;
        --ink-low: #948C7E;
        --flare: #FF6A3D;
        --on-flare: #1A0A04;
        --moss: #9BD18A;
        --tape-text: #F5C400;
    }
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--ground);
    color: var(--ink);
    font-family: var(--font);
    font-size: 1.0625rem;
    line-height: 1.6;
    overflow-wrap: break-word;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}

a:hover {
    text-decoration-thickness: 2px;
}

:focus-visible {
    outline: 3px solid var(--flare);
    outline-offset: 3px;
    border-radius: 4px;
}

h1,
h2 {
    font-family: var(--display);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: 0.02em;
    margin: 0 0 0.6em;
    text-wrap: balance;
    hyphens: none;
}

h1 {
    font-size: clamp(2.1rem, 6vw, 3.4rem);
}

h2 {
    font-size: clamp(1.5rem, 3.4vw, 2.1rem);
}

h3 {
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 0.4em;
    hyphens: none;
}

p {
    margin: 0 0 1em;
}

code {
    font-family: var(--mono);
    font-size: 0.92em;
    letter-spacing: 0.04em;
    background: var(--raised);
    border-radius: 4px;
    padding: 0.05em 0.3em;
}

.wrap {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 1.25rem;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -4rem;
    z-index: 10;
    background: var(--flare);
    color: var(--on-flare);
    font-weight: 600;
    padding: 0.75rem 1rem;
    border-radius: 999px;
    text-decoration: none;
}

.skip-link:focus {
    top: 1rem;
    outline-color: var(--ink);
}

/* Header */
.topbar {
    background: var(--ground);
    border-bottom: 1px solid var(--hairline);
}

.topbar .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1.5rem;
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    min-height: 48px;
    text-decoration: none;
    font-family: var(--display);
    font-weight: 700;
    font-size: 1.45rem;
    letter-spacing: 0.02em;
}

.brand img {
    border-radius: 10px;
}

.site-nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 48px;
    padding: 0 0.85rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 999px;
}

.site-nav a:hover {
    background: var(--raised);
}

.site-nav a[aria-current="page"] {
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 0.35em;
}

/* Night band: hero and closing band, dark in both schemes */
.night {
    background: var(--night);
    color: var(--chalk);
}

.night :focus-visible {
    outline-color: var(--night-flare);
}

.hero {
    padding: 3rem 0 3.5rem;
}

.hero-grid {
    display: grid;
    gap: 2.5rem;
    align-items: center;
}

.hero h1 {
    max-width: 15ch;
}

.hero .sub {
    font-size: 1.2rem;
    color: var(--chalk-mid);
    max-width: 34rem;
}

.cta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 1.5rem;
    margin-top: 1.5rem;
}

.cta-row p {
    margin: 0;
    color: var(--chalk-mid);
    font-size: 0.97rem;
    max-width: 24rem;
}

.play-badge {
    display: inline-block;
    border-radius: 8px;
    flex: none;
}

.play-badge img {
    width: 188px;
    height: 56px;
}

.hero-shot {
    justify-self: center;
    width: min(100%, 22rem);
}

/* Framed store shots (soot canvas): a 1 px hairline so the frame never floats on Dawn paper. */
.shot img,
.hero-shot img {
    border: 1px solid var(--hairline);
    border-radius: var(--notice);
}

.night .hero-shot img {
    border-color: var(--night-line);
}

/* Sections */
.section {
    padding: 3.5rem 0;
    border-top: 1px solid var(--hairline);
}

.section.lead {
    border-top: 0;
    padding-bottom: 1rem;
}

.answer {
    font-size: 1.15rem;
    max-width: 44rem;
}

.lead .answer {
    font-size: 1.3rem;
    font-weight: 600;
    line-height: 1.5;
    max-width: 50rem;
}

.detail {
    color: var(--ink-mid);
    max-width: 44rem;
}

.split {
    display: grid;
    gap: 2.5rem;
    align-items: start;
}

.shot {
    margin: 0;
}

.shot-narrow {
    width: min(100%, 18rem);
    justify-self: center;
}

.shot figcaption {
    color: var(--ink-mid);
    font-size: 0.92rem;
    margin-top: 0.6rem;
}

/* Feature notices: cards like the app's notices */
.notices {
    list-style: none;
    margin: 1.5rem 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
}

.notices li {
    background: var(--card);
    color: var(--ink);
    border: 1px solid var(--hairline);
    border-radius: var(--notice);
    padding: 1.1rem 1.2rem;
    min-width: 0;
}

.notices p {
    margin: 0;
    color: var(--ink-mid);
}

/* Delivery states: each carries a word and a mark, never colour alone */
.states {
    list-style: none;
    margin: 1.25rem 0 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.states li {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--raised);
    color: var(--ink);
    border-radius: 999px;
    padding: 0.25rem 0.8rem;
    font-size: 0.92rem;
    font-weight: 600;
}

.states svg {
    width: 1rem;
    height: 1rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.states .ok {
    color: var(--moss);
}

.states .warn {
    color: var(--tape-text);
}

/* Caution band: tape fill, on-tape ink, in both schemes */
.caution {
    background: var(--tape);
    color: var(--on-tape);
    border-radius: var(--notice);
    padding: 1.5rem 1.4rem;
    max-width: 52rem;
}

.caution :focus-visible {
    outline-color: var(--on-tape);
}

.caution h2 {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.caution h2 svg {
    flex: none;
    width: 1.6rem;
    height: 1.6rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.caution ul {
    margin: 0 0 1rem;
    padding-left: 1.2rem;
}

.caution li {
    margin-bottom: 0.4rem;
}

.caution p {
    margin: 0;
    font-weight: 600;
}

.caution a {
    display: inline-block;
    padding: 0.6rem 0;
}

/* Fact lists */
.facts {
    display: grid;
    gap: 0.75rem;
    margin: 1.5rem 0 0;
    max-width: 44rem;
}

.facts > div {
    background: var(--card);
    color: var(--ink);
    border: 1px solid var(--hairline);
    border-radius: var(--notice);
    padding: 0.9rem 1rem;
}

.facts dt {
    font-weight: 700;
}

.facts dd {
    margin: 0.2rem 0 0;
    color: var(--ink-mid);
}

/* "What it doesn't do" and limit lists */
.nots,
.limits {
    list-style: none;
    margin: 1rem 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
    max-width: 48rem;
}

.nots li,
.limits li {
    display: grid;
    grid-template-columns: 1.4rem minmax(0, 1fr);
    gap: 0.75rem;
    align-items: start;
}

.nots span,
.limits span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.nots svg,
.limits svg {
    width: 1.4rem;
    height: 1.4rem;
    margin-top: 0.15rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Gallery */
.gallery {
    list-style: none;
    margin: 1.5rem 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr));
    gap: 1.25rem;
}

.gallery .shot {
    max-width: 20rem;
    margin: 0 auto;
}

/* Question links */
.qlinks {
    list-style: none;
    margin: 1rem 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.5rem;
    max-width: 44rem;
}

.qlinks a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    min-height: 48px;
    padding: 0.6rem 1rem;
    background: var(--card);
    color: var(--ink);
    border: 1px solid var(--hairline);
    border-radius: var(--notice);
    font-weight: 600;
    text-decoration: none;
}

.qlinks span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.qlinks a:hover {
    border-color: var(--ink-low);
}

.qlinks svg {
    flex: none;
    width: 1.2rem;
    height: 1.2rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Closing band */
.night-end {
    padding: 3.5rem 0;
    text-align: center;
}

.night-end h2 {
    margin-bottom: 1.25rem;
}

.night-end .play-badge {
    margin: 0 auto;
}

/* Inner pages */
.page-head {
    padding: 2rem 0 1.5rem;
    border-bottom: 1px solid var(--hairline);
}

.crumbs ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 0 0 1rem;
    padding: 0;
    font-size: 0.92rem;
    color: var(--ink-mid);
}

.crumbs li + li::before {
    content: "\203A";
    padding: 0 0.5rem;
}

.crumbs a {
    display: inline-block;
    padding: 0.7rem 0;
}

.crumbs li[aria-current] {
    padding: 0.7rem 0;
}

.toc ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    margin: 1rem 0 0;
    padding: 0;
}

.toc a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0.25rem 0.9rem;
    border: 1px solid var(--hairline);
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
}

.toc a:hover {
    background: var(--raised);
}

.steps > section,
.ledger > section {
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--hairline);
}

.steps > section:last-child,
.ledger > section:last-child {
    border-bottom: 0;
}

.steps h2,
.ledger h2 {
    scroll-margin-top: 1rem;
}

.ledger h2 {
    font-size: clamp(1.3rem, 2.6vw, 1.65rem);
}

.step-no {
    display: block;
    font-family: var(--font);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-mid);
    margin-bottom: 0.4rem;
}

.page-end {
    padding: 2.5rem 0 3.5rem;
    border-top: 1px solid var(--hairline);
}

.page-end .play-badge {
    margin-top: 0.5rem;
}

/* Footer */
.footer {
    background: var(--card);
    color: var(--ink);
    border-top: 1px solid var(--hairline);
    padding: 2.5rem 0 3rem;
    font-size: 0.95rem;
}

.footer-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.footer-top p {
    margin: 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0 1.25rem;
    list-style: none;
    margin: 0 0 1rem;
    padding: 0;
}

.footer-links a {
    display: inline-flex;
    align-items: center;
    min-height: 48px;
    overflow-wrap: anywhere;
}

.fine {
    color: var(--ink-mid);
    font-size: 0.88rem;
}

.fine p {
    margin: 0 0 0.4rem;
    max-width: 52rem;
}

@media (min-width: 40rem) {
    .facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .notices {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 60rem) {
    .hero-grid {
        grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    }
    .split {
        grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    }
}

@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}
