/* ============================================
   jon telep — v1 landing
   sidebar + dotted grid, face first, the sun below.
   ============================================ */
:root {
    --bg: #0b0d10;
    --bg-2: #10131a;
    --panel: #12161d;
    --line: rgba(215, 226, 234, 0.1);
    --line-2: rgba(215, 226, 234, 0.2);
    --fg: #e6edf3;
    --mist: #c7d3dc;
    --dim: rgba(199, 211, 220, 0.55);
    --dimmer: rgba(199, 211, 220, 0.32);
    --green: #35d07f;
    --amber: #f5b342;
    --red: #ff5f57;
    --cyan: #5ad1ff;
    --sun: #ffb347;
    --sans: 'Kanit', system-ui, sans-serif;
    --mono: 'JetBrains Mono', 'Consolas', 'Courier New', monospace;
    --side: 250px;
    --gutter: 56px;
    --p: 0;     /* whole-page scroll progress 0..1 */
    --s: 0;     /* progress through the "sun" reveal 0..1 */
    --sun-d: min(72vh, 82vw);
    --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--fg);
    font-family: var(--sans);
    font-weight: 300;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: inherit; }
::selection { background: var(--sun); color: #000; }

.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 12px; top: 12px; background: #fff; color: #000; padding: 6px 10px; z-index: 100; }

/* dotted grid like graph paper, drifts very slowly */
body::before {
    content: '';
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image: radial-gradient(rgba(199, 211, 220, 0.16) 1px, transparent 1.2px);
    background-size: 22px 22px;
    animation: drift 60s linear infinite;
    opacity: calc(1 - var(--p) * 0.6);
}
@keyframes drift { to { background-position: 22px 22px; } }

/* ---------- space + the sun ---------- */
#space {
    position: fixed; inset: -10% 0 0; z-index: 0; pointer-events: none;
    background-image:
        radial-gradient(1px 1px at 12% 18%, rgba(255,255,255,0.8) 50%, transparent 51%),
        radial-gradient(1px 1px at 68% 74%, rgba(255,255,255,0.55) 50%, transparent 51%),
        radial-gradient(1.5px 1.5px at 83% 26%, rgba(255,255,255,0.7) 50%, transparent 51%),
        radial-gradient(1px 1px at 31% 88%, rgba(255,255,255,0.5) 50%, transparent 51%),
        radial-gradient(1px 1px at 92% 58%, rgba(255,255,255,0.45) 50%, transparent 51%),
        radial-gradient(1.5px 1.5px at 7% 63%, rgba(255,255,255,0.5) 50%, transparent 51%),
        radial-gradient(1px 1px at 48% 12%, rgba(255,255,255,0.55) 50%, transparent 51%),
        radial-gradient(1px 1px at 74% 41%, rgba(255,255,255,0.4) 50%, transparent 51%),
        radial-gradient(2px 2px at 26% 44%, rgba(90,209,255,0.6) 50%, transparent 51%),
        radial-gradient(1.5px 1.5px at 56% 62%, rgba(255,179,71,0.5) 50%, transparent 51%);
    background-size: 640px 640px, 880px 880px, 520px 520px, 760px 760px, 700px 700px, 820px 820px, 580px 580px, 900px 900px, 1100px 1100px, 1300px 1300px;
    opacity: calc(var(--p) * 1.1);
    transform: translateY(calc(var(--p) * -140px));
}
#sun {
    position: fixed;
    left: calc(var(--side) + (100vw - var(--side)) * 0.66);
    top: var(--sun-top, 150vh);
    width: var(--sun-d);
    height: var(--sun-d);
    margin: calc(var(--sun-d) / -2) 0 0 calc(var(--sun-d) / -2);
    transform: scale(var(--sun-scale, 1));
    z-index: 0;
    pointer-events: none;
    will-change: transform, top;
}
#sun .core {
    position: absolute; inset: 0;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 42%, #fff8dc 0%, #ffd66b 26%, #ff9a2e 60%, #ff5a1f 100%);
    box-shadow:
        0 0 40px 10px rgba(255, 190, 90, 0.55),
        0 0 140px 40px rgba(255, 120, 40, 0.35),
        0 0 340px 130px rgba(255, 90, 30, 0.18);
    animation: breathe 6s ease-in-out infinite;
}
#sun .corona {
    position: absolute; inset: -22%;
    border-radius: 50%;
    background:
        conic-gradient(from 0deg, rgba(255,170,60,0.0) 0deg, rgba(255,170,60,0.28) 18deg, rgba(255,170,60,0) 36deg,
            rgba(255,170,60,0.22) 90deg, rgba(255,170,60,0) 120deg, rgba(255,170,60,0.3) 200deg, rgba(255,170,60,0) 240deg,
            rgba(255,170,60,0.2) 300deg, rgba(255,170,60,0) 360deg);
    -webkit-mask: radial-gradient(circle, transparent 38%, #000 42%, transparent 72%);
    mask: radial-gradient(circle, transparent 38%, #000 42%, transparent 72%);
    animation: spin 48s linear infinite;
}
@keyframes breathe { 50% { transform: scale(1.02); filter: brightness(1.06); } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- sidebar ---------- */
#side {
    position: fixed; left: 0; top: 0; bottom: 0;
    width: var(--side);
    padding: 34px 26px 26px;
    border-right: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(11, 13, 16, 0.85), rgba(11, 13, 16, 0.6));
    backdrop-filter: blur(6px);
    display: flex; flex-direction: column; gap: 30px;
    z-index: 10;
    font-family: var(--mono);
    font-size: 12px;
    overflow-y: auto;
    scrollbar-width: none;
}
#side::-webkit-scrollbar { display: none; }
.nav-toggle { display: none; }
.brand {
    font-family: var(--sans);
    font-weight: 600;
    font-size: 26px;
    letter-spacing: -0.01em;
    text-decoration: none;
    color: var(--fg);
    line-height: 1;
}
.brand::after {
    content: '_';
    color: var(--sun);
    animation: blink 1.1s step-end infinite;
}
.meta { margin: 0; display: grid; gap: 7px; }
.meta div { display: flex; gap: 8px; }
.meta dt { color: var(--dim); min-width: 56px; }
.meta dd { margin: 0; color: var(--fg); }
.meta dd a { color: var(--cyan); text-decoration: none; }
.meta dd a:hover { text-decoration: underline; }
#au { color: var(--sun); }

.sidenav { display: grid; gap: 4px; position: relative; }
.sidenav a {
    display: flex; align-items: center; gap: 12px;
    padding: 7px 10px; margin: 0 -10px;
    text-decoration: none;
    color: var(--mist);
    border-radius: 6px;
    transition: color 0.2s, background 0.2s, transform 0.25s var(--ease);
    position: relative;
}
.sidenav a span { color: var(--dimmer); font-size: 11px; min-width: 18px; }
.sidenav a::before {
    content: ''; position: absolute; left: -2px; top: 50%; width: 3px; height: 0; border-radius: 2px;
    background: var(--sun);
    transform: translateY(-50%);
    transition: height 0.25s var(--ease);
}
.sidenav a:hover { color: #fff; background: rgba(199, 211, 220, 0.05); transform: translateX(3px); }
.sidenav a.active { color: #fff; background: rgba(199, 211, 220, 0.06); }
.sidenav a.active::before { height: 60%; }
.sidenav a.active span { color: var(--sun); }

.signals { display: grid; gap: 8px; padding-top: 18px; border-top: 1px solid var(--line); }
.sig-head { margin: 0 0 4px; color: var(--dim); display: flex; align-items: center; gap: 8px; }
.live {
    display: inline-block; width: 7px; height: 7px; border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 0 rgba(53, 208, 127, 0.6);
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(53, 208, 127, 0.6); }
    70% { box-shadow: 0 0 0 7px rgba(53, 208, 127, 0); }
    100% { box-shadow: 0 0 0 0 rgba(53, 208, 127, 0); }
}
.sig { display: grid; grid-template-columns: 64px 1fr; gap: 8px; align-items: baseline; }
.sig span { color: var(--dim); }
.sig b { font-weight: 500; color: var(--fg); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sig b.decoding { color: var(--cyan); }

.side-foot { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px 14px; padding-top: 18px; border-top: 1px solid var(--line); }
.side-foot a { color: var(--dim); text-decoration: none; transition: color 0.2s; }
.side-foot a:hover { color: var(--sun); }

/* ---------- content ---------- */
#content {
    position: relative; z-index: 1;
    margin-left: var(--side);
    padding: 0 var(--gutter);
}
.sec { position: relative; padding: 96px 0; max-width: 1080px; }
.sec + .sec { border-top: 1px solid var(--line); }

.h1, .h2, .h-big, .h-sub, .build-card h3, .card h3, .pitch-item h3 { font-family: var(--sans); font-weight: 600; letter-spacing: -0.02em; margin: 0; }
.h1 { font-size: clamp(44px, 6vw, 84px); line-height: 1; min-height: 1em; }
.h2 { font-size: clamp(36px, 4.4vw, 56px); line-height: 1.05; }
.h-big { font-size: clamp(48px, 7.6vw, 108px); line-height: 0.98; }
.h-big .line { display: block; }
.h-sub { font-size: clamp(22px, 2.6vw, 34px); font-weight: 400; color: var(--sun); margin-top: 14px; }
.typed { white-space: pre; }
.caret {
    display: inline-block; width: 0.08em; height: 0.9em; margin-left: 0.08em;
    background: var(--sun); vertical-align: -0.08em;
    animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.kicker, .orbit-tag, .plate, .sec-sub, .tags, .open, .contact-foot, footer {
    font-family: var(--mono);
}
.kicker { font-size: 12px; color: var(--dim); margin: 0 0 18px; display: flex; align-items: center; gap: 10px; }
.lede { font-size: 18px; line-height: 1.65; color: var(--mist); max-width: 640px; margin: 22px 0 0; font-weight: 300; }
.lede.dim { color: var(--dim); font-size: 16px; }
.lede a { color: var(--fg); text-decoration: none; border-bottom: 1px solid var(--line-2); transition: border-color 0.2s, color 0.2s; }
.lede a:hover { color: var(--sun); border-color: var(--sun); }
.sec-sub { font-size: 13px; color: var(--dim); margin: 14px 0 0; }

.orbit-tag { font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--dim); margin: 0 0 16px; display: flex; align-items: center; gap: 10px; }
.orbit-tag i { width: 14px; height: 14px; border-radius: 50%; border: 1px solid var(--dimmer); position: relative; }
.orbit-tag i::after {
    content: ''; position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--sun);
    top: -2px; left: 5px; box-shadow: 0 0 6px var(--sun);
    transform-origin: 2px 9px;
    animation: spin 5s linear infinite;
}

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.btn {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 12px 20px;
    border: 1px solid var(--fg);
    border-radius: 8px;
    font-family: var(--mono);
    font-size: 13px;
    text-decoration: none;
    color: var(--fg);
    background: transparent;
    position: relative; overflow: hidden;
    transition: color 0.25s, border-color 0.25s, transform 0.25s var(--ease);
}
.btn::before {
    content: ''; position: absolute; inset: 0; background: var(--fg);
    transform: translateX(-101%); transition: transform 0.35s var(--ease); z-index: 0;
}
.btn > * { position: relative; z-index: 1; }
.btn:hover { color: #000; transform: translateY(-2px); }
.btn:hover::before { transform: translateX(0); }
.btn span { transition: transform 0.25s var(--ease); }
.btn:hover span { transform: translate(2px, -2px); }
.btn.ghost { border-color: var(--line-2); color: var(--mist); }
.btn.ghost::before { background: var(--sun); }
.btn.ghost:hover { border-color: var(--sun); color: #000; }

/* ---------- 01 hello ---------- */
#hello { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding-top: 70px; }
.hello-grid { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: 48px; align-items: center; }
.portrait-wrap { position: relative; }
#portrait {
    width: 100%; height: auto; aspect-ratio: 1 / 1; display: block;
    image-rendering: pixelated; image-rendering: crisp-edges;
    border-radius: 6px;
    filter: saturate(1.05) contrast(1.06);
    opacity: 0; animation: fade-in 1s ease 0.2s forwards;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}
@keyframes fade-in { to { opacity: 1; } }
.portrait-frame { position: absolute; inset: -10px; pointer-events: none; }
.corner { position: absolute; width: 16px; height: 16px; border: 1px solid var(--sun); opacity: 0.9; }
.corner.tl { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.corner.tr { top: 0; right: 0; border-left: 0; border-bottom: 0; }
.corner.bl { bottom: 0; left: 0; border-right: 0; border-top: 0; }
.corner.br { bottom: 0; right: 0; border-left: 0; border-top: 0; }
.scanline {
    position: absolute; left: 10px; right: 10px; height: 2px; top: 10px;
    background: linear-gradient(90deg, transparent, rgba(255, 179, 71, 0.7), transparent);
    animation: scan 4.5s linear infinite;
    mix-blend-mode: screen;
}
@keyframes scan { 0% { top: 10px; opacity: 0; } 10% { opacity: 1; } 90% { opacity: 1; } 100% { top: calc(100% - 12px); opacity: 0; } }
.plate { font-size: 11px; color: var(--dimmer); margin: 14px 0 0; letter-spacing: 0.02em; }

.hello-copy .lede { margin-top: 18px; }
.facts { list-style: none; padding: 0; margin: 36px 0 0; display: flex; flex-wrap: wrap; gap: 28px 40px; }
.facts li { display: grid; gap: 2px; }
.facts b { font-family: var(--sans); font-weight: 600; font-size: 30px; line-height: 1; color: var(--fg); }
.facts span { font-family: var(--mono); font-size: 11px; color: var(--dim); letter-spacing: 0.1em; }

.scroll-cue { margin-top: auto; padding-top: 48px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.3em; color: var(--dimmer); display: flex; align-items: center; gap: 14px; text-transform: uppercase; }
.scroll-cue span { width: 1px; height: 36px; background: linear-gradient(180deg, var(--sun), transparent); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 50% { transform: translateY(6px); opacity: 0.5; } }

/* ---------- 02 the sun ---------- */
.sun-sec { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; }
.sun-copy { position: relative; max-width: 720px; }
.sun-copy::before {
    content: ''; position: absolute; inset: -30px -40px;
    background: radial-gradient(ellipse at 35% 50%, rgba(11, 13, 16, 0.7), rgba(11, 13, 16, 0.35) 55%, transparent 80%);
    z-index: -1; pointer-events: none;
}
.sun-copy .h-big, .sun-copy .h-sub { text-shadow: 0 2px 30px rgba(0, 0, 0, 0.8), 0 0 2px rgba(0, 0, 0, 0.9); }
.sun-copy .lede { text-shadow: 0 1px 12px rgba(0, 0, 0, 0.9); color: var(--fg); }
.sun-copy .h-big .line { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.sun-copy .h-big .line:nth-child(2) { transition-delay: 0.12s; }
.sun-copy .h-sub, .sun-copy .lede, .sun-copy .pitch, .sun-copy .cta-row { opacity: 0; transform: translateY(16px); transition: opacity 0.7s var(--ease) 0.25s, transform 0.7s var(--ease) 0.25s; }
.sun-copy.in .h-big .line, .sun-copy.in .h-sub, .sun-copy.in .lede, .sun-copy.in .pitch, .sun-copy.in .cta-row { opacity: 1; transform: none; }
.pitch { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 34px; }
.pitch-item { border: 1px solid var(--line); border-radius: 10px; padding: 18px; background: rgba(16, 19, 26, 0.7); transition: border-color 0.25s, transform 0.25s var(--ease); }
.pitch-item:hover { border-color: var(--sun); transform: translateY(-3px); }
.pi-num { font-family: var(--mono); font-size: 11px; color: var(--sun); }
.pitch-item h3 { font-size: 18px; margin: 8px 0 6px; }
.pitch-item p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--dim); }

/* ---------- 03 what i build ---------- */
.build-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 40px; }
.build-card {
    border: 1px solid var(--line); border-radius: 12px; padding: 20px;
    background: rgba(16, 19, 26, 0.55);
    display: flex; flex-direction: column; gap: 10px;
    transition: border-color 0.25s, transform 0.3s var(--ease), box-shadow 0.3s;
}
.build-card:hover { border-color: var(--line-2); transform: translateY(-4px); box-shadow: 0 30px 60px rgba(0,0,0,0.45); }
.build-card h3 { font-size: 20px; }
.build-card p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--dim); flex: 1; }
.more { font-family: var(--mono); font-size: 12px; color: var(--cyan); text-decoration: none; }
.more:hover { text-decoration: underline; }
.viz { height: 90px; border-radius: 8px; background: var(--bg); border: 1px solid var(--line); overflow: hidden; position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; }
.viz-products span { width: 22px; height: 22px; border-radius: 5px; background: var(--sun); opacity: 0.25; animation: tile 2.4s ease-in-out infinite; }
.viz-products span:nth-child(2) { animation-delay: 0.2s; } .viz-products span:nth-child(3) { animation-delay: 0.4s; }
.viz-products span:nth-child(4) { animation-delay: 0.6s; } .viz-products span:nth-child(5) { animation-delay: 0.8s; } .viz-products span:nth-child(6) { animation-delay: 1s; }
@keyframes tile { 50% { opacity: 1; transform: translateY(-6px); } }
.viz-tools { font-family: var(--mono); font-size: 14px; color: var(--dim); gap: 6px; }
.viz-tools em { font-style: normal; opacity: 0; animation: pop 3.5s ease-in-out infinite; }
.viz-tools em:nth-child(2) { color: var(--cyan); } .viz-tools em:nth-child(5) { color: var(--sun); }
.viz-tools em:nth-child(1) { animation-delay: 0s; } .viz-tools em:nth-child(2) { animation-delay: 0.15s; } .viz-tools em:nth-child(3) { animation-delay: 0.3s; }
.viz-tools em:nth-child(4) { animation-delay: 0.45s; } .viz-tools em:nth-child(5) { animation-delay: 0.6s; } .viz-tools em:nth-child(6) { animation-delay: 0.75s; } .viz-tools em:nth-child(7) { animation-delay: 0.9s; }
@keyframes pop { 10%, 80% { opacity: 1; } 100% { opacity: 0; } }
.viz-signals svg { width: 100%; height: 60%; }
.wave { fill: none; stroke: var(--green); stroke-width: 1.5; stroke-dasharray: 400; stroke-dashoffset: 400; animation: draw 3s linear infinite; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- 04 projects ---------- */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-top: 40px; }
.card {
    display: flex; flex-direction: column;
    text-decoration: none;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 14px 14px 20px;
    background: rgba(16, 19, 26, 0.6);
    transition: border-color 0.25s, transform 0.3s var(--ease), box-shadow 0.3s;
}
.card:hover { border-color: var(--line-2); transform: translateY(-4px); box-shadow: 0 30px 60px rgba(0,0,0,0.45); }
.card-art {
    position: relative; height: 160px; border-radius: 8px; overflow: hidden;
    background: var(--bg);
    border: 1px solid var(--line);
    display: flex; align-items: center; justify-content: center;
}
.stamp {
    position: absolute; top: 10px; right: 10px;
    font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em;
    padding: 3px 8px; border-radius: 4px;
    background: rgba(11, 13, 16, 0.85);
    border: 1px solid;
    transform: rotate(-2deg);
}
.stamp.shipped { color: var(--green); border-color: var(--green); }
.stamp.building { color: var(--amber); border-color: var(--amber); animation: flicker 3s steps(2) infinite; }
@keyframes flicker { 50% { opacity: 0.55; } }
.card .plate { margin: 12px 0 0; }
.card h3 { font-size: 22px; margin: 6px 0 0; transition: color 0.2s; }
.card:hover h3 { color: var(--sun); }
.card > p:not(.plate) { margin: 6px 0 0; font-size: 14.5px; line-height: 1.6; color: var(--dim); flex: 1; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; font-size: 10.5px; }
.tags span { padding: 3px 8px; border-radius: 4px; background: rgba(199, 211, 220, 0.06); color: var(--dim); }
.open { margin-top: 14px; font-size: 12px; color: var(--cyan); text-decoration: underline; text-underline-offset: 3px; }
.open a { color: inherit; text-decoration: underline; text-underline-offset: 3px; margin-right: 16px; }
.open:has(a) { text-decoration: none; }

/* card art animations */
.art-sumvid .film { position: absolute; left: 0; right: 0; top: 24px; display: flex; gap: 8px; padding: 0 12px; animation: slide 6s linear infinite; width: 200%; }
.art-sumvid .film i { flex: 0 0 64px; height: 40px; border-radius: 4px; background: linear-gradient(135deg, #1e2a3a, #2a3f5a); border: 1px solid rgba(90,209,255,0.35); }
.art-sumvid .film i:nth-child(odd) { background: linear-gradient(135deg, #1a2430, #23415a); }
@keyframes slide { to { transform: translateX(-36%); } }
.art-sumvid .lines { position: absolute; left: 14px; right: 14px; bottom: 22px; display: grid; gap: 6px; }
.art-sumvid .lines i { height: 5px; border-radius: 3px; background: var(--green); opacity: 0.8; transform-origin: left; animation: grow 3s var(--ease) infinite; }
.art-sumvid .lines i:nth-child(1) { width: 80%; } .art-sumvid .lines i:nth-child(2) { width: 55%; animation-delay: 0.3s; } .art-sumvid .lines i:nth-child(3) { width: 65%; animation-delay: 0.6s; }
@keyframes grow { 0% { transform: scaleX(0); } 40%, 85% { transform: scaleX(1); } 100% { transform: scaleX(0); } }

.art-tools .tiles { display: grid; grid-template-columns: repeat(6, 22px); gap: 8px; }
.art-tools .tiles i { width: 22px; height: 22px; border-radius: 4px; border: 1px dashed var(--amber); opacity: 0.35; animation: fill 4s ease-in-out infinite; }
.art-tools .tiles i:nth-child(3n) { animation-delay: 0.6s; } .art-tools .tiles i:nth-child(3n+1) { animation-delay: 1.4s; } .art-tools .tiles i:nth-child(5n) { animation-delay: 2.2s; }
@keyframes fill { 45%, 55% { background: var(--amber); border-style: solid; opacity: 1; } }

.art-mine .grid { display: grid; grid-template-columns: repeat(6, 18px); gap: 5px; }
.art-mine .grid i { width: 18px; height: 18px; border-radius: 2px; background: #1c2633; border: 1px solid rgba(90,209,255,0.28); }
.art-mine .grid i.on { background: rgba(53,208,127,0.18); border-color: rgba(53,208,127,0.7); }
.art-mine .grid i.flag { background: var(--amber); border-color: var(--amber); }
.art-mine .grid i.mine { background: var(--red); border-color: var(--red); box-shadow: 0 0 10px rgba(255,95,87,0.65); }

/* barkmarks: a bark meter (quiet → full bark) over a timeline of trigger marks */
.art-bark { display: flex; align-items: flex-end; justify-content: center; }
.art-bark .meter { position: absolute; left: 22px; right: 22px; top: 18px; height: 52px; display: flex; align-items: flex-end; gap: 10px; }
.art-bark .meter i { flex: 1; border-radius: 3px 3px 0 0; background: var(--green); opacity: 0.85; transform-origin: bottom; animation: bark 3.2s var(--ease) infinite; }
.art-bark .meter i:nth-child(1) { height: 22%; }
.art-bark .meter i:nth-child(2) { height: 40%; animation-delay: 0.15s; }
.art-bark .meter i:nth-child(3) { height: 58%; background: var(--amber); animation-delay: 0.3s; }
.art-bark .meter i:nth-child(4) { height: 78%; background: var(--amber); animation-delay: 0.45s; }
.art-bark .meter i:nth-child(5) { height: 100%; background: var(--red); animation-delay: 0.6s; }
.art-bark .track { position: absolute; left: 22px; right: 22px; bottom: 22px; height: 2px; background: var(--line-2); }
.art-bark .track b { position: absolute; top: -5px; width: 12px; height: 12px; border-radius: 50%; background: var(--bg); border: 2px solid var(--red); box-shadow: 0 0 8px rgba(255, 95, 87, 0.6); animation: blink 1.6s ease-in-out infinite; }
.art-bark .track b:nth-child(1) { left: 12%; } .art-bark .track b:nth-child(2) { left: 38%; animation-delay: 0.4s; }
.art-bark .track b:nth-child(3) { left: 61%; animation-delay: 0.8s; } .art-bark .track b:nth-child(4) { left: 86%; animation-delay: 1.2s; }
@keyframes bark { 0%, 100% { transform: scaleY(0.7); } 50% { transform: scaleY(1); } }

.art-postgres svg { width: 80%; height: 80%; }
.art-postgres .nodes rect { fill: var(--bg-2); stroke: var(--cyan); stroke-width: 1; }
.art-postgres .edges line { stroke: var(--cyan); stroke-width: 1; stroke-dasharray: 6 4; animation: dash 2s linear infinite; opacity: 0.7; }
@keyframes dash { to { stroke-dashoffset: -20; } }

.card-art pre { margin: 0; font-family: var(--mono); font-size: 12px; line-height: 1.5; color: var(--mist); }
.art-json pre b { color: var(--cyan); font-weight: 500; } .art-json pre i { color: var(--green); font-style: normal; }
.art-term pre .g { color: var(--green); }
.art-term .cur { animation: blink 1s step-end infinite; }

/* ---------- 05 systems ---------- */
.term-window {
    margin: 40px 0 0;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
    overflow: hidden;
}
.term-titlebar {
    display: flex; align-items: center; gap: 8px;
    padding: 11px 14px;
    background: #171b21;
    border-bottom: 1px solid var(--line);
    font-family: var(--mono);
    font-size: 12px;
    color: var(--dim);
}
.tl { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.tl.red { background: var(--red); }
.tl.yellow { background: #febc2e; }
.tl.green { background: var(--green); }
.term-title { margin-left: 10px; }
.term-full { margin-left: auto; text-decoration: none; color: var(--dim); }
.term-full:hover { color: #fff; }
#terminal {
    height: 420px;
    overflow-y: auto;
    padding: 16px 18px;
    font-family: var(--mono);
    font-size: 13.5px;
    line-height: 1.55;
    color: #b7f7c3;
    cursor: text;
    scrollbar-width: thin;
    scrollbar-color: #2a2f37 transparent;
}
#terminal::-webkit-scrollbar { width: 8px; }
#terminal::-webkit-scrollbar-thumb { background: #2a2f37; border-radius: 4px; }
#output { white-space: pre-wrap; word-wrap: break-word; }
#output a { color: var(--cyan); }
.command-line { display: flex; align-items: center; margin: 4px 0; }
.prompt { color: var(--green); margin-right: 10px; white-space: nowrap; }
#command {
    flex: 1; background: transparent; border: none; outline: none;
    color: #fff; font-family: var(--mono); font-size: 13.5px; padding: 4px 0; caret-color: var(--green);
}
.banner { color: var(--green); font-family: var(--mono); white-space: pre; line-height: 1.15; margin: 4px 0 12px; font-size: 11px; }
.error { color: var(--red); }
.history { color: var(--cyan); }
.directory { color: var(--green); font-weight: 500; cursor: pointer; }
.file { color: var(--mist); cursor: pointer; }
.directory:hover, .file:hover { text-decoration: underline; }
.markdown-content {
    color: var(--mist); padding: 6px 14px; margin: 8px 0;
    border-left: 2px solid var(--green); white-space: normal;
    font-family: var(--sans); font-size: 15px;
}
.markdown-content h1, .markdown-content h2, .markdown-content h3 { color: #fff; margin: 10px 0 6px; font-weight: 600; }
.markdown-content p { margin: 8px 0; line-height: 1.5; }
.markdown-content a { color: var(--cyan); text-decoration: none; }
.markdown-content a:hover { text-decoration: underline; }
.markdown-content code { background: #1c2129; padding: 1px 5px; border-radius: 3px; font-family: var(--mono); font-size: 13px; }
.markdown-content pre { background: #1c2129; padding: 10px; border-radius: 6px; overflow-x: auto; }
.markdown-content ul, .markdown-content ol { margin: 8px 0; padding-left: 20px; }
.term-hints {
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
    padding: 10px 14px; border-top: 1px solid var(--line); background: #171b21;
    font-family: var(--mono); font-size: 11px; color: var(--dim);
}
.term-hints button {
    background: transparent; border: 1px solid var(--line-2); color: var(--mist);
    border-radius: 6px; padding: 4px 10px; font-family: var(--mono); font-size: 11px; cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.term-hints button:hover { background: var(--sun); border-color: var(--sun); color: #000; }

.sys-groups { margin-top: 40px; display: grid; gap: 26px; }
.sys-head { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--dim); padding: 0 12px 8px; border-bottom: 1px solid var(--line); }
.sys {
    display: grid; grid-template-columns: 14px 190px 200px 1fr; gap: 16px; align-items: center;
    padding: 12px; text-decoration: none; color: var(--fg);
    border-bottom: 1px solid var(--line);
    transition: background 0.15s, transform 0.2s var(--ease);
}
.sys:hover { background: rgba(199, 211, 220, 0.04); transform: translateX(4px); }
.sys-led { width: 8px; height: 8px; border-radius: 50%; background: #444; }
.sys-led.on { background: var(--green); box-shadow: 0 0 10px rgba(53, 208, 127, 0.6); }
.sys-led.hot { background: var(--cyan); box-shadow: 0 0 10px rgba(90, 209, 255, 0.6); }
.sys-led.build { background: var(--amber); box-shadow: 0 0 10px rgba(245, 179, 66, 0.6); animation: flicker 2.2s steps(2) infinite; }
.sys-name { font-weight: 500; font-size: 15px; }
.sys-url { font-family: var(--mono); font-size: 12px; color: var(--dim); }
.sys-desc { font-size: 14px; color: var(--dim); }

/* ---------- 06 contact ---------- */
#contact { padding-bottom: 60px; }
#contact .request-form { margin-top: 40px; }
#contact .request-success { margin-top: 32px; }
.contact-foot { font-size: 12px; color: var(--dim); margin-top: 30px; }
.contact-foot a { color: var(--mist); text-decoration: none; border-bottom: 1px solid var(--line-2); }
.contact-foot a:hover { color: var(--sun); border-color: var(--sun); }
footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 24px 0 36px; border-top: 1px solid var(--line); font-size: 11px; color: var(--dimmer); letter-spacing: 0.08em; }
footer a { color: var(--dim); text-decoration: none; }
footer a:hover { color: var(--sun); }

button.btn {
    cursor: pointer;
    font: inherit;
    color: var(--fg);
}
button.btn:disabled {
    opacity: 0.55;
    cursor: wait;
    transform: none;
}
button.btn:disabled:hover { transform: none; color: var(--fg); }
button.btn:disabled:hover::before { transform: translateX(-101%); }

/* ---------- /request ---------- */
body.request-page { --p: 0.55; --s: 0.35; }
body.request-page #sun {
    top: 22vh;
    transform: scale(0.38);
}
.request-sec { min-height: calc(100vh - 80px); padding-top: 70px; }
.request-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-width: 560px;
    margin-top: 36px;
}
.request-form label { display: flex; flex-direction: column; gap: 8px; }
.request-form label span {
    font-family: var(--mono);
    font-size: 12px;
    letter-spacing: 0.06em;
    color: var(--dim);
}
.request-form label span em {
    font-style: normal;
    color: var(--dimmer);
    letter-spacing: 0;
    margin-left: 8px;
}
.request-form input:not(.hp),
.request-form select,
.request-form textarea {
    font-family: var(--sans);
    font-size: 16px;
    font-weight: 300;
    color: var(--fg);
    background: rgba(18, 22, 29, 0.72);
    border: 1px solid var(--line-2);
    border-radius: 8px;
    padding: 12px 14px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.request-form textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.request-form select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--mist) 50%), linear-gradient(135deg, var(--mist) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 12px) 50%; background-size: 6px 6px, 6px 6px; background-repeat: no-repeat; padding-right: 36px; }
.request-form input:not(.hp):focus,
.request-form select:focus,
.request-form textarea:focus {
    border-color: var(--sun);
    box-shadow: 0 0 0 3px rgba(255, 179, 71, 0.15);
}
.request-form .hp {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    width: 0;
}
.form-error {
    font-family: var(--mono);
    font-size: 13px;
    color: var(--red);
    margin: 0;
}
.request-success { max-width: 640px; margin-top: 12px; }
.request-success.in .kicker, .request-success.in .h2, .request-success.in .lede, .request-success.in .cta-row { animation: rx-in 0.6s var(--ease) both; }
.request-success.in .lede { animation-delay: 0.9s; }
.request-success.in .cta-row { animation-delay: 1.2s; }
@keyframes rx-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* in flight: fields dim, the transmit line runs under the buttons */
.request-form.sending label, .request-form.sending .cta-row { opacity: 0.45; pointer-events: none; transition: opacity 0.3s; }
.tx { display: flex; flex-direction: column; gap: 10px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; color: var(--sun); }
.tx-bar { position: relative; display: block; height: 2px; background: var(--line); overflow: hidden; border-radius: 2px; }
.tx-bar i { position: absolute; top: 0; bottom: 0; width: 38%; background: linear-gradient(90deg, transparent, var(--sun), transparent); animation: tx-sweep 1.1s linear infinite; }
.tx-text::after { content: ''; display: inline-block; width: 0.5em; height: 0.9em; margin-left: 4px; background: var(--sun); vertical-align: -0.1em; animation: blink 0.8s step-end infinite; }
@keyframes tx-sweep { from { left: -40%; } to { left: 100%; } }
.request-success .h2 { margin-top: 8px; }
.sidenav a[aria-current="page"] { color: var(--fg); }
.sidenav a[aria-current="page"] span { color: var(--sun); }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1280px) {
    .hello-grid { grid-template-columns: 250px 1fr; gap: 36px; }
    .h1 { font-size: clamp(40px, 5vw, 64px); }
}
@media (max-width: 1180px) {
    .build-grid, .pitch { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
    :root { --side: 0px; --gutter: 20px; }
    html, body { overflow-x: clip; }

    /* the sidebar becomes a sticky top bar: brand + menu button, with the nav folded underneath */
    #side {
        position: sticky; top: 0; bottom: auto; width: auto;
        display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 0 12px;
        padding: 10px 16px; border-right: 0; border-bottom: 1px solid var(--line);
        background: rgba(11, 13, 16, 0.94);
        max-height: 100svh; overflow-y: auto;
    }
    .brand { font-size: 20px; }
    .nav-toggle {
        display: inline-flex; align-items: center; gap: 8px;
        padding: 7px 10px; border: 1px solid var(--line-2); border-radius: 6px;
        background: transparent; color: var(--mist);
        font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
        cursor: pointer;
    }
    .nav-toggle b { display: grid; width: 14px; height: 12px; place-items: center; }
    .nav-toggle i { grid-area: 1 / 1; display: block; width: 14px; height: 1px; background: currentColor; transition: transform 0.25s var(--ease), opacity 0.2s; }
    .nav-toggle i:nth-child(1) { transform: translateY(-4px); }
    .nav-toggle i:nth-child(3) { transform: translateY(4px); }
    .nav-toggle[aria-expanded="true"] { color: var(--sun); border-color: var(--sun); }
    .nav-toggle[aria-expanded="true"] i:nth-child(1) { transform: rotate(45deg); }
    .nav-toggle[aria-expanded="true"] i:nth-child(2) { opacity: 0; }
    .nav-toggle[aria-expanded="true"] i:nth-child(3) { transform: rotate(-45deg); }

    .meta, .sidenav, .signals, .side-foot { grid-column: 1 / -1; display: none; }
    #side.open .sidenav { display: grid; gap: 0; margin-top: 12px; border-top: 1px solid var(--line); }
    #side.open .sidenav a { padding: 12px 4px; margin: 0; border-radius: 0; border-bottom: 1px solid var(--line); font-size: 14px; }
    #side.open .sidenav a::before { display: none; }
    #side.open .sidenav a:hover { transform: none; background: transparent; }
    #side.open .sidenav a.active { background: transparent; }
    #side.open .signals { display: block; margin-top: 14px; }
    #side.open .side-foot { display: flex; padding-top: 14px; margin-top: 14px; padding-bottom: 6px; }

    #sun { left: 50%; }
    #content { margin-left: 0; }
    .sec { padding: 56px 0; }
    #hello { padding-top: 32px; min-height: auto; }
    .hello-grid { grid-template-columns: 1fr; gap: 28px; }
    .portrait-wrap { max-width: 280px; }
    .h1 { font-size: clamp(38px, 11vw, 56px); }
    .h2 { font-size: clamp(30px, 9vw, 44px); }
    .h-big { font-size: clamp(42px, 13vw, 84px); }
    .h-sub { font-size: clamp(19px, 5.5vw, 26px); }
    .lede { font-size: 16px; }
    .facts { gap: 20px 28px; }
    .cta-row { gap: 10px; }
    .btn { padding-left: 16px; padding-right: 16px; }
    .cards, .build-grid, .pitch { grid-template-columns: 1fr; }
    .sun-copy::before { inset: -20px -20px; }
    #terminal { height: 340px; font-size: 12.5px; }
    .term-hints { gap: 6px; }
    .sys { grid-template-columns: 14px 1fr; gap: 4px 12px; padding: 12px 6px; }
    .sys-url, .sys-desc { grid-column: 2; }
    .sys:hover { transform: none; }
    .request-form { max-width: none; }
    footer { flex-direction: column; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .reveal, .sun-copy .h-big .line, .sun-copy .h-sub, .sun-copy .lede, .sun-copy .pitch, .sun-copy .cta-row { opacity: 1; transform: none; }
    html { scroll-behavior: auto; }
}
