/* Nighter platform styles.
   Direction: night sky over industrial type. Ink-black canvas, moon-cream text,
   one signal-lime accent used with discipline. Anybody for display, Geist for body,
   Geist Mono for every number. */

:root {
  --bg: #07090d;
  --bg-2: #0c1016;
  --bg-3: #121821;
  --bg-4: #19202b;
  --line: rgba(226, 232, 240, 0.08);
  --line-2: rgba(226, 232, 240, 0.14);
  --text: #ece9df;
  --muted: #8b93a1;
  --faint: #59616e;
  --accent: #c6f35a;
  --accent-ink: #0b1003;
  --accent-soft: rgba(198, 243, 90, 0.12);
  --accent-glow: rgba(198, 243, 90, 0.35);
  --online: #6ee7a8;
  --danger: #ff7a66;
  --star: rgba(236, 233, 223, 0.22);
  --shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8);
  --r-lg: 20px;
  --r-md: 14px;
  --r-sm: 10px;
  --rail: 232px;
  --display: 'Anybody', 'Arial Narrow', sans-serif;
  --body: 'Geist', 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'Cascadia Mono', monospace;
  color-scheme: dark;
}

:root[data-theme='light'] {
  --bg: #f1eee6;
  --bg-2: #e9e5db;
  --bg-3: #fffdf8;
  --bg-4: #f4f0e6;
  --line: rgba(20, 24, 31, 0.09);
  --line-2: rgba(20, 24, 31, 0.16);
  --text: #12161d;
  --muted: #5d6573;
  --faint: #8f96a1;
  --accent: #4f7a00;
  --accent-ink: #f6ffe4;
  --accent-soft: rgba(79, 122, 0, 0.1);
  --accent-glow: rgba(79, 122, 0, 0.25);
  --online: #1f9d5c;
  --star: rgba(18, 22, 29, 0.12);
  --shadow: 0 24px 48px -28px rgba(20, 24, 31, 0.35);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
img { max-width: 100%; display: block; }
.mono { font-family: var(--mono); font-feature-settings: 'tnum' 1; }
[hidden] { display: none !important; }

/* Sky: star grid, horizon glow and grain */
.sky {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(1200px 520px at 78% -10%, var(--accent-soft), transparent 60%),
    radial-gradient(circle at center, var(--star) 0.8px, transparent 1.2px) 0 0 / 26px 26px,
    radial-gradient(circle at center, var(--star) 0.6px, transparent 1px) 13px 13px / 52px 52px;
  mask-image: linear-gradient(to bottom, #000 0%, rgba(0,0,0,.55) 55%, transparent 100%);
}
.sky::after {
  content: ''; position: absolute; inset: 0; opacity: .05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Shell layout */
.shell {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: var(--rail) 1fr;
  grid-template-rows: 64px 1fr;
  grid-template-areas: 'rail top' 'rail main';
  min-height: 100vh;
}
.rail {
  grid-area: rail; position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; gap: 28px;
  padding: 20px 14px 18px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-2) 85%, transparent), color-mix(in srgb, var(--bg) 70%, transparent));
  backdrop-filter: blur(10px);
}
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px; }
.brand-mark { color: var(--text); flex: none; }
.brand-word {
  font: 900 19px/1 var(--display); font-stretch: 100%;
  text-transform: uppercase; letter-spacing: 0.02em;
}
.brand-word b { font-weight: inherit; color: transparent; -webkit-text-stroke: 1px var(--text); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: var(--r-sm);
  color: var(--muted); font-weight: 500;
  transition: color .18s, background .18s;
}
.nav a svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.nav a:hover { color: var(--text); background: var(--bg-3); }
.nav a.active { color: var(--text); background: var(--bg-3); }
.nav a.active::before {
  content: ''; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 3px;
  border-radius: 0 3px 3px 0; background: var(--accent); box-shadow: 0 0 14px var(--accent-glow);
}
.badge {
  margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  display: grid; place-items: center; font: 600 11px/1 var(--mono);
  background: var(--accent); color: var(--accent-ink);
}
.rail-foot { margin-top: auto; padding: 0 10px; font-size: 11px; color: var(--faint); letter-spacing: .04em; }

.top {
  grid-area: top; position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 32px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(14px);
}
.top-title { font: 600 12px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.player-chip {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 14px 6px 6px; border: 1px solid var(--line-2); border-radius: 999px;
  transition: border-color .18s;
}
.player-chip:hover { border-color: var(--accent); }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  display: grid; place-items: center; position: relative;
  font: 700 12px/1 var(--display); font-stretch: 120%; color: #0b0d10;
}
.avatar.lg { width: 64px; height: 64px; font-size: 22px; }
.avatar .dot {
  position: absolute; right: -1px; bottom: -1px; width: 10px; height: 10px; border-radius: 50%;
  background: var(--faint); border: 2px solid var(--bg);
}
.avatar .dot.on { background: var(--online); }
.chip-name { font-weight: 600; font-size: 14px; }
.chip-score { font: 500 12px/1 var(--mono); color: var(--muted); }

.main { grid-area: main; padding: 32px 32px 80px; max-width: 1280px; width: 100%; outline: none; }

/* Type */
.h1, .h2 {
  font-family: var(--display); text-transform: uppercase; margin: 0;
  letter-spacing: 0.01em; line-height: .92;
}
.h1 { font-size: clamp(40px, 6vw, 76px); font-weight: 900; font-stretch: 112%; }
.h2 { font-size: 26px; font-weight: 800; font-stretch: 125%; }
.kicker { font: 500 11px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.kicker.accent { color: var(--accent); }
.muted { color: var(--muted); }
.section { margin-top: 44px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.section-head a { font: 500 12px/1 var(--mono); color: var(--muted); letter-spacing: .08em; text-transform: uppercase; }
.section-head a:hover { color: var(--accent); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 20px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-2); background: var(--bg-3); color: var(--text);
  font-weight: 600; font-size: 14px; white-space: nowrap;
  transition: transform .15s, border-color .15s, background .15s, box-shadow .2s;
}
.btn:hover { border-color: var(--text); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.btn.primary:hover { box-shadow: 0 0 0 4px var(--accent-soft), 0 10px 30px -10px var(--accent-glow); }
.btn.ghost { background: transparent; }
.btn.sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn.danger:hover { border-color: var(--danger); color: var(--danger); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.link { font: 500 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); background: none; border: 0; padding: 0; cursor: pointer; }

/* Panels */
.panel {
  background: color-mix(in srgb, var(--bg-2) 92%, transparent);
  border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 22px;
}
.panel-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 12px; }
.panel-title h3 { margin: 0; font: 700 15px/1.2 var(--body); }

/* Hero */
.hero {
  position: relative; overflow: hidden; border-radius: 26px; min-height: 420px;
  display: grid; align-items: end; padding: 40px;
  border: 1px solid var(--line-2); box-shadow: var(--shadow);
  isolation: isolate;
}
.hero-art { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 1.2s cubic-bezier(.2,.7,.2,1); }
.hero:hover .hero-art { transform: scale(1.07); }
.hero::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(5,7,10,.92) 0%, rgba(5,7,10,.55) 46%, rgba(5,7,10,0) 75%), linear-gradient(0deg, rgba(5,7,10,.7), transparent 50%); }
.hero-copy { max-width: 560px; color: #ece9df; }
.hero-copy .muted { color: #a9b0bb; }
.hero-copy p { font-size: 17px; margin: 14px 0 26px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.hero .btn:not(.primary) { background: rgba(10,13,18,.6); color: #ece9df; border-color: rgba(236,233,223,.22); }
.hero-meta { display: flex; gap: 18px; margin-bottom: 16px; }

/* Game cards: the whole card is the link */
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.game-card {
  position: relative; display: block; border-radius: var(--r-lg); overflow: hidden;
  background: var(--bg-2); border: 1px solid var(--line);
  transition: transform .25s cubic-bezier(.2,.7,.2,1), border-color .2s, box-shadow .25s;
}
.game-card:hover { transform: translateY(-4px); border-color: var(--line-2); box-shadow: var(--shadow); }
.game-card .art { aspect-ratio: 16 / 9; width: 100%; object-fit: cover; }
.game-card .body { padding: 16px 18px 18px; }
.game-card .title { font: 800 22px/1 var(--display); font-stretch: 125%; text-transform: uppercase; transition: color .2s; }
.game-card:hover .title { color: var(--accent); }
.game-card .tag { margin-top: 8px; color: var(--muted); font-size: 14px; }
.game-card .meta { display: flex; gap: 14px; margin-top: 14px; font: 500 11px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--faint); }
.chip-outline {
  display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent); color: var(--accent);
  font: 500 10.5px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase;
}
.game-card .chip-outline { position: absolute; top: 12px; left: 12px; background: rgba(6,8,11,.6); backdrop-filter: blur(6px); }

/* Rows */
.rows { display: flex; flex-direction: column; }
.row {
  display: flex; align-items: center; gap: 14px; padding: 12px 4px;
  border-top: 1px solid var(--line);
}
.row:first-child { border-top: 0; }
.row .grow { flex: 1; min-width: 0; }
.row .name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .sub { font-size: 13px; color: var(--muted); }
.row .sub.on { color: var(--online); }
.row .actions { display: flex; gap: 8px; }
.empty { color: var(--muted); font-size: 14px; padding: 6px 0; }

/* Friends online rail */
.friend-strip { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.friend-tile {
  flex: none; width: 200px; display: flex; gap: 12px; align-items: center;
  padding: 12px; border-radius: var(--r-md); background: var(--bg-2); border: 1px solid var(--line);
}

/* Two column layouts */
.cols { display: grid; gap: 18px; grid-template-columns: 1.35fr 1fr; }
.cols-3 { display: grid; gap: 18px; grid-template-columns: repeat(3, 1fr); }

/* Play view */
.play { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
.stage {
  position: relative; aspect-ratio: 16 / 9; width: 100%;
  border-radius: var(--r-lg); overflow: hidden; background: #000;
  border: 1px solid var(--line-2); box-shadow: var(--shadow);
}
.stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.stage-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; }
.stage-bar .h2 { font-size: 30px; }
.side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 82px; }
.members { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.member { display: flex; align-items: center; gap: 10px; }
.member .lead { margin-left: auto; }
.ach-list { display: flex; flex-direction: column; gap: 4px; max-height: 360px; overflow: auto; }
.ach {
  display: grid; grid-template-columns: 34px 1fr auto; gap: 12px; align-items: center;
  padding: 9px 6px; border-radius: var(--r-sm);
}
.ach .ico {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: var(--bg-3); border: 1px solid var(--line); color: var(--faint);
}
.ach .ico svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ach.done .ico { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); background: var(--accent-soft); }
.ach .n { font-weight: 600; font-size: 14px; }
.ach:not(.done) .n { color: var(--muted); }
.ach .d { font-size: 12.5px; color: var(--faint); }
.ach .pts { font: 500 12px/1 var(--mono); color: var(--muted); }
.ach.done .pts { color: var(--accent); }

/* Progress */
.bar { height: 6px; border-radius: 999px; background: var(--bg-4); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: var(--accent); box-shadow: 0 0 12px var(--accent-glow); transition: width .6s cubic-bezier(.2,.7,.2,1); }

/* Stat blocks */
.stat { display: flex; flex-direction: column; gap: 8px; }
.stat .v { font: 500 40px/1 var(--mono); letter-spacing: -0.02em; }
.stat .v.sm { font-size: 28px; }
.stat .l { font: 500 11px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }

/* Tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font: 500 11px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--faint); padding: 10px 8px; border-bottom: 1px solid var(--line); }
td { padding: 12px 8px; border-bottom: 1px solid var(--line); }
td.num, th.num { text-align: right; font-family: var(--mono); }
tr.me td { color: var(--accent); }
.rank { font: 600 13px/1 var(--mono); color: var(--muted); width: 44px; }

/* Forms */
.field { display: flex; gap: 10px; }
.input {
  flex: 1; min-width: 0; height: 42px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--bg); outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.input.mono { letter-spacing: .12em; text-transform: uppercase; }
.form-msg { min-height: 20px; margin-top: 8px; font-size: 13px; color: var(--muted); }
.form-msg.err { color: var(--danger); }
.form-msg.ok { color: var(--online); }
.code-big { font: 500 34px/1 var(--mono); letter-spacing: .22em; }
.segmented { display: inline-flex; padding: 3px; border-radius: 999px; border: 1px solid var(--line-2); }
.segmented button { border: 0; background: none; height: 32px; padding: 0 16px; border-radius: 999px; cursor: pointer; color: var(--muted); font-weight: 600; font-size: 13px; }
.segmented button.on { background: var(--bg-4); color: var(--text); }

/* Event card */
.event-head { display: flex; justify-content: space-between; align-items: start; gap: 16px; flex-wrap: wrap; }
.countdown { font: 500 13px/1 var(--mono); color: var(--accent); letter-spacing: .06em; }

/* Join view */
.join { max-width: 560px; margin: 4vh auto 0; text-align: center; }
.join .art { border-radius: var(--r-lg); border: 1px solid var(--line-2); aspect-ratio: 16/9; object-fit: cover; width: 100%; box-shadow: var(--shadow); }
.join .h1 { font-size: clamp(34px, 5vw, 56px); margin: 22px 0 10px; }

/* Toasts */
.toasts { position: fixed; right: 22px; bottom: 22px; z-index: 50; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.toast {
  width: 340px; max-width: calc(100vw - 44px); display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: center;
  padding: 14px 16px; border-radius: 16px;
  background: color-mix(in srgb, var(--bg-3) 94%, transparent); border: 1px solid var(--line-2);
  box-shadow: 0 20px 50px -20px rgba(0,0,0,.8), 0 0 0 1px var(--accent-soft);
  backdrop-filter: blur(12px);
  animation: toast-in .5s cubic-bezier(.2,.9,.25,1.2) both;
}
.toast.out { animation: toast-out .35s ease-in both; }
.toast .medal {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: var(--accent); color: var(--accent-ink); font: 600 13px/1 var(--mono);
  box-shadow: 0 0 24px var(--accent-glow);
}
.toast .t1 { font-weight: 700; }
.toast .t2 { font-size: 13px; color: var(--muted); }
.toast .acts { display: flex; gap: 14px; margin-top: 6px; }
.toast.plain { grid-template-columns: 1fr; }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px) scale(.96); } }
@keyframes toast-out { to { opacity: 0; transform: translateX(30px); } }

/* Sheet (modal) */
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; padding: 20px;
  background: rgba(3,4,6,.66); backdrop-filter: blur(6px);
  animation: fade .2s ease both;
}
.sheet { width: 100%; max-width: 480px; animation: rise .35s cubic-bezier(.2,.8,.2,1) both; }
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }

/* Page load stagger */
.reveal > * { animation: rise .55s cubic-bezier(.2,.8,.2,1) both; }
.reveal > *:nth-child(2) { animation-delay: .06s; }
.reveal > *:nth-child(3) { animation-delay: .12s; }
.reveal > *:nth-child(4) { animation-delay: .18s; }
.reveal > *:nth-child(5) { animation-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Narrow screens: rail becomes a bottom bar */
@media (max-width: 1080px) {
  .play { grid-template-columns: 1fr; }
  .side { position: static; }
  .cols, .cols-3 { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .shell { grid-template-columns: 1fr; grid-template-areas: 'top' 'main'; }
  .rail {
    position: fixed; top: auto; bottom: 0; left: 0; right: 0; height: auto; z-index: 20;
    flex-direction: row; padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0px)); gap: 0;
    border-right: 0; border-top: 1px solid var(--line);
  }
  .brand, .rail-foot { display: none; }
  .nav { flex-direction: row; justify-content: space-around; width: 100%; }
  .nav a { flex-direction: column; gap: 3px; padding: 6px 4px; font-size: 10.5px; }
  .nav a.active::before { display: none; }
  .nav a .badge { position: absolute; top: 0; right: 4px; margin: 0; }
  .nav a[data-route='developer'] { display: none; }
  .top { padding: 0 16px; }
  .main { padding: 20px 16px 110px; }
  .hero { padding: 24px; min-height: 360px; }
}

/* v0.2: challenges and clips */
.challenge-banner { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 12px; border: 1px solid var(--accent); border-radius: 12px; background: var(--accent-soft); }
.challenge-banner strong { font-weight: 600; }
.challenge-banner .link { margin-left: auto; }
.moment { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 12px; }
.moment-line { display: flex; flex-direction: column; gap: 6px; }
.moment-line strong { font-size: 17px; font-weight: 600; }
.moment-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.clip-video { display: block; width: 100%; max-height: 52vh; border-radius: 10px; background: #000; }
.clip-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.clip-card video { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: #000; }
.clip-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; flex-wrap: wrap; }
tr.me td { color: var(--accent); }

/* Home tiles: games only, small square covers */
.tiles { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, 150px); }
.tile {
  position: relative; aspect-ratio: 1; overflow: hidden; display: block;
  border-radius: 18px; background: var(--bg-3); border: 1px solid var(--line);
  box-shadow: 0 10px 24px -14px rgba(0,0,0,.7);
  transition: transform .22s cubic-bezier(.2,.8,.2,1.3), box-shadow .22s, border-color .2s;
}
.tile:hover, .tile:focus-visible { transform: translateY(-3px) scale(1.04); border-color: var(--accent); box-shadow: 0 16px 30px -14px rgba(0,0,0,.85), 0 0 0 3px var(--accent-soft); outline: none; z-index: 1; }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile::after { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(5,7,10,.85) 0%, rgba(5,7,10,0) 50%); opacity: 0; transition: opacity .2s; }
.tile:hover::after, .tile:focus-visible::after { opacity: 1; }
.tile-label { position: absolute; left: 12px; right: 12px; bottom: 11px; z-index: 1; color: #ece9df; opacity: 0; transform: translateY(6px); transition: opacity .2s, transform .2s; }
.tile:hover .tile-label, .tile:focus-visible .tile-label { opacity: 1; transform: none; }
.tile-name { display: block; font: 800 15px/1.05 var(--display); font-stretch: 110%; text-transform: uppercase; }
.tile-play {
  position: absolute; z-index: 1; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: var(--accent); color: var(--accent-ink);
  opacity: 0; transform: scale(.8); transition: opacity .2s, transform .25s cubic-bezier(.2,.8,.2,1.3);
}
.tile-play svg { width: 15px; height: 15px; }
.tile:hover .tile-play, .tile:focus-visible .tile-play { opacity: 1; transform: none; }
@media (max-width: 760px) {
  .tiles { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .tile-label { opacity: 1; transform: none; }
  .tile::after { opacity: 1; }
}

/* Corner fullscreen control, video-player style */
.stage-fs {
  position: absolute; right: 12px; bottom: 12px; z-index: 2; width: 38px; height: 38px;
  display: grid; place-items: center; border-radius: 10px; cursor: pointer;
  border: 1px solid rgba(236,233,223,.18); background: rgba(6,8,11,.72); color: #ece9df;
  opacity: .55; transition: opacity .18s, transform .18s, border-color .18s;
}
.stage:hover .stage-fs, .stage-fs:focus-visible { opacity: 1; }
.stage-fs:hover { transform: scale(1.08); border-color: var(--accent); color: var(--accent); }
.stage-fs svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.recs { margin-top: 36px; }

/* Covers carry the title in the art, so the tile shows only the play button on hover. */
.tile .tile-label { display: none; }
.tile::after { display: none; }

/* Ads: the local test slot sits over the stage; Google's own ads draw over the page. */
.ad-veil { position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; background: var(--bg-2); }
.ad-card { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 24px; max-width: 420px; }
.ad-card strong { font-size: 18px; }
.ad-count { font-size: 40px; color: var(--accent); line-height: 1; }

/* Plus */
.plus-page { max-width: 620px; }
.plus-price { display: flex; align-items: baseline; gap: 12px; margin: 18px 0 22px; }
.plus-price .v { font-size: 44px; font-weight: 800; color: var(--accent); }
.plus-perks { margin-bottom: 24px; }
.rail-foot a { color: inherit; text-decoration: none; }
.rail-foot a:hover { color: var(--accent); }
.ad-veil.page { position: fixed; z-index: 60; }
