/* Vote-Casting Couch themes.
   Every color in style.css / elections.css is derived from the tokens below,
   so a theme only needs to set tokens plus a few signature flourishes.
   --acid  = accent for text, focus and highlights
   --tint  = hue mixed into panels, borders and button surfaces
   --map-* = 3D map fills (top / -low side walls), edges, labels, grid
   --burst = Couch Call confetti colors, --burst-ring = its shockwave rings */

/* ── Theme picker (shared) ───────────────────────────── */
.theme-picker{position:relative;display:flex}
.mast>.theme-picker{margin-left:auto;margin-right:14px}
.theme-toggle{display:flex;align-items:center;gap:8px;background:color-mix(in srgb,var(--tint) 7%,var(--bg));border:1px solid color-mix(in srgb,var(--tint) 24%,var(--bg));border-radius:3px;padding:6px 10px;font-size:12px;color:var(--ink);cursor:pointer}
.theme-toggle:hover,.theme-toggle[aria-expanded=true]{border-color:var(--acid)}
.theme-toggle b{font-weight:500}
.theme-swatch{display:inline-flex;flex:none;align-items:center;gap:3px;padding:3px 5px;border-radius:999px;box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--ink) 22%,transparent)}
.theme-swatch i{display:block;width:8px;height:8px;border-radius:50%}
.theme-menu{position:absolute;top:calc(100% + 8px);right:0;z-index:40;width:250px;padding:6px;background:var(--panel);border:1px solid color-mix(in srgb,var(--tint) 30%,var(--bg));border-radius:6px;box-shadow:0 18px 50px color-mix(in srgb,var(--shadow) 55%,transparent)}
.theme-menu p{margin:4px 8px 6px;font:700 10.5px/1.2 var(--mono);letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
.theme-option{display:flex;align-items:center;gap:11px;width:100%;padding:8px;border:1px solid transparent;border-radius:4px;background:none;color:var(--ink);text-align:left;cursor:pointer}
.theme-option:hover,.theme-option:focus-visible{background:color-mix(in srgb,var(--tint) 10%,var(--panel));outline:none;border-color:color-mix(in srgb,var(--tint) 30%,var(--bg))}
.theme-option[aria-checked=true]{border-color:var(--acid)}
.theme-option .theme-swatch{padding:5px 7px;gap:4px}.theme-option .theme-swatch i{width:11px;height:11px}
.theme-option strong{display:block;font-size:13px;font-weight:600}
.theme-option small{display:block;font-size:11px;color:var(--muted);line-height:1.3}
@media(max-width:740px){.theme-toggle b{display:none}.theme-toggle{padding:6px 8px}.mast>.theme-picker{margin-right:8px}}
.tv-mode .theme-toggle{font-size:var(--tv-small,12px);min-height:38px}
html{transition:background-color .35s ease}

/* ── BROADSHEET · morning-edition newsprint ──────────── */
:root[data-theme=broadsheet]{color-scheme:light;
  --bg:#f3eee3;--panel:#fbf8f1;--ink:#16130f;--muted:#5d564b;--line:#cbc1ad;
  --acid:#b8321a;--tint:#7a6a4f;--dem:#1d4f91;--rep:#b3261e;--other:#94660a;--none:#9d978a;--shadow:#3b2f1f;
  --serif:'Newsreader','Iowan Old Style','Palatino Linotype',Palatino,'Book Antiqua',Georgia,serif;
  --sans:'Public Sans','Franklin Gothic Book','Libre Franklin','Helvetica Neue',Helvetica,Arial,sans-serif;
  --mono:'Courier Prime','Courier New',ui-monospace,monospace;
  --map-dem:#3a6db3;--map-dem-low:#1d3f6e;--map-rep:#c8483f;--map-rep-low:#7c2620;--map-other:#c09335;--map-other-low:#6e5418;--map-none:#ddd5c4;--map-none-low:#a59d8b;
  --map-grid:#7a6a4f;--map-edge:#4a4237;--map-edge-active:#16130f;--map-label:#16130f;--map-label-active:#b8321a;--map-label-halo:#f3eee3;
  --burst:#16130f,#1d4f91,#3a6db3,#b8321a,#94660a,#5d564b;--burst-ring:#16130f,#1d4f91}
[data-theme=broadsheet] body{background:
  repeating-linear-gradient(0deg,transparent 0 3px,#00000005 3px 4px),
  radial-gradient(ellipse at 50% -10%,#fffdf7 0,transparent 40rem),var(--bg)}
[data-theme=broadsheet] .mast{border-bottom:3px double var(--ink)}
[data-theme=broadsheet] .brand{letter-spacing:.22em}
[data-theme=broadsheet] .intro h1,[data-theme=broadsheet] .desk-intro h1{font-weight:700;letter-spacing:-.02em}
[data-theme=broadsheet] .intro h1 em{font-style:italic;font-weight:400}
[data-theme=broadsheet] h2{font-weight:700}
[data-theme=broadsheet] footer{border-top:3px double var(--ink)}

/* ── STUDIO · network election-night set ─────────────── */
:root[data-theme=studio]{color-scheme:dark;
  --bg:#060a18;--panel:#0b1226;--ink:#f2f5ff;--muted:#9aa6c7;--line:#1f2a4a;
  --acid:#ffd23f;--tint:#3a6cff;--dem:#4a93ff;--rep:#ff4458;--other:#ffb020;--none:#4a5578;--shadow:#000;
  --serif:'Avenir Next Condensed','DIN Condensed','Roboto Condensed','Arial Narrow',sans-serif;
  --sans:'Avenir Next','Segoe UI','Helvetica Neue',system-ui,sans-serif;
  --mono:'SF Mono','JetBrains Mono',ui-monospace,Consolas,monospace;
  --map-dem:#1f6bff;--map-dem-low:#0b2a6b;--map-rep:#ff2d45;--map-rep-low:#6b0f1a;--map-other:#ffb020;--map-other-low:#6b4708;--map-none:#1b2440;--map-none-low:#0b1124;
  --map-grid:#3a6cff;--map-edge:#5f78c0;--map-edge-active:#ffd23f;--map-label:#f2f5ff;--map-label-active:#ffd23f;--map-label-halo:#060a18;
  --burst:#ffffff,#ffd23f,#4a93ff,#1f6bff,#9fc3ff,#ffe9a3;--burst-ring:#ffd23f,#4a93ff}
[data-theme=studio] body{background:
  linear-gradient(transparent 0 calc(100% - 1px),#3a6cff12 0) 0 0/100% 48px,
  radial-gradient(ellipse 70rem 34rem at 50% -8%,#1b3aa055 0,transparent 70%),
  radial-gradient(ellipse 40rem 30rem at 100% 0,#ff2d4522 0,transparent 70%),var(--bg)}
[data-theme=studio] .intro h1,[data-theme=studio] .desk-intro h1,[data-theme=studio] h2{font-weight:800;text-transform:uppercase;letter-spacing:-.01em}
[data-theme=studio] .intro h1 em,[data-theme=studio] .desk-intro h1 em{font-style:normal;background:linear-gradient(90deg,#ffd23f,#ffe9a3);-webkit-background-clip:text;background-clip:text;color:transparent}
[data-theme=studio] .mast{border-bottom:2px solid transparent;border-image:linear-gradient(90deg,#1f6bff,#ffd23f 50%,#ff2d45) 1}
[data-theme=studio] #signal[data-live=true]{color:#ff4458}

/* ── FEVER DREAM · psychedelic gig poster ───────────── */
:root[data-theme=fever]{color-scheme:dark;
  --bg:#12061f;--panel:#1b0b2e;--ink:#fff1e0;--muted:#cdb2df;--line:#3d1f5c;
  --acid:#ff6fd8;--tint:#a35cff;--dem:#62c6ff;--rep:#ff8150;--other:#ffe14d;--none:#5a4373;--shadow:#05000a;
  --serif:'Bookman Old Style',Bookman,'URW Bookman','Cooper Black',Georgia,serif;
  --sans:'Futura','Century Gothic','Avenir Next',system-ui,sans-serif;
  --mono:ui-monospace,SFMono-Regular,Consolas,monospace;
  --map-dem:#3fb3ff;--map-dem-low:#1b3f8f;--map-rep:#ff6a3d;--map-rep-low:#7a2142;--map-other:#ffd84d;--map-other-low:#7a5a14;--map-none:#3b2456;--map-none-low:#1f1033;
  --map-grid:#ff6fd8;--map-edge:#c08bff;--map-edge-active:#ffe14d;--map-label:#fff1e0;--map-label-active:#ffe14d;--map-label-halo:#12061f;
  --burst:#ff6fd8,#ffe14d,#62c6ff,#a35cff,#ff8150,#7dffb2;--burst-ring:#ffe14d,#ff6fd8}
[data-theme=fever] body{background:
  radial-gradient(ellipse 60rem 40rem at 15% -5%,#ff6fd833 0,transparent 65%),
  radial-gradient(ellipse 55rem 45rem at 95% 10%,#62c6ff26 0,transparent 65%),
  radial-gradient(ellipse 70rem 50rem at 50% 110%,#ffe14d1c 0,transparent 70%),var(--bg);
  background-attachment:fixed}
[data-theme=fever] body::before{content:"";position:fixed;inset:-20%;z-index:-1;pointer-events:none;
  background:conic-gradient(from 0deg at 50% 50%,#ff6fd80d,#a35cff0d,#62c6ff0d,#7dffb20d,#ffe14d0d,#ff81500d,#ff6fd80d);
  animation:fever-spin 60s linear infinite}
@keyframes fever-spin{to{transform:rotate(1turn)}}
[data-theme=fever] .intro h1 em,[data-theme=fever] .desk-intro h1 em{background:linear-gradient(100deg,#ff6fd8,#ff8150 45%,#ffe14d);-webkit-background-clip:text;background-clip:text;color:transparent;padding-right:.08em}
[data-theme=fever] .intro h1,[data-theme=fever] .desk-intro h1{letter-spacing:-.03em}
[data-theme=fever] .mast{border-bottom:1px solid transparent;border-image:linear-gradient(90deg,#ff6fd8,#a35cff,#62c6ff,#ffe14d) 1}
@media(prefers-reduced-motion:reduce){[data-theme=fever] body::before{animation:none}}

/* ── PHOSPHOR · amber CRT terminal ───────────────────── */
:root[data-theme=phosphor]{color-scheme:dark;
  --bg:#0a0700;--panel:#110c02;--ink:#ffc45c;--muted:#b98a35;--line:#3a2a0a;
  --acid:#ffe3a0;--tint:#ffb000;--dem:#6fd3ff;--rep:#ff6b57;--other:#f2e36b;--none:#6a5126;--shadow:#000;
  --serif:'IBM Plex Mono','JetBrains Mono',ui-monospace,SFMono-Regular,Consolas,monospace;
  --sans:'IBM Plex Mono','JetBrains Mono',ui-monospace,SFMono-Regular,Consolas,monospace;
  --mono:'IBM Plex Mono','JetBrains Mono',ui-monospace,SFMono-Regular,Consolas,monospace;
  --map-dem:#2f9fcf;--map-dem-low:#0f3a4d;--map-rep:#d6503f;--map-rep-low:#4d1a12;--map-other:#d9b23a;--map-other-low:#4d3c0f;--map-none:#3a2b0d;--map-none-low:#1a1304;
  --map-grid:#ffb000;--map-edge:#b98a35;--map-edge-active:#ffe3a0;--map-label:#ffc45c;--map-label-active:#ffe3a0;--map-label-halo:#0a0700;
  --burst:#ffe3a0,#ffc45c,#ffb000,#6fd3ff,#ff6b57,#fff6dc;--burst-ring:#ffb000,#6fd3ff}
[data-theme=phosphor] body{font-size:14px;text-shadow:0 0 6px #ffb00040;
  background:radial-gradient(ellipse at 50% 40%,#1a1203 0,var(--bg) 75%)}
[data-theme=phosphor] body::after{content:"";position:fixed;inset:0;z-index:60;pointer-events:none;
  background:repeating-linear-gradient(0deg,#0000 0 2px,#00000038 2px 3px);mix-blend-mode:multiply}
[data-theme=phosphor] *:not(i):not(svg *){border-radius:0!important}
[data-theme=phosphor] .intro h1,[data-theme=phosphor] .desk-intro h1,[data-theme=phosphor] h2{text-transform:uppercase;letter-spacing:-.04em;font-weight:500}
[data-theme=phosphor] .intro h1 em::after{content:"▌";margin-left:.06em;font-size:.62em;vertical-align:.12em;animation:phosphor-blink 1.1s steps(1) infinite}
@keyframes phosphor-blink{50%{opacity:0}}
@media(prefers-reduced-motion:reduce){[data-theme=phosphor] .intro h1 em::after{animation:none}}

/* ── COUCH · the actual couch. Corduroy, tufting, fringe, plaid, a lava lamp.
   Completely ridiculous on purpose. ─────────────────── */
:root[data-theme=couch]{color-scheme:dark;
  --bg:#2b1a10;--panel:#3a2416;--ink:#fff0d6;--muted:#e2c49a;--line:#6b4526;
  --acid:#ffbe2e;--tint:#e0782c;--dem:#7cc4f2;--rep:#ff6a4a;--other:#c8d65a;--none:#7a5a3e;--shadow:#120a04;
  --serif:'Cooper Black','Cooper Std','Cooper BT','Bookman Old Style',Bookman,Georgia,serif;
  --sans:'Avenir Next Rounded','Nunito','Varela Round','Trebuchet MS',system-ui,sans-serif;
  --mono:'American Typewriter','Courier Prime','Courier New',ui-monospace,monospace;
  --map-dem:#4f9fd6;--map-dem-low:#1f4a6b;--map-rep:#e8573c;--map-rep-low:#6e2414;--map-other:#b5c24a;--map-other-low:#4f5618;--map-none:#8a6142;--map-none-low:#4a2f1c;
  --map-grid:#e0782c;--map-edge:#f2c98a;--map-edge-active:#ffbe2e;--map-label:#fff0d6;--map-label-active:#ffbe2e;--map-label-halo:#2b1a10;
  --burst:#fff6dc,#ffe7a8,#ffbe2e,#7cc4f2,#e0782c,#c8d65a;--burst-ring:#ffbe2e,#7cc4f2;
  --plaid:repeating-linear-gradient(90deg,#e0782c55 0 14px,transparent 14px 28px,#ffbe2e40 28px 34px,transparent 34px 56px),
          repeating-linear-gradient(0deg,#7a2e1455 0 14px,transparent 14px 28px,#ffbe2e40 28px 34px,transparent 34px 56px),#5a2f17;
  --stitch:2px dashed color-mix(in srgb,var(--acid) 55%,transparent);
  scrollbar-color:#e0782c #2b1a10}
/* corduroy ribs + warm lamp glow across the whole room */
:root[data-theme=couch]{background:
  radial-gradient(ellipse 60rem 38rem at 12% -6%,#ffbe2e2e 0,transparent 65%) no-repeat,
  repeating-linear-gradient(90deg,#00000038 0 2px,#ffffff08 2px 5px,#0000001c 5px 7px,transparent 7px 9px),
  linear-gradient(180deg,#3a2416,#2b1a10 40rem) no-repeat,var(--bg)}
[data-theme=couch] body{background:none}
/* the armrest: a plaid bolster with tassel fringe */
[data-theme=couch] .mast{position:relative;border-bottom:0;margin-top:10px;padding:0 18px;border-radius:38px 38px 18px 18px;
  background:var(--plaid);box-shadow:inset 0 10px 18px #ffffff1f,inset 0 -14px 20px #0000005c,0 10px 0 #1a0e06,0 18px 30px #0008}
[data-theme=couch] .mast::before{content:"";position:absolute;inset:7px;border:var(--stitch);border-radius:31px 31px 12px 12px;pointer-events:none}
[data-theme=couch] .mast::after{content:"";position:absolute;left:26px;right:26px;top:100%;height:16px;pointer-events:none;
  background:repeating-linear-gradient(90deg,#ffbe2e 0 3px,transparent 3px 7px);
  -webkit-mask:linear-gradient(#000,#0000);mask:linear-gradient(#000,#0000);transform-origin:top;animation:couch-fringe 3s ease-in-out infinite alternate}
@keyframes couch-fringe{from{transform:skewX(-6deg)}to{transform:skewX(6deg)}}
[data-theme=couch] .brand{color:#fff6dc;text-shadow:0 2px 0 #0007}
[data-theme=couch] .brand small{color:#ffe7a8}
[data-theme=couch] .brand-mark{filter:drop-shadow(0 2px 0 #0008)}
[data-theme=couch] .brand-mark::after{background:#ffbe2e}
/* every panel is a tufted cushion with piping and stitching */
[data-theme=couch] :is(.mapbox,.console,.raceboard,.detail,.recap,.desk-inspector,.outlook-card,.desk-method,.station,.broadcast-poster,.player-slot,.compare-table-wrap,.desk-map,.desk-races,.desk-stat,.archive-race-list,.local-layout>*,.local-card){
  border:3px solid #6b3a1a;border-radius:26px;
  background-image:radial-gradient(ellipse at 50% 0,#ffffff12,transparent 60%);
  box-shadow:inset 0 8px 16px #ffffff14,inset 0 -16px 28px #00000052,inset 0 0 0 6px #4a2a14,0 8px 0 #1a0e06,0 16px 30px #0007;
  outline:var(--stitch);outline-offset:-7px}
[data-theme=couch] :is(.mapbox,.desk-map){background-image:radial-gradient(circle at center,#0000006b 0 3px,#ffffff1f 3.5px 4.5px,transparent 5px),radial-gradient(ellipse at 50% 0,#ffffff12,transparent 60%);
  background-size:64px 64px,100% 100%;background-position:32px 32px,0 0}
[data-theme=couch] .mapbox{background-color:#3a2416}
[data-theme=couch] :is(.desk-stat,.local-card){padding:16px 18px}
[data-theme=couch] .mapbox::before{opacity:.35}
/* seat cushions */
[data-theme=couch] .mode{border-radius:20px;border:2px solid #8a4a1e;border-bottom:7px solid #4a2610;
  background:radial-gradient(ellipse at 50% 18%,#ffffff26,transparent 60%),linear-gradient(180deg,#c9662a,#9c4a1c);color:#fff6dc;
  box-shadow:inset 0 -6px 12px #0005,0 4px 10px #0006;outline:var(--stitch);outline-offset:-7px}
[data-theme=couch] .mode[aria-pressed=true]{background:radial-gradient(ellipse at 50% 18%,#ffffff40,transparent 60%),linear-gradient(180deg,#ffbe2e,#d98a14);color:#2b1a10;border-color:#fff0d6;transform:translateY(3px) scaleY(.96)}
[data-theme=couch] .mode[aria-pressed=true] :is(small,.arrow,.glyph){color:#2b1a10}
[data-theme=couch] .mode:hover{transform:translateY(-2px) rotate(-.6deg)}
[data-theme=couch] .mode .glyph{border-radius:50%}
/* buttons become little throw pillows */
[data-theme=couch] :is(.mast-actions button,.tools button,#refresh,.theme-toggle,#matrix button){border-radius:14px;border-width:2px;box-shadow:inset 0 -3px 0 #0004,0 2px 0 #0005}
[data-theme=couch] :is(.mast-actions button,.tools button,#refresh,.theme-toggle):hover{transform:translateY(-1px) rotate(-1.5deg)}
[data-theme=couch] .theme-menu{border-radius:20px;border:3px solid #6b3a1a;background-image:var(--plaid);outline:var(--stitch);outline-offset:-8px}
[data-theme=couch] .theme-option{background:#2b1a10e6;border-radius:14px;margin:3px 0}
[data-theme=couch] .theme-option:hover,[data-theme=couch] .theme-option:focus-visible{background:#3a2416f2}
[data-theme=couch] :is(.desk-tabs a,.year-strip button,.desk-offices button,.desk-calendar button){border-radius:16px;border:2px solid #8a4a1e;border-bottom-width:5px;
  background:radial-gradient(ellipse at 50% 15%,#ffffff1f,transparent 60%),linear-gradient(180deg,#8a4320,#5e2c14);outline:var(--stitch);outline-offset:-6px}
[data-theme=couch] :is(.desk-tabs a[aria-current],.desk-tabs a[aria-selected=true],.year-strip button[aria-pressed=true],.desk-offices button[aria-pressed=true]){background:linear-gradient(180deg,#ffbe2e,#d98a14);color:#2b1a10;border-color:#fff0d6}
[data-theme=couch] :is(.desk-tabs a[aria-current],.desk-tabs a[aria-selected=true]) *{color:#2b1a10}
/* headlines: Cooper Black with a plaid upholstered "Couch." */
[data-theme=couch] :is(.intro h1,.desk-intro h1){letter-spacing:-.035em;text-shadow:0 4px 0 #1a0e06,0 8px 22px #0009}
[data-theme=couch] :is(.intro h1 em,.desk-intro h1 em,.lost h1 em){color:#ffbe2e;text-shadow:none;padding-right:.1em;
  background:repeating-linear-gradient(90deg,#e0782c 0 .12em,#ffbe2e .12em .24em,#c8d65a .24em .28em,#ffbe2e .28em .4em),
             repeating-linear-gradient(0deg,#7a2e14aa 0 .12em,transparent .12em .24em);background-blend-mode:multiply;
  -webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;filter:drop-shadow(0 4px 0 #1a0e06)}
[data-theme=couch] .intro h1 em::after{content:"\1F6CB\FE0F";-webkit-text-fill-color:initial;display:inline-block;font-size:.45em;vertical-align:.9em;margin-left:.08em;filter:none;animation:couch-bounce 1.6s cubic-bezier(.3,1.6,.5,1) infinite}
@keyframes couch-bounce{0%,100%{transform:translateY(0) rotate(-4deg)}50%{transform:translateY(-.18em) rotate(5deg)}}
[data-theme=couch] h2{letter-spacing:-.02em}
[data-theme=couch] .eyebrow,[data-theme=couch] .micro{letter-spacing:.12em}
/* the footer is the bottom cushion, and we found some stuff in it */
[data-theme=couch] footer{position:relative;border-top:0;margin-top:30px;padding:26px 28px 30px;border-radius:30px 30px 10px 10px;
  background:var(--plaid);color:#ffe7a8;box-shadow:inset 0 10px 18px #ffffff1a,inset 0 -14px 22px #0006;outline:var(--stitch);outline-offset:-10px}
[data-theme=couch] footer a{color:#fff6dc}
[data-theme=couch] footer::after{content:"Found in this cushion: 3 quarters \00B7  1 remote \00B7  popcorn (2019) \00B7  a single sock \00B7  your dignity";
  grid-column:1/-1;font:italic 11px/1.4 var(--mono);color:#fff0d6;opacity:.8}
/* the lava lamp in the corner */
[data-theme=couch] body:not(.tv-mode)::after{content:"";position:fixed;left:14px;bottom:16px;z-index:30;width:30px;height:86px;pointer-events:none;
  border-radius:45% 45% 30% 30% / 30% 30% 12% 12%;
  background:radial-gradient(circle at 50% 20%,#ffbe2e 0 7px,transparent 8px) 0 0/100% 100%,
             radial-gradient(circle at 40% 70%,#ff6a4a 0 9px,transparent 10px) 0 0/100% 100%,
             linear-gradient(180deg,#e0782c66,#7a2e14cc);
  box-shadow:0 0 30px 6px #ffbe2e40,inset 0 0 0 2px #fff0d633,0 10px 0 -2px #5a2f17;
  animation:couch-lava 7s ease-in-out infinite alternate}
@keyframes couch-lava{0%{background-position:0 0,0 0,0 0}50%{background-position:0 42px,0 -38px,0 0}100%{background-position:0 18px,0 -12px,0 0}}
[data-theme=couch] #toast{border-radius:20px;border:2px solid #ffbe2e;background:var(--plaid);outline:var(--stitch);outline-offset:-6px}
[data-theme=couch] .track{border-radius:99px;height:7px}
[data-theme=couch] .lost .cushion{color:#e0782c;filter:drop-shadow(0 6px 0 #1a0e06)}
@media(max-width:740px){
  [data-theme=couch] .mast{padding:0 10px;border-radius:26px 26px 12px 12px;margin-top:6px}
  [data-theme=couch] .mast::before{inset:5px;border-radius:21px 21px 8px 8px}
  [data-theme=couch] :is(.mapbox,.console,.raceboard,.detail,.recap,.desk-inspector,.outlook-card,.desk-method,.station,.broadcast-poster,.player-slot,.compare-table-wrap,.desk-map,.desk-races,.desk-stat,.archive-race-list,.local-layout>*,.local-card){border-radius:18px;outline-offset:-5px;border-width:2px}
  [data-theme=couch] .mode{border-radius:12px;border-bottom-width:5px;outline-offset:-5px}
  [data-theme=couch] footer{padding:20px 18px 24px}
  }
@media(max-width:1639px){[data-theme=couch] body::after{display:none}}
@media(prefers-reduced-motion:reduce){[data-theme=couch] .mast::after,[data-theme=couch] .intro h1 em::after,[data-theme=couch] body::after{animation:none}}

[data-theme=phosphor] .tv-mode .detail h3{font-size:clamp(16px,2.4vw,30px)}
@media(max-width:740px){
  [data-theme=phosphor] .recap{letter-spacing:-.06em}
  [data-theme=phosphor] :is(.recap-title strong,.recap-control-card b,#recap-flip-count b){font-size:11px}
  [data-theme=phosphor] :is(.recap .micro,.recap-control-card strong,#recap-flip-count strong,.recap-control-card small){font-size:10px}}

/* ── Brand mark (follows the theme accent) ───────────── */
.brand-mark{display:block;flex:none;width:72px;height:72px;position:relative}
.brand-mark::after{content:"";position:absolute;inset:0;background:var(--acid);-webkit-mask:url(mark.svg) center/contain no-repeat;mask:url(mark.svg) center/contain no-repeat}
.brand:hover .brand-mark::after{animation:ballot-drop .6s cubic-bezier(.3,1.4,.5,1)}
@keyframes ballot-drop{0%{transform:translateY(-3px)}100%{transform:none}}
@media(prefers-reduced-motion:reduce){.brand:hover .brand-mark::after{animation:none}}
.tv-mode .brand-mark{width:min(72px,calc(var(--tv-head,80px) - 8px));height:min(72px,calc(var(--tv-head,80px) - 8px))}

/* ── The fine print ─────────────────────────────────── */
.respectfully{display:block;margin-top:5px;font:italic 11px/1.3 var(--serif);letter-spacing:0;text-transform:none;color:var(--muted);opacity:.7}
/* Couch header: keep the logo and buttons inside the stitching */
[data-theme=couch] .mast.mast{height:auto;min-height:88px;padding:16px 34px 16px 30px;box-sizing:border-box}
[data-theme=couch] .mast .brand .brand-mark{width:56px;height:56px}
@media(max-width:740px){[data-theme=couch] .mast.mast{min-height:68px;padding:12px 18px}[data-theme=couch] .mast .brand .brand-mark{width:44px;height:44px}}
/* Couch in TV layout: the armrest's margin and fringe take room, so the dashboard gives it back */
@media(min-width:760px){[data-theme=couch] .tv-mode main{height:calc(100dvh - var(--tv-head) - var(--recap-height,0px) - var(--couch-extra,48px))}}
@media(max-width:360px){:root[data-theme=couch] body .mast{padding-inline:6px}[data-theme=couch] .mast::before{inset:4px}.mast .theme-toggle{padding:5px 6px}}
