@import url("assets/fonts/fonts.css");
:root {
  color-scheme: dark;
  --ink: #f1eedb;
  --muted: #a4afa6;
  --gold: #f2cd7a;
  --mint: #97c8af;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #172222;
  color: var(--ink);
  font:
    16px/1.65 "DM Sans",
    sans-serif;
}
a {
  color: var(--gold);
  text-underline-offset: 4px;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1200px;
  margin: auto;
  padding: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font:
    700 22px "Space Grotesk",
    sans-serif;
  text-decoration: none;
  color: var(--ink);
}
.brand span {
  color: var(--mint);
  margin-left: 0;
}
.play {
  border: 1px solid #f2cd7a44;
  border-radius: 12px;
  padding: 10px 18px;
  text-decoration: none;
  font-weight: 700;
}
main {
  max-width: 1152px;
  margin: auto;
  padding: 0 24px;
}
.intro {
  padding: 56px 0 36px;
  max-width: 700px;
}
.eyebrow {
  color: var(--gold);
  font-size: 11px;
  letter-spacing: 2px;
  font-weight: 700;
}
h1,
h2,
h3 {
  font-family: "Space Grotesk", sans-serif;
  line-height: 1.15;
}
h1 {
  font-size: clamp(36px, 6vw, 62px);
  letter-spacing: -2px;
  margin: 18px 0;
}
h1 em {
  font-style: normal;
  color: var(--mint);
}
p {
  color: var(--muted);
}
.tools {
  padding: 22px;
  background: #202d2c;
  border: 1px solid #ffffff12;
  border-radius: 18px;
}
label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 8px;
}
input {
  width: 100%;
  background: #142120;
  border: 1px solid #ffffff25;
  padding: 14px;
  color: var(--ink);
  font: inherit;
  border-radius: 9px;
}
nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}
nav a {
  padding: 7px 13px;
  background: #31413a;
  color: var(--ink);
  text-decoration: none;
  border-radius: 8px;
  font-size: 13px;
}
nav a:hover,
.play:hover {
  background: #455444;
}
section {
  scroll-margin-top: 24px;
  margin: 42px 0;
}
h2 {
  font-size: 29px;
  margin-bottom: 12px;
}
.section-note {
  max-width: 760px;
  margin-top: 0;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
}
.entry {
  background: #202c2b;
  border: 1px solid #ffffff12;
  border-radius: 16px;
  padding: 22px;
  overflow: hidden;
}
.entry h3 {
  font-size: 19px;
  margin: 10px 0;
}
.entry p {
  font-size: 14px;
  margin: 10px 0;
}
.entry .tag {
  color: var(--gold);
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.entry .art {
  width: 72px;
  height: 72px;
  object-fit: contain;
  image-rendering: pixelated;
  float: right;
  margin: 0 0 10px 12px;
}
.entry .portrait {
  width: 88px;
  height: 100px;
  object-fit: cover;
  border-radius: 10px;
  object-position: center 25%;
  image-rendering: pixelated;
  float: right;
  margin-left: 12px;
}
.entry details {
  border-top: 1px solid #ffffff15;
  margin-top: 16px;
  padding-top: 10px;
  font-size: 13px;
  color: var(--muted);
}
summary {
  cursor: pointer;
  color: var(--mint);
}
.ranks {
  padding-left: 20px;
}
.ranks li {
  margin: 8px 0;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
th,
td {
  text-align: left;
  padding: 6px;
  border-bottom: 1px solid #ffffff15;
}
th {
  color: var(--mint);
}
.wide {
  grid-column: 1/-1;
}
footer {
  padding: 30px 0 60px;
  border-top: 1px solid #ffffff16;
  color: var(--muted);
  font-size: 12px;
}
#results {
  font-size: 12px;
  margin-bottom: 0;
}
a:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
@media (max-width: 480px) {
  header {
    padding: 16px;
  }
  .brand {
    font-size: 17px;
  }
  .play {
    font-size: 12px;
    padding: 8px 10px;
  }
  main {
    padding: 0 16px;
  }
  .intro {
    padding-top: 26px;
  }
  .tools,
  .entry {
    padding: 18px;
  }
  .grid {
    gap: 12px;
  }
  h1 {
    letter-spacing: -1px;
  }
  nav a {
    font-size: 12px;
    padding: 6px 9px;
  }
}
@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
.combat-preview {
  clear: both;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding-top: 14px;
  min-height: 88px;
  border-bottom: 1px solid #ffffff15;
}
.entry .portrait {
  transform: scale(var(--portrait-scale, 1));
  transform-origin: center bottom;
}
.combat-preview img {
  object-fit: contain;
  object-position: center bottom;
  image-rendering: pixelated;
}
.combat-preview span {
  font-size: 11px;
  color: var(--muted);
  padding-bottom: 8px;
}
#legends .entry {
  border: 1px solid #f2cd7a77;
  background: linear-gradient(160deg, #343325, #1a2524);
  position: relative;
}
#legends h3 {
  font-size: 32px;
  color: var(--gold);
  letter-spacing: 5px;
}
.legend-veil {
  height: 245px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-direction: column;
  position: relative;
  background: radial-gradient(ellipse at 50% 65%, #d8b65b30, transparent 65%);
  margin-top: 12px;
}
.legend-veil img {
  width: 90%;
  height: 210px;
  object-fit: contain;
  image-rendering: pixelated;
  filter: brightness(0);
  opacity: 0.95;
  user-select: none;
  pointer-events: none;
}
.legend-veil span {
  font-size: 9px;
  letter-spacing: 2px;
  color: #d7cba3;
  margin: 10px 0;
}
