:root {
  color-scheme: dark;
  --bg: #101114;
  --surface: #181b20;
  --surface-2: #22262d;
  --text: #f6efe1;
  --muted: #c8bca8;
  --gold: #f4bd45;
  --amber: #e26b2f;
  --red: #a83232;
  --blue: #497fb9;
  --green: #739f5a;
  --line: rgba(246, 239, 225, 0.16);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Arial, sans-serif;
  line-height: 1.6;
}

img {
  display: block;
  max-width: 100%;
}

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

.site-header {
  position: fixed;
  z-index: 10;
  top: 0;
  right: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  padding: 12px clamp(18px, 4vw, 56px);
  background: rgba(16, 17, 20, 0.78);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand-lockup {
  display: flex;
  gap: clamp(14px, 2vw, 24px);
  align-items: center;
  min-width: 0;
}

.brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  width: clamp(150px, 18vw, 230px);
}

.brand-credit {
  max-width: 270px;
  margin: 0;
  padding-left: clamp(12px, 1.5vw, 18px);
  color: rgba(200, 188, 168, 0.8);
  border-left: 1px solid rgba(244, 189, 69, 0.46);
  font-size: clamp(10px, 0.9vw, 12px);
  font-weight: 600;
  letter-spacing: 0.025em;
  line-height: 1.45;
}

.nav-links {
  display: flex;
  gap: clamp(14px, 3vw, 34px);
  align-items: center;
  color: var(--muted);
  font-size: 15px;
}

.nav-links a {
  padding: 8px 0;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--gold);
}

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: max(84svh, calc(100vw * 1290 / 2796));
  padding: 118px clamp(20px, 6vw, 72px) 64px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(7, 8, 10, 0.88) 0%, rgba(7, 8, 10, 0.52) 46%, rgba(7, 8, 10, 0.1) 100%),
    linear-gradient(0deg, rgba(16, 17, 20, 1) 0%, rgba(16, 17, 20, 0) 26%),
    url("assets/hero-bg.jpg");
  background-color: #090a0c;
  background-position:
    center,
    center bottom,
    center;
  background-repeat: no-repeat;
  background-size:
    cover,
    cover,
    100% auto;
}

.hero-copy {
  width: min(760px, 100%);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: 88px;
  line-height: 0.95;
}

.hero h1 {
  overflow-wrap: normal;
  white-space: nowrap;
}

h2 {
  margin: 0;
  font-size: clamp(30px, 5vw, 58px);
  line-height: 1.12;
}

h3 {
  margin: 0 0 10px;
  font-size: 22px;
  line-height: 1.2;
}

.hero-subtitle {
  width: min(670px, 100%);
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(18px, 2.2vw, 24px);
}

.hero-actions,
.download-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.store-button {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-width: 178px;
  min-height: 64px;
  padding: 10px 18px;
  color: #fff7e8;
  background: var(--surface-2);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.store-button span {
  font-size: 12px;
  color: rgba(255, 247, 232, 0.78);
}

.store-button strong {
  font-size: 21px;
  line-height: 1.1;
}

.store-button.primary {
  background: linear-gradient(135deg, var(--red), var(--amber));
}

.store-button.discord {
  background: linear-gradient(135deg, #34418f, var(--blue));
}

.store-button:hover,
.store-button:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(244, 189, 69, 0.75);
}

.section {
  padding: clamp(68px, 9vw, 118px) clamp(20px, 6vw, 72px);
}

.section-heading {
  max-width: 850px;
  margin-bottom: 38px;
}

.intro-section {
  background:
    linear-gradient(180deg, #101114 0%, #15191e 100%);
  border-top: 1px solid var(--line);
}

.intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(360px, 1.22fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}

.intro-copy {
  color: var(--muted);
  font-size: clamp(17px, 1.6vw, 20px);
}

.intro-copy p {
  margin: 0 0 20px;
}

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

.feature-card,
.battle-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: var(--shadow);
}

.feature-card {
  min-height: 172px;
  padding: 22px;
}

.feature-card p,
.battle-card p,
.commander-copy p,
.download-inner p {
  margin: 0;
  color: var(--muted);
}

.battles-section {
  background: #11171a;
}

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

.battle-card {
  overflow: hidden;
  background: var(--surface);
}

.battle-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #050607;
}

.battle-card div {
  padding: 20px;
}

.commander-section {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: center;
  background:
    linear-gradient(120deg, rgba(115, 159, 90, 0.14), rgba(226, 107, 47, 0.08)),
    #151617;
}

.commander-media {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.commander-media img {
  width: 100%;
  aspect-ratio: 1622 / 750;
  object-fit: cover;
}

.commander-copy p {
  margin-top: 22px;
  font-size: 18px;
}

.check-list {
  display: grid;
  gap: 12px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 28px;
  color: #f4ead8;
}

.check-list li::before {
  position: absolute;
  top: 0;
  left: 0;
  color: var(--gold);
  content: "✓";
}

.download-section {
  min-height: max(420px, calc(100vw * 1290 / 2796));
  padding: clamp(78px, 11vw, 142px) clamp(20px, 6vw, 72px);
  background:
    linear-gradient(90deg, rgba(16, 17, 20, 0.92), rgba(16, 17, 20, 0.44)),
    url("assets/download-bg.jpg");
  background-color: #081112;
  background-position:
    center,
    center;
  background-repeat: no-repeat;
  background-size:
    cover,
    100% auto;
}

.download-inner {
  width: min(760px, 100%);
}

.download-inner p {
  margin-top: 18px;
  font-size: 18px;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 28px 20px;
  color: var(--muted);
  background: #090a0c;
  border-top: 1px solid var(--line);
  text-align: center;
}

.site-footer img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.site-footer p {
  margin: 0;
  font-size: 14px;
}

.footer-copy {
  display: grid;
  gap: 5px;
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  color: rgba(200, 188, 168, 0.84);
  font-size: 13px;
}

.legal-links a {
  text-decoration: underline;
  text-decoration-color: rgba(244, 189, 69, 0.38);
  text-underline-offset: 3px;
}

.legal-links a:hover,
.legal-links a:focus-visible {
  color: var(--gold);
  text-decoration-color: currentColor;
}

/* Legal pages */
.legal-page {
  background:
    radial-gradient(circle at 80% 0%, rgba(226, 107, 47, 0.1), transparent 30rem),
    var(--bg);
}

.legal-page .site-header {
  position: sticky;
}

.legal-page .nav-links a[aria-current="page"] {
  color: var(--gold);
}

.legal-hero {
  padding: clamp(58px, 8vw, 96px) clamp(20px, 6vw, 72px) clamp(46px, 6vw, 72px);
  background:
    linear-gradient(90deg, rgba(9, 10, 12, 0.96), rgba(9, 10, 12, 0.7)),
    url("assets/download-bg.jpg") center 44% / cover;
  border-bottom: 1px solid var(--line);
}

.legal-hero-inner {
  width: min(1120px, 100%);
  margin: 0 auto;
}

.legal-hero h1 {
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1;
}

.legal-deck {
  width: min(760px, 100%);
  margin: 20px 0 0;
  color: var(--muted);
  font-size: clamp(17px, 1.7vw, 20px);
}

.legal-date {
  display: inline-flex;
  margin: 24px 0 0;
  padding: 7px 12px;
  color: #f4ead8;
  background: rgba(244, 189, 69, 0.1);
  border: 1px solid rgba(244, 189, 69, 0.28);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.legal-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 800px);
  gap: clamp(36px, 6vw, 80px);
  justify-content: center;
  align-items: start;
  padding: clamp(50px, 7vw, 88px) clamp(20px, 6vw, 72px) clamp(72px, 9vw, 120px);
}

.legal-toc {
  position: sticky;
  top: 104px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.legal-toc strong {
  display: block;
  margin-bottom: 12px;
  color: var(--text);
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.legal-toc ol {
  display: grid;
  gap: 7px;
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.legal-toc a:hover,
.legal-toc a:focus-visible {
  color: var(--gold);
}

.legal-content {
  min-width: 0;
}

.legal-notice {
  margin: 0 0 40px;
  padding: 20px 22px;
  color: #e9deca;
  background: rgba(73, 127, 185, 0.1);
  border: 1px solid rgba(73, 127, 185, 0.34);
  border-left: 3px solid var(--blue);
  border-radius: 6px;
}

.legal-content section {
  scroll-margin-top: 110px;
  padding: 0 0 38px;
}

.legal-content section + section {
  padding-top: 38px;
  border-top: 1px solid var(--line);
}

.legal-content h2 {
  margin: 0 0 20px;
  color: var(--text);
  font-size: clamp(25px, 3vw, 34px);
  line-height: 1.2;
}

.legal-content h3 {
  margin: 24px 0 10px;
  color: #f1dfbc;
  font-size: 18px;
}

.legal-content p,
.legal-content li {
  color: var(--muted);
}

.legal-content p {
  margin: 0 0 16px;
}

.legal-content ul,
.legal-content ol {
  display: grid;
  gap: 9px;
  margin: 0 0 18px;
  padding-left: 24px;
}

.legal-content a {
  color: #f5ca70;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-content strong {
  color: #f4ead8;
}

.legal-content .all-caps {
  color: #e9deca;
  font-size: 14px;
  letter-spacing: 0.015em;
}

.contact-card {
  display: grid;
  gap: 7px;
  margin-top: 18px;
  padding: 20px 22px;
  background: rgba(244, 189, 69, 0.07);
  border: 1px solid rgba(244, 189, 69, 0.24);
  border-radius: 8px;
}

.contact-card p {
  margin: 0;
}

.contact-followup {
  margin-top: 18px !important;
}

@media (max-width: 980px) {
  h1 {
    font-size: 72px;
  }

  .intro-grid,
  .commander-section {
    grid-template-columns: 1fr;
  }

  .battle-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .legal-layout {
    grid-template-columns: 1fr;
  }

  .legal-toc {
    position: static;
  }

  .legal-toc ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  h1 {
    font-size: 52px;
  }

  .site-header {
    position: absolute;
    align-items: flex-start;
    min-height: 92px;
  }

  .brand {
    width: 142px;
  }

  .brand-lockup {
    gap: 12px;
  }

  .brand-credit {
    max-width: 180px;
    padding-left: 12px;
    font-size: 9px;
  }

  .nav-links {
    gap: 12px;
    font-size: 13px;
  }

  .hero {
    min-height: max(86svh, calc(100vw * 1290 / 2796));
    padding-top: 118px;
    padding-bottom: 48px;
    background-position:
      center,
      center bottom,
      center;
  }

  .hero-actions,
  .download-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .store-button {
    width: 100%;
  }

  .feature-list,
  .battle-grid {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-direction: column;
  }

  .legal-page .site-header {
    position: relative;
    min-height: 92px;
  }

  .legal-page .nav-links {
    align-items: flex-end;
    flex-direction: column;
    gap: 2px;
  }

  .legal-hero {
    padding-top: 54px;
  }

  .legal-toc ol {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  h1 {
    font-size: 42px;
  }

  .site-header {
    min-height: 122px;
  }

  .brand-lockup {
    display: grid;
    gap: 7px;
  }

  .brand {
    width: 132px;
  }

  .brand-credit {
    max-width: 150px;
    padding: 5px 0 0;
    border-top: 1px solid rgba(244, 189, 69, 0.46);
    border-left: 0;
    font-size: 8.5px;
    line-height: 1.35;
  }

  .hero {
    padding-top: 148px;
  }

  .legal-page .site-header {
    min-height: 122px;
  }
}

@media (max-width: 420px) {
  h1 {
    font-size: 34px;
  }
}

@media (max-width: 360px) {
  h1 {
    font-size: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
