/* Bryan Alexander — shared styles */
:root {
  --paper: #F5F5F5;
  --ink: #141414;
  --muted: #5C5A55;
  --faint: #8A8780;
  --rule: rgba(20, 20, 20, 0.12);
  --accent: #B8361C;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; background: var(--paper); color: var(--ink); }
body { font-family: 'IBM Plex Mono', ui-monospace, monospace; -webkit-font-smoothing: antialiased; }
a { color: var(--ink); }
a:hover { color: var(--accent); }
img, video { display: block; }
button { font: inherit; }

.page { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; }

/* fine-print header + footer */
.site-header, .site-footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
  gap: 8px 24px; font-size: 10px; letter-spacing: 0.08em; color: var(--muted);
  position: relative; z-index: 2;
}
.site-header { padding: 16px 28px; }
.site-footer { padding: 16px 28px 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--ink); }
.brand img { width: 40px; height: auto; }
.site-footer a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); }

/* ---------- HOME: the wheel ---------- */
.home-main { position: relative; z-index: 1; flex: 1 1 auto; display: flex; align-items: center; justify-content: center; padding: 0 24px; overflow: hidden; }
.stage { position: relative; flex: 1 1 100%; max-width: 1280px; height: 740px; touch-action: pan-y; }
.wheel-item { position: absolute; left: 50%; top: 50%; width: 460px; max-width: 82vw; will-change: transform; }
.wheel-item > a { display: block; width: 100%; cursor: pointer; }
.wheel-img { width: 100%; height: 400px; object-fit: contain; filter: drop-shadow(0 18px 24px rgba(20,20,20,0.24)); }
.wheel-label { display: flex; justify-content: center; gap: 10px; margin-top: 14px; font-size: 12px; letter-spacing: 0.04em; white-space: nowrap; transition: opacity 200ms; }
.wheel-label .n { color: var(--muted); }
.screenbox { position: absolute; top: 0; left: 50%; transform: translateX(-50%); height: 400px; max-width: 100%; aspect-ratio: 999 / 1245; pointer-events: none; }
.screen { position: absolute; left: 30.53%; top: 29.32%; width: 39.04%; height: 23.29%; overflow: hidden; border-radius: 2px; background: #0B0B0B; box-shadow: inset 0 0 10px rgba(0,0,0,0.75); }
.screen img, .screen video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.glass { position: absolute; inset: 0; background: linear-gradient(125deg, rgba(255,255,255,0.16) 0%, rgba(255,255,255,0.05) 32%, rgba(255,255,255,0) 33%), radial-gradient(ellipse at center, rgba(0,0,0,0) 60%, rgba(0,0,0,0.35) 100%); box-shadow: inset 0 0 0 1px rgba(0,0,0,0.6); }
.turn { position: absolute; right: 0; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 4px; z-index: 400; }
.turn button { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; border: 1px solid rgba(20,20,20,0.25); background: transparent; cursor: pointer; color: var(--ink); }
.turn button:hover { background: var(--ink); color: var(--paper); }

@media (max-width: 719px) {
  .stage { height: 560px; }
  .wheel-item { width: 280px; }
  .wheel-img, .screenbox { height: 250px; }
  .turn { top: auto; bottom: -8px; right: auto; left: 50%; transform: translateX(-50%); flex-direction: row; gap: 8px; }
}

/* ---------- TEXT PAGES (about, archives) ---------- */
.text-main { flex: 1 1 auto; width: 100%; max-width: 1200px; margin: 0 auto; padding: 56px 28px 96px; }
.typed { max-width: 640px; font-family: 'Cutive Mono', 'Courier New', monospace; font-size: 18px; line-height: 1.55; }
.typed ol { margin: 0; padding-left: 2.6em; }
.typed .block { margin-bottom: 36px; }
.typed .label { margin-bottom: 12px; }
.typed a { display: inline-flex; align-items: center; min-height: 44px; }

/* archives */
.filters { display: flex; flex-wrap: wrap; align-items: center; gap: 0 10px; margin-bottom: 24px; }
.filters .sep { color: var(--faint); }
.filters button { min-height: 44px; padding: 0; border: 0; background: transparent; cursor: pointer; font: inherit; color: var(--muted); text-underline-offset: 5px; }
.filters button[aria-pressed="true"] { color: var(--ink); text-decoration: underline; }
.typed .alist, .alist { margin: 0; padding: 0; list-style: none; border-bottom: 1px solid var(--rule); }
.alist li { border-top: 1px solid var(--rule); transition: opacity 220ms ease; }
.alist li.dim { opacity: 0.22; }
.entry { display: flex; width: 100%; align-items: baseline; justify-content: space-between; gap: 16px; min-height: 44px; padding: 6px 0; border: 0; background: transparent; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.entry:hover .ttl { text-decoration: underline; text-underline-offset: 4px; }
.entry:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; }
.entry .left { display: flex; gap: 14px; min-width: 0; }
.entry .num { color: var(--faint); }
.entry .meta { display: flex; flex-direction: column; min-width: 0; }
.entry .credit { font-size: 14px; color: var(--muted); }
.entry .mark { color: var(--muted); flex: 0 0 auto; }
.drop { padding: 6px 0 22px; }
.drop video { width: 100%; background: #000; }

/* ---------- WORKS ---------- */
.works-main { flex: 1 1 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; padding: 8px 24px 32px; }
.bezel { position: relative; width: min(100%, 922px); padding: 30px 38px 56px; border-radius: 30px; background-color: #ACA59C;
  background-image: radial-gradient(120% 90% at 18% 0%, rgba(255,255,255,0.30), rgba(255,255,255,0) 55%), linear-gradient(180deg, rgba(255,255,255,0.06), rgba(0,0,0,0.14)), url(../ui/metal.webp);
  background-size: auto, auto, 512px 512px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.65), inset 0 -2px 3px rgba(0,0,0,0.25), inset 0 0 0 1px rgba(0,0,0,0.16), 0 0 0 1px rgba(60,55,48,0.55), 0 1px 0 3px rgba(160,152,142,0.95), 0 1px 0 4px rgba(60,55,48,0.45), 0 30px 46px -22px rgba(20,20,20,0.55); }
.well { padding: 5px; border-radius: 10px; background: #151515; box-shadow: inset 0 2px 4px rgba(0,0,0,0.75), 0 1px 0 rgba(255,255,255,0.6), 0 -1px 0 rgba(0,0,0,0.22); }
.cover { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #0B0B0B; overflow: hidden; border-radius: 5px; }
.cover > button { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: transparent; cursor: pointer; }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: opacity 300ms ease; opacity: 0; }
.cover img.on { opacity: 1; }
.static { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 120ms linear; background: repeating-linear-gradient(0deg, rgba(255,255,255,0.10) 0px, rgba(255,255,255,0.10) 1px, rgba(0,0,0,0.85) 1px, rgba(0,0,0,0.85) 3px); }
.static.on { opacity: 1; }
.counter { position: absolute; left: 14px; top: 12px; font-size: 11px; letter-spacing: 0.06em; color: #F5F5F5; text-shadow: 0 1px 2px rgba(0,0,0,0.8); }
.stopped { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; font-size: 11px; letter-spacing: 0.1em; color: var(--faint); }
.is-stopped .stopped { display: flex; }
.is-stopped .cover img { opacity: 0 !important; }
.side { position: absolute; top: calc(50% - 10px); transform: translateY(-50%); }
.side.l { left: -12px; } .side.r { right: -12px; }
.transport { position: absolute; left: 50%; bottom: 4px; transform: translateX(-50%); display: flex; gap: 2px; }
.devbtn { flex: 0 0 auto; padding: 0; border: 0; background: transparent; cursor: pointer; line-height: 0; transition: transform 120ms ease, filter 160ms ease; filter: drop-shadow(0 3px 4px rgba(20,20,20,0.18)); }
.devbtn:hover { filter: drop-shadow(0 5px 7px rgba(20,20,20,0.24)) brightness(1.06); }
.devbtn:active { transform: translateY(2px) scale(0.97); filter: drop-shadow(0 1px 2px rgba(20,20,20,0.2)) brightness(0.96); }
.devbtn:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; border-radius: 12px; }
.devbtn .arw { width: 50px; height: auto; } .devbtn .pil { width: 76px; height: auto; }
.readout { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.readout .name { font-family: 'Libre Franklin', 'Franklin Gothic Medium', sans-serif; font-weight: 800; font-size: 28px; letter-spacing: -0.02em; }
.readout .credit { font-size: 12px; letter-spacing: 0.06em; }
.readout .meta { font-size: 11px; letter-spacing: 0.06em; color: var(--muted); }
.chans { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px; margin-top: 6px; }
.chans button { min-width: 44px; min-height: 44px; padding: 0 6px; border: 0; background: transparent; cursor: pointer; font-size: 12px; letter-spacing: 0.04em; color: var(--faint); border-bottom: 1px solid transparent; }
.chans button:hover { color: var(--ink); }
.chans button[aria-current="true"] { color: var(--ink); border-bottom-color: var(--ink); }
@media (max-width: 719px) {
  .bezel { padding: 18px 24px 44px; border-radius: 22px; }
  .devbtn .arw { width: 38px; } .devbtn .pil { width: 60px; }
  .chans button { min-width: 40px; }
}

/* pop-up player */
.modal { position: fixed; inset: 0; z-index: 1000; background: rgba(12,12,12,0.94); display: none; align-items: center; justify-content: center; padding: 20px; }
.modal.open { display: flex; }
.modal-inner { display: flex; flex-direction: column; align-items: center; gap: 14px; max-width: 100%; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-width: 260px; max-width: 100%; color: #F5F5F5; }
.topbar .t { font-family: 'Libre Franklin', sans-serif; font-weight: 700; font-size: 15px; }
.topbar .c { font-size: 10px; letter-spacing: 0.06em; color: #A9A69F; }
.iconbtn { width: 44px; height: 44px; border: 0; background: transparent; color: #F5F5F5; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.frame { position: relative; max-width: 100%; background: #000; overflow: hidden; transition: width 260ms ease; }
.frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; cursor: pointer; }
.frame.fs { position: fixed; inset: 0; z-index: 1100; width: 100vw !important; height: 100vh; aspect-ratio: auto !important; }
.frame:fullscreen { width: 100vw !important; height: 100vh; aspect-ratio: auto !important; }
.round { position: absolute; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(245,245,245,0.86); color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.round:hover { background: #FFFFFF; }
.round.prev { left: 10px; top: 50%; transform: translateY(-50%); }
.round.next { right: 10px; top: 50%; transform: translateY(-50%); }
.round.small { width: 32px; height: 32px; bottom: 14px; background: rgba(20,20,20,0.6); color: #F5F5F5; }
.round.mute { right: 10px; } .round.full { right: 50px; }
.frame.fs .prev, .frame.fs .next, .frame:fullscreen .prev, .frame:fullscreen .next { display: none !important; }
.progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(245,245,245,0.18); }
.progress span { display: block; height: 100%; width: 0; background: #F5F5F5; }
.overlay-msg { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; font-size: 11px; letter-spacing: 0.08em; color: #A9A69F; pointer-events: none; }
.overlay-msg.on { display: flex; }
.dots { display: flex; gap: 6px; align-items: center; }
.dots button { width: 20px; height: 20px; padding: 0; border: 0; background: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.dots span { width: 6px; height: 6px; border-radius: 50%; background: rgba(245,245,245,0.35); }
.dots .on span { background: #F5F5F5; }
.hidden { display: none !important; }

/* ID card photo + signal glitches */
.idbox { aspect-ratio: 732 / 1200; }
.idwin { position: absolute; left: 7.79%; top: 10.33%; width: 39.62%; height: 33.83%; overflow: hidden; border-radius: 7px; background: #0B0B0B; box-shadow: inset 0 0 8px rgba(0,0,0,0.7); }
.idwin img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.idwin .g-base { filter: contrast(1.04); }
.idwin .g-red, .idwin .g-cyan, .idwin .g-s { opacity: 0; }
.idwin .g-red { mix-blend-mode: multiply; filter: sepia(1) saturate(5) hue-rotate(-45deg); }
.idwin .g-cyan { mix-blend-mode: multiply; filter: sepia(1) saturate(5) hue-rotate(150deg); }
.idwin .scan { position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(0,0,0,0.10) 0px, rgba(0,0,0,0.10) 1px, rgba(0,0,0,0) 1px, rgba(0,0,0,0) 3px); }
.idwin .g-bar { position: absolute; left: 0; right: 0; height: 3%; background: rgba(255,255,255,0.08); mix-blend-mode: screen; display: none; }
.idwin .glass { background: linear-gradient(125deg, rgba(255,255,255,0.18) 0%, rgba(255,255,255,0.05) 30%, rgba(255,255,255,0) 31%), radial-gradient(ellipse at center, rgba(0,0,0,0) 58%, rgba(0,0,0,0.38) 100%); }
.idwin .grain { position: absolute; inset: 0; background-image: url(../ui/grain.png); background-size: 160px 160px; mix-blend-mode: overlay; opacity: 0.16; pointer-events: none; }
.idwin .roll { position: absolute; left: 0; right: 0; top: -20%; height: 18%; background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.05) 50%, rgba(255,255,255,0) 100%); pointer-events: none; }
