:root {
  --bg: #0a0804;
  --card: #14110a;
  --gold: #f2c94c;
  --gold-2: #c9962a;
  --gold-grad: linear-gradient(180deg, #fff1b8, #f2c94c 45%, #b7801d);
  --text: #fff;
  --muted: #c9bfa4;
  --line: rgba(242, 201, 76, .35);
  --app-width: 500px;
  --nav-height: 64px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: "Segoe UI", Arial, Helvetica, sans-serif; background: #000; color: var(--text); -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
img { display: block; max-width: 100%; height: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }

.app {
  display: block;
  max-width: var(--app-width);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  padding-bottom: calc(var(--nav-height) + 24px + env(safe-area-inset-bottom));
  overflow-x: hidden;
}

/* ---------- Top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 30; display: grid; grid-template-columns: 52px 1fr 52px; align-items: center; padding: 4px 10px; min-height: 60px; background: radial-gradient(60% 120% at 50% 0%, #3a2c0c, #000 70%); }
.menu-btn img { width: 44px; height: auto; }
.logo { justify-self: center; }
.logo img { height: 50px; width: auto; }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; background: #000; color: var(--gold); border-bottom: 1px solid #1d1708; }
.mq { overflow: hidden; white-space: nowrap; }
.mq span { display: inline-block; padding: 5px 0 5px 30%; font-size: 13.5px; font-weight: 700; animation: marquee 45s linear infinite; }
@keyframes marquee { to { transform: translateX(-100%); } }

/* ---------- Carousel ---------- */
.carousel { position: relative; }
.carousel-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.carousel-track::-webkit-scrollbar { display: none; }
.slide { flex: 0 0 100%; min-width: 0; scroll-snap-align: start; aspect-ratio: 5 / 2; overflow: hidden; }
.slide img { width: 100%; height: 100%; max-width: none; object-fit: cover; }
.carousel-dots { position: absolute; bottom: 0; left: 0; right: 0; display: flex; justify-content: center; flex-wrap: wrap; }
.carousel-dots button { width: 18px; height: 22px; padding: 7.5px 5.5px; border-radius: 50%; background-color: rgba(255, 255, 255, .5); background-clip: content-box; }
.carousel-dots button.active { background-color: var(--gold); }

/* ---------- Login / Register ---------- */
.auth { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; align-items: center; margin: 14px 10px 0; }
.auth img { width: 100%; }

/* ---------- Quick links ---------- */
.quick { display: flex; gap: 8px; overflow-x: auto; padding: 14px 10px 2px; scrollbar-width: none; scroll-snap-type: x proximity; }
.quick::-webkit-scrollbar { display: none; }
.quick a { flex: 0 0 31%; min-width: 0; scroll-snap-align: start; }
.quick img { width: 100%; border-radius: 8px; }

/* ---------- Hot matches ---------- */
.match { display: block; margin: 0 10px; padding: 12px; border-radius: 12px; border: 1.5px solid var(--gold-2); background: linear-gradient(180deg, #1a150a, #0a0804); text-align: center; }
.match-tag { display: inline-block; padding: 3px 10px; border-radius: 10px; background: var(--gold-grad); color: #2a1d00; font-size: 11px; font-weight: 800; }
.match-body { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin: 10px 0 8px; }
.match-side { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 13px; font-weight: 800; }
.crest { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: #2a2210; font-size: 20px; }
.match-vs { font-size: 20px; font-weight: 900; color: var(--gold); }
.match-odds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.match-odds b { padding: 7px 0; border-radius: 6px; background: #2b2b2b; font-size: 13px; }
.match-text { display: block; margin-top: 8px; font-size: 12.5px; color: var(--muted); }

/* ---------- Referral ---------- */
.referral { display: flex; margin: 14px 10px 0; border: 1.5px solid var(--gold-2); border-radius: 10px; overflow: hidden; background: #14110a; }
.ref-title { flex: 0 0 32%; display: flex; flex-direction: column; justify-content: center; padding: 10px; }
.ref-title b { font-size: 18px; color: var(--gold); letter-spacing: .5px; }
.ref-title small { font-size: 9.5px; font-weight: 700; color: var(--muted); }
.ref-actions { flex: 1; min-width: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ref-actions > * { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 10px 2px; font-size: 10px; font-weight: 700; color: var(--muted); border-left: 1px solid #2a2210; white-space: nowrap; }
.ref-actions img { width: 26px; height: 26px; }

/* ---------- Games ---------- */
.block { margin-top: 16px; }
.head { padding: 0 10px 8px; font-size: 15px; font-weight: 800; }
.hscroll { display: flex; gap: 10px; overflow-x: auto; padding: 0 10px 4px; scroll-snap-type: x proximity; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }
.hot { flex: 0 0 31%; min-width: 0; scroll-snap-align: start; }
.hot img { width: 100%; aspect-ratio: 300 / 335; object-fit: cover; border-radius: 10px; }
.g-name { display: block; margin-top: 4px; font-size: 12px; font-weight: 700; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-meta { display: flex; align-items: center; justify-content: space-between; gap: 4px; margin-top: 2px; }
.g-prov { font-size: 10px; color: var(--muted); text-transform: uppercase; }
.rtp { flex-shrink: 0; padding: 2px 8px; border-radius: 10px; background: var(--gold-grad); color: #2a1d00; font-size: 11px; font-weight: 800; }
.rtp.play { display: block; margin: 6px auto 0; width: 80%; text-align: center; padding: 5px; font-size: 13px; }
.new-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 0 10px; }
.new-card { display: block; padding: 6px; border-radius: 10px; background: #fff; color: #1a1a1a; border: 2px solid var(--gold); }
.new-card img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; }
.new-card b { display: block; margin-top: 6px; font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.new-card > span:not(.rtp) { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase; }
.rtp.wide { display: block; margin-top: 6px; text-align: center; }

/* Category menu on the left, provider grid on the right. */
.games { display: grid; grid-template-columns: 20% minmax(0, 1fr); gap: 8px; align-items: start; padding: 0 10px; }
.cat-col { position: sticky; top: 70px; display: grid; gap: 6px; }
.cat { display: block; }
.cat img { width: 100%; }
.cat .a, .cat.on .n { display: none; }
.cat.on .a { display: block; }
.cat:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 10px; }
.prov-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.prov { display: block; }
.prov[hidden] { display: none; }
.prov img { width: 100%; aspect-ratio: 180 / 228; object-fit: cover; border-radius: 8px; }
.hot, .new-card, .prov, .quick a, .auth a { transition: transform .1s; }
.hot:active, .new-card:active, .prov:active, .quick a:active, .auth a:active { transform: scale(.97); }

/* ---------- Keyword text ---------- */
.seo { margin: 20px 10px 0; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); font-size: 14px; line-height: 1.6; color: #e6dcc3; }
.seo h1 { font-size: 17px; color: var(--gold); margin-bottom: 8px; }
.seo h2 { font-size: 16px; color: var(--gold); margin: 16px 0 6px; }
.seo h3 { font-size: 14px; color: #fff; margin: 12px 0 4px; }
.seo a { color: var(--gold); text-decoration: underline; }
.seo ol, .seo ul { padding-left: 20px; }
.seo li { margin-bottom: 6px; }
.seo b { color: #fff; }
.guide { margin-top: 14px; }
.guide .crumbs { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.guide .crumbs a { color: var(--muted); text-decoration: none; }
.guide-auth { margin: 18px 0 4px; }
.faq-list { display: grid; gap: 10px; margin: 14px 0; }
.faq-list details { border: 1px solid var(--line); border-radius: 12px; background: #0a0804; }
.faq-list summary { padding: 14px 16px; font-weight: 700; color: #fff; cursor: pointer; list-style: none; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; float: right; color: var(--gold); }
.faq-list details[open] summary::after { content: "−"; }
.faq-list details p { padding: 0 16px 14px; }
.table-wrap { overflow-x: auto; margin: 10px 0; }
.seo table { width: 100%; border-collapse: collapse; font-size: 13px; }
.seo th { background: var(--gold-grad); color: #2a1d00; text-align: left; padding: 8px; }
.seo td { padding: 8px; border: 1px solid var(--line); vertical-align: top; }

/* Long sections fold to a preview; collapse.js adds the toggle button. */
.collapsible { position: relative; max-height: 260px; overflow: hidden; }
.collapsible:not(.open)::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(rgba(20, 17, 10, 0), var(--card)); pointer-events: none; }
.collapsible.open { max-height: none; }
.toggle-btn { display: block; margin: 12px auto 0; padding: 10px 44px; border-radius: 22px; background: var(--gold-grad); color: #2a1d00; font-size: 14px; font-weight: 800; }

/* ---------- Guide card grid ---------- */
.guide-grid-wrap { margin-top: 22px; }
.home-grid { margin: 20px 10px 0; }
.guide-grid-title, .seo .guide-grid-title { margin: 0 0 12px; font-size: 18px; font-weight: 800; color: var(--gold); }
.guide-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.guide-grid a, .seo .guide-grid a { display: block; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); text-decoration: none; transition: border-color .15s; }
.seo .guide-grid a { background: #0a0804; }
.guide-grid a:hover { border-color: var(--gold); }
.guide-grid b { display: block; font-size: 15px; color: var(--gold); }
.guide-grid span { display: block; margin-top: 4px; font-size: 12.5px; line-height: 1.35; color: var(--muted); }

/* ---------- Footer ---------- */
.footer { padding: 20px 10px 10px; }
.card { padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); }
.foot-logo { height: 46px; width: auto; margin-bottom: 8px; }
.footer h3 { margin: 14px 0 6px; font-size: 14px; font-weight: 800; color: var(--gold); }
.footer p { font-size: 12.5px; }
.icons { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 8px; }
.icons img { height: 26px; width: auto; }
.copyright { margin-top: 20px; padding-top: 14px; border-top: 1px solid #2a2210; text-align: center; font-size: 13px; color: var(--gold); }

/* ---------- Floats ---------- */
.side-tab { position: fixed; right: max(0px, calc(50% - var(--app-width) / 2)); top: 45%; z-index: 20; width: 24px; }
.float { position: fixed; z-index: 25; }
.float[hidden] { display: none; }
.change-luck { right: max(0px, calc(50% - var(--app-width) / 2)); top: 150px; width: min(96px, 21vw); }
.float .close { position: absolute; top: 0; right: 2px; width: 22px; height: 22px; border-radius: 50%; background: rgba(0, 0, 0, .6); color: #fff; font-size: 14px; line-height: 1; }
.deposit-float { position: fixed; z-index: 24; right: calc(max(0px, calc(50% - var(--app-width) / 2)) + 8px); bottom: calc(var(--nav-height) + 14px + env(safe-area-inset-bottom)); width: min(58px, 14vw); }

/* ---------- Bottom nav ---------- */
.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  z-index: 40;
  width: 100%;
  max-width: var(--app-width);
  height: calc(var(--nav-height) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: #111;
  border-top: 1px solid #2a2210;
}
.bottom-nav a { position: relative; display: grid; place-items: center; }
.bottom-nav a.on { background: radial-gradient(80% 90% at 50% 100%, rgba(242, 201, 76, .25), transparent 70%); border-top: 2px solid var(--gold); }
.bottom-nav img { width: 64px; height: auto; }
.badge { position: absolute; top: 4px; right: 18%; min-width: 18px; height: 18px; border-radius: 50%; background: #e3001b; color: #fff; font-size: 11px; display: grid; place-items: center; }

/* ---------- Toast ---------- */
.toast { position: fixed; left: 50%; bottom: calc(var(--nav-height) + 24px); transform: translateX(-50%); z-index: 50; background: rgba(0, 0, 0, .85); color: #fff; padding: 10px 18px; border-radius: 20px; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .2s; }
.toast.show { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .mq span { animation: none; padding-left: 12px; }
}
