:root {
  color-scheme: light dark;
  --paper: #f7f7f5;
  --surface: #ffffff;
  --ink: #141414;
  --muted: #545454;
  --line: #c7c7c2;
  --soft: #e9e9e4;
  --amber: #a95700;
  --amber-strong: #7b3d00;
  --shadow: rgba(0,0,0,.16);
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Source Serif 4", Georgia, serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d0d0e;
    --surface: #171719;
    --ink: #f3f2ed;
    --muted: #b9b8b2;
    --line: #3c3b3d;
    --soft: #232326;
    --amber: #ffb044;
    --amber-strong: #ffd08a;
    --shadow: rgba(0,0,0,.52);
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
  overflow-x: hidden;
}
img { display: block; width: 100%; }
button, a { font: inherit; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }
.skip { position: fixed; left: 12px; top: -80px; z-index: 30; background: var(--surface); padding: 8px 12px; }
.skip:focus { top: 12px; }
.mastnav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: center;
  gap: clamp(18px, 5vw, 48px);
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(10px);
}
.mastnav a {
  text-decoration: none;
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: .82rem;
}
.mastnav a[aria-current="page"] { color: var(--amber-strong); }
.hero {
  position: relative;
  min-height: min(790px, 88vh);
  display: grid;
  align-items: end;
  isolation: isolate;
  background: #050505;
  color: #fff;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(0,0,0,.04) 16%, rgba(0,0,0,.16) 47%, rgba(0,0,0,.9) 100%);
}
.hero img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 54% center;
}
.hero-copy {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: clamp(52px, 9vw, 110px) clamp(20px, 5vw, 72px) clamp(42px, 7vw, 76px);
}
.hero h1 {
  max-width: 810px;
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(3.25rem, 9vw, 7.6rem);
  line-height: .83;
  letter-spacing: -.035em;
  text-transform: uppercase;
  text-wrap: balance;
}
.hero h1 span { color: #ffb044; }
.hero p {
  max-width: 620px;
  margin: 24px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.45;
  color: #f4f1e9;
  text-wrap: balance;
}
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 26px; font-family: var(--display); font-weight: 600; letter-spacing: .04em; }
.hero-meta span:first-child { color: #ffb044; }
main section { scroll-margin-top: 54px; }
.wrap { width: min(1140px, calc(100% - 40px)); margin-inline: auto; }
.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 420px);
  gap: 32px;
  align-items: end;
  padding: 84px 0 28px;
  border-bottom: 2px solid var(--ink);
}
.section-head h2 { margin: 0; font-family: var(--display); font-size: clamp(2.7rem, 6vw, 5.6rem); line-height: .9; letter-spacing: -.025em; text-transform: uppercase; }
.section-head p { margin: 0; color: var(--muted); }
.chapter-tabs { display: flex; flex-wrap: wrap; gap: 8px; padding: 24px 0 30px; }
.chapter-tabs a, .chapter-tabs button {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 16px;
  color: var(--ink);
  background: var(--surface);
  cursor: pointer;
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: .03em;
  text-decoration: none;
}
.chapter-tabs a[aria-selected="true"], .chapter-tabs button[aria-selected="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.episode-panel { padding-bottom: 88px; }
.episode-label {
  margin: 0 0 18px;
  font-family: var(--display);
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: .01em;
}
.webtoon-scroll {
  width: min(820px, 100%);
  margin-inline: auto;
  display: grid;
  gap: clamp(34px, 6vw, 64px);
}
.panel-story {
  margin: 0;
  overflow: hidden;
  background: #050505;
  border: 1px solid var(--line);
  box-shadow: 0 18px 44px var(--shadow);
}
.panel-story img {
  width: 100%;
  height: auto;
  object-fit: contain;
  background: #050505;
}
.panel-story figcaption {
  position: relative;
  padding: clamp(20px, 3.5vw, 30px) clamp(20px, 4vw, 34px);
  color: #f4f1e9;
  background: #111113;
  font-size: clamp(1.08rem, 2.1vw, 1.32rem);
  line-height: 1.5;
}
.panel-story figcaption::before {
  content: "";
  display: block;
  width: 42px;
  margin-bottom: 14px;
  border-top: 3px solid #ffb044;
}
.status {
  display: inline-block;
  margin: 0 0 16px;
  border-bottom: 2px solid var(--amber);
  color: var(--amber-strong);
  font-family: var(--display);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.upcoming { padding: 10px 0 88px; border-top: 2px solid var(--ink); }
.upcoming h3 { margin: 24px 0 18px; font-family: var(--display); font-size: clamp(1.7rem, 3vw, 2.5rem); line-height: 1; text-transform: uppercase; }
.upcoming-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.upcoming-card { min-height: 164px; padding: 20px; background: var(--surface); display: flex; flex-direction: column; justify-content: space-between; text-decoration: none; }
.upcoming-card .status { margin: 0 0 30px; align-self: flex-start; }
.upcoming-card h4 { margin: 0; font-family: var(--display); font-size: clamp(1.35rem, 2.3vw, 1.85rem); line-height: 1; text-transform: uppercase; }
.upcoming-card h4 span { display: block; margin-bottom: 5px; color: var(--muted); font-size: .78rem; letter-spacing: .08em; }
.world { padding-bottom: 88px; background: var(--ink); color: var(--paper); }
.world .section-head { border-color: var(--paper); }
.world .section-head p { color: color-mix(in srgb, var(--paper) 72%, transparent); }
.premise { padding: 34px 0 54px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: start; }
.premise .bigline { margin: 0; max-width: 18ch; font-family: var(--display); font-size: clamp(2rem, 4vw, 3.75rem); line-height: 1; font-weight: 700; }
.premise p:last-child { margin: 0; color: color-mix(in srgb, var(--paper) 78%, transparent); }
.characters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: color-mix(in srgb, var(--paper) 30%, transparent); border: 1px solid color-mix(in srgb, var(--paper) 30%, transparent); }
.character { background: var(--ink); }
.character img { aspect-ratio: 3/2; object-fit: cover; object-position: center; background: #fff; }
.character-copy { padding: 22px; }
.character h3 { margin: 0 0 7px; font-family: var(--display); font-size: 1.8rem; line-height: 1; text-transform: uppercase; }
.character p { margin: 0; color: color-mix(in srgb, var(--paper) 75%, transparent); font-size: .95rem; }
.character--text {
  min-height: 276px;
  display: flex;
  flex-direction: column;
  isolation: isolate;
  background: #f7f7f5;
  color: #141414;
}
.character--text .character-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
  background: #f7f7f5;
  color: #141414;
}
.character-role {
  display: block;
  margin-bottom: auto;
  padding-bottom: 34px;
  color: #ffb044;
  font-family: var(--display);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.character--text .character-role {
  margin-bottom: 24px;
  padding-bottom: 0;
  color: #7b3d00 !important;
  font-size: .86rem;
  opacity: 1;
  visibility: visible;
}
.character--text h3 {
  color: #141414 !important;
  font-size: 2rem;
  opacity: 1;
  visibility: visible;
}
.character--text p {
  color: #3f3f3c !important;
  font-size: 1rem;
  line-height: 1.5;
  opacity: 1;
  visibility: visible;
}
.character-detail {
  margin-top: 14px !important;
  padding-top: 12px;
  border-top: 1px solid #c7c7c2;
  color: #4f4f4b !important;
  font-size: .9rem !important;
}
.character--mystery { min-height: 360px; position: relative; display: grid; align-content: end; overflow: hidden; isolation: isolate; background: #050505; }
.mystery-portrait { position: absolute; inset: 0; z-index: -1; overflow: hidden; background: linear-gradient(180deg, #232323 0%, #101010 62%, #050505 100%); }
.mystery-portrait::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -18%;
  width: 48%;
  height: 88%;
  transform: translateX(-50%);
  border-radius: 48% 48% 14% 14%;
  background: #030303;
  box-shadow: 0 0 56px rgba(0,0,0,.82);
}
.mystery-portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(174deg, transparent 0 12px, rgba(255,255,255,.025) 13px 14px);
}
.character--mystery .character-copy { background: linear-gradient(180deg, transparent, rgba(0,0,0,.96) 34%); padding-top: 76px; }
.character--mystery .character-role { margin-bottom: 12px; padding-bottom: 0; color: #9b9b96; }
.character--mystery p { color: #d3d1cb; font-style: italic; }
.rules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin: 54px 0 0; padding: 0; list-style: none; counter-reset: rules; }
.rules li { counter-increment: rules; }
.rules li::before { content: "0" counter(rules); display: block; color: #ffb044; font-family: var(--display); font-size: 1.05rem; font-weight: 800; border-bottom: 1px solid color-mix(in srgb, var(--paper) 30%, transparent); padding-bottom: 7px; margin-bottom: 12px; }
.rules strong { display: block; font-family: var(--display); font-size: 1.4rem; line-height: 1.1; text-transform: uppercase; }
.rules span { display: block; margin-top: 7px; color: color-mix(in srgb, var(--paper) 72%, transparent); font-size: .94rem; }
.saga { padding-bottom: 88px; }
.saga-line { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding: 40px 0 18px; }
.saga-line::before { content: ""; position: absolute; left: 4%; right: 4%; top: 69px; border-top: 2px solid var(--line); }
.arc { position: relative; padding-top: 62px; }
.arc::before { content: ""; position: absolute; top: 21px; left: 0; width: 18px; height: 18px; border-radius: 50%; background: var(--surface); border: 4px solid var(--ink); }
.arc.current::before { background: var(--amber); border-color: var(--amber); box-shadow: 0 0 0 7px color-mix(in srgb, var(--amber) 18%, transparent); }
.arc .count { font-family: var(--display); color: var(--amber-strong); font-weight: 800; }
.arc h3 { margin: 5px 0 9px; font-family: var(--display); font-size: clamp(1.45rem, 2.7vw, 2.2rem); line-height: .96; text-transform: uppercase; }
.arc p { margin: 0; color: var(--muted); font-size: .95rem; }
.total { display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: 18px; margin-top: 38px; padding-top: 22px; border-top: 1px solid var(--line); }
.total strong { font-family: var(--display); font-size: clamp(4rem, 10vw, 8rem); line-height: .8; color: var(--amber-strong); }
.total span { max-width: 34ch; color: var(--muted); }
.closing { padding: 78px 20px 90px; text-align: center; background: var(--soft); border-top: 1px solid var(--line); }
.closing blockquote { max-width: 800px; margin: 0 auto; font-family: var(--display); font-size: clamp(2.4rem, 6vw, 5.5rem); font-weight: 700; line-height: .94; text-transform: uppercase; }
.closing em { color: var(--amber-strong); font-style: normal; }
.closing p { margin: 24px 0 0; color: var(--muted); }
.prose { padding: 34px 0 88px; max-width: 68ch; }
.prose p { margin: 0 0 1em; }
.prose h3 { font-family: var(--display); font-size: 1.6rem; text-transform: uppercase; margin: 1.6em 0 .4em; }
.pager { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 0 88px; }
.pager a {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 16px;
  color: var(--ink);
  background: var(--surface);
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: .03em;
  text-decoration: none;
}
.pager a:hover { background: var(--ink); color: var(--paper); }
@media (max-width: 780px) {
  body { font-size: 16px; }
  .mastnav { justify-content: flex-start; overflow: hidden; }
  .hero { min-height: 76vh; }
  .hero img { object-position: 60% center; }
  .hero-copy { padding-inline: 20px; }
  .hero h1 { max-width: 7.5ch; }
  .section-head { grid-template-columns: 1fr; gap: 16px; padding-top: 62px; }
  .premise { grid-template-columns: 1fr; }
  .upcoming-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .characters { grid-template-columns: 1fr; }
  .character { display: grid; grid-template-columns: 42% 1fr; }
  .character.character--text { grid-template-columns: 1fr; }
  .character img { height: 100%; aspect-ratio: auto; }
  .rules { grid-template-columns: 1fr; gap: 22px; }
  .saga-line { grid-template-columns: 1fr; gap: 2px; padding-left: 6px; }
  .saga-line::before { left: 14px; right: auto; top: 42px; bottom: 40px; border-top: 0; border-left: 2px solid var(--line); }
  .arc { padding: 12px 0 26px 52px; }
  .arc::before { top: 18px; left: 0; }
  .total { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .wrap { width: min(100% - 28px, 1140px); }
  .hero { min-height: 690px; }
  .hero::after { background: linear-gradient(180deg, rgba(0,0,0,.08), rgba(0,0,0,.27) 45%, rgba(0,0,0,.95) 83%); }
  .hero h1 { font-size: clamp(3.4rem, 19vw, 5.5rem); }
  .chapter-tabs { display: grid; grid-template-columns: repeat(3, 1fr); }
  .chapter-tabs a, .chapter-tabs button { padding-inline: 8px; }
  .upcoming-grid { grid-template-columns: 1fr; }
  .upcoming-card { min-height: 138px; }
  .character { grid-template-columns: 1fr; }
  .character img { aspect-ratio: 3/2; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
