* {
  box-sizing: border-box;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
body {
  margin: 0;
  background: var(--bg);
  /* Keep negative-z backgrounds above the opaque body Safari uses for its chrome. */
  isolation: isolate;
}
/* Search, sign-in and verification fields must still support normal editing. */
input,
textarea {
  -webkit-user-select: text;
  user-select: text;
  -webkit-touch-callout: default;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
button {
  padding: 0;
  color: inherit;
  cursor: pointer;
  border: 0;
  background: transparent;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin: 0;
  font-weight: inherit;
}
svg {
  flex-shrink: 0;
}
img {
  display: block;
  max-width: 100%;
}
[hidden] {
  display: none !important;
}
body:has(dialog[open]) {
  overflow: hidden;
}

/* ---------- Shared controls ---------- */
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  color: var(--text-1);
}
.icon-button:hover {
  background: var(--hairline);
}
.primary,
.secondary {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  font-weight: 500;
  font-size: 15px;
}
.primary {
  background: var(--accent);
  color: #fff;
}
.primary:hover {
  filter: brightness(1.08);
}
.secondary {
  background: var(--surface-3);
  color: var(--text-1);
}
.secondary:hover,
.setting-row:is(a, button):hover {
  background-color: var(--glass);
}
.primary,
.secondary,
.text-button {
  /* Colors switch instantly: a color transition would run from the UA default on load. */
  transition:
    transform 0.12s ease,
    filter 0.12s ease;
}
:is(.primary, .secondary):active {
  transform: scale(0.98);
}
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px;
  color: var(--text-2);
}
.quiet {
  color: var(--text-2);
}
.fine {
  font-size: 12px;
  color: var(--text-2);
  margin-top: var(--space-4);
}
.fine-print {
  font-size: 12px;
  color: var(--text-2);
}
.muted {
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.5;
  margin: 14px 0;
}
.eyebrow {
  color: var(--accent-soft);
  font-size: 13px;
}
form .form-error[role="alert"] {
  color: var(--danger);
  font-size: 14px;
  margin: 0;
}
input:not([type="hidden"])[aria-invalid="true"] {
  background: var(--danger-tint);
  border-color: var(--danger);
}
/* Strokes belong on inputs and selectable objects, never on content containers. */
input:not([type="hidden"]) {
  color: var(--text-1);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
/* Select: a compact pill control with its own chevron on every browser. */
select {
  appearance: none;
  min-height: 40px;
  padding: 8px 36px 8px 14px;
  color: var(--text-1);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  border: 1px solid var(--line);
  border-radius: 999px;
  background-color: var(--surface-3);
  background-image: url("/assets/chevron-down.svg");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 14px;
  text-overflow: ellipsis;
  cursor: pointer;
}
select:hover {
  background-color: var(--glass-strong);
  border-color: var(--glass-strong);
}
select:disabled {
  cursor: default;
  opacity: 0.45;
}
[dir="rtl"] select {
  padding: 8px 14px 8px 36px;
  background-position: left 12px center;
}
input:not([type="hidden"])::placeholder {
  color: var(--text-3);
  opacity: 1;
}

#notice {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  max-width: calc(100% - 32px);
  width: max-content;
  background: var(--text-1);
  color: var(--bg);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  display: none;
}
#notice.visible {
  display: block;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  top: -100px;
  left: 12px;
  z-index: 1000;
  padding: 12px;
  background: var(--text-1);
  color: var(--bg);
}
.skip-link:focus {
  top: max(12px, env(safe-area-inset-top));
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Bottom sheets ---------- */
.sheet {
  position: fixed;
  inset: auto 0 0;
  margin: 0 auto;
  width: min(100%, var(--column));
  max-width: 100%;
  max-height: 90dvh;
  border: 0;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: var(--surface-1);
  color: var(--text-1);
  padding: var(--space-3) 0 calc(var(--space-5) + env(safe-area-inset-bottom));
  box-shadow: 0 -12px 50px #0006;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.sheet::backdrop {
  background: #0009;
}
.sheet[open],
.sheet:target {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  /* Without JavaScript an open sheet must still sit above sticky headers. */
  z-index: 20;
}
.sheet-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 44px;
  margin: 0 var(--gutter) var(--space-3);
  flex-shrink: 0;
  z-index: 2;
  background: var(--surface-1);
}
.sheet-heading {
  flex: 1;
  min-width: 0;
}
.sheet-header h2 {
  outline: none;
  font-size: 21px;
  font-weight: 500;
  line-height: 1.25;
  color: #fff;
}
.sheet-header.with-cover h2 {
  font-size: 18px;
  font-weight: 500;
}
/* Title-less sheet: the close button floats over the body's own heading. */
.sheet-header.bare {
  position: absolute;
  top: var(--space-4);
  right: var(--gutter);
  margin: 0;
  min-height: 0;
  z-index: 3;
}
.sheet:has(> .sheet-header.bare) .sheet-body {
  padding-top: var(--space-3);
}
.sheet-subtitle {
  margin-top: 3px;
  font-size: 13px;
  line-height: 1.35;
  color: var(--text-2);
}
.sheet-cover {
  width: 48px;
  height: 64px;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  background: var(--surface-3);
}
.sheet-header.with-cover {
  align-items: center;
  padding-top: var(--space-3);
  margin-bottom: var(--space-4);
}
.sheet-close {
  width: 44px;
  height: 44px;
  background: var(--surface-2);
  align-self: flex-start;
}
.sheet-close svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.7;
}
.sheet-back {
  min-width: 44px;
  width: 44px;
  height: 44px;
  margin-inline-start: -8px;
  background: none;
}
.sheet-back svg {
  width: 18px;
  height: 18px;
}
.sheet-body {
  padding: 0 var(--gutter);
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* PN reader — one dark, mobile-first visual system.
   Tokens first; every surface, radius and type size below comes from them. */
:root {
  --bg: #101012;
  /* --gradient-page averaged along the top edge; browsers can't tint the
     status bar with a gradient. Keep theme-color in sync. */
  --status-bar: #170d0f;
  --surface-1: #1a181c;
  --surface-2: #232126;
  --surface-3: #2e2b33;
  --hairline: #ffffff12;
  --text-1: #f7f5f2;
  --text-2: #b8b4ba;
  --text-3: #8d888f;
  --accent: #cb334d;
  --accent-soft: #ffb3c0;
  --accent-tint: #cb334d26;
  --gold: #ffe1b1;
  /* Unlimited's own gold: the header disc, the lit comparison pane and the paywall action. */
  --gold-bright: #ffd98a;
  --gold-strong: #f7b548;
  --gold-deep: #dd8a24;
  --gold-ink: #261703;
  --gold-tint: #f7b5481a;
  --gold-soft: #f7b54866;
  --danger: #ffadba;
  /* On-image overlays: the reader's ink scrims and floating panels. */
  --ink: #121015;
  --scrim-strong: #080b10f5;
  --scrim: #080b10d9;
  --scrim-soft: #080b1070;
  --scrim-faint: #080b1080;
  --panel-overlay: #18151df2;
  --scrim-guide: #080b10a8;
  /* Translucent surfaces for controls that sit on gradients or imagery. */
  --glass: #ffffff0e;
  --glass-strong: #ffffff1a;
  --line: #ffffff20;
  --surface-tint: #3a2730;
  /* A dark-red light falling on the header from the top-left, gone by ~30% of the screen. */
  --gradient-page: radial-gradient(
    ellipse 105% 30% at 0% 0%,
    #240a0b,
    #240a0b00 85%
  );
  --line-strong: #ffffff30;
  --glass-header: #0c0a0c99;
  --danger-tint: #ffadba1f;
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 22px;
  --font-ui: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-display: Georgia, "Times New Roman", serif;
  --font-narration:
    Charter, "Iowan Old Style", Georgia, "Hiragino Mincho ProN", "Yu Mincho",
    serif;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --control-height: 48px;
  --column: 430px;
  --gutter: 20px;
  --header-height: 60px;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-1);
  background: var(--bg);
  color-scheme: dark;
}
/* One continuous gradient above the body background; the reader keeps its own art. */
body:not(.reading):not(:has(> .reader-backdrop))::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: var(--gradient-page), var(--bg);
}
/* iOS Safari ignores theme-color and paints its status bar with the body's
   background color; the gradient layer above covers the body everywhere else. */
body:not(.reading):not(:has(> .reader-backdrop)) {
  background: var(--status-bar);
}
/* ---------- Page chrome ---------- */
.browse {
  max-width: var(--column);
  min-height: 100dvh;
  margin: 0 auto;
  padding-bottom: env(safe-area-inset-bottom);
  container-type: inline-size;
}
/* Sticky chrome has no background of its own at rest — the page gradient runs
   straight through it. Once content scrolls beneath, it becomes glass. */
.browse-header,
.page-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: transparent;
}
.browse-header.scrolled,
.page-header.scrolled {
  background: var(--glass-header);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  backdrop-filter: blur(18px) saturate(1.3);
}
@supports not (backdrop-filter: blur(1px)) {
  .browse-header.scrolled,
  .page-header.scrolled {
    background: var(--surface-1);
  }
}
.home-header {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: calc(18px + env(safe-area-inset-top)) var(--space-3) var(--space-2);
}
.search {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #ffffff06;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  padding: 0 10px;
  height: 42px;
  flex: 1;
  min-width: 0;
  color: var(--text-2);
}
.search svg,
.home-header .icon-button svg {
  width: 16px;
  height: 16px;
}
.search input {
  background: transparent;
  border: 0;
  border-radius: 0;
  width: 100%;
  min-width: 0;
  padding: 1px 2px;
  color: var(--text-1);
  font-size: 16px;
  line-height: 21px;
  text-overflow: ellipsis;
}
.search input::placeholder {
  font-size: 14px;
}
/* Focus lifts the field's tone; the ring is reserved for keyboard focus. */
.search:focus-within {
  background: var(--glass-strong);
  color: var(--text-1);
}
.search:has(input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.search input:focus {
  outline: none;
}
.home-header .icon-button {
  flex: 0 0 44px;
  height: 44px;
  border-radius: var(--radius-md);
  color: var(--text-2);
}
/* Unlimited enters once; the link keeps the full touch target. */
.unlimited-button {
  flex: 0 0 44px;
  display: grid;
  place-items: center;
  height: 44px;
  border-radius: 50%;
  transition: transform 0.12s ease;
}
.unlimited-button:active {
  transform: scale(0.92);
}
.unlimited-disc {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--gold-ink);
  background: linear-gradient(
    150deg,
    var(--gold-bright),
    var(--gold-strong) 55%,
    var(--gold-deep)
  );
  box-shadow:
    inset 0 1px 0 #ffffff80,
    0 4px 16px var(--gold-soft);
  animation: unlimited-in 0.25s ease-out;
}
.unlimited-disc svg {
  width: 24px;
  height: 24px;
  stroke-width: 2.1;
}
@keyframes unlimited-in {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
}
.filter-pills {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  padding: var(--space-2) var(--space-3) 10px;
  scrollbar-width: none;
}
.filter-pills::-webkit-scrollbar {
  display: none;
}
.filter-pills {
  -webkit-mask-image: linear-gradient(
    90deg,
    #000 calc(100% - 36px),
    transparent
  );
  mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent);
}
.filter-pills button {
  flex-shrink: 0;
  white-space: nowrap;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 10px 15px;
  background: transparent;
  color: var(--text-1);
  font-size: 13px;
  line-height: 21px;
  min-height: 44px;
}
.filter-pills button:hover {
  background: var(--glass);
}
.filter-pills button[aria-pressed="true"] {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}
.page-header {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  align-items: center;
  gap: var(--space-2);
  padding: calc(10px + env(safe-area-inset-top)) var(--space-3) var(--space-2);
}
.page-header h1 {
  font-size: 18px;
  font-weight: 500;
  line-height: 1.3;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.header-spacer {
  width: 44px;
}

/* ---------- Home grid ---------- */
.show-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: var(--space-3);
  padding: 14px var(--space-3) var(--space-5);
}
.masonry-grid {
  grid-auto-rows: 1px;
  row-gap: 0;
}
.masonry-grid:not(.enhanced) {
  grid-auto-rows: auto;
  row-gap: var(--space-3);
}
.show-card {
  background: var(--glass);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: block;
  width: 100%;
  text-align: start;
}
.show-open {
  display: block;
  width: 100%;
  text-align: start;
  padding: 0;
}
.poster {
  height: 252px;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--surface-3);
}
/* Home cards size by shape, so the masonry heights differ by ~1.8x, not ~1.2x. */
.show-card .poster {
  height: auto;
  aspect-ratio: 2 / 3;
}
.show-card.short .poster {
  aspect-ratio: 1;
}
.show-card.xtall .poster {
  aspect-ratio: 9 / 16;
}
/* Hero: the same card across both columns, on For You only; other tabs stay plain masonry. */
.for-you .show-card.hero {
  grid-column: 1 / -1;
}
.for-you .show-card.hero .poster {
  aspect-ratio: 4 / 5;
}
.for-you .show-card.hero .poster-title em {
  font-size: 17px;
}
.for-you .show-card.hero h2 {
  font-size: 19px;
}
.poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  position: absolute;
  inset: 0;
  z-index: -2;
}
.poster::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -3;
  background: linear-gradient(
    100deg,
    transparent 30%,
    #ffffff0c 50%,
    transparent 70%
  );
  background-size: 200% 100%;
  animation: shimmer 1.6s linear infinite;
}
.poster.loaded::before {
  animation: none;
  display: none;
}
@keyframes shimmer {
  from {
    background-position: 120% 0;
  }
  to {
    background-position: -80% 0;
  }
}
.poster:after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    180deg,
    #00000010 20%,
    #00000000 42%,
    #000000b0 72%,
    #000000f0 100%
  );
}
.poster-title {
  position: absolute;
  bottom: 14px;
  left: var(--space-3);
  right: var(--space-3);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.02;
  text-align: center;
  letter-spacing: -0.6px;
  text-shadow: 0 2px 14px #000a;
  white-space: pre-line;
}
.poster-title em {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-family: var(--font-narration);
  font-weight: 400;
  font-size: 12px;
  line-height: 1.3;
  font-style: italic;
  letter-spacing: 0.2px;
  margin-bottom: 6px;
  color: var(--gold);
}
/* Home cards: the tagline is the only text on the art. */
.show-card .poster-title em {
  -webkit-line-clamp: 4;
  font-size: 13px;
  line-height: 1.35;
  margin-bottom: 0;
  text-shadow: 0 1px 8px #000c;
}
.show-card h2 {
  font-size: 15px;
  line-height: 1.32;
  font-weight: 500;
  padding: 11px 10px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
/* One row of whole chips: the padding box ends with row one, so row two never peeks. */
.show-card .tags {
  box-sizing: content-box;
  height: 32px;
  padding: 11px 10px 0;
  margin-bottom: 12px;
  overflow: hidden;
}
.show-meta {
  display: block;
  font-size: 12px;
  line-height: 1.35;
  color: var(--text-2);
}
.show-meta.resume {
  color: var(--accent-soft);
  font-weight: 600;
}
/* Continue reading: story circles, most recent first. */
.continue-strip {
  padding: 6px 0 0;
}
.story-circles {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 4px var(--space-3) 6px;
}
.story-circles::-webkit-scrollbar {
  display: none;
}
.story-circle {
  flex: 0 0 76px;
  display: grid;
  justify-items: center;
  gap: 8px;
}
.story-circle .ring {
  position: relative;
  display: grid;
  place-items: center;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  padding: 2px;
  background: linear-gradient(
    135deg,
    var(--gold),
    var(--accent) 60%,
    var(--accent-soft)
  );
}
/* Caught up on every published chapter: nothing waiting, so no lit ring. */
.story-circle.caught-up .ring {
  background: var(--line-strong);
}
.story-circle img {
  box-sizing: border-box;
  width: 66px;
  height: 66px;
  object-fit: cover;
  object-position: center 22%;
  border-radius: 50%;
  border: 2px solid var(--bg);
  background: var(--surface-3);
}
/* Where the reader is, sitting on the ring's lower edge like a "LIVE" badge. */
.story-badge {
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  padding: 1px 6px;
  border-radius: 999px;
  border: 2px solid var(--bg);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
  background: var(--accent);
}
.story-circle.caught-up .story-badge {
  background: var(--surface-3);
}
.story-circle small {
  max-width: 76px;
  font-size: 11px;
  line-height: 1.3;
  color: var(--text-2);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.story-circle:active .ring {
  transform: scale(0.96);
}
/* Category card: a tag's top picks, tinted so it reads apart from story cards. */
.category-card {
  background: var(--surface-tint);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-3) var(--space-3);
  display: grid;
  gap: 10px;
}
.category-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  min-height: 36px;
  padding: 2px 2px 4px;
}
.category-heading h2 {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
}
.category-heading svg {
  width: 18px;
  height: 18px;
  color: var(--text-2);
}
.category-picks {
  display: grid;
  gap: 10px;
}
/* List and Top show three picks; Strip scrolls through up to eight. */
.category-card:not(.strip) .category-row:nth-child(n + 4) {
  display: none;
}
.category-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  background: var(--glass);
}
.category-row:hover {
  background: var(--glass-strong);
}
.category-row img {
  width: 40px;
  height: 54px;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-xs);
  flex-shrink: 0;
  background: var(--surface-3);
}
.category-row span {
  font-size: 13px;
  line-height: 1.3;
  font-weight: 500;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
/* Fan: three covers splayed like a hand of cards. */
.category-card.fan .category-picks {
  display: flex;
  justify-content: center;
  padding: 8px 0 14px;
}
.category-card.fan .category-row {
  display: block;
  width: 46%;
  margin: 0 -8%;
  padding: 0;
  background: none;
  transform: rotate(-12deg) translateY(10px);
}
.category-card.fan .category-row:nth-child(2) {
  z-index: 1;
  transform: scale(1.12);
}
.category-card.fan .category-row:nth-child(3) {
  transform: rotate(12deg) translateY(10px);
}
.category-card.fan .category-row img {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-sm);
  box-shadow: 0 6px 18px #0009;
}
.category-card.fan .category-row span {
  display: none;
}
/* Top: big gold ranks beside the hottest three. */
.category-card.top .category-picks {
  counter-reset: pick;
}
.category-card.top .category-row {
  counter-increment: pick;
  padding: 4px 0;
  background: none;
}
.category-card.top .category-row::before {
  content: counter(pick);
  flex-shrink: 0;
  width: 24px;
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  color: var(--gold);
}
/* Strip: both columns wide, covers scroll sideways. */
.category-card.strip {
  grid-column: 1 / -1;
}
.category-card.strip .category-picks {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  margin: 0 calc(-1 * var(--space-3));
  padding: 0 var(--space-3);
  scroll-padding: 0 var(--space-3);
}
.category-card.strip .category-row {
  flex: 0 0 104px;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 0;
  background: none;
  scroll-snap-align: start;
}
.category-card.strip .category-row img {
  width: 104px;
  height: 156px;
  border-radius: var(--radius-sm);
}
.category-card.strip .category-row span {
  -webkit-line-clamp: 2;
}
.tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.tags :is(button, a) {
  border-radius: var(--radius-xs);
  background: var(--glass);
  color: var(--text-2);
  font-size: 10px;
  line-height: 1.3;
  padding: 6px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}
@container (max-width: 360px) {
  .home-header {
    gap: var(--space-2);
  }
  .poster {
    height: 220px;
  }
  .poster-title {
    font-size: 21px;
  }
  .show-card .tags :is(button, a) {
    padding: 4px;
  }
  .category-row img {
    width: 36px;
    height: 48px;
  }
  .category-row span {
    font-size: 12px;
  }
}
.empty {
  max-width: 520px;
  margin: 0 auto;
  padding: 70px var(--space-5);
  text-align: center;
  color: var(--text-2);
  line-height: 1.6;
}
.empty :is(.primary, .secondary) {
  margin-top: var(--space-4);
}

/* ---------- My List rows ---------- */
.show-list {
  display: grid;
  gap: var(--space-5);
  padding: var(--space-4) 14px var(--space-6);
  align-content: start;
}
.show-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px;
  gap: var(--space-1);
  align-items: center;
}
.show-row-open {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: start;
  gap: 14px;
  min-width: 0;
  text-align: start;
  padding: 0;
}
.show-row .poster {
  height: 136px;
  border-radius: var(--radius-sm);
}
.show-row .poster-title {
  display: none;
}
.show-row h2 {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.25;
  margin: 2px 0 4px;
  overflow-wrap: anywhere;
}
.show-row .show-meta {
  padding: 0;
  margin-bottom: var(--space-2);
}
.show-row p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.show-row [data-save] {
  width: 44px;
  min-width: 44px;
  height: 48px;
  padding: 0;
  background: none;
  color: var(--text-2);
}
.show-row [data-save] span {
  display: none;
}
.show-row [data-save][aria-pressed="true"] {
  color: var(--accent);
}
@container (max-width: 360px) {
  .show-row-open {
    grid-template-columns: 80px minmax(0, 1fr);
    gap: 10px;
  }
  .show-row .poster {
    height: 116px;
  }
  .show-row h2 {
    font-size: 16px;
  }
  .show-row p {
    font-size: 12px;
    -webkit-line-clamp: 2;
  }
}

/* Only the title clears the close button; tags below it use the full width. */
.sheet:has(> .sheet-header.bare) .synopsis-heading h3 {
  padding-inline-end: 48px;
  min-height: 36px;
}
.sheet[data-sheet="show"] .sheet-body,
.sheet[data-sheet="subscribe"] .sheet-body {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.synopsis-scroll {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-bottom: var(--space-4);
}
/* The cover floats so the title and tags run beside it, then wrap under it at
   full width instead of stacking one tag per line in a narrow column. */
.synopsis-heading {
  display: flow-root;
}
.synopsis-heading img {
  float: left;
  float: inline-start;
  margin-inline-end: var(--space-4);
  margin-bottom: 6px;
  width: 86px;
  height: 116px;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-sm);
  background: var(--surface-3);
}
.synopsis-heading h3 {
  outline: none;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.2;
  color: #fff;
  margin: 0 0 var(--space-3);
}
/* Inline tags (not flex) so their lines can flow around the floated cover. */
.synopsis-heading .tags {
  display: block;
}
.synopsis-heading .tags :is(button, a) {
  font-size: 11px;
  padding: 6px 7px;
  margin: 0 6px 6px 0;
  margin-inline: 0 6px;
  vertical-align: top;
}
.synopsis-copy {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-2);
  margin: 20px 0 var(--space-4);
  white-space: pre-line;
}
.availability {
  color: var(--text-2);
  font-size: 13px;
  margin: var(--space-3) 0 0;
}
.sheet[data-sheet="synopsis"] .synopsis-copy {
  margin: var(--space-2) 0 var(--space-4);
}
.translation-note {
  color: var(--accent-soft);
  font-size: 13px;
  margin: var(--space-3) 0;
}
.sheet-actions {
  position: relative;
  display: flex;
  gap: 10px;
  align-items: stretch;
  flex-shrink: 0;
  padding-top: var(--space-4);
  background: var(--surface-1);
}
/* Content slides under the actions through a fade, not a line. */
.sheet-actions::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 28px;
  background: linear-gradient(to bottom, transparent, var(--surface-1));
  pointer-events: none;
}
.sheet-actions .primary {
  flex: 1;
  min-width: 0;
  padding: 16px 10px;
  font-size: 15px;
}
.sheet-actions .secondary {
  min-width: 96px;
  padding: 14px;
  gap: 7px;
  font-size: 14px;
  font-weight: 500;
}
.sheet-actions .secondary[aria-pressed="true"] {
  color: var(--accent-soft);
  background: var(--accent-tint);
}
.sheet-actions svg {
  width: 16px;
  height: 16px;
}
.sheet .primary {
  font-weight: 500;
}

/* Rows shared by sheets and settings pages. */
/* Setting rows: hairline-divided lists whose separators run edge to edge. */
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: calc(100% + 2 * var(--gutter));
  margin-inline: calc(-1 * var(--gutter));
  text-align: start;
  gap: var(--space-3);
  min-height: 56px;
  padding: var(--space-3) var(--gutter);
  border-bottom: 1px solid var(--hairline);
  font-size: 16px;
  color: var(--text-1);
}
.setting-row:last-child {
  border-bottom: 0;
}
.setting-row small {
  display: block;
  color: var(--text-3);
  font-size: 12px;
  line-height: 1.4;
  margin-top: 2px;
}
.setting-row svg {
  width: 18px;
  height: 18px;
  color: var(--text-3);
}
.setting-row select {
  max-width: 55%;
}
.more-value {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--text-2);
  font-size: 13px;
}
.setting-row[aria-pressed="true"] .more-value {
  color: var(--accent-soft);
}
.more-setting {
  padding-block: var(--space-2);
  gap: 10px;
}
.language-form {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  max-width: 55%;
}
.setting-row .language-form select {
  max-width: 100%;
  width: 100%;
}
.more-report {
  display: flex;
  align-items: center;
  font-size: 14px;
  color: var(--text-2);
  padding: var(--space-3) 0;
  text-align: start;
  min-height: 44px;
}

/* Chapters sheet */
.chapter-summary {
  display: grid;
  gap: 4px;
  padding: var(--space-2) 0 var(--space-4);
  font-size: 14px;
  color: var(--text-2);
}
.chapter-summary > :last-child {
  color: var(--accent-soft);
  font-size: 12px;
}
.chapter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(48px, 1fr));
  gap: var(--space-2);
  margin: 0 0 20px;
}
.chapter-grid :is(a, span) {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 48px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  font-size: 16px;
  color: var(--text-1);
}
.chapter-grid a[aria-current="true"] {
  background: var(--accent);
  color: #fff;
  font-weight: 600;
}
.chapter-grid span {
  opacity: 0.45;
}
.chapter-grid svg {
  width: 11px;
}
.chapter-restart {
  display: flex;
  width: 100%;
  font-size: 14px;
  margin-bottom: var(--space-2);
}
@media (max-width: 350px) {
  .chapter-grid {
    gap: 6px;
  }
}

/* ---------- Profile ---------- */
.profile {
  max-width: var(--column);
  padding-bottom: max(28px, env(safe-area-inset-bottom));
}
.profile-account {
  padding: 22px var(--space-5) 28px;
  text-align: center;
}
.avatar {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: 50%;
  margin: 0 auto var(--space-4);
}
.avatar svg {
  width: 28px;
  height: 28px;
}
.profile-account h2 {
  font-size: 23px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.profile-account .profile-guest-title {
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.15;
}
.profile-account p {
  color: var(--text-2);
  font-size: 14px;
  margin: 10px 0 20px;
  line-height: 1.5;
}
.profile-account .primary {
  min-width: 140px;
}
.profile-guest-status {
  display: block;
  color: var(--text-3);
  font-size: 12px;
  line-height: 1.4;
  margin-top: var(--space-3);
}
.settings-group {
  margin: 0 var(--gutter);
}
.settings-group h3 {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: 0.7px;
  text-transform: uppercase;
  margin: 26px 0 var(--space-2);
}
.settings-group .primary {
  width: 100%;
}
.profile .setting-row {
  font-size: 15px;
}
.profile .setting-row svg {
  width: 16px;
  height: 16px;
}

/* Sign-in sheet + Google button */
.sign-in-content,
.sign-in-content > form,
.google-option {
  display: grid;
  gap: var(--space-4);
}
.sign-in-content > p {
  color: var(--text-2);
  line-height: 1.5;
}
.sign-in-content label {
  display: grid;
  gap: var(--space-2);
  font-size: 14px;
  color: var(--text-2);
}
.sign-in-content input {
  width: 100%;
  font-size: 16px;
  padding: 12px;
  height: var(--control-height);
}
.sign-in-divider {
  text-align: center;
  color: var(--text-3);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.google-option form {
  margin: 0;
}
/* Google's published HTML button: official G paths, dark-theme colors and sizing. */
.google-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid #8e918f;
  border-radius: 4px;
  background: #131314;
  color: #e3e3e3;
  font:
    500 14px/20px "Roboto",
    Arial,
    sans-serif;
  letter-spacing: 0.25px;
}
.google-button:hover {
  background: #252526;
}
.google-button svg {
  flex: 0 0 20px;
}
.google-option .fine {
  margin: 0;
}

/* ---------- Account / help / legal pages ---------- */
.account-page {
  width: 100%;
  max-width: var(--column);
  margin: 0 auto;
  background: transparent;
  padding: 0 var(--gutter) calc(var(--space-5) + env(safe-area-inset-bottom));
  min-height: 100dvh;
}
.account-page .page-header {
  margin: 0 calc(-1 * var(--gutter));
}
.panel {
  padding: var(--space-5) 0 0;
}
.panel + .panel {
  margin-top: var(--space-6);
  padding-top: 0;
}
.panel h1,
.panel .account-title {
  font-size: 25px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.3px;
  margin: var(--space-3) 0 var(--space-4);
}
.panel h2 {
  font-size: 19px;
  font-weight: 600;
  margin-bottom: var(--space-4);
}
.panel p {
  color: var(--text-2);
  margin: 14px 0;
  overflow-wrap: anywhere;
}
.panel form {
  display: grid;
  gap: var(--space-4);
  margin: 18px 0;
}
.panel form > label {
  display: grid;
  gap: var(--space-2);
}
.panel form .quiet {
  min-height: 44px;
}
.panel :is(form, p):last-child {
  margin-bottom: 0;
}
.panel p:first-child {
  margin-top: 0;
}
.panel input:not([type="hidden"]) {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  height: var(--control-height);
}
.dev-note {
  padding: var(--space-3);
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  font-size: 12px;
  margin: var(--space-4) 0;
}
.verification-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}
.verification-actions form {
  margin: 0;
}
.support-address {
  overflow-wrap: anywhere;
}
.resume-story {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-inline: calc(-1 * var(--gutter));
  padding: var(--space-3) var(--gutter);
  border-bottom: 1px solid var(--hairline);
}
.resume-story:last-child {
  border-bottom: 0;
}
.resume-story img {
  width: 54px;
  height: 72px;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.resume-story > span {
  flex: 1;
  min-width: 0;
}
.resume-story strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
}
.resume-story small {
  display: block;
  color: var(--text-2);
  font-size: 13px;
  margin-top: 6px;
}
.legal {
  padding-bottom: 30px;
}
.legal .legal-title {
  font-size: 25px;
  font-weight: 600;
  margin: 0 0 var(--space-5);
}
.legal h3 {
  font-size: 17px;
  font-weight: 600;
  margin: var(--space-5) 0 var(--space-2);
}
.legal p {
  margin: 0 0 var(--space-3);
}
.legal .fine {
  margin: 0 0 var(--space-4);
  padding: 10px 12px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
}
@media (prefers-reduced-motion: reduce) {
  :is(
    .primary,
    .secondary,
    .filter-pills button,
    .show-open,
    .chapter-grid a,
    .chapter-restart,
    .unlimited-button
  ):active {
    transform: none;
  }
}

/* Caught-up page */
.caught-up {
  text-align: center;
}
.caught-up > img {
  width: 108px;
  height: 144px;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-md);
  margin: 0 auto;
}
.caught-up .status-line {
  color: var(--text-2);
  font-size: 13px;
  margin: 0 0 var(--space-3);
}
.caught-up > .secondary {
  width: 100%;
  margin-top: var(--space-2);
}
.caught-up-browse {
  width: 100%;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.related-card {
  display: block;
  border-radius: var(--radius-md);
  overflow: hidden;
}
.related-card .poster {
  height: 168px;
}
.related-card .poster-title {
  font-size: 15px;
  left: 8px;
  right: 8px;
  bottom: 10px;
}
.related-card .poster-title em {
  display: none;
}

/* Paywall: sells the whole library at one price, against pay-per-chapter coins. */
.paywall {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding-top: var(--space-2);
}
.paywall-scroll {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-auto-rows: max-content;
  align-content: start;
  gap: var(--space-4);
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-bottom: var(--space-4);
}
/* This footer stays outside the scroll area and above the sheet's safe-area
   padding: the priced action, then reassurance. */
.paywall-actions {
  display: flex;
  flex-direction: column;
  text-align: center;
}
.paywall-actions form {
  margin: 0;
}
.paywall-status:not(:empty) {
  margin-bottom: var(--space-3);
  font-size: 13px;
  line-height: 1.4;
}
.paywall-assure {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  margin-top: 6px;
  font-size: 12px;
  color: var(--text-3);
}
.paywall-assure > * + *::before {
  content: "·";
  padding-inline: 8px;
}
.paywall-assure > span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding-block: 6px;
  color: var(--gold-strong);
  font-weight: 600;
}
.paywall-assure svg {
  width: 13px;
  height: 13px;
  stroke-width: 3;
}
.paywall-assure a {
  padding-block: 6px;
}
.paywall-eyebrow {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  padding-inline-end: 56px;
}
.paywall-eyebrow svg {
  width: 20px;
  height: 20px;
  color: var(--gold-strong);
  stroke-width: 2.4;
}
.paywall h3 {
  outline: none;
  font-family: var(--font-display);
  font-size: 29px;
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.3px;
  text-wrap: balance;
  margin-top: calc(-1 * var(--space-2));
}
.paywall-lead {
  color: var(--text-2);
  line-height: 1.45;
}
.paywall-shelf {
  display: flex;
  align-items: center;
  padding: 4px 0 4px 10px;
  overflow: hidden;
  mask-image: linear-gradient(to right, #000 65%, transparent);
}
[dir="rtl"] .paywall-shelf {
  mask-image: linear-gradient(to left, #000 65%, transparent);
}
.paywall-shelf > span {
  position: relative;
  flex-shrink: 0;
  margin-inline-start: -6px;
}
.paywall-shelf img {
  width: 64px;
  height: 96px;
  border-radius: var(--radius-sm);
  box-shadow: 0 6px 18px #0009;
  object-fit: cover;
  background: var(--surface-3);
}
.paywall-shelf .current {
  z-index: 1;
  margin-inline-end: 6px;
}
.paywall-shelf .current img {
  width: 72px;
  height: 108px;
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}
.paywall-shelf i {
  position: absolute;
  inset-inline-end: 5px;
  bottom: 5px;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  color: var(--gold-ink);
  background: var(--gold-strong);
  box-shadow: 0 2px 6px #0009;
}
.paywall-shelf i svg {
  width: 12px;
  height: 12px;
  stroke-width: 2.6;
}
/* Coin apps against Unlimited: two panes rather than ruled cells. The coin
   column sits sunk into the sheet; the Unlimited column is lifted and lit gold.
   The panes are painted behind the table, so rows stay aligned however they wrap. */
.compare {
  position: relative;
  margin-top: var(--space-1);
}
.compare::before,
.compare::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: calc(50% - 4px);
  border-radius: var(--radius-md);
}
.compare::before {
  inset-inline-start: 0;
  background: var(--glass);
}
.compare::after {
  inset-inline-end: 0;
  background:
    linear-gradient(to bottom, var(--gold-tint), transparent 70%),
    var(--gold-tint);
  box-shadow:
    inset 0 1px 0 #ffffff26,
    0 10px 30px var(--gold-tint);
}
.compare table {
  position: relative;
  z-index: 1;
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
/* Each column's inner padding also opens the 8px gutter between the panes. */
.compare :is(th, td) {
  padding-block: 8px;
  padding-inline: 12px 16px;
  text-align: start;
  vertical-align: top;
  font-size: 13px;
  line-height: 1.35;
}
.compare :is(th, td):last-child {
  padding-inline: 16px 12px;
}
.compare :is(th, td) > span {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  text-wrap: balance;
}
.compare th {
  padding-top: 14px;
  padding-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}
.compare th > span {
  align-items: center;
}
.compare th:last-child {
  color: var(--gold-strong);
}
.compare th svg {
  width: 16px;
  height: 16px;
}
.compare td {
  color: var(--text-3);
}
.compare td:last-child {
  color: var(--text-1);
  font-weight: 600;
}
.compare td svg {
  width: 14px;
  height: 14px;
  margin-top: 1px;
  stroke-width: 2.6;
}
.compare td:last-child svg {
  box-sizing: content-box;
  width: 10px;
  height: 10px;
  padding: 2px;
  border-radius: 50%;
  color: var(--gold-ink);
  background: var(--gold-strong);
  stroke-width: 3.4;
}
.compare tbody tr:last-child td {
  padding-bottom: 14px;
}
/* The price sits on a second line inside the subscription action. */
.paywall-actions .primary {
  flex-direction: column;
  gap: 1px;
  width: 100%;
  min-height: 52px;
  padding: 9px 18px;
  font-size: 16px;
  font-weight: 700;
  color: var(--gold-ink);
  background: linear-gradient(
    180deg,
    var(--gold-bright),
    var(--gold-strong) 55%,
    var(--gold-deep)
  );
  box-shadow:
    inset 0 1px 0 #ffffff80,
    0 8px 24px var(--gold-tint);
}
.cta-price {
  font-size: 13px;
  font-weight: 600;
  opacity: 0.78;
}
/* Native shows a skeleton there until the store prices the plan. */
[data-native-price][aria-busy="true"]::after {
  content: "";
  display: block;
  width: 6.5rem;
  max-width: 100%;
  height: 1em;
  margin-inline: auto;
  border-radius: var(--radius-xs);
  background: linear-gradient(
    100deg,
    transparent 30%,
    #ffffff66 50%,
    transparent 70%
  ) #0000001f;
  background-size: 200% 100%;
  animation: shimmer 1.6s linear infinite;
}
.paywall .fine-print {
  line-height: 1.45;
}
.paywall .text-button {
  justify-self: center;
}
.paywall-background:after {
  content: "";
  position: absolute;
  inset: 0;
  background: #0005;
}

/* ---------- Visual reader ---------- */
.reader {
  outline: none;
  position: relative;
  width: 100%;
  max-width: var(--column);
  --reader-inset: 24px;
  --passage-height: 240px;
  height: 100dvh;
  min-height: 300px;
  margin: 0 auto;
  background: var(--ink);
  overflow: hidden;
  isolation: isolate;
}
.reader:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.reader-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.reader-shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.reader-shade.top {
  background: linear-gradient(
    to bottom,
    var(--scrim-strong) 0%,
    var(--scrim) calc(var(--passage-height) + 82px),
    transparent calc(var(--passage-height) + 190px)
  );
}
.reader-shade.bottom {
  background:
    linear-gradient(180deg, var(--scrim-soft) 0%, transparent 18%),
    linear-gradient(
      to top,
      var(--scrim-strong) 0%,
      var(--scrim) calc(var(--passage-height) + 36px),
      transparent calc(var(--passage-height) + 155px)
    );
}
.reader-text {
  font-family: var(--font-ui);
  font-synthesis: none;
  font-size: var(--reader-font-size, 20px);
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: 0;
  color: #fff;
  text-shadow: 0 1px 4px #000a;
  overflow-wrap: anywhere;
  white-space: normal;
}
.reader > .reader-text {
  position: absolute;
  left: var(--reader-inset);
  right: var(--reader-inset);
  z-index: 2;
  pointer-events: none;
}
.reader-text.top {
  top: calc(72px + env(safe-area-inset-top));
}
.reader-text.bottom {
  bottom: calc(38px + env(safe-area-inset-bottom));
}
.reader-text p {
  margin: 0;
}
.reader-text p:last-child {
  margin-bottom: 0;
}
.reading-block + .reading-block {
  margin-top: 14px;
}
.speaker {
  font-size: 12px;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 6px;
  text-shadow: 0 1px 4px #000;
}
.reading-block[data-kind="narration"] {
  font-family: var(--font-narration);
  font-style: italic;
  font-synthesis: style;
}
.reader-text:lang(ja),
.reader-text:lang(zh) {
  line-break: strict;
  overflow-wrap: normal;
}
.reader-measure {
  padding: 0;
  margin: 0;
}
.reader:not(.enhanced) .reader-text {
  max-height: calc(100dvh - 150px);
  overflow-y: auto;
  pointer-events: auto;
  z-index: 4;
}
/* Story-style segments: one per card, filled as the reader advances. */
.reader-progress {
  position: absolute;
  top: calc(8px + env(safe-area-inset-top));
  left: 8px;
  right: 8px;
  display: flex;
  gap: 3px;
  z-index: 4;
  height: 3px;
}
.reader-progress span {
  flex: 1;
  background: #ffffff40;
  border-radius: 2px;
  overflow: hidden;
}
.reader-progress i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--text-1);
}
.reader-progress i.complete {
  width: 100%;
}
.reader-controls {
  position: absolute;
  right: 8px;
  top: calc(16px + env(safe-area-inset-top));
  display: flex;
  gap: 0;
  z-index: 6;
}
.reader-controls a {
  color: #ffffffd9;
  border-radius: 0;
  background: transparent;
  filter: drop-shadow(0 1px 2px #0006);
}
.reader-controls a:hover {
  color: #fff;
}
.reader-controls svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.6;
}
.reader-tap {
  position: absolute;
  z-index: 3;
  top: 0;
  bottom: 0;
  width: 50%;
  border-radius: 0;
}
.reader-tap.previous {
  left: 0;
}
.reader-tap.next {
  right: 0;
}
.reader-tap:focus-visible {
  outline-offset: -5px;
}
.reader-fallback {
  position: absolute;
  bottom: 8px;
  left: 0;
  width: 100%;
  text-align: center;
  z-index: 5;
  font-size: 12px;
}
.inline-notice {
  position: absolute;
  z-index: 5;
  bottom: calc(16px + env(safe-area-inset-bottom));
  left: var(--space-4);
  right: var(--space-4);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: var(--panel-overlay);
  font-size: 13px;
  text-align: center;
}
/* End-of-chapter beat: a scrim over the last image; taps still reach the zones. */
.reader-end {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: var(--space-3);
  padding: var(--space-5) var(--space-5)
    calc(40px + env(safe-area-inset-bottom));
  background: linear-gradient(
    to bottom,
    var(--scrim-faint),
    var(--scrim-strong) 55%
  );
  pointer-events: none;
  text-align: center;
}
.reader-end > * {
  pointer-events: auto;
}
.reader-end .eyebrow {
  color: var(--gold);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.reader-end h2 {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin-bottom: var(--space-3);
  text-shadow: 0 2px 14px #000a;
}
.reader-end .primary {
  width: 100%;
}
.reader-end .secondary {
  width: 100%;
  background: #ffffff1a;
}
.reader-end .secondary[aria-pressed="true"] {
  color: var(--accent-soft);
}
.reader.ended .reader-controls {
  z-index: 6;
}
/* First-read guide: the original client's full overlay, with motion that shows
   the gesture — pulsing tap points on each half — and a staggered entrance. */
.reader-guide {
  position: absolute;
  inset: 0;
  z-index: 9;
  color: #fff;
  background: var(--scrim-guide);
  text-align: center;
  outline: none;
  animation: guide-in 0.3s ease-out both;
}
.reader-guide.leaving {
  animation: guide-out 0.22s ease-in both;
  pointer-events: none;
}
.reader-guide h2 {
  position: absolute;
  top: 30%;
  left: var(--space-5);
  right: var(--space-5);
  font-size: 23px;
  line-height: 1.35;
  font-weight: 500;
  text-shadow: 0 1px 8px #000;
  animation: guide-rise 0.45s 0.1s ease-out both;
}
.tap-guide {
  position: absolute;
  top: 40%;
  bottom: 26%;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.tap-guide p {
  margin: 0;
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  font-size: 16px;
  line-height: 1.5;
  text-shadow: 0 1px 8px #000;
  cursor: pointer;
  animation: guide-rise 0.45s ease-out both;
}
.tap-guide p:first-child {
  animation-delay: 0.18s;
}
.tap-guide p + p {
  border-inline-start: 1px solid #ffffff60;
  animation-delay: 0.26s;
}
/* The tap point: the app's chevron in a ring, with a pulse expanding from it. */
.tap-point {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 2px solid #ffffffd9;
  background: #ffffff1a;
  box-shadow: 0 0 0 0 #ffffff80;
  animation: guide-pulse 1.8s ease-out infinite;
}
.tap-point svg {
  width: 26px;
  height: 26px;
  stroke-width: 2.2;
}
.tap-point.back svg {
  transform: scaleX(-1);
}
[dir="rtl"] .tap-point.back svg {
  transform: none;
}
.tap-guide p[data-guide-move="1"] .tap-point {
  animation-delay: 0.9s;
}
@keyframes guide-pulse {
  0% {
    box-shadow: 0 0 0 0 #ffffff80;
    transform: scale(0.96);
  }
  50% {
    transform: scale(1);
  }
  100% {
    box-shadow: 0 0 0 26px #ffffff00;
    transform: scale(0.96);
  }
}
.tap-guide[data-input="pointer"] {
  display: none;
}
@media (hover: hover) and (pointer: fine) {
  .tap-guide[data-input="touch"] {
    display: none;
  }
  .tap-guide[data-input="pointer"] {
    display: grid;
  }
}
.start-reading {
  position: absolute;
  bottom: 14%;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 48px);
  min-height: 48px;
  padding: 12px 24px;
  border: 1px solid #ffffff90;
  border-radius: 999px;
  background: var(--text-1);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.4;
  animation: guide-rise-centered 0.45s 0.36s ease-out both;
  transition: transform 0.12s ease;
}
.start-reading:active {
  transform: translateX(-50%) scale(0.97);
}
@keyframes guide-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes guide-out {
  to {
    opacity: 0;
  }
}
@keyframes guide-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes guide-rise-centered {
  from {
    opacity: 0;
    transform: translate(-50%, 10px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%);
  }
}
/* Wide screens: the phone column sits on a blurred, dimmed cover instead of a void. */
.reader-backdrop {
  display: none;
}
@media (min-width: 700px) {
  .reader {
    box-shadow: 0 0 80px #000c;
  }
  .reader-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: -1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(48px) brightness(0.35) saturate(0.8);
    transform: scale(1.15);
  }
}

/* ---------- Text mode ---------- */
.text-reader-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-2) 0 var(--space-4);
  font-size: 13px;
  color: var(--text-2);
}
.text-reader-bar .text-button {
  color: var(--accent-soft);
  padding: 10px 0;
}
.text-reader article {
  font-size: 18px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.text-card {
  margin-bottom: var(--space-6);
  scroll-margin-top: calc(var(--header-height) + env(safe-area-inset-top));
}
.text-card p + p {
  margin-top: var(--space-4);
}
.text-card p[data-kind="narration"] {
  font-family: var(--font-narration);
  font-style: italic;
  color: var(--text-2);
}
.text-card strong {
  font-weight: 600;
  color: var(--gold);
}
.text-reader .primary {
  width: 100%;
}

/* ---------- Notices, a11y, motion, RTL ---------- */
@media (max-width: 350px) {
  .reader {
    --reader-inset: 18px;
  }
}
[dir="rtl"] [data-icon="back"],
[dir="rtl"] [data-icon="chevron"] {
  transform: scaleX(-1);
}
[dir="rtl"] .reader-tap.next {
  left: 0;
  right: auto;
}
[dir="rtl"] .reader-tap.previous {
  right: 0;
  left: auto;
}

.filter-pills button,
.show-open,
.chapter-grid a,
.chapter-restart {
  transition:
    transform 0.12s ease,
    filter 0.12s ease;
}
:is(
  .filter-pills button,
  .show-open,
  .chapter-grid a,
  .chapter-restart
):active {
  transform: scale(0.98);
}
/* Native billing uses the same paywall and account controls as the web. */
.native-actions { display: grid; gap: .65rem; }
[data-native-billing] .fine-print { margin: .25rem 0; }

/* ---------- Welcome: the installed app's first launch ---------- */
.welcome {
  max-width: var(--column);
  margin: 0 auto;
  outline: none;
}
.welcome-step {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding: calc(env(safe-area-inset-top) + var(--space-4)) var(--gutter)
    calc(env(safe-area-inset-bottom) + var(--space-4));
  animation: welcome-in 0.35s ease-out;
}
.welcome-step[hidden] {
  display: none;
}
@keyframes welcome-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}
.welcome :is(h1, h2) {
  outline: none;
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.3px;
  text-wrap: balance;
  color: #fff;
}
.welcome h1 {
  font-size: 36px;
}
.welcome h2 {
  font-size: 29px;
}
.welcome-lead {
  margin-top: var(--space-2);
  color: var(--text-2);
  font-size: 16px;
  line-height: 1.45;
}
/* The hook: covers drift in three columns behind the promise. Each column holds
   its covers twice, so moving it up by half loops without a seam. */
.welcome-hook {
  position: relative;
  justify-content: flex-end;
  overflow: hidden;
}
.welcome-wall {
  position: absolute;
  inset: -10% -8%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  transform: rotate(-7deg);
}
.welcome-wall > div {
  animation: welcome-drift 60s linear infinite;
}
.welcome-wall > div:nth-child(2) {
  animation-direction: reverse;
}
.welcome-wall img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  margin-bottom: 10px;
  object-fit: cover;
  border-radius: var(--radius-md);
  background: var(--surface-3);
}
@keyframes welcome-drift {
  to {
    transform: translateY(-50%);
  }
}
.welcome-hook::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    var(--scrim-soft),
    transparent 22%,
    var(--scrim) 58%,
    var(--bg) 78%
  );
}
.welcome-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: var(--space-3);
  text-align: center;
}
.welcome-copy .paywall-eyebrow {
  justify-content: center;
  padding-inline-end: 0;
}
.welcome-hook .welcome-lead {
  margin: 0 0 var(--space-3);
  color: var(--gold);
  font-size: 17px;
  font-weight: 600;
}
.welcome .primary {
  width: 100%;
  min-height: 54px;
  font-size: 16px;
  font-weight: 600;
}
.welcome .primary:disabled {
  opacity: 0.4;
}
.welcome-age {
  font-size: 12px;
  color: var(--text-3);
}
.welcome-progress {
  display: flex;
  gap: 6px;
  margin: 0 0 var(--space-6);
  padding: 0;
  list-style: none;
}
.welcome-progress li {
  flex: 1;
  height: 3px;
  border-radius: 2px;
  background: var(--glass-strong);
}
.welcome-progress .done {
  background: var(--accent);
}
/* The action stays reachable over long lists on short phones. */
.welcome-actions {
  position: sticky;
  bottom: 0;
  margin-top: auto;
  padding-top: var(--space-5);
  background: linear-gradient(to bottom, transparent, var(--bg) 30%);
}
/* Taste: cover tiles, up to three lit gold. */
.welcome-tastes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: var(--space-5);
}
.welcome-taste {
  position: relative;
  height: 88px;
  padding: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--surface-3);
  color: #fff;
  text-align: start;
  transition: transform 0.12s ease;
}
.welcome-taste:active {
  transform: scale(0.97);
}
.welcome-taste img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 25%;
  filter: brightness(0.5);
  transition: filter 0.2s ease;
}
.welcome-taste span {
  position: absolute;
  inset-inline-start: 12px;
  bottom: 10px;
  font-size: 15px;
  font-weight: 600;
  text-shadow: 0 1px 6px #000c;
}
.welcome-taste i {
  position: absolute;
  top: 8px;
  inset-inline-end: 8px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--scrim-soft);
  color: transparent;
}
.welcome-taste i svg {
  width: 13px;
  height: 13px;
  stroke-width: 3;
}
.welcome-taste[aria-pressed="true"] {
  outline: 2px solid var(--gold-strong);
  outline-offset: -2px;
}
.welcome-taste[aria-pressed="true"] img {
  filter: brightness(0.8);
}
.welcome-taste[aria-pressed="true"] i {
  background: var(--gold-strong);
  color: var(--gold-ink);
}
/* Her three stories: cover, title and the gold hook line. */
.welcome-picks {
  display: grid;
  gap: var(--space-3);
  margin: var(--space-5) 0 0;
  padding: 0;
  list-style: none;
}
.welcome-picks li {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 10px;
  border-radius: var(--radius-md);
  background: var(--glass);
  animation: welcome-in 0.4s ease-out backwards;
}
.welcome-picks li[hidden] {
  display: none;
}
.welcome-picks li:nth-child(2) {
  animation-delay: 0.08s;
}
.welcome-picks li:nth-child(3) {
  animation-delay: 0.16s;
}
.welcome-picks img {
  width: 76px;
  height: 114px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--surface-3);
}
.welcome-picks strong {
  display: block;
  margin-bottom: 4px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.25;
  color: #fff;
}
.welcome-picks em {
  font-family: var(--font-display);
  font-size: 15px;
  line-height: 1.35;
  color: var(--gold);
}
/* The paywall: her covers fanned on top, the promise, the priced action. */
.welcome-paywall {
  text-align: center;
}
.welcome-fan {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  margin: var(--space-3) 0 var(--space-5);
}
.welcome-fan span {
  position: relative;
  flex-shrink: 0;
  width: 104px;
}
.welcome-fan span:nth-child(1) {
  transform: translate(22px, 8px) rotate(-9deg);
}
.welcome-fan span:nth-child(2) {
  z-index: 1;
  width: 124px;
}
.welcome-fan span:nth-child(3) {
  transform: translate(-22px, 8px) rotate(9deg);
}
.welcome-fan img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: var(--radius-md);
  box-shadow: 0 14px 32px #000b;
  background: var(--surface-3);
}
.welcome-fan i {
  position: absolute;
  inset-inline-end: 6px;
  bottom: 6px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: var(--gold-ink);
  background: var(--gold-strong);
  box-shadow: 0 2px 6px #0009;
}
.welcome-fan i svg {
  width: 15px;
  height: 15px;
  stroke-width: 2.6;
}
.welcome-paywall .paywall-eyebrow {
  justify-content: center;
  padding-inline-end: 0;
  margin-bottom: var(--space-2);
}
.welcome-benefits {
  display: grid;
  gap: var(--space-3);
  width: fit-content;
  margin: var(--space-5) auto 0;
  padding: 0;
  list-style: none;
  text-align: start;
}
.welcome-benefits li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 600;
}
.welcome-benefits svg {
  box-sizing: content-box;
  flex-shrink: 0;
  width: 12px;
  height: 12px;
  padding: 3px;
  border-radius: 50%;
  color: var(--gold-ink);
  background: var(--gold-strong);
  stroke-width: 3.4;
}
.welcome-free {
  display: block;
  margin-top: var(--space-2);
  padding: 12px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
}
.welcome-paywall .fine-print {
  color: var(--text-3);
  line-height: 1.45;
}
.welcome-paywall .text-button {
  min-height: 36px;
  padding: 6px;
  font-size: 13px;
}
@media (prefers-reduced-motion: reduce) {
  .welcome-wall > div,
  .welcome-step,
  .welcome-picks li {
    animation: none;
  }
}
.welcome-paywall h2 span {
  display: block;
}
/* The paywall flows to its action instead of floating it over the promise. */
.welcome-paywall .welcome-actions {
  position: static;
  background: none;
}
@media (max-height: 740px) {
  .welcome-fan {
    margin: 0 0 var(--space-3);
  }
  .welcome-fan span {
    width: 80px;
  }
  .welcome-fan span:nth-child(2) {
    width: 96px;
  }
  .welcome h2 {
    font-size: 25px;
  }
  .welcome-benefits {
    gap: var(--space-2);
    margin-top: var(--space-4);
  }
  .welcome-benefits li {
    font-size: 15px;
  }
  .welcome-paywall .welcome-actions {
    padding-top: var(--space-4);
  }
}

/* ---------- Age sheet: over any story until this device confirms an adult ---------- */
body:has(> .age-gate) > :is(main, .reader-backdrop) {
  filter: blur(24px);
}
.age-gate {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 var(--space-3) calc(env(safe-area-inset-bottom) + var(--space-3));
  background: var(--scrim-soft);
}
.age-gate-panel {
  display: grid;
  gap: var(--space-3);
  width: 100%;
  max-width: var(--column);
  padding: var(--space-5) var(--gutter) var(--space-3);
  border-radius: var(--radius-lg);
  background: var(--panel-overlay);
  text-align: center;
  animation: welcome-in 0.3s ease-out;
}
.age-gate h2 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.15;
  color: #fff;
}
.age-gate p {
  margin-bottom: var(--space-2);
  color: var(--text-2);
  line-height: 1.45;
}
.age-gate .primary {
  width: 100%;
  min-height: 52px;
  font-size: 16px;
  font-weight: 600;
}
.age-gate-panel:focus {
  outline: none;
}

/* ---------- Launch spotlight: one story, full screen, on a fresh app start ---------- */
.spotlight {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--bg);
  outline: none;
  animation: guide-in 0.3s ease-out both;
}
.spotlight[hidden] {
  display: none;
}
.spotlight.leaving {
  animation: guide-out 0.3s ease-in both;
  pointer-events: none;
}
.spotlight-art {
  position: absolute;
  inset: 0;
}
.spotlight-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}
.spotlight-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    #00000040 0%,
    #00000000 18%,
    #00000000 45%,
    #000000c0 70%,
    #000000f5 100%
  );
}
.spotlight-skip {
  position: absolute;
  top: calc(12px + env(safe-area-inset-top));
  right: var(--gutter);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
  padding: 0 8px 0 14px;
  border-radius: 999px;
  color: var(--text-1);
  font-size: 13px;
  background: var(--scrim-faint);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.spotlight-countdown {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}
/* The ring empties over the three seconds, so the reader sees why the card leaves. */
.spotlight-timer {
  position: relative;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}
.spotlight-timer svg {
  position: absolute;
  inset: 0;
  transform: rotate(-90deg);
}
.spotlight-timer circle {
  fill: none;
  stroke: var(--text-1);
  stroke-width: 1.6;
  stroke-dasharray: 100;
}
.spotlight.counting .spotlight-timer circle {
  animation: spotlight-ring 3s linear forwards;
}
@keyframes spotlight-ring {
  to {
    stroke-dashoffset: 100;
  }
}
.spotlight-close {
  display: none;
}
.spotlight-close svg {
  width: 18px;
  height: 18px;
}
/* A touch on the cover: no more countdown, the card waits for the reader. */
.spotlight.held .spotlight-skip {
  padding: 0;
}
.spotlight.held .spotlight-countdown {
  display: none;
}
.spotlight.held .spotlight-close {
  display: grid;
}
.spotlight-synopsis {
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-height: 0;
  /* Collapsed, it also takes back the body's gap. */
  margin: calc(-1 * var(--space-3)) 0 0;
  opacity: 0;
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.5;
  text-align: left;
  transition:
    max-height 0.35s ease,
    opacity 0.35s ease,
    margin 0.35s ease;
}
.spotlight.held .spotlight-synopsis {
  /* Above five lines, so the clamp's ellipsis ends the text, not the height. */
  max-height: 9em;
  margin: 0 0 var(--space-2);
  opacity: 1;
}
.spotlight-body {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  width: 100%;
  max-width: var(--column);
  margin: 0 auto;
  padding: 0 var(--gutter) calc(var(--space-5) + env(safe-area-inset-bottom));
  text-align: center;
  pointer-events: none;
}
.spotlight-body > a {
  pointer-events: auto;
}
.spotlight-body em {
  font-family: var(--font-narration);
  font-size: 17px;
  line-height: 1.35;
  color: var(--gold);
  text-shadow: 0 2px 14px #000a;
}
.spotlight-body h2 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1.05;
  letter-spacing: -0.6px;
  text-shadow: 0 2px 14px #000a;
}
.spotlight-body .primary {
  padding: 16px;
}
/* The story in progress: a compact glass pill, a second way in that doesn't
   compete with the main action. */
.spotlight-continue {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  align-self: center;
  max-width: 100%;
  padding: 6px 10px 6px 6px;
  border-radius: 999px;
  color: var(--text-1);
  font-size: 14px;
  background: var(--glass-strong);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.spotlight-continue span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.spotlight-continue img {
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}
.spotlight-continue svg {
  flex: none;
  width: 14px;
  height: 14px;
  opacity: 0.7;
}
@media (prefers-reduced-motion: reduce) {
  .spotlight,
  .spotlight.leaving,
  .spotlight.counting .spotlight-timer circle {
    animation: none;
  }
  .spotlight-synopsis {
    transition: none;
  }
}
