:root {
  --ink:#281e32; --muted:#625e69; --violet:#634494; --line:#dfdce0;
  --paper:#faf9f6; --lime:#dcfa90;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color:var(--ink); background:var(--paper); line-height:1.5;
}
* { box-sizing:border-box }
body { margin:0 }
a { color:inherit }
button { font:inherit; cursor:pointer }
[hidden] { display:none !important }
:focus-visible { outline:3px solid #7952ae; outline-offset:4px }
.skip { position:fixed; z-index:8; top:-6rem; left:1rem; padding:.7rem 1rem; background:white }
.skip:focus { top:1rem }
.wrap { width:min(75rem,calc(100% - clamp(2rem,8vw,8rem))); margin-inline:auto }
.site-header { border-bottom:1px solid var(--line) }
.mast { display:flex; align-items:center; justify-content:space-between; min-height:5rem; gap:1rem }
.brand { display:inline-flex; gap:.64rem; align-items:center; text-decoration:none }
.brand img { width:auto; height:3rem; display:block }
.mast nav { display:flex; gap:.45rem; align-items:center }
.mast nav a { font-size:.9rem; font-weight:650; text-decoration:none; padding:.48rem .93rem; border-radius:.55rem }
.mast nav a[aria-current], .mast nav a:hover { background:#eae5ef; color:#543578 }
.hero {
  position:relative; isolation:isolate; overflow:hidden; display:grid; grid-template-columns:1fr 1.05fr;
  background:linear-gradient(110deg,#21162c 8%,#32203d 55%,#433255); color:white;
  margin-top:2rem; border-radius:1.4rem; min-height:25rem;
}
.hero-copy { position:relative; z-index:2; padding:clamp(2rem,3.7vw,3.5rem) 0 clamp(2rem,3.8vw,3.5rem) clamp(1.5rem,4.2vw,3.9rem); align-self:center }
.eyebrow,.card-group { font-size:.79rem; letter-spacing:.09em; font-weight:750; text-transform:uppercase }
.eyebrow { margin:0 0 1rem; color:var(--violet) }
.eyebrow.light { color:#e8d8fd; display:flex; align-items:center; gap:.6rem }
.book-icon { width:1.12rem; height:.86rem; border:1.6px solid currentColor; border-radius:2px 3px 3px 2px; transform:rotate(-6deg); display:inline-block; position:relative }
.book-icon::before { content:""; position:absolute; left:45%; top:0; bottom:0; border-left:1.5px solid currentColor }
.hero h1 { margin:0; font-size:clamp(3.1rem,5.6vw,5.25rem); line-height:.98; font-weight:850; letter-spacing:-.075em }
.hero h1 em { display:block; font-style:normal; color:var(--lime) }
.lead { max-width:29rem; margin:1.25rem 0 1.55rem; color:#eee7f2; font-size:clamp(1rem,1.3vw,1.14rem); line-height:1.5 }
.cta { background:var(--lime); color:#242523; padding:.72rem 1.3rem; display:inline-block; font-weight:750; text-decoration:none; border-radius:.6rem }
.cta:hover { background:#ecffbc }
.hero-stage { position:relative; align-self:stretch; isolation:isolate; display:grid; place-items:center; margin-left:-7%; overflow:visible }
.hero-stage::before { content:""; position:absolute; inset:0 -3% 0 -10%; z-index:-2; background-image:radial-gradient(#ad8bc1 1.2px,transparent 1.5px); background-size:13px 13px; opacity:.35; mask-image:linear-gradient(100deg,transparent,#000 55%) }
.orbit { position:absolute; z-index:-1; width:67%; aspect-ratio:1; border-radius:50%; border:1px solid #a27bba; background:repeating-radial-gradient(circle,transparent 0 16%,#89649d 16.1% 16.4%,transparent 16.5% 23%),radial-gradient(circle at 58% 48%,#79598b, #4a345d 70%); transform:rotate(-15deg) }
.orbit::after,.orbit::before { content:""; position:absolute; inset:8% -14%; border:1px dashed #bda2cb; border-radius:50%; transform:rotate(-24deg); opacity:.75 }
.orbit::before { inset:-5% 8%; transform:rotate(28deg); border-style:solid; opacity:.45 }
.hero-stage img { display:block; width:107%; max-width:46rem; height:auto; filter:drop-shadow(3px 10px 0 #20152785); transform:rotate(-2deg) }
.spark { position:absolute; z-index:1; color:var(--lime); line-height:1 }
.spark.a { font-size:2.4rem; left:15%; top:19%; transform:rotate(10deg) }
.spark.b { font-size:1.55rem; right:13%; bottom:19% }
.spark.c { font-size:1.7rem; left:13%; bottom:21%; color:#d9c8ec }
.catalogue { margin:3rem 0 4.3rem }
.catalogue-title { display:flex; align-items:center; gap:.8rem }
.catalogue-title h2 { font-size:clamp(1.85rem,3vw,2.55rem); letter-spacing:-.062em; line-height:1.13; margin:0; font-weight:800 }
.catalogue-title span { min-width:1.9rem; text-align:center; background:#ece6f1; border-radius:2rem; color:#634479; font-size:.88rem; font-weight:700; padding:.14rem .5rem }
.filters { display:flex; flex-wrap:wrap; gap:.48rem; margin:1.1rem 0 1.35rem }
.filters button { border:1px solid #d9d4d8; border-radius:2rem; background:transparent; color:#554f5a; padding:.41rem .92rem; font-size:.89rem; font-weight:600 }
.filters button[aria-pressed=true] { background:#32263d; border-color:#32263d; color:white }
.filters button:hover:not([aria-pressed=true]) { border-color:#8c749d; background:#eee9f3 }
.cards { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:1.25rem }
.filters[hidden]+.cards { margin-top:1.35rem }
.card { display:flex; flex-direction:column; text-decoration:none; border:1px solid var(--line); border-radius:.95rem; overflow:hidden; background:#fff; transition:transform .15s,border-color .15s }
.card:hover { transform:translateY(-3px); border-color:#90759c }
.cover { overflow:hidden; isolation:isolate; position:relative; display:grid; place-items:center; height:clamp(8.3rem,12vw,10.7rem); background-color:var(--tint); background-image:radial-gradient(var(--dot) 1px,transparent 1.3px); background-size:11px 11px; border-bottom:1px solid #30263815 }
.peach { --tint:#f4bc89; --dot:#ce925b }
.mint { --tint:#addad1; --dot:#76b4a6 }
.violet { --tint:#cec0e9; --dot:#a693c7 }
.sky { --tint:#b6d9ed; --dot:#84b8d1 }
.gold { --tint:#ebd79e; --dot:#c4ab6d }
.cover::before { content:""; position:absolute; z-index:-1; width:64%; aspect-ratio:1; border:1px solid #fff8; transform:rotate(33deg); background:linear-gradient(120deg,#fff1,#fff6); box-shadow:0 0 0 8px #ffffff27,0 0 0 9px #ffffff70,0 0 0 25px #ffffff19 }
.cover img { height:100%; width:100%; object-fit:contain; filter:drop-shadow(0 4px 0 #30263820) }
.card-copy { padding:1.05rem 1.25rem 1.35rem }
.card-group { color:#705a7a; font-size:.72rem; letter-spacing:.085em }
.card h3 { margin:.28rem 0 .45rem; font-size:clamp(1.2rem,1.8vw,1.48rem); line-height:1.2; letter-spacing:-.038em }
.card p { color:var(--muted); font-size:1rem; margin:0; line-height:1.48 }
.footer { border-top:1px solid var(--line); padding:1.45rem 0 2rem; display:flex; align-items:center; gap:1rem; justify-content:space-between; color:var(--muted); font-size:.88rem }
.footer-name { text-decoration:none; color:var(--ink); font-weight:740 }
.reader { margin-bottom:4rem }
.story { max-width:45rem }
.stories { margin-top:1.1rem }
.crumbs { display:flex; flex-wrap:wrap; gap:.65rem; color:var(--muted); font-size:.88rem; margin:1.6rem 0 2rem }
.crumbs a { text-decoration:none }
.crumbs a:hover,.footer-name:hover { text-decoration:underline }
.reader-grid { display:grid; grid-template-columns:minmax(11rem,15.5rem) minmax(0,45rem); justify-content:space-between; gap:clamp(2rem,5vw,5rem); padding-right:min(4vw,4rem) }
.chapter-menu { position:sticky; top:1.5rem; padding:.85rem; border:1px solid var(--line); background:#f2eff4; border-radius:.85rem }
.chapter-menu summary { padding:.3rem .45rem; font-weight:750; cursor:pointer }
.chapter-menu nav { display:grid; gap:.19rem; margin-top:.65rem }
.chapter-group { margin:.65rem .68rem 0; font-size:.84rem; font-weight:700; color:var(--ink) }
.chapter-menu a { font-size:.92rem; line-height:1.4; padding:.55rem .68rem; border-radius:.4rem; text-decoration:none; color:#5d5262 }
.chapter-menu a:hover,.chapter-menu a[aria-current] { background:#e2d9ec; color:#492b66 }
.chapter-menu a[aria-current] { font-weight:700 }
.article-head { border-bottom:1px solid var(--line); padding:0 0 1.5rem; margin-bottom:1.65rem }
.article-head h1 { margin:0; font-size:clamp(2.1rem,4vw,3.2rem); line-height:1.05; letter-spacing:-.055em; overflow-wrap:break-word }
.article-head .eyebrow { margin-bottom:.65rem }
.guide-intro {
  margin:0 0 1.5rem;
  padding:1rem clamp(1rem,3vw,1.5rem);
  border-inline-start:4px solid var(--violet);
  border-radius:.5rem;
  background:#eee8f4;
  font-size:clamp(1rem,1.4vw,1.075rem);
  line-height:1.6;
}
.prose { font-size:1.075rem; line-height:1.7; overflow-wrap:break-word }
.prose h2,.prose h3 { margin:1.85em 0 .55em; line-height:1.18; letter-spacing:-.04em }
.table-nav { display:grid; gap:.3rem; margin-bottom:1.6rem; border-left:3px solid #b998d6; padding:.1rem 1rem }
.table-nav a { color:var(--violet); text-underline-offset:.2em }
.prose h2 { scroll-margin-top:1rem; font-size:clamp(1.55rem,2.7vw,2rem) }
.prose h3 { font-size:1.3rem }
.prose a,.turn-page a:hover { color:#624094; text-underline-offset:.16em }
.prose li { margin:.25rem 0 }
.prose ul,.prose ol { padding-left:1.5rem }
.prose img { display:block; max-width:100%; height:auto; margin:1.35rem auto; border-radius:.65rem }
.prose h2 img { display:inline-block; width:1.15em; height:1.15em; margin:0 .08em 0 0; vertical-align:-.18em; object-fit:contain; border-radius:0 }
.prose :is(td, h3) img[src^="/media/runes/"] { display:inline-block; width:1.1em; height:1.1em; margin:0; vertical-align:-.15em; object-fit:contain; border-radius:0 }
.prose table { border-collapse:collapse; width:100%; margin:1.4rem 0; font-size:.96rem; line-height:1.5 }
.prose th,.prose td { border:1px solid #dcd5df; text-align:left; padding:.55rem .7rem; vertical-align:top }
.prose th { background:#eae4ef }
.prose td:first-child { font-weight:600 }
.prose tr:nth-child(even) { background:#f4f1f4 }
.turn-page { margin-top:2.7rem; padding-top:1rem; border-top:1px solid var(--line); display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,13rem),1fr)); gap:.75rem }
.turn-page a { display:block; border:1px solid var(--line); background:#fff; padding:.8rem 1rem; border-radius:.55rem; text-decoration:none; font-weight:650 }
.turn-page small { display:block; color:var(--muted); font-size:.85rem; font-weight:500 }
@media(max-width:55rem) {
  .cards { grid-template-columns:repeat(2,minmax(0,1fr)) }
  .reader-grid { grid-template-columns:1fr; gap:1rem; padding:0 }
  .chapter-menu { position:static }
  .crumbs { margin-bottom:1rem }
  .hero { min-height:21rem }
  .hero-copy { padding-right:0 }
  .cover { height:9.5rem }
}
@media(max-width:39rem) {
  .wrap { width:calc(100% - 2rem) }
  .mast { min-height:4.1rem }
  .brand { gap:.4rem }
  .brand img { height:2.5rem }
  .mast nav { gap:0 }
  .mast nav a { font-size:.84rem; padding:.45rem .55rem }
  .hero { margin-top:1.05rem; grid-template-columns:1fr; border-radius:1rem }
  .hero-copy { padding:1.65rem 1.45rem 0 }
  .hero h1 { font-size:clamp(2.8rem,10vw,3.5rem) }
  .hero h1 em { display:inline }
  .lead { margin:.8rem 0 1rem }
  .hero-stage { height:clamp(10.5rem,40vw,13rem); margin:.15rem 0 0 10% }
  .hero-stage img { height:125%; width:auto; max-width:100%; object-fit:contain; position:absolute; bottom:-11% }
  .orbit { width:55% }
  .catalogue { margin:2rem 0 3rem }
  .cards { grid-template-columns:1fr }
  .cover { height:9.5rem }
  .filters { gap:.38rem; margin:.9rem 0 1rem }
  .filters button { padding:.35rem .65rem }
  .footer { gap:.45rem; flex-wrap:wrap }
  .prose { font-size:1rem }
}
@media(prefers-reduced-motion:reduce) { .card { transition:none } }
