:root {
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;
  --green: #35bf3f;
  --green-dark: #0f7f33;
  --gold: #fff000;
  --ink: #102019;
  --muted: #607083;
  --line: #d7dfec;
  --bg: #eef3fb;
  --panel: #ffffff;
  --shadow: 0 24px 70px rgba(26, 45, 74, 0.13);
  --radius: 8px;
  --sidebar: 204px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.5;
}

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

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

button,
input {
  font: inherit;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 20;
  width: var(--sidebar);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-6);
  border-right: 1px solid var(--line);
  background: #f8fbff;
  overflow-y: auto;
}

.side-logo img {
  width: 148px;
  height: 72px;
  object-fit: contain;
  margin-inline: auto;
}

.side-actions,
.side-nav {
  display: grid;
  gap: var(--space-3);
}

.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-6);
  border: 1px solid transparent;
  font-weight: 900;
}

.btn-primary {
  background: var(--green);
  color: #fff;
}

.btn-light {
  border-color: var(--green);
  background: #fff;
  color: var(--green-dark);
}

.btn-white {
  border-color: #fff;
  color: #fff;
}

.side-nav a {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  font-weight: 800;
}

.side-nav a.active,
.side-nav a:hover {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.friend-card {
  display: grid;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #6fffb2, #50d884);
  text-align: center;
  font-weight: 900;
}

.friend-card span {
  justify-self: start;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius);
  background: #ff1e1e;
  color: #fff;
  font-size: 12px;
}

.friend-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
}

.side-note {
  margin: auto 0 0;
  color: var(--muted);
  font-size: 13px;
}

.mobile-header {
  display: none;
}

.bottom-casino-nav {
  display: none;
}

.scroll-popup {
  position: fixed;
  right: var(--space-6);
  bottom: var(--space-6);
  z-index: 40;
  width: min(380px, calc(100% - var(--space-8)));
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: var(--space-4);
  align-items: center;
  padding: var(--space-4);
  border: 1px solid rgba(53, 191, 63, 0.35);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 24px 70px rgba(8, 19, 15, 0.28);
}

.scroll-popup[hidden] {
  display: none;
}

.scroll-popup img {
  width: 112px;
  aspect-ratio: 1;
  object-fit: contain;
}

.scroll-popup span {
  display: block;
  margin-bottom: var(--space-1);
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.scroll-popup strong {
  display: block;
  margin-bottom: var(--space-2);
  font-size: 20px;
  line-height: 1.2;
}

.scroll-popup p {
  margin: 0 0 var(--space-4);
  color: var(--muted);
  font-size: 14px;
}

.popup-close {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: #eef3fb;
  color: var(--ink);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.casino-shell {
  width: calc(100% - var(--sidebar));
  margin-left: var(--sidebar);
  padding: var(--space-6);
}

.hero-banner {
  position: relative;
  min-height: 310px;
  overflow: hidden;
  border-radius: var(--radius);
  background: #18271d;
  box-shadow: var(--shadow);
}

.hero-banner > img {
  width: 100%;
  height: 100%;
  min-height: 310px;
  object-fit: cover;
  object-position: center;
}

.hero-offer {
  position: absolute;
  top: var(--space-8);
  right: var(--space-8);
  width: min(420px, calc(100% - var(--space-16)));
  padding: var(--space-8);
  border-radius: var(--radius) var(--radius) var(--radius) 64px;
  background: var(--green);
  color: #fff;
}

.hero-offer span,
.section-title span,
.cashier-card > span,
.steps-card > span,
.mobile-section span {
  display: block;
  margin-bottom: var(--space-2);
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.hero-offer span {
  color: #eaffeb;
}

.hero-offer h1,
.section-title h2,
.cashier-card h2,
.steps-card h2,
.mobile-section h2 {
  margin: 0 0 var(--space-6);
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.15;
}

.hero-offer p {
  margin: 0 0 var(--space-6);
}

.lobby-panel,
.section {
  margin-top: var(--space-8);
}

.category-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: var(--space-3);
}

.category-row button,
.load-more-games {
  min-height: 52px;
  border: 0;
  border-radius: var(--radius);
  background: #fff;
  color: #50627a;
  font-weight: 800;
}

.category-row button.active,
.category-row button:hover,
.load-more-games {
  background: var(--green);
  color: #fff;
}

.tool-row {
  display: block;
  margin-block: var(--space-8);
}

.search-box {
  width: min(100%, 320px);
  display: grid;
  gap: var(--space-2);
}

.search-box span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.search-box input {
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-4);
  background: #fff;
}

.lobby-copy {
  display: grid;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
  padding: var(--space-6);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 10px 22px rgba(26, 45, 74, 0.06);
}

.lobby-copy h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
}

.lobby-copy p,
.cashier-card p,
.steps-card p,
.mobile-section p {
  margin: 0;
  color: var(--muted);
}

.game-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--space-4);
}

.load-more-games {
  display: none;
  width: 100%;
  margin: var(--space-6) 0 var(--space-8);
  font-weight: 900;
}

.steps-card .btn,
.cashier-card .btn,
.mobile-section .btn {
  margin-top: var(--space-6);
}

.game-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 10px 22px rgba(26, 45, 74, 0.08);
}

.game-card[hidden] {
  display: none;
}

.game-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.game-card span {
  position: absolute;
  top: 0;
  right: var(--space-3);
  padding: var(--space-2);
  border-radius: 0 0 var(--radius) var(--radius);
  background: #0ea5e9;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.game-card strong {
  display: block;
  padding: var(--space-3) var(--space-4);
}

.game-card a {
  position: absolute;
  inset: auto var(--space-4) var(--space-4);
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background: rgba(53, 191, 63, 0.94);
  color: #fff;
  font-weight: 900;
  opacity: 0;
  transform: translateY(var(--space-3));
  transition: 0.2s ease;
}

.game-card:hover a {
  opacity: 1;
  transform: translateY(0);
}

.section-title {
  margin-bottom: var(--space-8);
}

.section-title p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
}

.bonus-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
}

.bonus-card {
  display: flex;
  min-height: 620px;
  flex-direction: column;
  overflow: hidden;
  border: 2px solid var(--green-dark);
  border-radius: var(--radius);
  background: #fff;
}

.bonus-card.featured {
  box-shadow: 0 0 0 4px rgba(53, 191, 63, 0.16), var(--shadow);
}

.bonus-top {
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  background: #eef1ed;
  color: #004417;
  font-size: 13px;
  font-weight: 900;
}

.bonus-top b {
  color: var(--green-dark);
}

.bonus-card h3 {
  min-height: 72px;
  margin: 0;
  padding: var(--space-4);
  border-bottom: 2px solid var(--green-dark);
  text-align: center;
  text-transform: uppercase;
}

.bonus-card > img {
  width: 100%;
  height: 220px;
  object-fit: contain;
  padding: var(--space-4);
}

.bonus-info {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-4);
  text-align: center;
}

.bonus-info p {
  margin: 0;
}

.bonus-info dl {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
  margin: 0;
}

.bonus-info div {
  padding: var(--space-3);
  border-radius: var(--radius);
  background: #eef9f0;
}

.bonus-info dt {
  color: var(--muted);
  font-size: 12px;
}

.bonus-info dd {
  margin: 0;
  font-weight: 900;
}

.btn-bonus {
  width: min(220px, calc(100% - var(--space-8)));
  margin: auto auto var(--space-4);
  background: var(--gold);
  color: #001d0a;
  text-transform: uppercase;
}

.split-section {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: var(--space-8);
}

.cashier-card,
.steps-card,
.mobile-section,
.faq-section,
.footer {
  padding: var(--space-8);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.pay-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
  margin-top: var(--space-8);
}

.pay-grid img {
  height: 64px;
  width: 100%;
  object-fit: contain;
  padding: var(--space-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.steps-card ol {
  display: grid;
  gap: var(--space-4);
  margin: 0 0 var(--space-8);
  padding-left: var(--space-6);
}

.mobile-section {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: var(--space-8);
  align-items: center;
}

.mobile-section > img {
  width: 100%;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

details {
  padding: var(--space-6);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

summary {
  cursor: pointer;
  font-weight: 900;
}

details p {
  margin: var(--space-4) 0 0;
  color: var(--muted);
}

.footer {
  display: grid;
  grid-template-columns: 160px 1fr auto;
  gap: var(--space-8);
  align-items: center;
  background:
    radial-gradient(circle at 15% 20%, rgba(53, 191, 63, 0.16), transparent 32%),
    linear-gradient(135deg, #08130f, #11231a);
  color: #fff;
}

.footer > img {
  width: 160px;
}

.footer p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
}

.footer div {
  display: flex;
  gap: var(--space-3);
}

.footer div img {
  width: 104px;
  height: 40px;
  object-fit: contain;
  padding: var(--space-2);
  border-radius: var(--radius);
  background: #102019;
}

@media (max-width: 1180px) {
  .game-grid {
    grid-template-columns: repeat(3, 1fr);
  }

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

  .category-row {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 860px) {
  :root {
    --space-6: 16px;
    --space-8: 24px;
    --space-12: 40px;
    --sidebar: 0px;
  }

  .sidebar {
    display: none;
  }

  .mobile-header {
    position: sticky;
    top: 0;
    z-index: 20;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    padding: var(--space-3) var(--space-4);
    border-bottom: 1px solid var(--line);
    background: #f8fbff;
  }

  .mobile-header-actions {
    display: flex;
    gap: var(--space-2);
  }

  .mobile-header-actions .btn {
    min-height: 44px;
    padding: var(--space-2) var(--space-3);
    font-size: 13px;
    white-space: nowrap;
  }

  .mobile-header img {
    width: 112px;
    height: 56px;
    object-fit: contain;
  }

  .casino-shell {
    width: 100%;
    margin-left: 0;
    padding: var(--space-4) var(--space-4) 112px;
  }

  .bottom-casino-nav {
    position: fixed;
    left: var(--space-3);
    right: var(--space-3);
    bottom: var(--space-3);
    z-index: 30;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: var(--space-2);
    padding: var(--space-2);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius);
    background: rgba(8, 19, 15, 0.94);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(14px);
  }

  .scroll-popup {
    left: var(--space-3);
    right: var(--space-3);
    bottom: 96px;
    width: auto;
    grid-template-columns: 88px 1fr;
    padding: var(--space-3);
  }

  .scroll-popup img {
    width: 88px;
  }

  .scroll-popup strong {
    font-size: 17px;
  }

  .bottom-casino-nav a {
    min-height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: var(--space-1);
    border-radius: var(--radius);
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
    font-weight: 900;
  }

  .bottom-casino-nav span {
    color: var(--gold);
    font-size: 16px;
    line-height: 1;
  }

  .bottom-casino-nav a.active,
  .bottom-casino-nav a:hover {
    background: var(--green);
    color: #fff;
  }

  .bottom-casino-nav a.active span,
  .bottom-casino-nav a:hover span {
    color: #fff;
  }

  .hero-offer {
    position: static;
    width: 100%;
    border-radius: var(--radius);
  }

  .hero-banner > img {
    min-height: 260px;
    object-position: 36% center;
  }

  .category-row {
    display: flex;
    overflow-x: auto;
    gap: var(--space-3);
    padding-bottom: var(--space-2);
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
  }

  .category-row button {
    min-width: 156px;
    scroll-snap-align: start;
  }

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

  .bonus-grid,
  .split-section,
  .mobile-section,
  .faq-grid,
  .footer {
    grid-template-columns: 1fr;
  }

  .game-card img {
    aspect-ratio: 1 / 0.82;
  }

  .game-card strong {
    min-height: 56px;
    padding: var(--space-3);
    font-size: 14px;
    line-height: 1.25;
  }

  .game-card a {
    position: static;
    min-height: 40px;
    margin: 0 var(--space-3) var(--space-3);
    opacity: 1;
    transform: none;
  }

  .load-more-games {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-8);
  }

  .search-box {
    width: 100%;
  }

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

  .bonus-card {
    min-height: auto;
  }
}
