/* Snatch Casino — snatchcasino-ca-1 */

:root {
    --main-color: #fecd01;
    --accent: #28d6f0;
    --highlight-active: #65e2fe;
    --bg: #04090e;
    --panel-bg: #0b1622;
    --gradient-start: #22859b;
    --grad-mid: #0d4d58;
    --foreground: #ffffff;
    --muted: #c7cdd2;
    --alert-bg: #dc2626;

    --display-font: "Poppins", "Segoe UI", system-ui, sans-serif;
    --body-font: "Inter", "Segoe UI", system-ui, sans-serif;

    --text-h1: 60px;
    --size-h2: 34px;
    --type-h3: 24px;
    --type-h4: 19px;
    --text-h5: 16px;
    --size-h6: 14px;
    --text-base: 16px;
    --text-sm: 13px;
    --size-xs: 10px;

    --leading-tight: 1.1;
    --line-normal: 1.5;
    --leading-loose: 1.65;
    --letter-tight: -0.02em;
    --ls-normal-x: 0;
    --tracking-wide: 0.06em;
    --weight-regular: 400;
    --font-medium: 600;
    --weight-bold: 800;

    --gap-2xs: 8px;
    --gap-xs: 12px;
    --gap-sm: 16px;
    --gutter-md: 24px;
    --gutter-lg: 32px;
    --gap-xl: 48px;
    --gap-2xl: 72px;
    --gutter-3xl: 112px;

    --max-width: 1300px;
    --measure: 720px;
    --inset-desktop: 32px;
    --container-inner-max-x: calc(var(--max-width) + 2 * var(--inset-desktop));

    --round-xs: 2px;
    --corner-sm: 6px;
    --radius: 10px;
    --rounded-lg: 16px;
    --round-full: 9999px;
    --circle: 50%;
    --shade-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --depth-md: 0 4px 12px rgba(0, 0, 0, 0.09);
    --depth-lg: 0 8px 24px rgba(0, 0, 0, 0.13);

    --speed-fast: 80ms;
    --speed-base: 120ms;
    --speed-slow: 180ms;
    --timing: cubic-bezier(0.5, 0, 0.5, 1);

    --header-h-x: 112px;
}

/* Reset / base */
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    padding-top: var(--header-h-x);
    background: var(--bg);
    color: var(--foreground);
    font-family: var(--body-font);
    font-size: var(--text-base);
    font-weight: var(--weight-regular);
    line-height: var(--line-normal);
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--highlight-active); }
h1, h2, h3, h4, h5, h6 { margin: 0; }
p { margin: 0 0 var(--gutter-md); }
ul, ol { margin: 0; }

h1 {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-h1);
    line-height: var(--leading-tight);
    letter-spacing: var(--letter-tight);
    text-transform: uppercase;
}
h2 {
    font-family: var(--display-font);
    font-weight: var(--font-medium);
    font-size: var(--size-h2);
    line-height: var(--leading-tight);
}
h3 {
    font-family: var(--body-font);
    font-weight: var(--font-medium);
    font-size: var(--type-h3);
    line-height: var(--line-normal);
}

/* Accessibility */
.skip-link {
    position: absolute;
    left: var(--gap-sm);
    top: -200px;
    z-index: 200;
    background: var(--accent);
    color: var(--bg);
    padding: var(--gap-2xs) var(--gap-sm);
    border-radius: var(--radius);
    font-weight: var(--weight-bold);
}
.skip-link:not(:focus) { top: -200px !important; }
.skip-link:focus { top: var(--gap-sm); }
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0);
    white-space: nowrap; border: 0;
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Shared inner wrappers — single section width (A-04) */
.tile-inner,
.veranda-inner,
.portal-inner,
.lectern-inner,
.kiosk-inner,
.mosaic-inner,
.joist-inner,
.sigil-inner,
.foyer-inner,
.dormer-inner,
.finial-inner,
.threshold-inner,
.trefoil-inner,
.reel-inner,
.slab-inner,
.pediment-inner {
    width: 100%;
    max-width: calc(var(--max-width) + 2 * var(--inset-desktop));
    margin-inline: auto;
    padding-inline: var(--inset-desktop);
}

/* Shared button */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-sm);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    border: none;
    border-radius: var(--round-full);
    padding: 0 var(--gutter-lg);
    height: 52px;
    cursor: pointer;
    background: var(--accent);
    color: var(--bg);
    transition: background var(--speed-fast) var(--timing), color var(--speed-fast) var(--timing);
}
.btn:hover { background: var(--highlight-active); color: var(--bg); }
.btn--gold-x { background: var(--main-color); color: var(--bg); }
.btn--gold-x:hover { background: #ffd633; color: var(--bg); }
.btn--lg { height: 64px; padding: 0 var(--gap-2xl); font-size: var(--text-h5); }

/* ============ HEADER (.tile — HEAD-05 minimal / NAV-01 / STICKY-01) ============ */
.tile {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(4, 9, 14, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.tile-inner {
    display: flex;
    align-items: center;
    gap: var(--gutter-lg);
    min-height: var(--header-h-x);
}
.tile-logo, .tile-logo img { flex-shrink: 0; }
.tile-logo { display: inline-flex; align-items: center; }
.tile-logo-img { height: 88px; width: auto; }
.tile-nav { margin-left: auto; }
.tile-nav-list {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: var(--gap-sm);
    list-style: none;
    margin: 0; padding: 0;
}
.tile-link {
    display: inline-block;
    font-family: var(--display-font);
    font-weight: var(--font-medium);
    font-size: var(--text-sm);
    color: var(--muted);
    white-space: nowrap;
    padding: var(--gap-2xs) var(--gap-2xs);
    border-radius: var(--corner-sm);
    transition: color var(--speed-fast) var(--timing);
}
.tile-link:hover { color: var(--accent); }
.tile-link[aria-current="page"] { color: var(--main-color); }
.tile-toggle {
    display: none;
    margin-left: auto;
    width: 48px; height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius);
    background: transparent;
    color: var(--foreground);
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}
.tile-toggle span {
    display: block;
    width: 22px; height: 2px;
    background: var(--foreground);
    border-radius: 2px;
}
/* Mobile drawer */
.tile-drawer {
    display: none;
    position: fixed;
    inset: var(--header-h-x) 0 0 0;
    background: var(--bg);
    z-index: 99;
    padding: var(--gutter-lg) var(--gutter-md) var(--gap-2xl);
    overflow-y: auto;
}
.tile-drawer.is-open { display: block; }
.tile-drawer-list { list-style: none; margin: 0; padding: 0; }
.tile-drawer-list li { border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.tile-drawer-link {
    display: block;
    padding: var(--gutter-md) var(--gap-2xs);
    font-family: var(--display-font);
    font-weight: var(--font-medium);
    font-size: var(--type-h4);
    color: var(--foreground);
}
.tile-drawer-link:hover { color: var(--accent); }
.tile-drawer-link[aria-current="page"] { color: var(--main-color); }

/* ============ HERO (.portal — HERO-06 asymmetric tilted) ============ */
.portal { position: relative; overflow: hidden; background: var(--bg); }
.portal-inner { position: relative; min-height: 640px; display: flex; align-items: center; }
.portal-content {
    position: relative;
    z-index: 2;
    width: 52%;
    padding-block: var(--gap-xl);
}
.portal-eyebrow {
    display: inline-block;
    font-family: var(--body-font);
    font-weight: var(--font-medium);
    font-size: var(--size-h6);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--accent);
    margin-bottom: var(--gap-sm);
}
.portal-content h1 { color: var(--foreground); margin-bottom: var(--gutter-md); }
.portal-subtitle {
    font-size: var(--text-h5);
    line-height: var(--line-normal);
    color: var(--muted);
    max-width: 540px;
    margin-bottom: var(--gutter-lg);
}
.portal-figure {
    position: absolute;
    right: 0; top: -40px;
    width: 56%;
    height: calc(100% + 80px);
    overflow: visible;
    transform: rotate(2deg);
    border-radius: var(--rounded-lg);
    box-shadow: var(--depth-lg);
    z-index: 1;
    margin: 0;
}
.portal-figure img {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: var(--rounded-lg);
}

/* ============ PAGE HEADER (.lectern — PHEAD-06 editorial) ============ */
.lectern { padding-block: var(--gap-xl); background: var(--bg); }
.lectern h1 { color: var(--foreground); font-weight: var(--weight-bold); }
.lectern-rule {
    width: 40px; height: 1px;
    background: rgba(255, 255, 255, 0.2);
    border: 0;
    margin: var(--gutter-md) 0;
}
.lectern-desc {
    font-family: var(--body-font);
    font-style: italic;
    font-size: var(--text-h5);
    color: var(--muted);
    max-width: 640px;
    margin: 0;
}

/* ============ PROSE (.foyer — PROSE-06 centered quiet) ============ */
.foyer { padding-block: var(--gap-xl); }
.foyer-inner { text-align: center; }
.foyer-body { max-width: 820px; margin-inline: auto; }
.foyer-body h2 {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--type-h3);
    color: var(--foreground);
    margin-top: var(--gap-2xl);
    margin-bottom: var(--gutter-md);
}
.foyer-body h2:first-child { margin-top: 0; }
.foyer-body p {
    font-size: var(--text-base);
    line-height: var(--leading-loose);
    color: var(--muted);
    margin-bottom: var(--gutter-md);
}
.foyer-body ul, .foyer-body ol {
    text-align: left;
    display: inline-block;
    color: var(--muted);
    line-height: var(--leading-loose);
    margin: 0 0 var(--gutter-md);
    padding-left: var(--gutter-lg);
}
.foyer-body li { margin-bottom: var(--gap-2xs); }
.foyer-body a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.foyer-body a:hover { color: var(--highlight-active); text-decoration-thickness: 2px; }
.foyer-body strong { color: var(--foreground); font-weight: var(--weight-bold); }

/* ============ ITEMS GRID (.kiosk — GRID-02 numbered strip) ============ */
.kiosk { padding-block: var(--gap-xl); }
.kiosk-head { text-align: center; margin-bottom: var(--gap-xl); }
.kiosk-head h2 { color: var(--foreground); }
.kiosk-list { list-style: none; margin: 0; padding: 0; }
.kiosk-item {
    display: flex;
    gap: var(--gutter-lg);
    padding-block: var(--gap-xl);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.kiosk-item:first-child { border-top: none; }
.kiosk-num {
    flex-shrink: 0;
    width: 80px;
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-h1);
    line-height: 1;
    letter-spacing: var(--letter-tight);
    color: var(--accent);
    transition: transform var(--speed-base) var(--timing);
}
.kiosk-item:hover .kiosk-num { transform: scale(1.1); }
.kiosk-body { flex: 1; }
.kiosk-title {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--type-h3);
    color: var(--foreground);
    margin-bottom: var(--gap-xs);
}
.kiosk-text {
    font-size: var(--text-base);
    line-height: var(--leading-loose);
    color: var(--muted);
    max-width: 640px;
    margin: 0;
}

/* ============ DATA TABLE (.dormer — TABLE-01 striped) ============ */
.dormer { padding-block: var(--gap-xl); }
.dormer-head { text-align: center; margin-bottom: var(--gap-xl); }
.dormer-head h2 { color: var(--foreground); }
.dormer-scroll {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.dormer-table {
    width: 100%;
    min-width: 520px;
    border-collapse: collapse;
    background: var(--panel-bg);
}
.dormer-table thead { background: var(--main-color); }
.dormer-table th {
    font-family: var(--body-font);
    font-weight: var(--font-medium);
    text-transform: uppercase;
    font-size: var(--size-h6);
    letter-spacing: var(--tracking-wide);
    color: var(--bg);
    padding: var(--gutter-md);
    text-align: left;
}
.dormer-table td {
    padding: var(--gutter-md);
    font-size: var(--text-base);
    color: var(--muted);
    text-align: left;
}
.dormer-table td:first-child { color: var(--foreground); font-weight: var(--font-medium); }
.dormer-table tbody tr:nth-child(even) { background: rgba(255, 255, 255, 0.02); }
.dormer-table tbody tr:hover { background: rgba(255, 255, 255, 0.04); }

/* ============ REVIEWS (.joist — REV-06 compact list) ============ */
.joist { padding-block: var(--gap-xl); }
.joist-head { text-align: center; margin-bottom: var(--gap-xl); }
.joist-head h2 { color: var(--foreground); }
.joist-list { list-style: none; margin: 0; padding: 0; max-width: 820px; margin-inline: auto; }
.joist-item {
    padding-block: var(--gutter-md);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.joist-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: var(--gap-sm);
    margin-bottom: var(--gap-2xs);
}
.joist-author { font-size: var(--text-base); font-weight: var(--weight-bold); color: var(--foreground); }
.joist-rating { font-size: var(--text-sm); font-weight: var(--weight-bold); color: var(--accent); white-space: nowrap; }
.joist-text { font-size: var(--text-base); line-height: var(--line-normal); color: var(--muted); margin: 0; }

/* ============ FAQ (.mosaic — FAQ-02 always-open) ============ */
.mosaic { padding-block: var(--gap-xl); }
.mosaic-head { text-align: center; margin-bottom: var(--gap-xl); }
.mosaic-head h2 { color: var(--foreground); }
.mosaic-list { max-width: 820px; margin: 0 auto; }
.mosaic-question {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--type-h4);
    color: var(--foreground);
    margin-bottom: var(--gap-sm);
}
.mosaic-answer {
    margin: 0 0 var(--gap-xl);
    font-size: var(--text-base);
    line-height: var(--leading-loose);
    color: var(--muted);
}
.mosaic-answer p { margin: 0; }

/* ============ CTA BLOCK (.sigil — CTA-08 inverted block) ============ */
.sigil {
    padding-block: var(--gap-xl);
    background: linear-gradient(135deg, var(--grad-mid), var(--gradient-start));
}
.sigil-inner { text-align: center; display: flex; flex-direction: column; align-items: center; }
.sigil-title {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-h1);
    text-transform: uppercase;
    letter-spacing: var(--letter-tight);
    line-height: var(--leading-tight);
    color: var(--foreground);
    margin-bottom: var(--gutter-md);
}
.sigil-text {
    font-size: var(--text-h5);
    line-height: var(--line-normal);
    color: rgba(255, 255, 255, 0.85);
    max-width: 620px;
    margin-bottom: var(--gap-xl);
}

/* ============ INLINE CTA (.pediment — INLINE-CTA-01 band) ============ */
.pediment { background: var(--main-color); padding-block: var(--gutter-md); }
.pediment-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--gutter-md);
}
.pediment-text {
    font-family: var(--display-font);
    font-size: var(--text-h5);
    font-weight: var(--weight-bold);
    color: var(--bg);
    margin: 0;
}
.pediment-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--gap-sm) var(--gutter-lg);
    border-radius: var(--round-full);
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-sm);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    background: var(--bg);
    color: var(--accent);
    transition: background var(--speed-fast) var(--timing), color var(--speed-fast) var(--timing);
}
.pediment-btn:hover { background: var(--accent); color: var(--bg); }

/* ============ CONTENT FIGURES (per-page images) ============ */
.figure-band { padding-block: var(--gap-xl); }
.figure-context {
    max-width: var(--container-inner-max-x);
    margin-inline: auto;
    padding-inline: var(--inset-desktop);
}
.figure-context img { width: 100%; border-radius: var(--rounded-lg); box-shadow: var(--depth-md); }
.figure-row {
    max-width: var(--container-inner-max-x);
    margin-inline: auto;
    padding-inline: var(--inset-desktop);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--gutter-lg);
}
.figure-row figure { margin: 0; }
.figure-row img { width: 100%; border-radius: var(--radius); box-shadow: var(--shade-sm); }
.figure-cap { font-size: var(--text-sm); color: var(--muted); margin-top: var(--gap-2xs); text-align: center; }

/* ============ AUTHOR BYLINE (.reel — BYLINE-04 quote style) ============ */
.reel { padding-block: var(--gap-xl); }
.reel-quote {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    padding-top: var(--gutter-lg);
}
.reel-quote::before {
    content: "\201C";
    display: block;
    font-family: var(--display-font);
    font-size: var(--text-h1);
    line-height: 0.6;
    color: var(--accent);
}
.reel-quote > p {
    font-family: var(--display-font);
    font-style: italic;
    font-size: var(--type-h4);
    color: var(--foreground);
    margin: var(--gap-sm) 0 var(--gutter-md);
}
.reel-attribution {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--gap-xs);
}
.reel-portrait {
    width: 32px; height: 32px;
    border-radius: var(--circle);
    object-fit: cover;
    object-position: center 20%;
    background: var(--bg);
    border: 2px solid var(--bg);
    box-sizing: content-box;
}
.reel-name { font-style: normal; }
.reel-name a { color: var(--accent); font-weight: var(--weight-bold); }
.reel-role { font-size: var(--text-sm); font-style: italic; color: var(--muted); }

/* ============ AUTHOR CARD (.trefoil — AUTH-02 vertical centered) ============ */
.trefoil { padding-block: var(--gap-xl); }
.trefoil-card { max-width: 600px; margin-inline: auto; text-align: center; }
.trefoil-portrait {
    width: 140px; height: 140px;
    border-radius: var(--circle);
    object-fit: cover;
    object-position: center 20%;
    background: var(--bg);
    border: 3px solid var(--bg);
    box-sizing: content-box;
    margin: 0 auto var(--gutter-lg);
}
.trefoil-role {
    font-size: var(--text-sm);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--accent);
    margin-bottom: var(--gap-2xs);
}
.trefoil-name { font-size: var(--size-h2); color: var(--foreground); margin-bottom: var(--gutter-md); }
.trefoil-bio { line-height: var(--leading-loose); color: var(--muted); margin-bottom: var(--gutter-md); }
.trefoil-tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--gap-2xs);
    padding: 0; margin: 0;
}
.trefoil-tags span {
    display: inline-block;
    padding: var(--gap-2xs) var(--gap-sm);
    background: var(--main-color);
    color: var(--bg);
    border-radius: var(--round-full);
    font-size: var(--size-xs);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    font-weight: var(--font-medium);
}
.trefoil-articles { max-width: 600px; margin: var(--gap-2xl) auto 0; padding-block: var(--gutter-lg); }
.trefoil-articles-heading {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--type-h4);
    color: var(--foreground);
    margin-bottom: var(--gutter-md);
    text-align: center;
}
.trefoil-articles-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: var(--gap-xs);
    padding: 0; margin: 0;
    text-align: center;
}
.trefoil-articles-item { font-size: var(--text-base); line-height: var(--line-normal); }
.trefoil-articles-item a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.trefoil-articles-item a:hover { color: var(--highlight-active); }

/* ============ LEGAL (.finial — LEGAL-01 continuous doc) ============ */
.finial { padding-block: var(--gap-xl); }
.finial-doc { max-width: 800px; margin-inline: auto; }
.finial-doc h1 { color: var(--foreground); font-weight: var(--weight-bold); margin-bottom: var(--gutter-lg); }
.finial-intro {
    font-size: var(--text-h5);
    line-height: var(--line-normal);
    color: var(--foreground);
    margin-bottom: var(--gutter-lg);
}
.finial-section { padding-block-start: var(--gap-xl); border-block-start: 1px solid rgba(255, 255, 255, 0.06); }
.finial-section:first-of-type { border-block-start: none; padding-block-start: 0; }
.finial-section h2 {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--type-h3);
    color: var(--foreground);
    margin-bottom: var(--gutter-md);
}
.finial-section p { font-size: var(--text-base); line-height: var(--leading-loose); color: var(--muted); margin-bottom: var(--gutter-md); }
.finial-contacts {
    background: var(--panel-bg);
    padding: var(--gutter-lg);
    border-radius: var(--radius);
    margin-block-start: var(--gap-xl);
}
.finial-contacts h2 { font-family: var(--display-font); font-weight: var(--weight-bold); font-size: var(--type-h4); color: var(--foreground); margin-bottom: var(--gutter-md); }
.finial-contacts ul { list-style: none; padding: 0; margin: 0; }
.finial-contacts li { color: var(--muted); line-height: var(--line-normal); margin-bottom: var(--gap-xs); }
.finial-disclaimer {
    padding: var(--gutter-md);
    background: rgba(220, 38, 38, 0.08);
    border-left: 3px solid var(--alert-bg);
    border-radius: var(--round-xs);
    font-size: var(--text-sm);
    color: var(--muted);
    margin-block-start: var(--gap-xl);
}

/* ============ CONTACT FORM (.threshold — FORM-06 floating labels) ============ */
.threshold { padding-block: var(--gap-xl); }
.threshold-inner { }
.threshold-wrap { max-width: 620px; margin-inline: auto; }
.threshold-intro { font-size: var(--text-base); line-height: var(--leading-loose); color: var(--muted); margin-bottom: var(--gutter-lg); }
.threshold-success {
    display: none;
    padding: var(--gutter-md);
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: var(--radius);
    color: var(--foreground);
    margin-bottom: var(--gutter-lg);
}
.threshold-success.is-visible { display: block; }
.threshold-form { display: flex; flex-direction: column; gap: var(--gutter-md); }
.threshold-field { position: relative; }
.threshold-input, .threshold-textarea {
    width: 100%;
    font-family: var(--body-font);
    font-size: var(--text-base);
    color: var(--foreground);
    background: var(--bg);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius);
    padding: var(--gutter-lg) var(--gutter-md) var(--gap-2xs);
}
.threshold-input { height: 60px; }
.threshold-textarea { min-height: 140px; resize: vertical; padding-top: var(--gutter-lg); }
.threshold-input:focus, .threshold-textarea:focus { outline: none; border-color: var(--accent); }
.threshold-label {
    position: absolute;
    top: 50%; left: var(--gutter-md);
    transform: translateY(-50%);
    color: var(--muted);
    pointer-events: none;
    transition: top var(--speed-slow) var(--timing), font-size var(--speed-slow) var(--timing), color var(--speed-slow) var(--timing);
}
.threshold-textarea + .threshold-label { top: var(--gutter-lg); }
.threshold-input:focus + .threshold-label,
.threshold-input:not(:placeholder-shown) + .threshold-label,
.threshold-textarea:focus + .threshold-label,
.threshold-textarea:not(:placeholder-shown) + .threshold-label {
    top: var(--gap-2xs);
    transform: translateY(0);
    font-size: var(--size-xs);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--accent);
}
.threshold-submit {
    align-self: flex-start;
    border: none;
    height: 52px;
    padding-inline: var(--gap-xl);
    background: var(--accent);
    color: var(--bg);
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    border-radius: var(--round-full);
    cursor: pointer;
    transition: background var(--speed-fast) var(--timing), color var(--speed-fast) var(--timing);
}
.threshold-submit:hover { background: var(--highlight-active); color: var(--bg); }

/* ============ ERROR (.slab — ERR-07 geometric pattern) ============ */
.slab {
    padding-block: var(--gap-xl);
    background-color: var(--bg);
    background-image:
        linear-gradient(rgba(40, 214, 240, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(40, 214, 240, 0.06) 1px, transparent 1px);
    background-size: 40px 40px;
}
.slab-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--gutter-lg); }
.slab-code {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: clamp(80px, 18vw, 200px);
    line-height: var(--leading-tight);
    color: var(--accent);
}
.slab h1 { color: var(--foreground); max-width: 720px; }
.slab-text { font-size: var(--text-h5); line-height: var(--line-normal); color: var(--muted); max-width: 600px; }

/* ============ COOKIE (.window — COOK-03 corner card) ============ */
.window {
    display: none;
    position: fixed;
    inset-block-end: var(--gutter-md);
    inset-inline-end: var(--gutter-md);
    max-width: 360px;
    z-index: 90;
    background: var(--panel-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--rounded-lg);
    padding: var(--gutter-lg);
    box-shadow: var(--depth-lg);
    flex-direction: column;
    gap: var(--gutter-md);
}
.window.is-visible { display: flex; }
.window-title {
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--text-h5);
    text-transform: uppercase;
    color: var(--accent);
}
.window-message { font-size: var(--text-sm); line-height: var(--line-normal); color: var(--muted); margin: 0; }
.window-actions { display: flex; gap: var(--gap-sm); }
.window-button {
    flex: 1;
    height: 40px;
    border: none;
    border-radius: var(--radius);
    font-family: var(--display-font);
    font-weight: var(--weight-bold);
    font-size: var(--size-xs);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    cursor: pointer;
    transition: background var(--speed-fast) var(--timing), color var(--speed-fast) var(--timing);
}
.window-button--accept-x { background: var(--accent); color: var(--bg); }
.window-button--accept-x:hover { background: var(--highlight-active); color: var(--bg); }
.window-button--decline-x { background: transparent; border: 1px solid rgba(255, 255, 255, 0.15); color: var(--foreground); }
.window-button--decline-x:hover { background: rgba(255, 255, 255, 0.04); color: var(--foreground); }

/* ============ FOOTER (.veranda — FOOT-04 compact) ============ */
.veranda {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: var(--bg);
    padding-block: var(--gap-xl);
}
.veranda-inner { display: flex; flex-wrap: wrap; align-items: flex-start; gap: var(--gutter-lg) var(--gap-2xl); }
.veranda-brand { flex: 1 1 260px; }
.veranda-logo-img { height: 56px; width: auto; margin-bottom: var(--gap-sm); }
.veranda-copy { display: block; font-size: var(--size-xs); text-transform: uppercase; letter-spacing: var(--tracking-wide); color: var(--muted); }
.veranda-disclaimer { font-size: var(--text-sm); color: var(--muted); margin: var(--gap-xs) 0 0; max-width: 420px; }
.veranda-col { flex: 0 0 auto; }
.veranda-heading {
    font-family: var(--body-font);
    font-weight: var(--font-medium);
    font-size: var(--size-h6);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--foreground);
    margin-bottom: var(--gap-sm);
}
.veranda-nav { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--gap-2xs); }
.veranda-nav a { font-size: var(--text-sm); color: var(--muted); }
.veranda-nav a:hover { color: var(--accent); }

/* ============ RESPONSIVE ============ */
@media (max-width: 1099px) {
    .tile-nav { display: none; }
    .tile-toggle { display: flex; }
    .portal-content { width: 100%; }
    .portal-figure {
        position: relative;
        right: auto; top: auto;
        width: 100%;
        height: auto;
        transform: none;
        margin-top: var(--gutter-lg);
    }
    .portal-inner { flex-direction: column; align-items: stretch; min-height: 0; }
    .portal-figure img { height: auto; }
}

@media (max-width: 799px) {
    :root {
        --text-h1: 36px;
        --size-h2: 26px;
        --type-h3: 20px;
        --type-h4: 17px;
        --text-h5: 14px;
        --size-h6: 12px;
        --text-base: 15px;
        --text-sm: 12px;
        --size-xs: 9px;
        --header-h-x: 76px;
        --inset-desktop: 16px;
    }
    .tile-logo-img { height: 60px; }
    .tile-drawer { inset-top: var(--header-h-x); }
    .section { padding-block: var(--gap-xl); }
    .kiosk-item { gap: var(--gutter-md); }
    .kiosk-num { width: 56px; }
    .sigil { padding-block: var(--gap-xl); }
    .pediment-inner { flex-direction: column; align-items: stretch; text-align: center; }
    .pediment-btn { width: 100%; }
    .joist-top { flex-direction: column; gap: 2px; }
    .window {
        inset-inline: var(--gutter-md);
        max-width: none;
        width: calc(100vw - 2 * var(--gutter-md));
    }
}
