@font-face {
  font-family: 'Montserrat';
  src: url('/assets/fonts/montserrat-subset.woff2') format('woff2');
  font-weight: 400 600;
  font-display: swap;
}
:root {
  --ground: #0d0c0a;
  --panel: #17150f;
  --panel-2: #1d1a13;
  --ink: #f2eddf;
  --ink-dim: #b3ac97;
  --line: #2c2820;
  --bolt: #ffd400;
  --bolt-ink: #ffd400;
  --btc: #f7931a;
  --btc-ink: #f7931a;
  --bezel: #060605;
  --bezel-edge: #35302a;
  --glow-bolt: rgba(255, 212, 0, .13);
  --glow-btc: rgba(247, 147, 26, .13);
  --clip: #ff3355; --clank: #7FA25A;
  --clip-ink: #ff3355; --clank-ink: #7FA25A;
  --glow-clip: rgba(255, 51, 85, .14);
  --card-shadow: 0 24px 60px rgba(0,0,0,.55);
}
@media (prefers-color-scheme: light) {
  :root {
    --ground: #f2eddf;
    --panel: #faf7ee;
    --panel-2: #ffffff;
    --ink: #171410;
    --ink-dim: #6b6455;
    --line: #ddd5c2;
    --bolt-ink: #8a6d00;
    --btc-ink: #b35f00;
    --bezel: #12100d;
    --bezel-edge: #3b352c;
    --glow-bolt: rgba(255, 212, 0, .25);
    --glow-btc: rgba(247, 147, 26, .22);
    --clip-ink: #c2123a; --clank-ink: #4f7a2e;
    --glow-clip: rgba(255, 51, 85, .22);
    --card-shadow: 0 20px 44px rgba(40, 32, 12, .18);
  }
}
:root[data-theme="dark"] {
  --ground: #0d0c0a; --panel: #17150f; --panel-2: #1d1a13; --ink: #f2eddf;
  --ink-dim: #b3ac97; --line: #2c2820; --bolt-ink: #ffd400; --btc-ink: #f7931a;
  --bezel: #060605; --bezel-edge: #35302a;
  --glow-bolt: rgba(255, 212, 0, .13); --glow-btc: rgba(247, 147, 26, .13);
  --clip-ink: #ff3355; --clank-ink: #7FA25A; --glow-clip: rgba(255, 51, 85, .14);
  --card-shadow: 0 24px 60px rgba(0,0,0,.55);
}
:root[data-theme="light"] {
  --ground: #f2eddf; --panel: #faf7ee; --panel-2: #ffffff; --ink: #171410;
  --ink-dim: #6b6455; --line: #ddd5c2; --bolt-ink: #8a6d00; --btc-ink: #b35f00;
  --bezel: #12100d; --bezel-edge: #3b352c;
  --glow-bolt: rgba(255, 212, 0, .25); --glow-btc: rgba(247, 147, 26, .22);
  --clip-ink: #c2123a; --clank-ink: #4f7a2e; --glow-clip: rgba(255, 51, 85, .22);
  --card-shadow: 0 20px 44px rgba(40, 32, 12, .18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .chip, .btn, .navlinks a, .brand, .step-n, .spec dt {
  font-family: 'Montserrat', system-ui, sans-serif;
}
h1, h2, h3 { text-wrap: balance; line-height: 1.15; margin: 0; }
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* ---- top bar ---- */
nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 0; gap: 16px;
}
.brand { font-weight: 600; font-size: 18px; letter-spacing: .02em; text-decoration: none; }
.navlinks { display: flex; gap: 22px; flex-wrap: wrap; }
.navlinks a {
  font-size: 13px; letter-spacing: .09em; text-transform: uppercase;
  text-decoration: none; color: var(--ink-dim);
}
.navlinks a:hover, .navlinks a:focus-visible { color: var(--ink); }

/* ---- hero ---- */
header.hero { padding: 56px 0 30px; text-align: center; }
.eyebrow {
  font-size: 13px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-dim); margin: 0 0 18px;
  font-family: 'Montserrat', system-ui, sans-serif;
}
.hero h1 { font-size: clamp(34px, 6vw, 60px); font-weight: 600; }
.hero p.lede {
  max-width: 620px; margin: 22px auto 0; color: var(--ink-dim); font-size: 19px;
}
.hero-sets {
  display: flex; justify-content: center; align-items: flex-end; gap: 4vw;
  margin: 44px auto 8px; max-width: 720px;
}
.hero-sets a { line-height: 0; }
.hero-sets img { height: clamp(134px, 21.5vw, 224px); width: auto; }
.hero-sets .set-zap { filter: drop-shadow(0 18px 46px var(--glow-bolt)); transform: rotate(-3deg); }
.hero-sets .set-btc { filter: drop-shadow(0 18px 46px var(--glow-btc)); transform: rotate(2.5deg); }
@media (prefers-reduced-motion: no-preference) {
  .hero h1, .hero .lede, .hero-tvs { animation: rise .7s ease-out both; }
  .hero .lede { animation-delay: .12s; }
  .hero-tvs { animation-delay: .22s; }
  @keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
  .hero-sets a { transition: transform .25s ease; }
  .hero-sets a:hover { transform: translateY(-6px); }
}

.hero-tvs {
  display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 56px 64px;
  max-width: 900px; margin: 44px auto 8px; text-align: left;
}
@media (max-width: 700px) { .hero-tvs { grid-template-columns: 1fr; gap: 44px; max-width: 440px; } }
.hero-set { margin: 0; }
.hero-npub { margin-top: 16px; }
.hero-set .demo-status { text-align: center; }

.hero-tvs { position: relative; }
@media (min-width: 701px) {
  .hero-tvs::before { content: ""; position: absolute; left: 50%; top: 2%; bottom: 2%; width: 1px; background: var(--line); }
  .hero-tvs::after { content: ""; position: absolute; top: 50%; left: 2%; right: 2%; height: 1px; background: var(--line); }
}
.zap-try { margin-top: 64px; display: flex; flex-direction: column; align-items: center; }
.zap-try h3 { font-size: 15px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); font-weight: 600; }
.zap-try .tagline { margin: 10px auto 24px; max-width: 520px; }
.zap-try .tvset { width: 100%; max-width: 400px; }
.zap-try .npub-form { width: 100%; max-width: 400px; margin-top: 18px; }
.zap-try .demo-status { text-align: center; }

/* headline line break for wide screens only; phones flow and balance */
@media (max-width: 700px) { .br-wide { display: none; } }

/* ---- channel bands ---- */
section.channel { border-top: 1px solid var(--line); padding: 72px 0; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line);
}
.channel-zap .chip { color: var(--bolt-ink); border-color: color-mix(in srgb, var(--bolt) 45%, transparent); }
.channel-btc .chip { color: var(--btc-ink); border-color: color-mix(in srgb, var(--btc) 45%, transparent); }
.channel-clip .chip { color: var(--clip-ink); border-color: color-mix(in srgb, var(--clip) 45%, transparent); }
.channel-head { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 8px; }
.channel-head img { width: 84px; height: auto; }
.channel h2 { font-size: clamp(28px, 4vw, 40px); font-weight: 600; }
.tagline { color: var(--ink-dim); font-size: 18px; max-width: 640px; margin: 14px 0 0; }

.channel-body {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 48px; margin-top: 40px; align-items: start;
}
@media (max-width: 860px) { .channel-body { grid-template-columns: 1fr; } }

/* the TV set: bezel + screen + stand */
.tvset { margin: 0; }
.tv {
  background: var(--bezel);
  border: 1px solid var(--bezel-edge);
  border-radius: 22px;
  padding: 16px;
  box-shadow: var(--card-shadow);
  position: relative;
}
.tv .screen { border-radius: 10px; overflow: hidden; position: relative; }
.tv .screen::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,.028) 0 1px, transparent 1px 3px);
}
.tv .led {
  position: absolute; right: 22px; bottom: 7px; width: 5px; height: 5px;
  border-radius: 50%;
}
.channel-zap .tv .led { background: var(--bolt); box-shadow: 0 0 6px var(--bolt); }
.channel-btc .tv .led { background: var(--btc); box-shadow: 0 0 6px var(--btc); }
.channel-clip .tv .led { background: var(--clip); box-shadow: 0 0 6px var(--clip); }
.stand {
  width: 34%; height: 12px; margin: 0 auto;
  background: var(--bezel); border: 1px solid var(--bezel-edge); border-top: none;
  border-radius: 0 0 12px 12px;
}
.tvset figcaption {
  text-align: center; font-size: 13.5px; color: var(--ink-dim); margin-top: 14px;
}
.tv-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 18px; margin-top: 18px; }
.tv-row .tv { padding: 8px; border-radius: 12px; }
.tv-row .screen { border-radius: 6px; }

.channel-body .tvset { max-width: 354px; margin-left: auto; margin-right: auto; }
.tv-row { max-width: 354px; margin-left: auto; margin-right: auto; }

/* feature lists */
.features { margin: 0; padding: 0; list-style: none; display: grid; gap: 14px; }
.features li { padding-left: 26px; position: relative; color: var(--ink-dim); }
.features li strong { color: var(--ink); font-weight: 600; }
.features li::before {
  content: ''; position: absolute; left: 0; top: .52em; width: 12px; height: 12px;
  border-radius: 3px;
}
.channel-zap .features li::before { background: var(--bolt); clip-path: polygon(60% 0, 22% 55%, 46% 55%, 40% 100%, 78% 42%, 54% 42%); }
.channel-btc .features li::before { background: var(--btc); }
.channel-clip .features li::before { background: repeating-linear-gradient(-55deg, var(--clip) 0 3px, #171410 3px 6px); }
.channel-clip .features code, .channel-clip .qr-card code { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: .92em; }
.first-callout {
  margin-top: 26px; padding: 16px 18px; border-radius: 12px;
  border: 1px dashed color-mix(in srgb, var(--bolt) 50%, transparent);
  color: var(--ink-dim); font-size: 15px;
}
.first-callout strong { color: var(--bolt-ink); }


/* install QR tiles */
.qr-card {
  display: flex; align-items: center; gap: 20px; margin-top: 26px;
  padding: 16px 18px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--panel);
}
.qr-box {
  flex: 0 0 auto; width: 108px; height: 108px; padding: 10px;
  background: #f2eddf; border-radius: 8px;
}
.channel-zap .qr-card { border-color: color-mix(in srgb, var(--bolt) 40%, transparent); }
.channel-btc .qr-card { border-color: color-mix(in srgb, var(--btc) 40%, transparent); }
.channel-clip .qr-card { border-color: color-mix(in srgb, var(--clip) 40%, transparent); }
.qr-card .qr-text { min-width: 0; }
.qr-card strong { display: block; font-family: 'Montserrat', system-ui, sans-serif; font-weight: 600; }
.qr-card p { margin: 4px 0 0; color: var(--ink-dim); font-size: 14px; }


/* ---- npub demo ---- */
.demo-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; margin-top: 40px; align-items: start; }
@media (max-width: 860px) { .demo-body { grid-template-columns: 1fr; } }
.npub-form { display: flex; gap: 10px; }
.npub-form input {
  flex: 1 1 auto; min-width: 0; font: inherit; font-size: 15px;
  padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--panel); color: var(--ink);
}
.npub-form input:focus-visible { outline: 2px solid var(--bolt-ink); outline-offset: 2px; }
.demo-status { color: var(--ink-dim); font-size: 14px; margin: 12px 2px 0; min-height: 1.4em; }
.demo-status a { color: inherit; }
.demo-status.err { color: #e05d44; }
.demo-set { max-width: 420px; margin-left: auto; margin-right: auto; }
.demo-screen {
  aspect-ratio: 4 / 3; background: #000; position: relative;
  font-family: 'Montserrat', system-ui, sans-serif; cursor: pointer;
  container-type: inline-size;
}
/* off-air state */
.dz-off { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.dz-off span { position: relative; color: #777; font-size: 6cqw; letter-spacing: .3em; font-weight: 600; }
.dz-noise {
  position: absolute; inset: 0; opacity: .55;
  background-image: url("/assets/img/snow-1.png"), url("/assets/img/snow-2.png");
  background-size: 21cqw 21cqw, 27cqw 27cqw;
  filter: contrast(1.25) brightness(.9);
}
.dz-noise::after {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.22) 0 1px, transparent 1px 3px);
}
@media (prefers-reduced-motion: no-preference) {
  .dz-noise { animation: dzsnow .7s steps(1) infinite; }
  @keyframes dzsnow {
  0.0% { background-position: 41px 19px, -50px 83px; }
  8.3% { background-position: 6px 9px, -68px 12px; }
  16.7% { background-position: 46px 74px, -7px 64px; }
  25.0% { background-position: 27px 4px, -11px 55px; }
  33.3% { background-position: 53px 8px, -30px 11px; }
  41.7% { background-position: 70px 54px, -7px 72px; }
  50.0% { background-position: 15px 28px, -80px 80px; }
  58.3% { background-position: 74px 7px, -73px 74px; }
  66.7% { background-position: 50px 6px, -28px 5px; }
  75.0% { background-position: 71px 17px, -37px 53px; }
  83.3% { background-position: 18px 69px, -15px 73px; }
  91.7% { background-position: 39px 71px, -87px 23px; }
  100% { background-position: 0 0, 0 0; }
}
}
.dz-off[hidden], .dz-app[hidden] { display: none; }
/* app layout: 67% list / 28% side column, like the real screen */
.dz-app { position: absolute; inset: 0; display: flex; padding: 2.5cqw; gap: 2cqw; }
.dz-list { width: 67%; overflow: hidden; color: #fff; font-size: 4.55cqw; line-height: 1.32; word-break: break-word; }
.dz-list .dz-row { margin-bottom: .45em; }
.dz-list .dz-dim { color: #9a9a9a; font-size: 4cqw; }
.dz-side { width: 30%; display: flex; flex-direction: column; align-items: center; gap: 1.6cqw; }
.dz-pic { width: 86%; aspect-ratio: 1; background: #222 center/cover no-repeat; }
.dz-pic.dz-ph { display: flex; align-items: center; justify-content: center; color: #666; font-size: 9cqw; }
.dz-name { color: #fff; font-size: 3.8cqw; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dz-qr { width: 86%; height: auto; image-rendering: pixelated; }
/* lightning strike: flash overlay + jagged bolt, phases mirror the app */
.dz-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.dz-bolt { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; display: none; }
.dz-bolt polyline { fill: none; stroke: #FFD400; stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; }


/* ---- BlockTV live demo ---- */
.btv-screen {
  aspect-ratio: 4 / 3; background: var(--btv-bg, #000); color: var(--btv-fg, #fff);
  position: relative; font-family: 'Montserrat', system-ui, sans-serif;
  container-type: inline-size;
}
.btv-page { position: absolute; inset: 0 0 9cqw 0; }
.btv-page[hidden], #btvGrid[hidden], #btvChartPage[hidden] { display: none; }
/* the grid page */
#btvGrid { display: grid; padding: 2.5cqw 3cqw 0; gap: 1cqw 4cqw; }
#btvGrid.l1 { grid-template: 1fr / 1fr; }
#btvGrid.l2 { grid-template: 1fr 1fr / 1fr; }
#btvGrid.l4 { grid-template: 1fr 1fr / 1fr 1fr; }
#btvGrid.l8 { grid-template: repeat(4, 1fr) / 1fr 1fr; }
#btvGrid.l10 { grid-template: repeat(5, 1fr) / 1fr 1fr; gap: 0.4cqw 4cqw; }
.btv-tile { border: none; background: none; padding: 0; text-align: center; color: inherit; font: inherit; cursor: pointer; overflow: hidden; }
.btv-tile:focus-visible { outline: 1px solid var(--btv-fg, #fff); outline-offset: -1px; }
.btv-title { display: block; text-align: left; color: color-mix(in srgb, var(--btv-fg, #fff) 55%, transparent); font-size: 3.2cqw; letter-spacing: .18em; font-weight: 600; }
.btv-tile .btv-title { text-align: center; }
.btv-value { display: block; font-weight: 600; line-height: 1.05; font-variant-numeric: tabular-nums; white-space: nowrap; }
.btv-unit { display: block; color: color-mix(in srgb, var(--btv-fg, #fff) 55%, transparent); font-size: 3.1cqw; }
.l1 .btv-value { font-size: 17cqw; } .l1 .btv-title { font-size: 4cqw; } .l1 .btv-unit { font-size: 3.6cqw; }
.l2 .btv-value { font-size: 13cqw; }
.l4 .btv-value { font-size: 9.2cqw; }
.l8 .btv-value { font-size: 6.4cqw; } .l8 .btv-title { font-size: 2.5cqw; } .l8 .btv-unit { font-size: 2.4cqw; }
.l10 .btv-value { font-size: 5.1cqw; } .l10 .btv-title { font-size: 2.3cqw; } .l10 .btv-unit { font-size: 2.1cqw; }
/* the chart page */
#btvChartPage { padding: 2.5cqw 3cqw 0; }
.btv-chart-head { display: flex; justify-content: space-between; align-items: baseline; }
.btv-chart-price { font-size: 6.4cqw; font-weight: 600; font-variant-numeric: tabular-nums; }
#btvChart { position: absolute; inset: 9cqw 3cqw 10cqw; width: calc(100% - 6cqw); height: auto; }
.btv-delta {
  position: absolute; right: 3cqw; bottom: 11cqw; font-size: 4.4cqw; font-weight: 600;
  color: #26d968; padding: .4cqw 2cqw; border-radius: 99px;
}
.btv-delta.big { background: #26d968; color: #000; }
.btv-delta.down { color: #e05d44; }
.btv-delta.big.down { background: #e05d44; color: #fff; }
/* bottom bar */
.btv-bar {
  position: absolute; left: 0; right: 0; bottom: 0; height: 9cqw;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 3cqw; font-size: 3.4cqw;
  color: color-mix(in srgb, var(--btv-fg, #fff) 70%, transparent);
}
.btv-dots i { display: inline-block; width: 1.9cqw; height: 1.9cqw; border-radius: 50%; margin: 0 1cqw; background: color-mix(in srgb, var(--btv-fg, #fff) 35%, transparent); cursor: pointer; }
.btv-dots i.on { background: var(--btv-fg, #fff); }
.btv-gear { background: none; border: none; color: inherit; font-size: 5cqw; line-height: 1; cursor: pointer; padding: 0; }
.btv-gear:focus-visible, .btv-tile:focus-visible { outline: 1px solid currentColor; }
/* settings overlay */
.btv-menu {
  position: absolute; inset: 12% 14%; background: #111; color: #fff;
  border: 1px solid #333; border-radius: 2cqw; padding: 3cqw 4cqw;
  display: flex; flex-direction: column; justify-content: space-around;
  font-size: 4cqw;
}
.btv-menu[hidden] { display: none; }
.btv-menu-row { display: flex; justify-content: space-between; align-items: center; gap: 2cqw; }
.btv-menu-row button {
  font: inherit; font-size: 3.6cqw; min-width: 8cqw; padding: 1cqw 2cqw; margin-left: 1.2cqw;
  background: #222; color: #fff; border: 1px solid #444; border-radius: 1.2cqw; cursor: pointer;
}
.btv-menu-row button.on { border-color: #f7931a; color: #f7931a; }
.btv-menu-row button[data-c] { border-width: 2px; }
.btv-menu-row button[data-c].on { border-color: #f7931a; }

/* ---- ClipTV soundboard demo ---- */
.ctv-screen {
  aspect-ratio: 4 / 3; background: #000; color: #fff; position: relative;
  font-family: 'Montserrat', system-ui, sans-serif; container-type: inline-size;
}
.ctv-head {
  position: absolute; left: 0; right: 0; top: 0; height: 13cqw;
  display: flex; align-items: center; gap: 1.5cqw; padding: 0 2cqw;
}
.ctv-gear, .ctv-stop {
  width: 9cqw; height: 9cqw; border-radius: 1.6cqw; border: none; cursor: pointer;
  background: #2b2b2b; color: #fff; font-size: 5cqw; line-height: 1; padding: 0;
}
.ctv-stop { font-size: 4cqw; }
.ctv-gear:focus-visible, .ctv-stop:focus-visible, .ctv-btn:focus-visible, .ctv-back:focus-visible { outline: 1px solid #fff; outline-offset: 1px; }
.ctv-title { position: absolute; left: 0; right: 0; text-align: center; font-size: 4.4cqw; font-weight: 600; pointer-events: none; }
.ctv-pager { margin-left: auto; display: flex; align-items: center; gap: 1.5cqw; font-size: 3.8cqw; position: relative; }
.ctv-arrow {
  width: 9cqw; height: 9cqw; border-radius: 1.6cqw; border: none; cursor: pointer;
  background: #2b2b2b; color: #fff; font-size: 6cqw; line-height: 1; padding: 0;
}
.ctv-grid { position: absolute; left: 0; right: 0; top: 13cqw; bottom: 0; display: grid; gap: 1.5cqw; padding: 0 1.5cqw 1.5cqw; }
.ctv-grid[hidden], .ctv-player[hidden], .ctv-menu[hidden] { display: none; }
.ctv-btn {
  position: relative; border: none; border-radius: 2.2cqw; cursor: pointer; padding: 1cqw;
  font: inherit; font-weight: 600; font-size: 4.2cqw; line-height: 1.1;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  transition: filter .12s ease, transform .12s ease;
}
.ctv-btn:active { transform: scale(.96); }
.ctv-btn.playing { filter: brightness(1.12); }
.ctv-name { transition: transform .15s ease; }
.ctv-btn.playing .ctv-name { transform: translateY(-14%); }
/* equaliser bars: shown along the bottom of a button while its sound plays */
.ctv-eq {
  position: absolute; left: 0; right: 0; bottom: 0; height: 24%;
  display: flex; align-items: flex-end; justify-content: center; gap: 1cqw;
  padding: 0 2cqw 1.3cqw; opacity: 0; transition: opacity .12s ease; pointer-events: none;
}
.ctv-btn.playing .ctv-eq { opacity: .95; }
.ctv-eq i { width: 1.7cqw; height: 100%; border-radius: .5cqw .5cqw 0 0; background: currentColor; transform: scaleY(.35); transform-origin: bottom; }
@media (prefers-reduced-motion: no-preference) {
  .ctv-btn.playing .ctv-eq i { animation: ctveq .62s ease-in-out infinite alternate; }
  .ctv-btn.playing .ctv-eq i:nth-child(1) { animation-duration: .55s; animation-delay: -.10s; }
  .ctv-btn.playing .ctv-eq i:nth-child(2) { animation-duration: .74s; animation-delay: -.32s; }
  .ctv-btn.playing .ctv-eq i:nth-child(3) { animation-duration: .48s; animation-delay: -.05s; }
  .ctv-btn.playing .ctv-eq i:nth-child(4) { animation-duration: .68s; animation-delay: -.45s; }
  .ctv-btn.playing .ctv-eq i:nth-child(5) { animation-duration: .58s; animation-delay: -.22s; }
  .ctv-btn.playing .ctv-eq i:nth-child(6) { animation-duration: .80s; animation-delay: -.15s; }
  .ctv-btn.playing .ctv-eq i:nth-child(7) { animation-duration: .52s; animation-delay: -.38s; }
  @keyframes ctveq { from { transform: scaleY(.15); } to { transform: scaleY(1); } }
}
.ctv-btn.empty { background: #161616; border: 1px dashed #333; cursor: default; }
.ctv-name { text-align: center; overflow-wrap: anywhere; }
.ctv-badge {
  position: absolute; right: 1.6cqw; bottom: .8cqw; font-size: 4.4cqw; font-weight: 600; opacity: .85;
}
.ctv-player { position: absolute; inset: 0; background: #000; }
.ctv-player canvas { width: 100%; height: 100%; display: block; }
.ctv-back {
  position: absolute; left: 2.5cqw; top: 2.5cqw; width: 11cqw; height: 11cqw; border-radius: 50%;
  border: none; cursor: pointer; background: rgba(0,0,0,.55); color: #fff; font-size: 6cqw; line-height: 1; padding: 0;
}
.ctv-menu {
  position: absolute; inset: 12% 10%; background: #111; color: #fff;
  border: 1px solid #333; border-radius: 2cqw; padding: 3cqw 4cqw;
  display: flex; flex-direction: column; justify-content: space-around; font-size: 4cqw;
}
.ctv-menu-row { display: flex; justify-content: space-between; align-items: center; gap: 2cqw; }
.ctv-menu-row button {
  font: inherit; font-size: 3.6cqw; min-width: 8cqw; padding: 1cqw 2cqw; margin-left: 1.2cqw;
  background: #222; color: #fff; border: 1px solid #444; border-radius: 1.2cqw; cursor: pointer;
}
.ctv-menu-row button.on { border-color: var(--clip); color: var(--clip); }

.channel-clank .chip { color: var(--clank-ink); border-color: color-mix(in srgb, var(--clank) 45%, transparent); }
.channel-clank .tv .led { background: var(--clank); box-shadow: 0 0 6px var(--clank); }
.channel-clank .features li::before { top: .72em; height: 6px; width: 14px; border-radius: 3px; background: linear-gradient(90deg, var(--clank) 0 62%, color-mix(in srgb, var(--clank) 25%, transparent) 62%); }
.channel-clank .tagline a { color: inherit; }
.channel-clank .qr-card { border-color: color-mix(in srgb, var(--clank) 40%, transparent); }

/* ---- ClankerTV live set (colours, thresholds and layout from the app) ---- */
.clk-screen {
  aspect-ratio: 4 / 3; background: #000; color: #FAF9F5; position: relative;
  font-family: 'Montserrat', system-ui, sans-serif; container-type: inline-size;
  user-select: none; touch-action: pan-y;
}
.clk-title { position: absolute; left: 1.6cqw; top: .8cqw; font-size: 5cqw; white-space: nowrap; }
.clk-title .clk-plan { color: #B0AEA5; margin-left: 1.6cqw; }
.clk-page {
  position: absolute; left: 1.3cqw; right: 1.3cqw; top: 8.6cqw; bottom: 9.6cqw;
  overflow: hidden; display: flex; flex-direction: column; gap: 1.9cqw;
}
.clk-card { background: #1F1F1E; border-radius: 2.2cqw; padding: 1.7cqw 2.5cqw 1.9cqw; flex: 0 0 auto; }
.clk-row { display: flex; justify-content: space-between; align-items: center; gap: 2cqw; white-space: nowrap; }
.clk-name { font-size: 4.6cqw; }
.clk-lvl { font-size: 4.6cqw; }
.clk-chip { background: #2F2F2C; border-radius: 99px; padding: .5cqw 2.4cqw; font-size: 3.9cqw; }
.clk-big { font-size: 6.9cqw; font-variant-numeric: tabular-nums; }
.clk-bar { position: relative; height: 2cqw; border-radius: 1cqw; background: #2F2F2C; margin: 1.4cqw 0 1.1cqw; }
.clk-fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 1cqw; }
.clk-tick { position: absolute; top: -.6cqw; bottom: -.6cqw; width: .7cqw; margin-left: -.35cqw; background: #FAF9F5; border-radius: .3cqw; }
.clk-sub { font-size: 3.9cqw; color: #B0AEA5; font-variant-numeric: tabular-nums; }
.clk-foot {
  position: absolute; left: 1.3cqw; right: 1.3cqw; bottom: .8cqw; height: 8cqw;
  display: flex; align-items: center; gap: 1.6cqw; font-size: 3.9cqw; color: #B0AEA5;
}
.clk-bot { width: 6.2cqw; height: 6.2cqw; flex: 0 0 auto; }
.clk-src { flex: 1 1 auto; white-space: nowrap; overflow: hidden; }
.clk-src b { font-weight: 400; color: #FAF9F5; margin-right: 1.4cqw; }
.clk-btn {
  background: #1F1F1E; color: #B0AEA5; border: none; border-radius: 1.6cqw;
  width: 7.6cqw; height: 7cqw; font: inherit; font-size: 4.6cqw; line-height: 1; cursor: pointer; padding: 0;
}
.clk-btn:hover { color: #FAF9F5; }
.clk-btn:focus-visible { outline: 1px solid #FAF9F5; outline-offset: 1px; }
.clk-pg { color: #FAF9F5; min-width: 6cqw; text-align: center; font-variant-numeric: tabular-nums; }
.clk-toast {
  position: absolute; left: 8%; right: 8%; top: 30%; padding: 3cqw 4cqw; border-radius: 2.4cqw;
  background: #1F1F1E; border: 1px solid #2F2F2C; font-size: 4cqw; line-height: 1.4; color: #FAF9F5; text-align: center;
}
.clk-toast[hidden] { display: none; }
.clk-led { animation: clkblink .8s steps(1) infinite; }
@keyframes clkblink { 50% { opacity: .15; } }
@media (prefers-reduced-motion: reduce) { .clk-led { animation: none; } }

/* ---- MPOS section ---- */
section.mpos { border-top: 1px solid var(--line); padding: 72px 0 80px; }
.mpos h2 { font-size: clamp(26px, 4vw, 36px); font-weight: 600; }
.mpos .intro { color: var(--ink-dim); max-width: 640px; margin: 16px 0 0; }
.mpos-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px; margin-top: 40px; align-items: start;
}
@media (max-width: 860px) { .mpos-grid { grid-template-columns: 1fr; } }
.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
  padding: 26px 26px 28px;
}
.card h3 { font-size: 15px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-dim); font-weight: 600; margin-bottom: 18px; }
.steps { margin: 0; padding: 0; list-style: none; display: grid; gap: 18px; }
.steps li { display: grid; grid-template-columns: 40px minmax(0,1fr); gap: 14px; align-items: start; }
.step-n {
  width: 34px; height: 34px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 15px;
  background: var(--panel-2); border: 1px solid var(--line);
}
.steps p { overflow-wrap: anywhere; margin: 4px 0 0; color: var(--ink-dim); font-size: 15.5px; }
.steps strong { color: var(--ink); }
.steps a, .spec a, .tagline a, .mpos .intro a, .first-callout a { color: inherit; text-decoration-color: color-mix(in srgb, var(--ink) 40%, transparent); }
.spec { margin: 0; display: grid; gap: 14px; }
.spec > div { display: grid; grid-template-columns: 130px minmax(0,1fr); gap: 12px; }
.spec dt { font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-dim); font-weight: 600; padding-top: 2px; }
.spec dd { margin: 0; font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 32px; }
.btn {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 15px;
  padding: 12px 22px; border-radius: 10px; letter-spacing: .01em;
}
.btn-primary { background: var(--bolt); color: #171410; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-ghost { border: 1px solid var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink-dim); }
a.btn:focus-visible, .navlinks a:focus-visible { outline: 2px solid var(--bolt-ink); outline-offset: 3px; }

/* ---- footer ---- */
footer { border-top: 1px solid var(--line); padding: 36px 0 48px; color: var(--ink-dim); font-size: 14px; }
footer .wrap { display: grid; gap: 8px; }
