:root {
  color-scheme: dark;
  --ink: #121620;
  --surface: #1b202b;
  --raised: #222937;
  --line: #424957;
  --gold-line: #6e5b42;
  --paper: #f9f1df;
  --muted: #c5c8d0;
  --gold: #f3d394;
  --mint: #b9e1c8;
  --gutter: clamp(12px, 4vw, 54px);
  --display: Georgia, "Times New Roman", serif;
  --body: system-ui, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 18px; }
body { margin: 0; background: var(--ink); color: var(--paper); font: 1rem/1.58 var(--body); }
body:has(dialog[open]) { overflow: hidden; }
button, input, select { font: inherit; }
button, select, summary, input[type="range"] { cursor: pointer; }
button:disabled, select:disabled, button[aria-disabled="true"] { cursor: default; }
a { color: inherit; text-decoration-color: var(--gold-line); text-underline-offset: .24em; }
a:hover { color: var(--gold); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
[hidden] { display: none !important; }
img { max-width: 100%; }
img, figure { display: block; margin: 0; }
h1, h2, h3, p, ol, ul, dl, dd { margin: 0; }
h1, h2, h3 { line-height: 1.12; text-wrap: balance; overflow-wrap: anywhere; }
h1, h2 { font-family: var(--display); }
h2 { font-size: clamp(2rem, 4.3vw, 3.4rem); letter-spacing: -.035em; }
h3 { font-size: clamp(1.13rem, 1.9vw, 1.4rem); }
:lang(ja), :lang(ko), :lang(zh-CN) { --display: system-ui, "Yu Gothic", "Malgun Gothic", "Microsoft YaHei", sans-serif; }
html:lang(ko) { word-break: keep-all; }
p, dd, figcaption { color: var(--muted); overflow-wrap: anywhere; }
::selection { color: var(--ink); background: var(--gold); }
.frame { width: min(1240px, calc(100% - 2 * var(--gutter))); margin-inline: auto; }
.chapter { margin-block: clamp(54px, 8vw, 104px); }
.section-intro { margin-bottom: clamp(18px, 3vw, 28px); max-width: 68ch; }
.section-intro p { margin-top: 12px; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { position: absolute; z-index: 15; top: 8px; left: 8px; padding: 10px 16px; color: var(--ink); background: var(--gold); }

.site-header { position: relative; z-index: 3; background: #141923; }
.portal-bar { min-height: 63px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-grid; align-items: center; min-height: 44px; text-decoration: none; }
.brand img { width: clamp(124px, 16vw, 172px); height: auto; }
.portal-links { display: flex; flex-wrap: wrap; justify-content: flex-end; column-gap: clamp(12px, 2vw, 26px); }
.portal-links a { display: grid; place-items: center; min-height: 44px; font-size: .9rem; font-weight: 650; text-decoration: none; }
.section-bar { border-block: 1px solid #333a48; background: #191e29; }
.section-bar-inner { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.section-bar nav { display: flex; align-items: stretch; flex-wrap: wrap; gap: 0 clamp(13px, 3vw, 37px); }
.section-bar nav a { display: grid; align-items: center; min-height: 51px; border-bottom: 2px solid transparent; padding-block: 6px 4px; color: var(--muted); font-size: .95rem; font-weight: 660; text-decoration: none; }
.section-bar nav a:hover, .section-bar nav a[aria-current] { color: var(--gold); border-color: var(--gold); }
.language-picker { position: relative; flex: 0 0 auto; }
.language-picker summary { display: flex; align-items: center; justify-content: flex-end; gap: 8px; min-height: 44px; list-style: none; font-size: .91rem; }
.language-picker summary::-webkit-details-marker { display: none; }
.language-picker summary::after { width: 7px; height: 7px; border: solid var(--gold); border-width: 0 1px 1px 0; transform: translateY(-2px) rotate(45deg); content: ""; }
.language-picker[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.globe { position: relative; flex: 0 0 16px; height: 16px; border: 1px solid currentColor; border-radius: 50%; }
.globe::before, .globe::after { position: absolute; inset: 0 3px; border: solid currentColor; border-width: 0 1px; border-radius: 50%; content: ""; }
.globe::after { inset: 6px 0; border-width: 1px 0 0; border-radius: 0; }
.language-picker ul { position: absolute; z-index: 5; inset: calc(100% + 6px) 0 auto auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; width: min(332px, 85vw); padding: 8px; list-style: none; background: var(--raised); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 16px 40px #070912b0; }
.language-picker a { display: flex; align-items: center; min-height: 44px; padding: 6px 10px; border-radius: 4px; text-decoration: none; overflow-wrap: anywhere; }
.language-picker a:hover, .language-picker a[aria-current] { background: #353b47; color: var(--gold); }
.site-footer { border-top: 1px solid var(--line); background: #141923; }
.footer-inner { display: flex; align-items: center; flex-wrap: wrap; gap: 0 clamp(16px, 3vw, 38px); padding-block: 20px; }
.footer-inner a { display: inline-grid; align-items: center; min-height: 44px; font-size: .9rem; }
.footer-brand { font-weight: 760; text-decoration: none; }

.badges { display: flex; gap: 7px; flex-wrap: wrap; align-items: center; margin-bottom: 24px; }
.badge { display: inline-block; width: fit-content; padding: 5px 10px; border: 1px solid #69717c; border-radius: 4px; color: var(--paper); font-size: .79rem; font-weight: 740; line-height: 1.35; }
.status { background: #302921; border-color: #aa8a56; color: #ffe2af; }
.beta { background: #1d302b; border-color: #6b937f; color: var(--mint); }
.button { display: inline-flex; gap: 9px; align-items: center; justify-content: center; min-height: 46px; padding: 9px 16px; border: 1px solid transparent; border-radius: 6px; font-weight: 740; font-size: .94rem; line-height: 1.3; text-decoration: none; text-align: center; overflow-wrap: anywhere; }
.button-primary { background: var(--gold); color: #271c12; box-shadow: inset 0 -3px #87613c65; }
.button-primary:hover { background: #ffe5b5; color: #271c12; }
.button-secondary { background: #202633; color: var(--paper); border-color: #747483; }
.button-secondary:hover { background: #373a47; color: var(--gold); border-color: var(--gold); }
.button:disabled { opacity: .62; }
.studio-line { color: var(--muted); margin-top: 12px; font-size: .91rem; }
.hook-grid, .demo-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.hook-card { border-top: 2px solid var(--gold-line); border-radius: 7px; background: var(--surface); padding: clamp(16px, 2.4vw, 28px); }
.hook-card .sprite { margin-bottom: 10px; }
.hook-card p { margin-top: 9px; font-size: .97rem; }

.sprite { --scale: 1; --cell: calc(var(--pixels) * var(--scale) * 1px); display: inline-block; flex: none; width: var(--cell); height: var(--cell); background-repeat: no-repeat; background-size: calc(var(--cell) * var(--cols)) calc(var(--cell) * var(--rows)); background-position: calc(var(--cell) * var(--col) * -1) calc(var(--cell) * var(--row) * -1); image-rendering: pixelated; }
.sprite-class { --pixels: 32; --cols: 4; --rows: 2; background-image: url("../media/sprites/class_icons.webp"); }
.sprite-element { --pixels: 40; --cols: 8; --rows: 6; background-image: url("../media/sprites/slot_element_icons.webp"); }
.sprite-rarity { --pixels: 32; --cols: 8; --rows: 5; background-image: url("../media/sprites/slot_rarity_icons.webp"); }
.gallery, .download-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.gallery figure, .comparison, .download-grid article { overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.gallery figure a { display: block; overflow: hidden; }
.gallery a:focus-visible { outline-offset: -4px; }
.gallery img, .comparison img, .download-grid img { width: 100%; height: auto; aspect-ratio: 16/9; object-fit: contain; background: #11141c; }
.gallery a:hover img { filter: brightness(1.12); }
.gallery figcaption { padding: 10px 14px; font-weight: 650; }
dialog { width: min(1056px, calc(100% - 22px)); max-height: calc(100% - 24px); padding: 0; background: #171d27; border: 1px solid var(--gold-line); border-radius: 8px; color: var(--paper); }
dialog::backdrop { background: #080b12e8; }
.gallery-modal { position: relative; }
.gallery-modal img { width: 100%; height: auto; max-height: 75dvh; object-fit: contain; background: #11141c; }
.gallery-modal figcaption { padding: 10px 16px 0; text-align: center; }
.gallery-controls { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px; }
.icon-button { display: grid; place-items: center; width: 44px; height: 44px; background: #222937; border: 1px solid #84828a; border-radius: 6px; color: var(--paper); font-size: 1.5rem; line-height: 1; }
.icon-button:hover { border-color: var(--gold); color: var(--gold); }
.gallery-close { position: absolute; z-index: 1; top: 8px; right: 8px; }

.demo-section { padding: clamp(17px, 3.7vw, 45px); border: 1px solid var(--gold-line); border-radius: 12px; background: radial-gradient(ellipse at 15% 3%, #2b2732, #191e28 55%); }
.demo-stats { margin-block: 26px 20px; }
.demo-stats div { display: flex; flex-direction: column-reverse; align-items: flex-start; gap: 4px; border-top: 1px solid #a38860; padding: 10px clamp(5px, 1.5vw, 16px); background: #272935; border-radius: 4px; }
.demo-stats dt { color: var(--paper); font-size: .91rem; font-weight: 650; overflow-wrap: anywhere; }
.demo-stats dd { color: var(--gold); font: 700 clamp(2rem, 5vw, 3.4rem)/1.05 var(--display); }
.facts { display: grid; gap: 0 24px; }
.demo-section .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.facts div { padding: 10px 0; border-bottom: 1px solid var(--line); }
.facts dt { font-weight: 750; }
.facts dd { margin-top: 2px; }
.roadmap-track { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; list-style: none; padding: 0; }
.roadmap-track li { border: 1px solid var(--line); border-top: 3px solid #75a792; border-radius: 6px; background: var(--surface); padding: clamp(10px, 2vw, 24px); }
.roadmap-track .current { border-top-color: var(--gold); background: #302a2b; }
.roadmap-track span { display: block; margin-top: 7px; color: var(--mint); font-weight: 720; font-size: .86rem; }
.roadmap-track .current span { color: var(--gold); }
.planned { display: grid; grid-template-columns: minmax(0, .65fr) minmax(0, 1.35fr); align-items: center; gap: 15px 26px; margin-top: 15px; padding: clamp(16px, 3vw, 31px); border: 1px dashed #77737d; border-radius: 7px; background: #1b2029; }
.planned h3 { margin-top: 7px; }
.planned-badge { color: var(--muted); }
.planned ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 26px; padding-inline-start: 1.1em; color: var(--muted); }
.planned li::marker { color: var(--gold); }

.masthead { position: relative; isolation: isolate; display: grid; overflow: hidden; border: 1px solid var(--gold-line); background: #121b22; margin-top: clamp(16px, 3vw, 40px); min-height: clamp(215px, 26vw, 340px); align-items: end; }
.masthead::before { position: absolute; z-index: -1; inset: 0; content: ""; background: linear-gradient(90deg, #121620 0%, #121620fa 26%, #121620de 47%, #12162020 85%), linear-gradient(0deg, #111521de, transparent 75%); }
.masthead-art { position: absolute; z-index: -2; inset: 0 0 0 auto; height: 100%; object-fit: cover; width: min(70%, 850px); object-position: 60% 51%; }
.masthead-inner { position: relative; z-index: 1; max-width: 71%; padding: clamp(22px, 5vw, 60px); }
.eyebrow { color: var(--gold); font-weight: 780; letter-spacing: .12em; text-transform: uppercase; font-size: .81rem; margin-bottom: 8px; }
.masthead h1 { font-size: clamp(2.3rem, 6vw, 4.6rem); letter-spacing: -.045em; }
.masthead-inner > p:last-child { margin-top: 12px; max-width: 55ch; color: #e0e2e9; }
.masthead + .chapter { margin-top: clamp(28px, 5vw, 66px); }
.comparison-grid, .press-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.compare-images { position: relative; }
.compare-before { position: absolute; top: 0; left: 0; clip-path: inset(0 calc(100% - var(--split)) 0 0); }
.compare-line { position: absolute; inset: 0 auto 0 clamp(0px, var(--split), calc(100% - 2px)); width: 2px; background: #ffdf9d; box-shadow: 0 0 0 1px #27212a; }
.compare-controls { display: grid; grid-template-columns: minmax(0, auto) minmax(60px, 1fr) minmax(0, auto); align-items: center; gap: 10px; padding-inline: clamp(10px, 2vw, 18px); color: var(--gold); background: #222a35; font-weight: 720; font-size: .85rem; overflow-wrap: anywhere; }
.compare-controls input { margin: 0; width: 100%; height: 44px; accent-color: var(--gold); }
.comparison-copy { padding: 14px clamp(12px, 2vw, 20px) 18px; }
.comparison-copy p { margin-top: 7px; }
.playtest { border-left: 3px solid #91bba6; margin-block: 24px; padding: clamp(15px, 2.5vw, 28px); background: #1d2b2b; }
.playtest p { margin-top: 8px; }

.field { min-height: 44px; min-width: 0; width: 100%; border: 1px solid #767683; border-radius: 5px; padding: 6px 9px; background: #202633; color: var(--paper); }

.press-facts { gap: clamp(20px, 5vw, 65px); }
.press-facts .section-intro { margin-bottom: 13px; }
.press-facts .button { margin-top: 14px; }
.press-downloads .button-primary { margin-top: 16px; }
.download-grid article > div { padding: 14px; }
.download-grid h3 { margin-bottom: 12px; }
.download-grid .button { margin: 0 4px 4px 0; }
.download-grid img.download-wordmark { object-fit: contain; padding: clamp(17px, 4vw, 42px); image-rendering: pixelated; }
.download-mark { font-size: 1.1em; }

/* Art and typography from the MazeMancer interface. */
@font-face {
  font-family: "Hotar";
  src: url("stone/hotar-bold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}
:root {
  --ink: #0d1419;
  --surface: #182128;
  --raised: #202a35;
  --line: #3a464e;
  --gold-line: #a68650;
  --gold: #f7d28c;
  --paper: #faebcd;
  --muted: #c3c4bc;
  --mint: #aee1c1;
  --cobalt: #7aaefa;
  --gutter: clamp(10px, 3.4vw, 52px);
  --display: "Hotar", "Segoe UI", sans-serif;
  --frame-image: url("stone/carved-panel.webp");
  --card-image: url("stone/card.webp");
  --button-image: url("stone/button.webp");
  --rune-image: url("stone/rune.webp");
}
:lang(ja), :lang(ko), :lang(zh-CN) {
  --display: "Hotar", "Yu Gothic", "Malgun Gothic", "Microsoft YaHei", system-ui, sans-serif;
}
body {
  background: radial-gradient(ellipse at 50% 0%, #22344077, transparent 820px), url("stone/basalt.webp"), var(--ink);
}
h1, h2, h3 { font-family: var(--display); font-weight: 700; letter-spacing: 0; }
h2 { font-size: 48px; }
h3 { font-size: 24px; }
.masthead h1 { font-size: 72px; letter-spacing: 0; }
::selection { background: #edc382; }
:focus-visible { outline-color: #a9ceff; }
.frame { width: min(1240px, calc(100% - 2 * var(--gutter))); }

.site-header {
  border-top: 3px solid #312b20;
  background: #0f181e;
  box-shadow: 0 3px #030709;
}
.portal-bar { min-height: 55px; }
.brand img { width: 144px; }
.portal-links a { color: #c4c5bd; }
.portal-links a:hover { color: var(--gold); }
.section-bar {
  background: linear-gradient(90deg, #20354480, transparent 52%), url("stone/basalt.webp");
  border-block: 1px solid #72613c;
  box-shadow: inset 0 -2px #0b1218;
}
.section-bar-inner { min-height: 54px; }
.section-bar nav { gap: 6px; align-items: center; }
.section-bar nav a, .language-picker summary {
  justify-content: center;
  min-height: 42px;
  padding: 7px clamp(12px, 2.1vw, 28px);
  color: var(--paper);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}
.section-bar nav a[aria-current], .section-bar nav a:hover, .language-picker summary:hover {
  color: #fff2c6;
  background: linear-gradient(#314b65, #203044);
  --button-image: url("stone/button-lit.webp");
}
.language-picker summary { min-height: 44px; padding-inline: 13px; }
.language-picker ul { padding: 10px; }
.language-picker a, .language-picker ul, .badge, .field { border-radius: 0; }
.language-picker a[aria-current] { box-shadow: inset 2px 0 #88aff5; }
.site-footer {
  background: #10181dec;
  border-block: 1px solid #7c6441;
}
.footer-brand { color: var(--gold); }

.chapter {
  position: relative;
  margin-block: clamp(40px, 6vw, 86px);
  padding: clamp(18px, 3.3vw, 46px);
  background: linear-gradient(145deg, #202934b0, #11192010 52%), #141d24;
}
.chapter, .masthead {
  border: 8px solid transparent;
  border-image: var(--frame-image) 22 20 22 20 / 2 / 0 stretch;
  background-clip: padding-box;
  border-radius: 0;
  image-rendering: pixelated;
  box-shadow: 0 10px 24px #060b106f;
}
.chapter > *, .masthead > *, .diorama-hero { image-rendering: auto; }
.chapter::before {
  position: absolute;
  top: 13px;
  right: 13px;
  width: 22px;
  height: 22px;
  background: var(--rune-image) center / contain no-repeat;
  opacity: .72;
  pointer-events: none;
  content: "";
}
.section-intro { position: relative; padding-bottom: 17px; max-width: 70ch; }
.section-intro::after {
  position: absolute;
  inset: auto auto 0 0;
  width: min(100%, 248px);
  height: 2px;
  background: linear-gradient(90deg, #7aaffb 0 14px, transparent 14px 19px, #b48b50 19px, #664b2d8c 75%, transparent);
  content: "";
}
.section-intro h2, .masthead h1 { color: var(--paper); text-shadow: 3px 3px #090e15; }
.section-intro p { margin-top: 9px; }

.button, .icon-button, .section-bar nav a, .language-picker summary {
  border: 2px solid transparent;
  border-image: var(--button-image) 8 fill / 4 / 0 stretch;
  border-radius: 0;
  background-color: #1f2530;
  background-clip: padding-box;
  box-shadow: 2px 3px #080d13;
  image-rendering: pixelated;
}
.button.button-primary {
  --button-image: url("stone/button-lit.webp");
  background: linear-gradient(180deg, #503b22, #2b2523);
  background-clip: padding-box;
  color: #ffe5a6;
  text-shadow: 1px 2px #20180d;
  border-image-slice: 8;
}
.button.button-secondary {
  background: linear-gradient(180deg, #2e3947, #202632);
  background-clip: padding-box;
  border-image-slice: 8;
  color: var(--paper);
}
.button:hover, .icon-button:hover { --button-image: url("stone/button-lit.webp"); color: #fff3c9; }
.button:active, .icon-button:active, .section-bar nav a:active { --button-image: url("stone/button-pressed.webp"); }
.section-bar nav a:hover, .section-bar nav a[aria-current] {
  border-color: transparent;
  border-image-slice: 8;
  box-shadow: inset 0 -8px #3a76b7aa, 0 2px #080d13;
}
.section-bar nav a[aria-current] { text-decoration: underline; text-underline-offset: 4px; }
.section-bar nav a, .language-picker summary { border-image-slice: 8; }
.field, .language-picker ul {
  border: 1px solid #796344;
  box-shadow: inset 0 -2px #111921;
  background: #222c38;
}
.badge {
  border-color: #796344;
  background: #24282a;
  box-shadow: inset 0 -2px #111820;
  border-radius: 0;
}
.status { background: #34271d; }
.beta { background: #1d3029; border-color: #537d68; }
.studio-line { margin-top: 18px; color: #c8beaa; font-size: .87rem; text-align: center; }
.hooks { margin-top: clamp(32px, 5vw, 64px); }
.summon-section, .maze-chapter { display: grid; align-items: center; gap: clamp(18px, 4vw, 52px); }
.summon-section .section-intro, .maze-chapter .section-intro { margin-bottom: 0; }
@media (min-width: 960px) {
  .summon-section, .maze-chapter { grid-template-columns: minmax(0, .72fr) minmax(0, 1.13fr); }
}

.hook-card, .gallery figure, .download-grid article, .planned, .roadmap-track li,
.demo-stats div, .playtest, .timeline-note, dialog {
  border: 5px solid transparent;
  border-image: var(--card-image) 12 / 1 / 0 stretch;
  border-radius: 0;
  background: linear-gradient(152deg, #22314297, transparent 72%), #1a222b;
  background-clip: padding-box;
}
.hook-card {
  background: radial-gradient(ellipse at 16% 0%, #3c4e6c55, transparent 66%), #19232b;
  background-clip: padding-box;
  padding: clamp(12px, 2.2vw, 29px);
}
.hook-card .sprite { margin-bottom: 9px; }
.hook-card:hover, .roadmap-track .current { background-color: #242c38; }
.gallery, .download-grid { gap: 12px; }
.gallery figcaption { min-height: 48px; }
.gallery figure, .comparison, .download-grid article { align-self: start; }
.demo-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.demo-stats div { padding: 10px 12px; }
.demo-stats dd { font-size: 48px; }
.demo-section .facts { gap: 8px 23px; }
.roadmap-track li.current { background: linear-gradient(145deg, #4c3b27, #292629); background-clip: padding-box; }
.planned ul { padding-inline-start: 1em; }
.download-grid article > div { padding: 12px; }
dialog { overflow: auto; }

.masthead {
  border-width: 8px;
  min-height: clamp(214px, 25vw, 352px);
  align-items: center;
}
.masthead::before {
  background: linear-gradient(90deg, #121a22 2%, #121a22fa 24%, #121a22b8 50%, #121a2238 90%), linear-gradient(0deg, #101921bb, transparent 65%);
}
.masthead-inner { position: relative; padding: clamp(18px, 4vw, 62px); }
.masthead-inner::before {
  position: absolute;
  top: clamp(13px, 3vw, 39px);
  left: clamp(18px, 4vw, 62px);
  width: 46px;
  height: 2px;
  background: linear-gradient(90deg, #76acf7 0 8px, transparent 8px 12px, #9f7c53 12px);
  content: "";
}
.eyebrow { margin-top: 6px; margin-bottom: 8px; color: var(--gold); }
.comparison { padding: 8px; border: 7px solid transparent; border-image: url("stone/tablet.webp") 13 / 2 / 0 stretch; background: #252624; background-clip: padding-box; }
.compare-images { border: 2px solid #6d5941; box-shadow: 0 1px #080d12; }
.compare-line::after {
  position: absolute;
  inset: calc(50% - 9px) auto auto -8px;
  width: 18px;
  height: 18px;
  background: #283b5d;
  border: 2px solid #ffdb8e;
  box-shadow: 2px 2px #151517;
  content: "";
}
.compare-controls { background: #252b31; min-height: 47px; }
.comparison-copy { padding: 12px 4px 6px; }

.timeline { position: relative; padding: 0; list-style: none; }
.timeline li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 148px minmax(0, 1fr);
  align-items: center;
  min-height: 164px;
}
.timeline-note { grid-column: 1; grid-row: 1; padding: 17px 23px; margin-block: 6px; }
.timeline li:nth-child(even) .timeline-note { grid-column: 3; }
.timeline-date { margin-bottom: 5px; color: var(--gold); font-size: .87rem; font-weight: 750; }
.timeline li p { margin-top: 6px; }
.timeline-rail {
  position: relative;
  align-self: stretch;
  grid-column: 2;
  grid-row: 1;
  background: url("stone/road-turn.webp") center / 100% 100% no-repeat;
  image-rendering: pixelated;
}
.timeline li:nth-child(odd) .timeline-rail { background-image: url("stone/road-return.webp"); }
.village-art {
  position: absolute;
  left: 29%;
  top: 50%;
  width: 80px;
  height: 74px;
  background: var(--village) center no-repeat;
  transform: translate(-50%, -64%);
  filter: drop-shadow(2px 5px 0 #15130c90);
}
.timeline li:nth-child(even) .village-art { left: 71%; }
.timeline-rail::after {
  content: "";
  position: absolute;
  left: 29%;
  top: calc(50% + 14px);
  width: 7px;
  height: 7px;
  background: var(--cobalt);
  box-shadow: 0 0 0 2px #162027, 0 0 9px #357ed5;
  transform: translateX(-50%) rotate(45deg);
}
.timeline li:nth-child(even) .timeline-rail::after { left: 71%; }

@keyframes glint {
  0% { transform: scale(.75); opacity: 0; }
  34% { transform: scale(1); opacity: 1; }
  100% { transform: scale(.55); opacity: 0; }
}
.cursor-glint {
  position: fixed;
  z-index: 4;
  display: none;
  left: var(--glint-x, 0);
  top: var(--glint-y, 0);
  width: 15px;
  height: 15px;
  color: #a8caff;
  pointer-events: none;
  animation: glint .6s steps(5, end) both;
}
.cursor-glint.is-visible { display: block; }
.cursor-glint::after {
  position: absolute;
  inset: 0;
  background: currentColor;
  clip-path: polygon(43% 0, 57% 0, 57% 38%, 72% 38%, 72% 44%, 100% 44%, 100% 56%, 72% 56%, 72% 62%, 57% 62%, 57% 100%, 43% 100%, 43% 62%, 28% 62%, 28% 56%, 0 56%, 0 44%, 28% 44%, 28% 38%, 43% 38%);
  content: "";
}
@media (max-width: 790px) {
  h2 { font-size: 36px; }
  .masthead h1 { font-size: 48px; }
  .section-bar-inner { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; padding-block: 4px; }
  .section-bar nav { width: 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
  .section-bar nav a { padding: 6px 3px; min-height: 44px; font-size: .82rem; overflow-wrap: anywhere; }
  .language-picker { justify-self: end; }
  .hook-grid, .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .timeline li { grid-template-columns: 82px minmax(0, 1fr); min-height: 126px; }
  .timeline-rail { grid-column: 1; }
  .timeline li:nth-child(n) .timeline-note { grid-column: 2; }
  .village-art { background-size: contain; width: 62px; height: 55px; }
}
@media (max-width: 560px) {
  .chapter { padding: 13px; }
  .chapter::before { top: 5px; right: 5px; width: 12px; height: 12px; }
  .portal-bar { min-height: 45px; }
  .brand img { width: 119px; }
  .portal-links { column-gap: 9px; }
  .portal-links a { font-size: .78rem; }
  .hook-grid { gap: 7px; }
  .hook-card { padding: 12px 8px; }
  .hook-card p, .gallery figcaption { font-size: .85rem; }
  .gallery { gap: 6px; }
  .gallery figcaption { padding: 5px 6px; }
  .demo-stats, .demo-section .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .masthead { min-height: 185px; }
  .masthead-art { width: 100%; }
  .masthead-inner { max-width: none; padding: 19px 14px; }
  .masthead-inner::before { left: 14px; }
  .masthead::before { background: linear-gradient(90deg, #111a22f5, #111a22be), linear-gradient(0deg, #111921b8, transparent); }
  .comparison-grid, .press-facts, .download-grid, .planned { grid-template-columns: 1fr; }
  .timeline li { grid-template-columns: 56px minmax(0, 1fr); }
  .village-art { width: 45px; height: 46px; }
  .timeline-note { padding: 11px 9px; margin-inline-start: 4px; }
  .timeline-note p { font-size: .88rem; }
}
@media (max-width: 350px) {
  .masthead h1 { font-size: 36px; }
  .hook-grid, .roadmap-track { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0s !important; transition-duration: 0s !important; }
  .cursor-glint { display: none !important; }
}
