:root {
  --ink: #0a0908;
  --surface: #121010;
  --surface-2: #1a1716;
  --surface-3: #231f1d;
  --line: rgba(242, 237, 228, 0.09);
  --line-strong: rgba(242, 237, 228, 0.18);
  --text: #f2ede4;
  --muted: #a8a093;
  --faint: #6f685f;
  --crimson: #c90000;
  --crimson-hi: #e01f1f;
  --crimson-deep: #6e0808;
  --gold: #e3b341;
  --gold-soft: rgba(227, 179, 65, 0.14);
  --s-verified: #7fb38a;
  --s-reported: #e3b341;
  --s-claimed: #93a9cc;
  --s-contested: #e3864a;
  --s-unverified: #8d867d;
  --s-corrected: #e05252;
  --serif: "Cinzel", "Trajan Pro", Georgia, serif;
  --sans: "Montserrat", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --wrap: 1200px;
  --r: 4px;
  --text-xs: clamp(0.72rem, 0.7rem + 0.1vw, 0.78rem);
  --text-sm: clamp(0.85rem, 0.82rem + 0.15vw, 0.92rem);
  --text-base: clamp(0.95rem, 0.92rem + 0.2vw, 1.03rem);
  --text-lg: clamp(1.1rem, 1rem + 0.5vw, 1.3rem);
  --text-xl: clamp(1.45rem, 1.2rem + 1.1vw, 2.1rem);
  --text-2xl: clamp(2rem, 1.4rem + 2.6vw, 3.4rem);
  --text-hero: clamp(2.6rem, 1.4rem + 5.4vw, 5.6rem);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--ink);
  color: var(--text);
  font-family: var(--sans);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100dvh;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.num { font-variant-numeric: tabular-nums lining-nums; }
.wrap { width: min(var(--wrap), 100% - 2.5rem); margin-inline: auto; }

/* preview ribbon */
.ribbon {
  background: var(--crimson-deep);
  color: #f6d9d9;
  font-size: var(--text-xs);
  letter-spacing: 0.06em;
  text-align: center;
  padding: 0.45rem 1rem;
}
.ribbon b { color: #fff; font-weight: 700; }

/* header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 9, 8, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; height: 68px; }
.brand { display: flex; align-items: center; gap: 0.75rem; }
.brand-mark { width: 34px; height: 34px; color: var(--gold); flex: none; }
.brand-word { font-family: var(--serif); font-weight: 700; letter-spacing: 0.22em; font-size: 1.02rem; line-height: 1; }
.brand-word small { display: block; font-family: var(--sans); font-weight: 600; letter-spacing: 0.18em; font-size: 0.56rem; color: var(--muted); margin-top: 0.35rem; text-transform: uppercase; }
.nav { display: flex; flex-wrap: nowrap; gap: clamp(0.85rem, 1.5vw, 1.6rem); font-size: var(--text-sm); font-weight: 600; white-space: nowrap; }
.nav a { white-space: nowrap; }
@media (max-width: 1240px) { .nav { font-size: 0.8rem; } }
.nav a { color: rgba(242, 237, 228, 0.78); padding: 0.4rem 0; border-bottom: 2px solid transparent; transition: color .18s, border-color .18s; }
.nav a:hover, .nav a.active { color: var(--text); border-bottom-color: var(--crimson); }
.menu-btn { display: none; width: 40px; height: 40px; border: 1px solid var(--line-strong); border-radius: var(--r); }
.menu-btn span { display: block; width: 18px; height: 2px; background: var(--text); margin: 4px auto; }

.site-header .brand { flex-shrink: 0; }
@media (max-width: 990px) {
  .menu-btn { display: block; }
  .nav { position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--ink); border-bottom: 1px solid var(--line); padding: 0.5rem 1.25rem 1rem; display: none; }
  .nav.open { display: flex; }
  .nav a { padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
}

/* type */
.eyebrow { font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
.eyebrow.red { color: var(--crimson-hi); }
h1, h2, .display { font-family: var(--serif); font-weight: 700; letter-spacing: 0.04em; line-height: 1.08; }
h1 { font-size: var(--text-2xl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); font-weight: 700; line-height: 1.3; }
.lede { font-size: var(--text-lg); color: rgba(242, 237, 228, 0.86); max-width: 62ch; line-height: 1.55; }
.muted { color: var(--muted); }
p + p { margin-top: 0.9em; }

/* buttons */
.btn { display: inline-flex; align-items: center; gap: 0.55rem; font-weight: 800; font-size: var(--text-sm); letter-spacing: 0.08em; text-transform: uppercase; padding: 0.85rem 1.4rem; border-radius: 2px; transition: background .18s, color .18s, border-color .18s; }
.btn-primary { background: var(--crimson); color: #ffd700; }
.btn-primary:hover { background: var(--crimson-hi); }
.btn-ghost { border: 1px solid var(--line-strong); color: var(--text); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }

/* hero */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero .wrap { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 2rem; align-items: center; min-height: min(78vh, 760px); padding-block: 3rem; }
.hero-title { font-size: var(--text-hero); letter-spacing: 0.1em; margin: 0.9rem 0 0.4rem; line-height: 1; }
.hero-latin { font-family: var(--serif); color: var(--gold); font-size: var(--text-lg); letter-spacing: 0.08em; margin-bottom: 1.4rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2rem; }
.hero-art { position: relative; align-self: stretch; }
.hero-art img { width: 100%; height: 100%; max-height: 700px; object-fit: cover; object-position: center 30%; -webkit-mask-image: radial-gradient(ellipse 70% 75% at 60% 45%, #000 55%, transparent 100%); mask-image: radial-gradient(ellipse 70% 75% at 60% 45%, #000 55%, transparent 100%); }
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; min-height: 0; padding-block: 2.5rem 0; }
  .hero-art { order: -1; max-height: 340px; overflow: hidden; }
  .hero-art img { -webkit-mask-image: linear-gradient(to top, transparent 0%, #000 40%); mask-image: linear-gradient(to top, transparent 0%, #000 40%); max-height: 340px; }
}

/* facts strip */
.facts-band { border-bottom: 1px solid var(--line); }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); }
.fact { padding: 1.6rem 1.25rem; border-right: 1px solid var(--line); }
.fact:first-child { padding-left: 0; }
.fact:last-child { border-right: 0; }
.fact b { display: block; font-family: var(--serif); font-size: var(--text-xl); color: var(--gold); line-height: 1.1; }
.fact span { font-size: var(--text-sm); color: var(--muted); }
@media (max-width: 760px) { .fact:nth-child(3) { padding-left: 0; } .facts { grid-template-columns: 1fr 1fr; } .fact:nth-child(2) { border-right: 0; } .fact:nth-child(-n+2) { border-bottom: 1px solid var(--line); } }

/* sections */
.section { padding-block: clamp(3.5rem, 6vw, 6rem); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 2rem; margin-bottom: 2.2rem; flex-wrap: wrap; }
.section-head p { max-width: 52ch; color: var(--muted); }
.rule { height: 1px; background: linear-gradient(90deg, var(--crimson), transparent 60%); margin: 0.9rem 0 0; width: 120px; }

/* pillar group */
.pillar { margin-top: 2.6rem; }
.pillar-head { display: flex; align-items: baseline; gap: 1rem; padding-bottom: 0.8rem; border-bottom: 1px solid var(--line); margin-bottom: 1rem; flex-wrap: wrap; }
.pillar-head h3 { font-family: var(--serif); letter-spacing: 0.06em; font-size: var(--text-lg); }
.pillar-head span { color: var(--muted); font-size: var(--text-sm); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 1.25rem 1.25rem 1.1rem; display: flex; flex-direction: column; gap: 0.55rem; transition: border-color .2s, transform .2s, background .2s; position: relative; min-height: 190px; }
.card:hover { border-color: rgba(201, 0, 0, 0.6); background: var(--surface-2); transform: translateY(-2px); }
.card .code { font-family: var(--mono); font-size: var(--text-xs); color: var(--faint); letter-spacing: 0.06em; display: flex; justify-content: space-between; }
.card h4 { font-family: var(--serif); font-size: 1.12rem; letter-spacing: 0.04em; line-height: 1.25; }
.card .sub { font-size: var(--text-sm); color: var(--muted); }
.card .q { font-size: var(--text-sm); color: rgba(242,237,228,.82); margin-top: auto; padding-top: 0.6rem; border-top: 1px solid var(--line); }
.tag { display: inline-flex; align-items: center; gap: 0.35rem; font-family: var(--sans); font-size: 0.66rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 0.18rem 0.5rem; border-radius: 2px; border: 1px solid var(--line-strong); color: var(--muted); white-space: nowrap; }
.tag.live { color: var(--s-verified); border-color: rgba(127,179,138,.4); }
.tag.live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--s-verified); }
.tag.hyp { color: var(--s-contested); border-color: rgba(227,134,74,.4); }

/* featured split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 1.6rem; display: flex; flex-direction: column; gap: 0.8rem; }
.feature h3 { font-family: var(--serif); font-size: var(--text-xl); letter-spacing: 0.04em; }
.feature .btn { align-self: flex-start; margin-top: auto; }

/* meaning block */
.meaning { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(2rem, 5vw, 5rem); align-items: start; }
@media (max-width: 860px) { .meaning { grid-template-columns: 1fr; } }
.etym { border-left: 2px solid var(--crimson); padding-left: 1.4rem; display: grid; gap: 1.4rem; }
.etym dt { font-family: var(--serif); font-size: var(--text-lg); color: var(--gold); letter-spacing: 0.06em; }
.etym dd { color: rgba(242,237,228,.84); font-size: var(--text-sm); margin-top: 0.2rem; }

/* status legend */
.legend { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 0.75rem; }
.legend-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 0.9rem 1rem; }
.legend-item p { font-size: var(--text-sm); color: var(--muted); margin-top: 0.35rem; }
.status { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; white-space: nowrap; }
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.st-verified { color: var(--s-verified); } .st-reported { color: var(--s-reported); } .st-claimed { color: var(--s-claimed); }
.st-contested { color: var(--s-contested); } .st-unverified { color: var(--s-unverified); } .st-corrected { color: var(--s-corrected); }

/* page header */
.page-head { border-bottom: 1px solid var(--line); padding-block: clamp(2.5rem, 5vw, 4rem) 2rem; background: radial-gradient(ellipse at 85% 0%, rgba(201,0,0,.16), transparent 55%); }
.crumbs { font-size: var(--text-xs); color: var(--faint); letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 1rem; }
.crumbs a:hover { color: var(--gold); }
.page-head h1 { margin: 0.5rem 0 0.8rem; }
.meta-row { display: flex; flex-wrap: wrap; gap: 0.6rem 1.4rem; margin-top: 1.4rem; font-size: var(--text-sm); color: var(--muted); }
.meta-row b { color: var(--text); font-weight: 600; }

/* dashboard */
.dash { display: grid; grid-template-columns: repeat(12, 1fr); gap: 1rem; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 1.2rem 1.25rem; min-width: 0; }
.panel h3 { font-size: var(--text-sm); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.9rem; display: flex; justify-content: space-between; gap: .6rem 1rem; align-items: center; flex-wrap: wrap; }
.c3 { grid-column: span 3; } .c4 { grid-column: span 4; } .c5 { grid-column: span 5; } .c6 { grid-column: span 6; } .c7 { grid-column: span 7; } .c8 { grid-column: span 8; } .c12 { grid-column: span 12; }
@media (max-width: 960px) { .c3 { grid-column: span 6; } .c4, .c5, .c7, .c8 { grid-column: span 12; } .c6 { grid-column: span 12; } }
@media (max-width: 560px) { .c3 { grid-column: span 6; } .kpi .v { font-size: 1.25rem; } .kpi .l { font-size: .62rem; } .kpi .d { font-size: .74rem; } .panel { padding: 1rem; } }
.kpi .v { font-size: var(--text-xl); font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums lining-nums; }
.kpi .l { font-size: var(--text-xs); color: var(--muted); letter-spacing: 0.08em; text-transform: uppercase; font-weight: 700; }
.kpi .d { font-size: var(--text-sm); font-weight: 700; margin-top: 0.25rem; font-variant-numeric: tabular-nums; }
.up { color: var(--s-verified); } .down { color: var(--s-corrected); }
.chart-box { position: relative; height: 340px; }
@media (max-width: 560px) { .chart-box { height: 260px; } }
.seg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 2px; overflow: hidden; }
.seg button { font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.06em; padding: 0.35rem 0.7rem; color: var(--muted); }
.seg button.on { background: var(--crimson); color: #fff; }

ul.clean { list-style: none; display: grid; gap: 0.55rem; }
ul.clean li { font-size: var(--text-sm); padding-left: 1.1rem; position: relative; color: rgba(242,237,228,.86); }
ul.clean li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 6px; height: 1px; background: var(--crimson-hi); }

.placeholder { border: 1px dashed var(--line-strong); border-radius: var(--r); padding: 1.1rem; color: var(--faint); font-size: var(--text-sm); display: grid; place-items: center; text-align: center; min-height: 120px; }

/* cite box */
.cite { background: var(--surface-2); border: 1px solid var(--line); border-left: 2px solid var(--gold); border-radius: var(--r); padding: 1rem 1.2rem; font-size: var(--text-sm); display: flex; gap: 1rem; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.cite code { font-family: var(--mono); font-size: 0.78rem; color: rgba(242,237,228,.86); white-space: normal; word-break: break-word; flex: 1 1 380px; }

/* timeline */
.timeline { position: relative; display: grid; gap: 0; }
.tl-item { display: grid; grid-template-columns: 130px 1fr; gap: 1.2rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.tl-item:last-child { border-bottom: 0; }
.tl-date { font-family: var(--mono); font-size: var(--text-xs); color: var(--muted); padding-top: 0.15rem; }
.tl-body p { font-size: var(--text-sm); margin-top: 0.3rem; }
.tl-src { font-size: var(--text-xs); color: var(--faint); margin-top: 0.4rem; display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; }
.tl-src a { color: var(--gold); border-bottom: 1px solid rgba(227,179,65,.3); }
.tl-src a:hover { border-bottom-color: var(--gold); }
@media (max-width: 560px) { .tl-item { grid-template-columns: 1fr; gap: 0.3rem; } }

/* table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
th { text-align: left; font-size: var(--text-xs); letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); font-weight: 700; padding: 0.6rem 0.8rem; border-bottom: 1px solid var(--line-strong); }
td { padding: 0.85rem 0.8rem; border-bottom: 1px solid var(--line); vertical-align: top; }
td.by { color: var(--muted); min-width: 140px; }
td.path { color: var(--muted); min-width: 200px; }
.filters { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-bottom: 1rem; }
.chip { font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.06em; padding: 0.35rem 0.75rem; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--muted); transition: all .15s; }
.chip.on, .chip:hover { border-color: var(--gold); color: var(--gold); }

/* frames */
.frames { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0.8rem; }
.frame { border: 1px solid var(--line); border-radius: var(--r); padding: 1rem; background: var(--surface-2); }
.frame b { font-family: var(--serif); letter-spacing: 0.04em; display: block; margin-bottom: 0.25rem; }
.frame .who { font-size: var(--text-xs); color: var(--gold); letter-spacing: 0.06em; text-transform: uppercase; font-weight: 700; }
.frame p { font-size: var(--text-sm); color: var(--muted); margin-top: 0.4rem; }

/* workflow */
.flow { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; counter-reset: step; position: relative; }
.step { padding: 1.3rem 1.1rem 1.4rem; border: 1px solid var(--line); margin-left: -1px; background: var(--surface); position: relative; }
.step::before { counter-increment: step; content: "0" counter(step); font-family: var(--mono); font-size: var(--text-xs); color: var(--crimson-hi); display: block; margin-bottom: 0.6rem; }
.step h4 { font-family: var(--serif); letter-spacing: 0.05em; font-size: 1.08rem; margin-bottom: 0.4rem; }
.step p { font-size: var(--text-sm); color: var(--muted); }
.step .who { margin-top: 0.8rem; font-size: 0.66rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
.who.agent { color: var(--s-claimed); } .who.human { color: var(--gold); } .who.both { color: var(--s-verified); }
@media (max-width: 1000px) { .flow { grid-template-columns: repeat(2, 1fr); } .step { margin: 0 0 -1px -1px; } }
@media (max-width: 520px) { .flow { grid-template-columns: 1fr; } }

.tree { font-family: var(--mono); font-size: 0.8rem; line-height: 1.75; color: rgba(242,237,228,.85); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 1.2rem 1.4rem; overflow-x: auto; white-space: pre; }
.tree .c { color: var(--faint); }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 860px) { .two { grid-template-columns: 1fr; } }

.notice { border: 1px solid rgba(227,179,65,.3); background: var(--gold-soft); border-radius: var(--r); padding: 0.9rem 1.1rem; font-size: var(--text-sm); color: rgba(242,237,228,.9); }

/* footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 3rem 2.2rem; margin-top: 2rem; background: #070606; }
.foot { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 2rem; align-items: start; }
@media (max-width: 760px) { .foot { grid-template-columns: 1fr; } }
.foot h5 { font-size: var(--text-xs); letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); margin-bottom: 0.8rem; }
.foot a { display: block; font-size: var(--text-sm); color: var(--muted); padding: 0.18rem 0; }
.foot a:hover { color: var(--gold); }
.tcs-badge { display: flex; align-items: center; gap: 1rem; margin-top: 1rem; }
.tcs-badge img { width: 132px; height: auto; }
.foot-base { margin-top: 2.4rem; padding-top: 1.2rem; border-top: 1px solid var(--line); font-size: var(--text-xs); color: var(--faint); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

.fade { animation: fade .35s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .fade { animation: none; } .card:hover { transform: none; } }
.hero-art::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, var(--ink) 0%, transparent 28%), linear-gradient(0deg, var(--ink) 0%, transparent 14%), linear-gradient(180deg, var(--ink) 0%, transparent 12%), linear-gradient(270deg, var(--ink) 0%, transparent 10%); }
