:root {
  --bg: #05060a;
  --bg-2: #0e0f12;
  --panel: #1a1f26;
  --line: #262c34;
  --fg: #ffffff;
  --fg-dim: #98a3b3;
  --accent: #a8c5e0;          /* light blue used in screenshots */
  --accent-2: #5bd4ff;
  --lime: #d8ff5e;            /* numbered list accent */
  --device: #c8cdd6;          /* light metallic device body */
  --device-bezel: #e7eaef;    /* bright edge highlight */
  --device-rim: #1a1d23;      /* thin dark rim around the screen */
  --shadow: 0 24px 64px rgba(0, 0, 0, 0.45);

  --nav-h: 64px;
  --slide-pad-x: 6vw;
  --slide-pad-y: 6vh;
}

* { box-sizing: border-box; }

html {
  /* base dark canvas with a faint top-down depth gradient */
  background:
    radial-gradient(130% 90% at 50% -10%, #0d1018 0%, var(--bg) 55%, #030409 100%);
}
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  color: var(--fg);
  font: 15px/1.5 "Sora", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body { background: transparent; }

/* ---------- Ambient aurora backdrop (behind every slide) ---------- */
/* Soft, slowly drifting blurred lights — sits on a fixed layer so the
   cover, content, playable and thanks slides all share the same mood. */
.app-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  overflow: hidden;
}
.app-bg::before {
  content: "";
  position: absolute;
  inset: -25%;
  background:
    radial-gradient(38% 38% at 18% 24%, rgba(91, 212, 255, 0.20), transparent 70%),
    radial-gradient(36% 36% at 84% 14%, rgba(124, 108, 255, 0.18), transparent 70%),
    radial-gradient(42% 42% at 80% 84%, rgba(216, 255, 94, 0.12), transparent 70%),
    radial-gradient(40% 40% at 22% 88%, rgba(91, 212, 255, 0.12), transparent 70%);
  filter: blur(48px);
  animation: auroraDrift 26s ease-in-out infinite alternate;
}
.app-bg::after {
  content: "";
  position: absolute;
  inset: -25%;
  background:
    radial-gradient(30% 30% at 60% 40%, rgba(255, 110, 196, 0.10), transparent 70%),
    radial-gradient(34% 34% at 38% 60%, rgba(64, 224, 208, 0.10), transparent 70%);
  filter: blur(60px);
  mix-blend-mode: screen;
  animation: auroraDrift2 32s ease-in-out infinite alternate;
}
/* Vignette to keep the edges grounded and text legible */
.app-vignette {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(120% 110% at 50% 0%, transparent 52%, rgba(0, 0, 0, 0.6) 100%);
}
@keyframes auroraDrift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(-3%, -4%, 0) scale(1.1); }
}
@keyframes auroraDrift2 {
  from { transform: translate3d(0, 0, 0) scale(1.05); }
  to { transform: translate3d(4%, 3%, 0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .app-bg::before, .app-bg::after { animation: none; }
}

/* ---------- Stage ---------- */
.stage {
  position: fixed;
  inset: 0 0 var(--nav-h) 0;
  height: calc(100dvh - var(--nav-h));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.slide {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  overflow: hidden;
}
.stage,
.slide,
.intro,
.playable,
.playable-stage,
.device-wrap,
.device-screen {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.stage::-webkit-scrollbar,
.slide::-webkit-scrollbar,
.intro::-webkit-scrollbar,
.playable::-webkit-scrollbar,
.playable-stage::-webkit-scrollbar,
.device-wrap::-webkit-scrollbar,
.device-screen::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

/* ---------- Intro slides (cover, content, thanks) ---------- */
.intro {
  position: relative;
  width: 100%;
  height: 100%;
  padding: var(--slide-pad-y) var(--slide-pad-x);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  isolation: isolate;
}

.particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.85;
}

.intro-body {
  position: relative;
  z-index: 1;
  max-width: min(78ch, 78%);
}
.intro-body--center {
  margin: auto;
  text-align: left;
}

.intro-title {
  font-family: "Sora", sans-serif;
  font-weight: 400;
  font-size: clamp(56px, 8vw, 132px);
  line-height: 1.02;
  letter-spacing: -0.01em;
  margin: 0 0 0.4em;
  color: var(--fg);
}
.intro-title .accent { color: var(--accent); }
.intro-title--xl { font-size: clamp(72px, 11vw, 184px); }

.intro-subtitle {
  margin: 0;
  color: var(--fg);
  opacity: 0.85;
  font-size: clamp(18px, 1.6vw, 26px);
  font-weight: 300;
}

/* ---------- Cover hero (modern) ---------- */
.cover-hero {
  margin: auto 0;
  max-width: min(94%, 1120px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.cover-hero > * {
  animation: coverRise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.cover-hero .cover-badge { animation-delay: 0.05s; }
.cover-hero .cover-title { animation-delay: 0.15s; }
.cover-hero .cover-lead { animation-delay: 0.3s; }
.cover-hero .cover-stats { animation-delay: 0.42s; }
@keyframes coverRise {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: none; }
}

/* Soft colored glows behind the hero */
.cover-glow {
  position: absolute;
  z-index: 0;
  pointer-events: none;
  border-radius: 50%;
  filter: blur(30px);
}
.cover-glow--a {
  width: 58vw; height: 58vw;
  max-width: 760px; max-height: 760px;
  right: -10vw; top: -14vh;
  background: radial-gradient(circle, rgba(91, 212, 255, 0.22), rgba(91, 212, 255, 0) 62%);
  animation: glowFloatA 13s ease-in-out infinite alternate;
}
.cover-glow--b {
  width: 42vw; height: 42vw;
  max-width: 520px; max-height: 520px;
  left: -8vw; bottom: -16vh;
  background: radial-gradient(circle, rgba(216, 255, 94, 0.12), rgba(216, 255, 94, 0) 62%);
  animation: glowFloatB 16s ease-in-out infinite alternate;
}
@keyframes glowFloatA {
  from { transform: translate(0, 0); }
  to { transform: translate(-36px, 32px); }
}
@keyframes glowFloatB {
  from { transform: translate(0, 0); }
  to { transform: translate(28px, -26px); }
}

/* Eyebrow badge */
.cover-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(10px);
  font-size: clamp(11px, 1vw, 13px);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--fg);
}
.cover-badge-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--lime);
  animation: coverPulse 2.2s infinite;
}
@keyframes coverPulse {
  0% { box-shadow: 0 0 0 0 rgba(216, 255, 94, 0.5); }
  70% { box-shadow: 0 0 0 9px rgba(216, 255, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(216, 255, 94, 0); }
}

/* Headline */
.cover-title {
  margin: 0.32em 0 0;
  font-weight: 600;
  font-size: clamp(54px, 9vw, 142px);
  line-height: 0.96;
  letter-spacing: -0.025em;
}
.cover-grad {
  background: linear-gradient(100deg, var(--accent-2), var(--accent) 46%, var(--lime));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Lead paragraph */
.cover-lead {
  margin: 24px 0 0;
  max-width: 48ch;
  font-size: clamp(16px, 1.5vw, 21px);
  line-height: 1.5;
  font-weight: 300;
  color: var(--fg-dim);
}

/* Stat row */
.cover-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(18px, 3.5vw, 48px);
  margin-top: 40px;
}
.cover-stats .stat {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.stat-num {
  font-size: clamp(24px, 2.8vw, 38px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--fg);
  font-variant-numeric: tabular-nums;
}
.stat-unit { color: var(--accent-2); font-weight: 500; }
.stat-label {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-dim);
}
.stat-divider {
  width: 1px;
  align-self: stretch;
  min-height: 38px;
  background: rgba(255, 255, 255, 0.14);
}


/* Content list */
.intro--content { padding-top: var(--slide-pad-y); }
.content-grid {
  position: relative;
  z-index: 1;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(200px, 0.7fr) minmax(500px, 1fr);
  align-content: center;
  align-items: center;
  gap: 4vw;
}
.content-grid .intro-title {
  font-size: clamp(40px, 5.5vw, 80px);
  margin: 0;
}

.content-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.content-item {
  display: grid;
  grid-template-columns: 36px 1fr 28px;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 12px;
  background: rgba(35, 38, 44, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 12px;
  cursor: pointer;
  touch-action: manipulation;
  transition: background 0.15s ease, transform 0.1s ease, border-color 0.15s ease;
}
.content-item:hover,
.content-item:focus-visible {
  background: rgba(45, 49, 57, 0.96);
  border-color: rgba(216, 255, 94, 0.25);
  outline: none;
}
.content-item:active { transform: scale(0.995); }
.content-item .num {
  color: var(--lime);
  font-size: clamp(13px, 1.1vw, 17px);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  text-align: left;
  padding-left: 4px;
}
.content-item .label {
  color: var(--fg);
  font-size: clamp(13px, 1.1vw, 17px);
  font-weight: 400;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.content-item .chev {
  width: 24px;
  height: 24px;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.85);
  justify-self: end;
  flex-shrink: 0;
}
.content-empty {
  color: var(--fg-dim);
  padding: 18px 22px;
  background: rgba(35, 38, 44, 0.6);
  border-radius: 18px;
}
.content-empty code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: rgba(255, 255, 255, 0.08);
  padding: 1px 6px;
  border-radius: 4px;
}

/* Footer (cover/content/thanks) */
.intro-footer {
  position: relative;
  z-index: 1;
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.intro-footer-line {
  height: 1px;
  background: rgba(255, 255, 255, 0.18);
  width: 100%;
}
.intro-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: clamp(13px, 1vw, 16px);
  color: var(--fg);
  opacity: 0.95;
}
.intro-footer-row .marker { display: inline-flex; align-items: center; gap: 10px; }
.intro-footer-row .year { margin-left: auto; }
.marker--dot::before {
  content: "";
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--fg);
}
.marker--square::before {
  content: "";
  display: inline-block;
  width: 8px; height: 8px;
  background: var(--fg);
}

/* ---------- Playable slide ---------- */
.playable {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(280px, 460px) minmax(0, 1fr);
  gap: 40px;
  align-items: stretch;
  padding: 28px 36px;
  overflow: hidden;
}

.playable-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.playable-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  padding: 24px 0;
}
.playable-info .eyebrow {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}
.playable-info h1 {
  margin: 0;
  font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  font-weight: 600;
}
.playable-info p {
  margin: 0;
  color: var(--fg-dim);
  font-size: 16px;
  max-width: 50ch;
}
.playable-info .meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 8px;
  font-size: 13px;
  color: var(--fg-dim);
}
.playable-info .chip {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 6px 10px;
  border-radius: 999px;
}
.playable-info .chip-button {
  appearance: none;
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  border-color: rgba(168, 197, 224, 0.7);
  color: #06131b;
  min-height: 34px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(91, 212, 255, 0.18);
  transition: transform 0.12s ease, box-shadow 0.15s ease, filter 0.15s ease;
}
.playable-info .chip-button:hover {
  filter: brightness(1.08);
  box-shadow: 0 10px 28px rgba(91, 212, 255, 0.28);
}
.playable-info .chip-button:active {
  transform: scale(0.97);
}
.playable-info .chip-button:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}
.playable-info .chip-button:disabled {
  cursor: not-allowed;
  filter: grayscale(0.55);
  opacity: 0.55;
}
.playable-info .chip-button svg { stroke-width: 2.4; }

/* ---------- Device frame ---------- */

/* Fullscreen: strip device chrome, iframe fills 100% */
.playable-stage:fullscreen,
.playable-stage:-webkit-full-screen,
.playable-stage.is-fullscreen {
  width: 100%;
  height: 100%;
  padding: 0;
  background: #000;
}

.playable-stage:fullscreen .device-wrap,
.playable-stage:-webkit-full-screen .device-wrap,
.playable-stage.is-fullscreen .device-wrap {
  width: 100%;
  height: 100%;
}

/* Remove device frame styling in fullscreen */
.playable-stage:fullscreen .device,
.playable-stage:-webkit-full-screen .device,
.playable-stage.is-fullscreen .device {
  width: 100% !important;
  height: 100% !important;
  border-radius: 0;
  padding: 0;
  background: #000;
  box-shadow: none;
  transform: none !important;
}

.playable-stage:fullscreen .device-screen,
.playable-stage:-webkit-full-screen .device-screen,
.playable-stage.is-fullscreen .device-screen {
  border-radius: 0;
}

/* Close button */
.fullscreen-close {
  appearance: none;
  position: absolute;
  top: max(16px, env(safe-area-inset-top));
  right: max(16px, env(safe-area-inset-right));
  z-index: 3;
  display: none;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid rgba(168, 197, 224, 0.72);
  border-radius: 999px;
  background: rgba(10, 16, 22, 0.82);
  color: var(--fg);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(12px);
  transition: background 0.15s ease, transform 0.12s ease;
}
.fullscreen-close:hover { background: rgba(23, 34, 44, 0.94); }
.fullscreen-close:active { transform: scale(0.97); }
.fullscreen-close:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}
.playable-stage:fullscreen .fullscreen-close,
.playable-stage:-webkit-full-screen .fullscreen-close,
.playable-stage.is-fullscreen .fullscreen-close {
  display: inline-flex;
}

/* Fake fullscreen for mobile Safari (no Fullscreen API) */
body.has-fake-fullscreen .navbar,
body.has-fake-fullscreen .stage {
  visibility: hidden;
}
body.has-fake-fullscreen .playable-stage.is-fullscreen {
  visibility: visible;
  position: fixed;
  inset: 0;
  z-index: 9999;
  padding: 0;
  background: #000;
}
body.has-fake-fullscreen .playable-stage.is-fullscreen .device {
  width: 100% !important;
  height: 100% !important;
  border-radius: 0;
  padding: 0;
  background: #000;
  box-shadow: none;
  transform: none !important;
}
body.has-fake-fullscreen .playable-stage.is-fullscreen .device-screen {
  border-radius: 0;
}
body.has-fake-fullscreen .playable-stage.is-fullscreen .device-wrap {
  width: 100%;
  height: 100%;
}
body.has-fake-fullscreen .playable-stage.is-fullscreen .fullscreen-close {
  display: inline-flex;
}

.device-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

/* The body is the polished metal rail. Padding = rail + black bezel width.
   A diagonal gradient with light/dark stops simulates light raking across
   a brushed metal edge; the screen carries the uniform black bezel. */
.device {
  position: relative;
  background:
    linear-gradient(135deg,
      #fbfcfe 0%, #cdd2db 14%, #9ba1ad 32%,
      #babfc9 50%, #9ba1ad 68%, #cdd2db 86%, #fbfcfe 100%);
  border-radius: 38px;
  padding: 12px;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35),                 /* crisp metal edge */
    0 1px 1.5px rgba(255, 255, 255, 0.95) inset,   /* top rail glint */
    0 -1px 1.5px rgba(0, 0, 0, 0.3) inset,         /* bottom rail shade */
    0 24px 60px rgba(0, 0, 0, 0.55),               /* cast shadow */
    0 8px 20px rgba(0, 0, 0, 0.4);
  transform-origin: center center;
}

/* Phone shell: deep rounding, slim rail + bezel, dynamic island */
.device--phone {
  border-radius: 52px;
  padding: 11px;
}
.device--phone .device-screen { border-radius: 42px; }

/* Tablet shell: gentler rounding, slightly wider rail, camera dot */
.device--tablet {
  border-radius: 30px;
  padding: 13px;
}
.device--tablet .device-screen { border-radius: 18px; }

.device-screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 20px;
  overflow: hidden;
  overscroll-behavior: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
  background: #000;
  /* the black bezel: a thick dark ring inside the metal rail */
  box-shadow:
    0 0 0 6px #050608,
    0 0 0 7px rgba(255, 255, 255, 0.06),
    0 1px 10px rgba(0, 0, 0, 0.5) inset;
}
.device-screen::-webkit-scrollbar { display: none; }
.device-screen iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
  overflow: hidden;
}
.preview-frame.is-loading { opacity: 0; }

/* ---------- Physical side buttons (metal, sit under the rail) ---------- */
.device--phone::before,
.device--phone::after {
  content: "";
  position: absolute;
  z-index: -1;
  background: linear-gradient(180deg, #aab0ba, #80868f 50%, #aab0ba);
  border-radius: 3px;
}
/* portrait: power on the right, volume rocker on the left */
.device--phone.device--portrait::before { /* power */
  right: -3px; top: 26%;
  width: 3.5px; height: 64px;
  background: linear-gradient(90deg, #80868f, #c2c7d0);
}
.device--phone.device--portrait::after { /* volume */
  left: -3px; top: 32%;
  width: 3.5px; height: 104px;
  background: linear-gradient(270deg, #80868f, #c2c7d0);
}
/* landscape: same buttons, rotated to the horizontal edges */
.device--phone.device--landscape::before { /* power */
  top: -3px; right: 26%;
  height: 3.5px; width: 64px;
  background: linear-gradient(0deg, #80868f, #c2c7d0);
}
.device--phone.device--landscape::after { /* volume */
  bottom: -3px; left: 26%;
  height: 3.5px; width: 104px;
  background: linear-gradient(180deg, #80868f, #c2c7d0);
}
/* tablet: single slim power button */
.device--tablet::before {
  content: "";
  position: absolute;
  z-index: -1;
  background: linear-gradient(90deg, #80868f, #c2c7d0);
  border-radius: 3px;
}
.device--tablet.device--portrait::before {
  top: -3px; right: 16%;
  height: 3.5px; width: 56px;
  background: linear-gradient(0deg, #80868f, #c2c7d0);
}
.device--tablet.device--landscape::before {
  top: 14%; right: -3px;
  width: 3.5px; height: 56px;
}

/* ---------- Device chrome (dynamic island / home bar / camera) ---------- */
.device-notch,
.device-home { display: none; position: absolute; z-index: 4; }

/* Phone — dynamic island floating just inside the top of the screen */
.device--phone .device-notch {
  display: block;
  background: #000;
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06),
    0 1px 3px rgba(0, 0, 0, 0.6);
}
/* the camera lens inside the island */
.device--phone .device-notch::after {
  content: "";
  position: absolute;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #38507a 0%, #0a1322 55%, #000 100%);
  box-shadow: 0 0 0 1px rgba(120, 160, 220, 0.18);
}
.device--phone.device--portrait .device-notch {
  top: 22px; left: 50%; transform: translateX(-50%);
  width: 30%; max-width: 116px; height: 27px;
}
.device--phone.device--portrait .device-notch::after {
  top: 50%; right: 16%; transform: translateY(-50%);
}
.device--phone.device--landscape .device-notch {
  left: 22px; top: 50%; transform: translateY(-50%);
  height: 30%; max-height: 116px; width: 27px;
}
.device--phone.device--landscape .device-notch::after {
  left: 50%; top: 16%; transform: translateX(-50%);
}

/* Phone — home indicator bar */
.device--phone .device-home {
  display: block;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 999px;
}
.device--phone.device--portrait .device-home {
  bottom: 18px; left: 50%; transform: translateX(-50%);
  width: 34%; max-width: 138px; height: 5px;
}
.device--phone.device--landscape .device-home {
  right: 16px; top: 50%; transform: translateY(-50%);
  height: 34%; max-height: 138px; width: 5px;
}

/* Tablet — single front camera dot seated in the bezel */
.device--tablet .device-notch {
  display: block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #324a72 0%, #0a1322 55%, #000 100%);
  box-shadow: 0 0 0 1.5px rgba(0, 0, 0, 0.6), 0 0 0 2.5px rgba(255, 255, 255, 0.05);
}
.device--tablet.device--portrait .device-notch {
  top: 6.5px; left: 50%; transform: translateX(-50%);
}
.device--tablet.device--landscape .device-notch {
  left: 6.5px; top: 50%; transform: translateY(-50%);
}

/* Chrome + buttons are decoration — never block the preview in fullscreen */
.playable-stage:fullscreen .device-notch,
.playable-stage:fullscreen .device-home,
.playable-stage:fullscreen .device::before,
.playable-stage:fullscreen .device::after,
.playable-stage:-webkit-full-screen .device-notch,
.playable-stage:-webkit-full-screen .device-home,
.playable-stage:-webkit-full-screen .device::before,
.playable-stage:-webkit-full-screen .device::after,
.playable-stage.is-fullscreen .device-notch,
.playable-stage.is-fullscreen .device-home,
.playable-stage.is-fullscreen .device::before,
.playable-stage.is-fullscreen .device::after { display: none; }

/* ---------- Preview device controls (segmented toggles) ---------- */
/* Floating toolbar pinned to the top of the preview area. */
.device-controls {
  flex: 0 0 auto;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(10, 13, 18, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
}
/* Hide the toolbar in fullscreen — the device fills the screen there. */
.playable-stage:fullscreen .device-controls,
.playable-stage:-webkit-full-screen .device-controls,
.playable-stage.is-fullscreen .device-controls { display: none; }
.seg {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 999px;
}
.seg-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--fg-dim);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
}
.seg-btn:hover { color: var(--fg); }
.seg-btn[aria-checked="true"] {
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  color: #06131b;
  box-shadow: 0 6px 16px rgba(91, 212, 255, 0.18);
}
.seg-btn:active { transform: scale(0.96); }
.seg-btn:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 2px;
}
.seg-btn svg { stroke-width: 2.2; }

/* ---------- Bottom navigation ---------- */
.navbar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 0 16px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.96), rgba(0, 0, 0, 0.7));
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  z-index: 10;
}

.nav-btn {
  appearance: none;
  background: var(--panel);
  color: var(--fg);
  border: 1px solid var(--line);
  width: 44px;
  height: 44px;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.1s ease, background 0.15s ease;
}
.nav-btn:hover { background: #20262e; }
.nav-btn:active { transform: scale(0.96); }
.nav-btn:disabled { opacity: 0.35; cursor: not-allowed; }

.dots {
  display: flex;
  gap: 6px;
  max-width: min(60vw, 760px);
  overflow-x: auto;
  padding: 4px 8px;
  scrollbar-width: none;
}
.dots::-webkit-scrollbar { display: none; }
.dots button {
  appearance: none;
  background: transparent;
  border: 0;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  cursor: pointer;
  flex: 0 0 auto;
  padding: 0;
  position: relative;
  transition: transform 0.15s ease, width 0.2s ease;
}
.dots button::before {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 999px;
  background: var(--line);
  transition: background 0.15s ease, inset 0.2s ease;
}
.dots button:hover::before { background: #3a414c; }
.dots button[aria-current="true"] {
  width: 36px;
}
.dots button[aria-current="true"]::before {
  inset: 9px 5px;
  background: var(--accent);
}
.dots button.is-playable {
  outline: 1px solid rgba(216, 255, 94, 0.45);
  outline-offset: 2px;
}

.counter {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--fg-dim);
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  min-width: 56px;
  justify-content: center;
}
.counter .sep { opacity: 0.5; }

/* ---------- Loading state ---------- */
.loading {
  color: var(--fg-dim);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}
.loading::before {
  content: "";
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  :root {
    --nav-h: 72px;
    --slide-pad-x: clamp(16px, 5vw, 36px);
    --slide-pad-y: clamp(20px, 5vh, 40px);
  }
  .intro {
    overflow-y: auto;
    padding-bottom: 24px;
  }
  .intro-body {
    max-width: 100%;
  }
  .intro-title {
    font-size: clamp(40px, 13vw, 72px);
  }
  .intro-title--xl {
    font-size: clamp(56px, 18vw, 96px);
  }
  .intro--cover .intro-subtitle {
    margin-top: min(28vh, 180px);
  }
  .playable {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 12px;
    padding: 16px clamp(12px, 4vw, 24px) 12px;
    overflow: hidden;
  }
  .playable-info {
    padding: 0;
    gap: 10px;
    justify-content: flex-start;
  }
  .playable-info h1 { font-size: clamp(22px, 7vw, 30px); }
  .playable-info p {
    font-size: 14px;
    line-height: 1.45;
  }
  .playable-stage {
    height: 100%;
    min-height: 0;
  }
  .device-wrap {
    height: 100%;
  }
  .content-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    align-content: start;
  }
  .content-list {
    grid-template-columns: 1fr;
  }
  .content-item {
    grid-template-columns: 44px minmax(0, 1fr) 32px;
    min-height: 48px;
    padding: 10px 12px;
  }
  .content-item .label {
    white-space: normal;
  }
}

@media (max-width: 640px) {
  .intro-footer-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    text-align: left;
  }
  .intro-footer-row .year {
    margin-left: 0;
  }
  .playable-info p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }
  .playable-info .meta {
    gap: 8px;
  }
  .playable-info .chip {
    padding: 6px 9px;
  }
  /* Icon-only toggles to save horizontal room on phones */
  .device-controls { gap: 8px; }
  .seg-btn { padding: 8px 11px; }
  .seg-btn span { display: none; }
  .device {
    border-radius: 28px;
    padding: 12px;
  }
  .device--phone { border-radius: 38px; padding: 11px; }
  .device--tablet { border-radius: 22px; padding: 13px; }
  .device-screen {
    border-radius: 16px;
  }
  .navbar {
    gap: 8px;
    padding: 0 8px;
  }
  .dots {
    max-width: calc(100vw - 164px);
    padding-inline: 2px;
  }
  .counter {
    min-width: 44px;
  }
}

@media (max-width: 960px) and (max-height: 520px) {
  .playable {
    grid-template-columns: minmax(180px, 0.55fr) minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    align-items: stretch;
  }
  .playable-info p {
    display: none;
  }
  .device-controls { gap: 8px; }
  .seg-btn span { display: none; }
  .playable-stage,
  .device-wrap {
    height: 100%;
    min-height: 0;
  }
}
