:root {
  --ground: #15100c;
  --ground-2: #1b140f;
  --panel: #241a13;
  --line: #3d2c1f;
  --bronze: #c98e5a;
  --bronze-lo: #6e4022;
  --gold: #ffd100;
  --cream: #fff3d1;
  --text: #e6d8bf;
  --muted: #a8977b;
  --display: "Cinzel", Georgia, "Times New Roman", serif;
  --body: "Alegreya Sans", "Gill Sans", "Trebuchet MS", sans-serif;
}

* { box-sizing: border-box; }
/* the game's gauntlet, only where something game-like happens: the buttons and the frame list */
.btn, [data-fx] { cursor: url("/img/cursor-point.png") 1 1, pointer; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font: 19px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--bronze); text-underline-offset: 3px; }
a:hover { color: var(--cream); }
code { font: 0.9em ui-monospace, Menlo, monospace; color: var(--cream); }
strong { color: var(--cream); font-weight: 700; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.center { text-align: center; }

h1, h2 { font-family: var(--display); color: var(--cream); line-height: 1.2; font-weight: 700; margin: 0 0 18px; }
h1 { font-size: clamp(30px, 4.4vw, 46px); }
h2 { font-size: clamp(24px, 3vw, 32px); }
p { margin: 0 0 16px; }

/* header */
.top { border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 700; font-size: 22px; color: var(--cream); text-decoration: none; }
nav { display: flex; align-items: center; gap: 24px; }
nav a { color: var(--text); text-decoration: none; font-size: 17px; }
nav a:hover { color: var(--cream); }

/* buttons: a HealKit frame. Health at 70%; on hover the incoming heal fills it */
.btn {
  --hp: 70%;
  position: relative; display: inline-block; overflow: hidden;
  padding: 10px 26px 16px;
  border: 7px solid #493212; border-image: url("/img/trim.svg") 7 stretch;
  background: linear-gradient(180deg, rgba(255,255,255,0.10), rgba(0,0,0,0.18)),
              linear-gradient(90deg, #1e5fb0 0 var(--hp), #15100b var(--hp));
  background-clip: padding-box;
  color: #fff; font: 700 19px/1.2 var(--body); text-decoration: none;
  text-shadow: 0 1px 1px #000, 0 0 2px #000;
}
.btn::before { /* incoming heal */
  content: ""; position: absolute; top: 0; bottom: 7px; left: var(--hp); width: 0;
  background: rgba(70, 200, 70, 0.75); transition: width 0.35s ease-out;
}
.btn::after { /* the mana bar under the divider */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 5px;
  border-top: 2px solid #1f1200;
  background: linear-gradient(90deg, #3657d8 0 58%, #0d0906 58%);
}
/* casting: the heal's cost shows lighter at the end of the mana bar, as in game */
.btn:hover::after, .btn:focus-visible::after {
  background: linear-gradient(90deg, #3657d8 0 44%, #9db1ff 44% 58%, #0d0906 58%);
}
.btn span { position: relative; }
.btn:hover::before, .btn:focus-visible::before { width: calc(100% - var(--hp)); }
.btn:hover { color: #fff; }
.btn-small { padding: 4px 14px 10px; font-size: 16px; --hp: 85%; }
.btn-small::after { height: 4px; }
.link { color: var(--text); font-weight: 500; }

/* hero */
.hero { padding: 56px 0 64px; }
.hero-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 44px; align-items: center; }
.lead { font-size: 21px; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 22px; margin: 26px 0 18px; }
.facts { color: var(--muted); font-size: 16px; }

/* screenshots: a thin bronze rim, like the frames */
.shot { margin: 0; }
.trim, .shot img, .shot video {
  border: 7px solid #493212;
  border-image: url("/img/trim.svg") 7 stretch;
  background-clip: padding-box;
}
.shot figcaption { margin-top: 10px; color: var(--muted); font-size: 16px; font-style: italic; }

/* sections */
.band { padding: 72px 0; border-top: 1px solid var(--line); }
.band-alt { background: var(--ground-2); }
.split { display: grid; grid-template-columns: 1fr 1.1fr; gap: 52px; align-items: center; }
.split.reverse > :first-child { order: 2; }

.list { padding-left: 1.1em; margin: 0; }
.list li { margin-bottom: 12px; padding-left: 4px; }
.list li::marker { color: var(--bronze); }

/* why */
.why { display: grid; grid-template-columns: 96px 1fr; gap: 28px; align-items: start; }
.avatar { border-radius: 50%; border: 2px solid var(--bronze-lo); }
.sign { font-family: var(--display); color: var(--bronze); font-size: 20px; }

.panel { background: #18110c; padding: 8px 28px; }
.why.panel { padding: 28px; }

/* faq */
details { border-bottom: 1px solid var(--line); }
details:last-of-type { border-bottom: 0; }
summary { cursor: pointer; padding: 16px 32px 16px 0; font-weight: 700; color: var(--cream); list-style: none; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 14px; color: var(--bronze); font-size: 22px; font-weight: 400; }
details[open] summary::after { content: "–"; }
details p { padding: 0 0 18px; margin: 0; }

.foot { border-top: 1px solid var(--line); padding: 32px 0 40px; color: var(--muted); font-size: 16px; }
.foot .small { font-size: 14px; }

/* frame list: each item lights the clip next to it in its own color (fx.js) */
.fx-hint { text-decoration: underline dotted rgba(201, 142, 90, 0.7); text-underline-offset: 4px; }
[data-fx] { border-radius: 2px; }
#fx-target video { transition: filter 0.25s; }
#fx-target.fx-incoming video { border-image-source: url("/img/trim-incoming.svg"); filter: drop-shadow(0 0 11px rgba(70, 200, 70, 0.7)); }
#fx-target.fx-hot video { border-image-source: url("/img/trim-hot.svg"); filter: drop-shadow(0 0 11px rgba(63, 201, 180, 0.7)); }
#fx-target.fx-overheal video { border-image-source: url("/img/trim-overheal.svg"); filter: drop-shadow(0 0 11px rgba(214, 130, 60, 0.65)); }
#fx-target.fx-magic video { border-image-source: url("/img/trim-magic.svg"); filter: drop-shadow(0 0 11px rgba(51, 153, 255, 0.7)); }
#fx-target.fx-aggro video { border-image-source: url("/img/trim-aggro.svg"); filter: drop-shadow(0 0 11px rgba(255, 60, 30, 0.75)); }
#fx-target.fx-shield video { border-image-source: url("/img/trim-shield.svg"); filter: drop-shadow(0 0 11px rgba(235, 242, 250, 0.6)); }

@media (max-width: 900px) {
  .hero-grid, .split { grid-template-columns: 1fr; gap: 28px; }
  .split.reverse > :first-child { order: 0; }
  nav a:not(.btn) { display: none; }
  .hero { padding-top: 36px; }
  .band { padding: 52px 0; }
}
@media (max-width: 560px) {
  .why { grid-template-columns: 1fr; }
  .avatar { width: 72px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* 404: the rez icon from the frames, pulsing, and a Resurrect button that fills with its light */
.dead-page { min-height: 100vh; display: flex; align-items: center; padding: 48px 0; }
.dead-page .wrap { width: 100%; }
.dead-page h1 { margin-top: 0; }
.spirit { display: inline-block; margin-bottom: 24px; }
.spirit img { image-rendering: auto; animation: spirit 2.6s ease-in-out infinite; }
@keyframes spirit {
  0%, 100% { filter: drop-shadow(0 0 6px rgba(110, 200, 255, 0.35)); opacity: 0.85; }
  50% { filter: drop-shadow(0 0 18px rgba(130, 210, 255, 0.85)); opacity: 1; }
}
.btn-rez { padding: 10px 34px; font-size: 21px; background: #15100b; background-clip: padding-box; transition: box-shadow 0.35s; }
.btn-rez::after { display: none; }
.btn-rez::before {
  left: 0; right: 0; bottom: 0; width: auto; opacity: 0;
  background: radial-gradient(ellipse at center, rgba(150, 215, 255, 0.55), rgba(60, 140, 220, 0.2) 60%, transparent 85%);
  transition: opacity 0.35s;
}
.btn-rez:hover::before, .btn-rez:focus-visible::before { width: auto; opacity: 1; }
.btn-rez:hover, .btn-rez:focus-visible { box-shadow: 0 0 22px rgba(110, 200, 255, 0.45); }
@media (prefers-reduced-motion: reduce) { .spirit img { animation: none; filter: drop-shadow(0 0 10px rgba(110, 200, 255, 0.6)); } }
