:root {
  /* App brand — icon / in-game palette */
  --bg-top: #1a1450;
  --bg-mid: #141b3d;
  --bg-bottom: #070a1c;
  --glow: #5b4bd6;
  --teal: #12c9b9;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --pink: #ec4899;
  --orange: #fb8a2e;
  --text: #f4f7ff;
  --muted: rgba(196, 210, 255, 0.72);
  --link: #9bd4ff;
  --border: rgba(139, 92, 246, 0.38);
  --card: rgba(255, 255, 255, 0.055);
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --font-display: "Rubik", "Heebo", system-ui, sans-serif;
  --font-body: "Rubik", "Heebo", system-ui, sans-serif;
  --radius: 18px;
  --max: 1080px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.55;
  background:
    radial-gradient(ellipse 90% 55% at 50% -10%, rgba(91, 75, 214, 0.35), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 20%, rgba(236, 72, 153, 0.12), transparent 50%),
    radial-gradient(ellipse 40% 35% at 0% 60%, rgba(18, 201, 185, 0.1), transparent 45%),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 42%, var(--bg-bottom) 100%);
  background-attachment: fixed;
}

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: #fff; }

img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }

/* ── Site chrome ── */
.site-header {
  position: absolute;
  inset-inline: 0;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(16px, 4vw, 40px);
  pointer-events: none;
}
.site-header a,
.site-header .brand-mark,
.site-header button {
  pointer-events: auto;
}

.brand-mark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: #fff;
  text-decoration: none;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.55);
}

.header-end {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 16px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(7, 10, 28, 0.45);
  border: 1px solid rgba(155, 212, 255, 0.28);
  backdrop-filter: blur(10px);
}

.lang-btn {
  appearance: none;
  margin: 0;
  padding: 4px 8px;
  border: none;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  line-height: 1;
  opacity: 0.55;
  transition: opacity 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.lang-btn:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.lang-btn.is-active {
  opacity: 1;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 0 0 1px rgba(251, 138, 46, 0.45);
}
.lang-flag {
  font-size: 1.25rem;
  display: block;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 14px;
}
.site-nav a {
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 500;
  padding: 6px 2px;
}
.site-nav a:hover { color: #fff; }

/* ── Landing hero ── */
.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  overflow: hidden;
}

.hero-media {
  position: relative;
  z-index: 0;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px clamp(12px, 3vw, 28px) 12px;
  min-height: 0;
}
.hero-media img {
  width: min(1120px, 100%);
  height: auto;
  max-height: min(62svh, 560px);
  object-fit: contain;
  border-radius: 20px;
  box-shadow:
    0 0 0 1px rgba(139, 92, 246, 0.28),
    0 28px 80px rgba(0, 0, 0, 0.55),
    0 0 80px rgba(91, 75, 214, 0.22);
  animation: heroRise 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-scrim {
  display: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(var(--max), 100%);
  margin: 0 auto;
  padding: 8px clamp(16px, 4vw, 40px) clamp(24px, 4vw, 40px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: heroRise 0.85s 0.08s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-kicker {
  margin: 0;
  font-size: clamp(0.95rem, 2.2vw, 1.15rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
  max-width: 36ch;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.55);
}

.store-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.btn-icon {
  width: 1.15em;
  height: 1.15em;
  flex: 0 0 auto;
  display: block;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff9b3d 0%, var(--orange) 55%, #e86a12 100%);
  color: #1a0a00;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  border: none;
  box-shadow:
    0 10px 28px rgba(251, 138, 46, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.btn:hover {
  color: #1a0a00;
  transform: translateY(-2px);
  filter: brightness(1.05);
  box-shadow:
    0 16px 36px rgba(251, 138, 46, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}
.btn:active { transform: translateY(0); }

.btn-secondary {
  background: rgba(20, 27, 61, 0.55);
  color: #fff;
  border: 1.5px solid rgba(155, 212, 255, 0.45);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
}
.btn-secondary:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.7);
  filter: none;
}

.tower-strip {
  display: flex;
  gap: 6px;
  height: 8px;
  width: min(220px, 55vw);
  border-radius: 999px;
  overflow: hidden;
  box-shadow: 0 0 24px rgba(91, 75, 214, 0.35);
}
.tower-strip span {
  flex: 1;
  display: block;
}
.tower-strip span:nth-child(1) { background: var(--teal); }
.tower-strip span:nth-child(2) { background: var(--blue); }
.tower-strip span:nth-child(3) { background: var(--purple); }
.tower-strip span:nth-child(4) { background: var(--pink); }
.tower-strip span:nth-child(5) { background: var(--orange); }

.site-footer {
  width: min(var(--max), 100%);
  margin: 0 auto;
  padding: 8px clamp(16px, 4vw, 40px) 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 0.9rem;
  animation: heroRise 1s 0.12s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: #fff; }

@keyframes heroRise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-content,
  .site-footer,
  .btn { animation: none; transition: none; }
}

/* ── Inner / legal pages ── */
.wrap {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: 36px clamp(16px, 4vw, 28px) 72px;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  margin: 0 0 4px;
  color: #fff;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin: 18px 0 28px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.nav a {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 0.92rem;
}
.nav a:hover { color: #fff; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(18px, 3vw, 28px);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  font-weight: 800;
  margin: 0 0 12px;
  color: #fff;
}
h2 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 700;
  margin: 26px 0 8px;
  color: var(--orange);
}
p, li { color: var(--muted); }
.muted { color: var(--muted); font-size: 0.92rem; }

.hero-code {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 5vw, 2.2rem);
  font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--orange);
  margin: 12px 0 20px;
  text-align: center;
  text-shadow: 0 0 28px rgba(251, 138, 46, 0.35);
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}
.actions .btn { width: 100%; text-align: center; }

[dir="rtl"] .wrap,
[dir="rtl"] .hero-content { text-align: right; }
[dir="ltr"] .wrap,
[dir="ltr"] .hero-content { text-align: left; }

[dir="rtl"] .header-end,
[dir="rtl"] .site-nav { justify-content: flex-start; }
[dir="ltr"] .header-end,
[dir="ltr"] .site-nav { justify-content: flex-end; }

@media (max-width: 640px) {
  .hero-media {
    padding-top: 58px;
    padding-bottom: 4px;
  }
  .hero-media img {
    max-height: min(48svh, 420px);
    border-radius: 14px;
  }
  .site-header { padding-top: 14px; }
  .brand-mark { font-size: 0.95rem; }
  .site-nav a { font-size: 0.78rem; }
  .store-cta { width: 100%; }
  .store-cta .btn { flex: 1 1 140px; }
}
