/* ============================================================
   telomere.dev — garage biolab after midnight
   Palette:
     #0A0A0F  void black (primary background)
     #00FFE0  electric cyan (headings, glow)
     #FF2D6B  neon magenta (secondary headings, hover)
     #FFE014  hazard yellow (annotations, callouts)
     #C8C8D4  cool silver (body text)
     #111118  deep indigo (alt-bg)
     #1B4D3E  circuit green (PCB traces)
     #00FFE033 glow wash (ambient halos)
   Fonts: Caveat, Karla, Permanent Marker
   ============================================================ */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --void: #0A0A0F;
    --cyan: #00FFE0;
    --magenta: #FF2D6B;
    --hazard: #FFE014;
    --silver: #C8C8D4;
    --indigo: #111118;
    --circuit-green: #1B4D3E;
    --glow-wash: #00FFE033;
}

html, body {
    background: var(--void);
    color: var(--silver);
    font-family: 'Karla', system-ui, sans-serif;
    font-weight: 400;
    line-height: 1.72;
    letter-spacing: 0.005em;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    position: relative;
    background:
        radial-gradient(ellipse at 20% 10%, rgba(0, 255, 224, 0.04), transparent 60%),
        radial-gradient(ellipse at 80% 80%, rgba(255, 45, 107, 0.04), transparent 65%),
        var(--void);
    overflow-x: hidden;
}

/* ============================================================
   PERSISTENT GRAIN LAYER
   ============================================================ */
.grain-layer {
    position: fixed;
    inset: 0;
    z-index: 100;
    pointer-events: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' seed='4'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.7 0'/></filter><rect width='240' height='240' filter='url(%23n)' opacity='0.85'/></svg>");
    background-size: 240px 240px;
    opacity: 0.07;
    mix-blend-mode: screen;
    will-change: background-position, opacity;
}

.grain-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n2'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' seed='9'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.6 0'/></filter><rect width='180' height='180' filter='url(%23n2)'/></svg>");
    background-size: 180px;
    opacity: 0.09;
    mix-blend-mode: overlay;
    z-index: 1;
}

/* ============================================================
   PERSISTENT CIRCUIT TRACE NETWORK
   ============================================================ */
.circuit-network {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 1;
}

.circuit-network .trace {
    fill: none;
    stroke: var(--circuit-green);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.18;
    stroke-dasharray: 1200;
    stroke-dashoffset: 1200;
    transition: stroke 0.3s ease, opacity 0.4s ease, stroke-dashoffset 1.4s ease;
}

.circuit-network .solder {
    fill: var(--circuit-green);
    opacity: 0.55;
    transition: fill 0.3s ease, filter 0.3s ease, opacity 0.3s ease;
    animation: solder-pulse 2.5s ease-in-out infinite;
}

.circuit-network .trace-group.active .trace {
    stroke: var(--cyan);
    opacity: 0.6;
    stroke-dashoffset: 0;
    filter: drop-shadow(0 0 4px rgba(0, 255, 224, 0.5));
}

.circuit-network .trace-group.active .solder {
    fill: var(--cyan);
    opacity: 1;
    filter: drop-shadow(0 0 6px var(--cyan));
}

@keyframes solder-pulse {
    0%, 100% { box-shadow: 0 0 4px var(--cyan); }
    50% { box-shadow: 0 0 12px var(--cyan); }
}

/* ============================================================
   NUCLEOTIDE STRIP (vertical T A G section indicators)
   ============================================================ */
.nucleotide-strip {
    position: fixed;
    left: 0.5vw;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
    z-index: 90;
    padding: 0.6rem 0.4rem;
}

.nucleotide-strip .nuc {
    font-family: 'Caveat', cursive;
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--circuit-green);
    line-height: 1;
    transition: color 0.4s ease, text-shadow 0.4s ease, transform 0.3s ease;
    cursor: pointer;
    user-select: none;
    transform: rotate(-3deg);
}

.nucleotide-strip .nuc:hover {
    color: var(--magenta);
    transform: rotate(2deg) scale(1.1);
}

.nucleotide-strip .nuc.active {
    color: var(--cyan);
    text-shadow:
        0 0 8px var(--cyan),
        0 0 16px rgba(0, 255, 224, 0.4);
    animation: nuc-pulse 1.6s ease-in-out infinite;
}

@keyframes nuc-pulse {
    0%, 100% { text-shadow: 0 0 6px var(--cyan), 0 0 14px rgba(0, 255, 224, 0.3); }
    50% { text-shadow: 0 0 14px var(--cyan), 0 0 28px rgba(0, 255, 224, 0.6); }
}

/* ============================================================
   Z-ROW LAYOUT SCAFFOLD
   ============================================================ */
.z-row {
    position: relative;
    width: 100%;
    min-height: 92vh;
    padding: clamp(80px, 12vh, 160px) 5vw;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
    column-gap: 4vw;
    row-gap: clamp(40px, 6vh, 80px);
    align-items: center;
    z-index: 2;
}

.z-row.alt-bg {
    background-color: var(--indigo);
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='600'><g stroke='%231B4D3E' stroke-width='1' fill='none' opacity='0.5'><path d='M0 80 L 200 80 L 220 100 L 400 100 L 420 120 L 600 120'/><path d='M0 200 L 140 200 L 160 220 L 360 220 L 380 240 L 600 240'/><path d='M0 320 L 240 320 L 260 340 L 460 340 L 480 360 L 600 360'/><path d='M0 440 L 180 440 L 200 460 L 380 460 L 400 480 L 600 480'/><circle cx='200' cy='80' r='3' fill='%231B4D3E'/><circle cx='400' cy='100' r='3' fill='%231B4D3E'/><circle cx='160' cy='220' r='3' fill='%231B4D3E'/><circle cx='360' cy='220' r='3' fill='%231B4D3E'/></g></svg>");
    background-size: 600px;
    background-repeat: repeat;
    background-blend-mode: lighten;
}

.z-block {
    position: relative;
    z-index: 3;
    max-width: 52vw;
}

.z-left {
    grid-column: 1 / 2;
    justify-self: start;
}

.z-right {
    grid-column: 2 / 3;
    justify-self: end;
}

/* ============================================================
   ENTRANCE ANIMATIONS (Intersection Observer triggered)
   ============================================================ */
.fade-in-left,
.fade-in-right {
    opacity: 0;
    transition: opacity 0.6s ease-out, transform 0.5s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform, opacity;
}

.fade-in-left  { transform: translateX(-40px); }
.fade-in-right { transform: translateX(40px); }

.fade-in-left.is-visible,
.fade-in-right.is-visible {
    opacity: 1;
    transform: translateX(0);
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
    min-height: 100vh;
    align-items: center;
}

.wordmark {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: clamp(2.4rem, 6vw, 5rem);
    letter-spacing: -0.01em;
    line-height: 1.1;
    color: var(--cyan);
    text-shadow:
        0 0 12px rgba(0, 255, 224, 0.4),
        0 0 28px rgba(0, 255, 224, 0.15);
    transform: rotate(-1.5deg);
    margin-bottom: 1rem;
    user-select: none;
}

.wm-letter {
    display: inline-block;
    opacity: 0;
    transform: translateY(8px);
    animation: letter-in 0.5s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
    animation-delay: calc(0.8s + var(--i) * 0.05s);
}

.wm-letter.wm-dot {
    color: var(--magenta);
    text-shadow:
        0 0 10px rgba(255, 45, 107, 0.6),
        0 0 24px rgba(255, 45, 107, 0.2);
}

@keyframes letter-in {
    0%   { opacity: 0; transform: translateY(8px); filter: drop-shadow(0 0 12px var(--cyan)); }
    60%  { opacity: 1; filter: drop-shadow(0 0 18px var(--cyan)); }
    100% { opacity: 1; transform: translateY(0); filter: drop-shadow(0 0 6px rgba(0, 255, 224, 0.4)); }
}

.tagline {
    margin-top: 0.6rem;
    font-family: 'Permanent Marker', cursive;
    color: var(--hazard);
    font-size: clamp(0.95rem, 1.2vw, 1.15rem);
    transform: rotate(-1.5deg) translateY(10px);
    opacity: 0;
    animation: tagline-in 0.7s ease-out forwards;
    animation-delay: 1.8s;
}

@keyframes tagline-in {
    to { opacity: 1; transform: rotate(-1.5deg) translateY(0); }
}

.hero-meta {
    margin-top: 1.4rem;
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
    opacity: 0;
    animation: tagline-in 0.7s ease-out forwards;
    animation-delay: 2.2s;
}

.hazard-tag {
    font-family: 'Permanent Marker', cursive;
    font-size: 0.78rem;
    color: var(--void);
    background: var(--hazard);
    padding: 0.2rem 0.6rem;
    transform: rotate(-2deg);
    letter-spacing: 0.02em;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.4);
}

.hazard-tag.alt {
    background: var(--magenta);
    color: var(--void);
    transform: rotate(1.5deg);
}

/* hero duotone frame */
.duotone-frame {
    position: relative;
    width: 55vw;
    max-width: 720px;
    height: 45vh;
    min-height: 320px;
    margin-right: -3vw;
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

.duotone-image {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: var(--void);
    filter: contrast(1.2) brightness(0.9);
    box-shadow:
        0 2px 8px rgba(0, 255, 224, 0.1),
        inset 0 0 60px rgba(0, 0, 0, 0.6);
    clip-path: polygon(
        0% 2%, 6% 0%, 22% 1%, 48% 0%, 72% 2%, 92% 0%, 100% 4%,
        99% 28%, 100% 56%, 99% 82%, 100% 100%,
        80% 99%, 56% 100%, 28% 99%, 4% 100%, 0% 96%, 1% 64%, 0% 34%
    );
    transition: filter 0.3s ease, transform 0.25s ease;
}

.duotone-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.duotone-cyan {
    box-shadow:
        0 4px 18px rgba(0, 255, 224, 0.15),
        inset 0 0 80px rgba(0, 0, 0, 0.6);
}

.duotone-magenta {
    box-shadow:
        0 4px 18px rgba(255, 45, 107, 0.16),
        inset 0 0 80px rgba(0, 0, 0, 0.6);
}

.duotone-frame:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px rgba(0, 255, 224, 0.25);
}

.duotone-frame:hover .duotone-image {
    filter: contrast(1.3) brightness(0.95);
}

.duotone-annotation {
    position: absolute;
    bottom: 1rem;
    right: 1.2rem;
    transform: rotate(-2deg);
    z-index: 2;
}

.duotone-caption {
    margin-top: 0.8rem;
    font-family: 'Karla', sans-serif;
    font-weight: 300;
    font-size: 0.85rem;
    color: var(--silver);
    opacity: 0.78;
    text-align: right;
}

.duotone-caption .marker-label {
    margin-right: 0.5rem;
    color: var(--hazard);
}

/* annotation arrows */
.annotation-arrow {
    position: absolute;
    pointer-events: none;
    z-index: 4;
    opacity: 0.85;
}

.arrow-hero {
    width: 220px;
    height: 80px;
    bottom: 18%;
    left: 38%;
    transform: rotate(8deg);
    opacity: 0;
    animation: arrow-in 0.8s ease-out forwards;
    animation-delay: 2.6s;
}

@keyframes arrow-in { to { opacity: 0.85; } }

/* ============================================================
   MARKER LABELS (handwritten annotations)
   ============================================================ */
.marker-label {
    font-family: 'Permanent Marker', cursive;
    font-size: clamp(0.8rem, 1vw, 1rem);
    color: var(--magenta);
    letter-spacing: 0.01em;
    display: inline-block;
    transform: rotate(-1.5deg);
}

.marker-label.cyan { color: var(--cyan); }
.marker-label.hazard { color: var(--hazard); }
.marker-label.rotate-pos { transform: rotate(2deg); }
.marker-label.rotate-neg { transform: rotate(-2deg); }

/* ============================================================
   SECTION HEADINGS
   ============================================================ */
.section-heading {
    font-family: 'Caveat', cursive;
    font-weight: 600;
    font-size: clamp(1.6rem, 3.5vw, 2.8rem);
    line-height: 1.1;
    letter-spacing: -0.01em;
    margin-bottom: 1.2rem;
    transform: rotate(-1deg);
}

.section-heading.cyan {
    color: var(--cyan);
    text-shadow: 0 0 10px rgba(0, 255, 224, 0.3);
}

.section-heading.magenta {
    color: var(--magenta);
    text-shadow: 0 0 10px rgba(255, 45, 107, 0.3);
}

/* ============================================================
   BODY TEXT BLOCKS
   ============================================================ */
.body-copy {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    color: var(--silver);
    line-height: 1.72;
    letter-spacing: 0.005em;
    margin-bottom: 1.1rem;
    max-width: 38rem;
}

.body-copy.small { font-size: clamp(0.82rem, 0.95vw, 0.96rem); }
.body-copy.caption { font-weight: 300; opacity: 0.85; }

.body-copy em {
    color: var(--cyan);
    font-style: italic;
    text-shadow: 0 0 6px rgba(0, 255, 224, 0.25);
}

.inline-mark {
    color: var(--magenta);
    background: linear-gradient(transparent 60%, rgba(255, 224, 20, 0.18) 60%);
    padding: 0 0.18em;
}

.inline-mark.hazard {
    color: var(--hazard);
    background: linear-gradient(transparent 55%, rgba(255, 45, 107, 0.2) 55%);
}

.inline-code {
    font-family: 'Caveat', cursive;
    font-size: 1.15em;
    color: var(--cyan);
    background: rgba(0, 255, 224, 0.07);
    padding: 0.05em 0.4em;
    border: 1px dashed rgba(0, 255, 224, 0.25);
    border-radius: 2px;
    transform: rotate(-0.5deg);
    display: inline-block;
}

/* ============================================================
   TORN PAPER PANEL
   ============================================================ */
.torn-panel {
    position: relative;
    padding: clamp(2rem, 4vw, 3rem) clamp(1.6rem, 3vw, 2.4rem);
    background: rgba(17, 17, 24, 0.72);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    clip-path: polygon(
        0% 1%, 6% 0%, 14% 2%, 26% 0%, 38% 1%, 52% 0%, 64% 2%, 78% 0%, 92% 1%, 100% 0%,
        99% 18%, 100% 38%, 99% 60%, 100% 82%, 99% 100%,
        86% 99%, 72% 100%, 58% 99%, 44% 100%, 30% 99%, 16% 100%, 4% 99%, 0% 100%,
        1% 78%, 0% 56%, 1% 34%, 0% 14%
    );
    border-left: 1px solid rgba(0, 255, 224, 0.08);
}

.torn-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='p'><feTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='2' seed='3'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.6 0'/></filter><rect width='200' height='200' filter='url(%23p)'/></svg>");
    background-size: 200px;
    opacity: 0.12;
    mix-blend-mode: overlay;
}

/* ============================================================
   CIRCUIT CALLOUT (Mid-right)
   ============================================================ */
.circuit-callout {
    position: relative;
    width: 100%;
    max-width: 460px;
    padding: 1.6rem;
    background: rgba(10, 10, 15, 0.6);
    border: 1px dashed rgba(0, 255, 224, 0.15);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

.circuit-callout::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='c'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' seed='13'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.55 0'/></filter><rect width='160' height='160' filter='url(%23c)'/></svg>");
    background-size: 160px;
    opacity: 0.07;
    transition: opacity 0.2s ease;
    mix-blend-mode: overlay;
}

.circuit-callout:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px rgba(0, 255, 224, 0.25);
    border-color: rgba(0, 255, 224, 0.35);
}

.circuit-callout:hover::before { opacity: 0.14; }

.circuit-svg {
    width: 100%;
    height: auto;
    display: block;
}

.circuit-svg .hand-trace {
    stroke-dasharray: 600;
    stroke-dashoffset: 600;
    transition: stroke-dashoffset 1s ease-out;
}

.circuit-callout.is-visible .circuit-svg .hand-trace { stroke-dashoffset: 0; }

.circuit-svg .solder-points circle {
    filter: drop-shadow(0 0 6px var(--cyan));
}

.callout-text {
    margin-top: 0.8rem;
}

.callout-text .marker-label {
    display: block;
    margin-bottom: 0.4rem;
}

/* ============================================================
   CIRCUIT MORPH SECTION
   ============================================================ */
.circuit-row {
    align-items: stretch;
}

.circuit-morph {
    position: relative;
    width: 100%;
    max-width: 560px;
    padding: 1.2rem;
    background: rgba(10, 10, 15, 0.55);
    border-top: 1px dashed rgba(0, 255, 224, 0.18);
    border-bottom: 1px dashed rgba(255, 45, 107, 0.18);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

.morph-svg {
    width: 100%;
    height: auto;
    display: block;
}

.morph-svg .hand-trace {
    stroke-dasharray: 500;
    stroke-dashoffset: 500;
    transition: stroke-dashoffset 1.2s ease-out;
}

.circuit-morph.is-visible .morph-svg .hand-trace { stroke-dashoffset: 0; }

.circuit-morph:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow:
        0 12px 32px rgba(0, 255, 224, 0.18),
        0 12px 32px rgba(255, 45, 107, 0.12);
}

.circuit-morph figcaption {
    margin-top: 0.8rem;
    text-align: right;
    display: block;
}

/* ============================================================
   TERMINAL WINDOW
   ============================================================ */
.terminal-window {
    width: 100%;
    max-width: 560px;
    background: rgba(10, 10, 15, 0.95);
    border: 1px solid rgba(0, 255, 224, 0.25);
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.6) inset,
        0 4px 18px rgba(0, 255, 224, 0.12);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

.terminal-window:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow:
        0 12px 32px rgba(0, 255, 224, 0.25),
        0 0 0 1px rgba(0, 0, 0, 0.6) inset;
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.9rem;
    background: rgba(27, 77, 62, 0.45);
    border-bottom: 1px dashed rgba(0, 255, 224, 0.18);
}

.t-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    box-shadow: 0 0 6px currentColor;
}

.t-red    { background: var(--magenta); color: var(--magenta); }
.t-yellow { background: var(--hazard);  color: var(--hazard); }
.t-green  { background: var(--cyan);    color: var(--cyan); }

.terminal-title {
    margin-left: auto;
    color: var(--silver);
    font-size: 0.78rem;
    transform: rotate(-1deg);
}

.terminal-body {
    padding: 1.1rem 1.2rem 1.4rem;
    font-family: 'Caveat', cursive;
    font-size: clamp(1.05rem, 1.4vw, 1.4rem);
    color: var(--cyan);
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
    min-height: 16rem;
    text-shadow: 0 0 6px rgba(0, 255, 224, 0.3);
}

.terminal-body code {
    font-family: 'Caveat', cursive;
    color: inherit;
}

.terminal-cursor {
    display: inline-block;
    color: var(--cyan);
    animation: cursor-blink 1s steps(2, jump-none) infinite;
    margin-left: 2px;
}

@keyframes cursor-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.terminal-notes {
    max-width: 32rem;
    padding-left: 1rem;
    border-left: 2px dashed rgba(255, 45, 107, 0.25);
}

/* ============================================================
   TELOMERE BAND (TTAGGG repeats, scroll-shortened)
   ============================================================ */
.telomere-band {
    position: relative;
    width: 100%;
    height: clamp(60px, 8vh, 110px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 4;
}

.telomere-band .ttaggg-track {
    display: inline-block;
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: clamp(1.1rem, 1.6vw, 1.6rem);
    letter-spacing: 0.18em;
    color: var(--cyan);
    text-shadow: 0 0 8px rgba(0, 255, 224, 0.45);
    white-space: nowrap;
    transition: width 0.35s ease, opacity 0.35s ease;
    width: 100vw;
    text-align: center;
    overflow: hidden;
    transform-origin: center;
}

.telomere-band .ttaggg-track .ttaggg-letter {
    display: inline-block;
    margin: 0 0.05em;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.telomere-band.terminal-band .ttaggg-track {
    color: var(--magenta);
    text-shadow: 0 0 10px rgba(255, 45, 107, 0.45);
}

/* ============================================================
   FORK / SIGNATURE
   ============================================================ */
.fork-row {
    grid-template-columns: 1fr;
    text-align: center;
    align-items: center;
    justify-items: center;
    min-height: 70vh;
}

.fork-anchor {
    position: relative;
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
    max-width: 520px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.arrow-fork {
    width: 280px;
    height: 90px;
    transform: rotate(-4deg);
    margin-bottom: -0.5rem;
}

.fork-handwritten {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: clamp(1.6rem, 3.6vw, 2.6rem);
    color: var(--hazard);
    text-shadow: 0 0 10px rgba(255, 224, 20, 0.4);
    transform: rotate(-2deg);
    line-height: 1.1;
}

.fork-endpoint {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 1.2rem 0.6rem 0.8rem;
    text-decoration: none;
    border: 1.5px dashed rgba(0, 255, 224, 0.3);
    background: rgba(10, 10, 15, 0.7);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease, border-color 0.25s ease;
    cursor: pointer;
    user-select: none;
}

.fork-endpoint .endpoint-node {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow:
        0 0 6px var(--cyan),
        0 0 14px rgba(0, 255, 224, 0.5);
    animation: solder-pulse 2.2s ease-in-out infinite;
}

.fork-endpoint .endpoint-label {
    font-family: 'Permanent Marker', cursive;
    font-size: 1rem;
    color: var(--cyan);
    letter-spacing: 0.04em;
    text-shadow: 0 0 6px rgba(0, 255, 224, 0.3);
}

.fork-endpoint:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px rgba(0, 255, 224, 0.25);
    border-color: rgba(0, 255, 224, 0.6);
}

.fork-endpoint:hover .endpoint-label { color: var(--hazard); }

.footer-line {
    grid-column: 1 / -1;
    margin-top: 3rem;
    color: var(--silver);
    opacity: 0.55;
    font-size: 0.85rem;
    text-align: center;
    transform: rotate(-1deg);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 880px) {
    .z-row {
        grid-template-columns: 1fr;
        padding: clamp(60px, 10vh, 120px) 6vw;
    }

    .z-left, .z-right {
        grid-column: 1 / -1;
        justify-self: stretch;
        max-width: 100%;
    }

    .duotone-frame {
        width: 100%;
        margin-right: 0;
        height: 38vh;
        min-height: 260px;
    }

    .torn-panel { max-width: 100%; }

    .arrow-hero { display: none; }

    .nucleotide-strip {
        left: 0.2vw;
        gap: 0.9rem;
    }

    .nucleotide-strip .nuc { font-size: 1.2rem; }

    .terminal-notes {
        border-left: none;
        padding-left: 0;
        border-top: 2px dashed rgba(255, 45, 107, 0.25);
        padding-top: 1rem;
    }
}

@media (max-width: 520px) {
    body {
        font-size: 0.95rem;
    }
    .wordmark { font-size: clamp(2rem, 9vw, 3.2rem); }
    .section-heading { font-size: clamp(1.4rem, 6vw, 2rem); }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
