:root {
  color-scheme: dark;
  --bg: #0b0908;
  --bg-soft: #15110f;
  --panel: rgba(30, 25, 21, 0.78);
  --panel-strong: rgba(38, 31, 26, 0.94);
  --line: rgba(219, 184, 116, 0.24);
  --line-strong: rgba(219, 184, 116, 0.48);
  --gold: #d9b878;
  --gold-soft: #f3dfb5;
  --ember: #b66d3a;
  --green: #7f9a74;
  --ink: #f4ebdc;
  --muted: #bba991;
  --muted-soft: #8e806f;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
  --radius: 14px;
  --max: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 16% 8%, rgba(217, 184, 120, 0.14), transparent 30%),
    radial-gradient(circle at 86% 12%, rgba(127, 154, 116, 0.11), transparent 28%),
    linear-gradient(180deg, #120f0d 0%, #080706 62%, #050403 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.026) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 78%);
}

a {
  color: inherit;
  text-decoration: none;
}

.shell {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(18px);
  background: rgba(8, 7, 6, 0.72);
  border-bottom: 1px solid rgba(219, 184, 116, 0.14);
}

.nav {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand img {
  width: 42px;
  height: 42px;
}

.navlinks {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.navlinks a:hover {
  color: var(--gold-soft);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 8px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, #c9a160, #876238);
  color: #140f0b;
  font-weight: 800;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: none;
}

.hero {
  min-height: calc(100vh - 72px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 430px);
  gap: 42px;
  align-items: center;
  padding: 56px 0 40px;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold-soft);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.kicker::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--gold);
}

h1 {
  margin: 16px 0 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(46px, 8vw, 96px);
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 14px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1;
}

h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

p {
  color: var(--muted);
  line-height: 1.65;
}

.lead {
  max-width: 660px;
  font-size: 18px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-art {
  position: relative;
  min-height: 520px;
  display: grid;
  place-items: center;
}

.board-card {
  position: relative;
  width: min(100%, 410px);
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(45, 36, 29, 0.88), rgba(14, 12, 10, 0.92));
  box-shadow: var(--shadow);
}

.board-card img.board {
  width: 100%;
  display: block;
  border-radius: 10px;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.36));
}

.piece-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(8, 7, 6, 0.82);
  color: var(--gold-soft);
  font-size: 13px;
  font-weight: 800;
}

.piece-badge img {
  width: 24px;
  height: 24px;
}

.piece-badge.attack {
  left: -18px;
  top: 36px;
}

.piece-badge.defend {
  right: -18px;
  bottom: 42px;
}

.section {
  padding: 74px 0;
}

.section.alt {
  border-top: 1px solid rgba(219, 184, 116, 0.1);
  border-bottom: 1px solid rgba(219, 184, 116, 0.1);
  background: rgba(255, 255, 255, 0.018);
}

.section-head {
  max-width: 680px;
  margin-bottom: 28px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.card {
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
}

.card strong {
  color: var(--gold-soft);
}

.difficulty-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.difficulty {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  background: var(--panel-strong);
}

.difficulty img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
}

.difficulty div {
  padding: 14px;
}

.policy-page {
  padding: 54px 0 76px;
}

.doc {
  max-width: 880px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(18, 15, 12, 0.86);
  box-shadow: var(--shadow);
}

.doc h1 {
  font-size: clamp(38px, 6vw, 68px);
}

.doc h2 {
  margin-top: 34px;
  font-size: 26px;
}

.doc ul {
  color: var(--muted);
  line-height: 1.7;
}

.footer {
  padding: 32px 0 42px;
  border-top: 1px solid rgba(219, 184, 116, 0.14);
  color: var(--muted-soft);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
}

.footer a {
  color: var(--muted);
}

@media (max-width: 850px) {
  .nav {
    height: auto;
    min-height: 72px;
    padding: 12px 0;
    align-items: flex-start;
  }

  .navlinks {
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px 14px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: 42px;
  }

  .hero-art {
    min-height: auto;
  }

  .piece-badge.attack {
    left: 8px;
  }

  .piece-badge.defend {
    right: 8px;
  }

  .grid,
  .difficulty-grid {
    grid-template-columns: 1fr;
  }

  .doc {
    padding: 24px;
  }
}

@media (max-width: 540px) {
  .shell {
    width: min(100% - 24px, var(--max));
  }

  .brand span {
    display: none;
  }

  .navlinks {
    font-size: 13px;
  }

  .button {
    width: 100%;
  }
}
