/* HoTX888 lobby. Layout idea: a dark casino lobby (sticky top bar, chip row of categories, hero banner, horizontal game rows).
   Own palette and logo; nothing here is copied from another site. */
:root {
  --rail: #08130f; --felt: #0d2621; --felt-hi: #17423a; --bg: #08130f; --panel: #0f2c26; --panel2: #17423a; --line: rgba(217,180,92,.22); --text: #fff; --muted: #97aea2;
  --accent: #ff9a1f; --accent2: #ff4d6d; --good: #29d391; --bad: #ff6b6b; --white: #f9fafa; --ink: #08130f;
  --radius: 8px; --top: 78px; --chips: 64px;
}
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--rail); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; color: var(--text); min-height: 100vh; min-height: 100dvh; background: var(--rail);
  -webkit-tap-highlight-color: transparent; overflow-x: hidden;
  font: 400 14px/1.4 Inter, "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", "Noto Sans Thai", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}
@font-face { font-family: Inter; font-weight: 100 900; font-display: swap; src: url(/assets/fonts/inter-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
/* the same jade felt as the Big Two page, on a fixed layer (iPhone Safari does not support background-attachment: fixed) */
body::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(120% 80% at 50% 38%, var(--felt-hi) 0%, var(--felt) 55%, var(--rail) 100%); }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.hidden { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 22px; border-radius: var(--radius);
  border: 1px solid #ced0d2; background: transparent; color: var(--white); font-weight: 700; letter-spacing: .3px; text-transform: uppercase; font-size: 13px; white-space: nowrap;
}
.btn:hover { background: rgba(255,255,255,.08); }
.btn.solid { background: var(--white); border-color: var(--white); color: var(--ink); }
.btn.solid:hover { background: #fff; }
.btn.hot { background: linear-gradient(180deg, #ffb340, var(--accent)); border-color: transparent; color: #2a1200; }
.btn.hot:hover { filter: brightness(1.08); }
.btn.small { min-height: 34px; padding: 0 14px; font-size: 12px; }
.btn:disabled { opacity: .55; cursor: default; }

/* ---------- top bar ---------- */
.top {
  position: sticky; top: 0; z-index: 30; height: var(--top); display: flex; align-items: center; gap: 28px; padding: 0 32px;
  background: rgba(8,19,15,.94); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--line);
}
.top .logo img { height: 66px; width: auto; display: block; }   /* tall enough for the flames above the letters */
.nav { display: flex; gap: 26px; align-self: stretch; }
.nav a { display: flex; align-items: center; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; font-size: 14px; border-bottom: 3px solid transparent; }
.nav a.on { border-bottom-color: var(--accent); }
.spacer { flex: 1; }
.lang { position: relative; }
.lang-btn { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; background: transparent; border: 1px solid var(--line); border-radius: var(--radius); }
.lang-btn img { width: 24px; height: 18px; border-radius: 2px; object-fit: cover; }
.lang-menu { position: absolute; right: 0; top: 46px; min-width: 170px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 6px; z-index: 40; box-shadow: 0 12px 30px rgba(0,0,0,.5); }
.lang-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 6px; }
.lang-menu a:hover, .lang-menu a.on { background: var(--panel2); }
.lang-menu img { width: 24px; height: 18px; border-radius: 2px; }
.acct { display: flex; align-items: center; gap: 10px; position: relative; }
/* the same account menu on a computer and a phone: the avatar button opens a drop-down with Avatar, History and Sign out */
.acct-pop { display: none; }
.acct-pop:not(.hidden) { display: flex; }
#histBtn, #signOutBtn, .who { display: none; }
.menu-btn { width: 40px; height: 40px; padding: 0; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.menu-btn svg { width: 22px; height: 22px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; }
.acct-pop { position: absolute; right: 0; top: 48px; min-width: 190px; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; z-index: 45; box-shadow: 0 12px 30px rgba(0,0,0,.5); }
.acct-pop .who2 { padding: 8px 10px 10px; color: var(--muted); font-weight: 600; border-bottom: 1px solid var(--line); margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-pop button { text-align: left; padding: 11px 10px; background: none; border: 0; border-radius: 6px; font-weight: 600; }
.acct-pop button:hover { background: var(--panel2); }
.bal { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); font-weight: 700; }
.bal small { color: var(--muted); font-weight: 600; text-transform: uppercase; font-size: 10px; letter-spacing: .6px; }
.bal b { color: var(--accent); font-variant-numeric: tabular-nums; }
.who { color: var(--muted); font-weight: 600; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- category chips ---------- */
.chips {
  position: sticky; top: var(--top); z-index: 20; display: flex; align-items: center; gap: 12px; padding: 12px 32px; background: rgba(8,19,15,.94); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.chiprow { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; flex: 1; padding: 2px; }
.chiprow::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 18px; border-radius: var(--radius); background: transparent;
  border: 1px solid var(--line); color: #c9d6db; font-weight: 600; white-space: nowrap; flex: none;
}
.chip svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.chip img { width: 26px; height: 26px; display: block; flex: none; }
.chip:hover { border-color: rgba(217,180,92,.6); color: #fff; }
.chip.on { border-color: #fff; color: #fff; background: var(--panel); }
.searchbtn { flex: none; width: 44px; height: 44px; display: grid; place-items: center; background: transparent; border: 0; border-radius: var(--radius); }
.searchbtn svg { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; }
.searchbtn img { width: 28px; height: 28px; display: block; }
.search { flex: none; display: flex; align-items: center; gap: 8px; }
.search input { width: 220px; height: 44px; padding: 0 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); color: #fff; font: inherit; font-size: 16px; -webkit-appearance: none; appearance: none; }

/* Big Two, Mahjong and Poker have their own player menu with Leave, so the floating Website Lobby button is not shown over them */
body.big2open #closeGame { display: none; }

/* ---------- suggestion window ---------- */
.sheet textarea { width: 100%; padding: 12px 14px; background: var(--bg); color: #fff; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; font-size: 16px; resize: vertical; min-height: 110px; }
.sheet textarea:focus { border-color: var(--accent); outline: 0; }
.sug-or { display: flex; align-items: center; gap: 12px; margin: 14px 0; color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; }
.sug-or::before, .sug-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.sug-rec { display: flex; align-items: center; gap: 14px; }
.sug-rec .btn { display: inline-flex; align-items: center; gap: 10px; }
.sug-rec .dot { width: 12px; height: 12px; border-radius: 50%; background: #ff4d4d; display: inline-block; }
.sug-rec .btn.on { border-color: #ff4d4d; }
.sug-rec .btn.on .dot { animation: sugpulse 1s ease-in-out infinite; }
@keyframes sugpulse { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.45); opacity: .55; } }
.sug-time { font-variant-numeric: tabular-nums; color: var(--muted); }
.sug-play { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.sug-play audio { flex: 1; min-width: 0; height: 40px; }
.sug-note { margin: 14px 0 0; font-size: 12px; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .sug-rec .btn.on .dot { animation: none; } }

/* ---------- the free sign-up bonus ---------- */
.sheet .bonus { display: flex; align-items: center; gap: 12px; margin: 0 0 6px; padding: 12px 14px; border-radius: 12px; background: linear-gradient(135deg, rgba(217,180,92,.28), rgba(255,154,31,.16)); border: 1px solid var(--gold, #d9b45c); }
.sheet .bonus .gift { font-size: 34px; line-height: 1; flex: none; }
.sheet .bonus b { display: block; font-size: 20px; color: #ffe08a; line-height: 1.2; }
.sheet .bonus span { color: #d6e1e5; font-size: 13px; }
.acct-pop .bonusline { padding: 0 10px 8px; margin-top: -4px; font-size: 12px; color: #ffe08a; border-bottom: 1px solid var(--line); margin-bottom: 6px; }

/* ---------- avatars and membership band rings ---------- */
.ring { --rc: conic-gradient(#8a4b1a, #e0a060, #a0612a, #f0b878, #8a4b1a); display: inline-block; flex: none; padding: var(--rw, 4px); border-radius: 50%; background: var(--rc); box-shadow: 0 2px 6px rgba(0,0,0,.45); line-height: 0; }
.ring img, .ring b { display: block; width: var(--rs, 64px); height: var(--rs, 64px); border-radius: 50%; object-fit: cover; background: var(--panel2); }
.ring b { display: grid; place-items: center; font-size: calc(var(--rs, 64px) * .45); color: #fff; line-height: 1; }
.ring.b1 { --rc: conic-gradient(#8f979f, #f2f5f7, #aab2ba, #ffffff, #8f979f); }
.ring.b2 { --rc: conic-gradient(#b8860b, #ffe27a, #d4a017, #fff3b0, #b8860b); }
.ring.b3 { --rc: conic-gradient(#cfe3f5, #ffffff, #9fc3e8, #f4fbff, #cfe3f5); box-shadow: 0 0 10px rgba(190,225,255,.55); }
.ring.b4 { --rc: conic-gradient(#2fd4ff, #b6fff5, #6a7bff, #9ef7ff, #2fd4ff); box-shadow: 0 0 12px rgba(80,220,255,.7); animation: ringglow 3s ease-in-out infinite; }
@keyframes ringglow { 0%, 100% { box-shadow: 0 0 8px rgba(80,220,255,.5); } 50% { box-shadow: 0 0 18px rgba(120,240,255,.95); } }
.menu-btn.has-av { background: none; border-color: transparent; }
.sheet.avsheet { width: min(640px, 100%); }
.avgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 14px 10px; justify-items: center; margin-top: 4px; }
.avb { background: none; border: 0; padding: 4px; border-radius: 14px; cursor: pointer; display: grid; justify-items: center; gap: 4px; color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .3px; text-transform: uppercase; --rs: 68px; }
.avb:hover { background: rgba(255,255,255,.06); }
.avb.sel { background: rgba(255,154,31,.16); outline: 2px solid var(--accent); }
.sheet .sub.avsub, #avatarSub { margin-bottom: 6px; }
.avmsg { min-height: 22px; margin: 0 0 14px; font-weight: 600; color: var(--accent); }
.avmsg.ok { color: var(--good); }
@media (max-width: 700px) { .avgrid { grid-template-columns: repeat(4, 1fr); gap: 10px 6px; } .avb { --rs: 56px; } }
@media (prefers-reduced-motion: reduce) { .ring.b4 { animation: none; } }

/* ---------- banner carousel (replaces the old hero) ---------- */
.tag { display: inline-block; background: #fff; color: var(--ink); font-weight: 800; font-size: 12px; letter-spacing: .5px; padding: 5px 9px; text-transform: uppercase; }
.hb { position: relative; overflow: hidden; background: #07150f; container-type: inline-size; aspect-ratio: 3.6 / 1; max-height: 540px; touch-action: pan-y; -webkit-user-select: none; user-select: none; }
.hb img { -webkit-user-drag: none; }
.hb.dragging .slide { transition: none; }
.hb .slide { position: absolute; inset: 0; z-index: 1; opacity: 0; visibility: hidden; transition: opacity .9s ease, visibility .9s, transform .25s ease; }
.hb .slide.on { opacity: 1; visibility: visible; z-index: 2; }
.hb .pic { position: absolute; inset: 0; transform-origin: 72% 50%; }
.hb .slide.on .pic { animation: hbzoom 9s ease-out both; }
@keyframes hbzoom { from { transform: scale(1); } to { transform: scale(1.06); } }
.hb picture, .hb img { display: block; width: 100%; height: 100%; }
.hb img { object-fit: cover; object-position: right center; }
.hb .slide::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, rgba(5,16,12,.78) 0%, rgba(5,16,12,.32) 38%, transparent 56%); }
.hb::after { content: ""; position: absolute; top: 0; bottom: 0; width: 16%; left: -30%; z-index: 3; pointer-events: none; background: linear-gradient(100deg, transparent, rgba(255,236,170,.15), transparent); transform: skewX(-14deg); animation: hbsweep 8s ease-in-out infinite; }
@keyframes hbsweep { 0%, 55% { left: -30%; } 100% { left: 130%; } }
.hb .fx { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.hb .fx i { position: absolute; width: 7px; height: 7px; border-radius: 50%; opacity: 0; background: radial-gradient(circle, #fff7cf 0 30%, rgba(255,200,80,0) 72%); animation: hbtw var(--d, 4s) ease-in-out var(--l, 0s) infinite; }
@keyframes hbtw { 0% { opacity: 0; transform: translateY(12px) scale(.4); } 40% { opacity: 1; } 100% { opacity: 0; transform: translateY(-46px) scale(1.25); } }
.hb .copy { position: absolute; z-index: 3; left: clamp(16px, 5cqw, 96px); top: 50%; transform: translateY(-50%); max-width: 36cqw; }
.hb h1 { margin: 10px 0 8px; font-size: clamp(22px, 3.3cqw, 54px); line-height: 1.05; text-transform: uppercase; letter-spacing: -.3px; text-shadow: 0 2px 14px rgba(0,0,0,.65); }
.hb p { margin: 0 0 18px; font-size: clamp(13px, 1.35cqw, 21px); color: #d6e1e5; text-shadow: 0 1px 8px rgba(0,0,0,.6); }
.hb .cta { display: flex; gap: 10px; flex-wrap: wrap; }
.hb .rib { position: absolute; z-index: 3; left: var(--dx); top: var(--dy); transform: translate(-50%, -50%); width: 16cqw; min-height: 3cqw; display: grid; place-items: center; text-align: center; background: none; border: 0; cursor: pointer; font-family: inherit; font-weight: 900; font-size: 1.15cqw; line-height: 1.05; letter-spacing: .04em; text-transform: uppercase; color: #3a2200; text-shadow: 0 1px 0 rgba(255,236,170,.7); }
.hb .rib:hover { filter: brightness(1.15); }
.hb-nav { position: absolute; top: 50%; z-index: 4; width: 44px; height: 44px; margin-top: -22px; border-radius: 50%; display: grid; place-items: center; background: rgba(8,19,15,.62); border: 1px solid var(--line); color: #fff; cursor: pointer; opacity: 0; transition: opacity .2s; }
.hb:hover .hb-nav, .hb-nav:focus-visible { opacity: 1; }
.hb-nav.prev { left: 14px; } .hb-nav.next { right: 14px; }
.hb-nav svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.hb .dots { position: absolute; z-index: 4; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 8px; }
.hb .dots button { width: 9px; height: 9px; padding: 0; border-radius: 99px; border: 0; background: rgba(255,255,255,.4); cursor: pointer; transition: width .25s, background .25s; }
.hb .dots button.on { width: 26px; background: var(--accent); }
@media (prefers-reduced-motion: reduce) { .hb .slide.on .pic, .hb::after, .hb .fx i { animation: none !important; } .hb .slide { transition: none; } }
@media (max-width: 700px) {
  .hb { aspect-ratio: 1.8 / 1; min-height: 200px; max-height: none; }
  .hb .slide::before { background: linear-gradient(0deg, rgba(5,16,12,.94) 0%, rgba(5,16,12,.55) 40%, transparent 66%); }
  .hb .copy { left: 14px; right: 14px; top: auto; bottom: 28px; transform: none; max-width: none; }
  .hb .tag, .hb p { display: none; }
  .hb h1 { font-size: 21px; margin: 0 0 8px; }
  .hb .cta .btn { min-height: 34px; padding: 0 14px; font-size: 12px; }
  .hb .rib { display: none; }                      /* on a phone the two buttons carry the provider names */
  .hb-nav { display: none; }
  .hb .dots { bottom: 8px; }
}

/* ---------- game rows and grid ---------- */
main { padding-bottom: 20px; }
.section { padding: 26px 32px 6px; }
.section header { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.section h2 { margin: 0; font-size: 22px; flex: 1; }
.arrows { display: flex; gap: 10px; }
.arrow { width: 40px; height: 40px; border-radius: 50%; border: 0; background: #1d4a40; display: grid; place-items: center; }
.arrow:hover { background: #2a6354; }
.arrow svg { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.track { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x proximity; padding: 4px 2px 14px; scrollbar-width: none; }
.track::-webkit-scrollbar { display: none; }
.track .tile { flex: none; width: 190px; scroll-snap-align: start; }
.grid { list-style: none; margin: 0; padding: 4px 2px 14px; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 18px 16px; }
.grid > li, .grid > li > .tile { min-width: 0; }      /* grid items must be allowed to shrink below the icon's natural width */
.tile { position: relative; padding: 0; background: none; border: 0; text-align: left; display: block; color: inherit; width: 100%; }
.tile .pic { position: relative; display: block; aspect-ratio: 5 / 4; border-radius: 14px; overflow: hidden; background: var(--panel); transition: transform .18s, box-shadow .18s; }
.tile .pic img { width: 100%; height: 100%; object-fit: contain; display: block; }   /* SpinX icons are about 5:4 and carry their title inside the picture, so never crop them */
.tile .pic b { display: grid; place-items: center; height: 100%; padding: 8px; text-align: center; }
/* Pragmatic Play and PG Soft icons keep their own proportions (PG's are square app icons with the logo in the corner, Pragmatic's are wide) */
.tile[data-prov="pg"] .pic { aspect-ratio: 1 / 1; background: transparent; }
.tile[data-prov="pp"] .pic { aspect-ratio: 325 / 234; }
.tile:hover .pic { transform: translateY(-4px); box-shadow: 0 14px 28px rgba(0,0,0,.5); }
.tile .name { display: block; margin: 8px 2px 0; font-size: 13px; font-weight: 600; color: #dfe8eb; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.badge { position: absolute; top: 8px; left: 8px; z-index: 2; background: rgba(8,19,15,.85); color: #fff; font-size: 10px; font-weight: 800; letter-spacing: .6px; padding: 3px 7px; border-radius: 5px; text-transform: uppercase; }
.badge.hot { background: var(--accent2); }
.badge.new { background: var(--good); color: #052a1c; }
.badge.own { background: var(--accent); color: #2a1200; }
.empty { color: var(--muted); padding: 30px 4px; }

/* ---------- footer ---------- */
.foot { margin-top: 30px; padding: 30px 32px 40px; border-top: 1px solid var(--line); color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.foot img { height: 48px; }
.foot p { margin: 0; max-width: 720px; font-size: 12px; }

/* ---------- modals ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: rgba(0,0,0,.72); }
.sheet { width: min(420px, 100%); max-height: 92vh; overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 26px; box-shadow: 0 30px 70px rgba(0,0,0,.6); }
.sheet.wide { width: min(560px, 100%); }
.sheet h3 { margin: 0 0 6px; font-size: 22px; }
.sheet .sub { margin: 0 0 18px; color: var(--muted); }
.sheet label { display: block; font-size: 12px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; color: var(--muted); margin: 14px 0 6px; }
.sheet input { width: 100%; height: 46px; padding: 0 14px; background: var(--bg); color: #fff; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; font-size: 16px; -webkit-appearance: none; appearance: none; }
.sheet input:focus { border-color: var(--accent); outline: 0; }
.sheet .err { min-height: 20px; margin: 12px 0 0; color: var(--bad); font-size: 13px; }
.sheet .row { display: flex; gap: 10px; margin-top: 8px; }
.sheet .row .btn { flex: 1; }
.sheet .alt { margin: 16px 0 0; text-align: center; color: var(--muted); }
.sheet .alt a { color: var(--accent); font-weight: 700; cursor: pointer; }
.close { float: right; background: none; border: 0; color: var(--muted); font-size: 26px; line-height: 1; padding: 0 4px; }
.hist { width: 100%; border-collapse: collapse; font-size: 13px; margin-top: 6px; }
.hist th, .hist td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: left; }
.hist th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .5px; }
.hist td.plus { color: var(--good); } .hist td.minus { color: var(--bad); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90; max-width: min(92vw, 520px); background: #17423a; color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 14px; text-align: center; box-shadow: 0 8px 24px rgba(0,0,0,.5); border: 1px solid var(--line); }

/* ---------- full-viewport game frame ---------- */
#player { position: fixed; inset: 0; z-index: 70; background: #000; overflow: hidden; height: 100vh; height: 100dvh; }
#frameHost { position: absolute; inset: 0; }
#player iframe { display: block; width: 100%; height: 100%; border: 0; background: #000; }
#frameLoading { position: absolute; inset: 0; display: grid; place-items: center; background: #000; pointer-events: none; transition: opacity .25s; }
#frameLoading.done { opacity: 0; }
.spin { width: 44px; height: 44px; border: 4px solid #333; border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.floatback {
  position: absolute; top: max(8px, env(safe-area-inset-top)); left: max(8px, env(safe-area-inset-left)); z-index: 2;
  display: flex; align-items: center; gap: 5px; padding: 6px 11px 6px 8px; border-radius: 999px; border: 1px solid var(--accent); cursor: pointer;
  line-height: 1; color: var(--accent); background: rgba(8,19,15,.88); font-weight: 800; font-size: 10px; letter-spacing: .2px; white-space: nowrap;
  box-shadow: 0 2px 7px rgba(0,0,0,.5); opacity: .92;
}
.floatback b { font-size: 13px; line-height: 1; }
/* slot games have no player menu of their own: a small Suggestion button sits beside the back button */
.floatsug { position: absolute; top: max(8px, env(safe-area-inset-top)); left: calc(max(8px, env(safe-area-inset-left)) + 112px); z-index: 2; height: 34px; padding: 0 12px; border-radius: 99px; background: rgba(8,19,15,.72); border: 1px solid var(--line); color: #fff; font-weight: 700; font-size: 12px; cursor: pointer; opacity: .72; }
.floatsug:hover { opacity: 1; background: #0f2c26; }
body.big2open .floatsug { display: none; }
.floatback:hover { opacity: 1; background: #0f2c26; }

/* "Rotate your phone": only while a slot-style game is open on a phone held upright */
#rotateHint { display: none; position: fixed; inset: 0; z-index: 90; place-items: center; text-align: center; padding: 24px; background: linear-gradient(#08130f, #17423a); }
#rotateHint .rot { font-size: 64px; line-height: 1; display: block; animation: tilt 2.2s ease-in-out infinite; }
#rotateHint p { margin: 14px 0 0; font-size: 20px; font-weight: 800; }
@keyframes tilt { 0%, 15% { transform: rotate(0); } 55%, 100% { transform: rotate(-90deg); } }
@media (orientation: portrait) and (pointer: coarse) and (max-width: 700px) { body.needland #rotateHint { display: grid; } }

/* ---------- phones and small tablets ---------- */
@media (max-width: 900px) {
  :root { --top: 60px; --chips: 60px; }
  .top { padding: 0 max(12px, env(safe-area-inset-right)) 0 max(12px, env(safe-area-inset-left)); gap: 10px; }
  .top .logo { flex: none; }
  .top .logo img { height: clamp(33px, 12vw, 62px); width: auto; }   /* grows with the phone's width, as big as the header can hold */
  .nav { display: none; }
  .lang-btn { height: 38px; padding: 0 9px; }
  .lang-btn span { display: none; }                         /* the flag is enough on a phone */
  .acct { gap: 8px; }
  .bal { height: 38px; padding: 0 11px; }
  .bal small { display: none; }
  .menu-btn { display: inline-flex; }
  .acct-pop:not(.hidden) { display: flex; }
  .btn { padding: 0 14px; }
  .chips { padding: 10px max(12px, env(safe-area-inset-right)) 10px max(12px, env(safe-area-inset-left)); gap: 8px; }
  .chip { height: 40px; padding: 0 14px; }
  .chip img { width: 24px; height: 24px; }
  .searchbtn { width: 40px; height: 40px; }
  .search input { width: 150px; height: 40px; }
  .section { padding: 20px max(14px, env(safe-area-inset-left)) 4px; }
  .section h2 { font-size: 19px; }
  .track { margin-right: -14px; padding-right: 14px; }
  .track .tile { width: 138px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 12px 10px; }
  .tile .name { font-size: 12px; }
  .arrows { display: none; }
  .foot { padding: 24px 16px calc(34px + env(safe-area-inset-bottom)); }
  .sheet { padding: 22px; }
  .modal { padding: max(16px, env(safe-area-inset-top)) 12px max(16px, env(safe-area-inset-bottom)); align-items: center; }
  .toast { bottom: calc(18px + env(safe-area-inset-bottom)); }
}
/* narrow phones (360px and below, e.g. small Androids and iPhone SE/mini): the header must never be wider than the screen */
.lang, .acct { flex: none; }
.spacer { min-width: 0; }
@media (max-width: 420px) {
  .top { gap: 8px; padding-left: max(10px, env(safe-area-inset-left)); padding-right: max(10px, env(safe-area-inset-right)); }
  .lang-btn { min-width: 40px; height: 36px; justify-content: center; }
  .acct .btn { padding: 0 10px; font-size: 11.5px; min-height: 36px; letter-spacing: .2px; }
  .bal { height: 36px; padding: 0 10px; }
  .menu-btn { width: 38px; height: 38px; }
}
@media (max-width: 340px) {                                  /* 320px-wide phones */
  .top { gap: 6px; padding-left: 8px; padding-right: 8px; }
  .top .logo img { height: 33px; }
  .lang-btn { min-width: 34px; padding: 0 6px; }
  .acct { gap: 6px; }
  .acct .btn { padding: 0 8px; font-size: 11px; }
  .bal { padding: 0 8px; font-size: 13px; }
  .chip { padding: 0 11px; gap: 7px; }
}
@media (max-width: 380px) {
  .track .tile { width: 124px; }
}
/* phones held sideways: keep the bars slim so there is room for games */
@media (max-height: 480px) and (orientation: landscape) {
  :root { --top: 50px; --chips: 52px; }
  .top .logo img { height: 36px; }
  .chips { padding-top: 6px; padding-bottom: 6px; }
  .chip { height: 36px; }
}
