/* 643PLAY — "Lacquer × Packet" design system.
   Lacquer: chamfered gold-framed panels, window-lattice ground, duotone icons, diamond markers.
   Packet: envelope jackpot with coin seal, ticket wallet, packet game grid, notched nav with gold-coin 玩.
   Every colour is a token; players switch palettes at runtime (see THEMES in app.js). */
/* Self-hosted fonts, cut down to the characters the app uses (built from Google Fonts' OFL sources).
   Chinese body text uses the phone's own Chinese font (PingFang SC / Noto Sans CJK), which every device has. */
@font-face { font-family: "Poppins"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/poppins-400.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/poppins-500.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/poppins-600.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/poppins-700.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 800; font-style: normal; font-display: swap; src: url("fonts/poppins-800.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 900; font-style: normal; font-display: swap; src: url("fonts/poppins-900.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 900; font-style: italic; font-display: swap; src: url("fonts/poppins-900i.woff2") format("woff2"); }
@font-face { font-family: "Noto Serif SC"; font-weight: 600 900; font-display: swap; src: url("fonts/notoserifsc-900.woff2") format("woff2"); }
@font-face { font-family: "ZCOOL QingKe HuangYou"; font-display: swap; src: url("fonts/zcool.woff2") format("woff2"); }
@font-face { font-family: "Ma Shan Zheng"; font-display: swap; src: url("fonts/mashanzheng.woff2") format("woff2"); }

:root {
  /* palette (朱砂 cinnabar default — app.js rewrites these per theme) */
  --bg0: #2a0405; --bg1: #5a0a0d; --bg2: #7c1213; --bg3: #3c0607;
  --hi: #e2231f; --hi2: #a8100f; --muted: #e9c98a; --on-gold: #5a0a0a; --ink: #fff1d6; --accent-txt: #ffe7a0;
  --code-grad: linear-gradient(120deg, #a96d0c, #fff1b8 40%, #f2c34c 70%, #a96d0c);
  /* constants */
  --gold1: #fff1b8; --gold: #f2c34c; --gold2: #a96d0c; --gold-txt: #ffe7a0;
  --g: linear-gradient(135deg, var(--gold1), var(--gold) 40%, var(--gold2) 75%, #f7d77e);
  --coin: radial-gradient(circle at 35% 30%, var(--gold1), var(--gold) 50%, #b07a10);
  --panel: linear-gradient(160deg, var(--bg2), var(--bg3));
  --line: color-mix(in srgb, var(--gold) 35%, transparent);
  --soft: color-mix(in srgb, var(--gold) 12%, transparent);
  --success: #3fd08a; --danger: #ff5a5f; --player: #4f94d4;
  --c: 9px;
  --safe-bottom: max(env(safe-area-inset-bottom, 0px), var(--tg-safe-area-inset-bottom, 0px), var(--tg-content-safe-area-inset-bottom, 0px));
  --font: "Poppins", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Noto Sans CJK SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --display: "Noto Serif SC", "Songti SC", "STSong", Georgia, serif;
  --fun: "ZCOOL QingKe HuangYou", "Noto Serif SC", serif;
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { margin: 0; height: 100%; }
/* --app-h is the real visible height (Telegram's viewport inside the Mini App, the window elsewhere); 100dvh is the fallback before JS runs. */
body { margin: 0; height: var(--app-h, 100dvh); }
body { background: var(--bg0); color: var(--ink); font-family: var(--font); font-size: 14px; -webkit-font-smoothing: antialiased; overflow: hidden; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
.num { font-variant-numeric: tabular-nums; }
.hide-sb { scrollbar-width: none; } .hide-sb::-webkit-scrollbar { display: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- shapes ---------- */
.cut, .field, .amts button, .search, .slot-provs button, .lucky i, .cd-big b, .two button, .link-row, .qr, .roads, .bc-screen, .calc, .bet, .dlg .box, .slot-provs button, .frame, .card, .cont, .prov, .rank-card, .room, .bacc-card, .help, .sec-card, .dlg, .lang-grid button, .promo-row, .art { clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c)); }
/* gold chamfered frame on a single element: gold paints the edge, ::before paints the panel */
.frame, .card, .cont, .prov, .rank-card, .room, .bacc-card, .help, .sec-card, .dlg, .lang-grid button, .promo-row, .art { position: relative; isolation: isolate; background: var(--g); }
.frame::before, .card::before, .cont::before, .prov::before, .rank-card::before, .room::before, .bacc-card::before, .help::before, .sec-card::before, .dlg::before, .lang-grid button::before, .promo-row::before, .art::before { content: ""; position: absolute; inset: 1.5px; z-index: -1; background: var(--panel);
  clip-path: polygon(calc(var(--c) - .6px) 0, calc(100% - var(--c) + .6px) 0, 100% calc(var(--c) - .6px), 100% calc(100% - var(--c) + .6px), calc(100% - var(--c) + .6px) 100%, calc(var(--c) - .6px) 100%, 0 calc(100% - var(--c) + .6px), 0 calc(var(--c) - .6px)); }
.frame.cut, .field, .amts button, .search, .slot-provs button, .lucky i, .cd-big b, .two button, .link-row, .qr, .roads, .bc-screen, .calc, .bet, .dlg .box, .slot-provs button, .frame, .card, .cont, .prov, .rank-card, .room, .bacc-card, .help, .sec-card, .dlg, .lang-grid button, .promo-row, .art { clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c)); }
.coin-i { display: grid; place-items: center; border-radius: 50%; background: var(--coin); color: var(--on-gold); box-shadow: inset 0 -2px 0 rgba(120,60,0,.35); }
.ico { width: 1em; height: 1em; }

/* ---------- app frame ---------- */
.frame-root { display: flex; justify-content: center; height: 100%; background: var(--bg0); }
.app { position: relative; width: 100%; max-width: 430px; height: 100%; display: flex; flex-direction: column; overflow: hidden;
  background:
    linear-gradient(rgba(0,0,0,.88), rgba(0,0,0,.88)),
    url("img/bg-neon.svg") center top / cover no-repeat,
    radial-gradient(120% 60% at 50% 0%, var(--bg2), var(--bg1) 55%, var(--bg0)); }
/* slow light shimmer gliding over the crystal facets */
.app::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(115deg, transparent 40%, rgba(255,205,130,.075) 50%, transparent 60%); background-size: 300% 100%; animation: bgSheen 16s ease-in-out infinite; }
@keyframes bgSheen { 0% { background-position: 150% 0; } 60%, 100% { background-position: -50% 0; } }
@media (prefers-reduced-motion: reduce) { .app::before { animation: none; } }
/* ---------- background options (pick with ?bg=scales|lanterns|clouds|facets) ---------- */
.app[data-bg="scales"] { background: radial-gradient(130% 80% at 50% 35%, transparent 50%, rgba(0,0,0,.5)), url("img/bg-scales.svg") 0 0 / 44px 44px repeat, radial-gradient(120% 60% at 50% 0%, var(--bg2), var(--bg1) 55%, var(--bg0)); }
.app[data-bg="clouds"] { background: radial-gradient(130% 80% at 50% 35%, transparent 50%, rgba(0,0,0,.5)), url("img/bg-clouds.svg") 0 0 / 110px 74px repeat, radial-gradient(120% 60% at 50% 0%, var(--bg2), var(--bg1) 55%, var(--bg0)); }
.app[data-bg="lanterns"] { background: url("img/bg-lanterns.svg") 0 0 / 100% 900px repeat-y, radial-gradient(120% 60% at 50% 0%, var(--bg2), var(--bg1) 55%, var(--bg0)); background-position: 0 0, 0 0; animation: bgDrift 70s linear infinite; }
@keyframes bgDrift { to { background-position: 0 -900px, 0 0; } }
.app[data-bg="lanterns"]::before { display: none; }
@media (prefers-reduced-motion: reduce) { .app[data-bg="lanterns"] { animation: none; } }

.main { position: relative; z-index: 10; flex: 1; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; padding: 0 14px calc(108px + var(--safe-bottom)); scrollbar-width: none; }
.main::-webkit-scrollbar { display: none; }
.main.no-nav { padding-bottom: 24px; }

/* ---------- header ---------- */
.hdr { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 8px; }
.logo { display: flex; flex-direction: column; align-items: center; gap: 2px; line-height: 1; user-select: none; }
.wordmark { display: flex; font: 900 25px/1 "Poppins", sans-serif; font-style: italic; letter-spacing: -.5px; filter: drop-shadow(0 2px 3px rgba(0,0,0,.5)); }
.wordmark .we, .wordmark .play { position: relative; background: linear-gradient(120deg, #b07a14 0%, #e6b23a 22%, #fff0b0 45%, #e6b23a 68%, #b07a14 100%); background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: weShine 3.2s linear infinite; }
.wordmark .play { margin-left: 1px; padding-right: 2px; }
.wordmark .n99 { color: #f7f4ee; margin-left: -2px; padding-right: 3px; }
.tagline { font: 700 8px/1 "Poppins", sans-serif; letter-spacing: 2px; color: var(--muted); text-transform: uppercase; opacity: .85; }
.logo.big .wordmark { font-size: 52px; } .logo.big .tagline { font-size: 12px; letter-spacing: 3.5px; }
@keyframes weShine { 0% { background-position: 0% 50%; } 100% { background-position: -250% 50%; } }
.hdr-act { display: flex; align-items: center; gap: 7px; }
.hdr-bal { flex: none; height: 30px; padding: 0 10px; font-size: 11px; }
.hdr-bal a { display: flex; align-items: center; gap: 3px; color: inherit; }
.ibtn { position: relative; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--coin); color: var(--on-gold); box-shadow: inset 0 -2px 0 rgba(120,60,0,.35), 0 2px 6px rgba(0,0,0,.35); }
.ibtn svg { width: 16px; height: 16px; }
.ibtn .dot { position: absolute; top: -1px; right: -1px; width: 9px; height: 9px; border-radius: 50%; background: var(--hi); box-shadow: 0 0 0 2px var(--bg1); }
.theme-toggle svg.sun-moon { animation: sunMoonIn .45s cubic-bezier(.34,1.56,.64,1); }
@keyframes sunMoonIn { 0% { transform: rotate(-120deg) scale(.3); opacity: 0; } 100% { transform: rotate(0) scale(1); opacity: 1; } }
.page-title { display: flex; align-items: center; gap: 10px; font: 900 24px var(--display); margin: 0 0 14px; }
.page-title::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--gold2), transparent); }
.subhdr { display: flex; align-items: center; gap: 8px; height: 56px; margin-bottom: 6px; }
.subhdr h1 { flex: 1; text-align: center; font: 900 17px var(--display); margin: 0; }
.subhdr .ibtn { flex: none; } .subhdr .sp { width: 32px; }

/* ---------- banners ---------- */
.adverts { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; }
.adverts > * { flex: 0 0 100%; scroll-snap-align: center; }
.ad { --cut-ad: 18px; position: relative; display: block; height: 164px; border: 2px solid transparent; clip-path: polygon(var(--cut-ad) 0, 100% 0, 100% calc(100% - var(--cut-ad)), calc(100% - var(--cut-ad)) 100%, 0 100%, 0 var(--cut-ad)); box-shadow: 0 12px 24px -12px rgba(0,0,0,.8); animation: realmSpin 7s linear infinite; }
.ad-tag { position: absolute; left: 10px; bottom: 9px; display: flex; align-items: center; gap: 6px; max-width: 72%; padding: 3px 10px 3px 3px; border-radius: 99px; background: rgba(0,0,0,.4); }
.ad-tag i { font-style: normal; flex: none; border-radius: 99px; background: var(--g); padding: 1px 7px; font-size: 9.5px; font-weight: 700; line-height: 14px; color: var(--on-gold); }
.ad-tag span { font-size: 11px; font-weight: 700; color: var(--gold-txt); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dots { display: flex; justify-content: center; gap: 6px; margin-top: 8px; }
.dots i { width: 6px; height: 6px; background: color-mix(in srgb, var(--ink) 25%, transparent); transform: rotate(45deg); transition: all .3s; }
.dots i.on { background: var(--gold); transform: rotate(45deg) scale(1.35); }

/* jackpot envelope */
.jp { text-align: center; background: linear-gradient(var(--hi), var(--hi2)) padding-box, var(--molten) border-box; }
.jp::before { content: ""; position: absolute; left: -10%; right: -10%; top: -78px; height: 132px; border-radius: 0 0 50% 50%; background: linear-gradient(color-mix(in srgb, var(--hi) 80%, white), var(--hi)); box-shadow: 0 3px 0 rgba(0,0,0,.18); }
.jp .seal { position: absolute; left: 50%; top: 34px; translate: -50% 0; width: 40px; height: 40px; font: 900 16px var(--display); }
.jp .side { position: absolute; top: 9px; font: 700 9.5px "Poppins", sans-serif; color: var(--gold-txt); } .jp .side.l { left: 12px; } .jp .side.r { right: 12px; }
.jp-body { position: absolute; left: 0; right: 0; top: 80px; }
.jp-sub { font: 600 9.5px "Poppins", sans-serif; letter-spacing: .22em; color: var(--gold-txt); }
.jp-amt { display: flex; justify-content: center; align-items: baseline; gap: 5px; font-weight: 900; }
.jp-amt small { font-size: 14px; color: var(--gold-txt); }
.jp-amt b { font: 900 30px "Poppins", sans-serif; letter-spacing: .5px; background: linear-gradient(#fff, var(--gold1) 45%, var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 2px 0 rgba(0,0,0,.3)); }
.jp-cd { display: flex; justify-content: center; gap: 4px; margin-top: 2px; }
.jp-cd div { display: flex; align-items: baseline; gap: 1px; font: 700 12px "Poppins", sans-serif; color: #fff; }
.jp-cd span { font-size: 8px; color: var(--gold-txt); margin-right: 4px; }

/* art banners = framed lacquer boxes */
.art { display: flex; align-items: center; padding: 0 16px; --c: 12px; }
.art::before { background: radial-gradient(circle at 80% 45%, var(--hi), var(--bg2) 50%, var(--bg3)); }
.art .copy { position: relative; z-index: 2; max-width: 58%; }
.art .kick { font-size: 10px; color: var(--accent-txt); font-weight: 700; letter-spacing: 1px; }
.art h3 { margin: 4px 0; font: 900 21px/1.2 var(--display); background: linear-gradient(#fff, var(--gold1) 55%, var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.art p { margin: 0; font-size: 11px; color: var(--muted); }
.art img { position: absolute; right: -4px; bottom: -14px; height: 168px; z-index: 1; }

/* ---------- marquee ---------- */
.marquee { position: relative; display: flex; align-items: center; gap: 8px; height: 34px; margin-top: 10px; padding: 0 14px; --cut-m: 12px; clip-path: polygon(var(--cut-m) 0, 100% 0, 100% calc(100% - var(--cut-m)), calc(100% - var(--cut-m)) 100%, 0 100%, 0 var(--cut-m)); border: 2px solid transparent;
  background: linear-gradient(165deg, rgba(44,18,14,.9), rgba(8,4,6,.95)) padding-box, var(--molten) border-box; animation: realmSpin 7s linear infinite .3s reverse; overflow: hidden; font-size: 12px; }
.marquee > svg { width: 14px; height: 14px; color: var(--ember2); flex: none; }
.marquee .track { flex: 1; overflow: hidden; white-space: nowrap; }
.marquee .track span { display: inline-block; padding-left: 100%; animation: mq 48s linear infinite; color: var(--ink); }
@keyframes mq { to { transform: translateX(-100%); } }

/* ---------- wallet: dark molten-glass panel (matches the LONG888 gate/tile theme) ---------- */
.wallet { position: relative; display: flex; align-items: center; gap: 8px; margin-top: 14px; padding: 8px 16px; --cut-w: 16px; clip-path: polygon(var(--cut-w) 0, 100% 0, 100% calc(100% - var(--cut-w)), calc(100% - var(--cut-w)) 100%, 0 100%, 0 var(--cut-w)); border: 2px solid transparent; color: var(--ink);
  background: linear-gradient(165deg, rgba(44,18,14,.9), rgba(8,4,6,.95)) padding-box, var(--molten) border-box; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 10px 28px rgba(0,0,0,.5), 0 0 20px rgba(255,106,31,.1); animation: realmSpin 7s linear infinite; }
.balance { flex: 1; min-width: 0; }
.balance .lbl { display: flex; align-items: center; gap: 4px; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ember2); font-weight: 700; }
.balance .lbl button { display: grid; color: inherit; } .balance .lbl svg { width: 14px; height: 14px; }
.balance .val { margin-top: 1px; font: 800 22px "Poppins", sans-serif; letter-spacing: .5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: linear-gradient(180deg, #fff, #ffe2a0); -webkit-background-clip: text; background-clip: text; color: transparent; }
.w-acts { display: flex; gap: 6px; padding-left: 12px; border-left: 1.5px solid rgba(255,178,74,.25); }
.w-act { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 9.5px; font-weight: 700; color: #ffe6bf; }
.w-act i { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.07); border: 1px solid rgba(255,178,74,.3); color: var(--ember2); }
.w-act.pri i { background: linear-gradient(160deg, #ffd36b, #ff6a1f); color: #3a1204; border-color: transparent; box-shadow: 0 0 0 2px rgba(255,178,74,.45), 0 0 10px rgba(255,106,31,.7); animation: navPulse 2.2s ease-in-out infinite; }
.w-act svg { width: 16px; height: 16px; }

/* ---------- continue (lacquer frame) ---------- */
.cont { display: flex; align-items: center; gap: 10px; margin-top: 12px; height: 76px; padding: 10px 12px; --c: 10px; }
.cont .ico { width: 48px; height: 48px; flex: none; border-radius: 10px; background: var(--hi) url("img/art/mascot-head.webp") center 8% / 118% no-repeat; box-shadow: inset 0 0 0 1.5px var(--gold); }
.cont .tx { flex: 1; min-width: 0; }
.cont .lbl { font-size: 10px; color: var(--accent-txt); letter-spacing: .1em; }
.cont .nm { font: 900 15px var(--display); margin-top: 1px; }
.cont .sub { font-size: 11px; color: var(--muted); margin-top: 1px; }
.cont .go { flex: none; width: 44px; height: 44px; }
.cont .go svg { width: 18px; height: 18px; margin-left: 2px; }

/* ---------- category chips (coin icon pills) ---------- */
.cats { display: flex; gap: 6px; margin-top: 22px; overflow-x: auto; }
.chip { flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px 0 4px; border-radius: 99px; font-size: 12px; font-weight: 700; color: var(--muted); background: var(--soft); }
.chip i { width: 24px; height: 24px; flex: none; }
.chip i svg { width: 13px; height: 13px; }
.chip.on { background: var(--g); color: var(--on-gold); } .chip.on i { background: var(--hi); color: var(--gold-txt); box-shadow: none; }
.chip.plain { padding: 0 14px; }

/* ---------- section heading (gold rules + diamond) ---------- */
.sec { display: flex; align-items: center; gap: 8px; margin: 18px 0 10px; }
.sec h2 { display: flex; align-items: center; gap: 8px; margin: 0; font: 900 15px var(--display); white-space: nowrap; }
.sec h2::before { content: ""; width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); }
.sec::after { content: ""; order: 1; flex: 1; height: 1px; background: linear-gradient(90deg, var(--gold2), transparent); }
.sec a, .sec button, .sec .r { order: 2; font-size: 10.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }

/* ---------- packet game grid ---------- */
.pk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pk { position: relative; display: block; aspect-ratio: 1 / 1.2; border-radius: 14px; overflow: hidden; background: linear-gradient(var(--hi), var(--hi2)); box-shadow: 0 6px 14px -8px rgba(0,0,0,.7); }
.pk::before { content: ""; position: absolute; left: -22%; right: -22%; top: -40px; height: 70px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, white 10%, transparent); }
.pk img { position: absolute; left: 8%; right: 8%; top: 12%; width: 84%; height: 64%; object-fit: contain; }
.pk b { position: absolute; left: 4px; right: 4px; bottom: 16px; text-align: center; font-size: 11.5px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pk small { position: absolute; left: 0; right: 0; bottom: 4px; text-align: center; font-size: 8.5px; color: var(--gold-txt); }
.pk .n { position: absolute; right: 6px; top: 6px; padding: 1px 6px; border-radius: 99px; background: var(--g); color: var(--on-gold); font: 700 8.5px "Poppins", sans-serif; z-index: 1; }
.pk.gd { background: var(--g); color: var(--on-gold); } .pk.gd small { color: var(--on-gold); }
.pk-grid.mt { margin-top: 8px; }
.prov { display: flex; align-items: center; gap: 8px; height: 54px; padding: 7px 10px 7px 7px; --c: 8px; }
.prov .lg { flex: none; width: 54px; height: 38px; display: grid; place-items: center; font-size: 9px; font-weight: 900; font-style: italic; line-height: 1.05; text-align: center; background: var(--g); -webkit-background-clip: text; background-clip: text; color: transparent; }
.prov .cp { flex: 1; min-width: 0; }
.prov .cp b { display: block; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prov .cp span { font-size: 9.5px; color: var(--muted); }
.prov .arr { flex: none; color: var(--accent-txt); font-size: 9px; }
.prov .tag { position: absolute; left: 0; top: 0; font-size: 7px; font-weight: 900; padding: 1px 8px 1px 5px; background: var(--hi); color: #fff; clip-path: polygon(0 0, 100% 0, 85% 100%, 0 100%); z-index: 1; }
.prov.more .lg { font-size: 22px; font-style: normal; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 20px; }

/* ---------- invite rank (home) ---------- */
.rank-card { padding: 4px 12px; --c: 10px; }
.rk-row { display: grid; grid-template-columns: 28px 1fr auto auto; align-items: center; gap: 8px; height: 38px; border-bottom: 1px dashed var(--line); font-size: 12px; }
.rk-row:last-child { border-bottom: 0; }
.rk-n { width: 22px; height: 22px; display: grid; place-items: center; font-size: 11px; font-weight: 800; background: var(--soft); color: var(--muted); border-radius: 50%; }
.rk-n.g1, .rk-n.g2, .rk-n.g3 { background: var(--coin); color: var(--on-gold); }
.rk-c { color: var(--accent-txt); font-weight: 700; } .rk-p { color: var(--muted); font-size: 11px; text-align: right; min-width: 70px; }

/* ---------- bottom nav: cueball-shape bar + gold coin 玩 button on top ---------- */
.bnav { position: absolute; left: 0; right: 0; bottom: 0; z-index: 40; height: calc(96px + var(--safe-bottom)); }
.bnav-bg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; filter: drop-shadow(0 -4px 14px rgba(0,0,0,.45)); }
.bnav-bg .s1 { stop-color: var(--bg0); } .bnav-bg .s2 { stop-color: var(--bg3); } .bnav-bg .s3 { stop-color: var(--bg1); }
.bnav-bg path { stroke: var(--line); stroke-width: 1px; }
.bnav .bar { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); align-items: end; height: 100%; padding-bottom: calc(16px + var(--safe-bottom)); }
.nv { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 9px; color: var(--muted); font-weight: 700; transition: color .2s; }
.nv i { width: auto; height: auto; border-radius: 0; background: none; display: grid; place-items: center; color: inherit; transition: none; }
.nv i svg { width: 20px; height: 20px; }
.nv.on { color: var(--accent-txt); } .nv.on i { background: none; color: inherit; transform: none; }
.nv-play { position: relative; height: 100%; }
@property --a { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
.play-btn { position: absolute; left: 50%; top: 16px; translate: -50% 0; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-size: 0;
  background: radial-gradient(circle at 50% 40%, #3a0f0a, #120504); box-shadow: 0 0 0 2px rgba(255,178,74,.45), 0 10px 30px rgba(255,106,31,.65); animation: navPulse 2.4s ease-in-out infinite; }
.play-btn::before { content: ""; position: absolute; inset: -5px; border-radius: 50%; background: conic-gradient(from var(--a), #ffd36b, transparent 30%, #ff5a1f 55%, transparent 80%, #ffd36b);
  -webkit-mask: radial-gradient(circle, transparent 62%, #000 64%); mask: radial-gradient(circle, transparent 62%, #000 64%); animation: navSpin 3s linear infinite; }
.play-btn img { position: relative; width: 82%; height: 82%; border-radius: 50%; object-fit: cover; }
@keyframes navSpin { to { --a: 360deg; } }
@keyframes navPulse { 50% { box-shadow: 0 0 0 3px rgba(255,210,107,.8), 0 12px 40px rgba(255,122,31,.95); } }
.nv-play small { position: absolute; left: 0; right: 0; bottom: -12px; text-align: center; font-size: 10px; font-weight: 700; color: var(--accent-txt); }

/* ---------- dim scrim behind the fan menu ---------- */
.fan-scrim { position: fixed; inset: 0; z-index: 39; background: rgba(0,0,0,0); transition: background .25s ease; pointer-events: none; }
.fan-scrim.open { background: rgba(0,0,0,.6); pointer-events: auto; }

/* ---------- play-btn fan menu: a fixed layer so it can float above the nav's own clipped box ---------- */
.fan-layer { position: fixed; left: 0; right: 0; bottom: 0; max-width: 430px; margin: 0 auto; height: calc(96px + var(--safe-bottom)); z-index: 45; pointer-events: none; }
.fan { position: absolute; left: 50%; top: 16px; width: 56px; height: 56px; translate: -50% 0; }
.fan-btn { position: absolute; left: 50%; top: 50%; width: 58px; margin: -29px 0 0 -29px; display: flex; flex-direction: column; align-items: center; gap: 4px;
  opacity: 0; pointer-events: none; transform: translate(0, 0) scale(.3); transition: transform .5s cubic-bezier(.4, 0, .2, 1), opacity .45s ease; }
.fan-bob { display: flex; flex-direction: column; align-items: center; gap: 4px; animation: fanFloat 2.6s ease-in-out infinite; }
.fan-ic { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #3a0f0a, #120504);
  box-shadow: 0 0 0 2px var(--gold), 0 0 16px rgba(255,122,31,.65), 0 6px 14px rgba(0,0,0,.55); color: var(--ember2, var(--gold)); transition: transform .3s; }
.fan-ic svg { width: 22px; height: 22px; }
.fan-btn b { font-size: 10px; font-weight: 700; color: var(--accent-txt); text-shadow: 0 1px 4px rgba(0,0,0,.6); white-space: nowrap; }
.fan-layer.open .fan-btn { opacity: 1; pointer-events: auto; transition: transform .32s cubic-bezier(.3, 1.6, .4, 1), opacity .2s; }
.fan-layer.open .fan-btn.f1 { transform: translate(-64px, -62px) rotate(-18deg) scale(1); transition-delay: 0s; }
.fan-layer.open .fan-btn.f2 { transform: translate(0, -86px) rotate(0deg) scale(1); transition-delay: .05s; }
.fan-layer.open .fan-btn.f3 { transform: translate(64px, -62px) rotate(18deg) scale(1); transition-delay: .1s; }
@keyframes fanFloat { 50% { transform: translateY(-5px); } }
@media (prefers-reduced-motion: reduce) { .fan-bob { animation: none; } }

/* ---------- free spin float ---------- */
.fsf { position: absolute; right: 10px; bottom: 130px; z-index: 35; width: 80px; height: 80px; animation: fsBob 3s ease-in-out infinite; }
.fsf img { width: 100%; height: 100%; filter: drop-shadow(0 4px 12px rgba(242,195,76,.45)); }
.fsf .x { position: absolute; top: -8px; left: -6px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--bg0); border: 1px solid var(--line); color: var(--ink); font-size: 12px; }
@keyframes fsBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }

/* ---------- generic: cards, buttons, forms ---------- */
.card { padding: 14px; --c: 10px; }
.card + .card { margin-top: 12px; }
.card-gold::before { background: linear-gradient(160deg, color-mix(in srgb, var(--hi) 55%, var(--bg2)), var(--bg3)); }
.muted { color: var(--muted); } .gold { color: var(--accent-txt); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 46px; padding: 0 20px; font-weight: 800; font-size: 15px; --c: 10px;
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% 50%, calc(100% - var(--c)) 100%, var(--c) 100%, 0 50%); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-gold { color: var(--on-gold); background: var(--g); }
.btn-dark { color: var(--accent-txt); background: var(--soft); box-shadow: inset 0 0 0 1px var(--line); }
.btn-block { display: flex; width: 100%; }
.btn-sm { height: 34px; font-size: 13px; padding: 0 18px; --c: 8px; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.tabs { display: flex; gap: 6px; margin-bottom: 12px; overflow-x: auto; }
.tabs .chip { flex: 1; }
.list-item { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.list-item:last-child { border-bottom: 0; }
.empty { text-align: center; padding: 30px 0; color: var(--muted); font-size: 13px; }
.field { display: flex; align-items: center; gap: 8px; height: 50px; padding: 0 14px; background: color-mix(in srgb, black 30%, transparent); box-shadow: inset 0 0 0 1px var(--line); --c: 8px; }
.field input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; font-size: 18px; font-weight: 700; }
.field b { color: var(--accent-txt); }
.amts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.amts button { height: 40px; font-weight: 700; background: var(--soft); --c: 7px; }
.amts button.on { background: var(--g); color: var(--on-gold); }
.steps { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; font-size: 12px; color: var(--muted); }
.steps b { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: var(--soft); font-size: 11px; }
.steps .on { color: var(--ink); } .steps .on b { background: var(--coin); color: var(--on-gold); }
.steps hr { flex: 1; border: 0; border-top: 1px dashed var(--line); }
.note { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin: 12px 0; }
.link-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; background: var(--soft); font-size: 13px; --c: 8px; }
.link-row svg { width: 14px; height: 14px; flex: none; color: var(--gold); }

/* ---------- me ---------- */
.me-top { display: flex; align-items: center; gap: 14px; margin: 6px 0 18px; }
.avatar { width: 66px; height: 66px; border-radius: 50%; flex: none; background: var(--hi) url("img/art/mascot-head.webp") center 8% / 118% no-repeat; box-shadow: 0 0 0 2px var(--gold), 0 0 0 5px color-mix(in srgb, var(--gold) 25%, transparent); }
.me-top .nm { font: 900 17px var(--display); }
.me-top .uid { font-size: 12px; color: var(--muted); margin-top: 3px; }
.sec-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.sec-card { height: 92px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font-size: 12px; --c: 9px; }
.sec-card i { width: 30px; height: 30px; } .sec-card i svg { width: 15px; height: 15px; }
.sec-card span { font-size: 10px; color: var(--accent-txt); }
.menu-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px 0; }
.menu-grid a, .menu-grid button { height: 78px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; font-size: 11px; color: var(--ink); }
.menu-grid i { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--soft); color: var(--gold); box-shadow: inset 0 0 0 1px var(--line); }
.menu-grid i svg { width: 18px; height: 18px; }

/* ---------- hall ---------- */
.room { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin-bottom: 8px; --c: 10px; }
.room .ri { width: 52px; height: 60px; flex: none; border-radius: 8px; display: grid; place-items: center; position: relative; overflow: hidden; background: linear-gradient(var(--hi), var(--hi2)); font: 900 15px var(--display); color: var(--gold-txt); text-align: center; line-height: 1; }
.room .ri::before { content: ""; position: absolute; left: -30%; right: -30%; top: -22px; height: 38px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, white 12%, transparent); }
.room .ri small { display: block; font-size: 9px; color: var(--gold); margin-top: 3px; }
.room .rc { flex: 1; min-width: 0; }
.room .rc b { font: 900 15px var(--display); } .room .rc p { margin: 3px 0; font-size: 11px; color: var(--muted); }
.room .hot { font-size: 11px; color: var(--accent-txt); font-weight: 800; } .room .hot span { color: var(--muted); font-weight: 500; margin-left: 4px; }
.circle-arr { width: 28px; height: 28px; flex: none; } .circle-arr svg { width: 12px; height: 12px; }
.bacc-card { position: relative; display: block; height: 118px; padding: 14px; overflow: hidden; --c: 12px; }
.live { display: inline-block; padding: 1px 7px; font-size: 10px; font-weight: 800; background: var(--danger); color: #fff; clip-path: polygon(4px 0, 100% 0, calc(100% - 4px) 100%, 0 100%); }
.bacc-card h3 { margin: 6px 0 2px; font: 900 19px var(--display); } .bacc-card p { margin: 0; font-size: 11px; color: var(--muted); }
.bacc-card .cards2 { position: absolute; right: 44px; top: 10px; }
.bacc-card .cards2 i { position: absolute; width: 50px; height: 72px; border-radius: 6px; background: #fffaf0; box-shadow: inset 0 0 0 1px var(--gold2); color: #111; font-style: normal; font-weight: 900; font-size: 18px; padding: 3px 5px; }
.bacc-card .cards2 i:first-child { transform: rotate(-12deg); right: 20px; } .bacc-card .cards2 i:last-child { transform: rotate(8deg); right: -18px; color: #d2262b; }
.slot-search { display: flex; gap: 10px; }
.slot-provs { display: flex; flex-direction: column; gap: 6px; width: 70px; flex: none; }
.slot-provs button { height: 54px; font-size: 9.5px; font-weight: 900; font-style: italic; color: var(--muted); background: var(--soft); --c: 7px; }
.slot-provs button.on { background: var(--g); color: var(--on-gold); }
.slot-main { flex: 1; min-width: 0; }
.search { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; background: color-mix(in srgb, black 30%, transparent); box-shadow: inset 0 0 0 1px var(--line); --c: 8px; }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; font-size: 13px; }
.search svg { width: 15px; height: 15px; color: var(--muted); }
.slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.slot { display: flex; flex-direction: column; gap: 4px; min-width: 0; font-size: 10px; color: var(--muted); text-align: center; }
.slot .th { display: block; width: 100%; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: linear-gradient(160deg, var(--bg2), var(--bg3)); box-shadow: inset 0 0 0 1px var(--line); }
.slot .th img { display: block; width: 100%; height: 100%; object-fit: cover; }
.slot span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.help { display: flex; align-items: center; gap: 12px; padding: 14px; margin-top: 16px; --c: 10px; }
.help > i { width: 36px; height: 36px; flex: none; } .help > i svg { width: 18px; height: 18px; }
.help b { font-size: 13px; } .help p { margin: 2px 0 0; font-size: 11px; color: var(--muted); }
.bal-pill { display: flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; background: var(--g); color: var(--on-gold); font-size: 12px; font-weight: 800; }
.bal-pill svg { width: 13px; height: 13px; }

/* ---------- niu niu room ---------- */
.nn { position: absolute; inset: 0; z-index: 50; display: flex; flex-direction: column; background: var(--bg1); }
.nn-top { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg3); border-bottom: 1.5px solid var(--gold2); }
.nn-top .t { flex: 1; min-width: 0; } .nn-top b { font: 900 15px var(--display); } .nn-top small { display: block; font-size: 11px; color: var(--muted); }
.nn-phase { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; font-size: 12px; background: linear-gradient(90deg, var(--soft), transparent); border-bottom: 1px solid var(--line); }
.nn-phase b { color: var(--gold); font-size: 16px; }
.nn-log { flex: 1; overflow-y: auto; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; scrollbar-width: none;
  background: repeating-linear-gradient(45deg, color-mix(in srgb, var(--gold) 4%, transparent) 0 1px, transparent 1px 22px); }
.msg { display: flex; gap: 8px; max-width: 92%; }
.msg .av { width: 30px; height: 30px; border-radius: 50%; flex: none; display: grid; place-items: center; font-size: 12px; font-weight: 800; background: var(--soft); color: var(--gold); }
.msg .av.bot { background: var(--coin); color: var(--on-gold); font-size: 9px; }
.msg .bub { padding: 7px 10px; border-radius: 4px 12px 12px 12px; background: rgba(0,0,0,.38); box-shadow: inset 0 0 0 1px var(--line); font-size: 12.5px; line-height: 1.5; }
.msg .who { font-size: 10.5px; color: var(--accent-txt); font-weight: 700; margin-bottom: 1px; }
.msg.me { align-self: flex-end; flex-direction: row-reverse; } .msg.me .bub { background: var(--g); color: var(--on-gold); border-radius: 12px 4px 12px 12px; }
.packet { position: relative; width: 210px; height: 120px; border-radius: 12px; overflow: hidden; background: linear-gradient(var(--hi), var(--hi2)); text-align: center; color: #fff; }
.packet::before { content: ""; position: absolute; left: -10%; right: -10%; top: -50px; height: 86px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, var(--hi) 80%, white); }
.packet .seal { position: absolute; left: 50%; top: 22px; translate: -50% 0; width: 32px; height: 32px; font: 900 13px var(--display); }
.packet .tx { position: absolute; left: 0; right: 0; top: 62px; font-size: 12px; font-weight: 700; } .packet small { display: block; font-size: 10px; color: var(--gold-txt); font-weight: 500; }
.res-tbl { width: 100%; border-collapse: collapse; font-size: 11.5px; margin-top: 4px; }
.res-tbl td { padding: 3px 4px; border-top: 1px dashed var(--line); }
.res-tbl .w { color: var(--success); font-weight: 700; } .res-tbl .l { color: var(--danger); font-weight: 700; }
.nn-bar { padding: 8px 12px calc(10px + var(--safe-bottom)); background: var(--bg3); border-top: 1.5px solid var(--gold2); }
.quick { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 8px; }
.quick button { flex: none; height: 30px; padding: 0 12px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--soft); color: var(--accent-txt); }
.quick button.g { background: var(--g); color: var(--on-gold); }
.chat-in { display: flex; gap: 8px; }
.chat-in input { flex: 1; min-width: 0; height: 40px; padding: 0 14px; border-radius: 99px; background: color-mix(in srgb, black 30%, transparent); border: 0; box-shadow: inset 0 0 0 1px var(--line); outline: 0; font-size: 13px; }
.chat-in button { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--coin); color: var(--on-gold); }
.chat-in svg { width: 17px; height: 17px; }

/* ---------- baccarat ---------- */
.bc-top { display: flex; align-items: center; gap: 8px; height: 56px; }
.bc-top .t { flex: 1; text-align: center; } .bc-top b { font: 900 16px var(--display); } .bc-top small { display: block; font-size: 10.5px; color: var(--muted); }
.bc-top small::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--success); margin-right: 4px; }
.bc-video { display: flex; gap: 10px; }
.bc-screen { position: relative; width: 52%; aspect-ratio: 16/10; overflow: hidden; background: radial-gradient(ellipse at 50% 70%, #1d5a3a, #0a2318 70%); --c: 8px; }
.bc-screen .live { position: absolute; left: 6px; top: 6px; }
.bc-screen .hand { position: absolute; bottom: 8px; display: flex; gap: 3px; } .bc-screen .hand.p { left: 8px; } .bc-screen .hand.b { right: 8px; }
.bc-screen .hand i { width: 20px; height: 28px; border-radius: 3px; background: #fffaf0; color: #111; font-style: normal; font-size: 10px; font-weight: 900; padding: 1px 2px; }
.bc-screen .hand i.r { color: #d2262b; }
.bc-screen .lbl { position: absolute; top: 34%; font-size: 10px; font-weight: 800; } .bc-screen .lbl.p { left: 10px; color: #8ec2ff; } .bc-screen .lbl.b { right: 10px; color: #ff8a8a; }
.bc-info { flex: 1; font-size: 11px; color: var(--muted); line-height: 1.6; }
.bc-info .st { font-size: 14px; color: var(--ink); font-weight: 700; } .bc-info .st b { font-size: 22px; color: var(--gold); margin-left: 6px; }
.road-head { display: flex; align-items: center; gap: 10px; margin: 12px 0 6px; font-size: 12px; font-weight: 700; }
.road-head .b { color: #ff6b6b; } .road-head .p { color: #6fb0ff; } .road-head .t { color: var(--success); }
.roads { display: flex; gap: 2px; padding: 3px; background: #f3efe6; overflow: hidden; --c: 6px; }
.bead { display: grid; grid-template-rows: repeat(6, 18px); grid-auto-flow: column; grid-auto-columns: 18px; gap: 1px; }
.bead i { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 9px; color: #fff; font-weight: 700; }
.bead i.B { background: #d8312f; } .bead i.P { background: #2f6fd8; } .bead i.T { background: #2fa860; }
.bigroad { flex: 1; display: grid; grid-template-rows: repeat(6, 18px); grid-auto-flow: column; grid-auto-columns: 14px; gap: 1px; overflow: hidden;
  background-image: linear-gradient(#ddd6c8 1px, transparent 1px), linear-gradient(90deg, #ddd6c8 1px, transparent 1px); background-size: 15px 19px; }
.bigroad i { width: 12px; height: 12px; margin: 3px 1px; border-radius: 50%; border: 2px solid; }
.bigroad i.B { border-color: #d8312f; } .bigroad i.P { border-color: #2f6fd8; }
.bets { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; margin-top: 12px; }
.bet { position: relative; height: 74px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font: 900 18px var(--display); --c: 9px; }
.bet small { font: 500 10px var(--font); opacity: .85; }
.bet.P { background: linear-gradient(#2f6fd8, #173b80); color: #e6f0ff; } .bet.B { background: linear-gradient(#d8312f, #7a1010); color: #ffe6e6; } .bet.T { background: linear-gradient(#2fa860, #125a33); color: #e6ffef; }
.bet .stake { position: absolute; top: 4px; right: 8px; font: 700 10px var(--font); color: var(--gold1); }
.bets.side { grid-template-columns: 1fr 1fr; } .bets.side .bet { height: 48px; font-size: 13px; }
.chips { display: flex; gap: 8px; justify-content: center; margin-top: 12px; }
.chipc { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 900; color: #fff; border: 3px dashed rgba(255,255,255,.7); box-shadow: 0 0 0 2px rgba(0,0,0,.4); transition: transform .15s; }
.chipc.on { transform: translateY(-4px); box-shadow: 0 0 0 2px var(--gold), 0 4px 12px rgba(242,195,76,.5); }
.c10 { background: #2f6fd8; } .c50 { background: #2fa860; } .c100 { background: #111; } .c500 { background: #8b3fd8; } .c1k { background: #d8a032; }
.bc-acts { display: flex; gap: 8px; margin-top: 12px; } .bc-acts .btn { flex: 1; height: 42px; font-size: 14px; }
.result-flash { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55); font: 900 20px var(--display); }

/* ---------- jackpot page, rules, invite, promos ---------- */
.jp-page .ad { height: 170px; }
.lucky { display: flex; justify-content: center; gap: 6px; margin: 10px 0; }
.lucky i { width: 38px; height: 46px; display: grid; place-items: center; font-style: normal; font: 900 22px "Poppins", sans-serif; color: var(--on-gold); background: var(--g); --c: 6px; }
.flow { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: 11px; color: var(--muted); text-align: center; }
.flow b { display: block; color: var(--accent-txt); font-size: 15px; }
.rule-steps { display: flex; flex-direction: column; gap: 10px; }
.rs { display: flex; gap: 12px; }
.rs b { width: 26px; height: 26px; flex: none; }
.rs h4 { margin: 2px 0 3px; font: 900 14px var(--display); } .rs p { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.55; }
.calc { display: flex; align-items: center; gap: 10px; padding: 12px; background: color-mix(in srgb, black 25%, transparent); margin-top: 8px; font-size: 13px; --c: 7px; }
.calc .amt { font: 800 17px "Poppins", sans-serif; color: var(--gold-txt); } .calc .pts { margin-left: auto; font-weight: 800; color: var(--gold); }
.hands { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
.hand-c { padding: 10px 6px; text-align: center; background: linear-gradient(var(--hi), var(--hi2)); border-radius: 10px; }
.hand-c b { display: block; font: 900 14px var(--display); } .hand-c .a { font: 800 16px "Poppins", sans-serif; color: var(--gold-txt); margin: 2px 0; } .hand-c small { display: block; font-size: 10px; color: var(--gold-txt); opacity: .8; }
.hand-c .x { display: inline-block; margin-top: 4px; padding: 0 8px; border-radius: 99px; font-size: 11px; font-weight: 800; background: var(--g); color: var(--on-gold); }
details.acc { border-top: 1px dashed var(--line); }
details.acc summary { list-style: none; cursor: pointer; padding: 12px 0; font: 900 14px var(--display); display: flex; justify-content: space-between; }
details.acc summary::after { content: "◆"; color: var(--gold); font-size: 10px; transition: transform .2s; } details.acc[open] summary::after { transform: rotate(45deg); }
details.acc p { margin: 0 0 10px; font-size: 12.5px; color: var(--ink); opacity: .9; line-height: 1.65; } details.acc p b { color: var(--accent-txt); }
.inv-hero { position: relative; height: 130px; overflow: hidden; padding: 16px; --c: 16px; background: linear-gradient(var(--hi), var(--hi2));
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c)); }
.inv-hero::before { content: ""; position: absolute; left: -20%; right: 30%; top: -60px; height: 110px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, white 10%, transparent); }
.inv-hero img { position: absolute; right: -4px; bottom: -22px; height: 150px; }
.inv-hero .k { position: relative; font-size: 11px; color: var(--gold-txt); font-weight: 700; } .inv-hero h2 { position: relative; margin: 6px 0; font: 900 26px var(--display); }
.inv-hero p { position: relative; margin: 0; font-size: 11px; color: var(--gold-txt); max-width: 60%; }
.wb-promo { position: relative; margin: 14px auto 12px; width: 100%; }
.wb-hero { position: relative; isolation: isolate; width: 100%; aspect-ratio: 702 / 340; overflow: hidden; --c: 16px;
  background: var(--g);
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, 0 100%, 0 var(--c)); }
.wb-hero::before { content: ""; position: absolute; inset: 1.5px; z-index: -1; background: var(--panel);
  clip-path: polygon(calc(var(--c) - .6px) 0, calc(100% - var(--c) + .6px) 0, 100% calc(var(--c) - .6px), 100% 100%, 0 100%, 0 calc(var(--c) - .6px)); }
.wb-bg { position: absolute; left: calc(-5.70% + 1.5px); top: 1.5px; width: calc(111.40% - 3px); max-width: none; z-index: 0; pointer-events: none;
  filter: sepia(.65) saturate(2.2) hue-rotate(-25deg) brightness(.92); }
.wb-arrow { position: absolute; top: 0; height: 85.9%; z-index: 1; pointer-events: none;
  filter: sepia(.65) saturate(2.2) hue-rotate(-25deg) brightness(.92); }
.wb-arrow-l { left: 0.28%; } .wb-arrow-r { right: 0.28%; }
.wb-k { position: absolute; left: 50%; top: 7%; translate: -50% 0; z-index: 1; font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--gold-txt); white-space: nowrap; }
.wb-qr { position: absolute; left: 50%; top: 22%; translate: -50% 0; z-index: 1; width: 17%; aspect-ratio: 1; background: #fff; padding: 4px; }
.wb-qr svg { width: 100%; height: 100%; display: block; }
.wb-code { position: absolute; left: 50%; top: 63%; translate: -50% 0; z-index: 1; font: 900 20px "Poppins", sans-serif; letter-spacing: 1.5px; color: #fff; white-space: nowrap; }
.wb-caption { position: absolute; left: 50%; top: 80%; translate: -50% 0; z-index: 1; width: 82%; font-size: 10px; line-height: 1.35; text-align: center; color: color-mix(in srgb, #fff 75%, transparent); }
.wb-actions { position: relative; isolation: isolate; padding: 14px 16px 16px; --c: 16px;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)));
  background: var(--g); }
.wb-actions::before { content: ""; position: absolute; inset: 1.5px; z-index: -1; background: var(--panel);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--c) + .6px), calc(100% - var(--c) + .6px) 100%, calc(var(--c) - .6px) 100%, 0 calc(100% - var(--c) + .6px)); }
.wb-actions .two button { position: relative; isolation: isolate; background: var(--g); --c: 8px; }
.wb-actions .two button::before { content: ""; position: absolute; inset: 1px; z-index: -1; background: var(--panel);
  clip-path: polygon(calc(var(--c) - .6px) 0, calc(100% - var(--c) + .6px) 0, 100% calc(var(--c) - .6px), 100% calc(100% - var(--c) + .6px), calc(100% - var(--c) + .6px) 100%, calc(var(--c) - .6px) 100%, 0 calc(100% - var(--c) + .6px), 0 calc(var(--c) - .6px)); }
.wb-actions .two b { position: relative; color: var(--accent-txt); } .wb-actions .two span { position: relative; color: var(--muted); }
.wb-share-row { display: flex; gap: 8px; margin-top: 10px; }
.wb-share-btn, .wb-tg-btn { --c: 8px; clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c)); }
.wb-share-btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; height: 44px;
  background: linear-gradient(180deg, var(--gold1), var(--gold) 45%, var(--gold2)); color: var(--on-gold); font: 800 14px "Poppins", sans-serif; box-shadow: 0 6px 14px -6px rgba(0,0,0,.5); }
.wb-share-btn svg { width: 16px; height: 16px; }
.wb-tg-btn { position: relative; isolation: isolate; flex: none; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  background: var(--g); }
.wb-tg-btn::before { content: ""; position: absolute; inset: 1px; z-index: -1; background: var(--panel);
  clip-path: polygon(calc(var(--c) - .6px) 0, calc(100% - var(--c) + .6px) 0, 100% calc(var(--c) - .6px), 100% calc(100% - var(--c) + .6px), calc(100% - var(--c) + .6px) 100%, calc(var(--c) - .6px) 100%, 0 calc(100% - var(--c) + .6px), 0 calc(var(--c) - .6px)); }
.wb-tg-btn svg { position: relative; color: #229ED9; }
.code-box { display: flex; align-items: center; gap: 12px; }
.qr { width: 92px; height: 92px; background: #fff; padding: 6px; flex: none; --c: 0px; }
.code { display: flex; align-items: center; gap: 6px; font: 900 26px "Poppins", sans-serif; letter-spacing: 2px; color: var(--accent-txt); }
.code svg { width: 16px; height: 16px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 12px 0; }
.two button { padding: 10px; text-align: left; background: var(--soft); --c: 8px; }
.two b { display: block; font-size: 13px; color: var(--accent-txt); } .two span { font-size: 10px; color: var(--muted); }
.how { display: flex; justify-content: space-between; text-align: center; margin-top: 14px; }
.how div { flex: 1; } .how b { margin: 0 auto 4px; width: 28px; height: 28px; }
.how h5 { margin: 0; font: 900 13px var(--display); } .how p { margin: 2px 0 0; font-size: 10px; color: var(--muted); }
.promo .ph { display: flex; gap: 12px; } .promo .ph img { width: 62px; height: 62px; flex: none; }
.promo .k { font-size: 9.5px; color: var(--muted); letter-spacing: 1px; }
.promo h3 { margin: 3px 0; font: 900 18px var(--display); } .promo .ph p { margin: 0; font-size: 12px; color: var(--ink); opacity: .85; }
.promo .big { display: flex; align-items: baseline; justify-content: space-between; border-top: 1px dashed var(--line); margin-top: 12px; padding-top: 10px; }
.promo .big b { font: 900 30px "Poppins", sans-serif; color: var(--accent-txt); } .promo .big small { font-size: 11px; color: var(--gold); font-weight: 700; margin-left: 4px; }
.promo .big span { font-size: 13px; text-align: right; }
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 10px 0; }
.tiers div { padding: 8px 4px; text-align: center; font-size: 11px; background: linear-gradient(var(--hi), var(--hi2)); border-radius: 10px; color: var(--gold-txt); } .tiers b { display: block; font-size: 13px; color: #fff; }
.promo-row { display: flex; align-items: center; gap: 12px; padding: 12px; }
.promo-row .ic { width: 44px; height: 44px; flex: none; font-size: 20px; }
.promo-row .c { flex: 1; min-width: 0; } .promo-row b { font: 900 14px var(--display); } .promo-row p { margin: 2px 0 0; font-size: 11px; color: var(--muted); }
.lb { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.lb th { font-size: 11px; color: var(--muted); font-weight: 500; text-align: left; padding: 6px 4px; }
.lb td { padding: 9px 4px; border-top: 1px dashed var(--line); } .lb td:last-child { color: var(--accent-txt); }
.cd-big { display: flex; justify-content: center; gap: 6px; align-items: center; margin: 8px 0 4px; }
.cd-big b { min-width: 40px; padding: 4px 6px; background: var(--g); color: var(--on-gold); font: 800 20px "Poppins", sans-serif; text-align: center; --c: 6px; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.set-row small { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.tgl { position: relative; width: 44px; height: 26px; border-radius: 99px; background: color-mix(in srgb, black 35%, transparent); box-shadow: inset 0 0 0 1px var(--line); transition: .2s; flex: none; }
.tgl::after { content: ""; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--muted); transition: .2s; }
.tgl.on { background: var(--hi); } .tgl.on::after { left: 21px; background: var(--coin); }

/* ---------- theme picker ---------- */
.th-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.th-sw { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--ink); }
.th-sw .pkt { position: relative; width: 100%; aspect-ratio: 1 / 1.25; border-radius: 12px; overflow: hidden; background: linear-gradient(var(--a), var(--b)); box-shadow: 0 6px 14px -8px rgba(0,0,0,.8); transition: transform .2s; }
.th-sw .pkt::before { content: ""; position: absolute; left: -22%; right: -22%; top: -34px; height: 62px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, var(--a) 75%, white); }
.th-sw .pkt i { position: absolute; left: 50%; top: 16px; translate: -50% 0; width: 26px; height: 26px; border-radius: 50%; background: var(--coin); color: #5a0a0a; display: grid; place-items: center; font: 900 12px var(--display); font-style: normal; }
.th-sw .pkt em { position: absolute; left: 0; right: 0; bottom: 10px; text-align: center; font: 900 20px var(--display); font-style: normal; color: #ffe7a0; }
.th-sw small { font-size: 10px; color: var(--muted); font-weight: 500; margin-top: -4px; }
.th-sw.on .pkt { transform: translateY(-3px); box-shadow: 0 0 0 2px var(--gold), 0 10px 18px -8px rgba(0,0,0,.8); }
.th-sw.on::after { content: "✓"; position: absolute; top: -6px; right: -4px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: var(--coin); color: var(--on-gold); font-size: 11px; font-weight: 900; }
.th-sw:active .pkt { transform: scale(.96); }

/* ---------- theme transition FX ---------- */
#fx { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 9999; pointer-events: none; view-transition-name: fx; }
::view-transition-old(fx) { display: none; }
::view-transition-new(fx) { animation: none; }
::view-transition-group(root), ::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-new(root) { z-index: 2; }
::view-transition-old(root) { z-index: 1; }

/* ---------- overlays ---------- */
.ov { position: absolute; inset: 0; z-index: 80; display: none; align-items: center; justify-content: center; padding: 24px; background: rgba(0,0,0,.7); backdrop-filter: blur(2px); }
.ov.show { display: flex; }
.ov.sheet { align-items: flex-end; padding: 0; }
.dlg { width: 100%; max-width: 360px; max-height: 88%; overflow-y: auto; padding: 18px; --c: 14px; }
.ov.sheet .dlg { max-width: none; border-radius: 0; padding: 18px 16px calc(22px + var(--safe-bottom)); --c: 18px; clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, 0 100%, 0 var(--c)); }
.ov.sheet .dlg::before { clip-path: none; inset: 1.5px 0 0; border-radius: 0; }
.dlg h3 { margin: 0 0 14px; text-align: center; font: 900 19px var(--display); color: var(--accent-txt); }
.dlg .lead { margin: -8px 0 14px; text-align: center; font-size: 12px; color: var(--muted); }
.dlg .box { padding: 14px; background: color-mix(in srgb, black 25%, transparent); --c: 9px; }
.dlg .box + .box { margin-top: 10px; }
.dlg .box h4 { margin: 0 0 6px; font: 900 16px/1.35 var(--display); color: var(--gold); }
.dlg .box p { margin: 0 0 12px; font-size: 12.5px; color: var(--ink); opacity: .9; line-height: 1.5; }
.dlg .got { display: block; margin: 14px auto 0; color: var(--muted); font-size: 13px; }
.lang-screen { position: absolute; inset: 0; z-index: 90; display: flex; flex-direction: column; align-items: center; padding: 56px 24px 24px; background: inherit; }
.lang-screen .logo { align-items: center; margin-bottom: 6px; }
.lang-screen img.m { height: 150px; margin-bottom: 10px; }
.lang-screen h2 { margin: 0; font: 900 19px var(--display); color: var(--accent-txt); } .lang-screen p { margin: 4px 0 18px; font-size: 12px; color: var(--muted); }
.lang-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; }
.lang-grid button { height: 54px; font-size: 15px; font-weight: 700; --c: 9px; }
.toast { position: absolute; left: 50%; top: 70px; z-index: 99; translate: -50% -10px; opacity: 0; pointer-events: none; max-width: 86%; padding: 10px 18px; font-size: 13px; text-align: center; font-weight: 700;
  background: var(--g); color: var(--on-gold); transition: .25s; border-radius: 99px; }
.toast.show { opacity: 1; translate: -50% 0; }
.game-frame { position: absolute; inset: 0; z-index: 70; display: flex; flex-direction: column; background: #000; }
.game-frame .gf-top { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 10px; background: var(--bg3); border-bottom: 1.5px solid var(--gold2); font-weight: 700; }
.game-frame iframe { flex: 1; width: 100%; border: 0; }
.demo-note { margin: 18px 0 0; text-align: center; font-size: 10.5px; color: color-mix(in srgb, var(--muted) 60%, transparent); }

@media (min-width: 431px) { .app { box-shadow: 0 0 0 1px var(--line); } }
@media (prefers-reduced-motion: reduce) { .fsf, .marquee .track span { animation: none; } }

/* ---------- artwork (Higgsfield set) ---------- */
.ad.pic img { width: 100%; height: 100%; object-fit: cover; }
.chip i.pic { background: none; box-shadow: none; width: 26px; height: 26px; }
.chip i.pic img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 1px 1px rgba(0,0,0,.35)); }
.chip.on i.pic { background: none; }
.room .ri { display: block; padding: 0; }
.room .ri img { position: absolute; left: -4px; right: -4px; bottom: -4px; width: calc(100% + 8px); height: 100%; object-fit: cover; object-position: top; }
.bacc-card .bc-art { position: absolute; right: 6px; bottom: -6px; height: 128px; filter: drop-shadow(0 6px 10px rgba(0,0,0,.5)); }
.jp-hero { position: relative; border-radius: 16px; overflow: hidden; box-shadow: 0 12px 24px -12px rgba(0,0,0,.8); }
.jp-hero img { display: block; width: 100%; aspect-ratio: 343 / 164; object-fit: cover; }
.jp-hero .tx { position: absolute; left: 0; top: 0; bottom: 0; width: 46%; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
.jp-hero .jp-amt b { font-size: 22px; } .jp-hero .jp-amt small { font-size: 11px; }
.inv-hero { background: var(--hi2) url("img/art/hdr-referral.webp") right center / cover no-repeat; }
.inv-hero::before { display: none; }
.inv-hero h2, .inv-hero .k, .inv-hero p { text-shadow: 0 2px 6px rgba(0,0,0,.5); }
.msg .av.bot { background: var(--coin); overflow: hidden; }
.msg .av.bot img { width: 118%; height: 118%; object-fit: cover; object-position: top; }
.packet-anim { position: relative; width: 210px; text-align: center; }
.packet-anim img { width: 150px; height: 150px; margin: -6px auto -10px; object-fit: contain; }
.packet-anim b { display: block; font-size: 12.5px; } .packet-anim small { font-size: 10px; color: var(--muted); }
.res-head { display: flex; align-items: center; gap: 8px; }
.res-head img { width: 44px; height: 44px; object-fit: contain; }
.win { text-align: center; }
.win img { width: 190px; height: 190px; margin: -10px auto 0; object-fit: contain; }
.lang-screen img.m { height: 170px; }

/* ---------- living game tiles ---------- */
.pk-grid { perspective: 700px; }
.pk { --rx: 0deg; --ry: 0deg; transform: rotateX(var(--rx)) rotateY(var(--ry)); transition: transform .35s cubic-bezier(.2,.8,.2,1); transform-style: preserve-3d; }
.pk.tilt { transition: transform .08s linear; }
.pk:active { scale: .97; }
/* gold sheen sweeping across the packet */
.pk::after { content: ""; position: absolute; inset: -20% -60%; z-index: 3; pointer-events: none; background: linear-gradient(105deg, transparent 42%, rgba(255,240,190,.38) 49%, rgba(255,255,255,.55) 50%, rgba(255,240,190,.38) 51%, transparent 58%);
  transform: translateX(-70%); animation: pkSheen 4.8s ease-in-out infinite; }
.pk.s2::after { animation-delay: 1.6s; } .pk.s3::after { animation-delay: 3.2s; }
@keyframes pkSheen { 0%, 62% { transform: translateX(-70%); } 82%, 100% { transform: translateX(70%); } }
.pk img { z-index: 1; transform-origin: 50% 90%; will-change: transform; }
/* 1 · Speed: wind-up, slam, recoil, with a flash on impact */
.pk.s1 img { animation: pkSlam 2.6s cubic-bezier(.3,0,.2,1) infinite; }
@keyframes pkSlam { 0%, 55% { transform: translateY(0) rotate(0) scale(1); } 66% { transform: translateY(-7%) rotate(-5deg) scale(1.03); } 72% { transform: translateY(3%) rotate(2deg) scale(.98); }
  78% { transform: translateY(-1%) rotate(-1deg) scale(1.01); } 86%, 100% { transform: translateY(0) rotate(0) scale(1); } }
.pk .flash { position: absolute; left: 50%; top: 66%; width: 70%; aspect-ratio: 1; translate: -50% -50%; z-index: 2; border-radius: 50%; pointer-events: none; opacity: 0;
  background: radial-gradient(circle, rgba(255,250,220,.95), rgba(255,200,80,.55) 35%, transparent 65%); animation: pkFlash 2.6s ease-out infinite; mix-blend-mode: screen; }
@keyframes pkFlash { 0%, 71% { opacity: 0; transform: scale(.4); } 73% { opacity: 1; transform: scale(1); } 90%, 100% { opacity: 0; transform: scale(1.5); } }
/* 2 · TNG: floats and bobs, packet glow pulses */
.pk.s2 img { animation: pkFloat 3.2s ease-in-out infinite; }
@keyframes pkFloat { 0%, 100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-6%) rotate(1.5deg); } }
.pk .glow { position: absolute; right: 6%; top: 18%; width: 46%; aspect-ratio: 1; z-index: 0; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255,214,107,.75), transparent 65%); animation: pkGlow 1.6s ease-in-out infinite alternate; mix-blend-mode: screen; }
@keyframes pkGlow { from { opacity: .35; transform: scale(.85); } to { opacity: 1; transform: scale(1.15); } }
/* 3 · Baccarat: dealer sway with a breath */
.pk.s3 img { animation: pkSway 3.6s ease-in-out infinite; }
@keyframes pkSway { 0%, 100% { transform: rotate(-2deg) scale(1); } 50% { transform: rotate(2deg) scale(1.03); } }
/* twinkling gold sparkles */
.pk .spk { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.pk .spk i { position: absolute; width: 9px; height: 9px; background: radial-gradient(circle, #fff 0 18%, transparent 20%), linear-gradient(transparent 44%, #ffe9a8 44% 56%, transparent 56%), linear-gradient(90deg, transparent 44%, #ffe9a8 44% 56%, transparent 56%);
  opacity: 0; animation: pkTwinkle 2.4s ease-in-out infinite; filter: drop-shadow(0 0 3px #ffd56b); }
.pk .spk i:nth-child(1) { left: 14%; top: 22%; animation-delay: .2s; } .pk .spk i:nth-child(2) { left: 78%; top: 40%; animation-delay: 1s; width: 7px; height: 7px; }
.pk .spk i:nth-child(3) { left: 24%; top: 58%; animation-delay: 1.6s; } .pk .spk i:nth-child(4) { left: 64%; top: 14%; animation-delay: 2.1s; width: 6px; height: 6px; }
.pk.s2 .spk i { animation-duration: 2s; } .pk.s3 .spk i { animation-duration: 2.8s; }
@keyframes pkTwinkle { 0%, 100% { opacity: 0; transform: scale(.2) rotate(0); } 45% { opacity: 1; transform: scale(1) rotate(45deg); } 60% { opacity: 0; transform: scale(.3) rotate(90deg); } }
/* live counters */
.pk .n { z-index: 4; transition: transform .2s; }
.pk .n.bump { animation: pkBump .5s ease-out; }
@keyframes pkBump { 0% { transform: scale(1); } 35% { transform: scale(1.3); background: #fff; } 100% { transform: scale(1); } }
.pk .live-n::before { content: ""; display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: #e0242a; margin-right: 3px; vertical-align: 1px; animation: pkLive 1s ease-in-out infinite alternate; }
@keyframes pkLive { from { opacity: .3; } to { opacity: 1; box-shadow: 0 0 5px #ff3b3b; } }
.pk b, .pk small { z-index: 4; }
@media (prefers-reduced-motion: reduce) { .pk img, .pk::after, .pk .flash, .pk .glow, .pk .spk i, .pk .n.bump, .pk .live-n::before { animation: none !important; } .pk { transform: none; } }

/* ---------- split banners: text panel + artwork ---------- */
.ad.split { display: grid; grid-template-columns: 46% 54%; background: var(--bg3) padding-box, var(--molten) border-box; }
.ad.split .bt { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 10px 8px; text-align: center;
  background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--hi) 55%, var(--bg2)), var(--bg3) 75%); }
.ad.split .bt::before { content: ""; position: absolute; inset: 7px; border: 1px solid color-mix(in srgb, var(--gold) 55%, transparent); pointer-events: none;
  clip-path: polygon(8px 0, calc(100% - 8px) 0, 100% 8px, 100% calc(100% - 8px), calc(100% - 8px) 100%, 8px 100%, 0 calc(100% - 8px), 0 8px); }
.ad.split .bt::after { content: ""; position: absolute; top: 0; bottom: 0; right: 0; width: 2px; background: var(--g); }
.ad.split .k { display: inline-flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 700; letter-spacing: .12em; color: var(--accent-txt); }
.ad.split .k .live { font-style: normal; font-size: 8.5px; letter-spacing: 0; padding: 1px 5px; }
.ad.split b { font: 900 34px/1.05 "Poppins", var(--display); letter-spacing: -.5px; background: linear-gradient(#fff 10%, var(--gold1) 45%, var(--gold) 70%, var(--gold2)); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 2px 0 rgba(0,0,0,.35)); }
.ad.split b.md { font-size: 25px; }
.ad.split b.sm { font: 900 25px/1.1 var(--display); letter-spacing: 1px; }
.ad.split .s { font-size: 10.5px; color: var(--ink); opacity: .9; line-height: 1.35; }
.ad.split .ba { position: relative; overflow: hidden; }
.ad.split .ba img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 35%; }
.ad.split .ba.cut-art { background: radial-gradient(ellipse 70% 45% at 50% 100%, #1f7a4a, #0d3a24 60%, transparent 61%), radial-gradient(circle at 50% 20%, rgba(255,214,120,.55), transparent 55%), linear-gradient(#2a1206, #120802); }
.ad.split .ba.cut-art img { position: absolute; left: 50%; bottom: -6px; translate: -50% 0; width: auto; height: 104%; object-fit: contain; filter: drop-shadow(0 8px 12px rgba(0,0,0,.6)); }

/* ---------- footer note ---------- */
.legal { margin: 22px 0 0; text-align: center; font-size: 10.5px; letter-spacing: .02em; color: color-mix(in srgb, var(--muted) 70%, transparent); }

/* ---------- deposit form ---------- */
.pm-list { display: grid; gap: 8px; }
.pm { display: flex; align-items: center; gap: 12px; padding: 10px 12px; text-align: left; background: rgba(0,0,0,.25); box-shadow: inset 0 0 0 1px var(--line); border-radius: 12px; }
.pm i { width: 42px; height: 30px; flex: none; border-radius: 6px; display: grid; place-items: center; color: #fff; font: 800 10.5px "Poppins", sans-serif; font-style: normal; }
.pm b { display: block; font-size: 13.5px; } .pm small { font-size: 11px; color: var(--muted); }
.pm.on { box-shadow: inset 0 0 0 2px var(--gold); background: var(--soft); }
.opt-row { display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: linear-gradient(90deg, color-mix(in srgb, var(--hi) 35%, transparent), transparent); cursor: pointer; }
.opt-row input { width: 20px; height: 20px; accent-color: var(--gold); flex: none; }
.opt-row b { display: block; font-size: 13px; color: var(--accent-txt); } .opt-row small { font-size: 11px; color: var(--muted); }
.lbl-f { display: block; font-size: 12px; color: var(--muted); margin: 10px 0 6px; }

/* ---------- withdraw ---------- */
.prog { height: 8px; border-radius: 99px; background: rgba(0,0,0,.35); overflow: hidden; margin-top: 10px; }
.prog i { display: block; height: 100%; background: var(--g); border-radius: 99px; }
.chks { display: grid; gap: 8px; margin-top: 10px; }
.chk { display: flex; align-items: center; gap: 10px; padding: 10px 12px; text-align: left; border-radius: 12px; background: rgba(0,0,0,.25); }
.chk i { width: 26px; height: 26px; flex: none; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 900; background: var(--hi); color: #fff; }
.chk.ok i { background: var(--success); }
.chk span { flex: 1; min-width: 0; } .chk b { display: block; font-size: 13px; } .chk small { font-size: 11px; color: var(--muted); }
.chk em { font-style: normal; font-size: 11.5px; color: var(--accent-txt); white-space: nowrap; } .chk.ok em { color: var(--success); }
.st { display: inline-block; margin-top: 3px; padding: 1px 8px; border-radius: 99px; font-size: 10px; font-weight: 700; }
.st.done { background: color-mix(in srgb, var(--success) 22%, transparent); color: var(--success); }
.st.review { background: color-mix(in srgb, var(--gold) 22%, transparent); color: var(--accent-txt); }
.st.off { background: rgba(255,255,255,.08); color: var(--muted); }
.sec-card.done span { color: var(--success); }


/* ---------- blind box ---------- */
.boxes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.bx { position: relative; aspect-ratio: 1 / 1.25; border-radius: 12px; overflow: hidden; background: linear-gradient(var(--hi), var(--hi2)); box-shadow: 0 8px 16px -8px rgba(0,0,0,.7); animation: bxIdle 2.4s ease-in-out infinite; }
.bx:nth-child(2) { animation-delay: .3s; } .bx:nth-child(3) { animation-delay: .6s; }
.bx .flap { position: absolute; left: -20%; right: -20%; top: -30px; height: 60px; border-radius: 0 0 50% 50%; background: color-mix(in srgb, var(--hi) 75%, white); }
.bx i { position: absolute; left: 50%; top: 24px; translate: -50% 0; width: 34px; height: 34px; font: 900 15px var(--display); font-style: normal; }
.bx.off { filter: grayscale(.7) brightness(.7); animation: none; }
@keyframes bxIdle { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-4px) rotate(-1.5deg); } }
.lucky-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.lucky-list span { padding: 4px 10px; border-radius: 8px; background: var(--g); color: var(--on-gold); font-weight: 800; letter-spacing: 2px; font-size: 13px; }
.udot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--hi); margin-right: 6px; vertical-align: 1px; }

/* ---------- live chat ---------- */
.chat { position: absolute; inset: 0; z-index: 30; display: flex; flex-direction: column; background: var(--bg1); }
.ch-top { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg3); border-bottom: 1.5px solid var(--gold2); }
.ch-top img { width: 40px; height: 40px; border-radius: 50%; background: var(--coin); object-fit: cover; object-position: top; }
.ch-top .t { flex: 1; min-width: 0; } .ch-top b { font: 900 15px var(--display); } .ch-top small { display: block; font-size: 11px; color: var(--success); }
.ch-log { flex: 1; overflow-y: auto; padding: 14px 12px; display: flex; flex-direction: column; gap: 10px; scrollbar-width: none;
  background: repeating-linear-gradient(45deg, color-mix(in srgb, var(--gold) 4%, transparent) 0 1px, transparent 1px 22px); }
.cm { display: grid; gap: 2px 8px; max-width: 86%; }
.cm.in { grid-template-columns: 32px auto; align-self: flex-start; } .cm.out { align-self: flex-end; justify-items: end; }
.cm img, .cm .ag { grid-row: span 2; width: 32px; height: 32px; border-radius: 50%; background: var(--coin); object-fit: cover; object-position: top; }
.cm .ag { display: grid; place-items: center; font-style: normal; font-size: 9.5px; font-weight: 800; color: var(--on-gold); }
.cm .b { padding: 8px 12px; border-radius: 4px 14px 14px 14px; background: rgba(0,0,0,.38); box-shadow: inset 0 0 0 1px var(--line); font-size: 13px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.cm.out .b { background: var(--g); color: var(--on-gold); box-shadow: none; border-radius: 14px 4px 14px 14px; }
.cm small { font-size: 9.5px; color: var(--muted); } .cm.in small { grid-column: 2; }
.ch-bar { padding: 8px 12px calc(10px + var(--safe-bottom)); background: var(--bg3); border-top: 1.5px solid var(--gold2); }

/* ---------- lucky wheel ---------- */
.wheel { position: relative; width: min(330px, 92%); aspect-ratio: 1; margin: 6px auto 16px; }
.wh-svg { width: 100%; height: 100%; display: block; filter: drop-shadow(0 10px 24px rgba(0,0,0,.55)); }
#whRot { transform-origin: 0 0; transform-box: view-box; }
.wh-bulb { animation: whBulb 1s steps(1) infinite; }
@keyframes whBulb { 50% { fill: #f2c34c; } }
.wh-ptr { position: absolute; left: 50%; top: -6px; translate: -50% 0; z-index: 2; width: 34px; height: 44px; background: var(--g); clip-path: polygon(50% 100%, 0 0, 100% 0); filter: drop-shadow(0 3px 3px rgba(0,0,0,.5)); }
.wh-go { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 26%; aspect-ratio: 1; flex-direction: column; gap: 0; box-shadow: 0 0 0 5px #3a0505, 0 0 0 7px #f2c34c, 0 6px 16px rgba(0,0,0,.6); }
.wh-go b { font: 900 18px "Poppins", sans-serif; line-height: 1; } .wh-go small { font-size: 9.5px; font-weight: 700; }
.wh-go:disabled { filter: grayscale(.6) brightness(.8); }
.wh-prizes { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.wh-prizes span { padding: 4px 10px; border-radius: 99px; background: var(--soft); font-size: 12px; font-weight: 700; color: var(--accent-txt); }
.wh-prizes span.top { background: var(--g); color: var(--on-gold); }
@media (prefers-reduced-motion: reduce) { .wh-bulb { animation: none; } }

/* ---------- side menu (slide-in drawer) ---------- */
.sidemenu { position: fixed; inset: 0; z-index: 60; pointer-events: none; }
.sidemenu-scrim { position: absolute; inset: 0; background: rgba(0,0,0,.55); opacity: 0; transition: opacity .25s; }
.sidemenu-panel { position: absolute; left: 0; top: 0; bottom: 0; width: 78%; max-width: 300px; background: linear-gradient(180deg, var(--bg2), var(--bg0) 60%); box-shadow: 4px 0 24px rgba(0,0,0,.5); transform: translateX(-100%); transition: transform .3s cubic-bezier(.3,.9,.3,1); overflow-y: auto; padding: 18px 14px calc(24px + var(--safe-bottom)); scrollbar-width: none; display: flex; flex-direction: column; }
.sidemenu.show { pointer-events: auto; }
.sidemenu.show .sidemenu-scrim { opacity: 1; }
.sidemenu.show .sidemenu-panel { transform: translateX(0); }
.sm-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.sm-avatar { width: 48px; height: 48px; }
.sm-who .nm { font-weight: 800; font-size: 14px; color: var(--ink); }
.sm-who .uid { font-size: 11px; color: var(--muted); }
.sm-bal { justify-content: space-between; margin-bottom: 16px; }
.sm-bal svg { width: 13px; height: 13px; }
.sm-group { display: flex; flex-direction: column; gap: 8px; }
.sm-row { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; color: var(--ink); }
.sm-big { background: var(--soft); }
.sm-ic { width: 34px; height: 34px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--coin); color: var(--on-gold); }
.sm-ic svg { width: 17px; height: 17px; }
.sm-ic-plain { background: none; color: var(--muted); width: 22px; height: 22px; }
.sm-ic-plain svg { width: 18px; height: 18px; }
.sm-lbl { flex: 1; font-weight: 700; font-size: 13.5px; }
.sm-chev { width: 16px; height: 16px; color: var(--muted); flex: none; } .sm-chev svg { width: 100%; height: 100%; }
.sm-div { height: 1px; background: var(--line); margin: 14px 0; }
.sm-group-plain { gap: 4px; }
.sm-group-plain .sm-row { padding: 8px 10px; }
.sm-spacer { flex: 1; min-height: 20px; }
.sm-lang { padding: 8px 10px; }
.sm-version { text-align: center; font-size: 10px; color: var(--muted); opacity: .6; margin-top: 10px; }
body.menu-open { overflow: hidden; }

/* ---------- intro door-open animation (plays once on first load) ---------- */
.intro-doors { position: fixed; inset: 0; z-index: 9999; pointer-events: none; }
.intro-door { position: absolute; top: 0; bottom: 0; width: 50.5%; overflow: hidden; transition: transform .6s cubic-bezier(.65,0,.25,1); will-change: transform; backface-visibility: hidden; contain: layout paint; transform: translate3d(0,0,0);
  background: linear-gradient(rgba(0,0,0,.6), rgba(0,0,0,.6)), url("img/bg-neon.svg") no-repeat, var(--bg0); background-size: auto, 200% 100%, auto;
  box-shadow: inset 0 0 0 4px var(--gold2), inset 0 0 0 7px var(--bg0), inset 0 0 0 8px var(--gold); }
.intro-door.l { left: 0; background-position: 0 0, left top, 0 0; } .intro-door.r { right: 0; background-position: 0 0, right top, 0 0; }
.intro-door i { position: absolute; top: 50%; width: 110px; height: 110px; margin-top: -55px; border-radius: 50%; display: grid; place-items: center; overflow: hidden;
  background: var(--coin); box-shadow: 0 0 0 4px var(--bg0), 0 0 0 6px var(--gold); }
.intro-door i img { width: 86%; height: 86%; object-fit: cover; border-radius: 50%; }
.intro-door.l i { right: -55px; } .intro-door.r i { left: -55px; }
.intro-doors.go .intro-door.l { transform: translate3d(-102%,0,0); } .intro-doors.go .intro-door.r { transform: translate3d(102%,0,0); }
.intro-doors.go.shut .intro-door { transform: translate3d(0,0,0); transition-duration: .5s; }
.intro-doors.open .intro-door.l { transform: translate3d(-102%,0,0); } .intro-doors.open .intro-door.r { transform: translate3d(102%,0,0); }

/* ---------- game board: one hero gate + three scale tiles (ported as-is from LONG888's Dragon Realm skin) ---------- */
:root { --molten: conic-gradient(from var(--a), #ffd36b, rgba(255,90,31,.12) 18%, rgba(255,211,107,0) 40%, rgba(255,106,31,.85) 62%, rgba(255,211,107,.08) 80%, #ffd36b); --ember: #ff6a1f; --ember2: #ffb24a; --jade: #26e0a8; }
@keyframes realmSpin { to { --a: 360deg; } }
@keyframes realmBob { 50% { transform: translateY(-7px) rotate(-1.2deg); } }
.gboard { --cut: 16px; display: grid; gap: 12px; margin-top: 32px; }
.gate, .gt { position: relative; display: block; color: var(--ink); filter: drop-shadow(0 10px 18px rgba(0,0,0,.55)); }
.gt-edge, .gt-fill { position: absolute; inset: 0; clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.gt-edge { background: var(--molten); animation: realmSpin 6s linear infinite; }
.gt-fill { inset: 2.5px; background: radial-gradient(70% 90% at 78% 45%, rgba(255,106,31,.4), transparent 70%), linear-gradient(165deg, rgba(44,18,14,.9), rgba(8,4,6,.95)); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.gt.gd .gt-fill { background: radial-gradient(80% 70% at 50% 40%, rgba(255,210,107,.4), transparent 72%), linear-gradient(165deg, rgba(74,44,12,.92), rgba(14,8,6,.95)); }
.gt.more .gt-fill { background: linear-gradient(165deg, rgba(34,18,14,.85), rgba(8,4,6,.92)); }
.gate { height: 116px; margin-top: 18px; }
.gt-tx { position: absolute; z-index: 2; left: 16px; top: 10px; bottom: 10px; width: 52%; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 3px; }
.gt-tx b { font: 900 italic 19px/1.05 var(--display); background: linear-gradient(180deg, #fff6d6, #ffc457 60%, #e0701a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.gt-tx small { font-size: 10.5px; color: #e6bd8a; }
.gt-go { margin-top: 5px; padding: 5px 15px; border-radius: 99px; font: 800 12px var(--display); color: #3a1204; background: linear-gradient(135deg, #ffd36b, #ff7a1f); box-shadow: 0 0 18px rgba(255,122,31,.6); }
.gt-art { position: absolute; z-index: 1; right: 4px; bottom: 3px; height: 126%; width: auto; max-width: 52%; object-fit: contain; filter: drop-shadow(0 10px 14px rgba(0,0,0,.6)) drop-shadow(0 0 16px rgba(255,140,40,.4)); animation: realmBob 3.6s ease-in-out infinite; transform-origin: 50% 100%; pointer-events: none; }
.gt-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.gt { aspect-ratio: 1 / 1.12; }
.gt img { position: absolute; left: 50%; top: 5%; width: 96%; height: 68%; transform: translateX(-50%); object-fit: contain; filter: drop-shadow(0 8px 10px rgba(0,0,0,.6)) drop-shadow(0 0 12px rgba(255,140,40,.35)); transition: transform .4s cubic-bezier(.2,1.4,.4,1); pointer-events: none; }
.gt.gd img { transform: translateX(-50%) scale(1.3); }
.gt:hover img, .gt:active img { transform: translateX(-50%) translateY(-4px) scale(1.07); }
.gt.gd:hover img, .gt.gd:active img { transform: translateX(-50%) translateY(-4px) scale(1.38); }
.gt b { position: absolute; left: 6px; right: 6px; bottom: 10px; text-align: center; font: 800 12px/1.15 var(--display); color: #fff3de; text-shadow: 0 2px 8px #000; }
.gt.more .plus { position: absolute; left: 0; right: 0; top: 20%; text-align: center; font: 300 46px/1 var(--display); color: var(--ember2); text-shadow: 0 0 16px rgba(255,140,40,.7); }
.gt-ic { position: absolute; left: 50%; top: 18%; width: 46px; height: 46px; transform: translateX(-50%); display: grid; place-items: center; color: var(--ember2); filter: drop-shadow(0 0 12px rgba(255,140,40,.5)); }
.gt-ic svg { width: 100%; height: 100%; }
.gt .n, .gate .n { z-index: 3; font: 700 9px var(--display); padding: 2px 7px; border-radius: 99px; background: rgba(0,0,0,.6); color: var(--jade); border: 1px solid rgba(38,224,168,.5); }
.gt .n { position: absolute; top: 8px; right: 8px; }
.gate .n { margin-bottom: 4px; }
.gt .n:empty, .gate .n:empty { display: none; }
.gt .n::before, .gate .n::before { content: ""; display: inline-block; width: 5px; height: 5px; margin-right: 4px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; vertical-align: middle; }
.gt .n.live-n, .gate .n.live-n { color: #ff3b3b; border-color: rgba(255,59,59,.5); }
.grid2:empty, .gboard:empty { display: none; }
@media (prefers-reduced-motion: reduce) { .gt-edge, .gt-art { animation: none !important; } }


/* ---------- tile motion: free, code-only "video" feel (floating art, light sweep, twinkles) ---------- */
@keyframes gtFloat { 50% { translate: 0 -5px; } }
@keyframes gtSweep { 0% { background-position: 130% 0; } 55%, 100% { background-position: -60% 0; } }
@keyframes gtTwinkle { 0%, 100% { opacity: 0; scale: .3; } 45% { opacity: 1; scale: 1; } 70% { opacity: .2; scale: .6; } }
.gt img { animation: gtFloat 3.6s ease-in-out infinite; }
.gt-row .gt:nth-child(2) img { animation-delay: -1.2s; } .gt-row .gt:nth-child(3) img { animation-delay: -2.4s; }
.gt-svg { position: absolute; left: 50%; top: 5%; width: 82%; height: 68%; transform: translateX(-50%); pointer-events: none; animation: gtFloat 3.6s ease-in-out infinite; filter: drop-shadow(0 8px 10px rgba(0,0,0,.6)) drop-shadow(0 0 14px rgba(255,140,40,.4)); transition: transform .4s cubic-bezier(.2,1.4,.4,1); }
.gt-svg svg { display: block; width: 100%; height: 100%; overflow: visible; }
.gt:hover .gt-svg, .gt:active .gt-svg { transform: translateX(-50%) translateY(-4px) scale(1.07); }
.gt-row .gt:nth-child(2) .gt-svg { animation-delay: -1.2s; } .gt-row .gt:nth-child(3) .gt-svg { animation-delay: -2.4s; }
.gt.vid .gt-vid { position: absolute; inset: 2.5px; z-index: 1; width: calc(100% - 5px); height: calc(100% - 5px); object-fit: cover; pointer-events: none; animation: none; translate: none; transform: none;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.gt.vid .gt-vshade { position: absolute; inset: 2.5px; z-index: 2; pointer-events: none; background: linear-gradient(to top, rgba(0,0,0,.9) 0%, rgba(0,0,0,.45) 50%, rgba(0,0,0,0) 100%);
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.gt.vid .gt-shine { z-index: 3; } .gt.vid .gt-sp { display: none; } .gt.vid b { z-index: 4; text-shadow: 0 1px 3px rgba(0,0,0,.9), 0 2px 10px rgba(0,0,0,.8); }
.gt.vid:hover .gt-vid, .gt.vid:active .gt-vid { transform: none; }
.gt-shine { position: absolute; inset: 2.5px; pointer-events: none; z-index: 2; background: linear-gradient(115deg, transparent 38%, rgba(255,226,150,.30) 50%, transparent 62%); background-size: 260% 100%; animation: gtSweep 5s ease-in-out infinite;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.gt-row .gt:nth-child(2) .gt-shine { animation-delay: -1.6s; } .gt-row .gt:nth-child(3) .gt-shine { animation-delay: -3.2s; }
.gt-sp { position: absolute; z-index: 3; width: 9px; height: 9px; pointer-events: none; opacity: 0; background: #fff3c2; box-shadow: 0 0 8px 2px rgba(255,200,90,.8);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: gtTwinkle 2.8s ease-in-out infinite; }
.gt-sp.s1 { left: 16%; top: 22%; } .gt-sp.s2 { right: 18%; top: 34%; animation-delay: -.9s; width: 7px; height: 7px; } .gt-sp.s3 { left: 44%; top: 12%; animation-delay: -1.8s; width: 6px; height: 6px; }
.gate .gt-sp.s1 { left: 56%; top: 20%; } .gate .gt-sp.s2 { right: 6%; top: 46%; } .gate .gt-sp.s3 { left: 40%; top: 70%; }
@media (prefers-reduced-motion: reduce) { .gt img, .gt-svg, .gt-shine, .gt-sp { animation: none !important; } .gt-sp { display: none; } }

/* ---------- referral page ---------- */

/* ---------- partner logo strip ---------- */
.partners { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 4px 0 22px; }
.partners .pv { height: 46px; display: grid; place-items: center; padding: 0 10px; border: 1px solid rgba(242,195,76,.22); background: rgba(255,255,255,.03); clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); }
.partners .pv img { max-width: 100%; max-height: 22px; filter: brightness(0) invert(1); opacity: .78; }
.partners .pv-t { font: 800 13px/1 Poppins, sans-serif; letter-spacing: .08em; color: #fff; opacity: .78; white-space: nowrap; }
.partners .pv img[src*="pragmatic"] { max-height: 36px; }

/* ---------- Slots page (Lucky365) ---------- */
.slot-search { margin: 4px 0 12px; } .slot-search input { width: 100%; height: 42px; padding: 0 14px; border-radius: 12px; border: 1.5px solid rgba(255,178,74,.3); background: rgba(255,255,255,.05); color: var(--ink); font: 600 14px "Poppins", sans-serif; outline: none; } .slot-search input:focus { border-color: var(--gold); }
.slot-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding-bottom: 20px; }
.slot-tile { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; aspect-ratio: 1 / 1.1; padding: 10px 6px 10px; border: 1.5px solid rgba(255,178,74,.28); color: var(--ink); text-align: center; overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, rgba(226,35,31,.45), rgba(20,8,8,.95) 70%); clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); }
.slot-tile i { position: absolute; top: 10px; left: 50%; translate: -50% 0; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font: 900 22px "Poppins", sans-serif; font-style: normal; color: #3a1d05; background: linear-gradient(160deg, #ffe08a, #e2a21a); box-shadow: 0 0 0 2px rgba(255,178,74,.4); }
.slot-tile b { font: 700 11.5px/1.2 "Poppins", sans-serif; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.slot-tile:active { transform: scale(.97); }

/* ---------- website login screen ---------- */
.auth-gate { position: fixed; inset: 0; z-index: 10000; display: grid; place-items: center; padding: 16px; overflow-y: auto;
  background: linear-gradient(rgba(0,0,0,.82), rgba(0,0,0,.82)), url("img/bg-neon.svg") center / cover no-repeat, var(--bg0); }
.auth-card { position: relative; width: 100%; max-width: 400px; padding: 26px 22px 22px; border: 2px solid transparent; color: var(--ink); --cut-w: 18px;
  clip-path: polygon(var(--cut-w) 0, 100% 0, 100% calc(100% - var(--cut-w)), calc(100% - var(--cut-w)) 100%, 0 100%, 0 var(--cut-w));
  background: linear-gradient(165deg, rgba(44,18,14,.94), rgba(8,4,6,.97)) padding-box, var(--molten) border-box; }
.auth-card .logo { justify-content: center; margin: 4px 0 16px; } .auth-card .logo .wordmark { font-size: 40px; }
.auth-lang { position: absolute; top: 10px; right: 14px; } .auth-lang button { font: 700 12px "Poppins", sans-serif; color: var(--gold); padding: 4px 8px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 14px; }
.auth-tabs button { height: 40px; font: 800 14px "Poppins", sans-serif; color: var(--muted); border-bottom: 2px solid rgba(255,178,74,.2); }
.auth-tabs button.on { color: var(--gold); border-bottom-color: var(--gold); }
.auth-card label, .auth-dlg label { display: block; margin-bottom: 12px; font: 700 12px "Poppins", sans-serif; color: var(--muted); }
.auth-card input, .auth-dlg input { display: block; width: 100%; height: 44px; margin-top: 5px; padding: 0 14px; border-radius: 12px; border: 1.5px solid rgba(255,178,74,.3); background: rgba(255,255,255,.05); color: var(--ink); font: 600 15px "Poppins", sans-serif; outline: none; }
.auth-card input:focus, .auth-dlg input:focus { border-color: var(--gold); }
.auth-err { min-height: 18px; margin: -2px 0 10px; font-size: 12.5px; color: #ff8a7a; }
.auth-note { margin: 14px 0 0; text-align: center; font-size: 12px; color: var(--muted); }

/* ---------- computer version: full-width layout with a sidebar (>= 1024px) ---------- */
.dside { display: none; }
@media (min-width: 1024px) {
  .app { max-width: none; box-shadow: none; }
  .bnav { left: 0; right: auto; top: 0; bottom: 0; width: 236px; height: auto; border-right: 1px solid var(--line); background: linear-gradient(180deg, var(--bg3), var(--bg0)); }
  .bnav .bnav-bg, .bnav .bar { display: none; }
  .dside { display: flex; flex-direction: column; gap: 6px; height: 100%; padding: 18px 14px 24px; }
  .dside-logo { padding: 4px 6px 18px; } .dside-logo .logo .wordmark { font-size: 30px; }
  .dn { display: flex; align-items: center; gap: 12px; height: 46px; padding: 0 14px; border-radius: 12px; color: var(--muted); font: 700 14px "Poppins", sans-serif; border: 1px solid transparent; transition: background .2s, color .2s; }
  .dn i { display: grid; place-items: center; width: 24px; height: 24px; } .dn i svg { width: 20px; height: 20px; }
  .dn:hover { background: rgba(255,255,255,.05); color: var(--ink); }
  .dn.on { color: var(--gold); background: rgba(255,178,74,.1); border-color: rgba(255,178,74,.3); }
  .dside-dep { margin-top: auto; }
  .main { margin-left: 236px; padding: 0 36px 40px; }
  .main.no-nav { padding-bottom: 40px; }
  .main > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
  .hdr .logo { display: none; } .hdr { justify-content: flex-end; }
  #fanLayer, #fanScrim { display: none !important; }
  .slot-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
  .game-frame iframe { max-width: 520px; margin: 0 auto; }
  .game-frame { background: #050303; }
  .auth-card { max-width: 440px; }

  /* home: banner + wallet side by side, games in one wide row, leaderboard + partners side by side */
  .main.is-home { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(330px, 1fr); grid-auto-flow: row dense; gap: 18px 26px; align-content: start; }
  .main.is-home > * { max-width: none; margin: 0; }
  .is-home > .hdr { grid-column: 1 / -1; grid-row: 1; }
  .is-home > .adverts { grid-column: 1; grid-row: 2; }
  .is-home > .dots { grid-column: 1; grid-row: 3; margin: -6px 0 0; }
  .is-home > .wallet { grid-column: 2; grid-row: 2 / span 2; flex-direction: column; align-items: stretch; justify-content: center; gap: 22px; padding: 28px 26px; --cut-w: 22px; }
  .is-home .wallet .balance .lbl { font-size: 12px; } .is-home .wallet .balance .val { margin-top: 6px; font-size: 38px; }
  .is-home .wallet .w-acts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding: 18px 0 0; border-left: 0; border-top: 1.5px solid rgba(255,178,74,.25); }
  .is-home .wallet .w-act { font-size: 11.5px; } .is-home .wallet .w-act i { width: 46px; height: 46px; } .is-home .wallet .w-act svg { width: 20px; height: 20px; }
  .is-home .ad { height: 100%; min-height: 250px; }
  .is-home > .marquee, .is-home > .gboard, .is-home > .cats, .is-home > .link-row { grid-column: 1 / -1; }
  .is-home > .gboard { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.3fr); gap: 20px; margin: 0; }
  .is-home .gboard .gate { height: auto; min-height: 300px; margin: 0; }
  .is-home .gboard .gt-row { gap: 20px; height: 100%; }
  .is-home .gboard .gt { aspect-ratio: auto; height: 100%; min-height: 300px; } .gt b { font-size: 17px; }
  .is-home .gate .gt-tx b { font-size: 26px; }
  .is-home > .cats { min-height: 44px; align-items: center; overflow-y: hidden; padding: 3px 0; }
  .is-home > .sec.lb, .is-home > .rank-card { grid-column: 1; }
  .is-home > .sec.pt, .is-home > .partners { grid-column: 2; }
  .is-home > .sec { margin: 0; }
  .partners { grid-template-columns: repeat(3, 1fr); margin: 0; }
}
