/* Northwyn website. Palette and pieces follow the game's Northwyn interface (docs/UIStyle.md): thin gilded frames (a dark
   outline, a gold, a bronze and a dark hairline) round navy, slate slots, a crimson primary button with a gold rim. The pieces
   in img/ui are the game's v3_* art at 2x (Tools/WebsiteBuild/ui_pieces.cjs); bump their ?v= when they change. */

@font-face { font-family: "Jacquard"; src: url("../fonts/Jacquard24-Regular.woff2") format("woff2"), url("../fonts/Jacquard24-Regular.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: "Jersey20"; src: url("../fonts/Jersey20-Regular.woff2") format("woff2"), url("../fonts/Jersey20-Regular.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: "Jersey15"; src: url("../fonts/Jersey15-Regular.woff2") format("woff2"), url("../fonts/Jersey15-Regular.ttf") format("truetype"); font-display: swap; }

:root {
  --bg: #0a0d16;
  --bg-2: #0d111e;
  --navy: #0d111e;
  --navy-2: #141827;
  --stone: #4a505e;
  --gold: #e4ab52;
  --gold-hi: #f1be59;
  --gold-lo: #a16d3f;
  --bronze: #6a453c;
  --outline: #09060b;
  --crimson: #901f30;
  --cream: #efe4cc;
  --text: #d9d2c4;
  --muted: #9b9588;
  --line: rgba(228, 171, 82, 0.25);
  /* The game's thin gilded frame on any box: outline, gold, bronze, outline (v3_ui_frame). */
  --gilded: 0 0 0 1px var(--outline), inset 0 0 0 1px var(--bronze), inset 0 0 0 2px var(--outline);
  --font-title: "Jacquard", "Times New Roman", serif;
  --font-body: "Jersey20", "Trebuchet MS", sans-serif;
  --font-small: "Jersey15", "Trebuchet MS", sans-serif;
  --wrap: 1200px;
  --nav-h: 64px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 20px;
  line-height: 1.35;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold-hi); text-decoration: none; }
a:hover { color: #fff; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; color: var(--cream); }
h2 { font-family: var(--font-title); font-size: 48px; line-height: 1.05; color: var(--gold-hi); text-shadow: 0 3px 0 #000, 0 0 24px rgba(232, 184, 92, 0.25); }
h3 { font-family: var(--font-body); font-size: 30px; line-height: 1.1; }
h4 { font-family: var(--font-body); font-size: 20px; color: var(--gold); letter-spacing: 0.02em; }
p { margin: 0 0 0.8em; }
.muted { color: var(--muted); }
.pixel { image-rendering: pixelated; image-rendering: crisp-edges; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; }

/* ---------- Skin pieces ---------- */
.frame {
  position: relative;
  border-style: solid;
  border-width: 12px;
  border-image: url("../img/ui/frame.png?v=3") 12 fill / 12px / 0 stretch;
  background-clip: padding-box;
  padding: 14px;
  image-rendering: pixelated;
}
/* The window's ruby gem on the middle of its top edge, as in the game. */
.frame::after {
  content: ""; position: absolute; left: 50%; top: -27px; width: 30px; height: 30px; margin-left: -15px; z-index: 3;
  background: url("../img/ui/gem.png?v=3") 0 0 / 100% 100% no-repeat; image-rendering: pixelated; pointer-events: none;
}
.btn {
  --h: 52px;
  display: inline-flex; align-items: center; justify-content: center;
  min-height: var(--h); padding: 0 30px;
  font-family: var(--font-body); font-size: 22px; color: var(--cream);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.7);
  border-style: solid; border-width: 8px;
  border-image: url("../img/ui/button.png?v=3") 8 fill / 8px stretch;
  image-rendering: pixelated;
  cursor: pointer; white-space: nowrap;
  transition: transform 0.12s ease, filter 0.12s ease;
}
.btn:hover { border-image-source: url("../img/ui/button_hover.png?v=3"); color: #fff; transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn--primary { border-width: 10px; border-image: url("../img/ui/button_primary.png?v=3") 10 fill / 10px stretch; color: #fff3dc; }
.btn--primary:hover { border-image-source: url("../img/ui/button_primary_hover.png?v=3"); }
.btn--small { --h: 40px; font-size: 18px; padding: 0 10px; }
.btn--big { --h: 64px; font-size: 26px; padding: 0 48px; }
.divider { margin: 14px auto 18px; width: 322px; max-width: 80%; height: auto; }
.badge {
  display: inline-block; padding: 2px 12px; margin-bottom: 8px;
  font-family: var(--font-small); font-size: 15px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--bg); background: var(--gold); box-shadow: 0 0 0 1px var(--outline), 0 2px 0 var(--gold-lo);
}
.eyebrow { font-family: var(--font-small); font-size: 15px; letter-spacing: 0.25em; text-transform: uppercase; color: var(--gold); margin: 0 0 6px; }

/* ---------- Navigation ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 24px;
  transition: background 0.25s ease, box-shadow 0.25s ease;
}
.nav.is-solid { background: rgba(11, 14, 22, 0.94); box-shadow: 0 1px 0 var(--line), 0 6px 20px rgba(0, 0, 0, 0.4); backdrop-filter: blur(6px); }
.nav__brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-title); font-size: 30px; color: var(--gold-hi); text-shadow: 0 2px 0 #000; }
.nav__brand img { width: auto; height: 34px; }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a:not(.btn) { color: var(--cream); font-size: 20px; text-shadow: 0 2px 0 #000; position: relative; }
.nav__links a:not(.btn)::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--gold); transform: scaleX(0); transition: transform 0.2s ease; }
.nav__links a:not(.btn):hover::after { transform: scaleX(1); }
.nav__toggle { display: none; background: none; border: 0; width: 44px; height: 44px; padding: 10px; cursor: pointer; }
.nav__toggle span { display: block; height: 3px; margin: 5px 0; background: var(--gold-hi); box-shadow: 0 1px 0 #000; transition: transform 0.2s ease, opacity 0.2s ease; }

/* ---------- Hero ---------- */
.hero { position: relative; height: 100vh; height: 100svh; min-height: 640px; overflow: hidden; background: #2a1c34; }
.hero__stage { position: absolute; inset: 0; overflow: hidden; }
.hero__stage canvas, .hero__fallback {
  position: absolute; left: 50%; top: 50%;
  width: 1920px; height: 1080px; transform: translate(-50%, -50%);
  image-rendering: pixelated; image-rendering: crisp-edges;
}
.hero__shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(11, 14, 22, 0.55) 0%, rgba(11, 14, 22, 0) 16%),
    radial-gradient(ellipse 60% 70% at 72% 52%, rgba(11, 14, 22, 0.55), rgba(11, 14, 22, 0) 70%),
    linear-gradient(to bottom, rgba(11, 14, 22, 0) 70%, var(--bg) 100%);
}
.hero__content {
  position: absolute; z-index: 2; right: max(4vw, 16px); top: 50%; transform: translateY(-46%);
  width: min(600px, 92vw); text-align: center;
}
.hero__wordmark { width: 512px; max-width: 100%; margin: 0 auto; height: auto; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.7)) drop-shadow(0 0 30px rgba(255, 190, 90, 0.3)); animation: rise 1.1s cubic-bezier(.2, .8, .2, 1) both; }
.hero__tagline { font-family: var(--font-body); font-size: 32px; letter-spacing: 0.04em; color: var(--gold-hi); margin: 10px 0 10px; text-shadow: 0 3px 0 #000; animation: rise 1.1s 0.15s cubic-bezier(.2, .8, .2, 1) both; }
.hero__lead { font-size: 22px; color: var(--cream); text-shadow: 0 2px 0 #000, 0 0 12px #000; margin: 0 auto 26px; max-width: 520px; animation: rise 1.1s 0.3s cubic-bezier(.2, .8, .2, 1) both; }
.hero__cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; animation: rise 1.1s 0.45s cubic-bezier(.2, .8, .2, 1) both; }
.hero__note { margin-top: 18px; font-family: var(--font-small); font-size: 15px; color: var(--cream); opacity: 0.8; text-shadow: 0 2px 0 #000; animation: rise 1.1s 0.6s cubic-bezier(.2, .8, .2, 1) both; }
.hero__scroll { position: absolute; z-index: 2; left: 50%; bottom: 22px; transform: translateX(-50%); width: 30px; height: 46px; border: 3px solid var(--gold); border-radius: 15px; }
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; background: var(--gold-hi); animation: wheel 1.8s infinite; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes wheel { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(16px); } }


/* ---------- Sections ---------- */
.section { padding: 96px 0; position: relative; }
.section--dark { background: var(--bg-2); }
.section--dark::before, .section--dark::after { content: ""; position: absolute; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--line), transparent); }
.section--dark::before { top: 0; } .section--dark::after { bottom: 0; }
.section__head { text-align: center; max-width: 780px; margin: 0 auto 46px; }
.section__lead { font-size: 22px; color: var(--text); margin: 0; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.2, .8, .2, 1); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Showcase ---------- */
.showcase__frame { position: relative; }
.showcase__slides { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #000; }
.slide { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 0.9s ease; }
.slide.is-active { opacity: 1; }
.slide img { width: 100%; height: 100%; object-fit: cover; }
.slide.is-active img { animation: kenburns 9s ease-out both; }
@keyframes kenburns { from { transform: scale(1.06); } to { transform: scale(1); } }
.slide figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 22px 16px;
  background: linear-gradient(transparent, rgba(5, 7, 12, 0.85));
  font-size: 22px; color: var(--cream);
}
.slide figcaption b { font-family: var(--font-title); font-size: 34px; font-weight: 400; color: var(--gold-hi); margin-right: 10px; }
.showcase__nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 46px; height: 64px; border: 0; cursor: pointer;
  background: rgba(11, 14, 22, 0.75); color: var(--gold-hi); font-size: 40px; line-height: 1;
  box-shadow: inset 0 0 0 2px var(--gold-lo);
}
.showcase__nav:hover { background: rgba(11, 14, 22, 0.95); color: #fff; }
.showcase__nav--prev { left: 0; } .showcase__nav--next { right: 0; }
.showcase__dots { display: flex; justify-content: center; gap: 10px; margin-top: 16px; }
.showcase__dots button { width: 14px; height: 14px; padding: 0; border: 2px solid var(--gold-lo); background: transparent; transform: rotate(45deg); cursor: pointer; }
.showcase__dots button[aria-selected="true"] { background: var(--gold); border-color: var(--gold-hi); }

/* ---------- Regions ---------- */
.regions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.region { position: relative; background: var(--navy); border: 1px solid var(--gold); box-shadow: var(--gilded), 0 18px 40px rgba(0, 0, 0, 0.45); overflow: hidden; }
.region__img { aspect-ratio: 16 / 9; overflow: hidden; }
.region__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s cubic-bezier(.2, .8, .2, 1); }
.region:hover .region__img img { transform: scale(1.05); }
.region__body { padding: 18px 22px 22px; border-top: 1px solid var(--gold); box-shadow: inset 0 1px 0 var(--bronze); }
.region__body h3 { font-family: var(--font-title); font-size: 40px; color: var(--gold-hi); margin-bottom: 6px; }
.region__body p { margin: 0; }

/* ---------- Classes ---------- */
.classes__tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 18px; }
.class-tab {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 10px 6px; font-family: var(--font-body); font-size: 24px; color: var(--muted);
  background: var(--navy); border: 1px solid var(--stone); box-shadow: 0 0 0 1px var(--outline); cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.class-tab img { width: 32px; height: 32px; filter: grayscale(0.7) brightness(0.8); transition: filter 0.2s ease; }
.class-tab:hover { color: var(--cream); }
.class-tab.is-active { color: var(--gold-hi); border-color: var(--gold); background: var(--navy-2); box-shadow: 0 0 0 1px var(--outline), inset 0 -3px 0 var(--gold); }
.class-tab.is-active img, .class-tab:hover img { filter: none; }
.class-panel { display: grid; grid-template-columns: 320px 1fr; gap: 34px; padding: 6px; }
.class-panel[hidden] { display: none; }
.class-panel.is-active { animation: fadein 0.45s ease both; }
@keyframes fadein { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.class-panel__hero { text-align: center; }
.class-panel__pedestal {
  height: 260px; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 26px;
  background: radial-gradient(ellipse 50% 12% at 50% 88%, rgba(0, 0, 0, 0.55), transparent 70%), radial-gradient(circle at 50% 55%, rgba(232, 184, 92, 0.18), transparent 60%);
}
.class-panel__pedestal .sprite { width: auto; height: 224px; animation: bob 3.2s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.class-panel__hero h3 { font-family: var(--font-title); font-size: 48px; color: var(--gold-hi); }
.class-panel__role { color: var(--muted); }
.attrs { margin: 14px 0 0; display: grid; gap: 6px; }
.attrs div { display: grid; grid-template-columns: 46px 1fr; align-items: center; gap: 10px; }
.attrs dt { font-family: var(--font-small); font-size: 15px; color: var(--gold); text-align: left; }
.attrs dd { margin: 0; display: flex; align-items: center; gap: 8px; font-family: var(--font-small); font-size: 15px; }
.attrs i { display: block; height: 10px; width: calc(var(--v) / 30 * 100%); max-width: 82%; background: linear-gradient(var(--gold-hi), var(--gold) 50%, var(--gold-lo)); box-shadow: 0 0 0 2px #05070c; }
.class-panel__info > p { font-size: 22px; }
.class-panel__info h4 { margin: 18px 0 10px; }
.skills { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px 18px; }
.skills li { display: flex; align-items: center; gap: 10px; font-size: 20px; color: var(--cream); }
.skills img {
  box-sizing: content-box; width: 64px; height: 64px; padding: 2px; flex: none;
  border-style: solid; border-width: 12px; border-image: url("../img/ui/slot.png?v=3") 12 fill / 12px stretch; image-rendering: pixelated;
}
.skills--small li { font-size: 18px; }
.skills--small img { width: 32px; height: 32px; padding: 3px; }
.specs { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 22px; }
.spec { padding: 16px 18px 18px; background: rgba(13, 17, 30, 0.7); border: 1px solid var(--gold); box-shadow: var(--gilded); }
.spec h4 { margin: 0 0 6px; font-family: var(--font-title); font-size: 30px; color: var(--gold-hi); }
.spec p { color: var(--text); }
.spec .skills { flex-direction: column; gap: 8px; }

/* ---------- Combat ---------- */
.combat { display: grid; grid-template-columns: 1.5fr 1fr; gap: 34px; align-items: center; }
.combat__main { margin: 0; }
.combat__main img { cursor: zoom-in; }
.combat__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.combat__list li { padding-left: 34px; position: relative; font-size: 21px; }
.combat__list li::before { content: ""; position: absolute; left: 4px; top: 7px; width: 12px; height: 12px; background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 0 3px #05070c, 0 0 12px rgba(232, 184, 92, 0.5); }
.combat__list b { color: var(--gold-hi); font-weight: 400; }
.fx-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
.fx, .weather, .gallery__item { position: relative; margin: 0; overflow: hidden; border: 1px solid var(--gold); box-shadow: var(--gilded); background: #000; }
.fx img, .weather img, .gallery__item img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; cursor: zoom-in; transition: transform 0.6s cubic-bezier(.2, .8, .2, 1); }
.fx img { object-position: 50% 55%; transform: scale(1.6); }
.fx:hover img { transform: scale(1.75); }
.weather:hover img, .gallery__item:hover img { transform: scale(1.05); }
.fx figcaption, .weather figcaption, .gallery__item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 14px 10px; pointer-events: none;
  background: linear-gradient(transparent, rgba(5, 7, 12, 0.85)); font-size: 20px; color: var(--cream);
}

/* PvP + reputation */
.pvp { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; margin-top: 70px; padding: 30px; background: linear-gradient(135deg, rgba(163, 38, 55, 0.18), rgba(18, 22, 33, 0.6)); border: 1px solid rgba(163, 38, 55, 0.45); }
.pvp h3 { font-family: var(--font-body); font-size: 36px; color: var(--gold-hi); margin-bottom: 12px; }
.rep { position: relative; padding-top: 30px; }
.rep__bar { display: flex; height: 44px; box-shadow: 0 0 0 3px #05070c, 0 0 0 5px var(--gold-lo); }
.rep__band { width: var(--w); display: flex; align-items: center; justify-content: center; font-family: var(--font-small); font-size: 15px; color: #fff; text-shadow: 0 1px 0 #000; overflow: hidden; white-space: nowrap; }
.rep__band--murderer { background: #8c1a22; }
.rep__band--outlaw { background: #c4452f; }
.rep__band--warning { background: #c99a3a; }
.rep__band--commoner { background: #d8d2c2; color: #1a1a1a; text-shadow: none; }
.rep__band--hero { background: #3d8fd6; }
.rep__scale { display: flex; justify-content: space-between; margin-top: 10px; font-family: var(--font-small); font-size: 15px; color: var(--muted); }
.rep__scale span:nth-child(2) { margin-left: 4%; } .rep__scale span:nth-child(5) { margin-right: 10%; }
.rep__marker { position: absolute; top: 0; left: 75%; transform: translateX(-50%); transition: left 2.4s cubic-bezier(.4, 0, .2, 1); }
.rep__marker span { display: block; width: 0; height: 0; border-left: 10px solid transparent; border-right: 10px solid transparent; border-top: 16px solid var(--gold-hi); filter: drop-shadow(0 2px 0 #000); }

/* ---------- Atmosphere ---------- */
.atmos { display: grid; grid-template-columns: 2fr 1fr; gap: 22px; }
.compare { position: relative; overflow: hidden; user-select: none; touch-action: pan-y; }
.compare > .compare__img, .compare__top .compare__img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.compare__top { position: absolute; inset: 0; clip-path: inset(0 50% 0 0); }
.compare__handle { position: absolute; top: 0; bottom: 0; left: 50%; width: 4px; margin-left: -2px; background: var(--gold-hi); box-shadow: 0 0 0 2px #05070c; cursor: ew-resize; }
.compare__handle span { position: absolute; top: 50%; left: 50%; width: 34px; height: 34px; transform: translate(-50%, -50%) rotate(45deg); background: var(--crimson); border: 3px solid var(--gold-hi); box-shadow: 0 0 0 2px #05070c, 0 0 18px rgba(255, 220, 143, 0.5); }
.compare__label { position: absolute; top: 12px; padding: 2px 12px; font-family: var(--font-small); font-size: 15px; letter-spacing: 0.15em; text-transform: uppercase; background: rgba(5, 7, 12, 0.75); color: var(--gold-hi); pointer-events: none; }
.compare__label--left { left: 12px; } .compare__label--right { right: 12px; }
.atmos__side { display: grid; gap: 22px; align-content: start; }

/* ---------- Bestiary ---------- */
.beasts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.beast { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 18px 10px 16px; background: var(--navy); border: 1px solid var(--gold-lo); box-shadow: var(--gilded); transition: transform 0.25s ease, border-color 0.25s ease; }
.beast:hover { transform: translateY(-4px); border-color: var(--gold-hi); }
/* Bosses: the game's boss plate, wine with a ruby rim. */
.beast--boss { border-color: #b3343a; box-shadow: 0 0 0 1px var(--outline), inset 0 0 0 1px #721427, inset 0 0 0 2px var(--outline); background: linear-gradient(rgba(114, 20, 39, 0.35), var(--navy)); }
.beast__art { width: 100%; height: 150px; display: flex; align-items: flex-end; justify-content: center; margin-bottom: 10px; }
.beast__art .sprite { width: auto; height: 108px; }
.beast b { font-weight: 400; font-size: 22px; color: var(--cream); }
.beast span { font-family: var(--font-small); font-size: 15px; color: var(--gold); }
.beast--boss span { color: #ff8a7a; }

/* ---------- Features ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.feature { padding: 4px; text-align: left; transition: transform 0.25s ease; }
.feature:hover { transform: translateY(-4px); }
.feature__icon { width: 64px; height: 64px; margin-bottom: 10px; }
.feature h3 { font-size: 26px; color: var(--gold-hi); margin-bottom: 6px; }
.feature p { margin: 0; font-size: 19px; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.gallery__item--wide { grid-column: span 2; grid-row: span 2; }
.gallery__item--wide img { height: 100%; aspect-ratio: auto; }

/* ---------- Play ---------- */
.play { position: relative; padding: 110px 0; overflow: hidden; }
.play__bg { position: absolute; inset: 0; background: url("../img/hero-bg.png") center 30% / cover no-repeat; image-rendering: pixelated; filter: brightness(0.45) saturate(1.1); }
.play__bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(var(--bg-2), rgba(11, 14, 22, 0.2) 30%, rgba(11, 14, 22, 0.2) 70%, var(--bg)); }
.play__inner { position: relative; display: flex; justify-content: center; }
.play__card { max-width: 720px; text-align: center; padding: 10px 20px; }
.play__crest { width: 124px; margin: -6px auto 8px; animation: bob 3.6s ease-in-out infinite; }
.play__card h2 { margin-bottom: 22px; }
.steps { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 14px; text-align: left; }
.steps li { display: flex; gap: 16px; align-items: flex-start; }
.steps li > span { position: relative; flex: none; width: 44px; height: 44px; display: grid; place-items: center; font-family: var(--font-body); font-size: 26px; color: var(--bg); margin-top: 2px; }
.steps li > span::before { content: ""; position: absolute; inset: 7px; z-index: -1; background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 0 2px #05070c, 0 0 0 4px var(--gold-lo); }
.steps li { isolation: isolate; }
.steps b { display: block; color: var(--gold-hi); font-weight: 400; font-size: 22px; }
.play__note { margin-top: 16px; font-size: 18px; }

/* ---------- Footer ---------- */
.footer { padding: 40px 0 50px; border-top: 1px solid var(--line); text-align: center; }
.footer__brand img { width: 256px; height: auto; margin: 0 auto 12px; opacity: 0.9; }
.footer p { margin: 4px 0; font-size: 18px; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: 24px 64px; background: rgba(4, 5, 9, 0.94); animation: fadein 0.25s ease both; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 100%; max-height: 100%; text-align: center; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 110px); margin: 0 auto; box-shadow: 0 0 0 2px var(--gold-lo), 0 20px 60px #000; }
.lightbox figcaption { margin-top: 12px; color: var(--cream); font-size: 22px; }
.lightbox__close, .lightbox__nav { position: absolute; border: 0; background: none; color: var(--gold-hi); cursor: pointer; font-size: 54px; line-height: 1; padding: 8px 14px; }
.lightbox__close { top: 10px; right: 14px; }
.lightbox__nav--prev { left: 6px; top: 50%; transform: translateY(-50%); }
.lightbox__nav--next { right: 6px; top: 50%; transform: translateY(-50%); }
.lightbox__close:hover, .lightbox__nav:hover { color: #fff; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .features { grid-template-columns: repeat(2, 1fr); }
  .class-panel { grid-template-columns: 1fr; }
  .class-panel__pedestal { height: 220px; }
  .class-panel__pedestal .sprite { height: 180px; }
  .combat, .pvp, .atmos { grid-template-columns: 1fr; }
  .atmos__side { grid-template-columns: 1fr 1fr; }
  .hero__content { right: 50%; transform: translate(50%, -40%); }
  .hero__shade { background: linear-gradient(to bottom, rgba(11, 14, 22, 0.55) 0%, rgba(11, 14, 22, 0.15) 30%, rgba(11, 14, 22, 0.55) 60%, var(--bg) 100%); }
}
@media (max-width: 820px) {
  :root { --nav-h: 58px; }
  body { font-size: 19px; }
  h2 { font-size: 40px; }
  .nav { padding: 0 12px; }
  .nav__toggle { display: block; }
  .nav__links {
    position: fixed; top: var(--nav-h); left: 0; right: 0; flex-direction: column; gap: 6px; padding: 14px 16px 22px;
    background: rgba(11, 14, 22, 0.97); border-bottom: 1px solid var(--line);
    transform: translateY(-120%); transition: transform 0.3s ease; visibility: hidden;
  }
  .nav.is-open .nav__links { transform: none; visibility: visible; }
  .nav.is-open { background: rgba(11, 14, 22, 0.97); }
  .nav.is-open .nav__toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav.is-open .nav__toggle span:nth-child(2) { opacity: 0; }
  .nav.is-open .nav__toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .nav__links a:not(.btn) { padding: 8px 0; font-size: 24px; }
  .section { padding: 70px 0; }
  .regions, .specs, .fx-strip { grid-template-columns: 1fr; }
  .classes__tabs { grid-template-columns: repeat(2, 1fr); }
  .beasts { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: 1fr 1fr; }
  .gallery__item--wide { grid-column: span 2; grid-row: auto; }
  .gallery__item--wide img { aspect-ratio: 16 / 9; }
  .hero__tagline { font-size: 30px; }
  .hero__lead { font-size: 20px; }
  .slide figcaption { font-size: 18px; padding: 30px 14px 10px; }
  .slide figcaption b { font-size: 26px; display: block; }
  .showcase__nav { width: 36px; height: 50px; font-size: 30px; }
  .pvp { padding: 20px 16px; }
  .lightbox { padding: 16px; }
  .lightbox__nav { bottom: 10px; top: auto; transform: none; }
}
@media (max-width: 520px) {
  .features, .features, .atmos__side, .gallery { grid-template-columns: 1fr; }
  .gallery__item--wide { grid-column: auto; }
  .frame { padding: 8px; }
  .hero__cta .btn { width: 100%; }
  .btn--big { padding: 0 20px; font-size: 22px; }
  .skills li { font-size: 18px; }
  .rep__band { font-size: 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
.slide img { cursor: zoom-in; }
@media (max-width: 520px) {
  .slide figcaption { padding: 24px 12px 8px; }
  .slide figcaption b { display: inline; font-size: 24px; }
  .slide figcaption { font-size: 0; }
  .slide figcaption b { font-size: 24px; }
}
.class-panel__info > .skills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 520px) { .class-panel__info > .skills { grid-template-columns: 1fr; } }

/* ---------- Language switcher and Discord ---------- */
.nav__right { display: flex; align-items: center; gap: 18px; }
.lang { display: flex; box-shadow: 0 0 0 2px #05070c, 0 0 0 3px var(--gold-lo); background: rgba(11, 14, 22, 0.7); }
.lang button {
  font-family: var(--font-small); font-size: 15px; letter-spacing: 0.08em; color: var(--muted);
  background: none; border: 0; padding: 5px 9px; cursor: pointer;
}
.lang button + button { border-left: 1px solid rgba(232, 184, 92, 0.25); }
.lang button:hover { color: var(--cream); }
.lang button[aria-pressed="true"] { color: var(--bg); background: var(--gold); }
.nav__discord { display: inline-flex; align-items: center; gap: 6px; }
.nav__discord svg { width: 22px; height: 22px; }
.btn--discord { gap: 10px; border-image-source: url("../img/ui/button.png?v=3"); color: #e6e8ff; }
.btn--discord svg { width: 24px; height: 24px; color: #8f9cff; flex: none; }
.btn--discord:hover svg { color: #b3bcff; }

/* ---------- Playtest sign-up ---------- */
.playtest { display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; max-width: 1100px; width: 100%; padding: 14px 18px; }
.playtest__intro { text-align: left; }
.playtest__intro .play__crest { margin: 0 0 6px; width: 104px; }
.playtest__intro h2 { margin-bottom: 12px; }
.playtest__intro > p { font-size: 21px; }
.playtest__discord { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.playtest__discord p { color: var(--muted); }
.signup { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; align-content: start; }
.signup[hidden], .signup__done[hidden] { display: none; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; margin: 0; padding: 0; border: 0; }
.field label, .field legend { font-size: 19px; color: var(--gold-hi); padding: 0; }
.field small { font-family: var(--font-small); font-size: 15px; color: var(--muted); }
.input {
  width: 100%; min-height: 46px; padding: 0 6px;
  font-family: var(--font-body); font-size: 20px; color: var(--cream);
  background: transparent; border-style: solid; border-width: 8px;
  border-image: url("../img/ui/input.png?v=3") 8 fill / 8px stretch; image-rendering: pixelated;
  outline: none; border-radius: 0; appearance: none; -webkit-appearance: none;
}
.input:focus { filter: brightness(1.18) drop-shadow(0 0 6px rgba(255, 220, 143, 0.35)); }
select.input { cursor: pointer; padding-right: 26px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' shape-rendering='crispEdges'%3E%3Cpath fill='%23e8b85c' d='M0 0h12v2H10v2H8v2H6v2H6V6H4V4H2V2H0z'/%3E%3C/svg%3E") right 2px center / 12px 8px no-repeat; }
select.input option { background: var(--navy); color: var(--cream); }
.field.is-error .input, .check.is-error { filter: drop-shadow(0 0 0 #000) drop-shadow(0 0 5px rgba(232, 92, 84, 0.9)); }
.field--classes, .check, .signup__submit, .signup__status { grid-column: 1 / -1; }
.class-pick { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.class-pick label { cursor: pointer; }
.class-pick input { position: absolute; opacity: 0; pointer-events: none; }
.class-pick span {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px 6px; height: 100%;
  font-size: 17px; color: var(--muted); text-align: center; line-height: 1.05;
  background: rgba(13, 17, 30, 0.7); border: 1px solid var(--stone); box-shadow: 0 0 0 1px var(--outline); transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.class-pick img { width: 32px; height: 32px; filter: grayscale(0.6) brightness(0.85); }
.class-pick em { font-style: normal; }
.class-pick__q { display: grid; place-items: center; width: 32px; height: 32px; font-family: var(--font-title); font-size: 30px; font-weight: 400; color: var(--gold); }
.class-pick label:hover span { color: var(--cream); border-color: var(--gold-lo); }
.class-pick input:checked + span { color: var(--gold-hi); border-color: var(--gold); background: var(--navy-2); box-shadow: 0 0 0 1px var(--outline), inset 0 -3px 0 var(--gold); }
.class-pick input:checked + span img { filter: none; }
.class-pick input:focus-visible + span { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 18px; color: var(--text); cursor: pointer; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check::before { content: ""; flex: none; width: 28px; height: 28px; margin-top: 1px; background: url("../img/ui/checkbox.png?v=3") 0 0 / 100% 100% no-repeat; image-rendering: pixelated; }
.check:has(input:checked)::before { background-image: url("../img/ui/checkbox_checked.png?v=3"); }
.check:has(input:focus-visible)::before { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
.field--trap { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.signup__submit { justify-self: start; min-width: 260px; }
.signup__submit:disabled { filter: grayscale(0.6) brightness(0.8); cursor: wait; transform: none; }
.signup__status { margin: 0; min-height: 1.4em; font-size: 19px; color: var(--muted); }
.signup__status.is-error { color: #ff8a7a; }
.signup__done { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 10px; padding: 20px 10px; outline: none; animation: fadein 0.5s ease both; }
.signup__done img { width: 96px; height: 96px; }
.signup__done h3 { font-family: var(--font-title); font-size: 48px; color: var(--gold-hi); }
.signup__done p { font-size: 21px; max-width: 420px; }
.footer__links { display: flex; justify-content: center; gap: 26px; margin-bottom: 12px !important; }
.footer__links a { display: inline-flex; align-items: center; gap: 8px; font-size: 20px; }
.footer__links svg { width: 22px; height: 22px; }

@media (max-width: 1080px) {
  .nav__links { gap: 18px; }
  .playtest { grid-template-columns: 1fr; gap: 26px; }
}
@media (max-width: 820px) {
  .nav__right { gap: 10px; }
  .nav__discord { padding: 8px 0; font-size: 24px; }
  .lang button { padding: 5px 7px; }
}
@media (max-width: 520px) {
  .signup { grid-template-columns: 1fr; }
  .class-pick { grid-template-columns: repeat(3, 1fr); }
  .signup__submit { width: 100%; min-width: 0; }
  .playtest { padding: 4px 2px; }
  .nav__brand span { display: none; }
}
@media (max-width: 820px) {
  .nav__links { background: var(--bg); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6); align-items: stretch; text-align: center; }
  .nav.is-open, .nav.is-open.is-solid { background: var(--bg); backdrop-filter: none; }
}
@media (max-width: 820px) { .nav__discord { justify-content: center; } }

/* ---------- Class heroes (the game's doll, animated) ---------- */
.class-panel__pedestal { height: 300px; padding-bottom: 0; align-items: center; }
.doll { display: block; width: 288px; height: 288px; cursor: pointer; image-rendering: pixelated; image-rendering: crisp-edges; }
.class-panel__note { margin: -6px 0 6px; font-family: var(--font-small); font-size: 15px; color: var(--muted); }
@media (max-width: 1080px) { .class-panel__pedestal { height: 240px; } .doll { width: 216px; height: 216px; } }

/* ---------- Language links, FAQ, document pages ---------- */
.lang a { font-family: var(--font-small); font-size: 15px; letter-spacing: 0.08em; color: var(--muted); padding: 5px 9px; text-decoration: none; }
.lang a + a { border-left: 1px solid rgba(232, 184, 92, 0.25); }
.lang a:hover { color: var(--cream); }
.lang a[aria-current="page"] { color: var(--bg); background: var(--gold); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.faq { max-width: 860px; margin: 0 auto; display: grid; gap: 12px; }
.faq__item { background: var(--navy); border: 1px solid var(--gold-lo); box-shadow: var(--gilded); }
.faq__item[open] { border-color: var(--gold); }
.faq__item summary { cursor: pointer; list-style: none; padding: 14px 48px 14px 18px; font-size: 22px; color: var(--gold-hi); position: relative; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-size: 28px; color: var(--gold); }
.faq__item[open] summary::after { content: "\2212"; }
.faq__item p { margin: 0; padding: 0 18px 16px; font-size: 20px; }
.check a { color: var(--gold-hi); text-decoration: underline; }
.footer__links { flex-wrap: wrap; }
.doc-page .nav { position: sticky; }
.doc { max-width: 820px; padding-top: 50px; padding-bottom: 60px; }
.doc h1 { font-family: var(--font-title); font-size: 52px; color: var(--gold-hi); text-shadow: 0 3px 0 #000; margin-bottom: 4px; }
.doc h2 { font-family: var(--font-body); font-size: 28px; color: var(--cream); text-shadow: none; margin: 30px 0 8px; }
.doc p { font-size: 20px; }
.doc a:not(.btn) { text-decoration: underline; }
.lost { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 20px; gap: 4px; }
.lost__sprite { width: 80px; height: auto; margin-bottom: 10px; }
.lost h1 { font-family: var(--font-title); font-size: 96px; color: var(--gold-hi); text-shadow: 0 4px 0 #000; }
.lost p { margin: 0; font-size: 21px; }
.lost__links { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 18px !important; }

/* ---------- Subclasses in the class panels ---------- */
.spec__head { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.spec__emblem { width: 64px; height: 64px; flex: none; filter: drop-shadow(0 3px 0 rgba(0, 0, 0, 0.6)); }
.spec__head h4 { margin: 0; }
.spec__role { display: block; font-family: var(--font-small); font-size: 15px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.spec__passive { margin: -4px 0 12px; padding: 6px 10px; border-left: 2px solid var(--gold-lo); background: rgba(228, 171, 82, 0.06); font-family: var(--font-small); font-size: 16px; line-height: 1.3; color: var(--text); }
.spec__passive b { color: var(--gold-hi); font-weight: normal; margin-right: 4px; }
.spec .skills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; }
.spec .skills li { font-size: 17px; line-height: 1.1; }

/* ---------- Picture + text rows (progression, damage meter) ---------- */
.showrow { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 46px; align-items: center; margin-top: 70px; }
.section__head + .showrow { margin-top: 0; }
.showrow--flip .showrow__img { order: 2; }
.showrow--wide { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
.showrow--meter { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); margin-top: 60px; }
.showrow__img { margin: 0; background: #000; }
.showrow__img img { width: 100%; cursor: zoom-in; }
.showrow__text h3 { font-family: var(--font-title); font-size: 44px; color: var(--gold-hi); margin-bottom: 12px; text-shadow: 0 3px 0 #000; }
.showrow__text > p { font-size: 21px; }
.showrow__text .combat__list { margin-top: 6px; }
.badge__icon { display: inline-block; width: 20px; height: 20px; vertical-align: -4px; margin-right: 6px; }

.emblems { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 10px; }
.emblems li { display: grid; justify-items: center; text-align: center; gap: 2px; }
.emblems img { width: 64px; height: 64px; filter: drop-shadow(0 3px 0 rgba(0, 0, 0, 0.6)); transition: transform 0.2s ease; }
.emblems li:hover img { transform: translateY(-4px) scale(1.06); }
.emblems b { font-weight: 400; font-size: 20px; color: var(--cream); }
.emblems span { font-family: var(--font-small); font-size: 14px; color: var(--muted); line-height: 1.1; }

.groups { list-style: none; margin: 20px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.groups li { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: rgba(13, 17, 30, 0.7); border: 1px solid var(--gold-lo); box-shadow: var(--gilded); }
.groups img { width: 48px; height: 48px; flex: none; }
.groups b { display: block; font-weight: 400; font-size: 22px; color: var(--gold-hi); }
.groups span { display: block; font-size: 17px; color: var(--text); line-height: 1.15; }

/* ---------- Loot ---------- */
.rarities { list-style: none; margin: 0 0 46px; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; }
.rarity { --c: #fff; display: grid; justify-items: center; text-align: center; gap: 2px; padding: 22px 10px 18px; background: linear-gradient(to top, color-mix(in srgb, var(--c) 14%, transparent), rgba(5, 7, 12, 0.5) 70%); border: 1px solid color-mix(in srgb, var(--c) 45%, transparent); transition: transform 0.25s ease, box-shadow 0.25s ease; }
.rarity:hover { transform: translateY(-5px); box-shadow: 0 10px 30px color-mix(in srgb, var(--c) 25%, transparent); }
.rarity__slot { display: block; width: 128px; height: 128px; margin-bottom: 12px; background: center / 100% 100% no-repeat; image-rendering: pixelated; box-shadow: 0 0 0 3px #05070c; }
.rarity__slot img { width: 128px; height: 128px; }
.rarity b { font-weight: 400; font-size: 26px; color: var(--c); text-shadow: 0 2px 0 #000; }
.rarity__item { font-size: 19px; color: var(--cream); }
.rarity small { font-family: var(--font-small); font-size: 15px; color: var(--muted); }
.rarity--common { --c: #ffffff; } .rarity--common .rarity__slot { background-image: url("../img/game/ui_itemgrade_common.png"); }
.rarity--uncommon { --c: #1eff00; } .rarity--uncommon .rarity__slot { background-image: url("../img/game/ui_itemgrade_uncommon.png"); }
.rarity--rare { --c: #3d9bff; } .rarity--rare .rarity__slot { background-image: url("../img/game/ui_itemgrade_rare.png"); }
.rarity--epic { --c: #b65cf5; } .rarity--epic .rarity__slot { background-image: url("../img/game/ui_itemgrade_epic.png"); }
.rarity--legendary { --c: #ff8000; } .rarity--legendary .rarity__slot { background-image: url("../img/game/ui_itemgrade_legendary.png"); }
.features--3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 1080px) {
  .showrow, .showrow--wide, .showrow--meter { grid-template-columns: 1fr; gap: 26px; }
  .showrow--flip .showrow__img { order: 0; }
  .showrow__img { max-width: 720px; justify-self: center; width: 100%; }
  .rarities { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
  .rarity__slot, .rarity__slot img { width: 96px; height: 96px; }
  .features--3 { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .rarities { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .showrow__text h3 { font-size: 38px; }
}
@media (max-width: 520px) {
  .rarities { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rarity__slot, .rarity__slot img { width: 64px; height: 64px; }
  .emblems { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .groups { grid-template-columns: 1fr; }
  .spec .skills { grid-template-columns: 1fr; }
}
/* Window screenshots are shown smaller than their pixels: smooth them so the UI text stays readable (the lightbox shows them 1:1). */
.showrow__img img { image-rendering: auto; }
@media (max-width: 520px) { .rarity--legendary { grid-column: span 2; } }

/* ---------- Steam (coming soon, not a link yet) ---------- */
.btn--steam { gap: 10px; color: #c7d5e0; cursor: default; filter: saturate(0.6) brightness(0.85); }
.btn--steam:hover { border-image-source: url("../img/ui/button.png?v=3"); color: #c7d5e0; transform: none; }
.btn--steam svg { width: 24px; height: 24px; color: #9fb6c9; flex: none; }
.btn__soon {
  font-family: var(--font-small); font-style: normal; font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--bg); background: var(--gold); padding: 2px 7px; text-shadow: none;
}
.playtest__links { display: flex; flex-wrap: wrap; gap: 12px; }
.footer__steam { display: inline-flex; align-items: center; gap: 8px; font-size: 20px; color: var(--muted); }
.footer__steam svg { width: 22px; height: 22px; }
.footer__steam em { font-style: normal; font-family: var(--font-small); font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); }
@media (max-width: 520px) { .playtest__links .btn { width: 100%; } }

/* ---------- Devlog (Tools/WebsiteBuild/devlog.cjs) ---------- */
.devlog-page main.devlog { padding-top: calc(var(--nav-h) + 44px); padding-bottom: 80px; min-height: 70vh; }
.devlog__head h1, .post__head h1 {
  font-family: var(--font-title); line-height: 1.02; color: var(--gold-hi);
  text-shadow: 0 3px 0 #000, 0 0 24px rgba(232, 184, 92, 0.25);
}
.devlog__head h1 { font-size: 66px; }
.devlog__feed { margin: 12px 0 0; font-size: 18px; }
.devlog__feed a { text-decoration: underline; }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.post-card { display: flex; flex-direction: column; min-width: 0; }
.post-card__img { display: block; overflow: hidden; box-shadow: 0 0 0 2px #05070c; }
.post-card__img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform 0.4s ease; }
.post-card:hover .post-card__img img { transform: scale(1.04); }
.post-card__body { display: flex; flex-direction: column; flex: 1; padding-top: 14px; }
.post-card__meta, .post__meta {
  font-family: var(--font-small); font-size: 15px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gold); margin: 0 0 6px;
}
.post-card__title { font-family: var(--font-body); font-size: 27px; line-height: 1.1; margin: 0 0 8px; }
.post-card__title a { color: var(--cream); }
.post-card__title a:hover { color: var(--gold-hi); }
.post-card__summary { flex: 1; font-size: 19px; }
.post-card__more { font-size: 19px; align-self: flex-start; }
.post-grid--all .post-card--wide { grid-column: 1 / -1; flex-direction: row; gap: 26px; }
.post-grid--all .post-card--wide .post-card__img { flex: 0 0 58%; }
.post-grid--all .post-card--wide .post-card__body { padding-top: 4px; justify-content: center; }
.post-grid--all .post-card--wide .post-card__title { font-size: 36px; }
.post-grid--all .post-card--wide .post-card__summary { flex: 0 0 auto; font-size: 21px; }
.post__all { text-align: center; margin: 34px 0 0; }

.post { max-width: 880px; }
.post__crumbs { font-size: 18px; color: var(--muted); margin-bottom: 22px; }
.post__crumbs a { color: var(--muted); }
.post__crumbs a:hover { color: var(--gold-hi); }
.post__head h1 { font-size: 60px; margin: 4px 0 14px; }
.post__lead { font-size: 24px; line-height: 1.35; color: var(--cream); }
.post__cover { margin: 26px 0 34px; }
.post__cover img, .post__fig img {
  width: 100%; cursor: zoom-in;
  box-shadow: 0 0 0 2px #05070c, 0 0 0 3px var(--gold-lo), 0 16px 40px rgba(0, 0, 0, 0.5);
}
.post__body { font-size: 21px; line-height: 1.5; }
.post__body h2 { font-family: var(--font-body); font-size: 34px; line-height: 1.1; color: var(--gold-hi); text-shadow: 0 2px 0 #000; margin: 42px 0 12px; }
.post__body h3 { font-size: 26px; color: var(--cream); margin: 28px 0 8px; }
.post__body ul, .post__body ol { padding-left: 1.3em; margin: 0 0 1em; }
.post__body li { margin: 5px 0; }
.post__body li::marker { color: var(--gold); }
.post__body b { color: var(--gold-hi); font-weight: 400; }
.post__body p a, .post__body li a { text-decoration: underline; }
.post__body code { font-family: var(--font-small); background: var(--navy-2); padding: 0 6px; }
.post__fig { margin: 30px 0; }
.post__fig figcaption { margin-top: 12px; font-size: 17px; color: var(--muted); text-align: center; }
.post__body blockquote { margin: 24px 0; padding: 12px 20px; border-left: 3px solid var(--gold); background: var(--navy); color: var(--cream); }
.post__table { overflow-x: auto; margin: 22px 0; }
.post__table table { width: 100%; border-collapse: collapse; font-size: 19px; line-height: 1.3; }
.post__table th {
  text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--line);
  font-family: var(--font-small); font-weight: 400; font-size: 15px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gold);
}
.post__table td { padding: 9px 12px; border-bottom: 1px solid rgba(232, 184, 92, 0.12); vertical-align: top; }
.post__table tr:nth-child(even) td { background: rgba(18, 22, 33, 0.6); }
.post__emblem { display: inline-block; width: 24px; height: 24px; vertical-align: -5px; margin-right: 8px; image-rendering: pixelated; }
.post__body .rarities { margin: 26px 0; }
.r-common { color: #fff; } .r-uncommon { color: #1eff00; } .r-rare { color: #3d9bff; } .r-epic { color: #b65cf5; } .r-legendary { color: #ff8000; }
.post__cta { margin-top: 50px; text-align: center; }
.post__cta h2 { margin-bottom: 8px; }
.post__cta p { font-size: 21px; }
.post__cta-links { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 6px; }
.post__more { margin-top: 80px; }
.post__more > h2 { text-align: center; margin-bottom: 28px; }
@media (max-width: 980px) {
  .post-grid { grid-template-columns: repeat(2, 1fr); }
  .post-grid--all .post-card--wide { flex-direction: column; gap: 0; }
  .post-grid--all .post-card--wide .post-card__body { padding-top: 14px; }
  .post-grid--all .post-card--wide .post-card__title { font-size: 30px; }
}
@media (max-width: 620px) {
  .post-grid { grid-template-columns: 1fr; }
  .devlog__head h1 { font-size: 50px; }
  .post__head h1 { font-size: 44px; }
  .post__lead { font-size: 21px; }
  .post__body { font-size: 19px; }
  .post__body h2 { font-size: 30px; }
  .post__table table { font-size: 17px; }
  .post__cta-links .btn { width: 100%; }
}
@media (max-width: 620px) {
  /* Tables become one card per row, each cell with its column name. */
  .post__table thead { display: none; }
  .post__table table, .post__table tbody, .post__table tr, .post__table td { display: block; }
  .post__table tr { padding: 10px 0; border-bottom: 1px solid var(--line); }
  .post__table tr:nth-child(even) td { background: none; }
  .post__table td { padding: 2px 0; border: 0; }
  .post__table td::before {
    content: attr(data-label); display: block;
    font-family: var(--font-small); font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gold);
  }
  .post__table td:first-child::before { display: none; }
  .post__table td:first-child { font-size: 22px; color: var(--cream); }
}

/* Rifts glimpse (Regions section): a cave shot, two thumbnails and a link to the devlog post. */
.showrow--rift { margin-top: 80px; }
.showrow--rift .showrow__img img, .rift-thumbs img { image-rendering: auto; }
.rift-thumbs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 26px 0 24px; }
.rift-thumbs figure { margin: 0; background: #000; overflow: hidden; border: 1px solid var(--gold); box-shadow: var(--gilded); }
.rift-thumbs img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; cursor: zoom-in; transition: transform 0.5s cubic-bezier(.2, .8, .2, 1); }
.rift-thumbs figure:hover img { transform: scale(1.06); }
@media (max-width: 1080px) { .showrow--rift { margin-top: 56px; } }

/* Massive PvP block (Combat section): the crowd shot and a link to the technical devlog post. */
.showrow--mass .showrow__img img { image-rendering: auto; }
.mass-more { margin-top: 28px; }
/* The longer hero text reaches the bottom on phones: the scroll hint would sit on the note. */
@media (max-width: 520px) { .hero__scroll { display: none; } }

/* Skill tooltips (class panels): what each skill does, its level and subclass. Placed by initSkillTips (main.js). */
.skills li[tabindex] { position: relative; cursor: help; border-radius: 2px; }
.skills li[tabindex]:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.skill-tip {
  position: fixed; z-index: 60; display: none; width: 300px; max-width: calc(100vw - 24px); padding: 12px 14px 13px;
  background: rgba(9, 8, 16, 0.97); border: 1px solid var(--gold); box-shadow: var(--gilded), 0 14px 30px rgba(0, 0, 0, 0.6);
  font-family: var(--font-small); font-size: 16px; line-height: 1.35; color: var(--text); text-align: left; pointer-events: none;
}
.skill-tip.is-open { display: block; }
.skill-tip b { display: block; font-family: var(--font-body); font-size: 21px; font-weight: normal; line-height: 1.1; color: var(--gold-hi); }
.skill-tip small { display: block; margin: 2px 0 7px; font-size: 14px; color: var(--muted); }
.no-js .skills li[tabindex]:hover .skill-tip { display: block; position: absolute; left: 0; top: 100%; }

/* ---- Server status (docs/Website.md "Server status"): nav badge and realm list, filled by main.js initServers ---- */
.srv { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-small); font-size: 15px; color: var(--cream); text-decoration: none; white-space: nowrap; padding: 4px 10px; background: rgba(11, 14, 22, 0.7); box-shadow: 0 0 0 2px #05070c, 0 0 0 3px var(--gold-lo); }
.srv:hover { color: var(--gold-hi); }
.srv__dot { width: 9px; height: 9px; flex: none; background: #6b6f7d; box-shadow: 0 0 0 1px #05070c; }
.srv[data-state="online"] .srv__dot, .realm[data-status="online"] .srv__dot { background: #5fd068; animation: srv-pulse 2.4s steps(2, end) infinite; }
.srv[data-state="maintenance"] .srv__dot, .realm[data-status="maintenance"] .srv__dot, .realm[data-status="full"] .srv__dot { background: #f1be59; }
.srv[data-state="offline"] .srv__dot, .realm[data-status="offline"] .srv__dot { background: #d9443f; }
@keyframes srv-pulse { 50% { background: #3f9a48; } }
@media (prefers-reduced-motion: reduce) { .srv__dot { animation: none !important; } }

.realms { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 360px)); justify-content: center; gap: 16px; }
.realms__note { grid-column: 1 / -1; text-align: center; color: var(--muted); margin: 0; }
.realms__note--warn { color: var(--gold-hi); }
.realm { padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; }
.realm__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.realm__name { margin: 0; font-family: var(--font-title); font-weight: 400; font-size: 28px; color: var(--gold); text-shadow: 2px 2px 0 var(--outline); }
.realm__status { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-small); font-size: 16px; color: var(--cream); }
.realm[data-status="offline"] .realm__status { color: #e8857f; }
.realm__meta, .realm__desc, .realm__rates { margin: 0; color: var(--muted); font-size: 17px; }
.realm__desc { color: var(--text); }
.realm__rates { color: var(--gold-hi); }
.realm__tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0; }
.realm__tag { font-family: var(--font-small); font-size: 14px; padding: 1px 8px; color: var(--cream); background: #202436; border: 1px solid #05070c; }
.realm__tag--pvp { color: #ffb0a8; background: #4a1220; }
.realm__tag--pve { color: #8fe0a0; background: #1d3a2a; }
.realm__tag--rec { color: #fff4ab; background: #3a2a14; }
.realm__pop { font-family: var(--font-small); font-size: 15px; color: var(--muted); }
.realm__pop--high, .realm__pop--full { color: var(--gold-hi); }

@media (max-width: 1080px) {
  .srv { order: -1; }
  .srv__text { display: none; }
  .srv { padding: 6px 8px; }
}

/* ---------- Screenshots: shown smaller than their 1600 x 900 native pixels, so smooth the downscale ---------- */
.slide img, .region__img img, .fx img, .weather img, .gallery__item img, .combat__main img, .compare__img { image-rendering: auto; }

/* ---------- Professions ---------- */
.profs { list-style: none; margin: 46px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.prof { display: flex; gap: 14px; align-items: flex-start; padding: 18px; }
.prof > img { width: 64px; height: 64px; flex: none; filter: drop-shadow(0 3px 0 rgba(0, 0, 0, 0.6)); }
.prof h3 { margin: 2px 0 4px; font-size: 24px; color: var(--gold-hi); }
.prof p { margin: 0; font-size: 18px; line-height: 1.3; }
.profs + .showrow { margin-top: 60px; }
.beast--world .beast__art { height: 150px; }
@media (max-width: 900px) { .profs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .profs { grid-template-columns: 1fr; } }
.market-card { display: grid; grid-template-columns: 64px 1fr; gap: 22px; align-items: start; margin-top: 60px; padding: 26px 28px; }
.market-card .feature__icon { margin: 4px 0 0; }
.market-card .combat__list { margin-top: 8px; }
@media (max-width: 600px) { .market-card { grid-template-columns: 1fr; } }
