@import url('/fonts.css');
:root{color-scheme:dark;--ink:#fff3d9;--muted:#b6c9c0;--gold:#efc46a;--gold-dark:#9c692d;--panel:#09282a;--line:#d9bb7640;--danger:#ffc5b8;font:16px/1.5 system-ui,sans-serif;background:#071c20;color:var(--ink)}
*{box-sizing:border-box}body{margin:0;min-width:320px}button,input,select{font:inherit}button,a,input,select{touch-action:manipulation}button{cursor:pointer;border:1px solid var(--line);border-radius:12px;padding:11px 18px;min-height:46px;color:var(--ink);background:#123b3b;font-weight:650}button:hover{background:#205150;border-color:var(--gold)}button:disabled{cursor:default;opacity:.5}button.primary{color:#30220d;background:linear-gradient(#ffe09b,#e8b65d);border-color:#f8d789;box-shadow:0 3px 0 #865d2f}button.quiet{background:transparent}button.danger{color:var(--danger)}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #f7d286;outline-offset:4px}input,select{width:100%;padding:12px;border:1px solid #66847a;border-radius:10px;background:#092223;color:var(--ink);min-height:48px}input[type=checkbox]{width:22px;min-height:22px}input[type=file]{font-size:.85rem}label{display:grid;gap:6px;color:var(--muted);font-size:.9rem}h1,h2,h3{font-family:Georgia,serif;line-height:1.15;font-weight:500}h1{font-size:clamp(2.4rem,5vw,4.6rem);margin:0 0 16px}h2{font-size:1.9rem;margin:0 0 20px}h3{font-size:1.5rem;margin:0 0 12px}p{margin:0 0 18px}a{color:var(--gold)}.muted{color:var(--muted)}.eyebrow{font-size:.76rem;font-weight:750;letter-spacing:.18em;text-transform:uppercase;color:var(--gold);margin-bottom:12px}.row{display:flex;align-items:center;gap:12px}.spread{justify-content:space-between}.wrap{flex-wrap:wrap}.stack{display:grid;gap:16px}.small{font-size:.85rem}.grow{flex:1}.pill{font-size:.8rem;background:#163d3b;border:1px solid var(--line);border-radius:99px;padding:6px 12px}.brand{display:flex;gap:12px;align-items:center;font-family:Georgia,serif;font-size:1.8rem}.brand img{width:50px;height:50px;border-radius:12px}.brand small{display:block;font:11px system-ui;letter-spacing:.18em;color:var(--gold);text-transform:uppercase}.topbar{position:relative;z-index:5;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:18px 4vw;border-bottom:1px solid var(--line);background:#071c20ed}.topbar button{padding:9px 14px}.shell{min-height:100dvh;background:linear-gradient(90deg,#061e23f2 8%,#071c20d9 50%,#071c2050),url('/assets/castle-table.webp') center/cover fixed}.content{max-width:1200px;margin:auto;padding:48px 28px}.welcome{max-width:650px;margin-bottom:32px}.welcome h1{font-size:clamp(2.6rem,4vw,4rem)}.welcome p{color:var(--muted)}.home-grid{display:grid;grid-template-columns:1.55fr 1fr;gap:24px;align-items:start}.panel{background:linear-gradient(145deg,#103638f2,#071e22f5);border:1px solid var(--line);border-radius:20px;padding:26px;box-shadow:0 20px 60px #0003}.games{display:grid;grid-template-columns:1fr 1fr;gap:16px}.game-choice{text-align:left;display:flex;flex-direction:column;align-items:flex-start;gap:6px;min-height:200px;padding:24px;background:linear-gradient(145deg,#1e4742,#0c2b2d);border-radius:16px}.game-choice strong{font-family:Georgia,serif;font-size:1.6rem;font-weight:500}.game-choice .game-symbol{font-size:3.2rem;color:var(--gold);line-height:1.1;margin:0 0 12px}.game-choice .muted{font-size:.84rem}.game-choice small{color:var(--gold);margin-top:auto}.join-form{display:flex;gap:8px}.join-form input{min-width:0;text-transform:uppercase;letter-spacing:.1em}.table-list{display:grid;gap:10px}.table-link{text-align:left;display:flex;justify-content:space-between;align-items:center;gap:10px;width:100%;font-weight:400}.table-link strong{display:block;color:var(--ink)}.table-link small{color:var(--muted)}.empty{border:1px dashed var(--line);padding:20px;border-radius:12px;color:var(--muted)}.auth-layout{min-height:100dvh;display:grid;grid-template-columns:1.1fr 1fr;align-items:center;gap:8vw;max-width:1200px;margin:auto;padding:48px 30px}.auth-art .brand img{width:120px;height:120px;border-radius:24px}.auth-art .brand{font-size:3rem;margin-bottom:28px}.auth-art p{max-width:470px;font-size:1.1rem;color:#dae5dc}.auth-panel{max-width:440px;width:100%;justify-self:end}.tabs{display:flex;padding:4px;background:#061a1d;border-radius:12px;margin-bottom:24px}.tabs button{flex:1;border:0;background:transparent}.tabs button.active{color:var(--gold);background:#234443}.avatar{width:48px;height:48px;display:grid;place-items:center;background:radial-gradient(circle at 40% 25%,#376461,#132e31);border:2px solid #c39d55;border-radius:50%;font-size:30px;flex-shrink:0;overflow:hidden}.avatar img{width:100%;height:100%;object-fit:cover}.avatar-picker{display:flex;flex-wrap:wrap;gap:8px}.avatar-picker button{padding:3px;border-radius:50%;border:2px solid transparent}.avatar-picker button.selected{border-color:#ffe6a6;background:#567f65}.seat-list{display:grid;gap:10px}.lobby-seat{display:flex;gap:14px;align-items:center;border-bottom:1px solid var(--line);padding:12px 0}.lobby-seat strong{display:block}.lobby-seat small{color:var(--muted)}.lobby-seat .actions{display:flex;gap:6px}.lobby-layout{display:grid;grid-template-columns:1.2fr 1fr;gap:24px}.code{font-family:monospace;font-size:1.5rem;letter-spacing:.12em;color:var(--gold);overflow-wrap:anywhere}.rule-list{padding-left:20px;color:var(--muted)}.rule-list li{margin-bottom:10px}.loading{display:grid;place-content:center;text-align:center;min-height:100vh}.loading img{width:100px;justify-self:center;margin-bottom:24px;border-radius:20px}.table-screen{height:100dvh;display:flex;flex-direction:column;overflow:hidden;background:#05191a}.table-screen .topbar{padding:8px 22px;min-height:68px}.table-screen .brand{font-size:1.35rem}.table-screen .brand img{width:42px;height:42px}.stage{flex:1;min-height:0;position:relative;isolation:isolate;background:url('/assets/castle-table.webp') center center/100% 100% no-repeat}.stage:before{content:'';position:absolute;inset:0;z-index:-1;background:linear-gradient(#0003,transparent 25%,transparent 65%,#061619d9)}.opponent{position:absolute;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:3px;width:100px;text-align:center}.opponent .avatar{width:58px;height:58px;font-size:36px;box-shadow:0 5px 15px #0009}.opponent.active .avatar{border-color:#fff0a6;box-shadow:0 0 0 3px #c69540,0 0 24px #f3be63}.opponent .name{max-width:115px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:#061f23ef;padding:2px 12px;border:1px solid #ad8f4d;border-radius:6px;font-size:.85rem}.opponent .count{font-size:.78rem;color:#ffe2a1;text-shadow:0 1px 5px black;background:#092827cc;border-radius:5px;padding:1px 6px}.mini-hand{height:24px;display:flex;justify-content:center;padding-left:10px}.card-back{display:block;width:22px;height:29px;border:1px solid #d7b46b;border-radius:3px;background:repeating-linear-gradient(45deg,transparent,transparent 5px,#bd955722 6px,#bd955722 7px),#153966;box-shadow:0 2px 5px #0005;margin-left:-10px}.center-play{position:absolute;left:50%;top:45%;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:12px}.piles{display:flex;gap:20px;align-items:center}.deck{width:72px;height:100px;background:repeating-linear-gradient(45deg,transparent,transparent 12px,#e3b55d33 13px,#e3b55d33 14px),#153966;border:3px solid #ecd6a0;border-radius:9px;display:grid;place-items:center;box-shadow:3px 4px 0 #dbc79f,5px 7px 0 #8e785b,0 12px 20px #0007;color:#f3d17d;font-size:2rem}.deck-label{font-size:.8rem;color:#ffebbd;text-align:center;margin-top:8px;text-shadow:0 2px 5px black}.card{position:relative;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;width:94px;height:134px;padding:8px 10px;color:#192326;background:linear-gradient(120deg,#fffef5,#e7e0ca);border:1px solid #cfc4a5;border-radius:10px;box-shadow:0 5px 12px #0006;font-family:Georgia,serif;line-height:1;flex-shrink:0;font-size:1.5rem;min-height:0}.card.red{color:#b62932}.card:hover{background:#fffdf2}.card:disabled{opacity:.85;color:#455650}.card.red:disabled{color:#9e4b50}.card .suit-large{font-size:2.5rem;align-self:center}.card .rank-bottom{align-self:flex-end;transform:rotate(180deg)}.card.legal{border:2px solid #ffdb74;box-shadow:0 0 10px #f5c55980,0 5px 12px #0005}.card.legal:hover{transform:translateY(-12px)}.discard .card{width:72px;height:100px;font-size:1.1rem;transform:rotate(5deg)}.discard .suit-large{font-size:2rem}.turn-label{background:#082d2bd9;border:1px solid var(--line);padding:5px 15px;border-radius:99px;color:#ffdfa0;text-align:center;font-size:.85rem;max-width:300px}.your-hand{position:absolute;bottom:22px;left:18%;right:18%;display:flex;align-items:end;justify-content:safe center;padding:20px 10px 12px;gap:8px;overflow-x:auto;scrollbar-color:#c49b51 #102d2a;max-height:210px}.local-player{position:absolute;bottom:40px;left:4%;display:flex;flex-direction:column;align-items:center;gap:5px;text-align:center}.local-player .avatar{width:66px;height:66px;font-size:38px}.local-player strong{font-size:.85rem;background:#061f23e6;padding:3px 14px;border-radius:8px}.turn-help{position:absolute;bottom:197px;left:22%;right:22%;text-align:center;font-size:1rem;color:#ffe4a4;text-shadow:0 2px 5px black}.game-action{position:absolute;right:3%;bottom:65px;max-width:15%;display:grid;gap:8px}.game-action button{font-size:1rem;padding:13px 18px}.game-action small{font-size:.75rem;text-align:center;text-shadow:0 2px 5px black}.books{font-size:.8rem;color:#ffe4aa}.event-line{font-size:.78rem;color:#d7e5d9;max-width:380px;text-align:center;text-shadow:0 2px 5px black}.pause-panel{position:absolute;z-index:6;inset:0;display:grid;place-items:center;background:#031514a8;backdrop-filter:blur(5px);padding:22px;overflow:auto}.pause-panel .panel{max-width:500px;text-align:center;width:100%}.pause-panel button{width:100%;margin-top:9px}#toast{position:fixed;z-index:100;left:50%;bottom:24px;transform:translateX(-50%);max-width:min(560px,90vw);padding:13px 20px;background:#172d2b;border:1px solid var(--gold);border-radius:12px;box-shadow:0 10px 40px #0008;display:none}#toast.visible{display:block}dialog{color:var(--ink);background:#0d2c2e;border:1px solid #b18b49;border-radius:20px;padding:28px;width:min(500px,94vw);max-height:90dvh;box-shadow:0 30px 100px #000a}dialog::backdrop{background:#00151dcc;backdrop-filter:blur(5px)}dialog .close{float:right;margin:-12px -10px 10px 15px}.form-error{color:#ffc5b8;font-size:.9rem}.device-row{display:flex;align-items:center;justify-content:space-between;gap:12px;border-top:1px solid var(--line);padding:12px 0}.orientation-hint{display:none}.offline{background:#733d27;color:#fff2dc;padding:6px;text-align:center;font-size:.85rem}.footer-note{color:var(--muted);margin-top:22px;font-size:.8rem}.suit-options{display:grid;grid-template-columns:1fr 1fr;gap:12px}.suit-options button{font-size:1.2rem}.target-list{display:grid;gap:10px}.target-list button{display:flex;gap:15px;align-items:center;text-align:left}.results-names{font:2rem Georgia;color:var(--gold);margin:20px 0}.connection{font-size:.75rem;color:var(--muted)}
@media(min-width:1500px){.opponent .avatar{width:72px;height:72px;font-size:44px}.opponent .name{font-size:1rem}.card{width:112px;height:160px}.your-hand{max-height:230px}.turn-help{bottom:220px}}
@media(max-width:900px){.home-grid,.lobby-layout{grid-template-columns:1fr}.auth-layout{gap:30px}.auth-art .brand{font-size:2.3rem}.content{padding:30px 20px}.topbar{padding:12px 20px}.table-screen .topbar{min-height:52px;padding:5px 12px}.table-screen .brand{font-size:1.1rem}.table-screen .brand img{width:32px;height:32px}.table-screen .brand small{font-size:9px}.table-screen .topbar button{min-height:40px;padding:6px 10px;font-size:.85rem}.table-screen .topbar .pill{display:none}.opponent{width:80px}.opponent .avatar{width:42px;height:42px;font-size:26px}.opponent .name{font-size:.75rem;max-width:85px;padding:1px 6px}.opponent .count{font-size:.75rem}.mini-hand{display:none}.card{width:64px;height:94px;padding:6px;font-size:1.1rem;border-radius:7px}.card .suit-large{font-size:1.7rem}.your-hand{bottom:7px;left:15%;right:18%;gap:6px;padding:10px 5px;max-height:145px}.turn-help{bottom:116px;font-size:.8rem;left:18%;right:18%}.local-player{bottom:20px;left:3%}.local-player .avatar{width:42px;height:42px;font-size:26px}.local-player strong{font-size:.75rem;padding:1px 7px}.game-action{bottom:30px;right:2%;max-width:17%}.game-action button{font-size:.85rem;min-height:44px;padding:9px 12px}.game-action small{display:none}.deck{width:47px;height:63px;border-width:2px;font-size:1.5rem}.deck-label{font-size:.75rem;margin-top:5px}.discard .card{width:47px;height:63px;font-size:.8rem}.discard .suit-large{font-size:1.2rem}.piles{gap:16px}.center-play{gap:7px;top:44%}.turn-label{font-size:.75rem;padding:3px 10px}.event-line{display:none}.books{font-size:.7rem}}
@media(max-width:600px) and (orientation:portrait){.auth-layout{grid-template-columns:1fr;padding:28px 20px;gap:25px}.auth-art .brand img{width:66px;height:66px}.auth-art p{display:none}.auth-art .brand{margin-bottom:0}.auth-panel{max-width:none}.games{gap:10px}.game-choice{padding:18px;min-height:175px}.game-choice strong{font-size:1.4rem}.topbar .brand small{display:none}.topbar{padding:10px 14px}.topbar .brand{font-size:1.4rem}.topbar .brand img{width:40px;height:40px}.panel{padding:20px}.topbar button{font-size:.85rem;padding:8px 10px}.orientation-hint{display:block;background:#1a3e3b;text-align:center;padding:7px 15px;font-size:.8rem;color:#ffe4a8}.opponent{width:63px}.opponent .avatar{width:35px;height:35px;font-size:22px}.opponent .name{max-width:66px;font-size:.7rem;padding:1px 3px}.opponent .count{font-size:.7rem}.local-player{bottom:142px;left:5%}.your-hand{left:4%;right:4%;bottom:14px;max-height:125px}.turn-help{bottom:132px;left:24%;right:4%}.game-action{bottom:172px;max-width:40%;right:5%}.center-play{top:48%}.lobby-seat .actions{flex-direction:column}.lobby-seat .actions button{padding:6px 8px;font-size:.75rem}.auth-art h1{display:none}}
@media(max-height:500px) and (orientation:landscape){.opponent .avatar{width:32px;height:32px;font-size:21px}.opponent .name,.opponent .count{font-size:.75rem}.opponent{gap:1px}.table-screen .topbar{min-height:48px}.card{width:57px;height:82px}.turn-help{bottom:103px}.your-hand{max-height:110px}.center-play{top:42%;gap:4px}.deck{width:39px;height:54px}.discard .card{width:39px;height:54px}.deck-label{display:none}.turn-label{font-size:.75rem}.local-player .avatar{width:36px;height:36px}.local-player{bottom:20px}.game-action{bottom:27px}}
@media(prefers-reduced-motion:no-preference){button{transition:background .15s,transform .15s,box-shadow .15s}.panel{animation:arrive .25s ease-out}@keyframes arrive{from{opacity:.3;transform:translateY(8px)}to{opacity:1;transform:none}}}
/* Solid plates keep labels readable over every part of the castle photograph. */
.books,.turn-help,.deck-label{background:#061f23;border:1px solid #ad8f4d;border-radius:8px;padding:4px 9px;color:#ffe4aa;text-shadow:none}
.opponent .count,.opponent .name,.local-player strong{background:#061f23}
.opponent.active .name{background:#ffe4aa;color:#172522;border-color:#fff1c7;font-weight:800}
.speaking{z-index:4}.speech-bubble{position:absolute;top:100%;left:50%;transform:translateX(var(--bubble-shift,-50%));width:max-content;max-width:230px;background:#fff3d9;color:#182b2d;border:3px solid #efc46a;border-radius:18px;padding:12px 18px;box-shadow:0 7px 22px #0009;font-size:1.3rem;line-height:1.2;pointer-events:none}
.speech-bubble:before{content:'';position:absolute;bottom:100%;left:calc(50% - 8px);border:9px solid transparent;border-bottom-color:#efc46a}.speech-bubble.fish{background:#ffe7a6}.local-player .speech-bubble{top:auto;bottom:110%;left:0;transform:none}.local-player .speech-bubble:before{top:100%;bottom:auto;left:20px;border-bottom-color:transparent;border-top-color:#efc46a}
.action-caption{position:absolute;top:61%;left:50%;transform:translateX(-50%);width:min(480px,64%);padding:7px 12px;border:1px solid #ad8f4d;border-radius:10px;background:#061f23;color:#fff3d9;text-align:center;font-size:.85rem;pointer-events:none}.action-caption strong,.action-caption span{display:block}.action-caption strong{color:#ffe4aa}.action-caption span{font-size:.8rem}
.deck{padding:0;min-height:0}.deck:disabled{opacity:1}.deck.legal{outline:3px solid #fff0ac;outline-offset:5px;box-shadow:0 0 30px #ffd969;cursor:pointer}.card.legal{outline:2px solid #ffe38f;outline-offset:2px}
@media(max-width:900px){.speech-bubble{max-width:175px;font-size:1rem;padding:8px 12px}.action-caption{top:53%;font-size:.75rem;padding:4px 8px}.action-caption span{font-size:.7rem}.books{padding:1px 5px}.turn-help{padding:3px 6px}}
@media(max-width:600px) and (orientation:portrait){.action-caption{top:62%;width:90%}.speech-bubble{max-width:145px}}
@media(prefers-reduced-motion:no-preference){.speech-bubble.pop{animation:speech-pop .45s ease-out}.draw-flash{animation:draw-flash .7s ease-out}.opponent.active .avatar,.deck.legal{animation:turn-glow 1.8s ease-in-out infinite}@keyframes speech-pop{from{opacity:0;scale:.65}65%{scale:1.08}to{opacity:1;scale:1}}@keyframes draw-flash{50%{translate:0 -12px;box-shadow:0 0 35px #ffe39c}}@keyframes turn-glow{50%{box-shadow:0 0 0 4px #c69540,0 0 32px #f3be63}}}
.speech-bubble strong{background:none;color:#182b2d;padding:0;font:inherit;border-radius:0}
@media(max-width:900px){.action-caption span{display:none}.action-caption{top:53%;padding:5px 8px}.local-player .speech-bubble{max-width:150px}}
.turn-help{left:50%;right:auto;transform:translateX(-50%);width:max-content;max-width:75%;padding:4px 10px;font-size:.8rem;line-height:1.3}
.action-caption{width:max-content;max-width:65%;font-size:.75rem;padding:4px 9px}.action-caption span{display:none}
.face-card{font-size:.95rem}.face-card .rank-bottom{font-size:.85rem}
.saved-row{display:flex;gap:8px;align-items:center}.saved-row .table-link{flex:1;min-width:0}
.completed-pairs{display:flex;gap:4px;flex-wrap:wrap;justify-content:center;max-width:140px;max-height:65px;overflow:auto;padding:3px}
.pair-stack{display:flex;position:relative;width:32px;height:30px;flex-shrink:0}.pair-stack i{display:grid;place-items:center;position:absolute;left:0;top:0;width:23px;height:30px;background:#fff3d9;color:#182b2d;border:1px solid #ae8a49;border-radius:3px;font:8px Georgia;box-shadow:0 2px 4px #0006;transform:rotate(-9deg)}.pair-stack i+i{left:9px;transform:rotate(8deg)}
.flying-card{position:absolute;z-index:9;pointer-events:none;display:grid;place-items:center;width:44px;height:60px;border:2px solid #efc46a;border-radius:5px;color:#ffe4aa;background:repeating-linear-gradient(45deg,transparent,transparent 5px,#bd955722 6px,#bd955722 7px),#153966;box-shadow:0 6px 15px #0007;font:14px Georgia}.flying-card.face-up{background:#fff3d9;color:#182b2d}
@media(max-width:900px){.completed-pairs{max-width:100px;max-height:38px}.pair-stack{scale:.85;width:26px;margin:-2px}.face-card{font-size:.7rem}.face-card .rank-bottom{font-size:.65rem}.turn-help{max-width:68%;font-size:.75rem}.speech-bubble{padding:6px 9px;font-size:.95rem}}
.completed-pairs{scrollbar-width:none}.completed-pairs::-webkit-scrollbar{display:none}

.kids-help{margin-top:4px;color:var(--ink);font-size:.8rem;line-height:1.35;font-weight:400}.kids-help strong{color:var(--gold)}.kids-mode .turn-help{max-width:min(560px,68%);z-index:4}.device-row small{display:block}input[type=radio]{width:22px;min-height:22px}summary{cursor:pointer;margin:18px 0} @media(max-width:900px){.kids-help{font-size:.68rem}.kids-mode .action-caption{display:none}}
.extra-game.stage{display:flex;flex-direction:column;height:calc(100dvh - 68px);min-height:420px;padding:10px 18px;gap:8px;background:linear-gradient(#071c2060,#071c2090),url('/assets/castle-table.webp') center/cover;overflow:hidden}
.player-strip{display:flex;justify-content:center;gap:10px;overflow:auto;flex-shrink:0}.extra-seat{display:flex;gap:7px;align-items:center;background:#08292df5;border:1px solid #6b775e;border-radius:12px;padding:6px 10px;flex-shrink:0}.extra-seat.active{border:2px solid var(--gold)}.extra-seat strong,.extra-seat small{display:block}.extra-seat small{font-size:.7rem;color:#eee2bc}.extra-seat .avatar{width:32px;height:32px;font-size:22px}.finished-pair{display:inline-block;padding:2px;margin:2px;background:#f6eed7;color:#19302e;font-size:.65rem;font-style:normal;border-radius:3px}.extra-board{flex:1;min-height:90px;overflow:auto;text-align:center;padding:6px;color:#fff3d4;text-shadow:0 1px 2px #000}.extra-board p{margin:0 0 8px;background:#08292dee;border-radius:8px;padding:5px;display:table;margin-inline:auto}.extra-board .card{width:64px;height:90px;font-size:1rem;text-shadow:none}.extra-board .card .suit-large{font-size:1.8rem}.extra-board .card.face-card{font-size:.75rem}.extra-board .discard{transform:none}.extra-prompt{text-align:center;align-self:center;max-width:800px;background:#08292df5;padding:5px 12px;border:1px solid var(--gold);border-radius:8px;font-size:.8rem;flex-shrink:0}.extra-prompt p{margin:4px 0 0;font-size:.75rem;color:var(--ink)}.extra-hand.your-hand{position:static;transform:none;display:flex;justify-content:safe center;gap:5px;overflow-x:auto;overflow-y:hidden;flex-shrink:0;padding:4px;min-height:0}.hand-choice{padding:0;border:2px solid transparent;min-height:0;background:none;flex-shrink:0}.hand-choice .card{width:70px;height:100px;font-size:1rem;pointer-events:none}.hand-choice .card.face-card{font-size:.8rem}.hand-choice .card .suit-large{font-size:1.8rem}.hand-choice.selected{border-color:#ffdf7e;box-shadow:0 0 12px #ffd572}.hand-choice:disabled{opacity:.65}.extra-controls{display:flex;justify-content:center;align-items:center;gap:6px;flex-wrap:wrap;max-height:110px;overflow:auto;flex-shrink:0}.extra-controls button{min-height:34px;padding:5px 10px;font-size:.8rem}.extra-event{align-self:center;max-width:90%;font-size:.8rem;padding:5px 10px;background:#fff0c7;color:#18322e;border-radius:9px;text-align:center;flex-shrink:0}.trick-table{display:flex;justify-content:center;gap:14px}.trick-table small{display:block;background:#08292dee;padding:3px;margin-bottom:3px}.pick-fan{display:flex;flex-wrap:wrap;justify-content:center;gap:6px}.pick-fan button{width:48px;height:66px;font-size:22px;min-height:0}.memory-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:5px;max-width:620px;margin:auto}.memory-card{padding:4px;min-height:48px;background:repeating-linear-gradient(45deg,#214566,#214566 8px,#416483 9px,#214566 10px);font-size:1rem}.memory-card.revealed{background:#ffefd4;color:#18322e;opacity:1}.memory-card:disabled:not(.revealed){opacity:.4}.sevens-lanes{max-width:1000px;margin:auto;display:grid;gap:8px}.sevens-lanes>div{display:flex;gap:3px;align-items:center}.lane-card{flex:1;font-size:.75rem;padding:8px 1px;background:#0d292ab0;color:#a7b9ae;border:1px dashed #849589;border-radius:4px;text-shadow:none}.lane-card.placed{background:#fff1cf;color:#17332c;border-style:solid}.rummy-stock{display:flex;gap:12px;align-items:center;justify-content:center}.rummy-stock .deck{position:static;width:60px;height:85px;min-height:0}.melds{display:flex;flex-wrap:wrap;justify-content:center;gap:10px;margin-top:8px}.meld{background:#0a272be8;padding:5px;border-radius:8px}.meld>div{display:flex}.meld .card{width:38px;height:55px;margin-left:-7px;font-size:.65rem}.meld .card.face-card{font-size:.5rem}.meld .card .suit-large{font-size:1rem}.meld small{display:block}.up-card{display:flex;justify-content:center;margin-bottom:8px}
@media(max-width:900px){.extra-game.stage{height:calc(100dvh - 50px);min-height:330px;padding:4px 7px;gap:4px}.extra-seat{padding:3px 5px;gap:4px}.extra-seat strong{font-size:.7rem}.extra-seat small{font-size:.6rem}.extra-seat .avatar{width:25px;height:25px;font-size:18px}.player-strip{justify-content:safe center;gap:4px}.extra-board{padding:2px}.extra-board .card{width:42px;height:57px;font-size:.7rem}.extra-board .card.face-card{font-size:.55rem}.extra-board .card .suit-large{font-size:1.2rem}.extra-hand .card{width:45px;height:65px;font-size:.7rem}.extra-hand .card.face-card{font-size:.55rem}.extra-hand .card .suit-large{font-size:1.3rem}.extra-prompt{font-size:.72rem;padding:3px 8px;max-width:90%}.extra-prompt p{font-size:.65rem;margin-top:2px;max-height:44px;overflow:auto}.extra-event{font-size:.7rem;padding:3px 8px}.memory-grid{max-width:500px;gap:3px}.memory-card{min-height:30px;font-size:.72rem}.sevens-lanes{gap:3px}.lane-card{font-size:.55rem;padding:5px 0}.pick-fan button{width:34px;height:44px}.extra-controls{max-height:75px}.extra-controls button{min-height:30px;font-size:.7rem}.rummy-stock .deck{width:40px;height:54px}.extra-board p{font-size:.7rem}}
.extra-board{display:flex;flex-direction:column;align-items:center;justify-content:center}.memory-grid{width:min(620px,100%)}.memory-card{height:80px}.sevens-lanes{width:100%}.extra-event.fresh{animation:speech-pop .4s ease-out}.memory-card.revealed{animation:reveal-card .35s ease-out}@keyframes reveal-card{from{transform:rotateY(90deg)}to{transform:rotateY(0)}}@media(max-width:900px){.memory-grid{width:min(500px,100%)}.memory-card{height:32px}}@media(prefers-reduced-motion:reduce){.extra-event.fresh,.memory-card.revealed{animation:none}}
.hand-choice:enabled .card{border-color:#ecc971;box-shadow:0 0 5px #f8d15e66}.hand-choice.selected .card{background:#fff2ba}.extra-seat.active .avatar{box-shadow:0 0 10px #efc572}
.extra-board{justify-content:safe center}.extra-board:has(.rummy-stock){flex-direction:row;gap:18px}.extra-board:has(.rummy-stock) .melds{margin-top:0;max-width:65%}.extra-seat span{display:block;max-width:180px;max-height:28px;overflow:auto}
