@charset "UTF-8";

.voice-panel { padding:18px 22px; margin-bottom:18px; border:1px solid rgba(214,180,116,.22); border-radius:14px; background:linear-gradient(100deg,#1c3025,#1a241d); }
.voice-heading { display:flex; align-items:center; gap:12px; min-width:0; }
.voice-heading strong { font-size:15px; color:#f1d49d; }
.voice-heading p { font-size:12px; color:#adbbae; margin-top:5px; overflow-wrap:anywhere; }
.voice-symbol { display:grid; place-items:center; flex:0 0 36px; width:36px; height:36px; border-radius:50%; background:#284435; color:#d6b474; }
.voice-panel[data-active="true"] .voice-symbol { box-shadow:0 0 0 4px rgba(130,199,167,.09); color:#82c7a7; }
.voice-count { margin-left:auto; white-space:nowrap; font-size:11px; color:#a9b9ac; }
.voice-controls { display:flex; flex-wrap:wrap; gap:8px; margin-top:14px; }
.voice-members { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.voice-member { display:inline-flex; align-items:center; gap:6px; padding:5px 9px; border-radius:6px; background:#22382b; color:#b3cbb8; font-size:11px; border:1px solid transparent; }
.voice-level { width:6px; height:6px; border-radius:50%; background:#617865; transition:background .15s; }
.voice-member.speaking { border-color:#82c7a7; color:#e1f8e7; }
.voice-member.speaking .voice-level { background:#a4f7bd; box-shadow:0 0 7px #82c7a7; }
.voice-privacy { display:block; color:#a2ae9e; font-size:10px; line-height:1.7; margin-top:11px; }
@media(max-width:600px) { .voice-panel { padding:13px; margin-bottom:12px; } .voice-heading { flex-wrap:wrap; gap:8px; } .voice-heading>div { flex:1; min-width:0; } .voice-count { margin-left:44px; width:100%; } .voice-controls .button { font-size:11px; min-height:36px; padding:8px 11px; } }


:root {
  --bg: #0d1713;
  --surface: #17271f;
  --surface-raised: #20362a;
  --jade: #2c7053;
  --jade-light: #9bdebb;
  --gold: #d9b778;
  --gold-light: #f4dba5;
  --gold-muted: #b5a27d;
  --text: #f4f2e8;
  --muted: #adbdaf;
  --line: rgba(182, 211, 186, .16);
  --line-strong: rgba(204, 218, 187, .28);
  --font-ui: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --shadow-panel: 0 12px 32px rgba(0, 0, 0, .18);
  --red: #b53f43;
  --danger: #ef9994;
  --sidebar-width: 224px;
  --radius: 16px;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.6;
  color-scheme: dark;
  color: var(--text);
  background: var(--bg);
  font-synthesis: none;
  -webkit-tap-highlight-color: transparent;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 320px; scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; background: radial-gradient(ellipse at 95% 0%, #1b2920 0%, transparent 48%), var(--bg); }
button, input, select { font: inherit; }
button, a, input, select { touch-action: manipulation; }
button { color: inherit; cursor: pointer; }
button { border: 0; }
button:disabled { opacity: .38; cursor: not-allowed; box-shadow: none !important; transform: none !important; }
a { color: inherit; text-decoration: none; }
button, a, input, select { outline: none; }
:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
::selection { background: #456b51; color: #fff; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; pointer-events: none; }
.icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.app-shell { min-height: 100dvh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 30; width: var(--sidebar-width); display: flex; flex-direction: column; padding: 36px 22px 22px; background: #111b16; border-right: 1px solid var(--line); }
.brand { display: flex; gap: 13px; align-items: center; padding: 0 8px; }
.brand-monogram { position: relative; font-family: Georgia, serif; font-size: 41px; font-weight: bold; color: var(--gold); line-height: 1; letter-spacing: -5px; padding-right: 4px; }
.brand-monogram span { color: var(--gold-light); }
.brand-monogram i { position: absolute; width: 4px; height: 4px; background: var(--gold); transform: rotate(45deg); left: 11px; bottom: -9px; }
.brand-wordmark { font-size: 23px; font-weight: 600; letter-spacing: 5px; }
.brand-wordmark small { display: block; font-size: 7px; letter-spacing: 1.15px; color: var(--gold-muted); margin-top: 6px; }
.sidebar-divider { height: 1px; background: var(--line); margin: 32px 8px 27px; }
.nav-caption { font-size: 9px; color: #6e8073; letter-spacing: 1.2px; margin: 0 12px 14px; }
.navigation { display: grid; gap: 8px; }
.nav-item { display: flex; align-items: center; gap: 13px; border: 1px solid transparent; padding: 14px 15px; border-radius: 9px; background: none; color: var(--muted); text-align: left; font-size: 14px; }
.nav-item:hover { background: #1d2b21; color: var(--text); }
.nav-item.active { color: var(--gold-light); background: linear-gradient(100deg, #2d3a29, #1c2b21); border-color: rgba(214, 180, 116, .18); }
.nav-item i { width: 5px; height: 5px; margin-left: auto; border-radius: 50%; background: transparent; }
.nav-item.active i { background: var(--gold); box-shadow: 0 0 12px #d6b47466; }
.sidebar-bottom { margin-top: auto; padding-top: 36px; }
.club-seal { display: flex; flex-direction: column; align-items: center; margin: 20px 0 38px; opacity: .38; color: var(--gold); }
.club-seal > span { font: 66px Georgia, serif; line-height: 1.2; }
.club-seal small { text-align: center; line-height: 1.8; letter-spacing: 2px; font-size: 9px; }
.fairplay-note { display: flex; gap: 9px; align-items: flex-start; border-top: 1px solid var(--line); padding: 21px 3px 0; }
.fairplay-note .icon { color: var(--gold-muted); width: 17px; height: 17px; }
.fairplay-note p { font-size: 11px; color: #bbc6b9; line-height: 1.6; }
.fairplay-note small { display: block; font-size: 10px; color: #708375; margin-top: 3px; }
.sidebar-foot { display: block; color: #586b5d; font-size: 10px; margin: 24px 5px 0; }
.main-shell { margin-left: var(--sidebar-width); min-width: 0; }
.topbar { height: 78px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 38px; background: rgba(16, 23, 19, .58); }
.breadcrumb { display: flex; align-items: center; gap: 12px; font-size: 12px; color: #7f9182; }
.breadcrumb strong { font-weight: 500; color: #c3cdbf; }
.breadcrumb .icon { width: 13px; height: 13px; }
.topbar-right { display: flex; align-items: center; gap: 18px; min-width: 0; }
.connection-status { display: flex; align-items: center; gap: 7px; font-size: 11px; background: none; color: var(--muted); padding: 8px 0; white-space: nowrap; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #a28b57; flex-shrink: 0; }
.connection-status[data-state="online"] .status-dot { background: #8bcaa7; box-shadow: 0 0 0 3px #8bcaa712; }
.connection-status[data-state="offline"] .status-dot, .connection-status[data-state="error"] .status-dot { background: var(--danger); }
.connection-status[data-state="reconnecting"] .status-dot, .connection-status[data-state="connecting"] .status-dot { animation: status-pulse 1.6s ease-in-out infinite; }
.topbar-divider { width: 1px; height: 24px; background: var(--line); }
.identity-button { display: flex; gap: 10px; align-items: center; font-size: 12px; padding: 0; background: none; min-width: 0; }
#identity-name { max-width: 140px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar { position: relative; width: 57px; height: 57px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 35% 20%, #497762, #244837 75%); border: 2px solid #709481; color: #f0f5e8; font-weight: 600; font-size: 20px; box-shadow: 0 4px 18px #0004; flex-shrink: 0; }
.avatar-small { width: 32px; height: 32px; font-size: 11px; border: 1px solid #648268; box-shadow: none; }
.avatar-bot { background: radial-gradient(circle at 35% 20%, #414e49, #283b32 75%); color: #bdd0c1; }
.avatar-amber { background: radial-gradient(circle at 35% 20%, #95784b, #594228 75%); border-color: #baa174; }
.avatar .icon { width: 28px; height: 28px; }
.view { max-width: 1580px; margin: 0 auto; padding: 35px 38px 20px; min-width: 0; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 28px; }
.eyebrow { display: block; font-size: 9px; font-weight: 600; color: var(--gold-muted); letter-spacing: 2px; line-height: 1.8; }
h1 { font-size: clamp(25px, 2.4vw, 34px); line-height: 1.35; letter-spacing: -.8px; font-weight: 650; margin-top: 7px; }
.gold-dot { color: var(--gold); }
.page-heading p { font-size: 12px; color: var(--muted); margin-top: 9px; line-height: 1.8; }
.edition-tag { font-size: 10px; letter-spacing: 1.5px; color: var(--gold-muted); padding: 9px 13px; border: 1px solid var(--line); border-radius: 5px; white-space: nowrap; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 9px; padding: 13px 21px; min-height: 46px; border: 1px solid transparent; border-radius: 7px; font-size: 12px; font-weight: 600; letter-spacing: .3px; white-space: nowrap; transition: background .18s, transform .18s, border-color .18s, box-shadow .18s; }
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button .icon { width: 17px; height: 17px; }
.button-gold { color: #283022; background: linear-gradient(110deg, #dfc18c, #cdaa65); box-shadow: inset 0 1px 0 #f6dfa988, 0 3px 12px #0002; }
.button-gold:hover:not(:disabled) { background: linear-gradient(110deg, #f0d6a1, #dcbb7d); box-shadow: 0 5px 20px #cba85c18; }
.button-glass { background: #ffffff06; border-color: #d5dfc333; color: #e6e8d7; }
.button-glass:hover:not(:disabled) { background: #ffffff0d; }
.button-outline { background: transparent; color: #d0ccba; border-color: #d6b47433; }
.button-outline:hover:not(:disabled) { background: #d6b4740b; border-color: #d6b47466; }
.button-muted { background: #ffffff05; color: var(--muted); border-color: var(--line); }
.button-small { min-height: 36px; padding: 9px 14px; font-size: 11px; }
.button-full { width: 100%; margin-top: 22px; }
.icon-button { width: 36px; height: 36px; display: grid; place-items: center; background: transparent; border-radius: 6px; color: var(--muted); flex-shrink: 0; }
.icon-button:hover:not(:disabled) { background: #ffffff09; color: var(--gold-light); }
.text-button { background: none; color: var(--gold); font-size: 11px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 0; }
.text-button:hover:not(:disabled) { color: var(--gold-light); }
.text-button .icon { width: 15px; height: 15px; }
.resume-room { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px 18px; margin-bottom: 20px; border: 1px solid #739b693b; background: #345c2929; border-radius: 9px; }
.resume-room > div { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.resume-room strong { font-size: 12px; }
.resume-room #resume-detail { color: var(--muted); font-size: 11px; }
.live-ring { width: 7px; height: 7px; border: 1px solid var(--jade-light); border-radius: 50%; }
.hero { position: relative; isolation: isolate; min-height: 363px; display: flex; overflow: hidden; border-radius: var(--radius); border: 1px solid #a6b98f24; background: radial-gradient(ellipse at 70% 15%, #3e6040 0%, transparent 70%), linear-gradient(110deg, #1c3c2c, #193326 60%, #233a2a); box-shadow: 0 18px 40px #0002; }
.hero-grain { position: absolute; inset: 0; z-index: -1; opacity: .14; background-image: repeating-linear-gradient(14deg, transparent, transparent 2px, #ffffff10 2px, #ffffff10 3px), repeating-linear-gradient(104deg, transparent, transparent 3px, #00000035 3px, #00000035 4px); pointer-events: none; }
.hero::after { content: ""; position: absolute; inset: 13px; border: 1px solid #ddcb8822; border-radius: 9px; pointer-events: none; z-index: -1; }
.hero-copy { position: relative; z-index: 2; width: 54%; padding: 35px 42px 29px; }
.hero-kicker { display: flex; align-items: center; gap: 9px; font-size: 10px; color: #c4cbaa; letter-spacing: 2px; }
.hero-kicker i { width: 5px; height: 5px; background: var(--gold); transform: rotate(45deg); }
.hero h2 { font-family: "Songti SC", "SimSun", Georgia, serif; font-size: clamp(32px, 3.5vw, 49px); line-height: 1.35; letter-spacing: 1.5px; font-weight: 600; margin: 17px 0 14px; }
.hero h2 span { color: #e1c58f; }
.hero-copy > p { font-size: 11px; line-height: 1.95; color: #bdcbbc; }
.hero-actions { display: flex; gap: 12px; margin-top: 23px; }
.hero-footnote { display: flex; align-items: center; gap: 12px; margin-top: 22px; color: #95ab93; font-size: 9px; letter-spacing: .5px; }
.hero-footnote i { height: 3px; width: 3px; border-radius: 50%; background: #9ca881; }
.hero-art { position: absolute; width: 49%; height: 100%; right: 0; top: 0; }
.art-orbit { width: 405px; height: 405px; border: 1px solid #d3ba7133; border-radius: 50%; position: absolute; top: -15px; left: -5px; }
.orbit-two { width: 350px; height: 350px; top: 13px; left: 22px; border-color: #c2b0751c; }
.art-mark { position: absolute; top: 34px; right: 28px; color: #d6c99716; font: 120px Georgia, serif; letter-spacing: -11px; }
.art-label { position: absolute; top: 30px; left: 6px; font-size: 8px; line-height: 1.8; letter-spacing: 2px; color: #b2bb9066; transform: rotate(-90deg) translate(-100%, -100%); transform-origin: top left; }
.art-card { position: absolute; width: 147px; height: 220px; border-radius: 11px; box-shadow: -8px 19px 24px #04190e66, inset 0 0 0 1px #fff7; background: #f4f0e3; color: #192c25; }
.art-card-back { left: 8%; top: 79px; transform: rotate(-24deg); padding: 8px; background: #e6deca; }
.card-back-design { width: 100%; height: 100%; border: 1px solid #c3a96a; border-radius: 5px; display: grid; place-items: center; color: #ddc383; background-color: #214d3c; background-image: repeating-linear-gradient(45deg, transparent, transparent 7px, #d6b47422 7px, #d6b47422 8px), repeating-linear-gradient(-45deg, transparent, transparent 7px, #d6b47422 7px, #d6b47422 8px); }
.card-back-design > span { font: 34px Georgia, serif; border: 1px solid #d6b47488; border-radius: 50%; padding: 15px 10px; background: #214d3c; box-shadow: 0 0 0 6px #214d3c, 0 0 0 7px #d6b47455; letter-spacing: -3px; }
.art-card-ace { left: 26%; top: 66px; transform: rotate(-8deg); }
.art-card-eight { left: 48%; top: 86px; transform: rotate(15deg); color: var(--red); }
.art-corner { position: absolute; top: 11px; left: 12px; display: flex; flex-direction: column; align-items: center; font: 25px/1 Georgia, serif; }
.art-corner small { font-size: 22px; margin-top: 1px; }
.corner-bottom { top: auto; left: auto; bottom: 11px; right: 12px; transform: rotate(180deg); }
.art-suit { position: absolute; inset: 0; display: grid; place-items: center; font: 110px Georgia, serif; padding-bottom: 12px; }
.eight-pips { display: grid; grid-template-columns: 1fr 1fr; position: absolute; inset: 22px 34px; gap: 0 11px; align-items: center; justify-items: center; font: 32px/1 Georgia, serif; }
.eight-pips b { font-weight: normal; }
.eight-pips b:nth-child(n+5) { transform: rotate(180deg); }
.art-stamp { position: absolute; bottom: 27px; right: 31px; color: #baaf7f; text-align: right; font-size: 8px; letter-spacing: 2px; line-height: 2; }
.art-stamp strong { font-weight: normal; font-size: 7px; color: #87956b; }
.section-heading { display: flex; justify-content: space-between; align-items: center; margin: 31px 0 17px; gap: 18px; }
.section-heading h2 { font-size: 21px; font-weight: 600; margin-top: 4px; }
.mode-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px; }
.mode-card { position: relative; display: flex; flex-direction: column; text-align: left; padding: 22px 24px 0; border-radius: 12px; border: 1px solid var(--line); background: linear-gradient(125deg, #1d2a20, #18211b); min-width: 0; overflow: hidden; transition: border-color .2s, transform .2s, background .2s; }
.mode-card:hover { transform: translateY(-4px); border-color: #d6b47455; background: linear-gradient(125deg, #233329, #1b2920); }
.mode-featured { border-color: #b49b623d; background: radial-gradient(ellipse at top right, #71603120, transparent 70%), #1c281f; }
.mode-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 6px; }
.mode-number { font: 40px/1 Georgia, serif; color: #d0c399; letter-spacing: -2px; }
.mode-number small { display: block; color: #758873; font: 7px/1.5 "Segoe UI", sans-serif; letter-spacing: 1.8px; margin-top: 6px; }
.mode-badge { color: #a3ae95; font-size: 9px; border: 1px solid #b7c79920; padding: 5px 8px; border-radius: 4px; }
.mode-featured .mode-badge { color: var(--gold); border-color: #d6b47433; }
.mode-symbols { height: 43px; display: flex; align-items: center; gap: 6px; margin: 13px 0 11px; }
.mode-symbols i { width: 28px; height: 33px; border: 1px solid #9cad8a30; background: #293b2d; border-radius: 5px; display: grid; place-items: center; font: 21px Georgia, serif; color: #97b9a2; transform: rotate(-8deg); }
.mode-symbols i:nth-child(even) { color: #c4a36a; background: #3b3828; transform: rotate(7deg); }
.mode-symbols i:nth-child(3n) { transform: rotate(-3deg); }
.mode-card > strong { font-size: 16px; font-weight: 550; }
.mode-description { font-size: 10px; line-height: 2; color: #8c9d8c; margin: 10px 0 18px; }
.mode-bottom { display: flex; align-items: center; justify-content: space-between; font-size: 10px; color: #c2be9d; width: calc(100% + 48px); margin-left: -24px; padding: 13px 24px; background: #ffffff02; border-top: 1px solid var(--line); }
.mode-bottom .icon { width: 16px; height: 16px; color: var(--gold); }
.lobby-bottom-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 17px; margin-top: 19px; }
.practice-card { display: flex; align-items: center; gap: 15px; padding: 23px; border: 1px solid var(--line); border-radius: 12px; background: #17231a; }
.practice-icon { width: 48px; height: 48px; background: #34423377; border: 1px solid #bcbf9122; border-radius: 13px; display: grid; place-items: center; color: #c1b58c; flex-shrink: 0; }
.practice-icon .icon { width: 25px; height: 25px; }
.practice-card h3 { font-size: 14px; margin-top: 4px; font-weight: 550; }
.practice-card p { font-size: 10px; line-height: 1.8; color: var(--muted); margin-top: 6px; }
.practice-card .button { margin-left: auto; min-height: 39px; padding: 10px 14px; font-size: 11px; }
.rules-teaser { display: flex; align-items: center; gap: 14px; text-align: left; padding: 23px; border: 1px solid var(--line); border-radius: 12px; background: #1b251d; }
.rules-teaser > .icon:first-child { color: var(--gold-muted); width: 25px; height: 25px; }
.rules-teaser > .icon:last-child { margin-left: auto; width: 14px; height: 14px; color: #6b826a; }
.rules-teaser strong { font-size: 12px; font-weight: 550; }
.rules-teaser small { display: block; font-size: 10px; color: var(--muted); line-height: 1.8; margin-top: 8px; }
.rules-teaser:hover { border-color: #bca26b44; }
.page-footer { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 27px 0 5px; font-size: 9px; color: #637661; line-height: 1.8; }

/* 牌桌与大厅等待区 */
.room-view { padding-top: 26px; }
.room-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 21px; }
.room-heading h1 { font-size: 25px; }
#room-code { font: 22px Georgia, serif; color: var(--gold); margin-left: 9px; letter-spacing: 2px; }
.room-heading p { font-size: 10px; color: var(--muted); margin-top: 8px; line-height: 1.8; }
.room-heading-actions { display: flex; align-items: center; gap: 8px; }
.waiting-panel { padding: 33px 26px 24px; border-radius: var(--radius); border: 1px solid #a7bc9322; background: radial-gradient(ellipse at 50% 0%, #294d353d, transparent 70%), #18261c; }
.waiting-intro { text-align: center; }
.waiting-emblem { color: #cdb27c; display: block; font: 42px/1 Georgia, serif; margin-bottom: 15px; }
.waiting-intro h2 { font-size: 24px; font-weight: 550; margin-top: 8px; }
.waiting-intro p { color: var(--muted); font-size: 11px; line-height: 1.9; margin: 10px auto 17px; max-width: 470px; }
.invite-code { display: inline-flex; align-items: center; gap: 13px; border: 1px dashed #c9b17b44; border-radius: 7px; padding: 5px 10px 5px 16px; background: #111c1655; }
.invite-code > span { font-size: 10px; color: var(--muted); }
.invite-code strong { font-size: 24px; letter-spacing: 5px; font-weight: 550; color: var(--gold-light); }
.waiting-players { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; margin: 28px auto 25px; max-width: 850px; }
.waiting-players[data-size="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 670px; }
.waiting-players[data-size="5"] { grid-template-columns: repeat(5, minmax(0, 1fr)); max-width: 760px; }
.waiting-player { display: flex; flex-direction: column; align-items: center; padding: 21px 8px 14px; border: 1px solid var(--line); background: #ffffff02; border-radius: 10px; min-width: 0; }
.waiting-player .avatar { width: 53px; height: 53px; font-size: 19px; margin-bottom: 12px; }
.waiting-player.empty { border-style: dashed; background: none; color: #667c6b; }
.empty-avatar { width: 53px; height: 53px; margin-bottom: 12px; border: 1px dashed #66816a66; border-radius: 50%; display: grid; place-items: center; }
.waiting-player-name { font-size: 12px; font-weight: 550; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.waiting-player-meta { display: flex; align-items: center; gap: 4px; color: #a59b7d; font-size: 9px; min-height: 17px; margin-top: 5px; }
.waiting-player-meta .icon { width: 12px; height: 12px; }
.waiting-player-state { margin-top: 11px; font-size: 10px; color: #8d9b87; }
.waiting-player-state.ready { color: var(--jade-light); }
.waiting-player-state.disconnected { color: #a88f6f; }
.waiting-controls { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 12px; }
.waiting-help { text-align: center; color: #8e9d88; font-size: 10px; line-height: 1.9; margin-top: 13px; }
.waiting-activity { margin-top: 19px; padding: 19px 24px; border: 1px solid var(--line); border-radius: 12px; background: #19231b; }
.waiting-activity h3 { font-size: 12px; font-weight: 550; color: #c2c8b5; }
.waiting-chat-list { max-height: 150px; overflow-y: auto; margin-top: 13px; font-size: 11px; }
.waiting-chat-form { display: flex; gap: 10px; margin-top: 13px; }
.waiting-chat-form input { flex: 1; min-width: 0; }
.game-layout { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 18px; align-items: stretch; }
.game-column { min-width: 0; }
.table-toolbar { display: flex; align-items: center; gap: 13px; min-height: 35px; margin-bottom: 8px; }
.team-legend { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.team-label { display: inline-flex; align-items: center; gap: 6px; font-size: 10px; padding: 4px 7px; border: 1px solid transparent; border-radius: 4px; white-space: nowrap; }
.team-jade { color: #a0dab8; background: #466e4e25; border-color: #82c7a728; }
.team-amber { color: #e5c18a; background: #94753e20; border-color: #d6b47428; }
.team-label b { font-weight: 500; opacity: .72; }
.versus { font-size: 8px; color: #70816d; font-family: Georgia, serif; }
.round-label { color: #9d9c7f; font-size: 10px; margin-left: auto; }
.table-stage { position: relative; height: clamp(380px, 31vw, 480px); width: 100%; overflow: hidden; background: radial-gradient(ellipse, #1e3123, #121b16 75%); border-radius: 14px; border: 1px solid #acbc9320; isolation: isolate; }
.table-shadow { position: absolute; left: 12%; right: 12%; top: 19%; bottom: 12%; background: #0009; filter: blur(22px); border-radius: 45%; transform: translateY(12px); }
.table-rim { position: absolute; inset: 16% 9%; border-radius: 45%; padding: 10px; background: linear-gradient(140deg, #786548, #463f2e 40%, #635137 80%, #897349); border: 1px solid #baa26d66; box-shadow: 0 8px 0 #0c130eee, 0 13px 23px #0009, inset 0 0 0 3px #302d23, inset 0 0 0 4px #d0ad6355; }
.table-felt { position: relative; height: 100%; border-radius: inherit; border: 2px solid #112a1e; overflow: hidden; background-color: #24533c; background-image: repeating-linear-gradient(22deg, transparent, transparent 2px, #ffffff03 2px, #ffffff03 3px), repeating-linear-gradient(112deg, transparent, transparent 3px, #00000008 3px, #00000008 4px), radial-gradient(ellipse at 50% 35%, #376a48, #1b4230); box-shadow: inset 0 4px 18px #061f1499; }
.felt-ring { position: absolute; inset: 13px; border: 1px solid #cbb67933; border-radius: 45%; }
.felt-ring::after { content: ""; position: absolute; inset: 5px; border: 1px dashed #cbb6791c; border-radius: inherit; }
.felt-brand { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #d6c39110; font: 91px Georgia, serif; letter-spacing: -9px; }
.felt-brand small { font: 9px "Microsoft YaHei", sans-serif; letter-spacing: 5px; margin-top: 7px; color: #d6c39126; }
.table-center { position: absolute; inset: 30% 23% 23%; display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 2; min-width: 0; pointer-events: none; }
.trick-caption { font-size: 10px; color: #d6d9b9; text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 8px; }
.table-cards { display: flex; justify-content: center; min-width: 0; width: 100%; min-height: 79px; padding: 2px 0; }
.table-cards .playing-card { width: 49px; height: 71px; margin-left: -22px; box-shadow: -2px 3px 7px #0005; flex-shrink: 0; }
.table-cards .playing-card:first-child { margin-left: 0; }
.table-cards[data-many="true"] .playing-card { margin-left: -33px; }
.table-cards[data-many="true"] .playing-card:first-child { margin-left: 0; }
.table-cards[data-huge="true"] .playing-card { margin-left: -39px; }
.table-cards[data-huge="true"] .playing-card:first-child { margin-left: 0; }
.table-cards .card-corner { font-size: 14px; top: 4px; left: 4px; }
.table-cards .card-corner small { font-size: 12px; }
.table-cards .card-corner.bottom { top: auto; left: auto; bottom: 4px; right: 4px; }
.table-cards .card-center-symbol { font-size: 25px; }
.table-cards .card-pips { inset: 12px 14px; }
.table-cards .pip { font-size: 13px; }
.table-cards .card-face { font-size: 23px; }
.table-cards .card-face-suit { font-size: 15px; }
.table-cards .joker-word { font-size: 7px; letter-spacing: 1px; }
.table-cards .joker-star { font-size: 24px; }
.combo-label { font-size: 10px; letter-spacing: .5px; color: #e6cd95; margin-top: 4px; text-align: center; line-height: 1.5; }
.turn-status { font-size: 10px; color: #aebd9f; text-align: center; margin-top: 7px; line-height: 1.7; max-width: 100%; overflow-wrap: anywhere; }
.turn-clock { display: inline-flex; align-items: center; gap: 5px; margin-top: 7px; font-size: 8px; color: #adbaa0; }
.turn-clock .icon { width: 11px; height: 11px; }
.turn-clock strong { font-variant-numeric: tabular-nums; font-size: 16px; font-weight: 550; color: #dfcb95; }
.turn-clock.urgent { color: #f0b69c; }
.turn-clock.urgent strong { color: #ffc396; }
.table-seats { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.seat { position: absolute; width: 118px; display: flex; flex-direction: column; align-items: center; transform: translate(-50%, -50%); text-align: center; }
.seat[data-slot="0"] { left: 50%; top: 85%; }
.seat[data-slot="1"] { left: 13%; top: 65%; }
.seat[data-slot="2"] { left: 20%; top: 20%; }
.seat[data-slot="3"] { left: 50%; top: 16%; }
.seat[data-slot="4"] { left: 80%; top: 20%; }
.seat[data-slot="5"] { left: 87%; top: 65%; }
.table-stage[data-size="4"] .seat[data-slot="1"] { left: 12%; top: 49%; }
.table-stage[data-size="4"] .seat[data-slot="2"] { left: 50%; top: 16%; }
.table-stage[data-size="4"] .seat[data-slot="3"] { left: 88%; top: 49%; }
.table-stage[data-size="5"] .seat[data-slot="1"] { left: 13%; top: 60%; }
.table-stage[data-size="5"] .seat[data-slot="2"] { left: 28%; top: 15%; }
.table-stage[data-size="5"] .seat[data-slot="3"] { left: 72%; top: 15%; }
.table-stage[data-size="5"] .seat[data-slot="4"] { left: 87%; top: 60%; }
.seat-avatar-wrap { position: relative; }
.seat-back-cards { position: absolute; left: -15px; bottom: 0; display: flex; transform: rotate(-13deg); z-index: -1; }
.mini-card-back { display: block; width: 20px; height: 29px; margin-left: -12px; border: 2px solid #d9d0b6; border-radius: 3px; background-color: #285440; background-image: repeating-linear-gradient(45deg, transparent, transparent 3px, #d6b47444 3px, #d6b47444 4px), repeating-linear-gradient(-45deg, transparent, transparent 3px, #d6b47433 3px, #d6b47433 4px); box-shadow: -1px 2px 3px #0005; }
.mini-card-back:first-child { margin-left: 0; }
.seat .avatar { width: 48px; height: 48px; font-size: 17px; border-width: 2px; transition: box-shadow .25s; }
.seat.is-turn .avatar { box-shadow: 0 0 0 3px #d6b47433, 0 0 0 4px #dcc68b77, 0 0 24px #d6b4742b; }
.seat.is-self .avatar::after { content: "你"; position: absolute; right: -5px; bottom: -1px; border-radius: 5px; padding: 2px 4px; font-size: 8px; color: #203624; background: #e0c489; border: 1px solid #b7a06e; }
.seat-connection { position: absolute; width: 7px; height: 7px; top: 2px; right: 0; border-radius: 50%; background: #7ac798; border: 1px solid #183c26; }
.seat-connection.offline { background: #8c7860; }
.seat-name { margin-top: 6px; font-size: 10px; line-height: 1.4; color: #eee8d6; max-width: 112px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seat-details { display: flex; align-items: center; justify-content: center; gap: 4px; margin-top: 4px; }
.seat .team-label { font-size: 8px; padding: 2px 4px; }
.seat-count { display: flex; align-items: center; gap: 3px; font-size: 9px; color: #c7c4a7; font-variant-numeric: tabular-nums; }
.seat-count .icon { width: 12px; height: 12px; }
.seat-state { color: #b9c397; font-size: 8px; margin-top: 4px; min-height: 12px; }
.seat-score { color: #8fa08a; font-size: 8px; }
.seat-bubble { position: absolute; left: 50%; top: -20px; transform: translateX(-50%); background: #102a1e; border: 1px solid #91aa693d; border-radius: 4px; padding: 3px 7px; color: #d9ce9f; font-size: 9px; white-space: nowrap; }
.dice-badge { position: absolute; left: -9px; bottom: -3px; font-size: 8px; background: #eee7d4; color: #494b31; padding: 2px 4px; border-radius: 3px; }
.hand-panel { margin-top: 14px; padding: 17px 18px 13px; border-radius: 12px; border: 1px solid var(--line); background: linear-gradient(135deg, #1d2b21, #17231b); min-width: 0; }
.hand-heading { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 5px; }
.hand-heading > div { display: flex; align-items: center; gap: 9px; min-width: 0; }
.hand-heading strong { font-size: 12px; font-weight: 550; }
#hand-count { font-size: 10px; color: var(--muted); }
.hand-scroll { overflow-x: auto; overflow-y: hidden; overscroll-behavior-inline: contain; scrollbar-width: thin; scrollbar-color: #637957 #17231b; padding: 26px 4px 13px; min-width: 0; scroll-behavior: smooth; }
.hand-scroll::-webkit-scrollbar { height: 4px; }
.hand-scroll::-webkit-scrollbar-thumb { background: #637957; border-radius: 4px; }
.hand-scroll::-webkit-scrollbar-track { background: #17231b; }
.hand-cards { display: flex; width: max-content; min-width: 100%; align-items: flex-start; padding-right: 3px; min-height: 100px; }
.playing-card { position: relative; width: 68px; height: 98px; border-radius: 6px; flex-shrink: 0; background-color: #f2eedf; background-image: linear-gradient(130deg, #fff8 0%, transparent 50%, #ded5bf66 100%); border: 1px solid #f6f2e7; box-shadow: -3px 3px 8px #0006; color: #23392c; font-family: Georgia, "Times New Roman", serif; padding: 0; }
button.playing-card { margin-left: -35px; transition: transform .16s ease-out, box-shadow .16s, border-color .16s; touch-action: pan-x; text-align: left; }
button.playing-card:first-child { margin-left: 0; }
button.playing-card:hover:not(:disabled) { transform: translateY(-7px); }
button.playing-card.selected { transform: translateY(-19px); border-color: #edcb76; box-shadow: -2px 3px 8px #0006, 0 0 0 2px #d6b474, 0 0 18px #d6b47420; }
button.playing-card.selected:hover:not(:disabled) { transform: translateY(-22px); }
button.playing-card:focus-visible { outline-offset: 2px; outline-width: 2px; z-index: 2; }
button.playing-card:disabled { opacity: 1; }
.playing-card.card-red { color: #b33d3f; }
.playing-card.card-big-joker { color: #a43d3c; background: linear-gradient(140deg, #fcf3df, #ebdbc0); }
.card-corner { position: absolute; top: 5px; left: 6px; display: flex; flex-direction: column; align-items: center; font-size: 20px; font-weight: bold; line-height: 1; z-index: 2; }
.card-corner small { display: block; font-size: 15px; font-weight: normal; margin-top: 1px; }
.card-corner.bottom { top: auto; left: auto; right: 6px; bottom: 5px; transform: rotate(180deg); }
.card-center-symbol { position: absolute; inset: 0; display: grid; place-items: center; font-size: 40px; padding-top: 1px; }
.card-pips { position: absolute; inset: 16px 19px; }
.pip { position: absolute; transform: translate(-50%, -50%); font-size: 17px; line-height: 1; }
.pip.inverted { transform: translate(-50%, -50%) rotate(180deg); }
.card-face-frame { position: absolute; inset: 17px 16px; border: 1px solid currentColor; display: flex; flex-direction: column; align-items: center; justify-content: center; background: repeating-linear-gradient(45deg, transparent, transparent 3px, #b79c5815 3px, #b79c5815 4px); color: inherit; }
.card-face { font-size: 33px; line-height: 1; }
.card-face-suit { font-size: 21px; }
.joker-word { position: absolute; inset: 15px 0 auto; font: 8px "Segoe UI", sans-serif; letter-spacing: 2px; text-align: center; color: currentColor; }
.joker-star { position: absolute; inset: 0; display: grid; place-items: center; font-size: 37px; }
.joker-caption { position: absolute; bottom: 12px; left: 0; right: 0; text-align: center; font-size: 8px; font-family: "Microsoft YaHei", sans-serif; }
.hand-empty { min-height: 98px; width: 100%; display: flex; align-items: center; justify-content: center; color: #8b9d83; font-size: 12px; }
.hand-tip { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0 11px; font-size: 10px; color: #98a88e; line-height: 1.8; }
.scroll-tip { font-size: 9px; color: #687e68; white-space: nowrap; }
.play-controls { display: flex; justify-content: center; gap: 8px; border-top: 1px solid var(--line); padding-top: 14px; }
.play-controls .button { min-height: 41px; padding: 10px 15px; font-size: 11px; }
.play-controls .button .icon { width: 15px; height: 15px; }
#play-button { min-width: 110px; }
#play-count { min-width: 17px; height: 17px; border-radius: 3px; display: inline-grid; place-items: center; background: #28302219; font-size: 10px; }
.pickup-button:not(:disabled) { color: var(--gold-light); border-color: #caae69; background: #caae6910; }
.action-note { font-size: 9px; color: #7b8f78; text-align: center; line-height: 1.8; margin-top: 10px; }
.finished-controls { display: flex; justify-content: center; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 15px; }
.finished-controls > span { font-size: 11px; color: var(--muted); }
.activity-panel { display: flex; flex-direction: column; min-height: 0; border: 1px solid var(--line); border-radius: 12px; background: #18231b; overflow: hidden; }
.activity-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); padding: 5px 12px 0; }
.activity-tabs button { display: flex; align-items: center; gap: 5px; font-size: 10px; color: #8a9c86; background: none; border-bottom: 2px solid transparent; padding: 13px 4px 12px; flex: 1; white-space: nowrap; justify-content: center; }
.activity-tabs button .icon { width: 14px; height: 14px; }
.activity-tabs button.active { color: var(--gold); border-color: var(--gold); }
.activity-content { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.chat-list, .logs-list { padding: 17px 14px; height: 510px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #415f42 transparent; flex: 1; }
.empty-activity { text-align: center; font-size: 10px; color: #73876e; line-height: 2; padding: 30px 0; }
.chat-item { margin-bottom: 17px; overflow-wrap: anywhere; }
.chat-meta { display: flex; align-items: center; gap: 8px; color: #b5bea3; font-size: 10px; }
.chat-meta strong { font-weight: 550; max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-meta time { margin-left: auto; font-size: 8px; color: #62785f; font-variant-numeric: tabular-nums; }
.chat-text { background: #314a352b; border: 1px solid #8fa88312; border-radius: 0 7px 7px 7px; color: #d1d6bf; padding: 9px 10px; margin-top: 6px; line-height: 1.85; font-size: 11px; white-space: pre-wrap; overflow-wrap: anywhere; }
.waiting-chat-list .chat-item { margin-bottom: 10px; }
.waiting-chat-list .chat-meta { justify-content: flex-start; }
.waiting-chat-list .chat-meta time { margin-left: 8px; }
.waiting-chat-list .chat-text { display: inline-block; margin-top: 4px; padding: 6px 10px; }
.chat-form { position: relative; padding: 12px 12px 25px; display: flex; gap: 3px; align-items: center; border-top: 1px solid var(--line); }
.chat-form input { padding: 10px; font-size: 10px; width: 100%; min-width: 0; background: #101b14; }
.chat-form .icon-button { width: 29px; height: 34px; color: var(--gold); }
.chat-form .icon { width: 16px; height: 16px; }
#chat-counter { position: absolute; bottom: 7px; right: 16px; font-size: 8px; color: #6f8468; }
.log-item { position: relative; margin-left: 3px; border-left: 1px solid #6a7c5a44; padding: 0 0 18px 13px; }
.log-item::before { content: ""; position: absolute; left: -3px; top: 3px; width: 5px; height: 5px; background: #899b71; border-radius: 50%; }
.log-item time { color: #708368; font-size: 8px; }
.log-item p { color: #bfc8af; font-size: 10px; line-height: 1.9; margin-top: 5px; overflow-wrap: anywhere; }
.activity-footer { border-top: 1px solid var(--line); font-size: 8px; padding: 12px 14px; color: #778b6e; display: flex; align-items: center; justify-content: center; gap: 5px; }
.activity-footer .icon { width: 12px; height: 12px; }
.play-arrival .playing-card { animation: play-arrival .4s cubic-bezier(.18, .75, .3, 1) both; animation-delay: calc(var(--card-index, 0) * 17ms); }
.pickup-arrival .playing-card { animation: pickup-arrival .45s ease-out both; }
@keyframes play-arrival { from { opacity: 0; transform: translateY(28px) rotate(-8deg) scale(.9); } to { opacity: 1; transform: translateY(0) rotate(0) scale(1); } }
@keyframes pickup-arrival { from { opacity: 0; transform: translateX(-25px) rotate(-10deg); } to { opacity: 1; transform: translateX(0) rotate(0); } }
@keyframes status-pulse { 50% { opacity: .35; } }

/* 规则手册 */
.rules-overview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 24px; }
.rules-overview > div { display: flex; flex-direction: column; padding: 23px; border: 1px solid var(--line); border-radius: 10px; background: #1b2b2044; }
.rules-overview span { font-size: 9px; color: var(--gold-muted); letter-spacing: 1px; }
.rules-overview strong { font-size: 24px; font-weight: 550; color: #ded6ba; margin: 11px 0 7px; }
.rules-overview small { color: var(--muted); font-size: 10px; line-height: 1.8; }
.rule-card { background: #18251b; border: 1px solid var(--line); border-radius: 12px; padding: 26px; min-width: 0; }
.rule-card h2 { font-size: 19px; font-weight: 550; margin: 7px 0 17px; line-height: 1.5; }
.rule-card p { font-size: 11px; line-height: 2.1; color: #a9b7a1; margin-top: 12px; }
.rule-card strong { color: #e0d7b8; font-weight: 550; }
.rule-card code { color: var(--gold); padding: 2px 4px; border-radius: 3px; background: #0002; font-size: 10px; }
.rank-chain-card { background: radial-gradient(ellipse at top right, #47623c24, transparent 70%), #1b2a1e; }
.rank-chain { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 6px; padding: 7px 0 5px; }
.rank-chain span { padding: 8px 11px; font-size: 12px; color: #c5cfb7; border: 1px solid #95b57928; border-radius: 5px; background: #ffffff02; }
.rank-chain b { font-size: 20px; font-weight: normal; color: #748863; }
.rank-chain .rank-king { color: #e8c995; border-color: #d8b67844; background: #d8b67808; }
.rank-chain .rank-bomb { color: #a9d0b4; border-color: #a3cd8733; }
.rank-chain .rank-fake { color: #d5c3a4; border-color: #b8986c44; background: #b8986c0c; }
.rule-card .rule-callout { padding: 12px 14px; background: #bbaf6610; border-left: 2px solid #bca76b88; border-radius: 0 4px 4px 0; font-size: 10px; }
.rule-callout .icon { width: 15px; height: 15px; vertical-align: middle; color: var(--gold); margin-right: 5px; }
.rules-two-column { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.rule-stack { display: flex; flex-direction: column; gap: 20px; }
.rule-stack .rule-card { flex: 1; }
.rule-definitions { margin: 16px 0 0; }
.rule-definitions > div { border-top: 1px solid var(--line); padding: 14px 0; }
.rule-definitions > div:last-child { padding-bottom: 0; }
.rule-definitions dt { color: #d1d7bf; font-size: 12px; margin-bottom: 6px; font-weight: 550; }
.rule-definitions dd { color: #9eaf97; font-size: 11px; line-height: 2.1; margin-left: 0; }
.rank-order strong { font-size: 10px; }
.pickup-example { display: flex; align-items: center; gap: 8px; margin: 14px 0; }
.example-card { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 40px; height: 58px; border: 1px solid #eee9d3; border-radius: 5px; font: 22px Georgia, serif; background: #f0e8d3; color: #244a33; transform: rotate(-6deg); box-shadow: 0 3px 8px #0003; }
.example-card small { font-size: 15px; }
.example-card:nth-child(2) { color: #a94644; transform: rotate(6deg); margin-right: 8px; }
.pickup-example .icon { margin-right: 8px; color: var(--gold-muted); }
.amber-card { background: #d4b378; border-color: #e4c991; transform: none; color: #42391e; }
.amber-card small { font-size: 11px; }
.rule-list { padding-left: 17px; margin: 12px 0 0; }
.rule-list li { padding-left: 3px; font-size: 11px; color: #a9b7a1; line-height: 2.1; margin-top: 10px; }
.rule-list li::marker { color: #ae9b68; }
.settlement-example { padding: 17px 19px; background: #111e15; border: 1px solid #adbb8622; border-radius: 7px; margin-top: 18px; display: flex; flex-direction: column; gap: 9px; }
.settlement-example span, .settlement-example small { font-size: 10px; color: #8da47c; }
.settlement-example strong { font-size: 14px; }

/* 弹窗与表单 */
dialog.modal { width: min(470px, calc(100% - 32px)); max-height: calc(100dvh - 40px); border: 1px solid #c7b17944; border-radius: 16px; padding: 28px 30px; color: var(--text); background: radial-gradient(ellipse at top left, #31523755, transparent 70%), #18261c; box-shadow: 0 24px 100px #0009; overflow: auto; scrollbar-width: thin; scrollbar-color: #586d47 transparent; }
dialog::backdrop { background: #060d0acf; backdrop-filter: blur(8px); }
dialog[open] { animation: dialog-arrival .18s ease-out; }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-top: -5px; }
.modal-header .icon-button { margin-right: -10px; }
.modal h2 { font-size: 25px; font-weight: 550; line-height: 1.5; margin-top: 10px; }
.modal > p { color: var(--muted); font-size: 11px; line-height: 2; margin: 9px 0 24px; }
.modal label:not(.toggle-field), .modal legend { display: block; font-size: 11px; color: #c2c8b2; margin: 16px 0 9px; }
.modal label small { color: #778c72; font-size: 10px; margin-left: 6px; }
input, select { display: block; width: 100%; padding: 12px 13px; background: #101c14; border: 1px solid #95a67e33; border-radius: 6px; color: #ede9d8; min-height: 42px; font-size: 12px; }
input::placeholder { color: #73846b; font-size: 11px; }
input:focus, select:focus { border-color: #d6b47499; box-shadow: 0 0 0 3px #d6b4740c; }
input:disabled, select:disabled { opacity: .45; }
input[type="number"] { font-variant-numeric: tabular-nums; }
.modal-footnote { display: block; color: #75876d; text-align: center; font-size: 9px; line-height: 1.8; margin-top: 21px; }
.modal-brand { font: 49px Georgia, serif; letter-spacing: -5px; color: var(--gold); text-align: center; margin: 5px 0 30px; }
.modal-brand span { display: block; font: 8px "Segoe UI", sans-serif; letter-spacing: 2px; color: #988761; margin-top: 10px; }
.nickname-modal > .eyebrow, .nickname-modal h2 { text-align: center; }
.nickname-modal > p { text-align: center; margin-top: 11px; }
.size-field { border: 0; padding: 0; margin: 0; }
.modal .size-field legend { margin-top: 0; }
.size-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.modal .size-options label { margin: 0; cursor: pointer; position: relative; }
.size-options input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; margin: 0; z-index: 1; cursor: pointer; }
.size-options label > span { display: flex; flex-direction: column; align-items: center; padding: 15px 5px; border: 1px solid #8b9e742e; border-radius: 7px; color: #a7b29b; background: #111e1644; }
.size-options strong { font-size: 18px; font-weight: 550; }
.modal .size-options small { display: block; color: #8a9b78; font-size: 9px; margin: 6px 0 0; }
.size-options input:checked + span { border-color: #cfb47399; background: #ccaf6410; color: var(--gold-light); }
.size-options input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 3px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.field-hint { font-size: 10px; color: #8fa180; line-height: 1.8; margin-top: 7px; }
.toggle-field { display: flex; align-items: center; justify-content: space-between; position: relative; gap: 12px; padding: 17px 0 0; margin-top: 20px; border-top: 1px solid var(--line); cursor: pointer; }
.toggle-field strong { font-size: 11px; font-weight: 550; }
.modal .toggle-field small { display: block; margin: 7px 0 0; font-size: 9px; line-height: 1.8; }
.toggle-field input { width: 39px; height: 22px; min-height: 0; position: absolute; right: 0; opacity: 0; z-index: 1; cursor: pointer; }
.toggle-track { width: 39px; height: 22px; background: #536448; border-radius: 20px; flex-shrink: 0; position: relative; }
.toggle-track::before { content: ""; position: absolute; width: 16px; height: 16px; border-radius: 50%; background: #d8d9c4; left: 3px; top: 3px; transition: transform .2s; }
.toggle-field input:checked + .toggle-track { background: #c3a56a; }
.toggle-field input:checked + .toggle-track::before { transform: translateX(17px); background: #f0e7cc; }
.toggle-field input:focus-visible + .toggle-track { outline: 2px solid var(--gold); outline-offset: 3px; }
.form-error { color: var(--danger); font-size: 11px; line-height: 1.8; margin-top: 12px; padding: 9px 11px; background: #a54f3d13; border-radius: 5px; overflow-wrap: anywhere; }
.code-input { text-align: center; letter-spacing: 6px; font-size: 27px; min-height: 65px; text-transform: uppercase; }
.code-input::placeholder { letter-spacing: 2px; font-size: 13px; }
.result-modal { text-align: center; }
.result-emblem { width: 68px; height: 68px; border-radius: 50%; background: #d0b37612; border: 1px solid #d6b47455; margin: 11px auto 17px; display: grid; place-items: center; color: var(--gold); }
.result-emblem .icon { width: 35px; height: 35px; }
.result-emblem.team-jade { color: #9dd3ad; background: #54866625; border-color: #82c7a755; }
.modal .result-unit { color: #aeaf8f; font-size: 10px; line-height: 1.8; margin: -8px 0 18px; }
.score-table-wrapper { overflow-x: auto; border: 1px solid var(--line); border-radius: 7px; }
.score-table { width: 100%; border-collapse: collapse; font-size: 11px; text-align: left; }
.score-table th { font-size: 9px; font-weight: 500; color: #819575; padding: 12px 12px; background: #101b1444; }
.score-table td { padding: 11px 12px; border-top: 1px solid var(--line); }
.score-table th:nth-child(n+2), .score-table td:nth-child(n+2) { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.score-table .player-score-name { display: block; color: #e0decc; overflow-wrap: anywhere; font-size: 11px; line-height: 1.6; }
.score-table .team-label { margin-top: 3px; padding: 0; border: 0; background: none; font-size: 8px; }
.score-positive { color: #9bd2a6; font-weight: 600; }
.score-negative { color: #d7a78f; }
.score-table tr.is-self { background: #d0b37608; }
.result-status { font-size: 10px; color: #93a389; line-height: 1.8; margin: 14px 0; }
.result-actions { display: flex; justify-content: center; gap: 9px; flex-wrap: wrap; }
.result-actions .button { padding: 11px 16px; min-height: 42px; font-size: 11px; }
.toast-region { position: fixed; bottom: max(27px, env(safe-area-inset-bottom)); left: calc(50% + var(--sidebar-width) / 2); transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; align-items: center; gap: 8px; width: min(430px, calc(100vw - 36px)); pointer-events: none; }
.toast { display: flex; align-items: center; gap: 10px; padding: 13px 18px; background: #2b3d2a; color: #e8e4cc; border: 1px solid #b7ae6a55; border-radius: 8px; box-shadow: 0 8px 30px #0006; font-size: 12px; line-height: 1.8; max-width: 100%; overflow-wrap: anywhere; animation: dialog-arrival .18s ease-out; }
.modal-toasts { position: sticky; bottom: 0; z-index: 2; display: grid; gap: 7px; }
.modal-toasts:not(:empty) { margin-top: 15px; }
.modal-toasts .toast { width: 100%; text-align: left; font-size: 11px; padding: 10px 12px; }
.toast.error { background: #382d22; border-color: #e4997144; color: #f0cebc; }
.toast .icon { width: 17px; height: 17px; }
.noscript-message { position: fixed; z-index: 99; bottom: 0; left: 0; right: 0; background: #332b20; padding: 20px; text-align: center; color: var(--gold-light); }
@keyframes dialog-arrival { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }

/* 平板与窄桌面 */
@media (min-width: 1500px) {
  .hero { min-height: 402px; }
  .hero-copy { padding-top: 41px; }
  .hero-art { transform: scale(1.1); transform-origin: center; }
  .hero h2 { font-size: 51px; }
  .hero-copy > p { font-size: 12px; }
  .mode-card { padding-top: 25px; }
  .mode-description { font-size: 11px; }
  .game-layout { grid-template-columns: minmax(0, 1fr) 270px; gap: 22px; }
  .table-stage { height: 500px; }
}
@media (max-width: 1250px) {
  :root { --sidebar-width: 190px; }
  .sidebar { padding-inline: 16px; }
  .brand { gap: 10px; padding-inline: 5px; }
  .brand-wordmark { font-size: 20px; }
  .brand-wordmark small { font-size: 6px; letter-spacing: .9px; }
  .topbar { padding-inline: 26px; }
  .view { padding-inline: 26px; }
  .hero-copy { padding-inline: 31px; }
  .art-card { width: 126px; height: 190px; }
  .art-card-back { top: 100px; }
  .art-card-ace { top: 86px; }
  .art-card-eight { top: 106px; }
  .art-suit { font-size: 95px; }
  .eight-pips { font-size: 26px; inset: 20px 29px; }
  .mode-card { padding-inline: 18px; }
  .mode-bottom { width: calc(100% + 36px); margin-left: -18px; padding-inline: 18px; }
  .lobby-bottom-grid { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
  .practice-card { padding: 20px 17px; gap: 12px; flex-wrap: wrap; }
  .practice-card .button { margin-left: 60px; }
  .rules-teaser { padding: 20px 17px; gap: 10px; }
  .game-layout { grid-template-columns: minmax(0, 1fr) 208px; gap: 12px; }
  .play-controls { gap: 6px; }
  .play-controls .button { padding-inline: 11px; }
  .table-stage { height: 395px; }
  .table-center { inset-inline: 24%; }
  .seat { width: 100px; }
  .seat .avatar { width: 43px; height: 43px; font-size: 15px; }
  .seat-name { max-width: 98px; }
}
@media (max-width: 1050px) {
  :root { --sidebar-width: 170px; }
  .sidebar { padding-inline: 12px; }
  .brand-monogram { font-size: 35px; }
  .brand-wordmark { font-size: 18px; }
  .brand-wordmark small { display: none; }
  .nav-item { padding: 13px 12px; font-size: 12px; gap: 10px; }
  .nav-caption { font-size: 8px; letter-spacing: .8px; }
  .view { padding-inline: 23px; }
  .topbar { padding-inline: 23px; }
  .hero-copy { width: 58%; padding-left: 28px; padding-right: 12px; }
  .hero-art { width: 45%; }
  .art-card { width: 113px; height: 175px; }
  .art-card-back { left: 0; }
  .art-card-ace { left: 20%; }
  .art-card-eight { left: 42%; }
  .art-corner { font-size: 21px; left: 9px; top: 9px; }
  .art-corner small { font-size: 18px; }
  .corner-bottom { right: 9px; bottom: 9px; left: auto; top: auto; }
  .eight-pips { inset: 20px 25px; font-size: 24px; gap: 0 6px; }
  .art-suit { font-size: 82px; }
  .art-orbit { left: -80px; }
  .orbit-two { left: -52px; }
  .hero h2 { font-size: 37px; }
  .hero-actions .button { padding: 12px 15px; font-size: 11px; }
  .hero-footnote { gap: 8px; font-size: 8px; }
  .mode-card { padding-top: 18px; }
  .mode-card > strong { font-size: 14px; }
  .mode-number { font-size: 34px; }
  .mode-badge { font-size: 8px; padding: 4px 5px; }
  .mode-symbols { gap: 3px; }
  .mode-symbols i { width: 24px; height: 30px; font-size: 18px; }
  .game-layout { grid-template-columns: minmax(0, 1fr); }
  .table-stage { height: 430px; }
  .table-center { inset: 31% 23% 23%; }
  .activity-panel { height: 290px; margin-top: 3px; }
  .activity-content { overflow: hidden; }
  .chat-list, .logs-list { height: auto; max-height: 230px; }
  .chat-form { padding-bottom: 23px; }
  .chat-item { margin-bottom: 11px; }
  .chat-meta strong { max-width: 80%; }
  .chat-text { display: inline-block; max-width: 100%; }
  .play-controls .button { padding-inline: 22px; }
  .hand-cards { justify-content: flex-start; }
  .rules-overview > div { padding: 19px; }
  .rules-overview strong { font-size: 20px; }
  .rule-card { padding: 22px; }
  .rule-card h2 { font-size: 17px; }
}
@media (max-width: 820px) {
  :root { --sidebar-width: 74px; }
  .sidebar { padding: 27px 11px 18px; align-items: center; }
  .brand { padding: 0; }
  .brand-monogram { font-size: 37px; }
  .brand-wordmark, .nav-caption, .sidebar-bottom { display: none; }
  .sidebar-divider { width: 32px; margin: 31px 0 24px; flex-shrink: 0; }
  .navigation { width: 100%; }
  .nav-item { justify-content: center; padding: 14px 0; }
  .nav-item span, .nav-item i { display: none; }
  .nav-item .icon { width: 22px; height: 22px; }
  .topbar { height: 65px; }
  .view { padding-top: 27px; }
  .mode-grid { gap: 12px; }
  .mode-card { padding-inline: 14px; }
  .mode-bottom { width: calc(100% + 28px); margin-left: -14px; padding-inline: 14px; }
  .lobby-bottom-grid { gap: 12px; }
  .edition-tag { font-size: 9px; }
  .waiting-panel { padding-inline: 17px; }
  .waiting-players { gap: 9px; }
  .waiting-player { padding-inline: 5px; }
  .waiting-player .avatar, .empty-avatar { width: 43px; height: 43px; font-size: 16px; }
  .waiting-player-name { font-size: 11px; }
}

/* 手机：竖屏紧凑围桌，只有手牌轨道横向滚动 */
@media (max-width: 640px) {
  :root { --sidebar-width: 0px; }
  html, body { width: 100%; }
  .sidebar { inset: 0 0 auto 0; width: 100%; height: 63px; padding: 0 17px; flex-direction: row; justify-content: space-between; align-items: center; border-right: 0; border-bottom: 1px solid var(--line); background: #111d17f5; backdrop-filter: blur(12px); }
  .brand { gap: 9px; }
  .brand-monogram { font-size: 31px; }
  .brand-monogram i { bottom: -5px; width: 3px; height: 3px; }
  .brand-wordmark { display: block; font-size: 17px; letter-spacing: 3px; }
  .sidebar-divider { display: none; }
  .navigation { display: flex; width: auto; gap: 4px; }
  .nav-item { padding: 10px; border-radius: 6px; gap: 5px; }
  .nav-item .icon { width: 17px; height: 17px; }
  .nav-item span { display: block; font-size: 10px; }
  #room-nav span { display: none; }
  .main-shell { margin-left: 0; padding-top: 63px; }
  .topbar { height: 49px; padding: 0 17px; }
  .breadcrumb { font-size: 10px; gap: 6px; }
  .breadcrumb > span { display: none; }
  .breadcrumb .icon { width: 11px; height: 11px; }
  .topbar-right { gap: 10px; }
  .connection-status { font-size: 9px; gap: 5px; }
  .status-dot { width: 5px; height: 5px; }
  .topbar-divider { height: 19px; }
  .identity-button { font-size: 10px; gap: 6px; }
  #identity-name { max-width: 88px; }
  .avatar-small { width: 26px; height: 26px; font-size: 9px; }
  .view { padding: 25px 17px 17px; width: 100%; }
  .page-heading { margin-bottom: 20px; gap: 12px; }
  .eyebrow { font-size: 8px; letter-spacing: 1.5px; }
  h1 { font-size: 27px; margin-top: 6px; letter-spacing: -.5px; }
  .page-heading p { font-size: 11px; margin-top: 7px; }
  .edition-tag { display: none; }
  .hero { min-height: 435px; border-radius: 12px; }
  .hero-copy { width: 100%; padding: 29px 26px 25px; }
  .hero-kicker { font-size: 9px; letter-spacing: 1.4px; }
  .hero h2 { font-size: 36px; letter-spacing: 1px; margin-top: 16px; }
  .hero-copy > p { font-size: 10px; max-width: 165px; }
  .hero-actions { position: absolute; bottom: 52px; left: 26px; right: 26px; gap: 10px; margin-top: 0; }
  .hero-actions .button { flex: 1; min-height: 43px; padding: 11px 10px; font-size: 11px; }
  .hero-footnote { position: absolute; bottom: 25px; left: 26px; font-size: 8px; gap: 11px; }
  .hero-art { width: 200px; height: 260px; top: 105px; right: -21px; opacity: .96; z-index: 1; pointer-events: none; }
  .art-card { width: 90px; height: 139px; border-radius: 7px; }
  .art-card-back { top: 77px; left: 5px; padding: 5px; transform: rotate(-22deg); }
  .art-card-ace { top: 69px; left: 35px; transform: rotate(-6deg); }
  .art-card-eight { top: 93px; left: 76px; transform: rotate(17deg); }
  .art-corner { font-size: 17px; left: 7px; top: 7px; }
  .art-corner small { font-size: 15px; }
  .corner-bottom { left: auto; top: auto; right: 7px; bottom: 7px; }
  .art-suit { font-size: 61px; padding-bottom: 7px; }
  .eight-pips { inset: 17px 22px; font-size: 20px; gap: 0 3px; }
  .card-back-design > span { font-size: 24px; padding: 10px 7px; }
  .art-mark { font-size: 86px; top: -7px; right: 18px; }
  .art-orbit { width: 300px; height: 300px; top: -18px; left: -83px; }
  .orbit-two { width: 260px; height: 260px; top: 2px; left: -63px; }
  .art-label, .art-stamp { display: none; }
  .section-heading { margin-top: 28px; }
  .section-heading h2 { font-size: 19px; }
  .section-heading .text-button { font-size: 10px; }
  .mode-grid { grid-template-columns: 1fr; gap: 12px; }
  .mode-card { min-height: 148px; padding: 18px 19px 16px 105px; }
  .mode-top { position: absolute; left: 20px; top: 20px; display: block; }
  .mode-number { font-size: 38px; }
  .mode-number small { font-size: 7px; }
  .mode-badge { display: block; font-size: 8px; padding: 4px 6px; margin-top: 13px; }
  .mode-symbols { position: absolute; right: 18px; bottom: 16px; margin: 0; height: auto; gap: 3px; opacity: .65; }
  .mode-symbols i { width: 19px; height: 25px; font-size: 15px; }
  .mode-card > strong { font-size: 16px; margin-top: 2px; }
  .mode-description { font-size: 10px; margin: 8px 0 12px; }
  .mode-bottom { background: none; border: 0; padding: 0; margin: 0; width: auto; justify-content: flex-start; gap: 9px; font-size: 9px; }
  .mode-bottom .icon { width: 13px; height: 13px; }
  .lobby-bottom-grid { grid-template-columns: 1fr; margin-top: 17px; }
  .practice-card { padding: 19px; gap: 13px; }
  .practice-card > div { min-width: 0; flex: 1; }
  .practice-card h3 { font-size: 14px; }
  .practice-card p { font-size: 10px; }
  .practice-card .button { width: 100%; margin-left: 61px; margin-top: 3px; }
  .rules-teaser { padding: 19px; gap: 16px; }
  .rules-teaser small { margin-top: 5px; }
  .page-footer { font-size: 8px; padding-top: 22px; gap: 10px; flex-wrap: wrap; }
  .resume-room { padding: 12px; gap: 9px; }
  .resume-room > div { gap: 5px; }
  .resume-room strong { font-size: 10px; }
  .resume-room #resume-detail { font-size: 9px; flex-basis: 100%; margin-left: 12px; }
  .resume-room .button { font-size: 10px; padding-inline: 10px; }
  .room-view { padding: 19px 12px 17px; }
  .room-heading { padding-inline: 3px; margin-bottom: 13px; align-items: flex-start; gap: 8px; }
  .room-heading h1 { font-size: 20px; }
  #room-code { font-size: 19px; letter-spacing: 1px; margin-left: 3px; }
  .room-heading p { font-size: 9px; margin-top: 5px; }
  .room-heading-actions { gap: 2px; padding-top: 9px; }
  .room-heading-actions .button { min-height: 32px; padding: 8px; font-size: 9px; gap: 5px; }
  .room-heading-actions .button .icon { width: 13px; height: 13px; }
  .room-heading-actions .icon-button { width: 27px; height: 32px; }
  .room-heading-actions .icon { width: 17px; height: 17px; }
  .waiting-panel { padding: 26px 16px 21px; border-radius: 12px; }
  .waiting-intro h2 { font-size: 20px; }
  .waiting-intro p { font-size: 10px; }
  .invite-code strong { font-size: 23px; }
  .waiting-players, .waiting-players[data-size="4"], .waiting-players[data-size="5"] { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 24px; }
  .waiting-player { padding: 15px 8px 12px; }
  .waiting-player .avatar, .empty-avatar { width: 48px; height: 48px; font-size: 18px; }
  .waiting-player-name { font-size: 12px; }
  .waiting-player-state { margin-top: 7px; }
  .waiting-controls { gap: 8px; }
  .waiting-controls .button { min-height: 40px; padding: 10px 13px; font-size: 10px; }
  .waiting-help { font-size: 9px; }
  .waiting-activity { padding: 17px; margin-top: 13px; }
  .waiting-chat-form { gap: 7px; }
  .waiting-chat-form input { font-size: 11px; padding: 10px; }
  .waiting-chat-form input::placeholder { font-size: 10px; }
  .game-layout { gap: 12px; }
  .table-toolbar { min-height: 30px; margin-bottom: 5px; gap: 7px; }
  .team-legend { gap: 6px; }
  .team-label { font-size: 9px; padding: 4px 5px; }
  .versus { font-size: 7px; }
  .round-label { font-size: 9px; }
  #show-result-button { font-size: 9px; }
  .table-stage { height: clamp(385px, 104vw, 455px); border-radius: 12px; }
  .table-rim { inset: 12% 12% 15%; border-radius: 43%; padding: 8px; }
  .felt-ring { inset: 10px; }
  .table-center { inset: 34% 17% 26%; }
  .felt-brand { font-size: 72px; }
  .felt-brand small { font-size: 7px; letter-spacing: 3px; }
  .seat { width: 91px; }
  .seat .avatar { width: 41px; height: 41px; font-size: 15px; }
  .seat .avatar .icon { width: 23px; height: 23px; }
  .seat-name { font-size: 9px; margin-top: 5px; max-width: 86px; }
  .seat .team-label { font-size: 7px; padding: 2px 3px; }
  .seat-count { font-size: 8px; gap: 2px; }
  .seat-count .icon { width: 10px; height: 10px; }
  .seat-details { gap: 3px; }
  .seat-state { font-size: 7px; margin-top: 3px; }
  .seat-bubble { font-size: 8px; padding: 2px 6px; top: -17px; }
  .seat[data-slot="0"] { left: 50%; top: 85%; }
  .seat[data-slot="1"] { left: 15%; top: 67%; }
  .seat[data-slot="2"] { left: 16%; top: 28%; }
  .seat[data-slot="3"] { left: 50%; top: 16%; }
  .seat[data-slot="4"] { left: 84%; top: 28%; }
  .seat[data-slot="5"] { left: 85%; top: 67%; }
  .table-stage[data-size="4"] .seat[data-slot="1"] { left: 15%; top: 49%; }
  .table-stage[data-size="4"] .seat[data-slot="2"] { left: 50%; top: 16%; }
  .table-stage[data-size="4"] .seat[data-slot="3"] { left: 85%; top: 49%; }
  .table-stage[data-size="5"] .seat[data-slot="1"] { left: 15%; top: 63%; }
  .table-stage[data-size="5"] .seat[data-slot="2"] { left: 27%; top: 18%; }
  .table-stage[data-size="5"] .seat[data-slot="3"] { left: 73%; top: 18%; }
  .table-stage[data-size="5"] .seat[data-slot="4"] { left: 85%; top: 63%; }
  .trick-caption { font-size: 9px; margin-bottom: 6px; }
  .table-cards { min-height: 66px; }
  .table-cards .playing-card { width: 43px; height: 63px; margin-left: -23px; border-radius: 4px; }
  .table-cards[data-many="true"] .playing-card { margin-left: -30px; }
  .table-cards[data-huge="true"] .playing-card { margin-left: -35px; }
  .table-cards .playing-card:first-child, .table-cards[data-many="true"] .playing-card:first-child, .table-cards[data-huge="true"] .playing-card:first-child { margin-left: 0; }
  .table-cards .card-corner { font-size: 12px; top: 3px; left: 3px; }
  .table-cards .card-corner small { font-size: 10px; }
  .table-cards .card-corner.bottom { right: 3px; bottom: 3px; top: auto; left: auto; }
  .table-cards .card-face-frame { inset: 13px 12px; }
  .table-cards .card-face { font-size: 20px; }
  .table-cards .card-face-suit { font-size: 13px; }
  .table-cards .card-pips { inset: 12px 13px; }
  .table-cards .pip { font-size: 11px; }
  .table-cards .card-center-symbol { font-size: 23px; }
  .table-cards .joker-star { font-size: 23px; }
  .table-cards .joker-word { font-size: 6px; top: 11px; }
  .table-cards .joker-caption { font-size: 6px; bottom: 9px; }
  .combo-label { font-size: 9px; }
  .turn-status { font-size: 9px; margin-top: 5px; }
  .turn-clock { font-size: 7px; margin-top: 6px; }
  .turn-clock strong { font-size: 16px; }
  .turn-clock .icon { width: 10px; height: 10px; }
  .hand-panel { padding: 14px 11px 12px; margin-top: 11px; }
  .hand-heading strong { font-size: 11px; }
  .hand-heading > div { gap: 7px; }
  #hand-count { font-size: 9px; }
  .hand-heading .text-button { font-size: 10px; }
  .hand-scroll { padding: 26px 3px 12px; }
  .hand-cards { min-height: 93px; }
  .hand-cards .playing-card { width: 63px; height: 92px; }
  .hand-cards button.playing-card { margin-left: -30px; }
  .hand-cards button.playing-card:first-child { margin-left: 0; }
  .hand-cards .card-corner { font-size: 18px; }
  .hand-cards .card-corner small { font-size: 14px; }
  .hand-cards .card-face { font-size: 30px; }
  .hand-cards .card-face-suit { font-size: 18px; }
  .hand-cards .pip { font-size: 16px; }
  .hand-tip { font-size: 9px; padding-block: 7px 9px; gap: 5px; }
  .scroll-tip { font-size: 8px; }
  .play-controls { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; padding-top: 12px; }
  .play-controls .button { min-height: 39px; padding: 10px 5px; font-size: 10px; gap: 4px; }
  .play-controls .button .icon { width: 13px; height: 13px; }
  #play-button { grid-column: 1 / -1; min-height: 43px; width: 100%; }
  #play-count { margin-inline: 3px; }
  .action-note { font-size: 8px; margin-top: 9px; }
  .activity-panel { height: 306px; }
  .activity-tabs { padding-inline: 17px; }
  .activity-tabs button { justify-content: flex-start; font-size: 11px; padding-block: 13px; }
  .chat-list, .logs-list { padding-inline: 17px; }
  .chat-text { font-size: 11px; }
  .chat-form { padding-inline: 15px; }
  .chat-form input { font-size: 11px; }
  .chat-form .icon-button { width: 36px; }
  .finished-controls { margin-top: 12px; gap: 8px; }
  .finished-controls .button { font-size: 10px; min-height: 39px; padding: 10px 14px; }
  .finished-controls > span { width: 100%; text-align: center; font-size: 10px; }
  .rules-view .page-heading { align-items: flex-start; }
  .rules-view .page-heading .button { padding: 8px; min-height: 32px; font-size: 9px; margin-top: 25px; }
  .rules-view h1 { font-size: 23px; }
  .rules-overview { gap: 8px; margin-bottom: 16px; }
  .rules-overview > div { padding: 13px 10px; }
  .rules-overview span { font-size: 8px; letter-spacing: 0; }
  .rules-overview strong { font-size: 15px; margin: 9px 0 6px; }
  .rules-overview small { font-size: 8px; }
  .rule-card { padding: 20px 18px; border-radius: 10px; }
  .rule-card h2 { font-size: 18px; }
  .rank-chain { gap: 6px 4px; }
  .rank-chain span { font-size: 10px; padding: 7px 8px; }
  .rank-chain b { font-size: 16px; }
  .rules-two-column { grid-template-columns: 1fr; gap: 16px; margin-top: 16px; }
  .rule-stack { gap: 16px; }
  .rule-card p, .rule-definitions dd, .rule-list li { font-size: 11px; }
  dialog.modal { padding: 25px 24px; border-radius: 13px; max-height: calc(100dvh - 32px); }
  .modal h2 { font-size: 23px; }
  .modal-brand { margin-bottom: 25px; }
  input, select { font-size: 16px; }
  input::placeholder { font-size: 12px; }
  .chat-form input, .waiting-chat-form input { font-size: 16px; }
  .chat-form input::placeholder, .waiting-chat-form input::placeholder { font-size: 11px; }
  .form-grid { gap: 11px; }
  .modal label:not(.toggle-field) { font-size: 11px; }
  .code-input { font-size: 28px; }
  .result-actions .button { padding-inline: 13px; font-size: 10px; }
  .toast-region { bottom: max(18px, env(safe-area-inset-bottom)); left: 50%; }
  .toast { font-size: 11px; padding: 11px 14px; }
}
@media (max-width: 380px) {
  .sidebar { padding-inline: 12px; }
  .nav-item { padding: 9px 7px; }
  .nav-item span { font-size: 9px; }
  .view { padding-inline: 13px; }
  .room-view { padding-inline: 9px; }
  .hero-copy { padding-left: 22px; }
  .hero h2 { font-size: 33px; }
  .hero-art { right: -42px; width: 185px; opacity: .85; }
  .hero-copy > p { max-width: 145px; font-size: 9px; }
  .hero-actions { left: 22px; right: 22px; }
  .hero-footnote { left: 22px; gap: 7px; }
  .mode-card { padding-left: 94px; }
  .mode-top { left: 16px; }
  .mode-card > strong { font-size: 15px; }
  .mode-symbols { gap: 1px; right: 12px; }
  .mode-symbols i { width: 17px; height: 23px; }
  .practice-card { padding: 17px 14px; }
  .practice-card .eyebrow { font-size: 7px; }
  .practice-card h3 { font-size: 13px; }
  .practice-card .button { margin-left: 0; }
  .room-heading h1 { font-size: 18px; }
  #room-code { font-size: 17px; }
  .room-heading-actions #invite-button span { display: none; }
  .room-heading-actions #invite-button { padding: 8px 10px; }
  .seat { width: 80px; }
  .seat-name { max-width: 77px; font-size: 8px; }
  .seat .avatar { width: 37px; height: 37px; font-size: 14px; }
  .seat-details { gap: 2px; }
  .seat .team-label { font-size: 7px; padding-inline: 2px; }
  .seat-score { font-size: 7px; }
  .turn-clock #countdown-note { max-width: 96px; }
  .table-center { inset-inline: 19%; }
  .table-cards .playing-card { width: 39px; height: 58px; }
  .table-cards[data-many="true"] .playing-card { margin-left: -28px; }
  .table-cards[data-huge="true"] .playing-card { margin-left: -33px; }
  .table-cards .playing-card:first-child { margin-left: 0; }
  .table-cards .card-corner { font-size: 11px; }
  .table-cards .card-corner small { font-size: 9px; }
  .table-cards .pip { font-size: 10px; }
  .rules-overview strong { font-size: 13px; }
  .rules-view h1 { font-size: 20px; }
  .rules-view .page-heading { gap: 7px; }
  .score-table td, .score-table th { padding-inline: 9px; }
}
/* Unified card-club UI: typography, action hierarchy and readable game state. */
body { background: radial-gradient(ellipse at 85% 0, #203a2a 0, transparent 55%), var(--bg); }
h1, h2, h3 { text-wrap: balance; }
.sidebar { background: #101f18; }
.topbar { background: rgba(13, 23, 19, .85); }
.view { max-width: 1500px; padding-bottom: 32px; }
.eyebrow { color: var(--gold-muted); font-size: 10px; letter-spacing: 1.8px; }
.nav-caption, .sidebar-foot, .page-footer, .fairplay-note small { color: #9eaf9c; }
.nav-caption { font-size: 10px; }
.sidebar-foot, .page-footer { font-size: 11px; }
.brand-wordmark small { color: #bbaa85; font-size: 8px; }
.nav-item { min-height: 48px; font-weight: 600; transition: background .18s, border-color .18s, color .18s; }
.breadcrumb { font-size: 13px; color: var(--muted); }
.breadcrumb strong { color: var(--text); }
.connection-status { border: 1px solid var(--line); border-radius: 999px; padding: 8px 12px; min-height: 38px; font-size: 12px; }
.connection-status[data-state="online"] { color: #b7e6c9; background: #21423255; border-color: #5fa37c38; }
.connection-status[data-state="offline"], .connection-status[data-state="error"] { color: #ffcdc3; background: #60392d44; border-color: #e4987944; }
.identity-button { min-height: 44px; border-radius: 9px; padding: 4px 8px; font-size: 13px; }
.identity-button:hover { background: #ffffff08; }
.page-heading p { font-size: 14px; }
.edition-tag { color: #d0c59f; background: #25332980; font-size: 11px; border-radius: 999px; }
.button { min-height: 46px; border-radius: 10px; font-size: 14px; padding: 12px 20px; line-height: 1.4; letter-spacing: .15px; }
.button-small { min-height: 40px; font-size: 12px; padding: 10px 14px; }
.button-gold { color: #283021; background: linear-gradient(110deg, #f0d39b, #d6b16a); box-shadow: inset 0 1px 0 #fff5, 0 4px 16px #0a10093d; }
.button-outline, .button-glass { background: #22382a77; border-color: var(--line-strong); color: #e5eadd; }
.button-outline:hover:not(:disabled), .button-glass:hover:not(:disabled) { background: #304b37; border-color: #c9b587; }
.button-muted { color: #c0cabb; background: #ffffff05; }
button:disabled { opacity: .62; }
.button:disabled { background: #1c2c22; color: #8a9c8b; border-color: #82978025; box-shadow: none; }
button:active:not(:disabled), .mode-card:active { transform: translateY(1px); }
:focus-visible { outline: 3px solid var(--gold-light); outline-offset: 3px; }
.icon-button { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 9px; background: #ffffff03; }
.text-button { min-height: 40px; padding: 8px 10px; border-radius: 8px; font-size: 12px; }
.text-button:hover:not(:disabled) { background: #d9b7780d; }
.hero { background: radial-gradient(ellipse at 78% 20%, #3e694b, transparent 62%), linear-gradient(110deg, #204933, #173423); border-color: #b4bf8e38; box-shadow: var(--shadow-panel); }
.hero-copy { padding: 34px 40px; }
.hero-kicker { font-size: 12px; color: #d0dfc6; }
.hero-copy > p { font-size: 14px; color: #ccdbc8; line-height: 1.9; }
.hero h2 { font-family: "Songti SC", "SimSun", Georgia, serif; font-weight: 700; letter-spacing: 2px; }
.hero-footnote { font-size: 11px; color: #c2ceac; gap: 14px; }
.hero-actions { gap: 12px; }
.hero-actions .button { min-width: 145px; }
.section-heading { margin-top: 32px; margin-bottom: 18px; }
.section-heading h2 { font-size: 23px; }
.mode-grid { gap: 18px; }
.mode-card { border-radius: 15px; padding: 24px 24px 0; background: linear-gradient(130deg, #22382a, #18271e); box-shadow: 0 6px 16px #00000014; }
.mode-card:hover { border-color: #d9b77888; transform: translateY(-3px); }
.mode-card > strong { font-size: 18px; font-weight: 650; }
.mode-description { color: #b7c7b0; font-size: 12px; line-height: 1.9; min-height: 46px; margin-bottom: 22px; }
.mode-badge { color: #c7d3b9; font-size: 11px; background: #ffffff04; }
.mode-number { color: #eddbac; font-size: 44px; }
.mode-number small { color: #b0bd9e; font-size: 9px; }
.mode-bottom { font-size: 12px; padding-block: 16px; color: #e3cf9e; background: #d9b77806; margin-top: auto; }
.mode-symbols { margin-block: 16px; }
.practice-card, .rules-teaser, .waiting-activity, .activity-panel, .hand-panel { background: linear-gradient(120deg, #1e3326, #17271e); border-color: var(--line); box-shadow: var(--shadow-panel); }
.practice-card h3 { font-size: 16px; font-weight: 650; }
.practice-card p, .rules-teaser small { font-size: 12px; }
.practice-card .button { min-height: 44px; font-size: 13px; }
.rules-teaser strong { font-size: 14px; }
.resume-room strong { font-size: 14px; }
.resume-room #resume-detail { font-size: 12px; }
.room-heading { margin-bottom: 20px; }
.room-heading h1 { font-size: clamp(22px, 2.2vw, 30px); }
#room-code { font: 650 25px var(--font-ui); letter-spacing: 2px; font-variant-numeric: tabular-nums; color: #f2d698; }
.room-heading p { font-size: 12px; max-width: 760px; color: #b6c6b0; }
.room-heading-actions #leave-button { color: #d6bf9c; }
.waiting-panel { background: radial-gradient(ellipse at 50% 0, #345e3c55, transparent 75%), #192d20; }
.waiting-intro h2 { font-size: 26px; font-weight: 650; }
.waiting-intro p, .waiting-help { font-size: 13px; color: #b5c5af; }
.invite-code { border-radius: 10px; padding: 8px 10px 8px 18px; border-color: #dcc08470; }
.invite-code > span { font-size: 12px; }
.invite-code strong { font-size: 28px; font-variant-numeric: tabular-nums; }
.waiting-player { border-radius: 12px; background: #24432b30; }
.waiting-player-name { font-size: 14px; font-weight: 600; }
.waiting-player-meta, .waiting-player-state { font-size: 11px; }
.waiting-player-state.ready { padding: 3px 8px; background: #4c885138; border-radius: 999px; }
.waiting-player-state.disconnected { color: #e8c497; }
.waiting-controls { padding-top: 4px; gap: 12px; }
.waiting-activity h3 { font-size: 14px; }
.voice-panel { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 18px; row-gap: 9px; padding: 15px 18px; background: #1b2f23; border-color: #8fbb8240; box-shadow: none; }
.voice-heading { min-width: 0; }
.voice-heading strong { font-size: 15px; color: #e1e8d3; }
.voice-heading p { font-size: 12px; color: #b8c8ae; }
.voice-count { font-size: 11px; color: #c4d3b7; }
.voice-controls { margin: 0; align-self: center; justify-content: flex-end; max-width: 530px; }
.voice-controls .button { min-height: 40px; font-size: 12px; padding: 10px 12px; }
.voice-members { grid-column: 1 / -1; margin-top: 0; }
.voice-members:empty { display: none; }
.voice-member { font-size: 12px; border-radius: 999px; padding: 5px 10px; }
.voice-controls [aria-pressed="true"] { color: #f9d0a2; background: #69442c5c; border-color: #cda16b; }
#voice-leave { color: #e7bdb0; border-color: #d5967638; }
.voice-privacy-details { grid-column: 1 / -1; color: #b0c2a5; font-size: 11px; }
.voice-privacy-details summary { cursor: pointer; width: fit-content; padding: 4px 0; min-height: 25px; }
.voice-privacy { font-size: 11px; margin-top: 5px; }
.game-layout { gap: 20px; grid-template-columns: minmax(0, 1fr) 248px; align-items: start; }
.table-toolbar { min-height: 40px; margin-bottom: 8px; }
.team-label { padding: 5px 8px; font-size: 12px; border-radius: 6px; }
.team-jade { color: #b2f0c8; background: #366b4740; border-color: #7aba8844; }
.team-amber { color: #f7d7a2; background: #84613b33; border-color: #dab77d44; }
.round-label { font-size: 12px; color: #c0c7a6; }
.turn-banner { display: flex; align-items: center; justify-content: space-between; min-height: 58px; gap: 14px; padding: 11px 16px; margin-bottom: 10px; border: 1px solid var(--line); border-radius: 12px; background: #18291e; }
.turn-status { text-align: left; margin: 0; font-size: 14px; line-height: 1.7; color: #cbdac2; font-weight: 600; }
.turn-clock { margin: 0; gap: 7px; color: #bcccae; font-size: 11px; flex-shrink: 0; }
.turn-clock strong { color: var(--gold-light); font-size: 23px; font-weight: 700; min-width: 27px; text-align: right; }
.turn-clock .icon { width: 15px; height: 15px; }
.turn-clock.urgent { border-radius: 8px; padding: 4px 8px; background: #6f3d2533; }
.turn-banner[data-turn="self"] { border-color: #d9b77888; background: linear-gradient(110deg, #3c452955, #223822); box-shadow: inset 3px 0 0 #d9b778; }
.turn-banner[data-turn="self"] .turn-status { color: #ffe4af; }
.turn-banner[data-turn="finished"] { border-color: #83c79a66; }
.table-stage { height: clamp(420px, 31vw, 500px); border-color: #859f7944; background: radial-gradient(ellipse, #234331, #101f18 80%); }
.table-center { inset: 30% 23%; gap: 5px; }
.trick-caption { font-size: 12px; color: #e2e7cf; margin-bottom: 8px; }
.combo-label { font-size: 13px; color: #f1dca5; font-weight: 600; }
.combo-label:not(:empty) { padding: 5px 10px; border-radius: 999px; background: #15281966; }
.seat { width: 112px; }
.seat[data-slot="0"] { top: 82%; }
.seat[data-slot="3"], .table-stage[data-size="4"] .seat[data-slot="2"] { top: 18%; }
.table-stage[data-size="5"] .seat[data-slot="2"], .table-stage[data-size="5"] .seat[data-slot="3"] { top: 18%; }
.seat-name { font-size: 12px; line-height: 1.5; font-weight: 600; max-width: 108px; }
.seat .team-label { font-size: 9px; padding: 3px 5px; }
.seat-count { padding: 2px 4px; font-size: 13px; font-weight: 700; color: #f5eccd; }
.seat-state { font-size: 10px; min-height: 14px; color: #cdd7b8; }
.seat-score { font-size: 10px; color: #adbd9d; }
.seat.is-turn .seat-state { color: #f5daa2; }
.seat.is-turn .avatar { box-shadow: 0 0 0 3px #d9b77855, 0 0 0 5px #edcc8a4d, 0 0 24px #d9b77838; }
.seat-bubble { font-size: 11px; padding: 3px 8px; background: #223f29; }
.hand-panel { padding: 18px 20px 14px; }
.hand-heading strong { font-size: 16px; font-weight: 650; }
#hand-count { font-size: 13px; color: #c0cfb4; }
.hand-heading .team-label { font-size: 11px; }
.hand-scroll { padding: 29px 4px 16px; }
.hand-cards { min-height: 112px; }
.hand-cards .playing-card { width: 76px; height: 110px; border-radius: 8px; }
.hand-cards button.playing-card { margin-left: -34px; }
.hand-cards button.playing-card:first-child { margin-left: 0; }
.hand-cards .card-corner { font-size: 23px; }
.hand-cards .card-corner small { font-size: 17px; }
button.playing-card.selected { border-color: #f2d18a; box-shadow: -2px 3px 8px #0005, 0 0 0 3px #e1bc76, 0 8px 20px #0004; }
button.playing-card.selected::after { content: ""; position: absolute; left: 5px; top: -12px; width: 6px; height: 6px; border-radius: 50%; background: #f4dba5; }
.hand-tip { font-size: 12px; color: #bccaac; }
.scroll-tip { font-size: 11px; color: #a3b497; }
#selection-label { font-weight: 500; }
.hand-panel:has([data-selected]:not([data-selected="0"])) #selection-label { color: #f4dba5; }
.play-controls { justify-content: flex-end; flex-wrap: wrap; gap: 9px; padding-top: 15px; }
.play-controls .button { min-height: 46px; font-size: 13px; padding: 11px 17px; }
#clear-button { margin-right: auto; }
#play-button { min-width: 134px; }
#play-count { min-width: 24px; height: 24px; font-size: 13px; border-radius: 6px; }
.action-note { font-size: 12px; color: #b5c2a9; margin-top: 12px; text-align: left; padding: 8px 11px; border-radius: 8px; background: #ffffff03; }
.hand-panel[data-busy="true"] .action-note { color: #f5d99b; }
.hand-panel[data-busy="true"] #play-button::after { content: ""; width: 13px; height: 13px; border: 2px solid #829780; border-top-color: #f4dba5; border-radius: 50%; animation: ui-spin .7s linear infinite; }
.activity-panel { position: sticky; top: 16px; max-height: 720px; }
.activity-tabs button { min-height: 46px; font-size: 12px; color: #becbac; }
.activity-tabs button.active { color: #f4dba5; }
.chat-list, .logs-list { height: 440px; flex: auto; }
.chat-meta { font-size: 12px; color: #c9d6bc; }
.chat-meta time, .log-item time { font-size: 10px; color: #a2b694; }
.chat-text { color: #e1e8d5; font-size: 13px; background: #2a4a3259; }
.empty-activity { font-size: 12px; color: #adbd9e; }
.log-item p { font-size: 12px; color: #cfdbc2; }
.chat-form input { font-size: 13px; }
.chat-form .icon-button { width: 40px; height: 42px; }
#chat-counter, .activity-footer { font-size: 10px; color: #a1b694; }
.rule-card { background: #192e21; padding: 28px; }
.rule-card h2 { font-size: 22px; font-weight: 650; }
.rule-card p, .rule-definitions dd, .rule-list li { font-size: 14px; line-height: 1.95; color: #bdcfb6; }
.rule-definitions dt { font-size: 15px; }
.rule-card .rule-callout { font-size: 13px; }
.rule-card code, .rank-order strong { font-size: 12px; }
.rules-overview small { font-size: 12px; }
.rules-overview span { font-size: 11px; }
.rank-chain span { font-size: 13px; padding: 9px 12px; }
.settlement-example span, .settlement-example small { font-size: 12px; color: #afc79f; }
dialog.modal { width: min(510px, calc(100% - 32px)); border-color: #cbb78466; background: radial-gradient(ellipse at top left, #355a3f55, transparent 70%), #192d21; padding: 28px 30px; }
.modal h2 { font-size: 27px; font-weight: 650; }
.modal > p { font-size: 14px; line-height: 1.8; margin-bottom: 22px; }
.modal label:not(.toggle-field), .modal legend { font-size: 13px; color: #e0e7cd; }
.modal label small, .modal .toggle-field small, .field-hint { font-size: 12px; color: #b4c4a8; }
input, select { min-height: 48px; padding: 12px 14px; font-size: 15px; border-radius: 9px; border-color: #a4bc8e55; background: #102319; }
input::placeholder { color: #a3b79a; font-size: 13px; }
input:focus, select:focus { border-color: #f0d29a; box-shadow: 0 0 0 3px #d9b77820; }
.size-options label > span { border-radius: 10px; }
.modal .size-options small { font-size: 12px; color: #b2c3a2; }
.toggle-field strong { font-size: 14px; }
.form-error { font-size: 13px; color: #ffd1c3; background: #8e4b3333; border: 1px solid #d5987b44; }
.modal-footnote { font-size: 11px; color: #aec09e; }
.score-table { font-size: 14px; }
.score-table th { font-size: 12px; color: #b8cba6; }
.score-table .player-score-name { font-size: 14px; }
.score-table .team-label { font-size: 10px; }
.result-status, .modal .result-unit { font-size: 12px; color: #bdcea9; }
.result-actions .button { font-size: 13px; min-height: 46px; }
.toast { font-size: 13px; border-radius: 12px; border-color: #d9b77866; }
#ready-button[aria-pressed="true"], #next-ready-button[aria-pressed="true"], #result-ready-button[aria-pressed="true"] { color: #cef2d6; background: #2e5b3c; border-color: #81c79877; }
@keyframes ui-spin { to { transform: rotate(360deg); } }
@media (max-width: 1250px) {
  .game-layout { grid-template-columns: minmax(0, 1fr); }
  .activity-panel { position: static; height: 310px; }
  .activity-content { overflow: hidden; }
  .chat-list, .logs-list { height: auto; max-height: 200px; flex: 1; }
  .hero-copy { padding-inline: 30px; }
  .mode-card { padding-inline: 18px; }
  .mode-bottom { width: calc(100% + 36px); margin-left: -18px; padding-inline: 18px; }
  .mode-card > strong { font-size: 16px; }
  .mode-badge { font-size: 10px; }
  .voice-panel { grid-template-columns: minmax(0, 1fr); }
  .voice-controls { justify-content: flex-start; max-width: none; }
}
@media (max-width: 820px) and (min-width: 641px) {
  .nav-item { min-height: 48px; }
  .hero-actions .button { min-width: 0; }
  .mode-grid { gap: 10px; }
  .mode-card { padding-inline: 14px; }
  .mode-bottom { width: calc(100% + 28px); margin-left: -14px; padding-inline: 14px; }
  .mode-top { flex-wrap: wrap; }
  .lobby-bottom-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .sidebar { position: sticky; inset: auto; top: 0; height: 60px; padding-inline: 12px; }
  .main-shell { padding-top: 0; }
  .nav-item { min-height: 42px; padding: 9px 8px; }
  .nav-item span { font-size: 11px; }
  .topbar { min-height: 54px; height: auto; padding: 7px 12px; }
  .breadcrumb { font-size: 11px; }
  .topbar-right { gap: 5px; }
  .connection-status { font-size: 10px; min-height: 34px; padding: 6px 8px; }
  .identity-button { min-height: 38px; font-size: 11px; padding: 3px; }
  #identity-name { max-width: 70px; }
  .topbar-divider { display: none; }
  .view { padding: 22px 14px 24px; }
  .page-heading p { font-size: 13px; }
  .eyebrow { font-size: 9px; }
  .hero { min-height: 450px; }
  .hero-copy { padding: 27px 23px 110px; }
  .hero-kicker { font-size: 11px; }
  .hero h2 { font-size: 37px; }
  .hero-copy > p { font-size: 12px; max-width: 174px; }
  .hero-art { top: 136px; right: -20px; transform: scale(.78); transform-origin: top right; }
  .hero-actions { bottom: 56px; left: 23px; right: 23px; }
  .hero-actions .button { min-width: 0; min-height: 46px; font-size: 13px; padding: 10px; }
  .hero-footnote { left: 23px; bottom: 26px; font-size: 10px; gap: 10px; }
  .section-heading { margin-top: 25px; gap: 8px; }
  .section-heading h2 { font-size: 21px; }
  .section-heading .text-button { font-size: 12px; }
  .mode-grid { gap: 12px; }
  .mode-card { padding: 20px 16px 18px 94px; min-height: 170px; }
  .mode-top { left: 16px; top: 22px; }
  .mode-number { font-size: 40px; }
  .mode-number small { font-size: 8px; }
  .mode-badge { font-size: 9px; padding: 4px; }
  .mode-card > strong { font-size: 16px; }
  .mode-description { font-size: 12px; margin: 9px 0 10px; min-height: 46px; }
  .mode-bottom { width: auto; margin: 0; padding: 0; background: none; font-size: 12px; }
  .mode-symbols { display: none; }
  .practice-card { display: grid; grid-template-columns: 45px minmax(0, 1fr); padding: 18px; gap: 12px; }
  .practice-icon { width: 45px; height: 45px; }
  .practice-card .button { grid-column: 1 / -1; width: 100%; margin: 0; font-size: 13px; }
  .practice-card h3 { font-size: 15px; }
  .practice-card p { font-size: 12px; }
  .rules-teaser { padding: 18px; }
  .page-footer { font-size: 10px; }
  .resume-room { flex-wrap: wrap; }
  .resume-room strong { font-size: 12px; }
  .resume-room #resume-detail { font-size: 11px; }
  .resume-room .button { min-height: 42px; font-size: 12px; margin-left: auto; }
  .room-view { padding: 18px 10px 24px; }
  .room-heading { flex-wrap: wrap; gap: 10px; }
  .room-heading > div:first-child { flex: 1 1 100%; }
  .room-heading h1 { font-size: 24px; }
  #room-code { font-size: 24px; margin-left: 6px; }
  .room-heading p { font-size: 12px; line-height: 1.8; }
  .room-heading-actions { padding: 0; margin-left: auto; gap: 8px; }
  .room-heading-actions .button { min-height: 42px; font-size: 12px; padding: 10px 14px; }
  .room-heading-actions .icon-button { width: 42px; height: 42px; }
  .room-heading-actions #invite-button span { display: inline; }
  .voice-panel { padding: 13px; gap: 9px; border-radius: 12px; }
  .voice-heading { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 8px; }
  .voice-heading p { font-size: 12px; }
  .voice-count { grid-column: 2; width: auto; margin: 0; white-space: normal; font-size: 11px; }
  .voice-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .voice-controls .button { min-height: 44px; font-size: 12px; padding: 10px 8px; }
  .voice-member { font-size: 11px; }
  .voice-privacy-details summary { min-height: 36px; padding: 8px 0; }
  .waiting-panel { padding: 24px 14px; }
  .waiting-intro h2 { font-size: 22px; }
  .waiting-intro p, .waiting-help { font-size: 12px; }
  .waiting-player-name { font-size: 13px; }
  .waiting-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .waiting-controls .button { min-height: 46px; font-size: 12px; padding-inline: 9px; }
  #start-button { grid-column: 1 / -1; }
  .table-toolbar { flex-wrap: wrap; gap: 8px; min-height: 38px; }
  .team-label { font-size: 11px; padding: 5px 7px; }
  .round-label { font-size: 11px; }
  .turn-banner { padding: 10px 12px; min-height: 65px; gap: 8px; }
  .turn-status { font-size: 13px; }
  .turn-clock { font-size: 10px; gap: 4px; }
  .turn-clock #countdown-note { max-width: 65px; line-height: 1.6; }
  .turn-clock strong { font-size: 23px; }
  .table-stage { height: clamp(425px, 110vw, 480px); }
  .table-center { inset: 37% 19% 30%; }
  .trick-caption { font-size: 11px; }
  .combo-label { font-size: 12px; line-height: 1.6; }
  .seat { width: 90px; }
  .seat[data-slot="0"] { top: 84%; }
  .seat[data-slot="3"], .table-stage[data-size="4"] .seat[data-slot="2"] { top: 16%; }
  .table-stage[data-size="5"] .seat[data-slot="2"], .table-stage[data-size="5"] .seat[data-slot="3"] { top: 18%; }
  .seat-name { font-size: 11px; max-width: 88px; }
  .seat .avatar { width: 40px; height: 40px; }
  .seat .team-label { font-size: 8px; padding: 2px 3px; }
  .seat-count { font-size: 12px; padding: 1px; }
  .seat-details { gap: 2px; }
  .seat-state, .seat-score { font-size: 9px; }
  .seat-bubble { font-size: 10px; }
  .hand-panel { padding: 15px 12px 12px; }
  .hand-heading { gap: 6px; }
  .hand-heading > div { gap: 6px; flex-wrap: wrap; }
  .hand-heading strong { font-size: 14px; }
  #hand-count { font-size: 12px; }
  .hand-heading .team-label { font-size: 10px; }
  .hand-heading .text-button { font-size: 12px; flex-shrink: 0; }
  .hand-cards .playing-card { width: 72px; height: 104px; }
  .hand-cards { min-height: 107px; }
  .hand-cards button.playing-card { margin-left: -28px; }
  .hand-cards button.playing-card:first-child { margin-left: 0; }
  .hand-cards .card-corner { font-size: 22px; }
  .hand-cards .card-corner small { font-size: 16px; }
  .hand-tip { font-size: 12px; flex-wrap: wrap; }
  .scroll-tip { font-size: 10px; }
  .play-controls { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
  .play-controls .button { min-height: 44px; padding: 10px 3px; font-size: 12px; gap: 3px; }
  #clear-button { margin: 0; }
  #play-button { grid-column: 1 / -1; min-width: 0; min-height: 49px; font-size: 15px; }
  .action-note { font-size: 11px; line-height: 1.8; }
  .activity-panel { height: 315px; }
  .activity-tabs button { font-size: 13px; }
  .chat-form input, .waiting-chat-form input, input, select { font-size: 16px; }
  .chat-form input::placeholder, .waiting-chat-form input::placeholder { font-size: 12px; }
  .chat-list, .logs-list { max-height: 195px; }
  .chat-text { font-size: 13px; }
  .rules-view .page-heading { flex-wrap: wrap; }
  .rules-view .page-heading .button { font-size: 12px; min-height: 42px; margin-top: 0; padding: 10px 12px; }
  .rules-view h1 { font-size: 25px; }
  .rules-overview { grid-template-columns: 1fr; gap: 9px; }
  .rules-overview > div { padding: 16px; }
  .rules-overview strong { font-size: 21px; }
  .rules-overview small { font-size: 12px; }
  .rule-card { padding: 22px 17px; }
  .rule-card h2 { font-size: 20px; }
  .rule-card p, .rule-definitions dd, .rule-list li { font-size: 13px; }
  .rank-chain span { font-size: 12px; }
  dialog.modal { padding: 24px 20px; max-height: calc(100dvh - 24px); border-radius: 16px; }
  .modal h2 { font-size: 25px; }
  .modal > p { font-size: 13px; }
  .modal label:not(.toggle-field), .modal legend { font-size: 13px; }
  .result-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .result-actions .button { padding: 10px 8px; font-size: 12px; }
  #result-start-button { grid-column: 1 / -1; }
  .score-table .player-score-name { font-size: 13px; }
  .score-table td, .score-table th { padding-inline: 10px; }
  .toast-region { bottom: max(14px, env(safe-area-inset-bottom)); }
}
@media (max-width: 380px) {
  .nav-item span { font-size: 10px; }
  .brand-wordmark { font-size: 15px; }
  .breadcrumb .icon { display: none; }
  .hero-copy > p { max-width: 153px; font-size: 12px; }
  .hero h2 { font-size: 34px; }
  .hero-art { right: -39px; }
  .hero-footnote { gap: 7px; font-size: 9px; }
  .mode-card { padding-left: 88px; padding-right: 13px; }
  .mode-card > strong { font-size: 15px; }
  .room-heading h1, #room-code { font-size: 22px; }
  .room-view { padding-inline: 9px; }
  .seat { width: 82px; }
  .seat-name { max-width: 80px; font-size: 10px; }
  .seat-score { font-size: 9px; }
  .turn-status { font-size: 12px; }
  .turn-banner { padding-inline: 10px; }
  .turn-clock .icon { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
