/* ==========================================================================
   Candy Shorts — design tokens lifted from candy.ai's production stylesheet
   (--primary-color:#f97187, --surface-primary-color:#1a1a1a, base #131313).
   ========================================================================== */

:root {
  /* Light by default. candy.ai's brand pink (#f97187) stays exact for fills;
     text and buttons use a deeper pink so contrast on white actually passes. */
  --pink:        #f97187;   /* brand fill, badges, borders */
  --pink-ink:    #c9234b;   /* links and body accents — 5.5:1 on white */
  --pink-strong: #d42a55;   /* button background, white text — 4.9:1 */
  --pink-dark:   #ab1b3e;
  --pink-soft:   #f894a6;
  --pink-semi:   rgb(249 113 135 / 0.45);
  --pink-glow:   rgb(249 113 135 / 0.12);

  /* candy.ai ships an orange Shorts theme (--shorts-accent:#fa5b2d);
     darkened here so it reads on a light surface. */
  --coral:       #d6401c;
  --coral-glow:  rgb(250 91 45 / 0.12);

  --gold:        #8a6210;   /* unused today; kept AA-safe on white */
  --gold-light:  #fff4d6;

  --bg:          #ffffff;
  --bg-deep:     #faf8fb;   /* sidebar */
  --surface:     #ffffff;
  --surface-2:   #f6f4f8;
  --surface-3:   #eceaf0;
  --line:        #e4e0e9;
  --line-soft:   rgb(0 0 0 / 0.07);

  --text:        #16141a;
  --text-dim:    #3d3947;
  --muted:       #6b6673;

  --shadow-sm:   0 1px 2px rgb(22 20 26 / .05);
  --shadow-md:   0 4px 16px -6px rgb(22 20 26 / .14);


  --sidebar-w:   258px;
  --head-h:      62px;
  --radius:      16px;
  --radius-sm:   10px;
  --max:         1320px;

  --font-head: "Outfit", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

/* Dark set kept ready: adding the toggle later means writing data-theme="dark"
   on <html> and a button to flip it. Nothing else has to change. */
:root[data-theme="dark"] {
  --pink:        #f97187;
  --pink-ink:    #f97187;
  --pink-strong: #f97187;
  --pink-dark:   #e0576f;
  --pink-soft:   #f894a6;
  --pink-semi:   rgb(249 113 135 / 0.34);
  --pink-glow:   rgb(249 113 135 / 0.12);

  --coral:       #fa5b2d;
  --coral-glow:  rgb(250 91 45 / 0.13);

  --gold:        #f7c65a;
  --gold-light:  #ffe7ad;

  --bg:          #121016;
  --bg-deep:     #0c0a10;
  --surface:     #1a1820;
  --surface-2:   #211f28;
  --surface-3:   #2b2934;
  --line:        #2a2833;
  --line-soft:   rgb(255 255 255 / 0.06);

  --text:        #f2f1f4;
  --text-dim:    #c6c4cd;
  --muted:       #9c99a6;

  --shadow-sm:   none;
  --shadow-md:   none;

}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }

a { color: var(--pink-ink); text-decoration: none; }
a:hover { color: var(--pink-dark); text-decoration: underline; }

:focus-visible { outline: 2px solid var(--pink-ink); outline-offset: 2px; border-radius: 4px; }

/* ------------------------------------------------------------- site header */

.skip-link {
  position: absolute; left: -9999px;
  background: var(--surface); color: var(--text);
  padding: 10px 16px; border-radius: var(--radius-sm); z-index: 300;
}
.skip-link:focus { left: 12px; top: 12px; }

.site-head {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--head-h);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.site-head__inner { display: flex; align-items: center; gap: 12px; height: var(--head-h); }

.brand { display: flex; align-items: center; gap: 10px; color: inherit; }
.brand:hover { text-decoration: none; }

.brand__mark {
  width: 30px; height: 30px; flex: 0 0 30px;
  border-radius: 9px;
  background: linear-gradient(145deg, var(--pink) 0%, var(--pink-dark) 100%);
  display: grid; place-items: center;
  color: #fff;
  font-family: var(--font-head);
  font-weight: 800; font-size: .88rem;
}

.brand__name {
  font-family: var(--font-head);
  font-weight: 700; font-size: 1.02rem;
  letter-spacing: -.015em; color: var(--text); line-height: 1.15;
}
.brand__name span { display: block; font-weight: 400; font-size: .7rem; color: var(--muted); letter-spacing: 0; }

/* ----------------------------------------------------------------- layout */

.layout {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  align-items: start;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0;
  padding: 0 32px;
}

.shell { min-width: 0; display: flex; flex-direction: column; min-height: calc(100vh - var(--head-h)); }
.site-main { flex: 1 0 auto; padding: 0 0 72px; }
.site-main > .wrap:first-child { padding-top: 28px; }

/* ----------------------------------------------------------------- sidebar */

.sidebar {
  position: sticky;
  top: var(--head-h);
  height: calc(100vh - var(--head-h));
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--bg-deep);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  z-index: 40;
}

.sidebar__nav { padding: 12px 10px 10px; }
.sidebar__nav ul { list-style: none; margin: 0; padding: 0; }
.sidebar__nav li { margin: 1px 0; }

.sidebar__label {
  font-size: .66rem;
  text-transform: uppercase;
  letter-spacing: .11em;
  color: var(--muted);
  padding: 16px 10px 5px;
  margin: 0;
  font-weight: 600;
}

.sb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-dim);
  font-size: .9rem;
  font-weight: 500;
  transition: background .14s ease, color .14s ease;
}
.sb-item:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }

.sb-icon { width: 17px; height: 17px; flex: 0 0 17px; opacity: .7; }
.sb-item__label { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sb-item__badge {
  flex: 0 0 auto;
  font-size: .68rem; font-weight: 700;
  padding: 1px 7px; border-radius: 999px;
  background: var(--surface-3); color: var(--muted);
}

.sb-rank {
  flex: 0 0 17px;
  font-family: var(--font-head);
  font-size: .72rem; font-weight: 700;
  color: var(--muted); text-align: center;
}
.sb-score { flex: 0 0 auto; font-size: .68rem; font-weight: 700; color: var(--muted); }
.sb-score[data-level="5"] { color: var(--coral); }
.sb-score[data-level="4"] { color: var(--pink-ink); }

/* --- active state: solid pill --- */
.is-active > .sb-item {
  background: var(--pink-strong);
  color: #fff;
  font-weight: 600;
}
.is-active > .sb-item:hover { background: var(--pink-dark); color: #fff; }
.is-active > .sb-item .sb-icon { opacity: 1; }

/* Badges and scores invert too, or they stay grey on a pink pill. */
.is-active > .sb-item .sb-rank  { color: rgb(255 255 255 / .82); }
.is-active > .sb-item .sb-score { color: #fff; }
.is-active > .sb-item .sb-item__badge { background: rgb(255 255 255 / .22); color: #fff; }

.sidebar__cta { margin-top: auto; padding: 14px 14px 18px; border-top: 1px solid var(--line); }
.sidebar__disclaimer { font-size: .68rem; color: var(--muted); line-height: 1.5; margin: 9px 0 0; }

/* -------------------------------------------------------------- mobile nav */

.nav-toggle {
  display: none;
  width: 38px; height: 38px;
  flex: 0 0 38px;
  align-items: center; justify-content: center;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  padding: 0;
}
.nav-toggle svg { width: 19px; height: 19px; }

.nav-scrim {
  display: none;
  position: fixed; inset: 0;
  background: rgb(22 20 26 / .45);
  z-index: 45;
}

/* ------------------------------------------------------------ breadcrumbs */

.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 20px; padding: 0; font-size: .8rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 7px; color: var(--surface-3); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--pink-ink); }

/* ------------------------------------------------------------- typography */

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.16;
  letter-spacing: -.026em;
  margin: 0 0 .48em;
  font-weight: 600;
}
h1 { font-size: clamp(2.25rem, 5.2vw, 3.1rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3.1vw, 1.9rem); margin-top: 2.25em; }
h3 { font-size: 1.18rem; margin-top: 1.8em; font-weight: 650; }
p  { margin: 0 0 1.15em; color: var(--text-dim); }
ul, ol { color: var(--text-dim); padding-left: 1.25em; }
li { margin: .35em 0; }
strong { color: var(--text); font-weight: 650; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.6em 0; }

.eyebrow {
  font-family: var(--font-head);
  display: inline-flex; align-items: center; gap: 7px;
  font-size: .72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--pink-ink);
  background: var(--pink-glow);
  border: 1px solid var(--pink-semi);
  border-radius: 999px;
  padding: 5px 12px;
  margin-bottom: 16px;
}

.lede { font-size: 1.08rem; color: var(--text-dim); max-width: 62ch; }

/* ------------------------------------------------------------------ hero */

/* The hero stays dark on a light site — same call the ranking competitor
   makes, and artwork needs a dark veil to keep text legible over it. */
.hero-wrap { position: relative; margin-bottom: 44px; }

.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  min-height: clamp(420px, 34vw, 620px);
  border-bottom: 1px solid var(--line);
  background: #141414;
}

/* Without artwork: still dark, with a little depth so it is not a flat slab. */
.hero:not(:has(.hero__bg)) {
  background:
    radial-gradient(900px 480px at 80% 12%, rgb(249 113 135 / .26), transparent 66%),
    radial-gradient(680px 420px at 96% 92%, rgb(250 91 45 / .18), transparent 70%),
    #141414;
}

.hero__bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 62% 22%;
  z-index: 0;
  display: block;
}

.hero__overlay {
  position: absolute; inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(90deg,
    rgb(20 20 20 / .92)  0%,
    rgb(20 20 20 / .82) 28%,
    rgb(20 20 20 / .58) 48%,
    rgb(20 20 20 / .18) 66%,
    transparent 78%);
}

.hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--max);
  margin: 0;
  padding: clamp(1.5rem, 4vw, 3.5rem) 32px;
  color: #fff;
}
/* Keep the measure tight even though the container spans the page width. */
.hero__content > * { max-width: 40rem; }

.hero h1 { margin: 0 0 .5rem; font-size: clamp(2.4rem, 5.4vw, 3.5rem); color: #fff; }
.hero h1 .accent { color: var(--pink); }

.hero__tag {
  font-family: var(--font-head);
  font-size: clamp(1.05rem, 1.9vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -.02em;
  color: #fff;
  margin: 0 0 .8rem;
  max-width: 32rem;
}

.hero__lede {
  font-size: clamp(.95rem, 1.3vw, 1.05rem);
  line-height: 1.6;
  font-weight: 500;
  color: rgb(255 255 255 / .86);
  margin: 0 0 1.4rem;
}
.hero__lede strong { color: #fff; }

.hero__cta { display: flex; flex-wrap: wrap; gap: .7rem; margin: 0 0 1.1rem; }
.hero__note { margin: 0; font-size: 11.5px; color: rgb(255 255 255 / .62); }

/* Ghost buttons sit on the dark veil, so they invert. */
.hero .btn--ghost {
  background: rgb(255 255 255 / .10);
  border-color: rgb(255 255 255 / .22);
  color: #fff;
  box-shadow: none;
}
.hero .btn--ghost:hover {
  background: rgb(255 255 255 / .18);
  border-color: rgb(255 255 255 / .38);
  color: #fff;
}

/* Inner pages: no artwork, light surface, ordinary text colours. */
.page-hero { padding: 34px 0 4px; }
.page-hero h1 { margin-bottom: .3em; }
.hero__sub { font-size: 1.14rem; color: var(--muted); font-weight: 500; margin: -.1em 0 1em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 11px; margin-top: 22px; }

/* --------------------------------------------------------------- buttons */

.btn {
  font-family: var(--font-head);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px;
  border-radius: 11px;
  font-weight: 600; font-size: .94rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s ease, filter .14s ease, background .14s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn--primary {
  background: linear-gradient(135deg, var(--pink-strong) 0%, var(--pink-dark) 100%);
  color: #fff;
  box-shadow: 0 6px 20px -10px var(--pink-strong);
}
.btn--primary:hover { color: #fff; filter: brightness(1.08); }
:root[data-theme="dark"] .btn--primary { color: #1a0d10; }
:root[data-theme="dark"] .btn--primary:hover { color: #1a0d10; }

.btn--ghost { background: var(--surface); color: var(--text); border-color: var(--line); box-shadow: var(--shadow-sm); }
.btn--ghost:hover { background: var(--surface-3); color: var(--text); }

.btn--block { width: 100%; }

/* ----------------------------------------------------------------- cards */

.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(196px, 1fr)); margin: 22px 0; }
.grid--6 { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 1240px) { .grid--6 { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 680px)  { .grid--6 { grid-template-columns: repeat(2, 1fr); } }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.card:hover { border-color: var(--pink-semi); transform: translateY(-2px); box-shadow: var(--shadow-md); }

.card__poster {
  display: block;
  position: relative;
  aspect-ratio: 3 / 4;
  background: linear-gradient(158deg, var(--poster-a) 0%, var(--poster-b) 100%);
  display: grid; place-items: center;
}
.card__poster::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgb(0 0 0 / .55) 100%);
}
.card__initial { font-size: 3.2rem; font-weight: 800; color: rgb(255 255 255 / .17); }

.card__badge {
  position: absolute; top: 9px; right: 9px; z-index: 2;
  font-size: .68rem; font-weight: 700;
  padding: 3px 8px; border-radius: 999px;
  background: rgb(0 0 0 / .6);
  border: 1px solid var(--line-soft);
  color: var(--text-dim);
  backdrop-filter: blur(4px);
}
.card__badge[data-level="4"] { color: #ffc2cd; border-color: rgb(249 113 135 / .5); }
.card__badge[data-level="5"] { color: #ffcaa8; border-color: rgb(250 91 45 / .55); background: rgb(0 0 0 / .55); }

.card__body { padding: 13px 14px 15px; }
.card__title { font-family: var(--font-head); font-size: 1rem; margin: 0 0 5px; line-height: 1.32; }
.card__title a { color: var(--text); }
.card__title a:hover { color: var(--pink-ink); text-decoration: none; }
.card__tagline { font-size: .82rem; color: var(--muted); margin: 0 0 9px; line-height: 1.45; }
.card__meta { display: flex; flex-wrap: wrap; gap: 5px 8px; font-size: .74rem; color: var(--muted); margin: 0; }
.card__meta span + span::before { content: "·"; margin-right: 8px; color: var(--surface-3); }

/* ------------------------------------------------------------ data table */

.facts { width: 100%; border-collapse: collapse; margin: 22px 0; font-size: .93rem; }
.facts th, .facts td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.facts th { width: 33%; color: var(--muted); font-weight: 600; }
.facts td { color: var(--text-dim); }
.facts tr:last-child th, .facts tr:last-child td { border-bottom: 0; }
.facts-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 22px 0; }
.facts-wrap .facts { margin: 0; }

/* -------------------------------------------------------------- callouts */

.note {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--pink-ink);
  border-radius: var(--radius-sm);
  padding: 15px 18px;
  margin: 24px 0;
  font-size: .93rem;
}
.note p:last-child { margin-bottom: 0; }
.note strong { color: var(--pink-ink); }

/* ------------------------------------------------------------------- CTA */

.cta-panel {
  background:
    radial-gradient(900px 260px at 18% -40%, rgb(249 113 135 / .18), transparent 70%),
    var(--surface);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  margin: 40px 0;
  text-align: center;
}
.cta-panel h2 { margin: 0 0 8px; font-size: 1.35rem; }
.cta-panel p { color: var(--muted); max-width: 46ch; margin: 0 auto 18px; font-size: .95rem; }

/* ------------------------------------------------------------------- FAQ */

.faq {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  margin: 9px 0;
  overflow: hidden;
}
.faq summary {
  cursor: pointer;
  padding: 14px 17px;
  font-weight: 600;
  font-size: .96rem;
  color: var(--text);
  list-style: none;
  position: relative;
  padding-right: 44px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute; right: 17px; top: 50%;
  transform: translateY(-50%);
  color: var(--pink-ink); font-size: 1.15rem; font-weight: 400;
}
.faq[open] summary::after { content: "−"; }
.faq[open] summary { border-bottom: 1px solid var(--line); }
.faq__a { padding: 14px 17px 4px; font-size: .92rem; }
.faq__a p { color: var(--muted); }

/* ------------------------------------------------------- series template */

.series-head { display: grid; grid-template-columns: 172px 1fr; gap: 24px; align-items: start; margin-bottom: 8px; }
.series-poster {
  aspect-ratio: 3 / 4;
  border-radius: var(--radius);
  background: linear-gradient(158deg, var(--poster-a) 0%, var(--poster-b) 100%);
  display: grid; place-items: center;
  border: 1px solid var(--line);
}
.series-poster span { font-size: 3.6rem; font-weight: 800; color: rgb(255 255 255 / .18); }
.series-head h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); }

.pills { display: flex; flex-wrap: wrap; gap: 7px; margin: 14px 0 18px; padding: 0; list-style: none; }
.pills li {
  font-size: .76rem; font-weight: 600;
  padding: 4px 11px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--line);
  color: var(--text-dim); margin: 0;
}
.pills li[data-hot="1"] { color: var(--coral); border-color: rgb(214 64 28 / .4); background: var(--coral-glow); }

/* -------------------------------------------------------------- filters */

.filters { display: flex; flex-wrap: wrap; gap: 7px; margin: 20px 0 6px; padding: 0; list-style: none; }
.filters a {
  display: inline-block; font-size: .82rem; font-weight: 600;
  padding: 6px 13px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--text-dim);
}
.filters a:hover { border-color: var(--pink-semi); color: var(--pink-ink); text-decoration: none; }
.filters .is-on a { background: var(--pink-glow); border-color: var(--pink-semi); color: var(--pink-ink); }
.filters li { margin: 0; }

/* --------------------------------------------------------------- age gate */

.agegate {
  position: fixed; inset: 0; z-index: 200;
  background: rgb(250 248 251 / .93);
  backdrop-filter: blur(9px);
  display: grid; place-items: center;
  padding: 24px;
}
.agegate[hidden] { display: none; }
.agegate__box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 17px;
  max-width: 420px; width: 100%;
  padding: 30px 28px;
  text-align: center;
  box-shadow: 0 18px 50px -20px rgb(22 20 26 / .35);
}
.agegate__box h2 { margin: 0 0 10px; font-size: 1.28rem; }
.agegate__box p { font-size: .91rem; color: var(--muted); }
.agegate__actions { display: grid; gap: 9px; margin-top: 20px; }

/* ---------------------------------------------------------------- footer */

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-deep);
  padding: 28px 0 40px;
  font-size: .84rem;
  color: var(--muted);
  flex-shrink: 0;
}
.site-footer a { color: var(--text-dim); }
.site-footer a:hover { color: var(--pink-ink); }
.site-footer nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 0; margin: 0 0 14px; }
.site-footer nav li { margin: 0; }
.site-footer p { color: var(--muted); font-size: .8rem; margin: 0 0 .6em; }

/* ------------------------------------------------------------ responsive */

@media (max-width: 1100px) {
  :root { --sidebar-w: 236px; }
  .wrap { padding: 0 24px; }
}

@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); }

  .sidebar {
    position: fixed;
    top: var(--head-h);
    left: 0;
    width: 282px;
    height: calc(100vh - var(--head-h));
    transform: translateX(-100%);
    transition: transform .2s ease;
    z-index: 50;
  }
  body.nav-open .sidebar { transform: none; }
  body.nav-open .nav-scrim { display: block; }

  .nav-toggle { display: inline-flex; }

  .wrap { padding: 0 16px; }
  .hero__content { padding-left: 16px; padding-right: 16px; }
  .brand__name span { display: none; }
  .series-head { grid-template-columns: 116px 1fr; gap: 16px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}
