/* The FancyGens site: the in-game menu's look (main-plugin/src/main/resources/mcgui/fancygens.html) as a page.
   Pixel art is shown at whole multiples with hard edges; type is the Minecraft face at multiples of 8 px. */

@font-face {
  font-family: Minecraft;
  src: url(fonts/minecraft.ttf) format("truetype");
  font-display: swap;
}

:root {
  --outline: #0e0818; --deep: #1a1029; --surface: #21153a; --stone: #2b1b42; --stone-hi: #3f2a5c; --stone-lit: #5a3f78;
  --gold-hi: #fff1b0; --gold: #f8d26a; --gold-mid: #e0a830; --gold-lo: #a8661c; --gold-ink: #5c3010;
  --mag-hi: #ffd0f4; --mag: #ff7ae6; --mag-mid: #ff3fd2; --mag-lo: #c41aa6; --mag-ink: #6e0a5c;
  --pink: #ffb3dc; --purple: #b77cff; --purple-lo: #5b28b0; --mint: #7cf0b4; --mint-lo: #1f7a4f; --bad: #ff8a9e;
  --text: #f6ecff; --muted: #b7a4cf; --dim: #85739f;
  --shadow: 6px 8px 0 rgba(0, 0, 0, .35);
  --gold-frame: 0 0 0 2px var(--outline), 0 0 0 4px var(--gold-mid), 0 0 0 6px var(--gold-lo), 0 0 0 8px var(--outline);
  --card-frame: 0 0 0 2px var(--outline), 0 0 0 4px var(--purple-lo), 0 0 0 6px var(--outline);
  --page: min(1240px, 100% - 48px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  font-family: Minecraft, "Courier New", monospace; font-size: 16px; line-height: 24px; color: var(--text);
  background: url(art/ui/bg_tile@4x.png) 0 0 / 64px 64px, var(--deep);
  -webkit-font-smoothing: none; font-smooth: never; text-rendering: optimizeSpeed;
}
/* Inherited, so backgrounds get hard pixels too; photos and renders opt out with image-rendering: auto. */
html { image-rendering: crisp-edges; image-rendering: pixelated; }
img { display: block; max-width: 100%; height: auto; }
/* Pixel art sized by site.js to a whole number of device pixels per art pixel; centred in what's left. */
img[data-px] { margin-inline: auto; }
a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-hi); }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 4px; }
b { font-weight: normal; color: var(--text); }
code { font-family: inherit; color: var(--pink); }
.muted { color: var(--muted); }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; padding: 8px 16px; background: var(--deep); box-shadow: var(--gold-frame); }

h1, h2, h3 { font-weight: normal; text-shadow: 3px 3px 0 var(--outline); }
h1 { font-size: 48px; line-height: 56px; }
h2 { font-size: 40px; line-height: 48px; color: var(--gold); text-shadow: 4px 4px 0 var(--gold-ink); }
h3 { font-size: 24px; line-height: 32px; color: var(--text); }
p + p { margin-top: 16px; }

/* --- Buttons (the menu's) ---------------------------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; gap: 8px; border: 0; cursor: pointer; font: inherit; font-size: 16px; color: #fff;
  padding: 10px 18px 14px; text-shadow: 2px 2px 0 var(--outline); transition: transform 90ms;
  box-shadow: 0 0 0 2px var(--outline), inset 0 2px 0 rgba(255, 255, 255, .25), inset 0 -4px 0 rgba(0, 0, 0, .35); }
.btn:hover { transform: translateY(-2px); color: #fff; }
.btn:active { transform: translateY(2px); }
.btn.magenta { background: var(--mag-lo); text-shadow: 2px 2px 0 var(--mag-ink); }
.btn.magenta:hover { background: #d42fbb; }
.btn.gold { background: var(--gold-mid); color: #2a1404; text-shadow: 2px 2px 0 var(--gold); }
.btn.gold:hover { background: var(--gold); color: #2a1404; }
.btn.stone { background: var(--stone-hi); }
.btn.stone:hover { background: var(--stone-lit); }

/* --- Frames ----------------------------------------------------------------------------------------- */
.frame { position: relative; background: var(--surface); box-shadow: var(--gold-frame), var(--shadow), 6px 8px 0 8px rgba(0, 0, 0, .35); }
.frame > .fl { position: absolute; width: 64px; height: 64px; z-index: 2; pointer-events: none; }
.fl.tl { top: -16px; left: -16px; }
.fl.tr { top: -16px; right: -16px; transform: scaleX(-1); }
.fl.bl { bottom: -16px; left: -16px; transform: scaleY(-1); }
.fl.br { bottom: -16px; right: -16px; transform: scale(-1, -1); }

/* --- Top bar ------------------------------------------------------------------------------------------ */
.topbar { position: fixed; z-index: 20; inset: 0 0 auto; display: flex; align-items: center; gap: 24px; height: 64px; padding: 0 24px;
  background: rgba(14, 8, 24, .88); box-shadow: 0 2px 0 var(--outline), 0 4px 0 var(--gold-lo), 0 6px 0 var(--outline); }
.bar-logo img { width: 186px; height: auto; margin: 0; }
.bar-links { display: flex; gap: 2px; padding: 2px; margin-left: auto; background: var(--outline); }
.bar-links a { padding: 6px 12px 8px; color: var(--muted); background: var(--deep); box-shadow: inset 0 2px 0 var(--stone-hi), inset 0 -4px 0 var(--outline); }
.bar-links a:hover { color: var(--text); background: var(--stone); }
.bar-links a.on { color: var(--gold); background: var(--stone-hi); box-shadow: inset 0 0 0 2px var(--gold-mid); }
.bar-status { display: flex; align-items: center; gap: 8px; padding: 6px 12px 8px; color: var(--text); white-space: nowrap;
  background: rgba(14, 8, 24, .78); box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--stone-hi); }
.lamp { width: 12px; height: 12px; flex: none; }

/* --- Hero ------------------------------------------------------------------------------------------- */
.hero { position: relative; min-height: max(760px, 100vh); display: grid; place-items: center; overflow: hidden; padding: 112px 24px 200px; }
.sky, .layer { position: absolute; inset: 0; }
.sky { z-index: 0; }
/* The sky is scaled by a whole number of device pixels per art pixel (--sky-size, set by site.js). */
.sky-base { background: url(art/web/hero_sky.png) center top / var(--sky-size, cover), #1a1029; }
/* The drifting layers move by transform, which the compositor does on its own: animating
   background-position repaints the whole layer every frame. Each is one tile wider than the hero. */
.sky-sparkles { inset: 0 0 -270px -480px; background: url(art/web/hero_sparkles.png) 0 0 / 1920px 1080px repeat;
  animation: drift 120s ease-in-out infinite alternate; }
.clouds-back { top: auto; left: -1920px; height: 360px; background: url(art/web/hero_clouds_back.png) 0 100% / 1920px 360px repeat-x;
  animation: slide 180s linear infinite; }
.clouds-front { top: auto; left: -1920px; bottom: -24px; height: 280px; background: url(art/web/hero_clouds_front.png) 0 100% / 1920px 280px repeat-x;
  animation: slide 90s linear infinite reverse; }
@keyframes slide { from { transform: translateX(0); } to { transform: translateX(1920px); } }
@keyframes drift { to { transform: translate(480px, -270px); } }

/* Parallax: each .depth layer moves down at --depth of the scroll. Where the browser can tie an
   animation to the scroll position, it runs on the compositor and keeps up with a phone's scrolling;
   elsewhere site.js moves the layers. */
.depth { position: absolute; pointer-events: none; }
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .depth { animation: depth linear both; animation-timeline: scroll(root block); animation-range: 0 120vh; }
  }
}
@keyframes depth { to { translate: 0 calc(var(--depth) * 120vh); } }

/* The islands are renders, not pixel art: scaled smoothly. They frame the copy rather than sit under it:
   the hub low on the right, the quarry low on the left, the far ones small around the edges, clear of
   the gem moon (upper right). */
.isle { width: 100%; height: auto; image-rendering: auto; filter: drop-shadow(0 24px 0 rgba(14, 8, 24, .25));
  animation: bob 9s ease-in-out infinite alternate; }
.isle-hub { width: min(33vw, 520px); right: 1%; bottom: 70px; }
.isle-hub .isle { animation-duration: 11s; }
.isle-quarry { width: min(23vw, 340px); left: 1%; bottom: 120px; }
.isle-quarry .isle { animation-delay: -3s; }
.isle-timber { width: min(12vw, 180px); left: 25%; bottom: 30px; }
.isle-timber .isle { animation-delay: -6s; }
.isle-dunes { width: min(13vw, 200px); left: 10%; top: 34%; }
.isle-dunes .isle { animation-delay: -2s; }
.isle-reef { width: min(11vw, 170px); right: 4%; top: 37%; }
.isle-reef .isle { animation-delay: -5s; }
.isle-ember { width: min(9vw, 140px); left: 3%; top: 12%; }
.isle-ember .isle { animation-delay: -8s; filter: brightness(.9); }
.isle-void { width: min(6vw, 96px); right: 27%; top: 13%; }
.isle-void .isle { animation-delay: -1s; filter: brightness(.85); }
@keyframes bob { from { transform: translateY(-10px); } to { transform: translateY(10px); } }
@media (prefers-reduced-motion: reduce) {
  .sky-sparkles, .clouds-back, .clouds-front, .isle { animation: none; }
}
/* On phones the oversized drifting layers would cost tens of megabytes of graphics memory each:
   they stand still there, and the parallax and the bobbing islands carry the motion. */
@media (max-width: 760px) {
  .sky-sparkles, .clouds-back, .clouds-front { animation: none; }
  .sky-sparkles { inset: 0; }
  .clouds-back, .clouds-front { left: 0; }
}

.hero-copy { position: relative; z-index: 5; display: flex; flex-direction: column; align-items: center; gap: 24px;
  max-width: 760px; text-align: center; margin-top: -120px; }
.hero-logo { width: 496px; height: auto; filter: drop-shadow(6px 8px 0 rgba(14, 8, 24, .55)); }
.hero h1 { color: var(--text); }
.hero-lede { max-width: 640px; color: var(--mag-hi); text-shadow: 2px 2px 0 var(--outline); }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }

/* The address plaque: a gold-framed panel with gems at its ends. */
.plaque { position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px 16px; padding: 16px 24px 20px;
  text-align: left; background: linear-gradient(180deg, var(--stone-hi), var(--stone)); box-shadow: var(--gold-frame), 6px 8px 0 8px rgba(0, 0, 0, .35); }
.plaque-gem { position: absolute; top: 50%; width: 24px; height: 24px; margin-top: -12px; }
.plaque-gem.left { left: -20px; } .plaque-gem.right { right: -20px; }
.plaque-label { grid-column: 1 / 3; color: var(--muted); }
.plaque-address { font-size: 32px; line-height: 40px; color: var(--gold); text-shadow: 3px 3px 0 var(--gold-ink); }
.plaque-live { grid-column: 1 / 3; display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 6px; color: var(--muted);
  background: rgba(14, 8, 24, .78); box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--stone-hi); }

/* --- Ticker ------------------------------------------------------------------------------------------ */
.ticker { position: relative; z-index: 6; display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; padding: 2px;
  background: var(--outline); box-shadow: 0 -4px 0 var(--gold-mid), 0 -6px 0 var(--outline), 0 4px 0 var(--gold-lo), 0 6px 0 var(--outline); }
.tick { display: grid; grid-template-columns: 32px 1fr; align-items: center; gap: 0 12px; padding: 16px 24px; background: var(--stone); }
.tick img { grid-row: 1 / 3; width: 32px; height: 32px; }
.tick b { font-size: 32px; line-height: 40px; color: var(--gold); text-shadow: 3px 3px 0 var(--gold-ink); }
.tick span { color: var(--muted); }

/* --- Sections ------------------------------------------------------------------------------------------ */
main { display: flex; flex-direction: column; gap: 128px; padding: 128px 0; }
.section { width: var(--page); margin: 0 auto; }
.section-head { display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; margin-bottom: 56px; }
.section-head p { max-width: 640px; color: var(--muted); }
.section-head.compact { margin-bottom: 32px; }
.divider { width: 480px; height: 32px; }

/* The first hour: a numbered path of illustrated steps. */
.path { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px 32px; counter-reset: step; }
.path li { position: relative; counter-increment: step; padding: 12px 12px 16px; background: var(--stone);
  box-shadow: var(--card-frame), inset 0 2px 0 var(--stone-lit), var(--shadow); }
.path li::before { content: counter(step); position: absolute; z-index: 1; top: -14px; left: -14px; width: 40px; height: 40px;
  display: grid; place-items: center; font-size: 24px; color: #2a1404; text-shadow: 2px 2px 0 var(--gold);
  background: var(--gold-mid); box-shadow: 0 0 0 2px var(--outline), inset 0 2px 0 var(--gold-hi), inset 0 -4px 0 var(--gold-lo); }
.path img { width: 100%; aspect-ratio: 5 / 3; box-shadow: 0 0 0 2px var(--outline); }
.path h3 { margin: 12px 0 4px; font-size: 16px; line-height: 24px; color: var(--gold); text-shadow: 2px 2px 0 var(--gold-ink); }
.path p { color: var(--muted); }

/* Features: a big framed scene beside its text; .flip puts the scene on the right. */
.feature { display: grid; grid-template-columns: auto 1fr; gap: 64px; align-items: center; }
.feature.flip > .frame { order: 2; }
.scene-frame { padding: 8px; background: var(--deep); }
.scene-frame .scene { width: 600px; height: auto; }
.feature-copy { display: flex; flex-direction: column; gap: 16px; }
.feature-copy p { color: var(--muted); max-width: 60ch; }
.feature-copy h2 { margin-bottom: 8px; }
.facts { list-style: none; display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.facts li { display: grid; grid-template-columns: 32px 1fr; align-items: center; gap: 12px; color: var(--muted); }
.facts img { width: 32px; height: 32px; flex: none; }
.facts b { color: var(--text); margin-right: 4px; }

/* Every gen: a dense wall of cards grouped by tier. */
.gens-wall { display: grid; grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 12px; padding: 24px;
  background: rgba(14, 8, 24, .55); box-shadow: var(--card-frame); }
.gen { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px 6px;
  background: linear-gradient(180deg, var(--stone-hi), var(--stone)); box-shadow: 0 0 0 2px var(--outline), inset 0 2px 0 var(--stone-lit); }
.gen img.model { width: 72px; height: 84px; }
.gen .tier { position: absolute; top: 4px; right: 4px; display: flex; align-items: center; gap: 2px; font-size: 16px; color: var(--muted); }
.gen .tier img { width: 16px; height: 16px; }
.gen .name { font-size: 16px; line-height: 20px; text-align: center; color: var(--text); }
.gen .drops { display: none; position: absolute; z-index: 3; bottom: calc(100% + 6px); left: 50%; translate: -50% 0; white-space: nowrap;
  padding: 4px 10px 6px; color: var(--text); background: var(--deep); box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--gold-lo); }
.gen:hover .drops, .gen:focus-visible .drops { display: block; }
.gen:hover { box-shadow: 0 0 0 2px var(--outline), 0 0 0 4px var(--mag-lo), inset 0 2px 0 var(--stone-lit); }
.gen.late { background: linear-gradient(180deg, #2a1640, #1d1030); }
.tier-break { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; color: var(--gold); text-shadow: 2px 2px 0 var(--gold-ink); }
.tier-break::after { content: ""; flex: 1; height: 2px; background: var(--gold-lo); box-shadow: 0 2px 0 var(--outline); }

.pieces { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 16px 20px; margin-top: 8px; }
.pieces figure { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.pieces img { width: 72px; height: 84px; }
.pieces figcaption { color: var(--muted); }

.render-band { display: grid; grid-template-columns: 1fr 360px; gap: 48px; align-items: center; }
.render-band img { width: 100%; max-width: 880px; filter: drop-shadow(8px 10px 0 rgba(0, 0, 0, .35)); }
.render-band p { color: var(--muted); }

/* Islands: the scene, a row of the islands themselves, then a gallery of views. */
.islands-intro { display: grid; grid-template-columns: auto 1fr; gap: 64px; align-items: center; margin-bottom: 64px; }
.isle-row { list-style: none; display: grid; grid-template-columns: repeat(7, 1fr); gap: 16px; align-items: end; margin-bottom: 64px; }
.isle-row li { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.isle-row img { width: 100%; height: 150px; object-fit: contain; image-rendering: auto; animation: bob 7s ease-in-out infinite alternate; }
.isle-row li:nth-child(2n) img { animation-delay: -3s; }
.isle-row li:nth-child(3n) img { animation-delay: -5s; }
.isle-row b { color: var(--gold); text-shadow: 2px 2px 0 var(--gold-ink); }
.isle-row span { color: var(--muted); }
.shots { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 200px; grid-auto-flow: dense; gap: 16px; }
.shots figure { position: relative; overflow: hidden; box-shadow: 0 0 0 2px var(--outline), 0 0 0 4px var(--gold-lo), 0 0 0 6px var(--outline); }
.shots figure.wide { grid-column: span 2; grid-row: span 2; }
.shots img { width: 100%; height: 100%; object-fit: cover; image-rendering: auto; transition: transform 300ms; }
.shots figure:hover img { transform: scale(1.04); }
.shots figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 4px 10px 6px; color: var(--text);
  background: rgba(14, 8, 24, .82); box-shadow: 0 -2px 0 var(--outline); }

.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.card { display: flex; flex-direction: column; gap: 12px; padding: 12px 12px 24px; background: var(--stone); box-shadow: var(--card-frame), var(--shadow); }
.card .scene { width: 100%; box-shadow: 0 0 0 2px var(--outline); }
.card h3 { padding: 0 8px; color: var(--gold); text-shadow: 2px 2px 0 var(--gold-ink); }
.card p { padding: 0 8px; color: var(--muted); }
.items { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 8px 0; }
.items img { width: 32px; height: 32px; }

.settle .map-frame { padding: 8px; background: var(--deep); }
.settle .map { width: 584px; height: 584px; }
.settle { grid-template-columns: 1fr 600px; }

/* --- Live: the in-game Stats window ---------------------------------------------------------------- */
.window { display: flex; flex-direction: column; gap: 32px; padding: 24px; background: url(art/ui/bg_tile@4x.png) 0 0 / 64px 64px, var(--deep);
  box-shadow: var(--gold-frame), 6px 8px 0 8px rgba(0, 0, 0, .35); }
.window-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.tabs, .spans { display: flex; gap: 2px; padding: 2px; background: var(--outline); }
.tab, .span { border: 0; cursor: pointer; font: inherit; font-size: 16px; color: var(--muted); padding: 6px 12px 10px; background: var(--deep);
  text-shadow: 2px 2px 0 var(--outline); box-shadow: inset 0 2px 0 var(--stone-hi), inset 0 -4px 0 var(--outline); }
.tab:hover, .span:hover { color: var(--text); background: var(--stone); }
.tab.on { color: var(--pink); background: var(--stone-hi); box-shadow: inset 0 0 0 2px var(--mag-lo), inset 0 4px 0 var(--stone-lit); }
.span.on { color: var(--gold); background: var(--stone-hi); box-shadow: inset 0 0 0 2px var(--gold-mid), inset 0 4px 0 var(--stone-lit); }

.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.tile { position: relative; display: grid; grid-template-columns: 1fr 96px; grid-template-rows: auto auto auto; gap: 2px 8px; padding: 12px 16px 14px;
  background: var(--stone); box-shadow: var(--card-frame), inset 0 2px 0 var(--stone-lit), var(--shadow); }
.tile > img { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px; }
.tile-label { grid-column: 1 / 3; color: var(--muted); letter-spacing: 2px; }
.tile b { grid-column: 1 / 3; font-size: 32px; line-height: 40px; text-shadow: 3px 3px 0 var(--outline); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile b.gold { color: var(--gold); text-shadow: 3px 3px 0 var(--gold-ink); }
.tile small { font-size: 16px; color: var(--dim); align-self: end; }
.tile small .up { color: var(--mint); } .tile small .down { color: var(--bad); }
.tile .spark { width: 96px; height: 24px; align-self: end; }

.live-grid { display: grid; grid-template-columns: 1fr 360px; gap: 40px; }
.chart-frame { padding: 20px 24px 16px; }
.chart-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; margin-bottom: 12px; }
.chart-head p { color: var(--muted); flex: 1; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; box-shadow: 0 0 0 2px var(--outline); }
.chart { position: relative; height: 360px; }
.chart canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.chart-labels span { position: absolute; color: var(--dim); white-space: nowrap; }
.chart-labels .end { color: var(--text); padding: 0 4px; background: var(--surface); }
.crosshair { position: absolute; top: 0; width: 2px; pointer-events: none; background: repeating-linear-gradient(180deg, var(--muted) 0 2px, transparent 2px 4px); }
.tooltip { position: absolute; z-index: 4; pointer-events: none; white-space: nowrap; padding: 6px 10px 8px; background: var(--deep);
  box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--gold-lo); }
.tooltip .t { color: var(--muted); }
.tooltip .r { display: flex; align-items: center; gap: 8px; }
.tooltip .r i { width: 10px; height: 10px; box-shadow: 0 0 0 2px var(--outline); }
.tooltip .r em { font-style: normal; color: var(--muted); }
.chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); }

.board { padding: 20px 20px 16px; box-shadow: var(--card-frame), var(--shadow); }
.board-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 12px; }
.board-head h3 { white-space: nowrap; }
.board-span { color: var(--muted); margin: 4px 0 12px; }
.select select { font: inherit; font-size: 16px; color: var(--text); padding: 4px 8px 6px; border: 0; background: var(--deep);
  box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--stone-hi); }
.bars { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.bars li { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 2px 8px; }
.bars .rank { color: var(--dim); }
.bars .who { display: flex; align-items: center; gap: 6px; overflow: hidden; white-space: nowrap; }
.bars .who img { width: 16px; height: 16px; flex: none; box-shadow: 0 0 0 1px var(--outline); }
.bars .val { color: var(--muted); }
.bars .bar { grid-column: 2 / 4; height: 10px; background: var(--gold-mid); box-shadow: inset 0 2px 0 var(--gold-hi), inset 0 -2px 0 var(--gold-lo); }
.bars li:first-child .bar { background: var(--gold); }

.live-lower { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; }
.live-lower .frame, .lookup, .ingame { padding: 20px; box-shadow: var(--card-frame), var(--shadow); }
.live-lower h3, .ingame h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.live-lower h3 img { width: 32px; height: 32px; }
.live-lower ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.world { display: grid; grid-template-columns: 12px 1fr auto; align-items: center; gap: 2px 10px; }
.world .meta { grid-column: 2 / 4; color: var(--dim); }
.world .count { color: var(--gold); }
.world.down .name { color: var(--dim); }
.tpsbar { grid-column: 2 / 4; height: 6px; background: var(--stone-hi); box-shadow: 0 0 0 1px var(--outline); }
.tpsbar i { display: block; height: 100%; background: var(--mint); }
.heads { flex-direction: row !important; flex-wrap: wrap; }
.heads li { display: flex; align-items: center; gap: 6px; padding: 4px 8px 6px; background: var(--deep); box-shadow: 0 0 0 2px var(--outline); }
.heads img { width: 16px; height: 16px; }
.heads small { color: var(--dim); font-size: 16px; }
.feed li { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 8px; color: var(--muted); }
.feed img { width: 24px; height: 24px; }
.feed b { color: var(--text); }
.feed time { color: var(--dim); }

.lookup-form { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.lookup-form label { display: flex; align-items: center; gap: 10px; font-size: 24px; line-height: 32px; text-shadow: 3px 3px 0 var(--outline); }
.lookup-form label img { width: 32px; height: 32px; }
.lookup-form input { flex: 1; min-width: 200px; font: inherit; font-size: 24px; line-height: 32px; color: var(--gold); padding: 6px 12px 8px; border: 0;
  background: var(--deep); box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--stone-hi); }
.lookup-form input::placeholder { color: var(--dim); }
.profile { margin-top: 24px; display: grid; grid-template-columns: 200px 1fr 1fr; gap: 24px; }
.profile-card { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px; text-align: center; background: var(--stone);
  box-shadow: var(--card-frame); }
.profile-card img { width: 96px; height: 96px; box-shadow: 0 0 0 4px var(--outline); }
.profile-card h3 { color: var(--gold); text-shadow: 3px 3px 0 var(--gold-ink); }
.profile-card .chip { font-size: 16px; }
.profile-card .lamp { width: 12px; height: 12px; box-shadow: none; }
.profile-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 16px; align-content: start; }
.profile-stats div { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 2px solid var(--stone-hi); }
.profile-stats span { color: var(--muted); }
.profile-side h4 { font-weight: normal; color: var(--gold); margin-bottom: 8px; }
.profile-side .mini { position: relative; height: 120px; margin-bottom: 16px; }
.profile-side .mini canvas { width: 100%; height: 100%; }
.profile .missing { grid-column: 1 / -1; color: var(--muted); }

.ingame-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; margin-bottom: 16px; }
.ingame-head p { color: var(--muted); }
.ingame img { width: 100%; max-width: 972px; margin: 0 auto; }

/* --- Join --------------------------------------------------------------------------------------------- */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; counter-reset: join; }
.steps li { counter-increment: join; padding: 48px 20px 24px; display: flex; flex-direction: column; gap: 8px; }
.steps li::before { content: counter(join); position: absolute; top: -20px; left: 50%; translate: -50% 0; width: 48px; height: 48px;
  display: grid; place-items: center; font-size: 32px; color: #fff; text-shadow: 2px 2px 0 var(--mag-ink); background: var(--mag-lo);
  box-shadow: 0 0 0 2px var(--outline), inset 0 2px 0 var(--mag-mid), inset 0 -4px 0 var(--mag-ink); }
.steps h3 { color: var(--gold); text-shadow: 2px 2px 0 var(--gold-ink); }
.steps p { color: var(--muted); }
.address { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; padding: 8px 12px 10px; cursor: pointer;
  border: 0; font: inherit; background: var(--deep); box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--gold-lo); }
.address code { font-size: 16px; color: var(--gold); }
.address img { width: 32px; height: 32px; }
.address:hover { box-shadow: 0 0 0 2px var(--outline), inset 0 0 0 2px var(--gold); }

/* --- Footer --------------------------------------------------------------------------------------------- */
.foot { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 64px 24px 48px; text-align: center; color: var(--muted);
  background: var(--outline); box-shadow: 0 -2px 0 var(--outline), 0 -4px 0 var(--gold-lo), 0 -6px 0 var(--outline); }
.foot img { width: 128px; height: 128px; }
.foot-links { display: flex; gap: 24px; }

/* --- Smaller screens -------------------------------------------------------------------------------------- */
@media (max-width: 1180px) {
  .feature, .islands-intro, .settle, .render-band { grid-template-columns: 1fr; gap: 40px; }
  .feature.flip > .frame { order: 0; }
  .scene-frame, .settle .map-frame { justify-self: center; max-width: 100%; }
  .scene-frame .scene { width: 100%; max-width: 600px; }
  .path { grid-template-columns: repeat(3, 1fr); }
  .live-grid, .live-lower { grid-template-columns: 1fr; }
  .isle-row { grid-template-columns: repeat(4, 1fr); }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .profile { grid-template-columns: 1fr; }
  .bar-links { display: none; }
  .bar-status { margin-left: auto; }
}
@media (max-width: 760px) {
  h1 { font-size: 32px; line-height: 40px; }
  h2 { font-size: 32px; line-height: 40px; }
  main { gap: 96px; padding: 96px 0; }
  .hero-logo { width: 248px; }
  .hero-copy { margin-top: -40px; }
  .plaque { grid-template-columns: 1fr; text-align: center; }
  .plaque-label, .plaque-live { grid-column: 1; justify-content: center; }
  .plaque-address { font-size: 24px; }
  .isle-hub { width: 86vw; }
  .isle-dunes, .isle-reef, .isle-ember, .isle-void { display: none; }
  .isle-quarry, .isle-timber { width: 30vw; bottom: 280px; }
  .ticker, .tiles, .steps, .trio, .path { grid-template-columns: 1fr; }
  .divider { width: 240px; height: 16px; }
  .shots { grid-template-columns: 1fr 1fr; grid-auto-rows: 140px; }
  .isle-row { grid-template-columns: repeat(2, 1fr); }
  .pieces { grid-template-columns: repeat(3, auto); }
  .settle .map { width: 100%; height: auto; }
  .window { padding: 16px; }
  .bar-logo img { width: 124px; }
  .gens-wall { grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 12px; }
  .gen img.model { width: 48px; height: 56px; }
  .tabs, .spans { flex-wrap: wrap; }
  .chart-head p { flex-basis: 100%; }
  .chart { height: 280px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
