/* Phones: a compact top bar, screens that use the full width, and a bottom navigation bar
   (Home, Search, a raised "new match" button, Inbox, Profile). Loaded after style.css and chat.css. */
.bnav, .top-on { display: none; }
.stk-tok { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 99px; font-size: 12.5px; font-weight: 700; background: var(--card2); border: 1px solid var(--line); }
.stk-tok .tk { width: 16px; height: 16px; margin: 0; }

@media (max-width: 760px) {
  :root { --top-h: 56px; --bn-h: 64px; --bn-space: calc(var(--bn-h) + 34px + env(safe-area-inset-bottom)); --bn-bg: #fafafa; --bn-red: #898989; }
  html, body { overflow-x: hidden; }
  .page { padding: 0 10px var(--bn-space) !important; }

  /* ----- top bar ----- */
  .top {
    position: sticky; top: 0; z-index: 70; flex-wrap: nowrap !important; gap: 8px !important;
    height: calc(var(--top-h) + env(safe-area-inset-top)); margin: 0 -10px 12px !important; padding: env(safe-area-inset-top) 12px 0 !important;
    border-radius: 0 !important; border: 0 !important; border-bottom: 1px solid var(--line) !important; box-shadow: none !important;
    background: color-mix(in srgb, var(--card) 90%, transparent) !important; -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  }
  .top .brand { margin-right: auto; }
  .top .brand > span { display: block !important; }
  .top .brand b { font-size: 16px; }
  .top .brand small { display: none !important; }
  .top .logo-img { width: 34px; height: 34px; }
  .top-r { display: flex !important; align-items: center; gap: 6px; margin-left: auto; flex-wrap: nowrap !important; }
  .top .navl, .top .snd, .top [data-go="settings"] { display: none !important; }
  .top .icon-btn { width: 34px; height: 34px; }
  .top-on { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border-radius: 99px; font-size: 12.5px; font-weight: 700; color: var(--ink2); background: var(--card2); border: 1px solid var(--line); }
  .top-on .isl-dot { width: 7px; height: 7px; }
  .me-chip { padding: 0 !important; border: 0 !important; background: none !important; }
  .me-chip span { display: none !important; }
  .me-chip img.av.sm { width: 34px; height: 34px; }

  /* The island only appears when it has news (a live game, a result); otherwise the bar shows who's online. */
  body:not(.isl-wide) .island { display: none !important; }
  body.isl-wide .top .brand > span, body.isl-wide .top-on { display: none !important; }
  .island { top: calc(env(safe-area-inset-top) + 10px) !important; height: 36px; }

  /* Inbox lives in the bottom bar, so no floating chat button. */
  .cx-fab { display: none !important; }
  .toasts { top: calc(var(--top-h) + env(safe-area-inset-top) + 8px) !important; left: 10px !important; right: 10px !important; }
  .foot { margin-top: 18px; font-size: 11.5px; }

  /* ----- full-width screens ----- */
  .card { border-radius: 18px; }
  .split, .grid2 { gap: 12px; }
  .split > .card, .grid2 > .card, .page > .enter > .card { padding: 18px 16px; }
  .hero { padding: 22px 16px !important; }

  /* ----- bottom navigation ----- */
  .bnav { display: block; position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 78; height: var(--bn-h); pointer-events: none; }
  .bnav::before { content: ''; position: absolute; left: 6%; right: 6%; bottom: -16px; height: 46px; z-index: -1; border-radius: 50%; background: radial-gradient(closest-side, rgba(137, 137, 137, .55), transparent); filter: blur(14px); }
  .bn-bar {
    position: relative; height: 100%; display: grid; grid-template-columns: 1fr 1fr 86px 1fr 1fr; align-items: center;
    border-radius: 999px; background: var(--bn-bg); pointer-events: auto;
    filter: drop-shadow(0 14px 22px rgba(0, 0, 0, .26)) drop-shadow(0 2px 4px rgba(0, 0, 0, .08));
  }
  /* the smooth bump that rises around the red button */
  .bn-bar::before {
    content: ''; position: absolute; left: 50%; top: -19px; width: 156px; height: 20px; transform: translateX(-50%);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 156 20' preserveAspectRatio='none'%3E%3Cpath d='M0 20C44 20 48 0 78 0s34 20 78 20z' fill='%23fbfaf8'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
  }
  .bn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 100%; padding: 0; color: #1c1c1e; font: 600 11.5px/1 'Inter', system-ui, sans-serif; letter-spacing: -.01em; -webkit-tap-highlight-color: transparent; transition: color .2s; }
  .bn-ic { position: relative; display: grid; place-items: center; transition: transform .25s cubic-bezier(.3, 1.6, .5, 1); }
  .bn svg { width: 24px; height: 24px; stroke-width: 1.9; }
  .bn.on { color: var(--bn-red); }
  .bn.on .bn-ic { transform: translateY(-1px); }
  .bn:active .bn-ic { transform: scale(.88); }
  .bn-n { position: absolute; top: -6px; right: -10px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; font: 700 10px/18px 'Inter', sans-serif; font-style: normal; text-align: center; color: #fff; background: var(--bn-red); box-shadow: 0 0 0 2px var(--bn-bg); }
  .bn-plus {
    position: absolute; left: 50%; top: -25px; z-index: 1; width: 62px; height: 62px; margin-left: -31px; border-radius: 50%;
    display: grid; place-items: center; color: #fff; pointer-events: auto; -webkit-tap-highlight-color: transparent;
    background: radial-gradient(circle at 34% 28%, #b8b8b8, var(--bn-red) 52%, #626262);
    box-shadow: 0 12px 26px -6px rgba(98, 98, 98, .7), inset 0 1px 0 rgba(255, 255, 255, .35), inset 0 -3px 6px rgba(51, 51, 51, .35);
    transition: transform .2s cubic-bezier(.3, 1.6, .5, 1);
  }
  .bn-plus svg { width: 28px; height: 28px; }
  .bn-plus:active { transform: scale(.92); }
  body.ch-in .bnav, body.kb-up .bnav, body.chat-open .bnav, body.on-ob .bnav { display: none; }

  /* ----- chat: the list fills the screen; a conversation takes the whole screen ----- */
  body.on-chat .page { padding-bottom: 0 !important; }
  .ch { height: calc(var(--vv-h, 100dvh) - var(--top-h) - env(safe-area-inset-top) - 12px) !important; margin: 0 -10px; }
  .ch-side { border-radius: 0 !important; border: 0 !important; box-shadow: none !important; background: transparent !important; }
  .ch-side .ch-scroll { padding: 0 10px calc(var(--bn-space) + 8px); }
  .ch-side-h { padding: 6px 14px 10px; }
  .ch-side-h h2 { font-size: 24px; }
  .ch-search { margin: 0 12px 6px; height: 44px; border-radius: 14px; background: var(--card); }
  .ch-row { padding: 10px; border-radius: 16px; }
  .ch-row.on::before { display: none; }
  .ch-av img.av.sm, .ch-ico { width: 48px; height: 48px; }
  .ch-ico { border-radius: 16px; }
  .ch-tt b { font-size: 15px; }
  .ch-tt small { font-size: 13px; }
  body.ch-in { overflow: hidden; }
  body.ch-in .ch-main {
    position: fixed; left: 0; right: 0; top: var(--vv-top, 0px); height: var(--vv-h, 100dvh); z-index: 90;
    display: flex !important; border-radius: 0 !important; border: 0 !important; box-shadow: none !important; padding-top: env(safe-area-inset-top);
  }
  body.ch-in .ch-form { padding: 8px 10px calc(10px + env(safe-area-inset-bottom)); }
  body.ch-in.kb-up .ch-form { padding-bottom: 8px; }
  body.ch-in .island { display: none !important; }
}
@media (max-width: 380px) {
  .bn { font-size: 10.5px; }
  .bn svg { width: 22px; height: 22px; }
  .bn-bar { grid-template-columns: 1fr 1fr 78px 1fr 1fr; }
  .top-on { padding: 0 8px; }
}
@media (max-width: 760px) {
  /* a conversation sits above everything; the page's entry animation must not trap it */
  body.ch-in .enter, body.ch-in .page, body.ch-in #app, body.ch-in .ch { animation: none !important; transform: none !important; filter: none !important; }
  body.ch-in .top { visibility: hidden; }
}

/* =========================================================
   v9: palette #131313 #282828 #4f4f4f #898989 #c6c6c6 #4A4A46
   compact notifications, home, money dashboard, create match
   ========================================================= */
:root { --p1: #131313; --p2: #282828; --p3: #4f4f4f; --p4: #898989; --p5: #c6c6c6; --p6: #4A4A46; }
[data-style="classic"] .btn.pri { background: linear-gradient(180deg, #4f4f4f, #282828); color: #eeeeee; }

/* notifications: smaller, warm gradient */
.nt { width: min(320px, calc(100vw - 24px)); padding: 10px 34px 10px 10px; gap: 10px; border-radius: 14px; align-items: center;
  background: linear-gradient(135deg, #282828 0%, #131313 100%); color: #e7e7e7; border: 1px solid rgba(137, 137, 137, .3); box-shadow: 0 16px 34px -14px rgba(19, 19, 19, .7); }
.nt::before { display: none; }
.nt-ic { width: 26px; height: 26px; font-size: 13px; background: var(--nt, #898989); color: #131313; }
.nt-ic svg { width: 14px; height: 14px; }
.nt-t { padding-top: 0; gap: 1px; }
.nt-t b { font-size: 13.5px; font-weight: 600; }
.nt-t small { font-size: 12px; }
.nt-x { top: 50%; transform: translateY(-50%); right: 6px; width: 24px; height: 24px; font-size: 16px; }
.nt-bar { height: 2px; }
@media (max-width: 760px) {
  .toasts { align-items: center !important; }
  .nt { width: auto; max-width: calc(100vw - 32px); min-width: 0; }
}

/* Privy button */
.pv-btn { gap: 10px; }
.pv-ic { width: 22px; height: 22px; border-radius: 6px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .25); }

/* money card (home and profile) */
.money-card { position: relative; overflow: hidden; padding: 18px; border-radius: 22px; color: #eeeeee;
  background: radial-gradient(120% 90% at 100% 0%, rgba(137, 137, 137, .45), transparent 55%), linear-gradient(150deg, #4f4f4f 0%, #282828 48%, #131313 100%);
  box-shadow: 0 18px 40px -18px rgba(19, 19, 19, .75), inset 0 1px 0 rgba(255, 255, 255, .1); }
.money-card::after { content: ''; position: absolute; right: -40px; bottom: -60px; width: 180px; height: 180px; border-radius: 50%; border: 26px solid rgba(198, 198, 198, .07); pointer-events: none; }
.mc-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.mc-who { display: flex; align-items: center; gap: 8px; min-width: 0; }
.mc-who b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-who img.av.sm { width: 30px; height: 30px; box-shadow: 0 0 0 2px rgba(198, 198, 198, .35); }
.mc-net { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 99px; font-size: 11.5px; font-weight: 600; background: rgba(19, 19, 19, .35); color: #c6c6c6; white-space: nowrap; }
.mc-net i { width: 6px; height: 6px; border-radius: 50%; background: #7FC98F; }
.mc-l { display: block; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; color: rgba(198, 198, 198, .8); }
.mc-bal { display: flex; align-items: center; gap: 10px; margin: 4px 0 16px; }
.mc-bal .tk { width: 30px; height: 30px; margin: 0; }
.mc-bal b { font: 700 38px/1 var(--fh, Georgia, serif); letter-spacing: -.01em; }
.mc-bal em { font-style: normal; font-size: 13px; font-weight: 700; color: rgba(198, 198, 198, .75); align-self: flex-end; margin-bottom: 5px; }
.mc-row { display: flex; align-items: center; gap: 8px; }
.mc-addr { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; height: 40px; padding: 0 12px; border-radius: 12px; background: rgba(19, 19, 19, .4); color: #eeeeee; font-size: 12.5px; border: 1px solid rgba(198, 198, 198, .14); }
.mc-addr svg { width: 15px; height: 15px; opacity: .7; flex: none; }
.mc-btn { height: 40px; padding: 0 14px; border-radius: 12px; background: #c6c6c6; color: #131313; font-weight: 700; border: 0; }
.mc-btn:hover { background: #d6d6d6; }
.mc-ex { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 12px; color: #c6c6c6; }
.mc-ex svg { width: 13px; height: 13px; }
.mc-out h3 { margin: 6px 0 6px; font: 700 22px/1.2 var(--fh, Georgia, serif); color: #eeeeee; }
.mc-out p { margin: 0 0 14px; font-size: 13.5px; color: rgba(238, 238, 238, .78); }

/* home */
.home-main { display: flex; flex-direction: column; gap: 12px; }
.quick-cta { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; border-radius: 18px; text-align: left; color: #131313; border: 0;
  background: linear-gradient(135deg, #c6c6c6 0%, #898989 100%); box-shadow: 0 12px 26px -14px rgba(79, 79, 79, .8), inset 0 1px 0 rgba(255, 255, 255, .45); transition: transform .15s; }
.quick-cta:active { transform: scale(.98); }
.qc-ic { flex: none; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: #131313; color: #c6c6c6; }
.qc-ic svg { width: 20px; height: 20px; }
.qc-t b { display: block; font-size: 17px; font-weight: 800; }
.qc-t small { font-size: 12.5px; color: rgba(19, 19, 19, .7); }
.quick-cta[disabled] { opacity: .8; }
.hm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hm-tile { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 14px; border-radius: 18px; text-align: left; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform .15s, border-color .2s; }
.hm-tile:hover { border-color: #898989; }
.hm-tile:active { transform: scale(.97); }
.hm-ic { width: 38px; height: 38px; margin-bottom: 8px; border-radius: 12px; display: grid; place-items: center; color: #4f4f4f; background: rgba(137, 137, 137, .16); }
[data-mode="dark"] .hm-ic { color: #c6c6c6; }
.hm-ic svg { width: 19px; height: 19px; }
.hm-tile b { font-size: 15px; }
.hm-tile small { font-size: 12px; color: var(--muted); }
.hm-join { display: flex; gap: 8px; padding: 6px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.hm-join .input { flex: 1; min-width: 0; border: 0; background: none; box-shadow: none !important; height: 42px; }
.hm-join .btn { height: 42px; border-radius: 12px; padding: 0 18px; }
.hm-note { display: flex; gap: 8px; margin: 2px 4px 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
.hm-note svg { flex: none; width: 14px; height: 14px; margin-top: 2px; }

/* profile */
.prof { display: flex; flex-direction: column; gap: 12px; max-width: 640px; margin: 0 auto; }
.pf-head { display: flex; align-items: center; gap: 14px; }
.pf-av img.av.xl { width: 68px; height: 68px; box-shadow: 0 0 0 3px var(--card), 0 0 0 5px #898989; }
.pf-t { flex: 1; min-width: 0; }
.pf-t h2 { margin: 0 0 2px; font-size: 20px; display: flex; align-items: center; gap: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-t small { color: var(--muted); font-size: 13px; }
.pf-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pf-stats > div { padding: 12px 10px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); text-align: center; }
.pf-stats small { display: block; font-size: 11px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
.pf-stats b { font: 700 17px/1.1 var(--fh, Georgia, serif); }
.pos { color: #3c8a5a; } .neg { color: #b5523f; }
.hx { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line2); }
.hx:first-of-type { border-top: 0; }
.hx-t { flex: 1; min-width: 0; }
.hx-t b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-t small { font-size: 12px; color: var(--muted); }
.hx-r { text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.hx-r b { font: 700 15px var(--fh, Georgia, serif); }
.hx-r small, .hx-r a { font-size: 11.5px; color: var(--muted); }
.pf-more { display: flex; flex-direction: column; gap: 4px; }
.pf-link { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 4px; border-top: 1px solid var(--line2); font-weight: 600; font-size: 14px; text-align: left; color: var(--ink); }
.pf-link span { flex: 1; }
.pf-link svg { width: 18px; height: 18px; color: var(--muted); }
.pf-link.danger { color: #b5523f; }
.pf-link.danger svg { color: #b5523f; transform: rotate(180deg); }

/* create match */
.cr-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.cr-head h2 { margin: 0 0 2px; font-size: 22px; }
.cr-head small { color: var(--muted); font-size: 13px; }
.cr-bal { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; font-size: 13px; background: var(--card2); border: 1px solid var(--line); white-space: nowrap; }
.cr-bal .tk { width: 16px; height: 16px; margin: 0; }
.cr-go { margin-top: 14px; }

@media (max-width: 760px) {
  .home.split { gap: 14px; }
  .money-card { padding: 16px; border-radius: 20px; }
  .mc-bal b { font-size: 34px; }
  .prof { gap: 10px; }
  .pf-stats { gap: 6px; }
  .pf-stats > div { padding: 10px 4px; border-radius: 14px; }
  .pf-stats b { font-size: 15px; }
  /* create: roomier controls, button stays in reach */
  .cr #mcard { display: none; }
  .cr .card { padding: 18px 14px !important; }
  .cr .stk { margin-top: 14px; padding: 14px; border-radius: 18px; }
  .cr .stk-val input { font-size: 40px; }
  .cr .stk-quick { grid-template-columns: repeat(3, 1fr) !important; gap: 8px !important; }
  .cr .stk-quick button { height: 40px !important; font-size: 14px !important; border-radius: 12px; }
  .cr .chev-i { padding: 8px 8px 8px 20px; }
  .cr .chev-i:first-child { padding-left: 12px; }
  .cr .chev-i b { font-size: 14px; }
  .cr .seg.full { border-radius: 14px; padding: 4px; }
  .cr .seg.full button { height: 40px; border-radius: 10px; font-size: 14px; }
  .cr .field > span { font-size: 13px; font-weight: 700; }
  .cr .post-chk { padding: 12px; border-radius: 14px; background: var(--card2); }
  .cr-go { position: sticky; bottom: calc(var(--bn-space, 90px) - 18px); z-index: 5; margin: 14px -4px 0; padding: 8px 4px 0; background: linear-gradient(transparent, var(--card) 30%); }
  .cr-go .btn { height: 52px; border-radius: 16px; font-size: 15.5px; }
  /* inbox: more breathing room */
  .ch-side .ch-scroll { padding: 0 16px calc(var(--bn-space) + 8px) !important; }
  .ch-side-h { padding: 8px 18px 12px !important; }
  .ch-search { margin: 0 16px 8px !important; }
  .ch-sec { padding: 18px 6px 8px !important; }
  .ch-row { padding: 12px 10px !important; gap: 14px; }
  .ch-none, .ch-hint { padding-left: 6px; padding-right: 6px; line-height: 1.55; }
}

/* =========================================================
   v10: phone home, inbox footer, brown status pills
   ========================================================= */
.top-on.off { display: none !important; }
.pv-ic { filter: invert(1); box-shadow: none; }

/* status pills in the palette, not green */
.tr-pill.on, .badge.ok { border-color: rgba(137, 137, 137, .45); background: rgba(137, 137, 137, .14); color: #4f4f4f; }
.tr-pill.on b { color: #282828; }
[data-mode="dark"] .tr-pill.on, [data-mode="dark"] .badge.ok { color: #c6c6c6; background: rgba(137, 137, 137, .16); }
[data-mode="dark"] .tr-pill.on b { color: #eeeeee; }
.ch-e2e { color: #898989 !important; }

/* home */
.hm-hi { padding: 4px 4px 2px; }
.hm-hi small { display: block; font-size: 13px; font-weight: 600; color: var(--muted); }
.hm-hi h2 { margin: 2px 0 0; font-size: 26px; line-height: 1.15; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hm-hero { position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; width: 100%; min-height: 168px; padding: 20px; border-radius: 24px; text-align: left; border: 0; color: #eeeeee;
  background:
    linear-gradient(105deg, rgba(19, 19, 19, .96) 0%, rgba(40, 40, 40, .9) 52%, rgba(40, 40, 40, .25) 100%),
    repeating-conic-gradient(#4f4f4f 0 25%, #898989 0 50%) right -20px top -20px / 56px 56px;
  box-shadow: 0 20px 40px -20px rgba(19, 19, 19, .8), inset 0 1px 0 rgba(255, 255, 255, .08); transition: transform .15s; }
.hm-hero:active { transform: scale(.985); }
.hh-k { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 99px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #131313; background: #c6c6c6; }
.hh-t { margin-top: auto; font: 700 30px/1.1 var(--fh, Georgia, serif); }
.hh-s { font-size: 13px; color: rgba(238, 238, 238, .75); max-width: 78%; }
.hh-go { position: absolute; right: 18px; bottom: 18px; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; color: #131313; background: linear-gradient(135deg, #c6c6c6, #898989); box-shadow: 0 10px 20px -8px rgba(0, 0, 0, .6); }
.hh-go svg { width: 22px; height: 22px; }
.hm-hero[disabled] { opacity: .85; justify-content: center; align-items: center; font-weight: 700; }
.hm-tile { flex-direction: row; align-items: center; gap: 12px; padding: 14px 12px; }
.hm-tile .hm-ic { margin: 0; flex: none; }
.hm-tile > span:last-child { min-width: 0; }
.hm-tile b, .hm-tile small { display: block; }
.hm-sec { display: flex; align-items: center; justify-content: space-between; padding: 6px 4px 0; }
.hm-sec b { font-size: 15px; }
.hm-sec span { min-width: 24px; height: 22px; padding: 0 8px; border-radius: 99px; font-size: 12px; font-weight: 700; line-height: 22px; text-align: center; color: #4f4f4f; background: rgba(137, 137, 137, .16); }
.hm-ppl { display: flex; gap: 12px; overflow-x: auto; padding: 4px 4px 8px; margin: 0 -4px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.hm-ppl::-webkit-scrollbar { display: none; }
.hm-p { flex: none; width: 66px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.hm-pa { position: relative; }
.hm-pa img.av { width: 56px; height: 56px; border-radius: 50%; box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px rgba(137, 137, 137, .55); }
.hm-pa .isl-dot { position: absolute; right: 1px; bottom: 1px; width: 12px; height: 12px; box-shadow: 0 0 0 2px var(--bg); }
.hm-p small { max-width: 100%; font-size: 11.5px; font-weight: 600; color: var(--ink2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* inbox footer: the credits live here on phones */
.ch-foot { display: none; }
@media (max-width: 760px) {
  .foot { display: none !important; }
  .ch-foot { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; margin: 26px 6px 0; padding: 18px 0 6px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
  .ch-foot p { display: flex; gap: 8px; margin: 0; line-height: 1.5; }
  .ch-foot p svg { flex: none; width: 14px; height: 14px; margin-top: 2px; color: #898989; }
  .ch-foot .powered { flex-wrap: wrap; }
  .ch-foot small { font-size: 12px; }
  .ch-foot small b { color: var(--ink2); }
  .home .hm-hi h2 { font-size: 24px; }
  .home #mcard { margin-top: 2px; }
}

/* =========================================================
   v11: bank-style numbers, uniform chat colours, replies,
   thinking dots, full-width desktop home, island colours
   ========================================================= */
:root { --fnum: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
/* money reads like a banking app: one clean sans, tabular figures */
.mc-bal b, .pf-stats b, .hx-r b, .chev-i b, .stk-val input, .amt, .cr-bal b, .stake-grid button, .of-amt, .of-big, .cx-inv-b b, .isl-up, .isl-down, .res-amt, .pot b, .kv b {
  font-family: var(--fnum) !important; font-variant-numeric: tabular-nums lining-nums; letter-spacing: -.02em; }
.mc-bal b { font-weight: 700; font-size: 40px; }
.stk-val input { font-weight: 700; }

/* Google button */
.pv-ic { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #fff; filter: none !important; box-shadow: none; }
.pv-ic svg { width: 15px; height: 15px; }

/* chat: one palette, no green boxes */
.ch, .cx, .mchat { --good: #4f4f4f; --good-soft: rgba(137, 137, 137, .14); }
[data-mode="dark"] .ch, [data-mode="dark"] .cx, [data-mode="dark"] .mchat { --good: #c6c6c6; --good-soft: rgba(137, 137, 137, .16); }
.ch .isl-dot, .cx .isl-dot, .ch-av .isl-dot { background: #4caf6a; }
.ch-e2e-note, .ch-e2e-note.off { color: var(--ink2); background: var(--card2); border: 1px solid var(--line); }
.ch-e2e-note svg, .ch-e2e-note.off svg { color: #898989; }
.cm-sys, .cm-sys.ok { color: var(--ink2); background: var(--card2); border: 1px solid var(--line); }
.cm-sys.ok svg { color: #898989; }
.cm-res { display: flex; align-items: center; gap: 10px; margin: 14px auto 6px; width: max-content; max-width: 92%; padding: 10px 14px; border-radius: 16px; font-size: 13px; color: #eeeeee; background: linear-gradient(135deg, #282828, #131313); box-shadow: 0 10px 22px -14px rgba(19, 19, 19, .8); }
.cm-res > svg, .cm-res > :first-child { flex: none; }
.cm-res svg { width: 18px; height: 18px; color: #cccccc; }
.cm-res span { display: flex; flex-direction: column; gap: 1px; }
.cm-res b { font-family: var(--fnum); color: #cccccc; }
.cm-res.l b { color: #e7a99c; }
.cm-res small { font-size: 11px; color: rgba(238, 238, 238, .65); }
.cm-res time { font-size: 10.5px; color: rgba(238, 238, 238, .55); align-self: flex-end; }

/* replies */
.cm { position: relative; }
.cm-rp { position: absolute; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); background: var(--card); border: 1px solid var(--line); opacity: 0; pointer-events: none; transition: opacity .15s; z-index: 2; }
.cm-rp svg { width: 15px; height: 15px; }
.cm:not(.me) .cm-rp { right: 4px; }
.cm.me .cm-rp { left: 4px; }
@media (hover: hover) { .cm:hover .cm-rp { opacity: 1; pointer-events: auto; } }
.cm.swipe-ok::before { content: ''; position: absolute; left: -34px; top: 50%; width: 26px; height: 26px; margin-top: -13px; border-radius: 50%; background: rgba(137, 137, 137, .25) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236B4A2E' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 14 4 9l5-5'/%3E%3Cpath d='M4 9h10.5a5.5 5.5 0 0 1 0 11H11'/%3E%3C/svg%3E") center / 15px no-repeat; }
.cm-re { display: flex; flex-direction: column; gap: 1px; width: 100%; margin: 0 0 6px; padding: 6px 10px; border-radius: 10px; text-align: left; border-left: 3px solid #898989; background: rgba(137, 137, 137, .14); }
.cm.me .cm-re { background: rgba(238, 238, 238, .14); border-left-color: #c6c6c6; }
.cm-re b { font-size: 11.5px; color: #898989; }
.cm.me .cm-re b { color: #c6c6c6; }
.cm-re span { font-size: 12.5px; opacity: .85; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.cm.flash .cm-b { animation: cmFlash 1.2s ease; }
@keyframes cmFlash { 0%, 40% { box-shadow: 0 0 0 3px rgba(137, 137, 137, .6); } 100% { box-shadow: none; } }
.cx-form.replying { flex-wrap: wrap; }
.cx-reply { flex: 1 0 100%; display: flex; align-items: center; gap: 10px; padding: 8px 10px; margin-bottom: 6px; border-radius: 12px; background: var(--card2); border-left: 3px solid #898989; }
.cx-reply > svg { width: 16px; height: 16px; color: #898989; flex: none; }
.cx-reply span { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cx-reply b { font-size: 12px; color: #4f4f4f; }
[data-mode="dark"] .cx-reply b { color: #c6c6c6; }
.cx-reply small { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cx-reply button { width: 26px; height: 26px; border-radius: 50%; font-size: 17px; color: var(--muted); }

/* the opponent is thinking: three dots */
.think { display: inline-flex; align-items: center; gap: 3px; height: 18px; padding: 0 7px; margin-right: 8px; border-radius: 99px; background: rgba(137, 137, 137, .18); vertical-align: middle; }
.think i { width: 5px; height: 5px; border-radius: 50%; background: #4f4f4f; animation: thinkDot 1.1s ease-in-out infinite; }
[data-mode="dark"] .think i { background: #c6c6c6; }
.think i:nth-child(2) { animation-delay: .15s; } .think i:nth-child(3) { animation-delay: .3s; }
@keyframes thinkDot { 0%, 60%, 100% { transform: translateY(0); opacity: .45; } 30% { transform: translateY(-4px); opacity: 1; } }

/* island: palette, not green */
.island.note.win, .island.over.won { background: linear-gradient(180deg, rgba(40, 40, 40, .92), rgba(19, 19, 19, .95)) !important; }
.island.note.win .isl-ic, .island.over.won .isl-ic { background: #cccccc !important; color: #131313 !important; }
.isl-up { color: #cccccc !important; }

/* the chat button */
.cx-fab { background: linear-gradient(135deg, #4f4f4f, #282828) !important; color: #eeeeee !important; border-radius: 18px !important; box-shadow: 0 14px 30px -12px rgba(19, 19, 19, .7) !important; }

/* desktop: navigation labels and a home that fills the screen */
@media (min-width: 901px) {
  .navl a span { display: inline !important; }
  .navl a { width: auto !important; padding: 0 12px !important; }
  body:not(.isl-wide) .island { display: none !important; }
  body.isl-wide .navl a span { display: none !important; }
  body.isl-wide .navl a { width: 36px !important; padding: 0 !important; }
  .home.split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-areas: "main side"; gap: 20px; align-items: start; }
  .home .home-main { grid-area: main; }
  .home #mcard { grid-area: side; }
  .home .hm-grid { grid-template-columns: repeat(4, 1fr); }
  .home .hm-tile { flex-direction: column; align-items: flex-start; padding: 16px; }
  .home .hm-hero { min-height: 230px; padding: 28px; }
  .home .hh-t { font-size: 40px; }
  .home .hm-online { padding: 16px 18px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); }
}
@media (min-width: 901px) and (max-width: 1180px) { .navl a span { display: none !important; } .navl a { width: 36px !important; padding: 0 !important; } }
@media (max-width: 760px) {
  /* a conversation fills the screen from the very top, so the composer is always visible */
  body.ch-in:not(.kb-up) .ch-main { top: 0 !important; bottom: 0 !important; height: auto !important; }
  .cm-rp { display: none; }
}

/* =========================================================
   v12: header, coming soon, how it works
   ========================================================= */
.navl a { position: relative; }
.soon-tag { font-style: normal; margin-left: 6px; height: 18px; padding: 0 6px; border-radius: 99px; font-size: 10px; font-weight: 700; line-height: 18px; letter-spacing: .02em; color: #4f4f4f; background: rgba(137, 137, 137, .18); }
[data-mode="dark"] .soon-tag { color: #c6c6c6; }
.navl a.nav-play { margin-left: 6px; padding: 0 16px !important; height: 38px; border-radius: 12px; color: #eeeeee !important; font-weight: 700;
  background: linear-gradient(180deg, #4f4f4f, #282828); box-shadow: 0 8px 18px -10px rgba(19, 19, 19, .8), inset 0 1px 0 rgba(255, 255, 255, .14); }
.navl a.nav-play:hover { filter: brightness(1.08); }
.navl a.nav-play svg { color: #cccccc; }
@media (min-width: 901px) and (max-width: 1180px) { .soon-tag { display: none; } .navl a.nav-play { width: auto !important; padding: 0 12px !important; } .navl a.nav-play span { display: inline !important; } }

.soon { max-width: 520px; text-align: center; padding: 40px 28px !important; }
.soon-ic { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 20px; color: #cccccc; background: linear-gradient(135deg, #4f4f4f, #131313); box-shadow: 0 14px 30px -14px rgba(19, 19, 19, .8); }
.soon-ic svg { width: 30px; height: 30px; }
.soon-k { display: block; margin: 18px 0 6px; font-size: 11.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #898989; }
.soon h2 { margin: 0 0 10px; font-size: 30px; }
.soon p { margin: 0 auto 18px; max-width: 400px; color: var(--muted); line-height: 1.6; }
.soon-pts { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 22px; }
.soon-pts span { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; font-size: 12.5px; font-weight: 600; background: var(--card2); border: 1px solid var(--line); }
.soon-pts svg { width: 14px; height: 14px; color: #898989; }

.hw { margin-top: 22px; padding: 40px; border-radius: 24px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); }
.hw-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: end; margin-bottom: 30px; }
.hw-k { font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #898989; }
.hw-head h3 { margin: 10px 0 0; font: 700 clamp(26px, 2.8vw, 36px)/1.15 var(--fh, Georgia, serif); max-width: 440px; }
.hw-head p { margin: 0; color: var(--muted); line-height: 1.65; font-size: 15px; }
.hw-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--line); }
.hw-s { padding: 24px 22px 6px 0; }
.hw-s + .hw-s { padding-left: 22px; border-left: 1px solid var(--line); }
.hw-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.hw-n { font: 600 13px var(--fnum, Inter, sans-serif); letter-spacing: .08em; color: #898989; }
.hw-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; color: #4f4f4f; background: rgba(137, 137, 137, .14); }
[data-mode="dark"] .hw-ic { color: #c6c6c6; }
.hw-ic svg { width: 20px; height: 20px; }
.hw-s h4 { margin: 0 0 8px; font-size: 17px; }
.hw-s p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }
@media (max-width: 900px) {
  .hw { padding: 26px 20px; }
  .hw-head { grid-template-columns: 1fr; gap: 12px; margin-bottom: 18px; }
  .hw-grid { grid-template-columns: 1fr 1fr; }
  .hw-s, .hw-s + .hw-s { padding: 20px 14px 18px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .hw-s:nth-child(even) { padding-left: 14px; border-left: 1px solid var(--line); }
}
@media (max-width: 520px) {
  .hw-grid { grid-template-columns: 1fr; }
  .hw-s:nth-child(even) { padding-left: 0; border-left: 0; }
  .hw-s:last-child { border-bottom: 0; }
}

/* =========================================================
   v13: wallet actions, inbox without the top bar, example chat
   ========================================================= */
.navl a.nav-play .glyph-ic { font-size: 16px; line-height: 1; }
.mc-acts { display: flex; gap: 8px; margin-top: 10px; }
.mc-act { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; border-radius: 12px; font-size: 12.5px; font-weight: 600; color: #eeeeee; background: rgba(19, 19, 19, .32); border: 1px solid rgba(198, 198, 198, .18); }
.mc-act svg { width: 14px; height: 14px; color: #c6c6c6; }
.mc-act:active { transform: scale(.97); }
.cx-ex { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 10px auto 14px; padding: 8px 14px; max-width: 320px; text-align: center; border-radius: 12px; background: var(--card2); border: 1px dashed var(--line); }
.cx-ex span { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: #898989; }
.cx-ex small { font-size: 11.5px; color: var(--muted); }
.cx-ex.end { border-style: solid; padding: 4px 12px; }
@media (max-width: 760px) {
  /* the inbox uses the whole screen: no site bar on top */
  body.on-chat .top { display: none !important; }
  body.on-chat .page { padding-top: env(safe-area-inset-top) !important; }
  body.on-chat .ch { height: calc(var(--vv-h, 100dvh) - env(safe-area-inset-top)) !important; }
  body.on-chat .ch-side-h { padding-top: 14px !important; }
}

/* =========================================================
   v14: architecture diagram, gold buttons, hero chips, header
   ========================================================= */
/* hero chips stay on one line beside each other */
@media (min-width: 901px) { .hero .chips { flex-wrap: nowrap; gap: 6px; } .hero .chip { white-space: nowrap; font-size: 11px; padding: 5px 9px; } .hero .chip svg, .hero .chip .tk { width: 13px; height: 13px; } }
.hb-float.pop { animation: hbPop .45s cubic-bezier(.3, 1.5, .5, 1); }
@keyframes hbPop { from { transform: translateY(6px) scale(.96); opacity: .4; } to { transform: none; opacity: 1; } }

/* architecture diagram */
.ad { margin-top: 6px; }
.ad-svg { display: block; width: 100%; height: auto; font-family: var(--fb, Inter, sans-serif); }
.ad-n rect { fill: var(--card2); stroke: var(--line); stroke-width: 1.5; }
.ad-n.dark rect { fill: #282828; stroke: #4f4f4f; }
.ad-t { text-anchor: middle; font-size: 19px; font-weight: 700; fill: var(--ink); }
.ad-s { text-anchor: middle; font-size: 14px; fill: var(--muted); }
.ad-n.dark .ad-t { fill: #eeeeee; } .ad-n.dark .ad-s { fill: #c6c6c6; }
.ad-e { fill: none; stroke: #898989; stroke-width: 2; }
.ad-e.gold { stroke: #4f4f4f; stroke-width: 2.5; }
.ad-e.dash { stroke-dasharray: 6 6; }
.ad-head { fill: #898989; }
.ad-l rect { fill: var(--card); stroke: var(--line); }
.ad-l text { text-anchor: middle; font-size: 12.5px; font-weight: 600; fill: var(--ink2); }
.ad-mob { display: none; }
@media (max-width: 760px) {
  .ad-svg { display: none; }
  .ad-mob { display: flex; flex-direction: column; align-items: stretch; }
  .ad-m { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; background: var(--card2); border: 1px solid var(--line); }
  .ad-m.dark { background: #282828; border-color: #4f4f4f; color: #eeeeee; }
  .ad-m.dark small { color: #c6c6c6 !important; }
  .ad-mi { flex: none; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; color: #4f4f4f; background: rgba(137, 137, 137, .16); }
  .ad-m.dark .ad-mi { color: #cccccc; background: rgba(204, 204, 204, .12); }
  .ad-mi svg { width: 18px; height: 18px; } .ad-mi .glyph-ic { font-size: 18px; }
  .ad-m b { display: block; font-size: 14.5px; } .ad-m small { font-size: 12px; color: var(--muted); }
  .ad-ma { position: relative; display: flex; align-items: center; gap: 10px; height: 36px; padding-left: 31px; font-size: 12px; font-weight: 600; color: var(--ink2); }
  .ad-ma i { position: absolute; left: 31px; top: 2px; bottom: 2px; width: 2px; background: #898989; }
  .ad-ma i::after { content: ''; position: absolute; left: -4px; bottom: -2px; border: 5px solid transparent; border-top: 7px solid #898989; border-bottom: 0; }
  .ad-ma.up i::after { bottom: auto; top: -2px; border-top: 0; border-bottom: 7px solid #898989; }
  .ad-ma span { margin-left: 14px; }
  .ad-side { display: flex; gap: 12px; margin-top: 14px; padding: 12px 14px; border-radius: 16px; border: 1px dashed #898989; }
  .ad-side > svg { flex: none; width: 18px; height: 18px; color: #898989; margin-top: 2px; }
  .ad-side b { display: block; font-size: 14px; } .ad-side small { font-size: 12px; color: var(--muted); line-height: 1.5; }
}

/* header during setup */
.me-chip.setup { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px !important; border-radius: 99px; font-weight: 600; font-size: 13px; color: #4f4f4f; background: rgba(137, 137, 137, .16) !important; border: 1px solid rgba(137, 137, 137, .4) !important; }
.me-chip.setup svg { width: 15px; height: 15px; }
@media (max-width: 760px) { .me-chip.setup span { display: inline !important; } }

/* profile numbers */
.pf-wld { display: block; margin-top: 3px; font-style: normal; font-size: 10.5px; color: var(--muted); }
.hx-r b em { font-style: normal; font-size: 11px; font-weight: 600; color: var(--muted); }

/* footer X link */
.x-link { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; }
.x-link svg { width: 12px; height: 12px; }

/* gold buttons for the main player actions */
.btn.pri.lg, .navl a.nav-play, .cr-go .btn, .hm-join .btn {
  position: relative; border: 2px solid transparent !important; border-radius: 999px !important; color: #cdcdcd !important;
  background: linear-gradient(180deg, #202020, #0d0d0d) padding-box, linear-gradient(180deg, #e2e2e2 0%, #9e9e9e 34%, #4e4e4e 58%, #c7c7c7 100%) border-box !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .55), 0 12px 26px -12px rgba(0, 0, 0, .75), inset 0 1px 0 rgba(237, 237, 237, .12), inset 0 -8px 14px rgba(0, 0, 0, .45) !important;
  font-family: var(--fh) !important; font-weight: 700 !important; letter-spacing: .05em; text-transform: uppercase; text-shadow: 0 1px 0 rgba(0, 0, 0, .7);
}
.btn.pri.lg { font-size: 14px !important; }
.navl a.nav-play { font-size: 12px !important; }
.btn.pri.lg svg, .navl a.nav-play svg, .cr-go .btn svg { color: #cdcdcd; }
.btn.pri.lg:hover, .navl a.nav-play:hover { filter: brightness(1.1); }
.btn.pri.lg:disabled { filter: grayscale(.5) brightness(.8); }
.pv-btn { text-transform: none !important; font-family: var(--fb, Inter, sans-serif) !important; letter-spacing: 0 !important; }

/* =========================================================
   v15: gold on every main button, the island and the board edge
   ========================================================= */
:root { --gold-rim: linear-gradient(180deg, #e2e2e2 0%, #9e9e9e 34%, #4e4e4e 58%, #c7c7c7 100%); --gold-ink: #cdcdcd; --gold-bg: linear-gradient(180deg, #202020, #0d0d0d); }
.btn.pri, .mc-btn, .hm-join .btn, [data-style] .btn.pri {
  border: 2px solid transparent !important; border-radius: 999px !important; color: var(--gold-ink) !important;
  background: var(--gold-bg) padding-box, var(--gold-rim) border-box !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .5), 0 10px 22px -12px rgba(0, 0, 0, .75), inset 0 1px 0 rgba(237, 237, 237, .12), inset 0 -6px 12px rgba(0, 0, 0, .45) !important;
  font-family: var(--fh) !important; font-weight: 700 !important; letter-spacing: .05em; text-transform: uppercase; text-shadow: 0 1px 0 rgba(0, 0, 0, .7);
}
.btn.pri.sm { font-size: 11px !important; }
.btn.pri:not(.lg):not(.sm) { font-size: 12.5px !important; }
.btn.pri svg, .mc-btn svg { color: var(--gold-ink); }
.btn.pri:hover, .mc-btn:hover { filter: brightness(1.12); }
.btn.pri:disabled { filter: grayscale(.55) brightness(.8); }
.pv-btn { text-transform: none !important; font-family: var(--fb, Inter, sans-serif) !important; letter-spacing: 0 !important; }
/* the raised + in the phone bar and the hero arrow get the same rim */
.bn-plus { background: radial-gradient(circle at 34% 28%, #2c2c2c, #0d0d0d 70%) padding-box, var(--gold-rim) border-box !important; border: 3px solid transparent; color: var(--gold-ink) !important; }
.hh-go { background: var(--gold-bg) padding-box, var(--gold-rim) border-box !important; border: 2px solid transparent; color: var(--gold-ink) !important; }

/* the island: dark with a gold rim */
.island { border: 1.5px solid transparent !important; background: linear-gradient(180deg, #1a1a1a, #0a0a0a) padding-box, var(--gold-rim) border-box !important; color: #e4e4e4 !important; box-shadow: 0 10px 26px -10px rgba(0, 0, 0, .7), inset 0 1px 0 rgba(237, 237, 237, .1) !important; }
.island.note.win, .island.over.won, .island.note.lose, .island.over.lost, .island.live, .island.wait, .island.ready, .island.note { background: linear-gradient(180deg, #1a1a1a, #0a0a0a) padding-box, var(--gold-rim) border-box !important; }
.island .isl-ic { background: var(--gold-rim) !important; color: #131313 !important; }
.isl-up, .island b { color: var(--gold-ink); }

/* the chess board sits in a gold frame */
.board-frame { position: relative; border: 3px solid transparent; background: linear-gradient(145deg, #424242, #282828) padding-box, var(--gold-rim) border-box !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .35), 0 18px 36px -14px rgba(0, 0, 0, .55), inset 0 0 0 1px rgba(237, 237, 237, .14) !important; }
.mc-btn { text-transform: none !important; font-size: 13px !important; }

/* =========================================================
   v16: falling captured pieces, gold send button, gold escrow box
   ========================================================= */
.hero-board { overflow: visible; }
.hb-drop { position: absolute; z-index: 4; display: grid; place-items: center; pointer-events: none; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .25)); transition: opacity .45s; }
.hb-drop.gone { opacity: 0; }
@media (max-width: 760px) { .hb-drop { display: none; } }
.cx-send { border: 2px solid transparent !important; background: var(--gold-bg) padding-box, var(--gold-rim) border-box !important; color: var(--gold-ink) !important; box-shadow: 0 8px 18px -10px rgba(0, 0, 0, .7), inset 0 -4px 8px rgba(0, 0, 0, .4) !important; }
.cx-send svg { color: var(--gold-ink); }
.ad-n.dark rect { fill: #151515; stroke: url(#adGold); stroke-width: 3; }
.ad-n.dark .ad-t { fill: #cdcdcd; }
.ad-n.dark .ad-s { fill: #c6c6c6; }
@media (max-width: 760px) { .ad-m.dark { border: 2px solid transparent !important; background: linear-gradient(180deg, #202020, #0d0d0d) padding-box, var(--gold-rim) border-box !important; } .ad-m.dark b { color: #cdcdcd; } }
.hero-board .hb-float { z-index: 6; }

/* =========================================================
   v17: photos in chat, gold pieces, rematch buttons
   ========================================================= */
.cx-pic { cursor: pointer; }
.cx-pic svg { width: 18px; height: 18px; }
.cm-img { display: grid; place-items: center; width: min(240px, 60vw); max-height: 320px; padding: 0; border-radius: 14px; overflow: hidden; background: var(--card2); border: 1px solid var(--line); cursor: zoom-in; }
.cm-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cm-img-x { font-size: 12px; color: var(--muted); padding: 18px; }
.cm.me .cm-img { border-color: rgba(238, 238, 238, .2); }
.img-view { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; padding: 20px; background: rgba(7, 7, 7, .88); cursor: zoom-out; animation: fadeIn .2s; }
.img-view img { max-width: 100%; max-height: 100%; border-radius: 12px; box-shadow: 0 30px 60px rgba(0, 0, 0, .6); }
.img-view button { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 16px; width: 40px; height: 40px; border-radius: 50%; font-size: 24px; color: #fff; background: rgba(255, 255, 255, .12); }
@keyframes fadeIn { from { opacity: 0; } }

/* gold and black pieces */
[data-pieces="gold"] .pc.cl.w { color: #e9c46a; -webkit-text-stroke: calc(100cqw / 8 * .03) #5a3a12; paint-order: stroke fill;
  filter: drop-shadow(0 1px 0 #f2f2f2) drop-shadow(0 2px 2px rgba(39, 39, 39, .55)); }
[data-pieces="gold"] .pc.cl.b { color: #17110c; -webkit-text-stroke: calc(100cqw / 8 * .026) #c9a050; paint-order: stroke fill;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .45)); }
@supports (-webkit-background-clip: text) {
  [data-pieces="gold"] .pc.cl.w { background: linear-gradient(180deg, #fff1bf 8%, #e8c46c 40%, #a8742a 72%, #f0d07e 96%); -webkit-background-clip: text; background-clip: text; color: transparent; }
}

/* rematch: two buttons side by side */
.res-acts .btn + .btn, .result-acts .btn + .btn { margin-left: 8px; }
@media (min-width: 761px) and (max-width: 900px) { body:not(.isl-wide) .island { display: none !important; } }
@media (min-width: 901px) and (max-width: 1180px) { .home .hm-grid { grid-template-columns: repeat(2, 1fr); } .home .hm-tile { flex-direction: row; align-items: center; } }
.tape-st { background: rgba(137, 137, 137, .14) !important; color: #4f4f4f !important; border-color: rgba(137, 137, 137, .35) !important; }
[data-mode="dark"] .tape-st { color: #c6c6c6 !important; }
.tape-st svg { color: #898989 !important; }

/* =========================================================
   v18: lighter phone layout, phone diagram, chat tabs, liquid nav
   ========================================================= */
.snd, .top .snd { display: none !important; }
.ad-phone { display: none; }
@media (max-width: 760px) {
  .ad-svg:not(.ad-phone) { display: none !important; }
  .ad-phone { display: block !important; max-width: 420px; margin: 0 auto; }
  .ad-phone .ad-t { font-size: 14px; } .ad-phone .ad-s { font-size: 10.5px; } .ad-phone .ad-l text { font-size: 9.5px; }
  .ad-mob { display: none !important; }
}

/* chat list tabs */
.ch-tabs { display: flex; gap: 4px; margin: 2px 4px 4px; padding: 4px; border-radius: 12px; background: var(--card2); border: 1px solid var(--line); }
.ch-tabs button { flex: 1; height: 32px; border-radius: 9px; font-size: 12.5px; font-weight: 600; color: var(--muted); transition: background .2s, color .2s; }
.ch-tabs button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .08); }

/* liquid indicator in the phone bar */
.bn-blob { position: absolute; left: 0; top: 7px; width: 54px; height: 46px; margin-left: -27px; border-radius: 18px; pointer-events: none; z-index: 0;
  background: radial-gradient(60% 60% at 50% 40%, rgba(137, 137, 137, .28), rgba(137, 137, 137, .12)); }
.bn-blob.go { transition: transform .55s cubic-bezier(.5, 1.6, .4, .9); animation: bnGoo .55s ease; }
@keyframes bnGoo { 0% { scale: 1 1; } 35% { scale: 1.55 .78; } 65% { scale: .9 1.1; } 100% { scale: 1 1; } }
.bn { position: relative; z-index: 1; }
.bn.on .bn-ic { animation: bnPop .45s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes bnPop { 0% { transform: translateY(0) scale(1); } 40% { transform: translateY(-4px) scale(1.12); } 100% { transform: translateY(-1px) scale(1); } }

/* ---------- phones: less padding, smaller type, more air ---------- */
@media (max-width: 760px) {
  :root { --top-h: 50px; --bn-h: 58px; }
  body { font-size: 14px; }
  .page { padding-left: 12px !important; padding-right: 12px !important; }
  .top { margin: 0 -12px 10px !important; padding-left: 14px !important; padding-right: 14px !important; }
  .top .logo-img { width: 30px; height: 30px; }
  .top .brand b { font-size: 15px; }
  .me-chip img.av.sm { width: 30px; height: 30px; }
  .top-on { height: 26px; font-size: 11.5px; padding: 0 9px; }
  .card { border-radius: 16px; }
  .split > .card, .grid2 > .card, .page > .enter > .card, .card { padding: 14px !important; }
  h2 { font-size: 20px; }
  .note { font-size: 12px; }
  .btn { height: 38px; font-size: 13px; }
  .btn.lg { height: 46px; }
  .btn.pri.lg { font-size: 12.5px !important; }

  /* home */
  .home-main { gap: 10px; }
  .hm-hi small { font-size: 12px; }
  .hm-hi h2 { font-size: 20px !important; }
  .hm-hero { min-height: 136px; padding: 16px; border-radius: 20px; }
  .hh-k { height: 20px; font-size: 10px; padding: 0 8px; }
  .hh-t { font-size: 24px; }
  .hh-s { font-size: 12px; }
  .hh-go { width: 42px; height: 42px; right: 14px; bottom: 14px; }
  .hh-go svg { width: 18px; height: 18px; }
  .hm-grid { gap: 8px; }
  .hm-tile { padding: 10px; gap: 10px; border-radius: 14px; }
  .hm-ic { width: 32px; height: 32px; border-radius: 10px; }
  .hm-ic svg { width: 16px; height: 16px; }
  .hm-tile b { font-size: 13.5px; }
  .hm-tile small { font-size: 11px; }
  .hm-sec b { font-size: 13.5px; }
  .hm-pa img.av { width: 46px; height: 46px; }
  .hm-p { width: 56px; } .hm-p small { font-size: 10.5px; }

  /* money card and profile */
  .money-card { padding: 14px; border-radius: 18px; }
  .mc-top { margin-bottom: 10px; }
  .mc-bal { margin: 2px 0 12px; } .mc-bal .tk { width: 24px; height: 24px; }
  .mc-bal b { font-size: 30px !important; }
  .mc-addr, .mc-btn { height: 36px; font-size: 12px; }
  .mc-act { height: 34px; font-size: 11.5px; }
  .pf-head { gap: 12px; }
  .pf-av img.av.xl { width: 54px; height: 54px; }
  .pf-t h2 { font-size: 17px; }
  .pf-t small { font-size: 12px; }
  .pf-stats > div { padding: 8px 4px; }
  .pf-stats small { font-size: 10px; } .pf-stats b { font-size: 14px; }
  .pf-link { padding: 10px 2px; font-size: 13.5px; }
  .hx-t b { font-size: 13px; } .hx-t small { font-size: 11px; }

  /* create */
  .cr-head h2 { font-size: 19px; }
  .cr-head small { font-size: 12px; }
  .cr .stk { padding: 12px; margin-top: 12px; }
  .cr .stk-val input { font-size: 32px; }
  .stk-step { width: 38px; height: 38px; }
  .cr .stk-quick button { height: 34px !important; font-size: 13px !important; }
  .cr .seg.full button { height: 34px; font-size: 13px; }
  .chev-i b { font-size: 13px !important; } .chev-i small { font-size: 10px; }
  .cr-go .btn { height: 46px; }

  /* chat list */
  .ch-side-h { padding: 6px 16px 8px !important; }
  .ch-side-h h2 { font-size: 21px; }
  .ch-search { height: 40px; }
  .ch-sec { padding: 12px 6px 6px !important; font-size: 10px; }
  .ch-row { padding: 9px 8px !important; gap: 12px; }
  .ch-av img.av.sm, .ch-ico { width: 42px !important; height: 42px !important; }
  .ch-tt b { font-size: 14px; } .ch-tt small { font-size: 12px; }
  .ch-foot { font-size: 11px; margin-top: 18px; }

  /* conversation */
  .cm-b p { font-size: 14px; }
  .ch-e2e-note { font-size: 11px; padding: 8px 10px; }

  /* game */
  .pbar b { font-size: 13.5px; } .pbar small { font-size: 11px; }
  .clock { font-size: 18px; padding: 6px 10px; }

  /* landing */
  .hero { padding: 18px 14px !important; }
  .display { font-size: 34px !important; }
  .hw { padding: 18px 14px; border-radius: 18px; }
  .hw-head h3 { font-size: 22px; } .hw-head p { font-size: 13.5px; }

  /* profile setup */
  .ob-head h2 { font-size: 20px; } .ob-head .muted { font-size: 13px; }
  .ob-pfp { padding: 10px; gap: 12px; }
  .ob-ph, .ob-ph img.av { width: 68px; height: 68px; }
  .ob2 .av-grid { gap: 6px; }

  /* bottom bar */
  .bn { font-size: 10.5px; }
  .bn svg { width: 21px; height: 21px; }
  .bn-plus { width: 54px; height: 54px; margin-left: -27px; top: -21px; }
  .bn-plus svg { width: 24px; height: 24px; }
  .bn-blob { top: 6px; height: 46px; }
}
.ad-phone .ad-n.dark rect { stroke: url(#adGold2); }

/* =========================================================
   v19: small gold notifications and island, centred sign-in, medal
   ========================================================= */
/* notifications: small, dark with a gold rim */
.nt { width: auto !important; max-width: min(300px, calc(100vw - 32px)) !important; padding: 7px 30px 7px 8px !important; gap: 8px !important; border-radius: 999px !important;
  border: 1.5px solid transparent !important; background: linear-gradient(180deg, #1a1a1a, #0a0a0a) padding-box, var(--gold-rim) border-box !important;
  color: #e4e4e4 !important; box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .7) !important; }
.nt-ic { width: 20px !important; height: 20px !important; font-size: 11px !important; background: var(--gold-rim) !important; color: #131313 !important; }
.nt-ic svg { width: 12px !important; height: 12px !important; }
.nt-ic svg.medal { width: 18px !important; height: 18px !important; }
.nt-t { gap: 0 !important; }
.nt-t b { font-size: 12px !important; font-weight: 600 !important; line-height: 1.25 !important; }
.nt-t small { font-size: 10.5px !important; color: rgba(228, 228, 228, .7) !important; line-height: 1.3 !important; }
.nt:has(small) { border-radius: 16px !important; }
.nt-x { width: 20px !important; height: 20px !important; font-size: 14px !important; right: 5px !important; color: rgba(228, 228, 228, .6) !important; }
.nt-bar { height: 1.5px !important; background: var(--gold-ink, #cdcdcd) !important; }
.nt-act .btn { height: 26px !important; padding: 0 10px !important; font-size: 10.5px !important; }
.nt-ok .nt-ic, .nt-win .nt-ic { background: var(--gold-rim) !important; }
.nt-win .nt-ic { background: none !important; }

/* island: smaller, and on phones it sits under the top bar so it never covers the buttons */
.island { height: 30px !important; padding: 0 12px !important; font-size: 11.5px !important; }
.island .isl-ic { width: 18px; height: 18px; font-size: 10px; }
.island .isl-ic svg { width: 11px; height: 11px; }
.island .isl-ic svg.medal { width: 16px; height: 16px; }
.island.over.won .isl-ic { background: none !important; }
.island img.av.sm { width: 20px !important; height: 20px !important; }
.island .isl-clk { font-size: 11.5px; }
@media (max-width: 760px) {
  .island { top: calc(var(--top-h, 50px) + env(safe-area-inset-top) + 6px) !important; }
  .toasts { top: calc(var(--top-h, 50px) + env(safe-area-inset-top) + 42px) !important; }
}

/* sign-in sits in the middle of the screen */
.auth-center { min-height: calc(100dvh - 190px); display: grid; place-items: center; }
@media (max-width: 760px) { .auth-center { min-height: calc(var(--vv-h, 100dvh) - var(--top-h, 50px) - var(--bn-space, 92px) - 30px); } }

.medal { display: block; }

/* v20: the bottom bar steps aside on match screens, so it never covers the deposit slider or the board */
@media (max-width: 760px) {
  body.on-match .bnav { display: none !important; }
  body.on-match .page { padding-bottom: calc(24px + env(safe-area-inset-bottom)) !important; }
}

/* v21: the match screen never grows wider than the phone, whatever the private chat below it contains */
@media (max-width: 900px) { .livegrid { grid-template-columns: minmax(0, 1fr) !important; } .livegrid > *, .livegrid .mchat, .livegrid .cx-list, .livegrid .cm-b { min-width: 0; } }

/* v22: the result card in a chat reads on one line; partner logos */
.cm-res span { display: block; }
.cm-res small { display: block; margin-top: 2px; }
.powered .tk { color: inherit; border-radius: 5px; box-shadow: 0 0 0 1px rgba(19, 19, 19, .12); }

/* =========================================================
   v20: laptop header during a match (the labels hide to make room for the island;
   the knight on Play is a span, so it must stay, and "Soon" gives its place to the icon)
   ========================================================= */
@media (min-width: 901px) {
  body.isl-wide .navl .soon-tag { display: none !important; }
  body.isl-wide .navl a svg { flex: none; width: 16px; height: 16px; }
  body.isl-wide .navl a { justify-content: center; }
  body.isl-wide .navl a.nav-play { width: 38px !important; flex: none; }
  body.isl-wide .navl a.nav-play .glyph-ic { display: inline !important; }
}
@media (min-width: 901px) and (max-width: 1020px) { body.isl-wide .island { left: 366px !important; } }
