/* The Slayer : Moveset MOD site. Hand-written CSS, no frameworks. */

@font-face {
  font-family: "Monocraft";
  src: url("../fonts/Monocraft.woff2") format("woff2");
  font-display: swap;
}

:root {
  --night: #0b0918;
  --night-2: #110e24;
  --ink: #f1edfb;
  --ink-2: #c3bdd6;
  --ink-3: #8a84a3;
  --line: #2b2446;
  --violet: #b48cff;
  --violet-2: #8a5cf0;
  --violet-3: #4b2c99;
  --yellow: #ffff55;
  --gold: #ffd76b;
  --green: #55ff55;
  --aqua: #55ffff;
  --orange: #ffaa55;
  --red: #ff5555;
  --zolt: #efe8ff;
  --judr: #c9a6ff;
  --voll: #ff9d4d;
  --bh: #d9b2ff;
  --px: 4px;
  --font: "Monocraft", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --mono: "Monocraft", ui-monospace, "Cascadia Mono", Consolas, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--night) url("../img/tile-deepslate.png") repeat;
  background-size: 64px 64px;
  image-rendering: pixelated;
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  font-feature-settings: "liga" 0, "calt" 0;
  overflow-x: hidden;
}

img { image-rendering: pixelated; image-rendering: crisp-edges; }
img[src*="mod-icon"], img[src*="favicon"] { image-rendering: auto; }

a { color: var(--aqua); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--yellow); }

b, strong { font-weight: 400; color: #fff; }

code, kbd { font-family: var(--mono); font-size: 0.88em; }
code {
  background: #1c1733;
  border: 2px solid #2d2650;
  padding: 0 6px;
  color: #e7ddff;
  overflow-wrap: anywhere;
}
kbd {
  display: inline-block;
  min-width: 1.9em;
  padding: 2px 7px 4px;
  text-align: center;
  color: #fff;
  background: #3a3550;
  border: 2px solid #0d0a18;
  box-shadow: inset -2px -3px 0 #221e33, inset 2px 2px 0 #5d5780;
  line-height: 1.2;
  vertical-align: 0.05em;
}

.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: #000; color: #fff; padding: 8px 12px; }
.skip:focus { left: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
@media (max-width: 560px) { .wrap { width: calc(100% - 32px); } }

.c-yellow { color: var(--yellow); }
.c-gray { color: var(--ink-3); }
.c-green { color: var(--green); }
.small { font-size: 0.84em; }
.big { font-size: 1.2em; line-height: 1.6; color: #fff; }

/* ---------- Minecraft-style text shadows ---------- */
.h2, .h3, .tip-title, .spell-name, .dl-title, .book-title, .toast h3, .hero-lede, .mc-btn, .plaque span {
  text-shadow: 3px 3px 0 rgba(0, 0, 0, 0.55);
}

/* ---------- buttons ---------- */
.mc-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 8px 26px 10px;
  font: 18px/1 var(--font);
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  background: #707078 url("../img/tile-button.png") repeat;
  background-size: 48px 48px;
  border: 3px solid #000;
  box-shadow: inset 3px 3px 0 rgba(255, 255, 255, 0.34), inset -3px -5px 0 rgba(0, 0, 0, 0.38);
  overflow: hidden;
  isolation: isolate;
  user-select: none;
}
.mc-btn:hover, .mc-btn:focus-visible {
  color: #ffffa0;
  background-image: url("../img/tile-button-hover.png");
  border-color: #fff;
  outline: none;
}
.mc-btn:active { transform: translateY(2px); box-shadow: inset 3px 3px 0 rgba(0, 0, 0, 0.3), inset -3px -3px 0 rgba(255, 255, 255, 0.12); }
.mc-btn--glint {
  background: #6a43c4 url("../img/tile-amethyst.png") repeat;
  background-size: 48px 48px;
}
.mc-btn--glint:hover, .mc-btn--glint:focus-visible { background-image: url("../img/tile-amethyst.png"); filter: brightness(1.12); }
.mc-btn--glint::after {
  content: "";
  position: absolute;
  inset: -40%;
  z-index: -1;
  background: repeating-linear-gradient(115deg, transparent 0 18px, rgba(228, 190, 255, 0.34) 18px 30px, transparent 30px 58px, rgba(173, 120, 255, 0.28) 58px 66px, transparent 66px 110px);
  mix-blend-mode: screen;
  animation: glint 3.2s steps(24) infinite;
  pointer-events: none;
}
.mc-btn--glint::before { content: ""; position: absolute; inset: 0; z-index: -2; background: inherit; }
@keyframes glint { from { transform: translateX(-110px); } to { transform: translateX(0); } }
.mc-btn--big { min-height: 62px; font-size: 22px; padding-inline: 34px; }
.mc-btn--small { min-height: 38px; font-size: 14px; padding: 4px 14px 6px; border-width: 2px; box-shadow: inset 2px 2px 0 rgba(255,255,255,.3), inset -2px -3px 0 rgba(0,0,0,.38); }

/* ---------- tooltip panels (the dark purple MC tooltip) ---------- */
.tip {
  position: relative;
  background: rgba(16, 0, 18, 0.93);
  padding: 22px 24px;
  border: 3px solid transparent;
  border-image: linear-gradient(180deg, #6a2cff, #2e0f82) 1;
  box-shadow: 0 0 0 3px #10000f, 8px 8px 0 3px rgba(0, 0, 0, 0.45);
}
.tip-title { margin: 0 0 8px; font-size: 1.1em; }

/* ---------- section scaffolding ---------- */
.section { position: relative; padding: 96px 0; }
.section + .section { border-top: 4px solid #07060e; box-shadow: inset 0 4px 0 #26223a; }
.h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 10px;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.05;
  font-weight: 400;
  letter-spacing: 0;
}
.h2 img { width: 40px; height: 40px; flex: none; }
.h3 { margin: 0 0 6px; font-size: 1.3em; font-weight: 400; }
.sub { margin: 0 0 34px; color: var(--ink-2); max-width: 62ch; }

/* ============================== HERO ============================== */
.hero {
  position: relative;
  min-height: max(640px, 100svh);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #0c0a22;
}
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}
.topnav {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(1160px, 100% - 40px);
  margin: 18px auto 0;
}
.topnav-brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-size: 18px; text-shadow: 2px 2px 0 #000; }
.topnav-brand img { width: 32px; height: 32px; }
.topnav ul { display: flex; flex-wrap: wrap; gap: 4px 6px; margin: 0; padding: 0; list-style: none; }
.topnav a:not(.topnav-brand) {
  display: block;
  padding: 4px 12px 6px;
  color: #e9e4f7;
  text-decoration: none;
  text-shadow: 2px 2px 0 #000;
  border: 2px solid transparent;
}
.topnav a:not(.topnav-brand):hover { color: var(--yellow); background: rgba(0, 0, 0, 0.45); border-color: rgba(255, 255, 255, 0.5); }

.hero-inner {
  position: relative;
  z-index: 2;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 24px;
  padding: 28px 0 180px;
}
.hero-copy { max-width: 640px; }
.logo { position: relative; margin: 0; line-height: 0; width: fit-content; }
.logo img { width: min(596px, 88vw); height: auto; filter: drop-shadow(0 8px 0 rgba(0, 0, 0, 0.35)); }
.splash {
  position: absolute;
  right: -34px;
  bottom: 18px;
  font: 19px/1 var(--font);
  color: var(--yellow);
  text-shadow: 3px 3px 0 #3f3f15;
  white-space: nowrap;
  transform: rotate(-17deg);
  transform-origin: center;
  animation: splash 0.55s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes splash { from { transform: rotate(-17deg) scale(1); } to { transform: rotate(-17deg) scale(1.09); } }
.plaque { margin: 18px 0 0; }
.plaque span {
  display: inline-block;
  padding: 6px 22px 8px;
  font-size: 17px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #ffe9a8;
  background: #3a2360;
  border: 3px solid #120a22;
  box-shadow: inset 0 3px 0 #58379a, inset 0 -3px 0 #26163f;
  clip-path: polygon(0 50%, 12px 0, calc(100% - 12px) 0, 100% 50%, calc(100% - 12px) 100%, 12px 100%);
  padding-inline: 30px;
}
.hero-lede { margin: 22px 0 26px; font-size: clamp(17px, 1.9vw, 21px); line-height: 1.6; color: #f4f0ff; max-width: 34ch; }
.hero-lede b { color: var(--yellow); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 22px 0 0; color: #d9d2ef; text-shadow: 2px 2px 0 #000; }
.hero-meta span + span::before { content: "·"; margin-right: 22px; color: var(--ink-3); }
.hint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 4px 10px 4px 4px;
  font: 14px var(--font);
  color: #cfc7ea;
  background: rgba(0, 0, 0, 0.35);
  border: 2px dashed rgba(255, 255, 255, 0.22);
  cursor: pointer;
}
.hint:hover { color: var(--yellow); border-color: var(--yellow); }
.slayer-anchor { align-self: stretch; min-height: 360px; }
.hero-grass { position: absolute; left: 0; right: 0; bottom: 0; height: 8px; background: #07060e; z-index: 2; }

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; padding-bottom: 60px; gap: 0; }
  .hero-copy { max-width: none; }
  .slayer-anchor { min-height: 300px; order: 2; }
  .splash { right: 0; bottom: -6px; font-size: 15px; }
  .topnav ul { display: none; }
}

/* ============================== ABOUT ============================== */
.about-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.85fr); gap: 48px; align-items: start; }
.about-text p { max-width: 62ch; }
.whatsnew { margin-top: 30px; }
.dash { margin: 0; padding: 0; list-style: none; }
.dash li { position: relative; padding-left: 26px; margin: 6px 0; color: var(--ink-2); }
.dash li::before { content: ""; position: absolute; left: 4px; top: 0.62em; width: 10px; height: 10px; background: var(--violet); box-shadow: 2px 2px 0 #2a1860; }

.ai-notice {
  position: sticky;
  top: 24px;
  padding: 24px 26px;
  color: #3b2a12;
  background: #efe0b9 url("../img/tile-parchment.png") repeat;
  background-size: 64px 64px;
  border: 4px solid #2a1a0c;
  box-shadow: inset 4px 4px 0 #fff4d6, inset -4px -4px 0 #c7a868, 10px 10px 0 rgba(0, 0, 0, 0.45);
}
.ai-notice::before {
  content: "";
  position: absolute;
  left: -4px; right: -4px; top: -16px;
  height: 12px;
  background: repeating-linear-gradient(90deg, #ffe36b 0 16px, #1b1426 16px 32px);
  border: 4px solid #1b1426;
  border-bottom: 0;
}
.ai-head { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.ai-head img { width: 48px; height: 48px; }
.ai-head h2 { margin: 0; font-size: 26px; line-height: 1; color: #1e1206; text-shadow: 2px 2px 0 #d8c08a; }
.ai-notice p { margin: 10px 0; }
.ai-notice b { color: #1e1206; }
.ai-notice .c-gray { color: #7a6440; }

@media (max-width: 860px) {
  .about-grid { grid-template-columns: 1fr; gap: 56px; }
  .ai-notice { position: relative; top: 0; }
}

/* ============================== SPELLS ============================== */
.spells { background: rgba(6, 4, 14, 0.55); }
.spell-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #07060f;
  border: 4px solid #000;
  box-shadow: 0 0 0 4px #3a3450, 0 0 0 8px #000, 12px 12px 0 8px rgba(0, 0, 0, 0.4);
}
.stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; }
.stage-tag {
  position: absolute; left: 12px; top: 10px;
  font: 16px var(--font); color: #fff; text-shadow: 2px 2px 0 #000;
  pointer-events: none;
}
.sound-toggle {
  position: absolute; right: 10px; top: 10px;
  font: 13px var(--font); color: #fff;
  padding: 3px 10px 5px;
  background: rgba(0, 0, 0, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.35);
  cursor: pointer;
}
.sound-toggle:hover, .sound-toggle[aria-pressed="true"] { color: var(--yellow); border-color: var(--yellow); }

.hotbar {
  display: flex;
  justify-content: center;
  gap: 0;
  width: fit-content;
  margin: 34px auto 0;
  padding: 4px;
  background: rgba(0, 0, 0, 0.6);
  border: 3px solid #000;
  box-shadow: inset 0 0 0 3px #4d4d58;
}
.slot {
  position: relative;
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  padding: 0;
  margin: 0;
  background: rgba(139, 139, 139, 0.18);
  border: 3px solid #1d1d24;
  box-shadow: inset 3px 3px 0 #2f2f3a, inset -3px -3px 0 #6b6b78;
  cursor: pointer;
}
.slot img { width: 56px; height: 56px; position: relative; z-index: 1; }
.slot kbd { position: absolute; bottom: -30px; left: 50%; transform: translateX(-50%); font-size: 14px; }
.slot:hover { background: rgba(255, 255, 255, 0.14); }
.slot.is-active { z-index: 2; outline: 5px solid #f4f4f4; outline-offset: 2px; box-shadow: 0 0 0 9px #000, inset 3px 3px 0 #2f2f3a, inset -3px -3px 0 #6b6b78; }
.slot.is-active kbd { color: var(--yellow); }
.slot .cd {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: conic-gradient(rgba(10, 8, 20, 0.72) var(--cd, 0deg), transparent 0);
}

.spell-info { min-height: 100%; }
.spell-card[hidden] { display: none; }
.spell-name { margin: 0 0 12px; font-size: 30px; line-height: 1.1; display: flex; align-items: center; gap: 12px; }
.spell-name kbd { font-size: 16px; }
.c-zolt { color: var(--zolt); }
.c-judr { color: var(--judr); }
.c-voll { color: var(--voll); }
.c-bh { color: var(--bh); }
.spell-card p { color: var(--ink-2); margin: 0 0 12px; }
.stats { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; }
.stats li { font: 13px/1.4 var(--mono); color: #fff; padding: 5px 10px; background: #231b3f; border: 2px solid #3e2f73; }
.spell-foot { margin: 22px 0 0; padding-top: 14px; border-top: 2px dashed #3a2a66; }

@media (max-width: 900px) {
  .spell-layout { grid-template-columns: 1fr; }
  .slot { width: 68px; height: 68px; }
  .slot img { width: 48px; height: 48px; }
}

/* ============================== FEATURES (advancement toasts) ============================== */
.features { overflow-x: clip; }
.toasts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin: 0; padding: 0; list-style: none; }
.toast {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 18px 18px;
  background: #1f1c29;
  border: 3px solid #07060c;
  box-shadow: inset 3px 3px 0 #4a4560, inset -3px -3px 0 #121019, 6px 6px 0 rgba(0, 0, 0, 0.4);
  transition: transform 0.35s steps(5), opacity 0.35s steps(5);
}
.toast img { width: 48px; height: 48px; flex: none; margin-top: 2px; }
.toast h3 { margin: 0 0 6px; font-size: 18px; font-weight: 400; color: var(--yellow); line-height: 1.2; }
.toast p { margin: 0; font-size: 14.5px; color: #e6e1f4; line-height: 1.6; }
.js .toast.pre { transform: translateX(40px); opacity: 0; }
@media (max-width: 980px) { .toasts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .toasts { grid-template-columns: 1fr; } }

/* ============================== CONTROLS ============================== */
.controls-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; }
.keys { margin: 0; display: grid; gap: 10px; }
.keys > div { display: grid; grid-template-columns: 210px 1fr; gap: 16px; align-items: center; padding: 10px 14px; background: rgba(0, 0, 0, 0.35); border-left: 4px solid var(--violet-3); }
.keys dt { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; color: var(--ink-3); }
.keys dd { margin: 0; color: var(--ink-2); }
.chat { margin: 0 0 16px; padding: 12px 14px; background: rgba(0, 0, 0, 0.5); }
.chat p { margin: 0; padding: 8px 0; display: flex; flex-direction: column; gap: 2px; }
.chat p + p { border-top: 2px solid rgba(255, 255, 255, 0.06); }
.chat code { background: none; border: 0; padding: 0; color: #fff; font-size: 15px; text-shadow: 2px 2px 0 #3f3f3f; }
.chat span { color: var(--ink-3); font-size: 14px; }
@media (max-width: 860px) {
  .controls-grid { grid-template-columns: 1fr; gap: 48px; }
  .keys > div { grid-template-columns: 1fr; gap: 6px; }
}

/* ============================== GUI (light gray inventory screens) ============================== */
.gui {
  background: #c6c6c6 url("../img/tile-gui.png") repeat;
  background-size: 64px 64px;
  color: #3f3f3f;
  padding: 14px 16px 18px;
  border: 3px solid #000;
  box-shadow: inset 4px 4px 0 #fff, inset -4px -4px 0 #555, 10px 10px 0 rgba(0, 0, 0, 0.45);
  clip-path: polygon(3px 0, calc(100% - 3px) 0, 100% 3px, 100% calc(100% - 3px), calc(100% - 3px) 100%, 3px 100%, 0 calc(100% - 3px), 0 3px);
}
.gui-title { margin: 0 0 10px; font-size: 15px; color: #404040; overflow-wrap: anywhere; }
.islot {
  position: relative;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  font: inherit;
  background: #8b8b8b;
  border: 0;
  box-shadow: inset 3px 3px 0 #373737, inset -3px -3px 0 #fff;
}
button.islot, .islot[data-tip] { cursor: pointer; }
.islot img { width: 36px; height: 36px; }
.islot[data-tip]:hover::after, .islot[data-tip]:focus-visible::after, .islot.is-picked::after {
  content: ""; position: absolute; inset: 3px; background: rgba(255, 255, 255, 0.45);
}
.islot:focus-visible { outline-offset: 0; }
.count {
  position: absolute; right: 2px; bottom: 0;
  font: 14px/1 var(--mono);
  color: #fff;
  text-shadow: 2px 2px 0 #3f3f3f;
  z-index: 1;
}

.install-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 64px; align-items: center; }
.craft-wrap { display: flex; justify-content: center; }
.craft-body { display: flex; align-items: center; gap: 22px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 52px); gap: 0; }
.craft-arrow {
  width: 44px; height: 30px;
  background: #8b8b8b;
  clip-path: polygon(0 35%, 55% 35%, 55% 0, 100% 50%, 55% 100%, 55% 65%, 0 65%);
}
.islot--out { width: 72px; height: 72px; }
.islot--out img { width: 48px; height: 48px; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { position: relative; counter-increment: s; padding: 10px 0 10px 56px; color: var(--ink-2); }
.steps li::before {
  content: counter(s);
  position: absolute; left: 0; top: 8px;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  font: 18px var(--font); color: #fff;
  background: #3a2a66;
  border: 3px solid #000;
  box-shadow: inset 2px 2px 0 #6b52b8, inset -2px -2px 0 #1e1540;
  text-shadow: 2px 2px 0 #000;
}
@media (max-width: 860px) {
  .install-grid { grid-template-columns: 1fr; gap: 40px; }
  .craft-wrap { order: 2; }
}
@media (max-width: 420px) {
  .grid3 { grid-template-columns: repeat(3, 44px); }
  .grid3 .islot { width: 44px; height: 44px; }
  .grid3 .islot img { width: 30px; height: 30px; }
  .craft-body { gap: 12px; }
}

/* ============================== SAFETY ============================== */
.safety { background: rgba(4, 12, 8, 0.35); }
.pillars { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; margin-bottom: 64px; }
.pillar { display: flex; flex-direction: column; }
.pillar p:not(.tip-title) { margin: 0 0 14px; color: var(--ink-2); font-size: 15px; }
.pillar .link { margin-top: auto; font-size: 15px; }
.safety-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 510px); gap: 56px; align-items: start; }
.checks { margin: 18px 0 0; padding: 0; list-style: none; }
.checks li { position: relative; padding: 10px 0 10px 44px; color: var(--ink-2); border-bottom: 2px solid rgba(255, 255, 255, 0.05); }
.checks li::before {
  content: "";
  position: absolute; left: 2px; top: 12px;
  width: 26px; height: 26px;
  background: #1f7a2a;
  border: 3px solid #000;
  box-shadow: inset 2px 2px 0 #55ff55, inset -2px -2px 0 #0f4515;
}
.checks li::after {
  content: "";
  position: absolute; left: 10px; top: 16px;
  width: 7px; height: 12px;
  border: solid #fff; border-width: 0 4px 4px 0;
  transform: rotate(40deg);
}
.chest { width: fit-content; margin-top: 18px; }
.chest-grid { display: grid; grid-template-columns: repeat(9, 52px); }
.chest-readout { margin: 12px 0 0; font-size: 14px; color: #404040; max-width: 468px; min-height: 3em; }
.chest-readout b { color: #202020; }
@media (max-width: 1100px) { .pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); } .safety-grid { grid-template-columns: 1fr; } }
@media (max-width: 620px) {
  .pillars { grid-template-columns: 1fr; }
  .chest { width: 100%; }
  .chest-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .chest-grid .islot { width: 100%; aspect-ratio: 1; height: auto; }
}

/* ============================== DOWNLOAD ============================== */
.download { background: radial-gradient(ellipse at 50% 0%, rgba(106, 44, 255, 0.18), transparent 60%); }
.dl { padding: 34px 36px; }
.dl-head { display: flex; gap: 22px; align-items: center; }
.dl-icon { width: 80px; height: 80px; flex: none; }
.dl-kicker { margin: 0; letter-spacing: 1px; }
.dl-title { margin: 2px 0 2px; font-size: clamp(28px, 4vw, 42px); line-height: 1.1; }
.dl-title span { color: var(--violet); }
.dl-head p:last-child { margin: 0; }
.dl-actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 28px 0 30px; }
.verify { border-top: 2px dashed #3a2a66; padding-top: 22px; }
.verify-label { margin: 0 0 8px; color: var(--ink-2); font-size: 15px; }
.hash-row, .cmd { display: flex; gap: 10px; align-items: stretch; margin-bottom: 18px; }
.hash, .cmd code {
  flex: 1;
  display: flex; align-items: center;
  font-size: 14px;
  padding: 8px 12px;
  background: #07050e;
  border: 2px solid #2d2650;
  color: var(--green);
  overflow-wrap: anywhere;
  word-break: break-all;
}
.cmd code { color: #fff; }
.cmd[hidden] { display: none; }
.tabs { display: flex; flex-wrap: wrap; gap: 0; margin-bottom: 0; }
.tab {
  font: 14px var(--font); color: var(--ink-3);
  padding: 6px 14px 8px;
  background: #15102a;
  border: 2px solid #2d2650; border-bottom: 0;
  cursor: pointer;
  margin-right: -2px;
}
.tab.is-active { color: #fff; background: #07050e; position: relative; top: 2px; }
.tab:hover { color: var(--yellow); }
@media (max-width: 560px) {
  .dl { padding: 24px 18px; }
  .dl-head { flex-direction: column; align-items: flex-start; }
  .hash-row, .cmd { flex-direction: column; }
}

/* ============================== CHANGELOG (book & quill) ============================== */
.book {
  background: #3a2716;
  border: 4px solid #140c05;
  box-shadow: inset 4px 4px 0 #5a3e24, inset -4px -4px 0 #24170b, 10px 10px 0 rgba(0, 0, 0, 0.45);
}
.book > summary {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 18px;
  align-items: center;
  padding: 20px 24px;
  cursor: pointer;
  list-style: none;
}
.book > summary::-webkit-details-marker { display: none; }
.book > summary img { grid-row: 1 / 3; width: 56px; height: 56px; }
.book-title { font-size: 26px; color: #ffe9b8; line-height: 1.1; }
.book-sub { grid-column: 2; color: #cdb28a; font-size: 14px; }
.book-chev {
  grid-column: 3; grid-row: 1 / 3;
  width: 34px; height: 34px;
  background: #ffe9b8;
  clip-path: polygon(20% 30%, 50% 60%, 80% 30%, 95% 45%, 50% 88%, 5% 45%);
  transition: transform 0.2s steps(3);
}
.book[open] .book-chev { transform: rotate(180deg); }
.book > summary:hover .book-title { color: var(--yellow); }
.book-pages { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 0 14px 14px; }
.page {
  padding: 26px 28px 30px;
  color: #3b2a12;
  background: #efe0b9 url("../img/tile-parchment.png") repeat;
  background-size: 64px 64px;
  box-shadow: inset 3px 3px 0 #fff4d6, inset -3px -3px 0 #c7a868;
  font-size: 15px;
}
.page h3 { margin: 0 0 4px; font-size: 28px; color: #1e1206; display: flex; align-items: center; gap: 12px; }
.page .tag { font: 13px var(--mono); color: #fff; background: #3a7a2a; padding: 4px 8px; border: 2px solid #1b3d12; }
.page-lede { margin: 0 0 12px; font-style: italic; color: #6b5330; }
.page h4 { margin: 20px 0 6px; font-size: 17px; font-weight: 400; color: #5a2d82; border-bottom: 2px dashed #c7a868; padding-bottom: 2px; }
.page ul { margin: 0; padding-left: 20px; }
.page li { margin: 5px 0; }
.page li::marker { color: #9a6a1c; }
.page b { color: #1e1206; }
.page code { background: rgba(255, 255, 255, 0.45); border-color: #c7a868; color: #3b2a12; }
@media (max-width: 860px) { .book-pages { grid-template-columns: 1fr; } .book > summary { padding: 16px; } .book-title { font-size: 24px; } }

/* ============================== FOOTER ============================== */
.footer {
  padding: 56px 0 64px;
  background: #1a1a1e url("../img/tile-bedrock.png") repeat;
  background-size: 64px 64px;
  border-top: 4px solid #000;
  color: #d8d8e0;
  text-shadow: 2px 2px 0 #000;
  font-size: 14px;
}
.footer-inner p { margin: 6px 0; }
.footer .c-gray { color: #a3a3ae; }
.footer-bedrock { font-size: 22px; color: var(--yellow) !important; margin-bottom: 14px !important; }

/* ============================== floating MC tooltip ============================== */
.mc-tooltip {
  position: fixed;
  z-index: 60;
  max-width: 320px;
  padding: 8px 10px 9px;
  font-size: 14px;
  line-height: 1.35;
  color: #fff;
  background: rgba(16, 0, 16, 0.95);
  border: 2px solid transparent;
  border-image: linear-gradient(180deg, #5000ff, #28007f) 1;
  box-shadow: 0 0 0 2px #100010;
  pointer-events: none;
  text-shadow: 2px 2px 0 #3f3f3f;
}
.mc-tooltip b { display: block; color: #fff; }
.mc-tooltip span { color: #aaa; }

@media (prefers-reduced-motion: reduce) {
  .splash, .mc-btn--glint::after { animation: none; }
  .toast { transition: none; }
}
