/* Kalypse - Ink & Seal */
@property --bleed {
  syntax: '<percentage>';
  inherits: false;
  initial-value: 170%;
}

:root {
  --paper: #D9D1C0;
  --paper-hi: #E0D9CA;
  --silk: #D8CFBC;
  --ink: #141210;
  --ink-soft: #2B2723;
  --wash: #8C877C;
  --wash-text: #5B564C;
  --cinnabar: #B8231B;
  --blood: #6E1410;
  --wood: #2A1D16;

  --serif: 'Shippori Mincho B1', 'Noto Serif CJK JP', 'Songti SC', Georgia, serif;
  --brush: 'Ma Shan Zheng', 'Noto Serif CJK SC', serif;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1320px;

  --brushline: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 8' preserveAspectRatio='none'%3E%3Cpath d='M0 4.2C40 3 90 2.6 160 3.2S300 4.4 380 3.6 520 2.8 600 3.9L600 4.6C520 5.6 450 5.2 380 5S240 5.4 160 5 40 5.6 0 4.8Z' fill='%23141210'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    radial-gradient(120% 60% at 10% 0%, rgba(237,232,220,.55), transparent 60%),
    radial-gradient(90% 50% at 100% 40%, rgba(140,135,124,.10), transparent 70%),
    radial-gradient(80% 40% at 0% 85%, rgba(140,135,124,.12), transparent 70%),
    radial-gradient(60% 30% at 70% 70%, rgba(140,135,124,.08), transparent 70%);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.8;
  font-weight: 400;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  position: relative;
}

/* paper grain and fibres laid over everything, art included, so it all reads as one sheet */
body::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 90;
  mix-blend-mode: multiply;
  opacity: .75;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='360'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .32 0 0 0 0 .29 0 0 0 0 .24 0 0 0 -1.1 .62'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

img { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 700; line-height: 1.15; text-wrap: balance; }
ul, ol { margin: 0; padding: 0; list-style: none; }

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

.wrap {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.skip {
  position: absolute; left: 12px; top: 12px; z-index: 100; transform: translateY(-200%);
  background: var(--ink); color: var(--paper); padding: .6rem 1rem; text-decoration: none;
}
.skip:focus { transform: none; }

/* ---------- seal stamps: the only structural marker ---------- */
.seal {
  --s: 3.25rem;
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: none;
  width: var(--s);
  height: var(--s);
  background: var(--cinnabar);
  color: var(--paper-hi);
  font-family: var(--brush);
  font-size: calc(var(--s) * .72);
  line-height: 1;
  border-radius: 3px 4px 2px 5px;
  box-shadow: inset 0 0 0 calc(var(--s) * .06) var(--cinnabar), inset 0 0 0 calc(var(--s) * .09) var(--paper-hi);
  transform: rotate(var(--r, -2.5deg));
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -8 0 0 0 6.1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -8 0 0 0 6.1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  -webkit-mask-size: 160px 160px;
  mask-size: 160px 160px;
}
.seal--num {
  font-family: var(--serif);
  font-weight: 800;
  font-size: calc(var(--s) * .46);
  letter-spacing: -.03em;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  min-height: 3.25rem;
  padding: .85rem 1.6rem .9rem;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.0625rem;
  line-height: 1.2;
  letter-spacing: .01em;
  text-decoration: none;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color .2s, color .2s, box-shadow .2s;
}
.btn--seal {
  background: var(--cinnabar);
  color: #E9E2D4;
  box-shadow: inset 0 0 0 3px var(--cinnabar), inset 0 0 0 4px rgba(233,226,212,.7);
}
.btn--seal:hover { background: var(--blood); box-shadow: inset 0 0 0 3px var(--blood), inset 0 0 0 4px rgba(233,226,212,.7); }
.btn--ink {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--ink);
}
.btn--ink:hover { background: var(--ink); color: var(--paper); }
.btn--solid { background: var(--ink); color: var(--paper); }
.btn--solid:hover { background: var(--ink-soft); }

.textlink {
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--cinnabar);
  text-decoration-thickness: 1.5px;
  text-underline-offset: .32em;
}
.textlink:hover { color: var(--cinnabar); }

/* ---------- header ---------- */
.site-head {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 30;
}
.site-head .wrap {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  height: 88px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  text-decoration: none;
  flex: none;
}
.brand svg { width: 46px; height: 46px; }
.brand span {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: .01em;
}
.nav { display: flex; align-items: center; gap: 2rem; margin-left: auto; }
.nav ul { display: flex; gap: 1.75rem; }
.nav a {
  font-size: .98rem;
  font-weight: 500;
  text-decoration: none;
  padding-block: .4rem;
  background-image: linear-gradient(var(--cinnabar), var(--cinnabar));
  background-position: left 100%;
  background-size: 0 1.5px;
  background-repeat: no-repeat;
  transition: background-size .25s;
}
.nav ul a:hover, .nav ul a:focus-visible { background-size: 100% 1.5px; }
.nav .acct { display: flex; align-items: center; gap: 1.25rem; }
.nav .acct .btn { min-height: 2.75rem; padding: .6rem 1.15rem; font-size: .98rem; background-image: none; }
.nav .acct .btn:hover { background-color: var(--blood); }
.menu-btn { display: none; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: max(760px, 100svh);
  overflow: clip;
}
.hero-glyph {
  position: absolute;
  z-index: 0;
  left: -4vw;
  top: 2%;
  font-family: var(--brush);
  font-size: min(92vh, 62vw);
  line-height: 1;
  color: var(--wash);
  opacity: .24;
  mix-blend-mode: multiply;
  pointer-events: none;
  user-select: none;
  animation: ink-in 2s cubic-bezier(.2,.65,.25,1) .1s both;
}
.hero-art {
  position: absolute;
  z-index: 1;
  right: -9vw;
  top: 56px;
  width: min(70vw, 1200px);
  aspect-ratio: 4 / 3;
  mix-blend-mode: multiply;
  -webkit-mask-image:
    radial-gradient(circle at 62% 46%, #000 calc(var(--bleed) - 34%), transparent var(--bleed)),
    linear-gradient(to right, transparent 0%, #000 13%),
    linear-gradient(to top, transparent 0%, #000 22%);
  -webkit-mask-composite: source-in, source-in;
  mask-image:
    radial-gradient(circle at 62% 46%, #000 calc(var(--bleed) - 34%), transparent var(--bleed)),
    linear-gradient(to right, transparent 0%, #000 13%),
    linear-gradient(to top, transparent 0%, #000 22%);
  mask-composite: intersect;
  animation: bleed 2.6s cubic-bezier(.25,.6,.2,1) .35s both;
}
.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: sepia(.22) contrast(1.06) saturate(.92) brightness(1.02);
}
.inscription {
  position: absolute;
  z-index: 2;
  left: 44.5%;
  top: 112px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.1rem;
  pointer-events: none;
}
.inscription p {
  writing-mode: vertical-rl;
  font-family: var(--brush);
  font-size: 2.8rem;
  line-height: 1.2;
  letter-spacing: .04em;
  color: var(--ink);
}
.inscription--m { display: none; }
.inscription .seal { --s: 2.6rem; --r: 3deg; animation: stamp .5s cubic-bezier(.3,1.6,.5,1) 2.2s both; }

.hero-copy {
  position: relative;
  z-index: 3;
  padding-top: clamp(190px, 25vh, 250px);
  padding-bottom: 96px;
  max-width: 35rem;
}
.live {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink-soft);
  margin-bottom: 1.6rem;
}
.live i {
  width: .6rem; height: .6rem; background: var(--cinnabar);
  transform: rotate(45deg); flex: none;
}
.hero h1 {
  font-size: clamp(4.25rem, 9.6vw, 9rem);
  font-weight: 800;
  line-height: .86;
  letter-spacing: -.025em;
  margin-left: -.05em;
}
.tagline {
  margin-top: 1.7rem;
  font-size: clamp(1.5rem, 2.4vw, 2.1rem);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: .01em;
}
.hero .lede {
  margin-top: 1.75rem;
  max-width: 29rem;
  font-size: 1.1875rem;
  line-height: 1.75;
  color: var(--ink-soft);
}
.actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 2.25rem; }
.rates {
  margin: 2.6rem 0 0;
  max-width: 22rem;
}
.rates div {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-block: .35rem .45rem;
  background: var(--brushline) left bottom / 100% 4px no-repeat;
}
.rates dt { font-size: 1rem; color: var(--wash-text); }
.rates dd { margin: 0; font-size: 1.2rem; font-weight: 700; font-variant-numeric: lining-nums; }

@keyframes ink-in {
  0% { opacity: 0; filter: blur(28px); transform: scale(1.1); }
  60% { opacity: .22; filter: blur(2px); }
  100% { opacity: .24; filter: none; transform: none; }
}
@keyframes bleed {
  from { --bleed: 0%; }
  to { --bleed: 170%; }
}
@keyframes stamp {
  0% { opacity: 0; transform: scale(1.6) rotate(-8deg); }
  100% { opacity: 1; transform: scale(1) rotate(3deg); }
}

/* ---------- sections ---------- */
section { position: relative; }
.sec { padding-block: clamp(80px, 9.5vw, 136px); }
.sec-head {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
}
.sec-head .seal { margin-top: .35rem; }
.sec-head h2 {
  font-size: clamp(2.1rem, 4.2vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -.012em;
  line-height: 1.12;
  max-width: 18ch;
}
.intro {
  max-width: 36rem;
  margin-top: 1.4rem;
  margin-left: calc(3.25rem + 1.25rem);
  font-size: 1.1875rem;
  color: var(--ink-soft);
}

/* ---------- lore ---------- */
.lore { padding-top: clamp(56px, 7vw, 110px); }
.lore-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 2rem;
  align-items: start;
}
.lore-lines {
  grid-column: 1 / span 6;
  display: flex;
  gap: 1.25rem;
}
.lore-lines .seal { margin-top: .5rem; }
.lore-lines h2 {
  font-size: clamp(2rem, 3.9vw, 3.35rem);
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: -.01em;
}
.lore-lines h2 span { display: block; }
.lore-lines h2 span + span { margin-top: .15em; }
.lore-body {
  grid-column: 8 / span 5;
  padding-top: .7rem;
  display: grid;
  gap: 1.35rem;
  max-width: 33rem;
}
.lore-body .first {
  font-size: 1.4rem;
  line-height: 1.6;
  font-weight: 500;
}
.lore-body p:not(.first) { color: var(--ink-soft); }

/* ---------- zones handscroll ---------- */
.zones .sec-head h2 { max-width: 20ch; }
.handscroll {
  position: relative;
  margin-top: clamp(48px, 6vw, 80px);
}
.handscroll-track {
  position: relative;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  scrollbar-color: var(--wash) transparent;
  padding: 12px 10px 14px;
  margin-inline: -10px;
}
.scroll-sheet {
  position: relative;
  min-width: 1180px;
  background:
    linear-gradient(var(--blood), var(--blood)) left 0 / 100% 7px no-repeat,
    linear-gradient(rgba(224,217,202,.9), rgba(224,217,202,.9)) left 7px / 100% 1.5px no-repeat,
    linear-gradient(var(--blood), var(--blood)) left 100% / 100% 7px no-repeat,
    linear-gradient(rgba(224,217,202,.9), rgba(224,217,202,.9)) left calc(100% - 7px) / 100% 1.5px no-repeat,
    linear-gradient(180deg, rgba(237,232,220,.55), rgba(224,217,202,.35));
  padding: 48px 40px 40px;
}
.scroll-sheet::before, .scroll-sheet::after {
  content: "";
  position: absolute;
  top: -10px; bottom: -10px;
  width: 16px;
  border-radius: 8px;
  background: linear-gradient(90deg, #1b120d, var(--wood) 35%, #4a3326 55%, #1b120d);
}
.scroll-sheet::before { left: -8px; }
.scroll-sheet::after { right: -8px; }

.road-line {
  position: absolute;
  left: 40px; right: 40px;
  top: 250px;
  height: 22px;
  pointer-events: none;
}
.zone-list {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr 1.1fr 1.1fr 1.5fr;
  gap: 0;
}
.zone {
  position: relative;
  padding: 0 18px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
}
.zone + .zone::before {
  content: "";
  position: absolute;
  left: 0; top: 18px; height: 170px; width: 1px;
  background: linear-gradient(to bottom, rgba(20,18,16,.0), rgba(20,18,16,.18) 30%, rgba(20,18,16,0));
}
.zone .n {
  font-size: .95rem;
  font-weight: 700;
  color: var(--wash-text);
}
.zone .g {
  font-family: var(--brush);
  font-size: 6.2rem;
  line-height: 1.15;
  height: 150px;
  color: var(--ink);
  margin-top: .25rem;
}
.zone--deep .g { color: var(--blood); }
.zone .marker {
  height: 64px;
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-top: 8px;
}
.zone .dot {
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--ink);
  box-shadow: 0 0 0 5px var(--paper-hi);
  margin-left: 6px;
}
.zone .marker .seal { --s: 3.1rem; }
.zone .marker .seal:nth-child(2) { --r: 3deg; }
.zone h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-top: 1.1rem;
  line-height: 1.25;
}
.zone .meta {
  margin-top: .4rem;
  font-size: .98rem;
  line-height: 1.55;
  color: var(--wash-text);
  max-width: 17rem;
}
.chapters {
  position: relative;
  margin-top: 36px;
  padding-top: 18px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  font-size: 1rem;
  color: var(--ink-soft);
}
.chapters::before {
  content: "";
  position: absolute; left: 0; right: 0; top: 0; height: 12px;
  border: 1.5px solid var(--ink);
  border-bottom: 0;
  opacity: .55;
}
.chapters b { font-weight: 700; color: var(--ink); }
.scroll-hint { display: none; }

/* ---------- classes: hanging scrolls ---------- */
.classes-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 48px);
  align-items: start;
  margin-top: clamp(40px, 5vw, 72px);
}
.hanging { position: relative; }
.hanging .cord { display: block; width: 62%; height: var(--h, 60px); margin-inline: auto; overflow: visible; }
.rod {
  position: relative;
  height: 14px;
  margin-inline: -12px;
  border-radius: 7px;
  background: linear-gradient(180deg, #4a3326, var(--wood) 45%, #120c09);
}
.rod::before, .rod::after {
  content: "";
  position: absolute; top: -3px;
  width: 12px; height: 20px; border-radius: 4px;
  background: linear-gradient(180deg, #2a1c15, #0d0907);
}
.rod::before { left: -8px; }
.rod::after { right: -8px; }
.rod--bottom { height: 20px; border-radius: 10px; margin-inline: -16px; }
.rod--bottom::before, .rod--bottom::after { top: -3px; height: 26px; width: 16px; border-radius: 6px; }
.rod--bottom::before { left: -10px; }
.rod--bottom::after { right: -10px; }
.mount {
  background: var(--silk);
  padding: 26px 16px 34px;
  background-image:
    linear-gradient(180deg, rgba(110,20,16,.18), rgba(110,20,16,.18)),
    linear-gradient(180deg, rgba(110,20,16,.18), rgba(110,20,16,.18));
  background-size: 100% 16px, 100% 22px;
  background-position: top, bottom;
  background-repeat: no-repeat;
}
.painting {
  background: linear-gradient(180deg, #E3DCCE, #DCD5C4 70%, #D6CDBA);
  box-shadow: inset 0 0 0 1px rgba(20,18,16,.12), inset 0 0 40px rgba(140,135,124,.18);
  padding: 30px 22px 30px;
  min-height: 430px;
  display: flex;
  flex-direction: column;
}
.painting .g {
  font-family: var(--brush);
  font-size: clamp(6rem, 11vw, 10rem);
  line-height: 1;
  text-align: center;
  color: var(--ink);
  margin-block: 6px 26px;
}
.painting h3 {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -.005em;
  margin-top: auto;
}
.painting p {
  margin-top: .45rem;
  font-size: 1.05rem;
  line-height: 1.5;
  color: var(--wash-text);
  font-weight: 500;
}

/* ---------- features ---------- */
.feat-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: clamp(24px, 3vw, 48px);
  row-gap: clamp(64px, 7vw, 104px);
  margin-top: clamp(56px, 6vw, 88px);
}
.feat h3 {
  font-size: clamp(1.6rem, 2.3vw, 2.05rem);
  font-weight: 700;
  letter-spacing: -.01em;
}
.feat p { margin-top: .8rem; max-width: 32rem; color: var(--ink-soft); }
.feat--honor { grid-column: 1 / span 7; }
.feat--bg { grid-column: 9 / span 4; }
.feat--lawless { grid-column: 1 / span 5; }
.feat--idols { grid-column: 7 / span 6; align-self: center; }

.ladder {
  display: flex;
  align-items: flex-end;
  gap: clamp(8px, 1.4vw, 18px);
  height: 120px;
  margin-top: 2.25rem;
}
.ladder i {
  flex: 1 1 0;
  max-width: 16px;
  background: var(--ink);
  border-radius: 1px 1px 0 0;
  height: calc(14px + var(--k) * 7.4px);
  opacity: calc(.35 + var(--k) * .045);
}
.ladder i:last-child { background: var(--cinnabar); opacity: 1; }
.ladder-ends {
  display: flex;
  justify-content: space-between;
  max-width: calc(15 * 16px + 14 * clamp(8px, 1.4vw, 18px));
  margin-top: .7rem;
  font-size: .98rem;
  color: var(--wash-text);
}
.ladder-ends b { color: var(--ink); font-weight: 700; }

.bg-list { margin-top: 1.6rem; }
.bg-list li {
  padding-block: .8rem .9rem;
  font-size: 1.3rem;
  font-weight: 600;
  line-height: 1.3;
  background: var(--brushline) left bottom / 100% 5px no-repeat;
}
.bg-list li:first-child { padding-top: 0; }
.feat--bg .after { margin-top: 1.25rem; font-size: 1.02rem; }
.feat--bg .textlink { display: inline-block; margin-top: 1rem; }

.lawless-panel {
  position: relative;
  isolation: isolate;
  color: #DED6C6;
  padding: clamp(36px, 4vw, 56px) clamp(28px, 3.4vw, 48px) clamp(40px, 4vw, 60px);
  min-height: 420px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.lawless-panel::before {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(120% 90% at 30% 20%, #2a2521, var(--ink) 70%);
  filter: url(#rough);
}
.lawless-panel .g {
  position: absolute;
  top: clamp(24px, 3vw, 40px);
  right: clamp(20px, 3vw, 40px);
  writing-mode: vertical-rl;
  font-family: var(--brush);
  font-size: clamp(4.5rem, 7vw, 6.5rem);
  line-height: 1;
  color: var(--cinnabar);
}
.lawless-panel h3 { color: #E9E2D4; }
.lawless-panel p { color: #D9D2C3; max-width: 22rem; }

.idols-field {
  display: grid;
  grid-template-columns: repeat(30, 1fr);
  gap: 7px;
  max-width: 400px;
  margin-top: 2rem;
}
.idols-field i {
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--ink);
  opacity: .78;
}
.idols-field i:nth-child(7n+3) { opacity: .55; }
.idols-field i:nth-child(11n+5) { opacity: .9; }
.idols-field i.secret { background: var(--cinnabar); opacity: 1; transform: scale(1.35); }
.idols-cap { margin-top: 1rem !important; font-size: 1rem; color: var(--wash-text) !important; }

/* ---------- kalypedia: a book index ---------- */
.wiki-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 2rem;
  align-items: start;
}
.wiki-head { grid-column: 1 / span 5; }
.wiki-head .more { display: inline-block; margin-top: 1.6rem; margin-left: calc(3.25rem + 1.25rem); }
.wiki-index { grid-column: 7 / span 6; }
.wiki-index li { background-image: var(--brushline); background-size: 100% 3px; background-repeat: no-repeat; background-position: left bottom; }
.wiki-index a {
  display: grid;
  grid-template-columns: 1fr auto;
  column-gap: 1.5rem;
  align-items: center;
  padding: 1.35rem 0 1.25rem;
  text-decoration: none;
}
.wiki-index .t {
  display: flex;
  align-items: baseline;
  gap: .7rem;
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1.2;
}
.wiki-index .t::after {
  content: "";
  flex: 1;
  min-width: 2rem;
  border-bottom: 2px dotted var(--wash);
}
.wiki-index .d {
  grid-column: 1;
  margin-top: .35rem;
  font-size: 1.02rem;
  line-height: 1.6;
  color: var(--wash-text);
  max-width: 34rem;
}
.wiki-index .g {
  grid-column: 2;
  grid-row: 1 / span 2;
  font-family: var(--brush);
  font-size: 3.4rem;
  line-height: 1;
  color: var(--ink);
  transition: color .2s;
}
.wiki-index a:hover .g, .wiki-index a:focus-visible .g { color: var(--cinnabar); }

.feat-quiet {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(24px, 3vw, 48px);
  padding-top: clamp(40px, 4vw, 56px);
  background: var(--brushline) left top / 100% 7px no-repeat;
}
.feat-quiet .feat h3 { font-size: 1.45rem; }
.feat-quiet .feat p { font-size: 1.05rem; }

/* ---------- ranking + news ---------- */
.board {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(32px, 4vw, 64px);
  align-items: start;
}
.rank { grid-column: 1 / span 7; }
.news { grid-column: 9 / span 4; }
.board .sec-head h2 { font-size: clamp(2rem, 3.4vw, 2.9rem); }
.board .sub { margin-top: .9rem; color: var(--ink-soft); }

.rank table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
  font-variant-numeric: lining-nums tabular-nums;
}
.rank th {
  text-align: left;
  font-size: .95rem;
  font-weight: 600;
  color: var(--wash-text);
  padding: 0 .75rem .6rem 0;
}
.rank td {
  padding: 1rem .75rem 1rem 0;
  font-size: 1.15rem;
  background: var(--brushline) left bottom / 100% 4px no-repeat;
  vertical-align: middle;
}
.rank td.pos { width: 4.25rem; font-weight: 800; font-size: 1.45rem; }
.rank td.pos .seal { --s: 2.4rem; font-size: 1.15rem; }
.rank td.name { font-weight: 700; }
.rank td.cls { color: var(--ink-soft); white-space: nowrap; }
.rank td.cls span {
  font-family: var(--brush);
  font-size: 1.7rem;
  line-height: 1;
  vertical-align: -.2em;
  margin-right: .45rem;
  color: var(--ink);
}
.rank th.lvl, .rank td.lvl { text-align: right; padding-right: 0; }
.rank td.lvl { font-weight: 700; font-size: 1.3rem; }
.rank .more { display: inline-block; margin-top: 1.5rem; }

.news-list { margin-top: 2rem; display: grid; gap: 2.4rem; }
.news article { position: relative; }
.news time { font-size: .98rem; color: var(--wash-text); font-weight: 500; }
.news h3 { font-size: 1.6rem; margin-top: .2rem; }
.news h3 a { text-decoration: none; }
.news h3 a:hover { color: var(--cinnabar); }
.news ul { margin-top: .9rem; display: grid; gap: .35rem; }
.news li {
  position: relative;
  padding-left: 1.25rem;
  font-size: 1.04rem;
  line-height: 1.55;
  color: var(--ink-soft);
}
.news li::before {
  content: "";
  position: absolute; left: 0; top: .62em;
  width: .42rem; height: .42rem; background: var(--cinnabar);
  transform: rotate(45deg);
}
.news article + article { padding-top: 2.4rem; background: var(--brushline) left top / 100% 5px no-repeat; }
.news p { margin-top: .6rem; color: var(--ink-soft); font-size: 1.04rem; }

/* ---------- final call ---------- */
.final {
  position: relative;
  overflow: clip;
  padding-block: clamp(110px, 13vw, 190px);
}
.final-art {
  position: absolute;
  z-index: 0;
  right: -6vw;
  top: 0;
  bottom: 0;
  width: min(58vw, 980px);
  mix-blend-mode: multiply;
  -webkit-mask-image: radial-gradient(ellipse 60% 58% at 50% 48%, #000 50%, transparent 100%), linear-gradient(to right, transparent 0, #000 26%);
  -webkit-mask-composite: source-in;
  mask-image: radial-gradient(ellipse 60% 58% at 50% 48%, #000 50%, transparent 100%), linear-gradient(to right, transparent 0, #000 26%);
  mask-composite: intersect;
}
.final-art img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 18% 12%;
  filter: brightness(1.1) contrast(1.1) sepia(.15) saturate(.9);
}
.final-copy { max-width: 36rem; position: relative; z-index: 1; }
.final .big-seal {
  --s: clamp(5.5rem, 9vw, 8rem);
  --r: -5deg;
  margin-bottom: 2.25rem;
}
.final h2 {
  font-size: clamp(2.5rem, 5.4vw, 4.6rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -.02em;
}
.final .lede { margin-top: 1.5rem; font-size: 1.2rem; color: var(--ink-soft); max-width: 30rem; }
.final .actions { margin-top: 2.4rem; }
.vote {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  max-width: 30rem;
  font-size: 1.02rem;
  color: var(--ink-soft);
  background: var(--brushline) left top / 100% 5px no-repeat;
}
.vote b { color: var(--ink); }

/* ---------- footer ---------- */
.site-foot {
  padding-block: 64px 40px;
  background: var(--brushline) left top / 100% 8px no-repeat;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 2rem;
}
.foot-brand p { margin-top: 1rem; max-width: 22rem; font-size: 1rem; color: var(--wash-text); }
.site-foot h2 { font-size: 1.05rem; font-weight: 700; margin-bottom: .8rem; }
.site-foot li a { display: inline-block; padding-block: .25rem; font-size: 1rem; text-decoration: none; color: var(--ink-soft); }
.site-foot li a:hover { color: var(--cinnabar); }
.foot-base {
  margin-top: 56px;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: .92rem;
  color: var(--wash-text);
}

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .nav ul { gap: 1.25rem; }
  .nav .acct .login { display: none; }
}
@media (max-width: 1040px) {
  .menu-btn {
    display: inline-flex; align-items: center; gap: .6rem;
    margin-left: auto;
    background: none; border: 0; padding: .6rem .2rem;
    font: 600 1rem var(--serif); color: var(--ink); cursor: pointer;
  }
  .menu-btn i { display: block; width: 22px; height: 2px; background: var(--ink); box-shadow: 0 -6px 0 var(--ink), 0 6px 0 var(--ink); }
  .nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 88px;
    flex-direction: column; align-items: stretch; gap: 1.25rem;
    background: var(--paper-hi);
    padding: 1.25rem var(--gutter) 1.75rem;
    box-shadow: 0 18px 30px -18px rgba(20,18,16,.35);
  }
  .nav.open { display: flex; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul a { display: block; padding-block: .7rem; font-size: 1.1rem; background-image: var(--brushline); background-size: 100% 3px; background-position: left bottom; }
  .nav .acct { justify-content: space-between; }
  .nav .acct .login { display: inline; }
  .feat--honor { grid-column: 1 / -1; }
  .feat--bg { grid-column: 1 / -1; }
  .feat--lawless { grid-column: 1 / span 6; }
  .feat--idols { grid-column: 7 / span 6; }
  .rank, .news { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  .hero { min-height: 0; display: flow-root; }
  .hero-art {
    position: relative;
    right: auto; top: auto;
    width: 118vw;
    margin-left: -6vw;
    margin-top: 100px;
    -webkit-mask-image:
      radial-gradient(circle at 62% 46%, #000 calc(var(--bleed) - 34%), transparent var(--bleed)),
      linear-gradient(to bottom, transparent 0, #000 12%, #000 72%, transparent 100%);
    mask-image:
      radial-gradient(circle at 62% 46%, #000 calc(var(--bleed) - 34%), transparent var(--bleed)),
      linear-gradient(to bottom, transparent 0, #000 12%, #000 72%, transparent 100%);
  }
  .hero-glyph { font-size: 120vw; top: 40px; left: -14vw; }
  .inscription { display: none; }
  .inscription--m { display: flex; left: auto; right: 0; top: 2.6rem; gap: .55rem; }
  .inscription--m p { font-size: 1.75rem; }
  .inscription--m .seal { --s: 1.8rem; }
  .hero-copy { padding-top: 0; margin-top: -10vw; padding-bottom: 72px; }
  .lore-grid { display: block; }
  .lore-body { margin-top: 2.25rem; padding-left: calc(3.25rem + 1.25rem); }
  .classes-row { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 8px; }
  .classes-row .hanging:nth-child(odd) { --h: 30px !important; }
  .classes-row .hanging:nth-child(even) { --h: 74px !important; }
  .feat--lawless, .feat--idols { grid-column: 1 / -1; }
  .wiki-grid { display: block; }
  .wiki-index { margin-top: 2.5rem; }
  .feat-quiet { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .scroll-hint {
    display: block; margin-top: 1rem; font-size: .95rem; color: var(--wash-text);
  }
}
@media (max-width: 560px) {
  body { font-size: 1.0625rem; }
  .site-head .wrap { height: 72px; }
  .nav { top: 72px; }
  .brand svg { width: 38px; height: 38px; }
  .brand span { font-size: 1.3rem; }
  .sec-head { gap: .9rem; }
  .sec-head .seal { --s: 2.5rem; margin-top: .2rem; }
  .intro { margin-left: 0; }
  .lore-lines .seal { --s: 2.5rem; }
  .lore-lines { gap: .9rem; }
  .lore-lines h2 { font-size: 1.85rem; }
  .classes-row { padding-inline: 12px; }
  .lore-body { padding-left: 0; }
  .wiki-head .more { margin-left: 0; }
  .wiki-index .t { font-size: 1.35rem; }
  .wiki-index .g { font-size: 2.6rem; }
  .hero-art { margin-top: 84px; }
  .hero h1 { font-size: 4.4rem; }
  .actions .btn { flex: 1 1 100%; }
  .scroll-sheet { min-width: 1240px; }
  .classes-row { gap: 14px; }
  .mount { padding: 14px 8px 18px; background-size: 100% 8px, 100% 12px; }
  .painting { min-height: 300px; padding: 18px 12px 20px; }
  .painting .g { font-size: 5.2rem; margin-block: 4px 16px; }
  .painting h3 { font-size: 1.3rem; }
  .painting p { font-size: .95rem; }
  .rod { margin-inline: -8px; height: 11px; }
  .rod--bottom { height: 15px; margin-inline: -10px; }
  .lawless-panel { min-height: 380px; }
  .idols-field { gap: 4px; }
  .rank td { font-size: 1.02rem; padding-right: .5rem; }
  .rank td.pos { width: 3rem; }
  .rank td.cls span { font-size: 1.4rem; margin-right: .3rem; }
  .final-art {
    position: relative; right: auto; width: 120vw; height: 92vw; margin: -40px 0 -12vw -10vw;
    -webkit-mask-image: radial-gradient(ellipse 60% 50% at 40% 45%, #000 50%, transparent 100%);
    mask-image: radial-gradient(ellipse 60% 50% at 40% 45%, #000 50%, transparent 100%);
  }
  .final { padding-top: 40px; }
  .final .big-seal { margin-top: 12px; }
  .foot-base { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .hero-art { --bleed: 170%; }
}

/* ---------- live status ---------- */
.live--off i { background: var(--wash) !important; }

/* ---------- other rankings ---------- */
.rank-kinds { margin-top: 1rem; font-size: 1rem; color: var(--wash-text); }
.rank-kinds a { margin-left: .55rem; color: var(--ink); text-underline-offset: .2em; }
.rank-kinds a:hover { color: var(--cinnabar); }

/* ---------- vote reminder ---------- */
.vote-pop[hidden] { display: none; }
.vote-pop {
  position: fixed; inset: 0; z-index: 190;
  display: grid; place-items: center; padding: 16px;
  background: rgba(20,18,16,.45);
}
.vote-card {
  position: relative;
  width: min(460px, 100%);
  padding: 2.4rem 2.2rem 2rem;
  background: var(--paper-hi);
  border: 1px solid var(--ink);
  box-shadow: 0 0 0 5px var(--paper-hi), 0 0 0 6px var(--ink), 0 30px 60px -20px rgba(0,0,0,.55);
}
.vote-card .seal { --s: 3rem; position: absolute; top: -1.4rem; left: 1.6rem; --r: -4deg; }
.vote-x {
  position: absolute; top: .55rem; right: .55rem;
  width: 2.75rem; height: 2.75rem;
  display: grid; place-items: center;
  background: none; border: 0; cursor: pointer;
  font: 400 2rem/1 var(--serif); color: var(--ink);
}
.vote-x:hover { color: var(--cinnabar); }
.vote-card h2 { font-size: 2rem; }
.vote-card p { margin-top: .8rem; color: var(--ink-soft); font-size: 1.05rem; }
.vote-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.6rem; }
.vote-actions .btn { flex: 1 1 auto; }
