/* ===== Variables ===== */
:root {
  --bg-dark: #0a0e17;
  --bg-card: #111827;
  --bg-elevated: #1a2235;
  --gold: #e8b923;
  --gold-soft: #f5d76e;
  --teal: #2dd4bf;
  --coral: #f472b6;
  --white: #f8fafc;
  --muted: #94a3b8;
  --border: rgba(248, 250, 252, 0.08);
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --radius: 16px;
  --radius-sm: 10px;
  --font-head: 'Unbounded', sans-serif;
  --font-body: 'Manrope', sans-serif;
  --safe-top: env(safe-area-inset-top);
  --safe-bottom: env(safe-area-inset-bottom);
}

/* ===== Reset & Base ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--white);
  background: var(--bg-dark);
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
  padding-top: var(--safe-top);
  padding-bottom: var(--safe-bottom);
}

.page {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

/* ===== Header ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  padding-top: calc(14px + var(--safe-top));
  background: linear-gradient(180deg, rgba(10, 14, 23, 0.98) 0%, rgba(10, 14, 23, 0.9) 100%);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-left {
  display: flex;
  align-items: center;
}

.header-logo-img {
  height: 36px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.logo {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--gold);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.header .logo {
  display: none;
}

.btn-register,
.btn-login {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn-register {
  background: linear-gradient(135deg, var(--gold) 0%, #c99a1a 100%);
  color: var(--bg-dark);
}

.btn-login {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}

.btn-register:active,
.btn-login:active {
  transform: scale(0.98);
}

.burger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--white);
}

.burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

.burger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger.is-open span:nth-child(2) {
  opacity: 0;
}

.burger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hide text buttons on very small screens, show burger */
@media (max-width: 360px) {
  .btn-register,
  .btn-login {
    font-size: 0;
    padding: 10px;
    min-width: 44px;
  }

  .btn-register::after {
    content: 'Рег';
    font-size: 0.85rem;
  }

  .btn-login::after {
    content: 'Вход';
    font-size: 0.85rem;
  }
}

/* ===== Promo ===== */
.promo {
  background: linear-gradient(160deg, var(--bg-elevated) 0%, #1e2d47 50%, var(--bg-card) 100%);
  padding: 32px 24px 40px;
  position: relative;
  overflow: hidden;
}

.promo::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 80%;
  height: 120%;
  background: radial-gradient(ellipse, rgba(232, 185, 35, 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.promo-inner {
  position: relative;
  z-index: 1;
  text-align: center;
}

.promo-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.8rem, 6vw, 2.5rem);
  color: var(--white);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.promo-text {
  color: var(--muted);
  font-size: 0.95rem;
  max-width: 320px;
  margin: 0 auto 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  padding: 14px 28px;
  border-radius: var(--radius);
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold) 0%, #c99a1a 100%);
  color: var(--bg-dark);
  box-shadow: 0 4px 20px rgba(232, 185, 35, 0.35);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(232, 185, 35, 0.45);
}

.promo-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
}

.btn-telegram {
  background: linear-gradient(135deg, #0088cc 0%, #006699 100%);
  color: var(--white);
  box-shadow: 0 4px 20px rgba(0, 136, 204, 0.35);
}

.btn-telegram:hover,
.btn-telegram:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(0, 136, 204, 0.45);
}

.btn-support {
  background: linear-gradient(135deg, var(--teal) 0%, #0d9488 100%);
  color: var(--bg-dark);
  margin-top: 16px;
}

/* ===== Sections ===== */
.section {
  padding: 28px 20px 32px;
}

.container {
  max-width: 520px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(1.25rem, 4vw, 1.5rem);
  color: var(--gold);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.section p {
  color: var(--muted);
  margin-bottom: 14px;
  font-size: 0.95rem;
}

.section p:last-of-type {
  margin-bottom: 0;
}

.lead {
  font-size: 1rem;
  line-height: 1.65;
}

.section a,
.lead a {
  color: var(--gold-soft);
  text-decoration: none;
  font-weight: 600;
}

.section a:hover,
.section a:focus-visible,
.lead a:hover,
.lead a:focus-visible {
  color: var(--gold);
  text-decoration: underline;
}

/* ===== Facts list ===== */
.facts-list {
  list-style: none;
  margin-bottom: 20px;
}

.facts-list li {
  padding: 12px 16px;
  margin-bottom: 8px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--gold);
  font-size: 0.9rem;
  color: var(--white);
}

.facts-list strong {
  color: var(--gold-soft);
  margin-right: 6px;
}

.facts-list a {
  color: var(--teal);
  text-decoration: none;
}

.facts-list a:hover,
.facts-list a:focus-visible {
  text-decoration: underline;
}

.intro-note {
  padding: 16px;
  background: rgba(45, 212, 191, 0.08);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(45, 212, 191, 0.2);
  color: var(--teal);
  font-size: 0.95rem;
}

/* ===== Block lists ===== */
.block-list {
  list-style: none;
  margin: 16px 0;
}

.block-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.95rem;
}

.block-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 8px;
  height: 8px;
  background: var(--gold);
  border-radius: 50%;
}

.games-list li::before {
  background: var(--teal);
}

/* ===== Bonus list ===== */
.bonus-list {
  list-style: none;
  margin: 16px 0;
}

.bonus-list li {
  padding: 14px 16px;
  margin-bottom: 10px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--muted);
  border: 1px solid var(--border);
}

.bonus-list strong {
  color: var(--gold-soft);
  display: block;
  margin-bottom: 4px;
}

/* ===== Section backgrounds ===== */
.intro {
  background: var(--bg-dark);
}

.facts {
  background: var(--bg-card);
}

.official {
  background: var(--bg-dark);
}

.mirror {
  background: var(--bg-elevated);
}

.register {
  background: var(--bg-card);
}

.verification {
  background: var(--bg-dark);
}

.mobile {
  background: var(--bg-elevated);
}

.games {
  background: var(--bg-card);
}

.bonuses {
  background: var(--bg-dark);
}

.support {
  background: linear-gradient(180deg, var(--bg-elevated) 0%, #152238 100%);
}

/* ===== Footer ===== */
.footer {
  margin-top: auto;
  padding: 28px 20px;
  padding-bottom: calc(28px + var(--safe-bottom));
  background: var(--bg-dark);
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer-logo {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--gold);
  margin-bottom: 4px;
}

.footer-domain {
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.footer-domain a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 500;
}

.footer-domain a:hover,
.footer-domain a:focus-visible {
  text-decoration: underline;
}

.footer-note {
  color: var(--muted);
  font-size: 0.85rem;
  max-width: 320px;
  margin: 0 auto;
}

/* ===== Overlay menu ===== */
.nav-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 14, 23, 0.96);
  backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.nav-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.nav-links {
  list-style: none;
  text-align: center;
}

.nav-links li {
  margin-bottom: 8px;
}

.nav-links a {
  display: block;
  padding: 16px 32px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--white);
  text-decoration: none;
  border-radius: var(--radius);
  transition: background 0.2s, color 0.2s;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: var(--bg-elevated);
  color: var(--gold);
}

/* ===== Focus & touch ===== */
@media (hover: hover) {
  .btn-register:hover {
    box-shadow: 0 4px 20px rgba(232, 185, 35, 0.4);
  }

  .btn-login:hover {
    color: var(--white);
    border-color: var(--muted);
  }
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* ===== Slight motion reduction ===== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
