/* ==============================================================
   LEON CWIERTNIA — WERKSTATT
   A shop floor, not a brochure.

   Identity rules (locked — do not drift):
     · radius 0 everywhere. no soft shadows. no glassmorphism.
     · palette capped: graphite / painted white / safety yellow / oxide red.
       one LED green for "running". nothing else.
     · monospace is the dominant voice. sans is a supporting player.
     · display type is Archivo at extreme condensed width = painted signage.
     · structure stays exposed: hairlines, ticks, screws, part numbers.
     · motion is mechanical — steps(), not smooth fades.
     · texture is real (grain overlay). generated pages never have grain.
   ============================================================== */

/* ==============================================================
   Self-hosted fonts (no third-party requests — GDPR)
   ============================================================== */
@font-face {
    font-family: 'Archivo';
    font-style: normal;
    font-weight: 100 900;
    font-stretch: 62% 125%;
    font-display: swap;
    src: url('../fonts/archivo-var.woff2') format('woff2');
}

@font-face {
    font-family: 'IBM Plex Sans';
    font-style: normal;
    font-weight: 400 600;
    font-display: swap;
    src: url('../fonts/plex-sans-var.woff2') format('woff2');
}

@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/plex-mono-400.woff2') format('woff2');
}

@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/plex-mono-500.woff2') format('woff2');
}

@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/plex-mono-600.woff2') format('woff2');
}

/* ==============================================================
   Tokens
   ============================================================== */
:root {
    /* graphite — neutral, anodised. deliberately not blue-black. */
    --steel-0: #0a0a0b;
    --steel-1: #0f0f11;
    --steel-2: #151518;
    --steel-3: #1c1c20;
    --steel-4: #24242a;

    --rule: #2c2c33;
    --rule-dim: #1e1e23;
    --rule-bright: #3d3d45;

    /* painted metal white, slightly warm — not #fff */
    --paint: #e8e5df;
    --paint-2: #a3a099;
    --paint-3: #6d6a64;

    /* DIN 4844 safety yellow. the signal colour. */
    --hazard: #ffd400;
    --hazard-dim: #b89800;
    --hazard-wash: rgba(255, 212, 0, 0.09);

    /* minium / red-lead primer. stamps and warnings only. */
    --oxide: #d1442a;

    /* running indicator */
    --led: #6ee787;

    --font-display: 'Archivo', 'Arial Narrow', sans-serif;
    --font-body: 'IBM Plex Sans', system-ui, sans-serif;
    --font-mono: 'IBM Plex Mono', 'Consolas', ui-monospace, monospace;

    --nav-h: 54px;
    --rail-w: 58px;
    --wrap: 1480px;

    --hazard-tape: repeating-linear-gradient(
        45deg,
        var(--hazard) 0 13px,
        var(--steel-0) 13px 26px
    );
}

/* ==============================================================
   Reset & base
   ============================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    border-radius: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    background: var(--steel-0);
    color: var(--paint);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* MUST stay `clip` — `hidden` makes body a scroll container and breaks anchors */
    overflow-x: clip;
}

::selection {
    background: var(--hazard);
    color: var(--steel-0);
}

a { color: inherit; }

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

:focus-visible {
    outline: 2px solid var(--hazard);
    outline-offset: 3px;
}

img, svg { display: block; max-width: 100%; }

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

/* ==============================================================
   Texture — grain + machine grid. The anti-generated layer.
   ============================================================== */
body::before {
    /* fractal noise, fixed, non-interactive */
    content: '';
    position: fixed;
    inset: -50%;
    z-index: 9998;
    pointer-events: none;
    opacity: 0.035;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='260' height='260' filter='url(%23n)'/%3E%3C/svg%3E");
}

body::after {
    /* faint machine grid, 64px */
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image:
        linear-gradient(to right, rgba(255, 255, 255, 0.018) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
    background-size: 64px 64px;
}

/* ==============================================================
   Industrial hardware — tape, screws, stamps, LEDs
   ============================================================== */
.tape {
    height: 9px;
    background: var(--hazard-tape);
    width: 100%;
}

.tape-thin { height: 6px; }

/* riveted panel: four slotted screw heads in the corners */
.panel {
    position: relative;
    border: 1px solid var(--rule);
    background: var(--steel-1);
}

.panel::before,
.panel::after,
.panel > .screws::before,
.panel > .screws::after {
    content: '';
    position: absolute;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background:
        linear-gradient(var(--steel-0) 0 0) center / 5px 1px no-repeat,
        radial-gradient(circle at 35% 30%, var(--steel-4), var(--steel-2) 70%);
    box-shadow: 0 0 0 1px var(--rule);
    pointer-events: none;
}

.panel::before { top: 7px; left: 7px; }
.panel::after { top: 7px; right: 7px; }
.panel > .screws::before { bottom: 7px; left: 7px; }
.panel > .screws::after { bottom: 7px; right: 7px; }

/* corner ticks — drafting registration */
.ticked {
    position: relative;
    border: 1px solid var(--rule);
    background: var(--steel-1);
}

.ticked::before,
.ticked::after {
    content: '';
    position: absolute;
    width: 11px;
    height: 11px;
    pointer-events: none;
    border-color: var(--hazard);
}

.ticked::before {
    top: -1px;
    left: -1px;
    border-top: 2px solid;
    border-left: 2px solid;
}

.ticked::after {
    bottom: -1px;
    right: -1px;
    border-bottom: 2px solid;
    border-right: 2px solid;
}

/* stamped label */
.stamp {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 0.18rem 0.5rem;
    border: 1px solid var(--rule-bright);
    color: var(--paint-2);
    white-space: nowrap;
}

.stamp-hazard {
    border-color: var(--hazard);
    color: var(--hazard);
}

.stamp-oxide {
    border-color: var(--oxide);
    color: var(--oxide);
}

.stamp-fill {
    background: var(--hazard);
    border-color: var(--hazard);
    color: var(--steel-0);
    font-weight: 600;
}

/* indicator lamp */
.led {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--led);
    box-shadow: 0 0 6px var(--led);
    flex: none;
    animation: led-pulse 2.4s steps(1, end) infinite;
}

.led-idle {
    background: var(--paint-3);
    box-shadow: none;
    animation: none;
}

.led-hazard {
    background: var(--hazard);
    box-shadow: 0 0 6px var(--hazard);
}

@keyframes led-pulse {
    0%, 70% { opacity: 1; }
    71%, 100% { opacity: 0.45; }
}

.accent { color: var(--hazard); }

/* ==============================================================
   Boot loader
   ============================================================== */
.boot-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    height: 100vh;
    background: var(--steel-0);
}

.loading-progress {
    position: relative;
    display: block;
    width: 5.5rem;
    height: 5.5rem;
}

.loading-progress circle {
    fill: none;
    stroke: var(--rule);
    stroke-width: 0.28rem;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: var(--hazard);
    stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
    transition: stroke-dasharray 0.05s linear;
}

.loading-progress-text::after {
    content: var(--blazor-load-percentage-text, "ANLAUFEN");
    color: var(--paint-3);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.22em;
}

/* ==============================================================
   Blazor error UI
   ============================================================== */
#blazor-error-ui {
    display: none;
    background: var(--steel-2);
    border-top: 3px solid var(--oxide);
    color: var(--paint);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    padding: 0.8rem 1.25rem;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
}

#blazor-error-ui .reload {
    color: var(--hazard);
    text-decoration: underline;
    cursor: pointer;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    float: right;
}

/* ==============================================================
   Left measurement rail — persistent structure down the page
   ============================================================== */
.rail {
    position: fixed;
    top: var(--nav-h);
    bottom: 0;
    left: 0;
    width: var(--rail-w);
    z-index: 900;
    border-right: 1px solid var(--rule-dim);
    background: var(--steel-0);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 0;
    pointer-events: none;
}

.rail::before {
    /* millimetre ticks */
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 9px;
    background-image: repeating-linear-gradient(
        to bottom,
        var(--rule) 0 1px,
        transparent 1px 12px
    );
    opacity: 0.75;
}

.rail-mark {
    writing-mode: vertical-rl;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.34em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding-left: 10px;
}

.rail-now {
    writing-mode: vertical-rl;
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--hazard);
    padding-left: 10px;
}

.rail-tape {
    width: 14px;
    height: 76px;
    background: var(--hazard-tape);
    margin-left: 10px;
}

/* ==============================================================
   Navigation — control strip
   ============================================================== */
.site-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-h);
    z-index: 1000;
    background: var(--steel-0);
    border-bottom: 1px solid var(--rule);
}

.site-nav::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -4px;
    height: 3px;
    background: var(--hazard-tape);
    background-size: auto;
    opacity: 0.85;
}

.site-nav-inner {
    max-width: calc(var(--wrap) + var(--rail-w));
    margin: 0 auto;
    padding: 0 2.25rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.nav-stamp {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    color: var(--paint);
    padding: 0;
}

.nav-stamp-mark {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    background: var(--hazard);
    color: var(--steel-0);
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.nav-stamp:hover .nav-stamp-mark { background: var(--paint); }

.nav-links {
    display: flex;
    align-items: center;
    gap: 0;
}

.nav-link {
    display: inline-flex;
    align-items: baseline;
    gap: 0.42rem;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--paint-2);
    padding: 0.5rem 0.85rem;
    border-left: 1px solid var(--rule-dim);
    transition: color 0.12s steps(2), background 0.12s steps(2);
}

.nav-links .nav-link:last-of-type { border-right: 1px solid var(--rule-dim); }

.nav-link:hover {
    color: var(--steel-0);
    background: var(--hazard);
}

.nav-link-idx {
    font-size: 0.58rem;
    color: var(--paint-3);
}

.nav-link:hover .nav-link-idx { color: var(--steel-0); }

.nav-clock {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.13em;
    color: var(--paint-3);
    padding-left: 1rem;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.nav-clock strong {
    color: var(--paint-2);
    font-weight: 500;
}

.nav-burger {
    display: none;
    flex-direction: column;
    gap: 4px;
    padding: 0.5rem;
}

.nav-burger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--paint);
}

.nav-mobile {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    z-index: 999;
    background: var(--steel-0);
    border-bottom: 1px solid var(--rule);
    display: flex;
    flex-direction: column;
}

.nav-mobile button {
    text-align: left;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--paint-2);
    padding: 0.95rem 1.5rem;
    border-bottom: 1px solid var(--rule-dim);
}

.nav-mobile button:last-child {
    color: var(--hazard);
    border-bottom: none;
}

/* ==============================================================
   Page shell — everything sits right of the rail
   ============================================================== */
.shop {
    padding-left: var(--rail-w);
}

/* ==============================================================
   Section chrome
   (.sheet / .sheet-head / .sheet-meta / .sheet-title / .sheet-sub
    are also used by the legal pages — keep these names)
   ============================================================== */
.sheet {
    position: relative;
    padding: 6.5rem 0;
    border-top: 1px solid var(--rule-dim);
}

.sheet-alt { background: var(--steel-1); }

/* The meta rule spans the full sheet like a drawing header; only the
   reading text is measured. */
.sheet-head { margin-bottom: 3.25rem; }

.sheet-meta {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex-wrap: wrap;
    font-family: var(--font-mono);
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding-bottom: 0.85rem;
    margin-bottom: 1.6rem;
    border-bottom: 1px solid var(--rule);
}

.sheet-meta .num {
    background: var(--hazard);
    color: var(--steel-0);
    padding: 0.2rem 0.45rem;
    letter-spacing: 0.1em;
}

.sheet-meta em {
    font-style: normal;
    color: var(--rule-bright);
}

.sheet-meta > span:last-child { margin-left: auto; }

.sheet-title {
    font-family: var(--font-display);
    font-stretch: 70%;
    font-weight: 800;
    font-size: clamp(2.2rem, 5.2vw, 4rem);
    line-height: 0.92;
    letter-spacing: 0.005em;
    text-transform: uppercase;
    color: var(--paint);
    max-width: 24ch;
}

.sheet-sub {
    margin-top: 1.15rem;
    font-size: 1.02rem;
    color: var(--paint-2);
    max-width: 58ch;
}

.sheet-sub strong { color: var(--paint); font-weight: 600; }

/* ==============================================================
   Buttons
   ============================================================== */
.btn-solid,
.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    font-family: var(--font-mono);
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 0.85rem 1.4rem;
    text-decoration: none;
    transition: background 0.12s steps(2), color 0.12s steps(2), border-color 0.12s steps(2);
}

.btn-solid {
    background: var(--hazard);
    color: var(--steel-0);
    border: 1px solid var(--hazard);
}

.btn-solid:hover {
    background: var(--paint);
    border-color: var(--paint);
}

.btn-ghost {
    background: transparent;
    color: var(--paint);
    border: 1px solid var(--rule-bright);
}

.btn-ghost:hover {
    border-color: var(--hazard);
    color: var(--hazard);
}

/* ==============================================================
   HERO
   ============================================================== */
#hero {
    position: relative;
    padding: calc(var(--nav-h) + 5.5rem) 0 0;
    overflow: hidden;
}

.hero-tape {
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    height: 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 355px;
    gap: 3.5rem;
    align-items: start;
}

.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--paint-3);
    margin-bottom: 2rem;
}

.hero-eyebrow em {
    font-style: normal;
    color: var(--hazard);
}

.hero-headline {
    font-family: var(--font-display);
    font-stretch: 63%;
    font-weight: 800;
    font-size: clamp(3.6rem, 12.5vw, 11.5rem);
    line-height: 0.84;
    letter-spacing: 0.004em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 2.4rem;
}

.hero-headline span { display: block; }

.hero-headline .run {
    color: var(--hazard);
    position: relative;
    width: fit-content;
}

.hero-headline .run::after {
    /* underline it like a painted floor stripe */
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.06em;
    height: 6px;
    background: var(--hazard-tape);
}

.hero-lede {
    font-size: 1.1rem;
    line-height: 1.62;
    color: var(--paint-2);
    max-width: 54ch;
    margin-bottom: 2.2rem;
}

.hero-lede strong {
    color: var(--paint);
    font-weight: 600;
}

.hero-cta {
    display: flex;
    gap: 0.9rem;
    flex-wrap: wrap;
}

/* ---- Typenschild (rating plate) ---- */
.plate {
    position: relative;
    border: 1px solid var(--rule-bright);
    background: var(--steel-1);
    padding: 1.15rem;
}

.plate::before,
.plate::after,
.plate .screws::before,
.plate .screws::after {
    content: '';
    position: absolute;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background:
        linear-gradient(var(--steel-0) 0 0) center / 5px 1px no-repeat,
        radial-gradient(circle at 35% 30%, var(--steel-4), var(--steel-2) 72%);
    box-shadow: inset 0 0 0 1px var(--rule);
    pointer-events: none;
}

.plate::before { top: 6px; left: 6px; }
.plate::after { top: 6px; right: 6px; }
.plate .screws::before { bottom: 6px; left: 6px; }
.plate .screws::after { bottom: 6px; right: 6px; }

.plate-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    font-family: var(--font-mono);
    font-size: 0.63rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding: 0 1rem 0.9rem;
    margin: 0 -0.15rem 1rem;
    border-bottom: 1px solid var(--rule);
}

.plate-run {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    color: var(--led);
}

.plate-rows {
    display: grid;
    gap: 0;
}

.plate-row {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 0.8rem;
    padding: 0.52rem 0.35rem;
    border-bottom: 1px dashed var(--rule-dim);
    font-size: 0.82rem;
}

.plate-row:last-child { border-bottom: none; }

.plate-key {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding-top: 0.16rem;
}

.plate-val {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--paint);
    line-height: 1.45;
}

.plate-val small {
    display: block;
    font-size: 0.68rem;
    color: var(--paint-3);
    letter-spacing: 0.04em;
}

.plate-foot {
    margin-top: 1rem;
    padding-top: 0.85rem;
    border-top: 1px solid var(--rule);
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--paint-3);
    text-align: center;
}

/* ---- hero footer strip ---- */
.hero-strip {
    margin-top: 5rem;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    background: var(--steel-1);
}

.hero-strip-inner {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.hero-strip-cell {
    padding: 1.15rem 1.5rem;
    border-left: 1px solid var(--rule-dim);
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.hero-strip-cell:first-child { border-left: none; }

.hero-strip-k {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-family: var(--font-mono);
    font-size: 0.61rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
}

.hero-strip-v {
    font-family: var(--font-display);
    font-stretch: 75%;
    font-weight: 700;
    font-size: 1.02rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--paint);
}

/* ==============================================================
   01 — WHAT'S RUNNING (status board)
   ============================================================== */
.board {
    border: 1px solid var(--rule);
    background: var(--steel-1);
}

.board-head,
.board-row {
    display: grid;
    grid-template-columns: 62px minmax(160px, 1fr) minmax(0, 2fr) minmax(150px, 1fr) 158px;
    gap: 1.25rem;
    padding: 0.95rem 1.35rem;
    align-items: start;
}

.board-head {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
    background: var(--steel-2);
    border-bottom: 1px solid var(--rule);
    padding-top: 0.7rem;
    padding-bottom: 0.7rem;
}

.board-row {
    border-bottom: 1px solid var(--rule-dim);
    transition: background 0.1s steps(2);
}

.board-row:last-child { border-bottom: none; }

.board-row:hover { background: var(--steel-2); }

.board-nr {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--hazard);
}

.board-sys {
    font-family: var(--font-display);
    font-stretch: 78%;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.015em;
    text-transform: uppercase;
    color: var(--paint);
    line-height: 1.2;
}

.board-fn {
    font-size: 0.88rem;
    color: var(--paint-2);
    line-height: 1.5;
}

.board-stack {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.04em;
    color: var(--paint-3);
    line-height: 1.55;
}

.board-state {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    align-items: flex-start;
}

.board-state-v {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--led);
}

.board-state-since {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    color: var(--paint-3);
}

.board-note {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    margin-top: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.1em;
    color: var(--paint-3);
}

.board-note::before {
    content: '';
    width: 34px;
    height: 6px;
    background: var(--hazard-tape);
    flex: none;
}

/* ==============================================================
   02 — THE PARTS LIST (work)
   ============================================================== */
.assembly {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
    border: 1px solid var(--rule-bright);
    background: var(--steel-1);
    margin-bottom: 1.5rem;
}

.assembly-main {
    padding: 2.25rem;
    border-right: 1px solid var(--rule);
}

.assembly-tags {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
}

.assembly-title {
    font-family: var(--font-display);
    font-stretch: 68%;
    font-weight: 800;
    font-size: clamp(2rem, 4.4vw, 3.1rem);
    line-height: 0.94;
    letter-spacing: 0.01em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 1rem;
}

.assembly-desc {
    font-size: 0.97rem;
    color: var(--paint-2);
    line-height: 1.65;
    max-width: 58ch;
    margin-bottom: 1.9rem;
}

.assembly-desc strong { color: var(--paint); font-weight: 600; }

/* the sequence — how the machine actually works */
.sequence {
    border-top: 1px solid var(--rule);
    padding-top: 1.35rem;
}

.sequence-label {
    font-family: var(--font-mono);
    font-size: 0.61rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--paint-3);
    margin-bottom: 1rem;
}

.sequence-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0;
}

.sequence-step {
    position: relative;
    padding: 0 1rem 0 0;
    border-left: 2px solid var(--hazard);
    padding-left: 0.85rem;
}

.sequence-step + .sequence-step { border-left-color: var(--rule-bright); }

.sequence-n {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    color: var(--hazard);
    margin-bottom: 0.3rem;
}

.sequence-t {
    font-size: 0.83rem;
    color: var(--paint-2);
    line-height: 1.45;
}

.assembly-side {
    padding: 2.25rem 1.9rem;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: var(--steel-2);
}

.assembly-side-head {
    font-family: var(--font-mono);
    font-size: 0.61rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding-bottom: 0.9rem;
    margin-bottom: 1.35rem;
    border-bottom: 1px solid var(--rule);
}

.fact { padding: 0.95rem 0; border-bottom: 1px dashed var(--rule-dim); }

.fact:last-child { border-bottom: none; }

.fact-v {
    display: block;
    font-family: var(--font-display);
    font-stretch: 72%;
    font-weight: 800;
    font-size: 1.7rem;
    line-height: 1;
    letter-spacing: 0.01em;
    text-transform: uppercase;
    color: var(--hazard);
    margin-bottom: 0.42rem;
}

.fact-k {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    color: var(--paint-2);
    line-height: 1.45;
}

.assembly-tech {
    font-family: var(--font-mono);
    font-size: 0.67rem;
    letter-spacing: 0.05em;
    color: var(--paint-3);
    margin-top: 1.6rem;
    padding-top: 1.1rem;
    border-top: 1px solid var(--rule);
    line-height: 1.7;
}

/* ---- secondary featured pair ---- */
.feat-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    margin-bottom: 3.25rem;
}

.feat {
    position: relative;
    border: 1px solid var(--rule);
    background: var(--steel-1);
    padding: 1.85rem;
    transition: border-color 0.12s steps(2), background 0.12s steps(2);
}

.feat:hover {
    border-color: var(--rule-bright);
    background: var(--steel-2);
}

.feat-title {
    font-family: var(--font-display);
    font-stretch: 72%;
    font-weight: 800;
    font-size: 1.75rem;
    line-height: 1;
    letter-spacing: 0.012em;
    text-transform: uppercase;
    color: var(--paint);
    margin: 1.1rem 0 0.85rem;
}

.feat-desc {
    font-size: 0.91rem;
    color: var(--paint-2);
    line-height: 1.62;
    margin-bottom: 1.4rem;
}

.feat-tech {
    font-family: var(--font-mono);
    font-size: 0.66rem;
    letter-spacing: 0.05em;
    color: var(--paint-3);
    padding-top: 1rem;
    border-top: 1px solid var(--rule-dim);
    line-height: 1.7;
}

/* ---- catalogue: dense rows, not a card grid ---- */
.cat-bar {
    display: flex;
    align-items: center;
    gap: 0;
    flex-wrap: wrap;
    margin-bottom: 0;
    border: 1px solid var(--rule);
    border-bottom: none;
    background: var(--steel-2);
}

.cat-bar-label {
    font-family: var(--font-mono);
    font-size: 0.61rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
    padding: 0.85rem 1.35rem;
    border-right: 1px solid var(--rule);
}

.cat-btn {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--paint-2);
    padding: 0.85rem 1.1rem;
    border-right: 1px solid var(--rule-dim);
    transition: background 0.1s steps(2), color 0.1s steps(2);
}

.cat-btn:hover { color: var(--paint); background: var(--steel-3); }

.cat-btn.active {
    background: var(--hazard);
    color: var(--steel-0);
    font-weight: 600;
}

.cat-count {
    font-size: 0.6rem;
    color: var(--paint-3);
    margin-left: 0.35rem;
}

.cat-btn.active .cat-count { color: rgba(10, 10, 11, 0.6); }

.cat-list {
    border: 1px solid var(--rule);
    background: var(--steel-1);
}

.part {
    display: grid;
    grid-template-columns: 96px minmax(160px, 1fr) minmax(0, 2.1fr) minmax(150px, 0.9fr);
    gap: 1.25rem;
    padding: 1.15rem 1.35rem;
    border-bottom: 1px solid var(--rule-dim);
    align-items: start;
    transition: background 0.1s steps(2);
}

.part:last-child { border-bottom: none; }

.part:hover { background: var(--steel-2); }

.part-nr {
    font-family: var(--font-mono);
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--paint-3);
    padding-top: 0.2rem;
}

.part:hover .part-nr { color: var(--hazard); }

.part-name {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    align-items: flex-start;
}

.part-name h3 {
    font-family: var(--font-display);
    font-stretch: 76%;
    font-weight: 700;
    font-size: 1.02rem;
    letter-spacing: 0.015em;
    text-transform: uppercase;
    color: var(--paint);
    line-height: 1.2;
}

/* only rendered when a project has a genuinely public repo */
a.part-repo {
    text-decoration: none;
    border-color: var(--rule-bright);
    color: var(--paint-2);
    transition: color 0.1s steps(2), border-color 0.1s steps(2);
}

a.part-repo:hover {
    color: var(--hazard);
    border-color: var(--hazard);
}

.part-desc {
    font-size: 0.87rem;
    color: var(--paint-2);
    line-height: 1.55;
}

.part-tech {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.04em;
    color: var(--paint-3);
    line-height: 1.6;
    padding-top: 0.12rem;
}

/* ==============================================================
   03 — THE TOOL WALL
   ============================================================== */
.wall {
    display: grid;
    gap: 0;
    border: 1px solid var(--rule);
    background: var(--steel-1);
}

.wall-band {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    border-bottom: 1px solid var(--rule);
}

.wall-band:last-child { border-bottom: none; }

.wall-label {
    padding: 1.6rem 1.5rem;
    border-right: 1px solid var(--rule);
    background: var(--steel-2);
}

.wall-label h3 {
    font-family: var(--font-display);
    font-stretch: 72%;
    font-weight: 800;
    font-size: 1.32rem;
    line-height: 1.05;
    letter-spacing: 0.015em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 0.5rem;
}

.wall-label p {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.09em;
    color: var(--paint-3);
    line-height: 1.6;
}

/* real pegboard: cells align column-to-column across every row */
.wall-tools {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(172px, 1fr));
    align-content: start;
}

.tool {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    padding: 0.95rem 1.15rem;
    border-right: 1px solid var(--rule-dim);
    border-bottom: 1px solid var(--rule-dim);
    transition: background 0.1s steps(2);
}

.tool:hover { background: var(--steel-2); }

.tool-n {
    font-family: var(--font-mono);
    font-size: 0.79rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    color: var(--paint);
}

.tool-u {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--paint-3);
}

.tool:hover .tool-u { color: var(--hazard); }

.bench-note {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    border: 1px solid var(--rule);
    border-top: none;
    background: var(--steel-2);
}

.bench-note-k {
    padding: 1.35rem 1.5rem;
    border-right: 1px solid var(--rule);
    font-family: var(--font-mono);
    font-size: 0.63rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
}

.bench-note-v {
    padding: 1.35rem 1.5rem;
    font-size: 0.92rem;
    color: var(--paint-2);
    line-height: 1.65;
}

.bench-note-v strong { color: var(--paint); font-weight: 600; }

/* ==============================================================
   04 — SHOP RULES
   ============================================================== */
.rules {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid var(--rule);
    border-left: 1px solid var(--rule);
}

.rule {
    padding: 2rem 2.1rem;
    border-right: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    position: relative;
}

.rule-n {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    color: var(--hazard);
    margin-bottom: 1.05rem;
}

.rule-t {
    font-family: var(--font-display);
    font-stretch: 72%;
    font-weight: 800;
    font-size: 1.42rem;
    line-height: 1.06;
    letter-spacing: 0.015em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 0.85rem;
}

.rule-d {
    font-size: 0.92rem;
    color: var(--paint-2);
    line-height: 1.62;
}

.rule-d strong { color: var(--paint); font-weight: 600; }

/* ==============================================================
   05 — THE OPERATOR
   ============================================================== */
.op-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
    gap: 3.5rem;
    align-items: start;
}

.op-quote {
    font-family: var(--font-display);
    font-stretch: 66%;
    font-weight: 800;
    font-size: clamp(2.1rem, 5vw, 3.6rem);
    line-height: 0.9;
    letter-spacing: 0.008em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 2rem;
}

.op-body p {
    font-size: 1rem;
    color: var(--paint-2);
    line-height: 1.72;
    margin-bottom: 1.15rem;
    max-width: 60ch;
}

.op-body p strong { color: var(--paint); font-weight: 600; }

.op-stats {
    border: 1px solid var(--rule-bright);
    background: var(--steel-2);
    position: relative;
}

.op-stat {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    padding: 1.15rem 1.4rem;
    border-bottom: 1px solid var(--rule);
}

.op-stat:last-child { border-bottom: none; }

.op-stat-v {
    font-family: var(--font-display);
    font-stretch: 70%;
    font-weight: 800;
    font-size: 2rem;
    line-height: 1;
    letter-spacing: 0.01em;
    color: var(--hazard);
}

.op-stat-k {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.07em;
    color: var(--paint-2);
    line-height: 1.5;
}

/* ==============================================================
   06 — CONTACT
   ============================================================== */
.contact-head {
    font-family: var(--font-display);
    font-stretch: 63%;
    font-weight: 800;
    font-size: clamp(3rem, 9.5vw, 8rem);
    line-height: 0.85;
    letter-spacing: 0.005em;
    text-transform: uppercase;
    color: var(--paint);
    margin-bottom: 1.9rem;
}

.contact-lede {
    font-size: 1.06rem;
    color: var(--paint-2);
    line-height: 1.65;
    max-width: 56ch;
    margin-bottom: 2.75rem;
}

.contact-lede strong { color: var(--paint); font-weight: 600; }

.contact-rows {
    border: 1px solid var(--rule-bright);
    background: var(--steel-1);
}

.contact-row {
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr) 40px;
    gap: 1.25rem;
    align-items: center;
    padding: 1.35rem 1.5rem;
    border-bottom: 1px solid var(--rule);
    text-decoration: none;
    transition: background 0.1s steps(2);
}

.contact-row:last-child { border-bottom: none; }

a.contact-row:hover { background: var(--steel-2); }

.contact-key {
    font-family: var(--font-mono);
    font-size: 0.63rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--paint-3);
}

.contact-val {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--paint);
    word-break: break-word;
}

.contact-val small {
    display: block;
    font-size: 0.68rem;
    color: var(--paint-3);
    letter-spacing: 0.06em;
    margin-top: 0.22rem;
}

a.contact-row:hover .contact-val { color: var(--hazard); }

.contact-arrow {
    font-family: var(--font-mono);
    font-size: 1.05rem;
    color: var(--paint-3);
    text-align: right;
}

a.contact-row:hover .contact-arrow { color: var(--hazard); }

/* ==============================================================
   Footer
   ============================================================== */
.site-footer {
    border-top: 1px solid var(--rule);
    background: var(--steel-0);
}

.site-footer-inner {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2.25rem;
    align-items: center;
    padding-top: 1.6rem;
    padding-bottom: 1.6rem;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--paint-3);
}

.site-footer-inner a {
    color: var(--paint-2);
    text-decoration: none;
    border-bottom: 1px solid var(--rule-bright);
}

.site-footer-inner a:hover {
    color: var(--hazard);
    border-color: var(--hazard);
}

.site-footer-inner > span:last-child { margin-left: auto; }

/* ==============================================================
   Legal pages
   ============================================================== */
.legal-body {
    max-width: 76ch;
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--paint-2);
}

.legal-body h2 {
    font-family: var(--font-display);
    font-stretch: 74%;
    font-weight: 800;
    font-size: 1.28rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--paint);
    margin: 2.5rem 0 0.8rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--rule);
}

.legal-body h3 {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--paint);
    margin: 1.8rem 0 0.55rem;
}

.legal-body p { margin-bottom: 1rem; }

.legal-body ul { margin: 0 0 1rem 1.15rem; }

.legal-body li { margin-bottom: 0.42rem; }

.legal-body a {
    color: var(--hazard);
    text-decoration: none;
    border-bottom: 1px solid var(--hazard-dim);
}

.legal-body a:hover { border-color: var(--hazard); }

.legal-body strong { color: var(--paint); font-weight: 600; }

/* ==============================================================
   Reveal — mechanical, stepped. Not a smooth fade.
   ============================================================== */
.reveal {
    opacity: 0;
    transform: translateY(16px);
}

.reveal-visible {
    opacity: 1;
    transform: none;
    transition: opacity 0.34s steps(6, end), transform 0.44s cubic-bezier(0.16, 0.9, 0.2, 1);
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    .reveal,
    .reveal-visible {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .led { animation: none; }
}

/* ==============================================================
   Responsive
   ============================================================== */
@media (max-width: 1180px) {
    .hero-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 2.75rem;
    }

    .plate { max-width: 420px; }

    .assembly { grid-template-columns: minmax(0, 1fr); }

    .assembly-main { border-right: none; border-bottom: 1px solid var(--rule); }

    .op-grid { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }

    .board-head { display: none; }

    .board-row {
        grid-template-columns: 54px minmax(0, 1fr);
        gap: 0.5rem 1rem;
        padding: 1.25rem 1.15rem;
    }

    .board-fn, .board-stack, .board-state { grid-column: 2; }

    .board-state {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.3rem 0.9rem;
    }
}

@media (max-width: 960px) {
    :root { --rail-w: 0px; }

    .rail { display: none; }

    .shop { padding-left: 0; }

    .nav-links { display: none; }

    .nav-clock { display: none; }

    .nav-burger { display: flex; }

    .feat-pair { grid-template-columns: minmax(0, 1fr); }

    .rules { grid-template-columns: minmax(0, 1fr); }

    .wall-band { grid-template-columns: minmax(0, 1fr); }

    .wall-label { border-right: none; border-bottom: 1px solid var(--rule); }

    .bench-note { grid-template-columns: minmax(0, 1fr); }

    .bench-note-k { border-right: none; border-bottom: 1px solid var(--rule); }

    .hero-strip-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }

    .hero-strip-cell:nth-child(3) { border-left: none; }

    .hero-strip-cell:nth-child(n + 3) { border-top: 1px solid var(--rule-dim); }

    .part {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.55rem;
    }

    .part-nr { padding-top: 0; }
}

@media (max-width: 640px) {
    .wrap { padding: 0 1.25rem; }

    .sheet { padding: 4rem 0; }

    .sheet-head { margin-bottom: 2.25rem; }

    .sheet-meta > span:last-child { margin-left: 0; }

    #hero { padding-top: calc(var(--nav-h) + 3rem); }

    .hero-strip { margin-top: 3rem; }

    .hero-strip-inner { grid-template-columns: minmax(0, 1fr); }

    .hero-strip-cell { border-left: none; border-top: 1px solid var(--rule-dim); }

    .hero-strip-cell:first-child { border-top: none; }

    .assembly-main, .assembly-side { padding: 1.5rem 1.25rem; }

    .feat { padding: 1.4rem 1.25rem; }

    .rule { padding: 1.6rem 1.35rem; }

    .cat-bar-label { width: 100%; border-right: none; border-bottom: 1px solid var(--rule); }

    .contact-row { grid-template-columns: minmax(0, 1fr) 30px; }

    .contact-key { grid-column: 1 / -1; }

    .site-footer-inner > span:last-child { margin-left: 0; }
}
