  /* ---------- the hub (lobby-hub.md, frame B · Tab bar; a real tab layout since Kiril's follow-up: "like Clash Royale"), loaded right after lobby.css ----------
     #lobby holds a pager (.hubpager): five panes side by side, one screen wide each, that scroll sideways with snap, so a swipe moves to the
     next tab and the tab bar fixed at the bottom lights the pane that is showing (hub.js keeps the two in step). Left to right: Shop, Album,
     Home, Social, Ranks. Each pane but Home is a page head (the marker title, no back button) over a body that scrolls on its own; Home is
     the hub column (home-bubbles-and-pick-a-game.md, frame C): the header (lobby.css, unchanged), the logo row (the marker logo left, the gem
     pill right), the "N playing now" and offline lines, the card slot (the sign-up card signed out, the challenge cards and the last-table card),
     the event bubbles three a side round the hero (hub.js's HUB_CARDS; your dice on a felt, the level and the XP), then the bottom group pushed
     down: Play, and How to play beside Quests under it (Kiril's ask), clear of the tab bar's raised Home button. The home never scrolls: the steps at the
     end shrink it in the md's order, added by hub.js's fit loop as the room runs out. */
  #lobby { --bar-h: 84px; --home-rise: 30px; --play-under: 8px; --play-gap: 14px; } /* the tab bar's height (over the home indicator's inset), how far the Home circle rises over it, what Play's look reaches below its box (the md's 8 px for its 7 px shadow: the −2° tilt drops nothing, its corners are rounded away) and the room it keeps over the circle */
  #lobby { overflow: hidden; } /* (the pager scrolls, sideways; each pane scrolls down on its own) */
  .hubpager { height: 100%; display: flex; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .hubpager::-webkit-scrollbar { display: none; }
  .hubpager.gliding { scroll-snap-type: none; } /* (while a tap's glide runs: the snap would stop it at the next pane) */
  .hubpane { flex: 0 0 100%; width: 100%; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; position: relative; display: flex; flex-direction: column; overflow: hidden; }
  .hubpane.lpage { background: transparent; } /* (the lobby's green is #lobby's, under every pane) */
  .hubpane .pagehead { flex: 0 0 auto; padding-top: 10px; } /* (#lobby already pads the top by the cutout) */
  .hubpane .pagehead .row { min-height: 52px; }
  .hubpane .pagebody.lbody { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding-bottom: calc(108px + env(safe-area-inset-bottom)); } /* (nothing ends under the bar) */
  #homePage { display: block; overflow-y: auto; } /* (block, not a flex column: a flex item shrinks into its own padding and hides the overflow the fit loop looks for; the fit loop keeps it from scrolling, the scroll is the fallback) */
  /* the Album pane until dice-album ships: one cream card */
  .soon { background: #FFF4D6; color: var(--ink2); border: 4px solid var(--ink2); border-radius: 18px; box-shadow: 0 5px 0 var(--ink2); padding: 16px 14px; margin-top: 6px; display: flex; flex-direction: column; gap: 6px; }
  .soon b { font: 400 24px/1.1 var(--lilita); } .soon small { font: 800 14px/1.35 var(--nunito); color: #5a4a1a; }
  /* the Social pane's sign-in card (signed out) */
  .socialout { margin-top: 6px; }
  .homecol { padding-bottom: 0; } /* (the bottom group pads itself clear of the bar and its Home circle) */
  /* the logo row: the logo smaller and left-aligned (CRAPS turned, DUEL nudged right), the gem pill level with its top */
  .logorow { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-top: 14px; }
  .logorow .logo { align-items: flex-start; text-align: left; font-size: clamp(48px, 15vw, 58px); padding-left: 6px; }
  .logorow .logo .l1 { transform: rotate(-4deg); transform-origin: left center; }
  .logorow .logo .l2 { transform: translateX(34px) rotate(-2deg); transform-origin: left center; }
  .gemslot { flex: 0 0 auto; margin-top: 4px; display: flex; } .gemslot:empty { display: none; }
  /* "N playing now" and the offline line: right under the logo row, left-aligned and small (they show only with text) */
  .playing { text-align: left; font-size: 14px; margin-top: 6px; padding-left: 4px; }
  /* the card slot: the sign-up card (signed out), the challenge cards and the last-table card, 12 px apart */
  .cardslot { display: flex; flex-direction: column; gap: 12px; }
  .cardslot:has(.chal, .lastcard, .signcard) { margin-top: 12px; }
  #hubSignup:empty { display: none; }
  #challengeBox { margin-top: 0; gap: 12px; }
  .signcard { background: #FFF4D6; color: var(--ink2); border: 4px solid var(--ink2); border-radius: 18px; box-shadow: 0 5px 0 var(--ink2); padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
  .signcard b { font: 400 19px/1.15 var(--lilita); }
  .signcard .sgo { height: 48px; padding: 0 16px; background: #FFD23F; color: var(--ink2); border: 3px solid var(--ink2); border-radius: 999px; box-shadow: 0 3px 0 var(--ink2); font: 400 18px var(--lilita); }
  .signcard .sgo:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink2); } .signcard .sgo:hover:not(:disabled) { filter: none; }
  /* signed out: no bubbles and no hero; the sign-up card sits in their place, centred between the logo row and the bottom group */
  .homecol.out .hubbubs { display: none; }
  .homecol.out .cardslot { margin: auto 0; } .homecol.out .homebtns { margin-top: 0; }
  /* the event bubbles: a three-column row 16 px under the logo row (or the lines and the card slot under it): three bubbles down each 92 px side, the hero in the middle */
  .hubbubs { display: grid; grid-template-columns: 92px minmax(0, 1fr) 92px; align-items: start; margin: 16px -6px 0; } /* (the columns reach 6 px into the gutters, as in the frame: a bubble's circle 21 px from the edge) */
  .bubcol { display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; }
  .bub { --bub: #FFF4D6; --bsz: 70px; position: relative; width: 92px; display: flex; flex-direction: column; align-items: center; padding: 0; background: none; border: 0; border-radius: 16px; box-shadow: none; color: #FFF4D6; font: inherit; transition: none; }
  .bub:hover:not(:disabled) { filter: none; } .bub:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
  .bub .bc { position: relative; flex: 0 0 auto; width: var(--bsz); height: var(--bsz); border-radius: 50%; border: 4px solid var(--ink2); box-shadow: 0 5px 0 var(--ink2); background: var(--bub); display: grid; place-items: center; transition: transform 80ms, box-shadow 80ms; }
  .bub:active:not(:disabled) .bc { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink2); }
  .bub .bico { width: calc(var(--bsz) * .486); height: calc(var(--bsz) * .486); display: block; } /* (34 px in the 70 px circle) */
  .bub .bn, .bub .bs { font: 400 15px/1.1 var(--lilita); color: #FFF4D6; white-space: nowrap; text-shadow: 0 2px 0 var(--ink2), 1px 1px 0 var(--ink2), -1px -1px 0 var(--ink2), 1px -1px 0 var(--ink2), -1px 1px 0 var(--ink2); }
  .bub .bn { margin-top: 8px; }
  .bub .bs { margin-top: 3px; font-size: 13px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; } .bub .bs.gold { color: #FFD93B; }
  .bub[data-card="chipround"] { --bub: #F0C24B; } .bub[data-card="roll"] { --bub: #3FA9F5; } .bub[data-card="sunday"] { --bub: #F58A3C; } .bub[data-card="season"] { --bub: #B57BFF; } .bub[data-card="path"] { --bub: #7ED957; } .bub[data-card="league"] { --bub: #C9D2D8; } /* (League's circle wears the tier's colour, account.css's .md.<tier>, which loads later) */
  .bub .bring { position: absolute; inset: -4px; width: calc(100% + 8px); height: calc(100% + 8px); transform: rotate(-90deg); overflow: visible; pointer-events: none; } .bub .bring circle { fill: none; stroke: #FFD93B; stroke-width: 6; } /* the season's progress, round the circle's edge from the top */
  .bub .bdot { position: absolute; top: -8px; right: -1px; width: 22px; height: 22px; box-sizing: border-box; border-radius: 50%; background: #E8505B; border: 4px solid var(--ink2); animation: hubpulse 1.6s ease-in-out infinite; }
  @keyframes hubpulse { 50% { transform: scale(1.2); } }
  .bub.bsoon { opacity: .5; cursor: default; } /* (not ready yet: the pass before the first season) */
  .bub.skel .bs { width: 54px; height: 13px; margin-top: 5px; border-radius: 6px; background: rgba(255,244,214,.18); } /* (before the first answer: a blank line) */
  /* the hero: your dice on a felt with a wooden rim, the level in a gold pill, the XP bar and its line; a tap opens My account on Profile, where the ladder is */
  .hubhero { display: flex; flex-direction: column; align-items: center; min-width: 0; padding: 0 4px; }
  .hfelt { --felt: 178px; width: min(var(--felt), 100%); height: auto; aspect-ratio: 1; flex: 0 0 auto; padding: 0; border-radius: 50%; border: 5px solid var(--ink2); background: radial-gradient(circle at 50% 42%, #1E8A4E, #0B3D22 78%); box-shadow: inset 0 0 0 6px #6B3A1E, inset 0 0 0 9px rgba(11,30,18,.55), 0 7px 0 var(--ink2); display: grid; place-items: center; container-type: inline-size; transition: transform 80ms, box-shadow 80ms; }
  .hfelt:hover:not(:disabled) { filter: none; } .hfelt:active:not(:disabled) { transform: translateY(3px); box-shadow: inset 0 0 0 6px #6B3A1E, inset 0 0 0 9px rgba(11,30,18,.55), 0 4px 0 var(--ink2); } .hfelt:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
  .hfelt .hdice { display: flex; align-items: center; justify-content: center; }
  .hfelt .diepv { width: 31cqw; height: 31cqw; padding: 4.6cqw; gap: 0; border: 3px solid var(--ink2); border-radius: 22%; box-shadow: 0 3px 0 var(--ink2), inset 0 0 0 1px rgba(0,0,0,.1); }
  .hfelt .diepv:first-child { transform: translateY(3cqw) rotate(-14deg); } .hfelt .diepv + .diepv { margin-left: -3cqw; transform: rotate(10deg); } /* (a 3 and a 4, tilted −14° and +10°, overlapping a little) */
  .hlv { margin-top: 16px; height: auto; padding: 4px 16px 3px; background: #F0C24B; color: var(--ink2); border: 3px solid var(--ink2); border-radius: 999px; box-shadow: 0 3px 0 var(--ink2); font: 400 17px/1.15 var(--lilita); white-space: nowrap; transition: transform 80ms, box-shadow 80ms; }
  .hlv:hover:not(:disabled) { filter: none; } .hlv:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink2); } .hlv:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
  .hxp { display: block; width: min(178px, 100%); height: 14px; margin-top: 12px; border: 3px solid var(--ink2); border-radius: 999px; background: #0B3D22; overflow: hidden; } .hxp i { display: block; height: 100%; background: #7ED957; border-radius: 999px; }
  .hxpl { margin-top: 7px; font: 800 12px/1.2 var(--nunito); color: #FFF4D6; white-space: nowrap; text-shadow: 0 1px 0 rgba(0,0,0,.45); }
  /* the bottom group, pushed down (a tall phone's spare room goes above it, so Play stays at the thumb): How to play left and Quests right, then Play full width 18 px under them, its look ending clear of the Home circle */
  .homebtns { margin-top: auto; padding-top: 16px; gap: 18px; padding-bottom: calc(var(--bar-h) + var(--home-rise) + var(--play-under) + var(--play-gap) + env(safe-area-inset-bottom)); }
  .gbtn.play { height: 80px; }
  .hubrow { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .howlink { font: 400 16px/1 var(--lilita); color: #D6F2E0; background: none; border: 0; box-shadow: none; padding: 0 6px; min-height: 44px; border-radius: 8px; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 2px; text-shadow: 0 1px 0 rgba(0,0,0,.45); white-space: nowrap; transition: none; }
  .howlink:hover:not(:disabled) { filter: none; } .howlink:active:not(:disabled) { transform: translateY(1px); } .howlink:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
  .gbtn.tasks { width: min(230px, 100%); height: 54px; padding-top: 5px; align-self: auto; margin: 0 0 0 auto; flex: 0 1 230px; }
  /* the tab bar: fixed to the bottom of #lobby (a size container, so fixed means its own bottom), over the pager, 84 px plus the home indicator's inset, five tabs with a 28 px icon over a 13 px label, Home raised in a gold circle; the one showing is lit (.on, hub.js: a tap or a swipe) */
  .hubtabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 2; height: calc(var(--bar-h) + env(safe-area-inset-bottom)); padding: 0 8px env(safe-area-inset-bottom); background: #0B3D22; border-top: 4px solid var(--ink2); display: flex; justify-content: center; align-items: stretch; }
  .hubtabs .tab { position: relative; flex: 1 1 0; max-width: 88px; min-width: 0; padding: 10px 2px 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 6px; background: none; border: 0; border-radius: 12px; box-shadow: none; color: #CFEBD9; font: 400 13px/1 var(--lilita); transition: none; }
  .hubtabs .tab:hover:not(:disabled) { filter: none; } .hubtabs .tab:active:not(:disabled) { transform: none; } .hubtabs .tab:active:not(:disabled) .ico { transform: translateY(2px); }
  .hubtabs .tab:disabled { opacity: .45; cursor: not-allowed; }
  .hubtabs .tab:focus-visible { outline: 3px solid #fff; outline-offset: -3px; }
  .hubtabs .tab .ico { width: 28px; height: 28px; display: grid; place-items: center; } .hubtabs .tab .ico svg { width: 28px; height: 28px; display: block; }
  .hubtabs .tab .lbl { font: 400 13px/1 var(--lilita); text-transform: none; letter-spacing: 0; white-space: nowrap; } /* (quests.css paints every .lbl as a bingo square's label: put back) */
  .hubtabs .tab.home { justify-content: flex-end; padding-bottom: 13px; }
  .hubtabs .tab.home .ico { position: absolute; top: calc(-4px - var(--home-rise)); left: 50%; width: 66px; height: 66px; margin-left: -33px; border-radius: 50%; background: #FFD23F; border: 4px solid var(--ink2); box-shadow: 0 5px 0 var(--ink2); } /* (rises --home-rise, 30 px, over the bar's 4 px top border) */
  .hubtabs .tab.home .ico svg { width: 34px; height: 34px; }
  .hubtabs .tab .ico { transition: transform .18s ease; }
  .hubtabs .tab.on .lbl { color: #FFD93B; }
  .hubtabs .tab.on:not(.home) .ico { transform: translateY(-3px) scale(1.15); }
  .hubtabs .tab.on:not(.home)::after { content: ""; position: absolute; left: 50%; bottom: 7px; width: 22px; height: 4px; margin-left: -11px; border-radius: 2px; background: #FFD93B; } /* (a small gold bar under the lit tab's label) */
  body.rm .hubtabs .tab .ico { transition: none; }
  .hubtabs .tab.home:active:not(:disabled) .ico { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink2); }
  .hubtabs .tbadge { position: absolute; top: 2px; left: calc(50% + 4px); min-width: 24px; height: 24px; padding: 0 5px; border-radius: 999px; background: #E8343B; border: 3px solid var(--ink2); color: #fff; font: 400 13px/1 var(--lilita); display: grid; place-items: center; } .hubtabs .tbadge:empty { display: none; }
  /* Reduce motion (Settings → Accessibility, or the phone's setting): the dots hold still */
  body.rm .bub .bdot { animation: none; }
  @media (prefers-reduced-motion: reduce) { .bub .bdot { animation: none; } }
  /* ---------- small phones: the home never scrolls. hub.js's fitHome measures the Home pane after every render, font load, resize and card change and
     adds the steps below to the column one at a time, in this order, until the content fits (the table's felt does the same), so the steps follow the
     real heights: a last-table card whose title wraps, a challenge card, the "N playing now" line, a cutout. A step that buys no room is taken off again
     (it would only cost looks: the felt's steps while the bubbles' columns are taller than the hero, the challenge cards' step with none showing). The md's order:
     1. the felt 178 → 144 px; 2. the logo to 48 px; 3. the bubbles 70 → 58 px, their columns' gap 12 → 8, the names 14 px;
     4. the XP line hidden, Play 80 → 70 px, Quests 54 → 48; 5. the challenge cards collapse to one line ("⚔️ Sam challenges you · Accept");
     6. the header and the gaps tighter, then (.nofelt, its own try) the felt hidden, the level pill and the bar staying, centred;
     then eight more (added: the md's six leave a 360×640 phone over by about 120 px without a card, the room the Play rule keeps under Play being fixed):
     7. the logo to 40 px, the columns 8 px under it; 8. the bubbles 58 → 52 px, 6 px between them; 9. the bubbles 52 → 46 px with 4 px between them, the names 13 px and the lines 12 px;
     10. the logo on one line ("CRAPS DUEL" at 32 px), the last-table card's lines on one line each; 11. Play 70 → 60 px, Quests 48 → 44, 10 px between them;
     12. (a challenge card on a 360×640 phone) the six bubbles in two rows of three across the column, the left three over the level and the bar on one line, the right three under them;
     13. the level's line hidden; 14. (both cards there) the last-table card on one line (its line hidden unless it says the chips are short, the pill 34 px), the bubbles 46 → 40 px. ---------- */
  .homecol.fit1 .hfelt { --felt: 144px; }
  .homecol.fit2 .logorow .logo { font-size: 48px; }
  .homecol.fit3 .bub { --bsz: 58px; } .homecol.fit3 .bubcol { gap: 8px; } .homecol.fit3 .bub .bn { font-size: 14px; margin-top: 7px; }
  .homecol.fit4 .hxpl { display: none; } .homecol.fit4 .gbtn.play { height: 70px; font-size: 40px; } .homecol.fit4 .gbtn.tasks { height: 48px; font-size: 26px; padding-top: 4px; }
  .homecol.fit5 .chal { padding: 5px 10px; gap: 8px; } .homecol.fit5 .chal .avw, .homecol.fit5 .chal .game, .homecol.fit5 .chal button[data-cd] { display: none; } .homecol.fit5 .chal .msg::before { content: "⚔️ "; } .homecol.fit5 .chal .msg::after { content: " ·"; } .homecol.fit5 .chal .msg { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .homecol.fit5 .chal button { height: 34px; padding: 0 10px; font-size: 14px; }
  .homecol.fit6 .homehead { min-height: 52px; } .homecol.fit6 .logorow { margin-top: 6px; } .homecol.fit6 .cardslot { gap: 8px; } .homecol.fit6 #challengeBox { gap: 8px; } .homecol.fit6 .cardslot:has(.chal, .lastcard, .signcard) { margin-top: 8px; } .homecol.fit6 .hubbubs { margin-top: 12px; } .homecol.fit6 .homebtns { padding-top: 10px; }
  .homecol.nofelt .hfelt { display: none; } .homecol.nofelt .hubhero { align-self: center; } .homecol.nofelt .hlv { margin-top: 0; }
  .homecol.fit7 .logorow .logo { font-size: 40px; } .homecol.fit7 .hubbubs { margin-top: 8px; }
  .homecol.fit8 .bub { --bsz: 52px; } .homecol.fit8 .bubcol { gap: 6px; } .homecol.fit8 .bub .bn { margin-top: 6px; }
  .homecol.fit9 .bub { --bsz: 46px; } .homecol.fit9 .bubcol { gap: 4px; } .homecol.fit9 .bub .bc { border-width: 3px; box-shadow: 0 4px 0 var(--ink2); } .homecol.fit9 .bub .bring { inset: -3px; width: calc(100% + 6px); height: calc(100% + 6px); } .homecol.fit9 .bub .bdot { width: 18px; height: 18px; border-width: 3px; top: -6px; right: 0; } .homecol.fit9 .bub .bn { font-size: 13px; margin-top: 6px; } .homecol.fit9 .bub .bs { font-size: 12px; margin-top: 1px; }
  .homecol.fit10 .logorow .logo { flex-direction: row; align-items: baseline; gap: 10px; font-size: 32px; } .homecol.fit10 .logorow .logo .l1 { transform: rotate(-3deg); } .homecol.fit10 .logorow .logo .l2 { transform: rotate(-2deg); } .homecol.fit10 .logorow { align-items: center; } .homecol.fit10 .gemslot { margin-top: 0; } .homecol.fit10 .lastcard .lt b, .homecol.fit10 .lastcard .lt small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .homecol.fit11 .gbtn.play { height: 60px; font-size: 34px; } .homecol.fit11 .gbtn.tasks { height: 44px; font-size: 24px; padding-top: 3px; } .homecol.fit11 .homebtns { gap: 10px; }
  .homecol.fit12 .hubbubs { grid-template-columns: repeat(3, minmax(0, 1fr)); justify-items: center; row-gap: 6px; margin-top: 6px; } .homecol.fit12 .bubcol { display: contents; } .homecol.fit12 #hubBubL > .bub { grid-row: 1; } .homecol.fit12 #hubBubR > .bub { grid-row: 3; } .homecol.fit12 .hubhero { grid-row: 2; grid-column: 1 / -1; flex-direction: row; gap: 12px; align-self: auto; } .homecol.fit12 .hfelt { display: none; } .homecol.fit12 .hlv { margin-top: 0; } .homecol.fit12 .hxp { width: 120px; margin-top: 0; } .homecol.fit12 .homebtns { padding-top: 6px; }
  .homecol.fit13 .hubhero { display: none; }
  .homecol.fit14 .lastcard { padding: 5px 10px 5px 12px; } .homecol.fit14 .lastcard .lt b { font-size: 17px; } .homecol.fit14 .lastcard .lt small:not(.bad) { display: none; } .homecol.fit14 .lastcard .lgo { height: 34px; padding: 0 12px; font-size: 15px; margin-right: 24px; } .homecol.fit14 .lastcard .lx { top: 50%; margin-top: -14px; right: 2px; } .homecol.fit14 .bub { --bsz: 40px; } .homecol.fit14 .bub .bdot { top: -4px; } .homecol.fit14 .hubbubs { row-gap: 2px; margin-top: 4px; } .homecol.fit14 .homebtns { gap: 8px; padding-top: 4px; }
