/* ============================================================
   v3 sections
============================================================ */

/* ---------- loader ---------- */
.loader { position: fixed; inset: 0; z-index: 10000; background: var(--paper); display: grid; place-items: center; }
.loader-c { width: min(440px, 84vw); text-align: left; }
.loader-id { font-family: var(--font-mono); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-3); display: flex; justify-content: space-between; margin-bottom: 18px; }
.loader-name { font-family: var(--font-display); font-weight: 700; font-size: clamp(34px,6vw,60px); line-height: .95; letter-spacing: -.03em; overflow: hidden; }
.loader-name span { display: block; transform: translateY(110%); }
.loader-bar { margin-top: 26px; height: 2px; background: var(--line); position: relative; overflow: hidden; }
.loader-bar i { position: absolute; inset: 0; background: var(--accent); transform: scaleX(0); transform-origin: left; }
.loader-pct { display: flex; justify-content: space-between; margin-top: 12px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; color: var(--ink-3); }

/* ---------- nav ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 200; display: flex; align-items: center; justify-content: space-between;
  padding: 24px var(--gutter); transition: padding .4s var(--ease), background .4s, border-color .4s; border-bottom: 1px solid transparent; }
.nav.shrink { padding: 14px var(--gutter); background: color-mix(in srgb, var(--paper) 80%, transparent); backdrop-filter: blur(16px) saturate(140%); border-color: var(--line); }
.brand { font-family: var(--font-display); font-weight: 600; font-size: 16px; letter-spacing: -.02em; display: flex; align-items: center; gap: 10px; }
.brand .sq { width: 9px; height: 9px; background: var(--accent); border-radius: 2px; }
.nav-right { display: flex; align-items: center; gap: 8px; }
.nav-links { display: flex; gap: 2px; margin-right: 8px; }
.nav-links a { font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); padding: 8px 12px; transition: color .25s; }
.nav-links a:hover { color: var(--accent); }
.nav-links a em { color: var(--ink-3); font-style: normal; margin-right: 5px; }
@media (max-width: 1040px){ .nav-links { display: none; } }
@media (max-width: 760px){
  .nav .brand {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-6px);
    transition: opacity .28s var(--ease), transform .32s var(--ease), visibility .32s step-end;
  }
  .nav.shrink .brand {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
    transition: opacity .28s var(--ease), transform .32s var(--ease), visibility 0s step-start;
  }
}
.ibtn { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--line-2); color: var(--ink-2); background: transparent; transition: all .25s; border-radius: var(--radius); }
.ibtn:hover { color: var(--accent); border-color: var(--accent); }
.kbd { font-family: var(--font-mono); font-size: 11px; border: 1px solid var(--line-2); padding: 4px 7px; color: var(--ink-3); border-radius: var(--radius); }

/* index rail */
.rail { position: fixed; left: 22px; top: 50%; transform: translateY(-50%); z-index: 150; display: flex; flex-direction: column; gap: 13px; }
@media (max-width: 1240px){ .rail { display: none; } }
.rail a { display: flex; align-items: center; gap: 11px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; color: var(--ink-3); transition: color .3s; }
.rail a .dot { width: 7px; height: 7px; border: 1px solid var(--ink-3); border-radius: 50%; transition: all .3s; flex: none; }
.rail a .lbl { opacity: 0; transform: translateX(-5px); transition: all .3s; white-space: nowrap; }
.rail a:hover .lbl, .rail a.on .lbl { opacity: 1; transform: none; }
.rail a.on { color: var(--accent); }
.rail a.on .dot { border-color: var(--accent); background: var(--accent); }

.sbar { position: fixed; top: 0; left: 0; height: 2px; background: var(--accent); z-index: 250; transform-origin: left; transform: scaleX(0); }

/* ---------- hero ---------- */
.hero { min-height: 100svh; display: flex; align-items: center; padding-top: 132px; padding-bottom: 72px; }
.hero-grid { display: grid; grid-template-columns: 1.18fr .82fr; gap: clamp(30px,5vw,76px); align-items: center; width: 100%; }
@media (max-width: 940px){ .hero-grid { grid-template-columns: 1fr; gap: 44px; } }
.eyebrow { display: flex; align-items: center; gap: 14px; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .08em; color: var(--ink-2); margin-bottom: 26px; flex-wrap: wrap; }
.eyebrow .av { display: inline-flex; align-items: center; gap: 7px; }
.eyebrow .av i { width: 7px; height: 7px; border-radius: 50%; background: #25b06a; }
.hero-name { font-family: var(--font-display); font-weight: 600; font-size: clamp(54px, 11vw, 150px); line-height: .88; letter-spacing: -.045em; }
.hero-name .ln { display: block; overflow: hidden; }
.hero-name .ln > span { display: inline-block; }
.hero-name .it { font-family: var(--font-serif); font-style: italic; font-weight: 400; font-size: .88em; letter-spacing: -.015em; color: var(--accent); }
.hero-name-row { display: block; }
.hero-mobile-avatar { display: none; }
.hero-roles { font-family: var(--font-mono); font-size: clamp(14px,2vw,19px); color: var(--ink-2); margin: 24px 0 26px; height: 1.5em; }
.hero-roles .pre { color: var(--ink-3); }
.hero-roles .accent { color: var(--accent); }
.hero-desc { color: var(--ink-2); font-size: clamp(15.5px,1.6vw,18px); line-height: 1.7; max-width: 46ch; margin-bottom: 32px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.reel-link { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 13px; color: var(--ink-2); padding: 10px 4px; transition: color .25s; }
.reel-link .play { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--accent); transition: transform .35s var(--ease-out), border-color .25s, background .25s; }
.reel-link:hover { color: var(--accent); }
.reel-link:hover .play { transform: scale(1.12); border-color: var(--accent); background: var(--accent-soft); }
.hero-scroll { margin-top: 40px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .18em; color: var(--ink-3); display: flex; align-items: center; gap: 12px; }
.hero-scroll .ln { width: 52px; height: 1px; background: var(--line-2); position: relative; overflow: hidden; }
.hero-scroll .ln::after { content:""; position:absolute; inset:0 100% 0 0; background: var(--accent); animation: sweep 2s var(--ease) infinite; }
@keyframes sweep { 0%{inset:0 100% 0 0} 50%{inset:0 0 0 0} 100%{inset:0 0 0 100%} }

/* portrait module — 3D HUD */
.portrait { position: relative; }
.portrait .ticks { position: absolute; top: -22px; left: 0; font-family: var(--font-mono); font-size: 10px; letter-spacing: .2em; color: var(--ink-3); z-index: 7; }
.portrait .stage { position: relative; perspective: 1100px; padding: 18px 22px 22px 0; isolation: isolate; }
.portrait .tilt { position: relative; transform-style: preserve-3d; will-change: transform; }
.portrait .backplate { position: absolute; inset: 26px -10px 10px 30px; border: 1px solid var(--line-2); border-radius: 16px; opacity: .55;
  background:
    linear-gradient(160deg, color-mix(in srgb, var(--accent-soft) 75%, transparent), transparent 44%),
    repeating-linear-gradient(135deg, transparent 0 12px, color-mix(in srgb, var(--accent-soft) 60%, transparent) 12px 13px);
  z-index: 0; }
.portrait .halo { position: absolute; border-radius: 50%; filter: blur(24px); pointer-events: none; z-index: 0; opacity: .7; }
.portrait .halo.h1 { width: 190px; height: 190px; right: -20px; top: 24px; background: color-mix(in srgb, var(--accent) 24%, transparent); }
.portrait .halo.h2 { width: 120px; height: 120px; left: 18px; bottom: 18px; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.portrait .pin { position: relative; z-index: 1; overflow: hidden; border-radius: 16px; box-shadow: 0 36px 90px -42px rgba(15, 12, 6, .45); background:
  linear-gradient(180deg, color-mix(in srgb, var(--surface) 96%, white 4%), var(--surface));
  border: 1px solid color-mix(in srgb, var(--line-2) 88%, white 8%); }
.portrait .pin::before { content: none; }
.portrait .pin::after { content: ""; position: absolute; inset: 0; box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); pointer-events: none; border-radius: 16px; z-index: 3; }
.portrait .frame-head { position: absolute; top: 0; left: 0; right: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 16px 22px 12px 24px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .18em; color: rgba(255,255,255,.76);
  background: linear-gradient(180deg, rgba(11, 10, 8, .72), rgba(11, 10, 8, 0)); text-transform: uppercase; }
.portrait .frame-head .fid { color: rgba(255,255,255,.7); }
.portrait .frame-head .fstate { display: inline-flex; align-items: center; gap: 8px; color: #f6f0e8; }
.portrait .frame-head .fstate i { width: 7px; height: 7px; border-radius: 50%; background: #2ab26d; box-shadow: 0 0 0 5px rgba(42,178,109,.14); }
.portrait .meta-rail { position: absolute; top: 84px; right: 16px; z-index: 5; display: grid; gap: 8px; text-align: right; }
.portrait .meta-rail span { padding: 7px 10px; border-radius: 999px; border: 1px solid rgba(255,255,255,.16); background: rgba(12, 10, 8, .46);
  backdrop-filter: blur(8px); font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .16em; color: rgba(255,255,255,.82); }
.portrait .pwrap { position: relative; overflow: hidden; aspect-ratio: 1/1.14; background:
  linear-gradient(180deg, rgba(24,21,17,.14), rgba(24,21,17,.02)); }
.portrait img { width: 100%; height: 114%; object-fit: cover; object-position: 50% 18%; display: block; filter: saturate(.98) contrast(1.02); transform: scale(1.02); }
.portrait .mesh { position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: .32; background:
  linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px),
  linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 26px 26px; mask-image: linear-gradient(180deg, rgba(0,0,0,.82), rgba(0,0,0,.18)); }
.portrait .focus-ring { position: absolute; inset: 14% 13% 17%; z-index: 2; border: 1px solid rgba(255,255,255,.48); border-radius: 22px; pointer-events: none; }
.portrait .focus-ring::before, .portrait .focus-ring::after { content: ""; position: absolute; background: rgba(255,255,255,.64); }
.portrait .focus-ring::before { left: 50%; top: -14px; width: 1px; height: 28px; transform: translateX(-50%); }
.portrait .focus-ring::after { top: 50%; left: -14px; width: 28px; height: 1px; transform: translateY(-50%); }
.portrait .grade { position: absolute; inset: 0; z-index: 2; pointer-events: none; mix-blend-mode: soft-light;
  background:
    radial-gradient(circle at 18% 22%, color-mix(in srgb, var(--accent) 46%, transparent), transparent 28%),
    linear-gradient(150deg, color-mix(in srgb, var(--accent) 55%, transparent) 0%, transparent 42%, transparent 70%, color-mix(in srgb, var(--accent) 65%, transparent) 130%);
  opacity: .58; }
.portrait .scanbar { position: absolute; left: 22px; right: 22px; top: 58px; height: 34px; z-index: 4; pointer-events: none;
  background: linear-gradient(color-mix(in srgb, var(--accent-soft) 92%, transparent), transparent); border-top: 1px solid color-mix(in srgb, var(--accent) 68%, white 12%); opacity: .72; }
.portrait .frame-foot { position: absolute; left: 22px; right: 22px; bottom: 18px; z-index: 5; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.portrait .idblock { min-width: 136px; padding: 12px 14px; border-radius: 16px; background: rgba(12, 10, 8, .56); border: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(10px); }
.portrait .idblock .lab { display: block; font-family: var(--font-mono); font-size: 9px; letter-spacing: .18em; text-transform: uppercase; color: rgba(255,255,255,.58); margin-bottom: 6px; }
.portrait .idblock strong { display: block; font-family: var(--font-display); font-size: 15px; font-weight: 600; letter-spacing: -.01em; color: #fff; }
.portrait .brk { position: absolute; width: 24px; height: 24px; border: 2px solid rgba(255,255,255,.92); z-index: 4; pointer-events: none; mix-blend-mode: difference; }
.portrait .brk.tl { top: 18px; left: 18px; border-right: 0; border-bottom: 0; }
.portrait .brk.tr { top: 18px; right: 18px; border-left: 0; border-bottom: 0; }
.portrait .brk.bl { bottom: 18px; left: 18px; border-right: 0; border-top: 0; }
.portrait .brk.br { bottom: 18px; right: 18px; border-left: 0; border-top: 0; }
.portrait .pchip { position: absolute; z-index: 6; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  padding: 10px 14px; border-radius: 999px; color: var(--ink); background: color-mix(in srgb, var(--surface) 86%, rgba(255,255,255,.12));
  border: 1px solid color-mix(in srgb, var(--line-2) 88%, white 8%); backdrop-filter: blur(10px); box-shadow: 0 24px 44px -34px rgba(13,12,9,.5); white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; will-change: transform; }
.portrait .pchip i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.portrait .pchip.c1 { top: 30%; left: -6%; }
.portrait .pchip.c2 { top: 12%; right: -4%; }
.portrait .pchip.c3 { bottom: -2%; right: 6%; color: var(--accent); }
@media (max-width: 940px){ .portrait .stage { padding-right: 0; } }
@media (max-width: 560px){
  .portrait .backplate { inset: 20px -6px 10px 18px; }
  .portrait .frame-head { padding: 14px 16px 10px 18px; }
  .portrait .meta-rail { right: 12px; top: 72px; }
  .portrait .meta-rail span { font-size: 9px; letter-spacing: .12em; }
  .portrait .frame-foot { left: 16px; right: 16px; bottom: 14px; }
  .portrait .idblock { min-width: 0; flex: 1 1 100%; }
  .portrait .pchip.c1 { left: 0; }
  .portrait .pchip.c2 { right: 0; }
}

@media (max-width: 760px){
  .hero {
    min-height: calc(100svh - var(--mobile-marquee-height, 78px));
    padding-top: 108px;
    padding-bottom: 20px;
    align-items: start;
  }
  .hero-grid {
    gap: 24px;
    min-height: calc(100svh - var(--mobile-marquee-height, 78px) - 128px);
    align-content: start;
  }
  .hero-grid > :first-child {
    min-height: calc(100svh - var(--mobile-marquee-height, 78px) - 128px);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: clamp(58px, 12vh, 92px);
    box-sizing: border-box;
  }
  .hero-name-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 82px;
    gap: 14px;
    align-items: start;
  }
  .hero-name {
    font-size: clamp(50px, 17vw, 86px);
    line-height: .9;
  }
  .hero-mobile-avatar {
    display: block;
    width: 82px;
    height: 82px;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--line-2) 88%, white 8%);
    box-shadow: 0 18px 40px -26px rgba(15, 12, 6, .34);
    justify-self: end;
    background: color-mix(in srgb, var(--surface) 96%, white 4%);
  }
  .hero-mobile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 18%;
    transform: scale(1.04);
  }
  .hero-roles {
    height: auto;
    min-height: 2.8em;
    font-size: 13px;
    line-height: 1.45;
    margin: 18px 0 14px;
  }
  .hero-roles .pre {
    display: block;
    margin-bottom: 4px;
  }
  .hero-desc {
    max-width: none;
    font-size: 15px;
    line-height: 1.68;
    margin-bottom: 0;
  }
  .hero-cta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
    margin-top: auto;
    padding-top: 24px;
  }
  .hero-cta .btn {
    width: 100%;
    justify-content: center;
    min-width: 0;
    padding-left: 14px;
    padding-right: 14px;
  }
  .hero-scroll {
    display: none;
  }
  .portrait {
    display: none;
  }
  .hero + .marquee {
    padding: 18px 0;
  }
  .hero + .marquee .marquee-track .item {
    font-size: clamp(18px, 5vw, 28px);
    padding: 0 16px;
    gap: 16px;
  }
}

@media (max-width: 560px){
  .hero {
    min-height: calc(100svh - var(--mobile-marquee-height, 72px));
    padding-top: 96px;
    padding-bottom: 16px;
  }
  .hero-grid {
    min-height: calc(100svh - var(--mobile-marquee-height, 72px) - 112px);
  }
  .hero-grid > :first-child {
    min-height: calc(100svh - var(--mobile-marquee-height, 72px) - 112px);
    padding-top: clamp(42px, 10vh, 70px);
  }
  .hero-grid {
    gap: 18px;
  }
  .eyebrow {
    gap: 10px;
    row-gap: 6px;
    margin-bottom: 18px;
    font-size: 11px;
    letter-spacing: .06em;
  }
  .eyebrow > span:not(.av):nth-child(2n) {
    display: none;
  }
  .hero-name-row {
    grid-template-columns: minmax(0, 1fr) 68px;
    gap: 12px;
  }
  .hero-name {
    font-size: clamp(44px, 18vw, 72px);
    max-width: 5.8ch;
  }
  .hero-mobile-avatar {
    width: 68px;
    height: 68px;
  }
  .hero-roles {
    min-height: 3.1em;
    font-size: 12px;
    margin: 16px 0 12px;
  }
  .hero-desc {
    font-size: 14px;
    margin-bottom: 0;
  }
  .hero-cta {
    gap: 8px;
    padding-top: 20px;
  }
  .hero-cta .btn {
    font-size: 11.5px;
    padding: 14px 10px;
  }
  .hero + .marquee {
    padding: 14px 0;
  }
  .hero + .marquee .marquee-track .item {
    font-size: clamp(17px, 5.4vw, 24px);
    padding: 0 12px;
    gap: 12px;
  }
}
.portrait .cap { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); margin-top: 26px; letter-spacing: .08em; text-transform: uppercase; }
.portrait .cap .accent { color: var(--accent); }

/* ---------- live ops monitor ---------- */
.monitor { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--paper-2); position: relative; z-index: 2; }
.mon-head { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.mon-head .k { font-family: var(--font-mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.mon-head .k .no { color: var(--accent); }
.mon-head h2 { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px,3.4vw,46px); letter-spacing: -.025em; line-height: 1; }
.mon-head .ln { flex: 1; height: 1px; background: var(--line); min-width: 30px; }
.mon-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 18px; }
@media (max-width: 920px){ .mon-grid { grid-template-columns: 1fr; } }
.mon-card { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 20px 22px; position: relative; }
.mon-card .lab { display: flex; justify-content: space-between; align-items: center; font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 14px; }
.mon-card .lab .live { color: var(--accent); }
.mon-spark { width: 100%; height: 180px; display: block; }
.mon-spark-foot { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); margin-top: 10px; }
.mon-spark-foot b { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--ink); letter-spacing: -.02em; }
.mon-spark-foot .accent { color: var(--accent); }
.mon-right { display: grid; gap: 18px; }
.mon-meters { display: grid; gap: 16px; }
.mon-meter { }
.mon-meter .top { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); margin-bottom: 7px; }
.mon-meter .top .v { color: var(--ink); font-weight: 500; }
.mon-meter .bar { height: 6px; background: var(--paper-2); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; }
.mon-meter .bar i { display: block; height: 100%; width: 40%; background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 60%, #fff)); border-radius: 20px; }
.mon-logwrap { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 16px 18px; }
.mon-logwrap .lab { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 10px; }
.mon-log { font-family: var(--font-mono); font-size: 12px; line-height: 1.85; color: var(--ink-2); max-height: 168px; overflow: hidden; }
.mon-logrow .ts { color: var(--ink-3); margin-right: 8px; }
.mon-logrow .ok { color: var(--accent); font-weight: 600; }

/* ---------- github activity ---------- */
.gh-grid { display: grid; grid-template-columns: 320px 1fr; gap: 24px; align-items: start; }
@media (max-width: 940px){ .gh-grid { grid-template-columns: 1fr; } }
.gh-side { display: grid; gap: 18px; }
.gh-profile { display: flex; align-items: center; gap: 14px; border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 16px 18px; position: relative; }
.gh-avatar { width: 52px; height: 52px; border-radius: 50%; overflow: hidden; flex: none; background: var(--paper-2); display: grid; place-items: center; font-family: var(--font-mono); color: var(--accent); border: 1px solid var(--line-2); }
.gh-avatar img { width: 100%; height: 100%; object-fit: cover; }
.gh-name { font-family: var(--font-display); font-weight: 700; font-size: 19px; letter-spacing: -.01em; }
.gh-handle { font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-3); margin-top: 3px; }
.gh-go { margin-left: auto; font-family: var(--font-mono); color: var(--ink-3); transition: transform .25s var(--ease-out), color .25s; }
.gh-profile:hover .gh-go { color: var(--accent); transform: translate(3px,-3px); }
.gh-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.gh-stat { background: var(--surface); padding: 18px 16px; transition: background .3s; }
.gh-stat:hover { background: var(--paper-2); }
.gh-stat b { font-family: var(--font-display); font-weight: 700; font-size: 30px; letter-spacing: -.02em; display: block; line-height: 1; }
.gh-stat span { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; color: var(--ink-3); margin-top: 7px; display: block; }
.gh-langs { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 18px; }
.gh-langs-h { font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; color: var(--ink-3); margin-bottom: 12px; }
.gh-langbar { display: flex; height: 9px; border-radius: 20px; overflow: hidden; background: var(--line); gap: 2px; }
.gh-langbar span { display: block; height: 100%; }
.gh-langlist { display: flex; flex-wrap: wrap; gap: 10px 16px; margin-top: 14px; }
.gh-langtag { font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 7px; }
.gh-langtag i { width: 9px; height: 9px; border-radius: 50%; }
.gh-langtag em { color: var(--ink-3); font-style: normal; }
.gh-main { display: grid; gap: 18px; }
.gh-cal-card { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 20px 22px; }
.gh-cal-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; color: var(--ink-3); margin-bottom: 16px; }
.gh-contrib { display: flex; align-items: baseline; gap: 14px; }
.gh-contrib b { font-family: var(--font-display); font-weight: 700; font-size: clamp(40px,5.5vw,72px); letter-spacing: -.03em; line-height: .9; color: var(--accent); }
.gh-contrib span { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); line-height: 1.35; }
.gh-legend { display: inline-flex; align-items: center; gap: 4px; }
.gh-legend i { width: 11px; height: 11px; border-radius: var(--radius); display: inline-block; }
.gh-cal-scroll { overflow-x: auto; padding-bottom: 6px; }
.gh-cal-scroll::-webkit-scrollbar { height: 6px; } .gh-cal-scroll::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 20px; }
.gh-months { display: grid; grid-template-columns: repeat(53, 13px); column-gap: 3px; font-family: var(--font-mono); font-size: 10px; color: var(--ink-3); margin-bottom: 5px; min-width: 760px; }
.gh-months span { grid-row: 1; white-space: nowrap; }
.gh-cal-grid { display: grid; grid-template-rows: repeat(7, 13px); grid-auto-flow: column; grid-auto-columns: 13px; gap: 3px; min-width: 760px; }
.gh-cell { width: 13px; height: 13px; border-radius: var(--radius); transition: transform .15s var(--ease-out); }
.gh-cell:hover { transform: scale(1.35); outline: 1px solid var(--accent); }
.gh-loading { font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.gh-repos { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 620px){ .gh-repos { grid-template-columns: 1fr; } }
.gh-repo { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 18px 20px; display: flex; flex-direction: column; transition: border-color .3s, transform .3s var(--ease-out), box-shadow .3s; }
.gh-repo:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: var(--shadow); }
.gh-repo-top { display: flex; justify-content: space-between; align-items: center; }
.gh-repo-name { font-family: var(--font-mono); font-size: 15px; font-weight: 500; color: var(--accent); }
.gh-repo-go { font-family: var(--font-mono); color: var(--ink-3); transition: transform .25s var(--ease-out); }
.gh-repo:hover .gh-repo-go { transform: translate(3px,-3px); color: var(--accent); }
.gh-repo-desc { color: var(--ink-2); font-size: 13.5px; line-height: 1.55; margin: 10px 0 16px; flex: 1; }
.gh-repo-foot { display: flex; gap: 16px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.gh-repo-lang { display: inline-flex; align-items: center; gap: 6px; }
.gh-repo-lang i { width: 9px; height: 9px; border-radius: 50%; }
.gh-repo-cta { justify-content: center; text-align: center; border-style: dashed; }
.gh-tip { position: fixed; z-index: 9500; transform: translate(-50%, -130%); background: var(--ink); color: var(--paper); font-family: var(--font-mono); font-size: 11px; padding: 6px 10px; border-radius: 4px; pointer-events: none; white-space: nowrap; box-shadow: var(--shadow); }

/* github focus redesign */
.gh-band { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.gh-status { display: inline-flex; align-items: center; gap: 8px; }
.gh-status i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); }
.gh-status i.ok { background: #25b06a; }
.gh-statrow { display: grid; grid-template-columns: repeat(3,1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 4px; overflow: hidden; margin-bottom: 18px; }
@media (max-width: 720px){ .gh-statrow { grid-template-columns: 1fr; } }
.gh-bigstat { background: var(--surface); padding: 26px 26px; transition: background .3s; }
.gh-bigstat:hover { background: var(--paper); }
.gh-bigstat b { font-family: var(--font-display); font-weight: 700; font-size: clamp(36px,4.4vw,56px); letter-spacing: -.03em; line-height: 1; display: block; }
.gh-bigstat .l { font-family: var(--font-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink); margin-top: 12px; display: block; }
.gh-bigstat .s { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); margin-top: 4px; display: block; }
.gh-pin-head { display: flex; justify-content: space-between; align-items: center; margin: 30px 0 16px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .16em; color: var(--ink-3); }
.gh-pin-head a { color: var(--accent); transition: opacity .2s; }
.gh-pin-head a:hover { opacity: .7; }
.gh-featured { display: block; border: 1px solid var(--line-2); border-left: 3px solid var(--accent); border-radius: var(--radius); background: var(--surface); padding: 30px 32px; margin-bottom: 14px; transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out), border-color .3s; }
.gh-featured:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.gh-feat-tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: .18em; color: var(--accent); }
.gh-featured h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px,3.4vw,44px); letter-spacing: -.02em; margin: 12px 0 14px; }
.gh-featured p { color: var(--ink-2); font-size: 16px; line-height: 1.66; max-width: 72ch; }
.gh-feat-foot { display: flex; align-items: center; gap: 22px; margin-top: 22px; font-family: var(--font-mono); font-size: 13px; color: var(--ink-3); }
.gh-feat-open { margin-left: auto; color: var(--accent); transition: transform .25s var(--ease-out); }
.gh-featured:hover .gh-feat-open { transform: translateX(4px); }
.gh-pingrid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
@media (max-width: 860px){ .gh-pingrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px){ .gh-pingrid { grid-template-columns: 1fr; } }
.gh-pin { border: 1px solid var(--line); background: var(--surface); border-radius: 4px; padding: 20px 22px; display: flex; flex-direction: column; transition: border-color .3s, transform .3s var(--ease-out), box-shadow .3s; }
.gh-pin:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: var(--shadow); }
.gh-pin-top { display: flex; align-items: center; gap: 9px; }
.gh-pin-ic { color: var(--ink-3); font-size: 13px; }
.gh-pin-name { font-family: var(--font-mono); font-size: 15px; font-weight: 500; color: var(--accent); }
.gh-pin-go { margin-left: auto; font-family: var(--font-mono); color: var(--ink-3); transition: transform .25s var(--ease-out), color .25s; }
.gh-pin:hover .gh-pin-go { transform: translate(3px,-3px); color: var(--accent); }
.gh-pin-desc { color: var(--ink-2); font-size: 13.5px; line-height: 1.6; margin: 12px 0 16px; flex: 1; }
.gh-pin-foot { display: flex; gap: 16px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.gh-langs { border: 1px solid var(--line); background: var(--surface); border-radius: 4px; padding: 22px 24px; margin-top: 16px; }

/* ---------- marquee ---------- */
.marquee { overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 26px 0; white-space: nowrap; background: var(--paper-2); position: relative; z-index: 2; }
.marquee-track { display: inline-flex; will-change: transform; }
.marquee-track .item { font-family: var(--font-display); font-weight: 600; font-size: clamp(24px,3.4vw,46px); letter-spacing: -.02em; padding: 0 30px; display: inline-flex; align-items: center; gap: 30px; }
.marquee-track .item::after { content: "／"; color: var(--accent); font-weight: 400; font-size: .7em; }
.marquee-track .item.gh { color: transparent; -webkit-text-stroke: 1px var(--line-2); }

/* ---------- profile / about ---------- */
.profile-shell { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(300px, .88fr); gap: clamp(24px,3.5vw,44px); align-items: start; }
@media (max-width: 980px){ .profile-shell { grid-template-columns: 1fr; } }
.profile-main { display: grid; gap: 18px; }
.profile-stage { position: relative; padding: clamp(26px,4vw,44px); min-height: 430px; border: 1px solid var(--line); border-radius: 28px; overflow: hidden; background:
  radial-gradient(140% 160% at 0% 0%, color-mix(in srgb, var(--accent-soft) 74%, transparent), transparent 34%),
  linear-gradient(180deg, color-mix(in srgb, var(--surface) 98%, white 2%), var(--surface));
  box-shadow: var(--shadow); }
.profile-stage::before { content: ""; position: absolute; inset: 0; pointer-events: none; background:
  linear-gradient(rgba(0,0,0,.03) 1px, transparent 1px),
  linear-gradient(90deg, rgba(0,0,0,.03) 1px, transparent 1px); background-size: 32px 32px; opacity: .38; }
.profile-stage::after { content: "01"; position: absolute; right: clamp(18px,3vw,28px); top: clamp(18px,3vw,28px); font-family: var(--font-display); font-weight: 700; font-size: clamp(70px,11vw,140px); line-height: .8; color: transparent; -webkit-text-stroke: 1px var(--line); pointer-events: none; }
.profile-stage > * { position: relative; z-index: 1; }
.profile-kicker, .profile-card-top, .profile-principle .nlab, .profile-strip span { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .16em; }
.profile-kicker { color: var(--ink-3); }
.profile-super { font-family: var(--font-display); font-weight: 700; font-size: clamp(44px,8vw,112px); line-height: .88; letter-spacing: -.05em; margin-top: clamp(22px,4vw,40px); max-width: 7ch; }
.profile-lead { font-family: var(--font-display); font-weight: 500; font-size: clamp(22px,2.7vw,34px); line-height: 1.12; letter-spacing: -.03em; max-width: 18ch; margin-top: 20px; }
.profile-lead .accent { color: var(--accent); font-style: italic; }
.profile-body { color: var(--ink-2); font-size: 16px; line-height: 1.76; margin-top: 18px; max-width: 40ch; }
.profile-body.short { max-width: 38ch; }
.profile-strip { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.profile-strip span { padding: 10px 13px; border-radius: 999px; border: 1px solid var(--line); background: color-mix(in srgb, var(--paper-2) 86%, white 14%); color: var(--ink-2); }
.profile-principle { border-top: 1px solid var(--line); padding-top: 16px; max-width: 34ch; }
.profile-principle .nlab { color: var(--accent); display: block; margin-bottom: 10px; }
.profile-principle p { font-family: var(--font-display); font-size: clamp(19px,2.2vw,26px); line-height: 1.4; letter-spacing: -.015em; }
.profile-side { display: grid; gap: 16px; }
.profile-matrix { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.profile-cell, .profile-bio-card { position: relative; border: 1px solid var(--line); border-radius: 22px; padding: 22px 22px 20px; background:
  linear-gradient(180deg, color-mix(in srgb, var(--surface) 98%, white 2%), var(--surface)); box-shadow: var(--shadow); overflow: hidden; }
.profile-cell::before, .profile-bio-card::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(155deg, color-mix(in srgb, var(--accent-soft) 62%, transparent), transparent 38%); opacity: .72; }
.profile-cell > *, .profile-bio-card > * { position: relative; z-index: 1; }
.profile-cell h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px,3vw,40px); line-height: .95; letter-spacing: -.03em; }
.profile-cell p { margin-top: 12px; color: var(--ink-2); font-size: 14px; line-height: 1.65; max-width: 18ch; }
.profile-bio-grid { display: grid; gap: 14px; margin-top: 4px; }
.profile-bio-grid .mrow { display: grid; gap: 4px; padding-top: 12px; border-top: 1px solid var(--line); }
.profile-bio-grid .mrow:first-child { padding-top: 0; border-top: 0; }
.profile-bio-grid span { font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: .16em; color: var(--ink-3); }
.profile-bio-grid strong { font-size: 15px; line-height: 1.55; }
@media (max-width: 640px){
  .profile-stage, .profile-cell, .profile-bio-card { border-radius: 18px; }
  .profile-stage { min-height: auto; padding: 22px 20px 24px; }
  .profile-matrix { grid-template-columns: 1fr; }
}

/* stats strip */
.stats { display: grid; grid-template-columns: repeat(4,1fr); border: 1px solid var(--line); margin-top: 0; }
@media (max-width: 720px){ .stats { grid-template-columns: repeat(2,1fr); } }
.stats-profile { gap: 1px; background: var(--line); border-radius: 22px; overflow: hidden; border-color: var(--line); }
.stats .st { position: relative; padding: 28px 26px; border-right: 1px solid var(--line); }
.stats .st:last-child { border-right: 0; }
@media (max-width: 720px){ .stats .st:nth-child(2n){ border-right: 0; } .stats .st:nth-child(-n+2){ border-bottom: 1px solid var(--line); } }
.stats-profile .st { background:
  linear-gradient(180deg, color-mix(in srgb, var(--surface) 98%, white 2%), var(--surface)); border-right: 0; }
.stats-profile .st .topline { width: 42px; height: 2px; background: var(--accent); margin-bottom: 18px; opacity: .8; }
.stats .st .v { font-family: var(--font-display); font-weight: 600; font-size: clamp(30px,3.8vw,48px); letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.stats .st .v small { font-size: .5em; color: var(--accent); }
.stats .st .l { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-3); margin-top: 12px; }

/* ---------- skills horizontal ---------- */
.skills { position: relative; }
.skills-sticky { position: sticky; top: 0; height: 100svh; overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
.skills-head { position: absolute; top: clamp(86px,11vw,120px); left: 0; right: 0; }
.skills-head .meta { display: flex; align-items: center; gap: 16px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.skills-head .meta .no { color: var(--accent); } .skills-head .meta .ln { flex: 1; height: 1px; background: var(--line); }
.skills-track { display: flex; align-items: center; gap: clamp(40px,6vw,110px); will-change: transform; padding: 0 var(--gutter); }
.skill-panel { flex: none; width: min(620px, 80vw); }
.skill-panel .pn { font-family: var(--font-mono); font-size: 13px; color: var(--accent); letter-spacing: .08em; }
.skill-panel h3 { font-family: var(--font-display); font-weight: 600; font-size: clamp(36px,5vw,72px); line-height: 1; letter-spacing: -.04em; margin: 12px 0 6px; }
.skill-panel .cmd { font-family: var(--font-mono); font-size: 13px; color: var(--ink-3); margin-bottom: 28px; }
.skill-panel .cmd::before { content: "$ "; color: var(--accent); }
.skill-panel .items { display: flex; flex-wrap: wrap; gap: 11px; max-width: 560px; }
.skill-panel .items .chip { font-size: 14px; padding: 11px 17px; }
.skills-foot { position: absolute; bottom: 7%; left: var(--gutter); right: var(--gutter); display: flex; align-items: center; gap: 16px; font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); }
.skills-foot .track { flex: 1; max-width: 240px; height: 2px; background: var(--line); position: relative; }
.skills-foot .track i { position: absolute; inset: 0; background: var(--accent); transform: scaleX(0); transform-origin: left; }

/* ---------- work (sticky-stacking panels) ---------- */
.work-head { padding-top: clamp(80px,11vw,170px); }
.work-stack { position: relative; }
.work-panel { position: relative; display: flex; align-items: center; padding: clamp(56px,8vw,96px) 0; }
.work-panel .pcard { position: relative; width: 100%; }
/* stack only where the panel provably fits the viewport */
@media (min-width: 981px) and (min-height: 700px) {
  .work-panel { position: sticky; top: 0; min-height: 100svh; padding: 0; }
  .work-panel .pcard { will-change: transform, opacity; }
}
.work-panel .prow { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px,4vw,72px); align-items: center; }
@media (max-width: 880px){ .work-panel .prow { grid-template-columns: 1fr; gap: 26px; } .work-panel .prow .wv { order: -1; } }
.work-panel.flip .prow .wv { order: 2; }
@media (max-width: 880px){ .work-panel.flip .prow .wv { order: -1; } }
.work-edge { position: absolute; top: 0; left: 0; right: 0; height: 1px; background: var(--line-2); }
.work-panel .pcard::before { content: none; position: absolute; top: clamp(20px,5vw,56px); right: var(--gutter); font-family: var(--font-display); font-weight: 700; font-size: clamp(96px,15vw,220px); line-height: .7; color: transparent; -webkit-text-stroke: 1px var(--line); pointer-events: none; z-index: 0; }
.work-panel .prow { position: relative; z-index: 1; }
.wv { position: relative; aspect-ratio: 4 / 3.4; border: 1px solid var(--line-2); overflow: hidden; background: var(--surface); border-radius: var(--radius); }
.wv .browser { position: absolute; inset: clamp(12px,1.6vw,20px); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--paper); display: flex; flex-direction: column; box-shadow: var(--shadow); }
.wv .bbar { height: 32px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 6px; padding: 0 12px; background: var(--paper-2); flex: none; }
.wv .bbar i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }
.wv .bbar .url { margin-left: 10px; font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-3); }
.wv .bcanvas { flex: 1; position: relative; display: grid; place-items: center; overflow: hidden;
  background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 16px 16px; }
.wv .bcanvas image-slot { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.wv .bcanvas .reel-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.wv .bcanvas .big { font-family: var(--font-display); font-weight: 700; font-size: clamp(40px,7vw,86px); letter-spacing: -.03em; color: var(--accent); opacity: .92; will-change: transform; }

/* open-source grid inside Work */
.gh-more { margin-top: clamp(40px,6vw,80px); }
.gh-more-head { display: flex; justify-content: space-between; align-items: center; font-family: var(--font-mono); font-size: 12px; letter-spacing: .14em; color: var(--ink-3); margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.gh-more-head a { color: var(--accent); transition: opacity .2s; }
.gh-more-head a:hover { opacity: .7; }
.gh-more-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
@media (max-width: 860px){ .gh-more-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px){ .gh-more-grid { grid-template-columns: 1fr; } }
.ghp-card { border: 1px solid var(--line); background: var(--surface); border-radius: 4px; padding: 22px 24px; display: flex; flex-direction: column; transition: border-color .3s, transform .3s var(--ease-out), box-shadow .3s; }
.ghp-card:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: var(--shadow); }
.ghp-top { display: flex; align-items: center; gap: 10px; }
.ghp-name { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: -.01em; }
.ghp-lang { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); padding: 3px 8px; border: 1px solid var(--line); border-radius: 20px; }
.ghp-go { margin-left: auto; font-family: var(--font-mono); color: var(--ink-3); transition: transform .25s var(--ease-out), color .25s; }
.ghp-card:hover .ghp-go { transform: translate(3px,-3px); color: var(--accent); }
.ghp-tag { font-family: var(--font-mono); font-size: 12.5px; color: var(--accent); margin-top: 8px; }
.ghp-desc { color: var(--ink-2); font-size: 13.5px; line-height: 1.6; margin: 12px 0 16px; flex: 1; }
.ghp-foot { display: flex; flex-wrap: wrap; gap: 7px; }
.ghp-foot .chip { font-size: 11px; padding: 5px 10px; }
.wv .tagline { flex: none; border-top: 1px solid var(--line); padding: 8px 14px; background: var(--surface); font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .05em; }
.wi .idx { font-family: var(--font-mono); font-size: 13px; color: var(--accent); letter-spacing: .08em; }
.wi .meta { display: flex; gap: 16px; align-items: center; margin: 14px 0 10px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.wi h3 { font-family: var(--font-display); font-weight: 600; font-size: clamp(30px,3.8vw,52px); line-height: 1.02; letter-spacing: -.035em; }
.wi .ptag { font-family: var(--font-mono); font-size: 13px; color: var(--accent); margin-top: 10px; }
.wi .blurb { color: var(--ink-2); font-size: 15.5px; line-height: 1.7; margin-top: 18px; max-width: 50ch; }
.wi .hl { list-style: none; margin: 18px 0 0; display: grid; gap: 8px; }
.wi .hl li { font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-2); display: flex; gap: 10px; }
.wi .hl li::before { content: "—"; color: var(--accent); }
.wi .foot { margin-top: 24px; display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.wi .stack { display: flex; flex-wrap: wrap; gap: 7px; max-width: 78%; }
.wi .open { font-family: var(--font-mono); font-size: 13px; color: var(--accent); display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; border-bottom: 1px solid transparent; transition: border-color .25s; }
.wi .open:hover { border-color: var(--accent); }

/* ---------- tech graph / network ---------- */
.net-grid { display: grid; grid-template-columns: 1fr 320px; gap: 24px; align-items: stretch; margin-top: 8px; }
@media (max-width: 920px){ .net-grid { grid-template-columns: 1fr; } }
.net-wrap { position: relative; height: min(620px, 74vh); border: 1px solid var(--line); background:
  radial-gradient(120% 120% at 50% 0%, var(--surface), var(--paper)); border-radius: var(--radius); overflow: hidden; }
.net-wrap::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 22px 22px; opacity: .6; }
.net-canvas { position: relative; display: block; width: 100%; height: 100%; touch-action: pan-y; }
.net-panel { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; }
@media (max-width: 920px){ .net-panel { min-height: 220px; } }
.net-panel .k { font-family: var(--font-mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3); }
.net-panel h4 { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px,3vw,38px); letter-spacing: -.02em; line-height: 1; margin-top: 10px; }
.net-panel .cnt { font-family: var(--font-mono); font-size: 13px; color: var(--ink-2); margin-top: 12px; }
.net-panel .cnt .accent { font-size: 16px; font-weight: 600; }
.net-detail ul { list-style: none; margin-top: 16px; display: grid; gap: 2px; }
.net-detail ul li a { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-top: 1px solid var(--line); font-family: var(--font-mono); font-size: 13.5px; color: var(--ink); transition: color var(--dur-micro) var(--ease), transform var(--dur-micro) var(--ease-out); }
.net-detail ul li a:hover { color: var(--accent); transform: translateX(5px); }
.net-detail ul li a .live i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); display: block; }
.net-detail ul li a .ar { margin-left: auto; color: var(--ink-3); }
.net-detail ul li a:hover .ar { color: var(--accent); }
.net-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.net-default { display: flex; flex-direction: column; height: 100%; }
.net-default p { color: var(--ink-2); font-size: 15px; line-height: 1.65; margin-top: 14px; }
.net-default p b { color: var(--ink); } .net-default p .accent { font-weight: 600; }
.net-legend { margin-top: auto; padding-top: 18px; display: grid; gap: 11px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); }
.net-legend span { display: inline-flex; align-items: center; gap: 10px; }
.net-legend i { width: 13px; height: 13px; border-radius: 50%; flex: none; }
.net-legend .lp { background: var(--accent); }
.net-legend .lt { background: var(--surface); border: 1.4px solid var(--ink-3); }
.net-legend .ls { background: #1f9d57; }

/* enhanced graph: stat bar, legend buttons, tooltip */
.net-statbar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 18px; }
@media (max-width: 620px){ .net-statbar { grid-template-columns: repeat(2,1fr); } }
.net-st { background: var(--surface); padding: 16px 18px; transition: background .3s; }
.net-st:hover { background: var(--paper-2); }
.net-st b { font-family: var(--font-display); font-weight: 700; font-size: 26px; letter-spacing: -.02em; display: block; line-height: 1; }
.net-st span { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin-top: 8px; display: block; }
.net-legend { display: flex; flex-direction: column; gap: 9px; margin-top: auto; padding-top: 18px; }
.net-leg { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-2); background: transparent; border: 1px solid transparent; border-radius: var(--radius); padding: 7px 9px; text-align: left; cursor: pointer; transition: background .25s, border-color .25s, color .25s, transform .25s var(--ease-out); }
.net-leg i { width: 12px; height: 12px; border-radius: var(--radius); flex: none; transition: transform .25s var(--ease-out); }
.net-leg:hover { border-color: var(--line-2); transform: translateX(3px); }
.net-leg:hover i { transform: scale(1.2); }
.net-leg.on { background: var(--accent-soft); border-color: var(--accent); color: var(--ink); }
.net-leg.static { cursor: default; color: var(--ink-3); padding-top: 12px; }
.net-tip { position: fixed; z-index: 9500; transform: translate(-50%, calc(-100% - 18px)); background: var(--ink); color: var(--paper); padding: 8px 12px; border-radius: var(--radius); pointer-events: none; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 2px; }
.net-tip b { font-family: var(--font-mono); font-size: 12.5px; font-weight: 600; }
.net-tip span { font-family: var(--font-mono); font-size: 10.5px; opacity: .7; }

.tl::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 1px; background: var(--line-2); }
.tl-fill { position: absolute; left: 8px; top: 6px; bottom: 6px; width: 1px; background: var(--accent); transform: scaleY(0); transform-origin: top; }
.tl-item { position: relative; padding-bottom: 52px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item .node { position: absolute; left: -40px; top: 2px; width: 17px; height: 17px; border-radius: 50%; background: var(--paper); border: 2px solid var(--accent); display: grid; place-items: center; }
.tl-item .node::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
.tl-item .per { font-family: var(--font-mono); font-size: 12px; color: var(--accent); letter-spacing: .04em; }
.tl-item .ro { font-family: var(--font-display); font-weight: 700; font-size: clamp(21px,2.6vw,32px); margin-top: 8px; letter-spacing: -.02em; line-height: 1.05; }
.tl-item .or { font-family: var(--font-mono); font-size: 13px; color: var(--ink-2); margin-top: 6px; }
.tl-item .pl { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
.tl-item .de { color: var(--ink-2); font-size: 15.5px; line-height: 1.65; margin-top: 12px; max-width: 60ch; }

/* ---------- credentials ---------- */
.creds { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; }
.creds.creds-2 { grid-template-columns: 1fr 1fr; max-width: 920px; }
@media (max-width: 760px){ .creds, .creds.creds-2 { grid-template-columns: 1fr; } }

/* ---------- showreel band ---------- */
.reel-band { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.reel-frame { border: 1px solid var(--line-2); border-radius: var(--radius); overflow: hidden; background: #0c0b08; box-shadow: var(--shadow); }
.reel-bar { height: 44px; display: flex; align-items: center; gap: 8px; padding: 0 16px; background: #16140f; border-bottom: 1px solid rgba(255,255,255,.08); }
.reel-bar .reel-name { font-family: var(--font-mono); font-size: 12px; letter-spacing: .18em; color: #8a8276; }
.reel-bar .reel-full { margin-left: auto; font-family: var(--font-mono); font-size: 12px; color: #a8a193; border: 1px solid rgba(255,255,255,.16); padding: 6px 12px; border-radius: var(--radius); transition: color .25s, border-color .25s; }
.reel-bar .reel-full:hover { color: var(--accent); border-color: var(--accent); }
.reel-screen { position: relative; aspect-ratio: 16 / 9; background: #0c0b08; overflow: hidden; }
.reel-screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.reel-screen video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; background: #000; cursor: pointer; }
.reel-ph { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; color: #6d6757; font-family: var(--font-mono); font-size: 12px; letter-spacing: .12em; }
.reel-ph .play { width: 64px; height: 64px; border-radius: 50%; border: 1px solid rgba(255,255,255,.2); display: grid; place-items: center; color: var(--accent); }

/* video player controls & sound on/off */
.reel-bar-controls { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.reel-sound-btn {
  appearance: none; background: rgba(255,255,255,.07); color: #dedad0;
  border: 1px solid rgba(255,255,255,.18); border-radius: var(--radius);
  padding: 6px 13px; font-family: var(--font-mono); font-size: 11.5px;
  letter-spacing: .06em; display: inline-flex; align-items: center; gap: 7px;
  cursor: pointer; transition: all .2s var(--ease-out);
}
.reel-sound-btn:hover { border-color: var(--accent); color: #fff; background: rgba(43,80,226,.2); }
.reel-sound-btn.active {
  background: var(--accent); border-color: var(--accent); color: #fff;
  box-shadow: 0 0 14px rgba(43,80,226,.45);
}
.reel-play-btn {
  appearance: none; background: transparent; color: #dedad0;
  border: 1px solid rgba(255,255,255,.18); border-radius: var(--radius);
  padding: 6px 12px; font-family: var(--font-mono); font-size: 11.5px;
  cursor: pointer; transition: all .2s;
}
.reel-play-btn:hover { border-color: var(--accent); color: #fff; }
.reel-float-sound {
  position: absolute; top: 16px; right: 16px; z-index: 10;
  background: rgba(12,11,8,.85); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.22); border-radius: 999px;
  padding: 8px 16px; color: #f4f1ea; font-family: var(--font-mono);
  font-size: 11.5px; letter-spacing: .08em; display: inline-flex; align-items: center;
  gap: 8px; cursor: pointer; transition: all .22s var(--ease-out);
  box-shadow: 0 6px 20px rgba(0,0,0,.45);
}
.reel-float-sound:hover { transform: scale(1.04); border-color: var(--accent); color: #fff; }
.reel-float-sound.muted { border-color: rgba(255,255,255,.3); background: rgba(18,17,14,.9); }
.reel-float-sound.unmuted { border-color: var(--accent); background: rgba(43,80,226,.45); color: #fff; }
.reel-scrub-wrap {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 24px 18px 12px;
  background: linear-gradient(0deg, rgba(0,0,0,.85) 0%, rgba(0,0,0,.4) 60%, transparent 100%);
  display: flex; align-items: center; gap: 14px; z-index: 8;
  opacity: 0.92; transition: opacity .25s;
}
.reel-screen:hover .reel-scrub-wrap { opacity: 1; }
.reel-scrub-bar {
  flex: 1; height: 5px; background: rgba(255,255,255,.25); border-radius: 999px;
  cursor: pointer; position: relative; overflow: hidden;
}
.reel-scrub-bar:hover { height: 7px; }
.reel-scrub-fill { height: 100%; background: var(--accent); border-radius: 999px; }
.reel-time-badge { font-family: var(--font-mono); font-size: 11px; color: #a8a193; flex: none; }
@media (max-width: 900px){ .creds { grid-template-columns: 1fr; } }
.col-head { font-family: var(--font-mono); font-size: 12px; color: var(--accent); letter-spacing: .14em; text-transform: uppercase; margin-bottom: 18px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.icard { border-bottom: 1px solid var(--line); padding: 18px 0; transition: transform var(--dur-micro) var(--ease-out); }
.icard:hover { transform: translateX(6px); }
.icard h4 { font-family: var(--font-display); font-weight: 600; font-size: 18px; letter-spacing: -.01em; line-height: 1.25; }
.icard .org { font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-2); margin-top: 6px; }
.icard .sub { display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); flex-wrap: wrap; }
.icard .sub .gpa { color: var(--accent); }

/* ---------- console ---------- */
.console-wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(30px,5vw,64px); align-items: center; }
@media (max-width: 920px){ .console-wrap { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- cv ---------- */
.cv-shell { display: grid; grid-template-columns: minmax(280px, .78fr) minmax(0, 1.22fr); gap: clamp(24px,4vw,52px); align-items: start; }
@media (max-width: 980px){ .cv-shell { grid-template-columns: 1fr; } }
.cv-copy { position: sticky; top: 110px; }
@media (max-width: 980px){ .cv-copy { position: static; } }
.cv-kicker, .cv-state-k, .cv-meta span, .cv-preview-bar, .cv-inline-link {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.cv-kicker { color: var(--accent); }
.cv-copy h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(34px, 5vw, 62px);
  line-height: .96;
  letter-spacing: -.04em;
  margin: 16px 0 14px;
  max-width: 10ch;
}
.cv-copy p {
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.75;
  max-width: 36ch;
}
.cv-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}
.cv-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}
.cv-meta span {
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper-2) 82%, white 18%);
  color: var(--ink-2);
}
.cv-preview-card {
  border: 1px solid var(--line-2);
  background: var(--surface);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.cv-preview-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--paper-2);
  color: var(--ink-3);
}
.cv-inline-link {
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.cv-preview {
  position: relative;
  min-height: clamp(420px, 78vh, 920px);
  background:
    linear-gradient(rgba(0,0,0,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,.03) 1px, transparent 1px),
    linear-gradient(180deg, color-mix(in srgb, var(--paper) 80%, white 20%), color-mix(in srgb, var(--surface) 96%, white 4%));
  background-size: 28px 28px, 28px 28px, auto;
}
.cv-preview iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
  opacity: 1;
  transition: opacity .35s var(--ease);
}
.cv-preview.ready iframe { opacity: 1; }
.cv-preview-state {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 10px;
  padding: 28px;
  text-align: center;
}
.cv-preview-state strong {
  font-family: var(--font-display);
  font-size: clamp(24px, 3.6vw, 40px);
  line-height: 1;
  letter-spacing: -.03em;
}
.cv-preview-state p {
  margin: 0 auto;
  max-width: 34ch;
  color: var(--ink-2);
  font-size: 14px;
  line-height: 1.7;
}
.cv-preview-state.fail {
  background: linear-gradient(180deg, color-mix(in srgb, #b74848 8%, var(--surface)), var(--surface));
}

/* ---------- contact ---------- */
.contact { text-align: center; }
.contact .big { font-family: var(--font-display); font-weight: 700; font-size: clamp(54px,13vw,200px); letter-spacing: -.045em; line-height: .86; margin: 10px 0 8px; }
.contact .big .it { font-style: italic; font-weight: 500; color: var(--accent); }
.contact .em { font-family: var(--font-mono); font-size: clamp(15px,2.4vw,24px); color: var(--ink-2); margin-top: 18px; }
.contact .em a { border-bottom: 1px solid var(--line-2); transition: color .25s, border-color .25s; }
.contact .em a:hover { color: var(--accent); border-color: var(--accent); }
.socials { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 40px; }
.soc { font-family: var(--font-mono); font-size: 13px; padding: 14px 24px; border: 1px solid var(--line-2); display: inline-flex; align-items: center; gap: 10px; transition: all .3s; border-radius: var(--radius); }
.soc:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-4px); }
.contact .meta { font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-3); margin-top: 46px; display: flex; gap: 26px; justify-content: center; flex-wrap: wrap; }

/* footer */
.footer { border-top: 1px solid var(--line); padding: 34px 0; }
.footer-in { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.footer-in b { color: var(--ink-2); font-weight: 500; }

/* ---------- terminal (light) ---------- */
.term { font-family: var(--font-mono); border: 1px solid var(--line-2); background: var(--surface); border-radius: 4px; overflow: hidden; box-shadow: var(--shadow); }
.term .winbar { display: flex; align-items: center; gap: 8px; padding: 11px 14px; border-bottom: 1px solid var(--line); background: var(--paper-2); font-size: 12px; color: var(--ink-3); }
.term .winbar .dot { width: 11px; height: 11px; border-radius: 50%; }
.term .winbar .dot.r { background: #ff5f57; } .term .winbar .dot.y { background: #febc2e; } .term .winbar .dot.g { background: #28c840; }
.term .winbar .title { margin-left: 10px; }
.term-body { padding: 16px 18px; height: 300px; overflow-y: auto; font-size: 13px; line-height: 1.7; }
.term-body::-webkit-scrollbar { width: 8px; } .term-body::-webkit-scrollbar-thumb { background: var(--line-2); }
.term-line { white-space: pre-wrap; word-break: break-word; }
.term-line .p { color: var(--accent); } .term-line .u { color: #1f9d57; }
.term-out { color: var(--ink-2); } .term-out a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.term-err { color: #d63a3a; } .term-key { color: var(--ink); font-weight: 500; }
.term-input-row { display: flex; align-items: center; gap: 8px; }
.term-input-row .p { color: var(--accent); white-space: nowrap; }
.term-input { flex: 1; background: transparent; border: 0; outline: 0; color: var(--ink); font-family: var(--font-mono); font-size: 13px; }
.term-hint { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); padding: 10px 14px; border-top: 1px solid var(--line); display: flex; gap: 14px; flex-wrap: wrap; background: var(--paper-2); }
.term-hint b { color: var(--accent); font-weight: 500; }

/* ---------- command palette ---------- */
.cmdk-ov { position: fixed; inset: 0; z-index: 9000; background: color-mix(in srgb, var(--ink) 40%, transparent); backdrop-filter: blur(7px); display: flex; align-items: flex-start; justify-content: center; padding-top: 14vh; opacity: 0; pointer-events: none; transition: opacity .2s; }
.cmdk-ov.open { opacity: 1; pointer-events: auto; }
.cmdk { width: min(560px,92vw); background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow); border-radius: var(--radius); transform: translateY(-12px) scale(.98); transition: transform .2s; overflow: hidden; }
.cmdk-ov.open .cmdk { transform: none; }
.cmdk-s { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.cmdk-s .p { color: var(--accent); font-family: var(--font-mono); }
.cmdk-s input { flex: 1; background: transparent; border: 0; outline: 0; color: var(--ink); font-family: var(--font-mono); font-size: 15px; }
.cmdk-list { max-height: 340px; overflow-y: auto; padding: 8px; }
.cmdk-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; font-family: var(--font-mono); font-size: 14px; color: var(--ink-2); border-radius: 4px; }
.cmdk-item .ic { color: var(--ink-3); width: 18px; text-align: center; }
.cmdk-item .desc { margin-left: auto; font-size: 11px; color: var(--ink-3); }
.cmdk-item.active { background: var(--accent-soft); color: var(--ink); }
.cmdk-foot { padding: 11px 16px; border-top: 1px solid var(--line); font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); display: flex; gap: 16px; }

/* ============================================================
   THEME STUDIO — user-facing colour / appearance picker
============================================================ */
.tstudio { position: relative; }
.tstudio-pop {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 320;
  width: 268px; padding: 16px;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow);
  display: grid; gap: 16px;
  transform-origin: top right;
  /* enter/exit without JS timers: discrete display participates in the transition */
  transition: opacity var(--dur-ui) var(--ease-out),
              transform var(--dur-ui) var(--ease-out),
              display var(--dur-ui) allow-discrete;
}
.tstudio-pop[hidden] { display: none; opacity: 0; transform: translateY(-6px) scale(.97); }
.tstudio-pop { opacity: 1; transform: none; }
@starting-style { .tstudio-pop { opacity: 0; transform: translateY(-6px) scale(.97); } }

.tstudio-grp { display: grid; gap: 9px; }
.tstudio-lbl {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--ink-3);
}
.tstudio-seg { display: grid; grid-auto-flow: column; gap: 4px; padding: 3px;
  background: var(--paper-2); border-radius: 9px; }
.tstudio-seg button {
  appearance: none; border: 0; background: transparent; color: var(--ink-2);
  font-family: var(--font-mono); font-size: 11.5px; padding: 7px 4px;
  border-radius: 6px; cursor: pointer;
  transition: background-color var(--dur-micro) var(--ease), color var(--dur-micro) var(--ease);
}
.tstudio-seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.10); }

.tstudio-swatches { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.tstudio-sw {
  appearance: none; padding: 0; cursor: pointer;
  aspect-ratio: 1; border-radius: 50%;
  border: 2px solid transparent; background: var(--sw);
  box-shadow: 0 0 0 1px var(--line) inset;
  transition: transform var(--dur-micro) var(--ease-out), border-color var(--dur-micro) var(--ease);
}
.tstudio-sw:hover { transform: scale(1.12); }
.tstudio-sw[aria-pressed="true"] { border-color: var(--ink); transform: scale(1.06); }

.tstudio-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-2);
}
.tstudio-switch {
  appearance: none; border: 0; cursor: pointer; flex: none;
  width: 36px; height: 20px; border-radius: 999px; padding: 2px;
  background: var(--line-2);
  transition: background-color var(--dur-micro) var(--ease);
}
.tstudio-switch[aria-pressed="true"] { background: var(--accent); }
.tstudio-switch i {
  display: block; width: 16px; height: 16px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.25);
  transform: translateX(0);
  transition: transform var(--dur-micro) var(--ease-out);
}
.tstudio-switch[aria-pressed="true"] i { transform: translateX(16px); }
.tstudio-note { font-family: var(--font-mono); font-size: 10px; color: var(--ink-3); line-height: 1.5; }

@media (max-width: 480px) {
  .tstudio-pop { position: fixed; right: 12px; left: 12px; top: auto; bottom: 12px; width: auto; }
}

/* marquee — WCAG 2.2.2: >5s of auto motion needs a pause control */
.marquee { position: relative; }
.marquee-pause {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%); z-index: 3;
  appearance: none; cursor: pointer;
  width: 26px; height: 26px; border-radius: 50%;
  border: 1px solid var(--line-2); background: var(--paper);
  color: var(--ink-3); font-size: 9px; line-height: 1;
  opacity: 0;
  transition: opacity var(--dur-micro) var(--ease), color var(--dur-micro) var(--ease), border-color var(--dur-micro) var(--ease);
}
.marquee:hover .marquee-pause, .marquee-pause:focus-visible { opacity: 1; }
.marquee-pause:hover { color: var(--accent); border-color: var(--accent); }

/* ============================================================
   CURSOR RING — a trailing outline that follows the pointer.
   The native cursor stays visible (an invisible pointer is a usability
   trap); this only adds a hover affordance on top of it.
   Position AND scale are written together by the rAF loop as one
   transform, so nothing here animates a layout property.
============================================================ */
.cursor-ring {
  position: fixed; top: 0; left: 0; z-index: 9998;
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border: 1px solid var(--ink-3); border-radius: 50%;
  pointer-events: none; opacity: 0;
  will-change: transform;
  transition: opacity var(--dur-ui) var(--ease),
              border-color var(--dur-micro) var(--ease),
              background-color var(--dur-micro) var(--ease);
}
body.cursor-on .cursor-ring { opacity: .55; }
body.cursor-on .cursor-ring.hot { opacity: 1; border-color: var(--accent); background: var(--accent-soft); }
body.cursor-on .cursor-ring.down { border-color: var(--accent); }

/* coarse pointers and touch never get one */
@media (hover: none), (pointer: coarse) {
  .cursor-ring { display: none; }
}
