/* livegamesbd500 — dark lobby theme (frozen palette) */
:root {
  --app-bg: #154890;
  --app-button: #31EF73;
  --app-gradient-start: #1183B7;
  --app-gradient-end: #33CBF9;
  --app-accent: #FC7155;
  --app-button-text: #000000;
  --page-deep: #0b2450;
  --card: #123567;
  --card-2: #0e2c58;
  --line: #1e4a8f;
  --text: #eaf2ff;
  --muted: #9db8e0;
  --header-h: 60px;
  --bottom-h: 66px;
  --radius: 18px;
}
* { box-sizing: border-box; }
html { scroll-behavior: auto; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  font-family: "Hind Siliguri", "Inter", "Noto Sans Bengali", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 500px at 50% -150px, var(--app-bg), transparent 70%),
    linear-gradient(180deg, var(--app-bg) 0%, var(--page-deep) 320px, var(--page-deep) 100%);
  background-color: var(--page-deep);
  padding-top: var(--header-h);
  padding-bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 12px);
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; line-height: 1.35; }
p { margin: 0; }
button { font: inherit; cursor: pointer; }
.wrap { width: min(1200px, 100% - 24px); margin-inline: auto; }
.page section { scroll-margin-top: calc(var(--header-h) + 10px); }
.center { text-align: center; margin-top: 16px; }

/* ---------- header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; height: var(--header-h); z-index: 60;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding-inline: clamp(10px, 2.5vw, 28px);
  background: linear-gradient(90deg, #0c2e63, #114890 55%, #0c2e63);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 12px rgba(3, 12, 30, .45);
}
.brand {
  font-family: "Inter", "Hind Siliguri", sans-serif;
  font-weight: 800; font-size: 19px; letter-spacing: .2px;
  background: linear-gradient(90deg, var(--app-gradient-end), var(--app-button));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  white-space: nowrap;
}
.header-actions { display: flex; align-items: center; gap: 8px; }
.lang-link {
  font-size: 13px; font-weight: 700; color: var(--app-gradient-end);
  border: 1px solid var(--app-gradient-start); border-radius: 999px;
  padding: 6px 10px; min-height: 34px; display: inline-flex; align-items: center;
}
.lang-link:hover { background: rgba(51, 203, 249, .12); }
.icon-link {
  width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  color: var(--muted); border: 1px solid var(--line); background: var(--card-2);
}
.icon-link:hover { color: var(--text); border-color: var(--app-gradient-start); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 8px 18px; border: 0; border-radius: 999px;
  font-weight: 700; font-size: 15px; transition: transform .12s ease, filter .12s ease, box-shadow .12s ease;
}
.btn:active { transform: scale(.96); }
.btn:focus-visible, .cat-btn:focus-visible, .dot:focus-visible,
.faq-q:focus-visible, .bn-item:focus-visible, .g-cover:focus-visible, .banner-link:focus-visible,
.promo-img:focus-visible, .back-top:focus-visible, .float-mini:focus-visible {
  outline: 3px solid var(--app-gradient-end); outline-offset: 2px;
}
.btn-solid { background: linear-gradient(90deg, var(--app-button), #22c565); color: var(--app-button-text); box-shadow: 0 4px 14px rgba(49, 239, 115, .35); }
.btn-solid:hover { filter: brightness(1.06); }
.btn-ghost { background: transparent; color: var(--text); border: 1.5px solid var(--app-gradient-start); }
.btn-ghost:hover { background: rgba(17, 131, 183, .18); }
.btn-gold { background: linear-gradient(90deg, #ffd700, #ffb300); color: #4a2d00; }
.btn-download { background: linear-gradient(90deg, var(--app-gradient-start), var(--app-gradient-end)); color: #03223a; padding: 8px 14px; }
.btn-download-label { font-size: 14px; }
@media (max-width: 520px) {
  .header-actions .btn-ghost, .header-actions .btn-solid { padding: 8px 12px; font-size: 14px; }
  .header-actions .btn-download .btn-download-label { font-size: 13px; }
}
.btn-link { color: var(--app-gradient-end); font-weight: 700; font-size: 14px; }
.btn-link:hover { text-decoration: underline; }

/* ---------- ticker ---------- */
.ticker {
  overflow: hidden; border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(17, 131, 183, .25), rgba(51, 203, 249, .08));
}
.tk-track {
  display: inline-flex; gap: 42px; white-space: nowrap; padding: 9px 0; min-width: 200%;
  animation: tkmove 38s linear infinite; will-change: transform;
}
.ticker:hover .tk-track { animation-play-state: paused; }
.tk-item { color: #ffe9c9; font-size: 13.5px; display: inline-flex; align-items: center; gap: 8px; }
.tk-item i { color: var(--app-button); }
@keyframes tkmove { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- hero carousel ---------- */
.hero { padding-top: 14px; }
.slides { position: relative; width: min(880px, 100%); margin-inline: auto; }
.slide { display: block; }
.slide[inert] { display: none; }
.slide-media {
  aspect-ratio: 704 / 267; border-radius: var(--radius); overflow: hidden;
  background: #0a1f45; border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(2, 10, 26, .5);
}
.banner-link, .banner-link img { width: 100%; height: 100%; display: block; }
.banner-link img { object-fit: contain; }
.slide-caption {
  text-align: center; padding: 10px 6px 0; font-size: clamp(14px, 2.4vw, 16px);
  color: var(--text); font-weight: 600; min-height: 40px; display: flex; align-items: center; justify-content: center;
}
.slide-dots { display: flex; justify-content: center; gap: 10px; padding: 8px 0 0; }
.dot {
  min-width: 44px; min-height: 34px; border: 1px solid var(--app-gradient-start); border-radius: 999px;
  background: var(--card-2); color: var(--muted); font-weight: 700;
}
.dot:hover { color: var(--text); }
.dot.is-on { background: linear-gradient(90deg, var(--app-gradient-start), var(--app-gradient-end)); color: #03223a; border-color: transparent; }

/* ---------- live strip ---------- */
.live-strip {
  margin-top: 16px; display: grid; gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  background: linear-gradient(135deg, rgba(17, 131, 183, .3), rgba(21, 72, 144, .55));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 12px;
}
.live-item { display: flex; flex-direction: column; gap: 2px; padding: 6px 10px; background: rgba(6, 22, 51, .45); border-radius: 12px; min-width: 0; }
.live-k { font-size: 12px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.live-k i { color: var(--app-accent); }
.live-v { font-size: 17px; font-weight: 800; color: var(--app-button); font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (min-width: 768px) { .live-strip { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

/* ---------- categories ---------- */
.sec-title { font-size: clamp(19px, 3.2vw, 24px); font-weight: 800; }
.sec-sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.cats { margin-top: 22px; }
.cat-rail {
  display: flex; gap: 10px; overflow-x: auto; padding: 12px 2px 6px;
  scrollbar-width: thin; scrollbar-color: var(--app-gradient-start) transparent;
}
.cat-btn {
  flex: none; min-height: 44px; padding: 9px 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card-2); color: var(--muted); font-weight: 700; font-size: 14px;
}
.cat-btn:hover { color: var(--text); border-color: var(--app-gradient-start); }
.cat-btn.active { background: linear-gradient(90deg, var(--app-gradient-start), var(--app-gradient-end)); color: #03223a; border-color: transparent; }

/* ---------- featured ---------- */
.feat { margin-top: 26px; }
.feat-grid { display: grid; gap: 16px; margin-top: 12px; grid-template-columns: 1fr; }
.feat-card {
  display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 14px; align-items: center;
  background: linear-gradient(150deg, var(--card), var(--card-2)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px;
}
.feat-cover img { border-radius: 14px; aspect-ratio: 1 / 1; object-fit: cover; width: 100%; }
.feat-body h3 { font-size: 18px; }
.feat-body p { color: var(--muted); font-size: 14px; margin-top: 6px; }
.feat-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 12px; }
@media (min-width: 768px) { .feat-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- game grid ---------- */
.games { margin-top: 30px; }
.grid {
  display: grid; gap: 12px; margin-top: 14px;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}
.g-card {
  background: linear-gradient(160deg, var(--card), var(--card-2)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 10px; display: flex; flex-direction: column; gap: 10px;
  transition: transform .15s ease, border-color .15s ease;
}
.g-card:hover { transform: translateY(-3px); border-color: var(--app-gradient-start); }
.g-cover { display: block; border-radius: 14px; overflow: hidden; }
.g-cover img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.g-title {
  font-size: 15px; font-weight: 700; padding-top: 8px; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.g-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tag {
  font-size: 11px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase;
  border-radius: 7px; padding: 3px 8px; color: #04222f;
}
.tag-hot { background: var(--app-accent); color: #380b00; }
.tag-new { background: var(--app-button); }
.tag-pop { background: var(--app-gradient-end); }
.tag-jack { background: #ffd700; }
.btn-play { min-height: 38px; padding: 6px 16px; font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 30px 0 8px; }
[data-game-id][hidden], .g-card[hidden] { display: none !important; }
@media (min-width: 1280px) { .grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

/* ---------- promotions (home + page) ---------- */
.offers { margin-top: 32px; }
.promo-grid { display: grid; gap: 14px; grid-template-columns: 1fr; margin-top: 14px; }
.promo-tile {
  background: linear-gradient(150deg, var(--card), var(--card-2)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; text-align: center;
}
.promo-tile i { font-size: 30px; color: var(--app-button); }
.promo-tile h3 { margin-top: 10px; font-size: 17px; }
.promo-tile p { margin-top: 8px; color: var(--muted); font-size: 14px; line-height: 1.6; }
.promo-tile .btn { margin-top: 14px; }
@media (min-width: 768px) { .promo-grid { grid-template-columns: repeat(3, 1fr); } }

.intro { padding-top: 18px; }
.intro h1 { font-size: clamp(24px, 5vw, 34px); font-weight: 800; }
.intro p { color: var(--muted); margin-top: 8px; max-width: 60ch; }
.promo-stack { display: grid; gap: 26px; margin-top: 22px; }
.promo-card {
  background: linear-gradient(160deg, var(--card), var(--card-2)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px;
}
.promo-card h2 { font-size: 20px; margin-bottom: 12px; }
.promo-img { display: block; border-radius: 14px; overflow: hidden; background: #0a1f45; border: 1px solid var(--line); }
.promo-img img { width: 100%; aspect-ratio: 704 / 300; object-fit: contain; }
.promo-card p { color: var(--muted); margin-top: 12px; font-size: 14.5px; line-height: 1.7; }
.promo-card .btn { margin-top: 14px; }

/* ---------- mini entry ---------- */
.mini-entry { margin-top: 34px; }
.mini-entry-card {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px;
  background: linear-gradient(120deg, var(--app-gradient-start), var(--app-bg) 60%, var(--card));
  border: 1px solid var(--app-gradient-start); border-radius: var(--radius); padding: 18px;
}
.mini-entry-card h2 { font-size: 20px; }
.mini-entry-card p { color: #cfe4ff; margin-top: 6px; font-size: 14px; }

/* ---------- FAQ ---------- */
.faq { margin-top: 34px; }
.faq-list { margin-top: 14px; display: grid; gap: 10px; }
.faq-item { background: var(--card-2); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: none; border: 0; color: var(--text); text-align: start;
  padding: 15px 16px; font-weight: 700; font-size: 15.5px; min-height: 44px;
}
.faq-q i { transition: transform .2s ease; color: var(--app-gradient-end); flex: none; }
.faq-q[aria-expanded="true"] i { transform: rotate(180deg); }
.faq-a { padding: 0 16px 14px; color: var(--muted); font-size: 14.5px; line-height: 1.7; }
.faq-a[hidden] { display: none; }

/* ---------- footer ---------- */
.site-footer {
  margin-top: 44px; border-top: 1px solid var(--line);
  background: linear-gradient(180deg, #0a244f, #071a3c); padding: 26px 0 18px;
}
.footer-grid { display: grid; gap: 22px; grid-template-columns: 1fr; }
.footer-brand p { color: var(--muted); font-size: 13.5px; margin-top: 10px; max-width: 46ch; }
.foot-18 { color: var(--app-accent) !important; font-weight: 700; }
.footer-links ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-links a { color: var(--muted); font-size: 14px; }
.footer-links a:hover { color: var(--text); }
.copyright { text-align: center; color: #6f8fc0; font-size: 12.5px; margin-top: 24px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }

/* ---------- bottom nav ---------- */
.bottom-nav {
  position: fixed; inset: auto 0 0 0; z-index: 60;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  background: linear-gradient(180deg, #0d2f66, #081f45);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
  height: calc(var(--bottom-h) + env(safe-area-inset-bottom));
}
.bn-item {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  min-height: 44px; color: var(--muted); font-size: 10.5px; font-weight: 700; border: 0; background: none;
  padding: 6px 2px; min-width: 0;
}
.bn-item i { font-size: 17px; }
.bn-item span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.bn-item:hover { color: var(--text); }
.bn-item.active { color: var(--app-button); }
button.bn-item { cursor: pointer; }
@media (min-width: 900px) { .bn-item { font-size: 12px; } .bn-item i { font-size: 19px; } }

/* ---------- floating elements ---------- */
.float-mini {
  position: fixed; z-index: 55; right: 14px;
  bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 18px);
  width: 58px; height: 58px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 30% 25%, #ffd700, #fc7155 60%, #c93d22);
  color: #4a1300; font-size: 24px; border: 2px solid #ffe9a8;
  box-shadow: 0 8px 22px rgba(252, 113, 85, .5);
}
.float-mini:active { transform: scale(.94); }
.back-top {
  display: inline-flex; align-items: center; gap: 8px; margin: 26px auto 0; left: 0; right: 0;
  width: max-content; min-height: 44px; padding: 8px 16px; border-radius: 999px;
  border: 1px solid var(--app-gradient-start); color: var(--app-gradient-end); font-weight: 700; font-size: 14px;
  background: rgba(10, 31, 69, .7);
}
.back-top:hover { background: rgba(17, 131, 183, .2); }

/* ---------- winner toasts ---------- */
.winners { position: fixed; left: 12px; z-index: 50; bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 14px);
  display: flex; flex-direction: column; gap: 8px; pointer-events: none; max-width: min(300px, calc(100% - 90px)); }
.winner-toast {
  display: flex; align-items: center; gap: 10px;
  background: linear-gradient(120deg, rgba(13, 47, 102, .96), rgba(17, 131, 183, .9));
  border: 1px solid var(--app-gradient-start); border-radius: 14px; padding: 9px 12px;
  box-shadow: 0 6px 18px rgba(2, 10, 26, .55);
}
.winner-toast i { color: #ffd700; flex: none; }
.wt-text { font-size: 12.5px; line-height: 1.5; color: var(--text); min-width: 0; }
.wt-text strong { color: var(--app-button); }
.wt-text .wt-amt { color: #ffd700; font-weight: 800; }
@media (prefers-reduced-motion: no-preference) {
  .winner-toast.rise { animation: rise 8s linear forwards; }
  @keyframes rise {
    0% { transform: translateY(10px); opacity: 0; }
    6% { transform: translateY(0); opacity: 1; }
    88% { opacity: 1; }
    100% { transform: translateY(-68vh); opacity: 0; }
  }
}

/* ---------- mini-game page ---------- */
.mini-page { padding-bottom: 10px; }
.mini-zone { display: grid; gap: 18px; margin-top: 18px; }
.mini-panel {
  background: linear-gradient(160deg, var(--card), var(--card-2)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; text-align: center;
}
.mini-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.balance { color: var(--muted); font-size: 14px; }
.balance strong { color: #ffd700; font-size: 20px; margin-left: 6px; font-variant-numeric: tabular-nums; }
.board {
  position: relative; width: min(330px, 100%); aspect-ratio: 1; margin: 18px auto 0;
  padding: 14px; background: #09203f; border: 1px solid var(--line); border-radius: 16px;
}
.grid9 { display: grid; grid-template: repeat(3, 1fr) / repeat(3, 1fr); gap: 10px; height: 100%; }
.tile { display: grid; place-items: center; border-radius: 12px; background: #123261; min-height: 0; }
.tile svg { width: 60%; height: 70%; }
.tile.active { background: #1f6fb2; box-shadow: inset 0 0 0 3px #ffd700, 0 0 16px rgba(255, 215, 0, .45); }
@media (prefers-reduced-motion: no-preference) {
  .tile { transition: background-color .12s ease, box-shadow .12s ease; }
  .btn-draw:enabled { animation: pulse 2.4s ease-in-out infinite; }
  @keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(49, 239, 115, .18); } }
}
.btn-draw {
  margin-top: 18px; min-width: min(220px, 100%); min-height: 52px; font-size: 18px;
  background: linear-gradient(90deg, var(--app-button), #22c565); color: var(--app-button-text);
  border: 0; border-radius: 999px; padding: 10px 26px; font-weight: 800;
  box-shadow: 0 6px 18px rgba(49, 239, 115, .35);
}
.btn-draw:disabled { background: #2c4877; color: var(--muted); box-shadow: none; cursor: default; animation: none; }
.remaining { margin-top: 12px; color: var(--muted); font-size: 14px; }
.remaining strong { color: var(--app-gradient-end); font-size: 18px; margin-left: 6px; }
.rules {
  background: rgba(10, 31, 69, .6); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
}
.rules h2 { font-size: 18px; color: #ffd700; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.rules ol { margin: 10px 0 0; padding-inline-start: 22px; color: #d9e8ff; font-size: 14px; line-height: 1.8; }
@media (min-width: 900px) { .mini-zone { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); align-items: start; } }

.mg-dialog {
  width: min(360px, 92%); margin: auto; border: 2px solid #ffd700; border-radius: 18px;
  background: linear-gradient(170deg, #10325f, #0a1f45); color: var(--text);
  padding: 26px 22px; text-align: center;
}
.mg-dialog::backdrop { background: rgba(3, 10, 24, .72); }
.mg-dialog h2 { font-size: 21px; color: #ffd700; }
#mg-prize { display: block; font-size: 34px; margin: 12px 0 4px; color: var(--app-button); font-variant-numeric: tabular-nums; }
.mg-dialog p { color: var(--muted); font-size: 14px; line-height: 1.7; margin-bottom: 16px; }
.mg-claim { width: 100%; }
.mg-actions { display: flex; gap: 10px; margin-top: 14px; }
.mg-actions button {
  flex: 1; min-height: 44px; border-radius: 999px; border: 1.5px solid var(--app-gradient-start);
  background: transparent; color: var(--text); font-weight: 700;
}
.mg-actions button:hover { background: rgba(17, 131, 183, .2); }

@media (prefers-reduced-motion: reduce) {
  .tk-track { animation: none; }
  * { transition: none !important; }
}
