:root{color-scheme:dark;--bg:#0b1220;--panel:#111d2d;--raised:#18273b;--line:#2b3c52;--text:#f0f5fa;--muted:#aab9ca;--blue:#82b8e4;--green:#80d0b7;--accent:#265978;--danger:#f4a7aa;--radius:16px}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font:16px/1.55 "Segoe UI",Roboto,Arial,sans-serif}a{color:var(--blue);text-decoration:none}a:hover{text-decoration:underline}button,input,select,textarea{font:inherit}button,select,input,textarea{border:1px solid var(--line);border-radius:9px;background:var(--raised);color:var(--text)}button{padding:9px 15px;min-height:43px;font-weight:600;cursor:pointer}button:hover{background:#243c54;border-color:#52789a}button:disabled{opacity:.48;cursor:default}button.primary{background:#287b69;border-color:#398c79;color:#fff}button.primary:hover{background:#348d78}button.danger{color:var(--danger)}button.subtle{background:transparent}input,select,textarea{min-height:43px;padding:9px 11px;max-width:100%}textarea{resize:vertical}input:focus-visible,select:focus-visible,textarea:focus-visible,button:focus-visible,a:focus-visible{outline:2px solid var(--green);outline-offset:3px}[hidden]{display:none!important}h1,h2,h3,p{margin-top:0}h1{font-size:clamp(2rem,4vw,2.75rem);line-height:1.1;letter-spacing:-.04em;margin-bottom:10px}h2{font-size:1.1rem;line-height:1.4;letter-spacing:-.015em;margin-bottom:5px}h3{line-height:1.4}label{display:flex;flex-direction:column;gap:6px;font-weight:600;font-size:.89rem}label input,label select{font-weight:400}p{margin-bottom:12px}.muted,.empty{color:var(--muted)}.together-shell{width:min(1400px,100%);margin:auto;padding:0 32px}.page-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:23px 0;border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:10px;color:var(--text);font-size:1.12rem;font-weight:700;letter-spacing:-.025em}.brand-mark{display:grid;place-items:center;width:30px;height:32px;color:var(--green);border:1px solid #487b79;border-radius:7px;font-size:1rem}.page-header nav{display:flex;gap:24px;font-size:.88rem}.page-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:35px 0 20px}.eyebrow{font-size:.68rem;letter-spacing:.16em;font-weight:700;color:var(--green);margin-bottom:12px}.lede{color:var(--muted);margin:0;font-size:1.06rem}.badge{display:inline-flex;align-items:center;border:1px solid var(--line);border-radius:99px;color:var(--muted);padding:5px 11px;font-size:.78rem;white-space:nowrap}.badge.online{color:var(--green);border-color:#35675e}.status{min-height:0;color:var(--green);margin:0 0 12px;padding:0;overflow-wrap:anywhere}.status:empty{display:none}.status.error{color:var(--danger);padding:11px 14px;border:1px solid #643947;border-radius:9px;background:#301e29}.panel{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius)}.setup-panel{padding:26px;max-width:1060px;margin:0 auto}.section-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:15px;margin-bottom:18px}.section-heading p{color:var(--muted);font-size:.86rem;margin:0;line-height:1.55}.section-heading button{flex:none}.notice{padding:13px 16px;border:1px solid #496b83;background:#172b40;border-radius:9px;font-size:.9rem;margin-bottom:22px}.notice a{display:inline-block}.language-fields{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-bottom:25px;max-width:660px}.mode-picker{border:0;padding:0;margin:0 0 26px;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.mode-picker legend{padding:0;margin-bottom:12px;font-size:.89rem;font-weight:600}.mode-card{position:relative;display:flex;gap:7px;padding:16px 15px 19px;border:1px solid var(--line);border-radius:12px;cursor:pointer;min-height:181px;transition:border-color .15s,background .15s}.mode-card:has(input:checked){border-color:var(--green);background:#193230}.mode-card input{position:absolute;right:13px;top:13px;min-height:0;accent-color:var(--green);width:15px;height:15px}.mode-symbol{color:var(--green);font-size:1.7rem;height:33px;font-weight:400;line-height:1}.mode-card strong{font-size:.96rem}.mode-card small{color:var(--muted);font-size:.79rem;font-weight:400;line-height:1.55}.setup-actions{display:flex;align-items:flex-end;gap:22px;padding-top:20px;border-top:1px solid var(--line)}.create-controls,.join-controls{display:flex;gap:12px;align-items:flex-end;flex:1}.create-controls button,.join-controls button{white-space:nowrap}.join-controls label{flex:1}.divider-word{font-size:.82rem;color:var(--muted);align-self:center;padding-top:20px}.setup-footnote{font-size:.8rem;color:var(--muted);margin:22px 0 0}.room-toolbar{padding:14px 20px;display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:22px}.room-identity{display:flex;align-items:center;gap:12px}.room-identity strong{display:block;font-size:.96rem}.room-code{font-size:.78rem;color:var(--muted);letter-spacing:.04em}.live-dot{width:8px;height:8px;flex:none;border-radius:50%;background:var(--green)}.toolbar-actions{display:flex;gap:9px;flex-wrap:wrap}.room-layout{display:grid;grid-template-columns:minmax(0,1fr) 292px;gap:22px;align-items:start}.activity-column{min-width:0}.activity-bar{display:flex;align-items:center;gap:14px;justify-content:space-between;min-height:58px;margin:0 0 14px;font-size:.82rem;color:var(--muted)}.activity-bar label{flex-direction:row;align-items:center;gap:10px;font-size:.82rem}.activity-bar select{min-width:170px}.activity-bar>span{margin-right:auto}.watch-panel{overflow:hidden}.screen-stage{position:relative;aspect-ratio:16/9;background:#03080f;display:flex;align-items:center;justify-content:center;overflow:hidden;border-bottom:1px solid var(--line)}.screen-stage video{width:100%;height:100%;object-fit:contain}.screen-placeholder{text-align:center;padding:25px;max-width:450px}.screen-placeholder>span{display:block;color:#5c7994;font-size:3.2rem;line-height:1;margin-bottom:18px}.screen-placeholder h2{font-size:1.17rem;color:#dce7f2}.screen-placeholder p{font-size:.85rem;color:#95a8bc;line-height:1.6;margin:0}.video-audio{position:absolute;inset:auto 50% 30px auto;transform:translateX(50%);width:max-content}.screen-badge{position:absolute;top:13px;left:15px;color:#c3f1e3;background:rgba(17,37,32,.9);border:1px solid #45695d;border-radius:99px;padding:4px 10px;font-size:.72rem;pointer-events:none}.watch-controls{padding:16px 20px;display:flex;gap:15px;align-items:center;flex-wrap:wrap}.watch-controls .host-only{display:flex;gap:10px}.watch-controls p{margin:0;font-size:.8rem;flex:1;min-width:180px}.captions-section{border-top:1px solid var(--line);padding:22px 20px}.caption-preferences{display:flex;align-items:flex-end;gap:11px;flex-wrap:wrap;margin-bottom:18px}.caption-preferences label{font-size:.8rem}.caption-preferences span{font-size:.78rem;margin:auto 0 10px}.caption-source{border:1px solid var(--line);border-radius:10px;padding:14px;background:#142335;margin-bottom:17px;display:flex;align-items:flex-end;gap:10px;flex-wrap:wrap}.caption-source>p{font-size:.77rem;flex-basis:100%;margin:2px 0}.caption-source>label{font-size:.8rem}.manual-caption{display:flex;align-items:flex-end;gap:10px;flex-basis:100%;margin-top:5px}.manual-caption label{flex:1;font-size:.8rem}.manual-caption input{font-size:.85rem}.caption-history{max-height:360px;overflow-y:auto;scrollbar-color:#456178 transparent}.caption-history>.empty{margin:14px 0;font-size:.9rem}.caption-entry{padding:13px 0;border-top:1px solid var(--line)}.caption-entry:first-child{border-top:0}.caption-entry .caption-meta{font-size:.7rem;color:var(--muted);margin:0 0 5px}.caption-line{margin:0 0 7px;line-height:1.8;overflow-wrap:anywhere}.caption-line.native{color:#c3d6e7;font-size:.92rem}.caption-line.original{color:var(--muted);font-size:.88rem}.caption-label{display:block;font-size:.68rem;text-transform:uppercase;color:var(--muted);letter-spacing:.045em;line-height:1.7;margin-bottom:2px}.caption-word{display:inline;border:0;padding:0 1px;min-height:0;border-radius:3px;background:transparent;color:inherit;font-weight:500;line-height:inherit;white-space:normal;font-size:inherit}.caption-word:hover{background:#264438;color:#fff;text-decoration:underline;text-underline-offset:4px;border:0}.caption-draft{border-left:2px solid var(--blue);padding:10px 12px;margin:5px 0 10px;background:#182b40;color:#c8daeb;font-size:.9rem}.caption-draft .caption-meta{color:var(--muted);font-size:.7rem;margin-bottom:4px}.room-sidebar{display:grid;gap:17px;margin-top:72px;min-width:0}.people-panel,.chat-panel{padding:18px}.people-panel .section-heading{margin-bottom:10px}.people-panel h2 span{font-size:.78rem;font-weight:400;margin-left:4px}.player-list{list-style:none;padding:0;margin:0}.player-list li{display:flex;align-items:center;gap:10px;padding:11px 0;border-top:1px solid var(--line)}.player-list li:first-child{border:0}.avatar{display:grid;place-items:center;width:32px;height:32px;flex:none;border-radius:50%;background:#254358;color:#c6e3f7;font-weight:600;font-size:.8rem}.player-info{min-width:0;flex:1}.player-name{font-size:.83rem;font-weight:600;overflow-wrap:anywhere}.player-info small{display:block;font-size:.69rem;color:var(--muted)}.player-list .remove-player{padding:3px 7px;min-height:28px;font-size:.69rem;color:var(--danger);background:transparent}.chat-panel{display:flex;flex-direction:column}.chat-panel .section-heading{margin-bottom:12px}.chat-messages{height:250px;overflow-y:auto;scrollbar-color:#456178 transparent}.chat-message{margin:0 0 16px;overflow-wrap:anywhere}.chat-message strong{font-size:.75rem;color:var(--blue)}.chat-message time{font-size:.65rem;color:var(--muted);margin-left:7px}.chat-message p{font-size:.85rem;margin:3px 0 0;white-space:pre-wrap}.chat-messages .empty{font-size:.82rem;margin:14px 0}.chat-form{display:flex;gap:8px;flex-wrap:wrap;border-top:1px solid var(--line);padding-top:14px;margin-top:10px}.chat-form textarea{width:100%;font-size:.85rem;min-height:75px}.chat-form button{margin-left:auto;padding:7px 17px;min-height:38px;font-size:.83rem}.chat-note{font-size:.7rem;margin:12px 0 0;line-height:1.5}.game-panel{padding:22px}.drawing-surface{background:#f7f9fc;border-radius:10px;overflow:hidden;border:1px solid #8095a6;aspect-ratio:8/5}.drawing-surface canvas{display:block;width:100%;height:100%;touch-action:none;cursor:default}.drawing-surface canvas.can-draw{cursor:crosshair}.drawing-tools{display:flex;align-items:flex-end;gap:12px;padding:13px 0}.drawing-tools label{font-size:.78rem}.drawing-tools input[type=color]{width:55px;padding:4px}.answer-form{display:flex;align-items:flex-end;gap:12px;margin-top:20px}.answer-form label{flex:1}.answer-language{font-weight:400;font-size:.75rem;color:var(--muted);display:inline}.answer-result{margin:10px 0 0;font-size:.87rem;color:var(--green);min-height:1.5em}.score-list{display:flex;gap:8px;flex-wrap:wrap;margin-top:17px}.score-chip{padding:5px 10px;border:1px solid var(--line);border-radius:99px;font-size:.75rem;color:var(--muted)}.score-chip strong{color:var(--text);margin-left:5px}.race-prompt{padding:35px 20px;background:#172b3b;border:1px solid #345066;border-radius:12px;text-align:center;margin:10px 0 27px}.race-prompt .eyebrow{display:block}.race-prompt h3{font-size:clamp(1.4rem,3vw,2rem);margin:8px 0 10px;color:#d7f0e8;overflow-wrap:anywhere}.race-prompt p{margin-bottom:0;font-size:.8rem}.checkers-board{display:grid;grid-template-columns:repeat(8,1fr);max-width:550px;aspect-ratio:1;margin:24px auto 18px;border:2px solid #516985;border-radius:5px;overflow:hidden}.checkers-square{position:relative;border:0!important;border-radius:0;padding:8%;min-height:0;aspect-ratio:1;display:grid;place-items:center;background:#d0dbe5!important}.checkers-square.dark{background:#325069!important}.checkers-square.selected{box-shadow:inset 0 0 0 3px #ffcf70!important}.checkers-square.legal{background:#54836e!important}.checkers-square.legal:empty:after{content:"";width:24%;height:24%;border-radius:50%;background:#d7f0e8}.checkers-square:disabled{opacity:1}.checker{display:grid;place-items:center;width:85%;height:85%;border-radius:50%;background:#192d42;border:2px solid #6583a0;box-shadow:0 3px 0 #0c1825;color:#dee9f1;font-size:clamp(.8rem,2vw,1.6rem)}.checker.red{background:#b65358;border-color:#f1b6b6;box-shadow:0 3px 0 #793335;color:#fff0ef}.checker.king:after{content:"♛"}.page-footer{display:flex;justify-content:space-between;gap:12px;border-top:1px solid var(--line);color:#7e91a5;font-size:.73rem;margin-top:40px;padding:22px 0 30px}.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}dialog{max-width:min(540px,calc(100vw - 32px));width:540px;background:var(--panel);border:1px solid #45617c;border-radius:16px;color:var(--text);padding:22px;max-height:85vh}dialog::backdrop{background:rgba(1,6,12,.78)}.dialog-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:20px}.dialog-heading h2{margin:0;font-size:1.2rem}.dialog-heading button{padding:3px 11px;min-height:36px;font-size:1.3rem}.word-meaning{color:var(--green);font-size:1.17rem}.word-definitions{padding-left:21px;font-size:.9rem}.word-definitions li{margin:9px 0}#roomLanguagesForm{display:grid;gap:18px}#roomLanguagesForm p{font-size:.85rem;margin:0}.word-context{color:var(--muted);font-size:.83rem;border-top:1px solid var(--line);padding-top:15px}
@media(min-width:1550px){.together-shell{padding:0 45px}.room-layout{grid-template-columns:minmax(0,1fr) 315px}}
@media(max-width:1050px){.together-shell{padding:0 22px}.mode-picker{grid-template-columns:repeat(2,minmax(0,1fr))}.mode-card{min-height:145px}.room-layout{grid-template-columns:minmax(0,1fr) 250px;gap:16px}.toolbar-actions button{font-size:.8rem;padding:7px 11px}.activity-bar{flex-wrap:wrap}.room-sidebar{margin-top:74px}.watch-controls{align-items:flex-start}.watch-controls p{flex-basis:100%}.setup-actions{gap:15px}.create-controls,.join-controls{flex-wrap:wrap}.create-controls label{flex:1}.create-controls button,.join-controls button{width:100%}.divider-word{padding-top:0}}
@media(max-width:760px){.together-shell{padding:0 16px}.page-header{padding:18px 0}.page-header nav{gap:15px;font-size:.77rem}.page-heading{margin:27px 0 19px;align-items:flex-start}.page-heading>.badge{max-width:140px;white-space:normal;text-align:center;font-size:.7rem}.lede{font-size:.91rem}.setup-panel{padding:21px 18px}.setup-panel .section-heading p{font-size:.83rem}.language-fields{gap:12px}.language-fields label{font-size:.79rem}.language-fields select{font-size:.87rem}.mode-picker{gap:10px}.mode-card{padding:15px 12px;min-height:165px}.mode-card strong{font-size:.89rem}.mode-card small{font-size:.76rem}.setup-actions{flex-direction:column;align-items:stretch;gap:16px}.create-controls,.join-controls{flex-wrap:nowrap;flex:none;gap:10px}.create-controls button,.join-controls button{width:auto;flex:none;font-size:.83rem}.create-controls label{flex:1}.divider-word{align-self:center}.room-toolbar{padding:13px 15px;align-items:flex-start;flex-direction:column;gap:13px}.toolbar-actions{width:100%;gap:8px}.toolbar-actions button{flex:1;min-height:39px}.room-layout{grid-template-columns:minmax(0,1fr);gap:18px}.room-sidebar{margin-top:0;grid-template-columns:minmax(0,1fr)}.activity-bar{min-height:0;gap:11px;margin-bottom:15px;align-items:center}.activity-bar>span{flex-basis:100%;order:3}.activity-bar label{font-size:.77rem}.activity-bar select{min-width:0;font-size:.83rem}.activity-bar button{font-size:.83rem}.screen-placeholder{padding:17px 20px}.screen-placeholder>span{font-size:2rem;margin-bottom:10px}.screen-placeholder h2{font-size:1rem}.screen-placeholder p{font-size:.74rem}.watch-controls,.captions-section{padding:16px}.section-heading{gap:10px}.section-heading button{font-size:.76rem;padding:7px 10px;min-height:38px}.section-heading p{font-size:.8rem}.caption-preferences{gap:10px}.caption-preferences select{font-size:.83rem}.caption-preferences button{font-size:.76rem}.caption-preferences span{margin:0;flex-basis:100%}.caption-source>button{font-size:.79rem;padding:8px 11px}.caption-source>label{width:100%}.caption-source select{font-size:.83rem}.manual-caption{align-items:flex-end}.manual-caption button{font-size:.79rem;padding:9px 11px}.caption-history{max-height:310px}.game-panel{padding:18px 15px}.answer-form{gap:8px}.answer-form label{font-size:.8rem}.answer-form input{font-size:.87rem}.answer-form button{font-size:.8rem;padding:9px 11px}.chat-messages{height:220px}.people-panel,.chat-panel{padding:17px}.player-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 15px}.player-list li{min-width:0}.player-list li:nth-child(2){border-top:0}.player-list .remove-player{padding:3px 5px}.page-footer{margin-top:28px;font-size:.65rem}.checkers-board{margin:18px auto}.checker{border-width:1px}.checkers-square{padding:7%}.video-audio{bottom:15px;font-size:.8rem}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
.chat-message .translate-message{background:transparent;border:0;padding:3px 0;margin-top:4px;min-height:28px;color:var(--blue);font-size:.71rem;font-weight:500;text-align:left}.chat-message .translate-message:hover{color:var(--green);text-decoration:underline}.chat-message .translate-message:disabled{opacity:1;color:var(--muted)}.chat-message .chat-translation{background:#1b3240;border-left:2px solid #518976;border-radius:4px;padding:7px 10px;color:#d6ece6;font-size:.81rem;white-space:pre-wrap}.chat-message .chat-translation .caption-label{font-size:.62rem;color:#9bb9ba}.chat-message .chat-translation-error{font-size:.71rem;color:var(--danger)}
.mode-picker{grid-template-columns:repeat(3,minmax(0,1fr))}.mode-card{min-height:160px}.game-setup{padding:17px 20px;margin-bottom:17px}.game-settings{display:flex;gap:14px;flex-wrap:wrap;align-items:flex-end}.game-settings label{flex:1;min-width:150px;font-size:.8rem}.game-settings p{flex-basis:100%;font-size:.78rem;margin:0}.chess-board{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));max-width:550px;aspect-ratio:1;margin:24px auto 18px;border:2px solid #516985;border-radius:5px;overflow:hidden}.chess-square{position:relative;display:grid;place-items:center;aspect-ratio:1;min-height:0;border:0!important;border-radius:0;padding:0;background:#d1dce4!important;opacity:1!important}.chess-square.dark{background:#4b6b82!important}.chess-square.selected{box-shadow:inset 0 0 0 3px #ffd378}.chess-square.legal{box-shadow:inset 0 0 0 3px #258b6d}.chess-square.legal:after{content:"";position:absolute;width:20%;height:20%;border-radius:50%;background:#286d58;opacity:.7}.chess-square.legal:has(.chess-piece):after{width:85%;height:85%;border:3px solid #80efbc;background:transparent}.chess-square:focus-visible{outline:3px solid #ffd378;outline-offset:-4px;z-index:1}.chess-piece{font-family:"Segoe UI Symbol","Noto Sans Symbols 2","DejaVu Sans",serif;font-size:clamp(1.65rem,4.1vw,3.5rem);line-height:1;pointer-events:none;z-index:1}.chess-piece.white{color:#fffdf3;text-shadow:0 1px 2px #152739,-1px 0 #152739,1px 0 #152739}.chess-piece.black{color:#101d2c;text-shadow:0 1px 1px #d1dce4}.board-coordinate{position:absolute;bottom:1px;right:3px;font-size:.55rem;color:#203547;pointer-events:none}.chess-square.dark .board-coordinate{color:#e0eaf2}.chess-actions{display:flex;gap:9px;flex-wrap:wrap}.chess-actions button{font-size:.8rem}.chess-actions .danger{margin-left:auto}.chessDrawOffer,.chess-actions+.notice{margin-top:15px;margin-bottom:0}.chess-actions+.notice button{margin:7px 7px 0 0;font-size:.79rem}.promotion-choices{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.promotion-choices button{display:flex;flex-direction:column;align-items:center;gap:9px;font-size:.8rem}.promotion-choices .chess-piece{font-size:2.7rem}.speaking-prompt{padding:26px;background:#172c3b;border:1px solid #345266;border-radius:12px;margin:10px 0 22px}.speaking-prompt h3{font-size:clamp(1.25rem,2.6vw,1.85rem);line-height:1.6;color:#ddf2e9;margin:8px 0 12px;overflow-wrap:anywhere;white-space:pre-wrap}.speaking-prompt .eyebrow{display:block;margin:0}.speaking-prompt p{font-size:.82rem;margin:0}.speaking-privacy{font-size:.82rem;color:var(--muted);margin-bottom:15px}.speaking-record-controls{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin-bottom:18px}.speaking-record-controls span{font-size:.8rem;flex:1;min-width:170px}.speaking-record-controls span.recording{color:var(--green)}#speechTranscript{width:100%;font-size:1rem;line-height:1.65;font-weight:400}.speech-preview{padding:13px 14px;background:#142938;border:1px solid var(--line);border-radius:10px;margin-top:14px;display:flex;flex-wrap:wrap;gap:8px;align-items:center}.speech-preview>.caption-label{flex-basis:100%;margin:0}.speech-preview audio{width:min(100%,380px);height:42px;flex:1;min-width:160px}.speech-preview button{font-size:.75rem;min-height:36px}.speaking-submit-controls{display:flex;gap:10px;margin-top:17px}.speaking-check-note{font-size:.76rem;margin:12px 0 0}.speaking-submissions{border-top:1px solid var(--line);margin-top:23px;padding-top:17px;max-height:420px;overflow:auto}.speaking-submissions h3{font-size:.95rem;margin-bottom:15px}.speech-submission{padding:13px 0;border-top:1px solid var(--line)}.speech-submission:first-of-type{border-top:0}.speech-submission strong{color:var(--blue);font-size:.8rem}.speech-submission p{font-size:.95rem;white-space:pre-wrap;overflow-wrap:anywhere;margin:5px 0}.speech-submission small{font-size:.72rem;color:var(--muted)}.speech-submission audio{width:100%;max-width:400px;height:40px;margin-top:8px}.speaking-empty{font-size:.86rem;color:var(--muted)}
@media(max-width:1050px){.mode-picker{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.game-setup{padding:15px}.game-settings{gap:11px}.game-settings label{min-width:120px}.chess-board{margin:18px auto}.chess-piece{font-size:clamp(1.65rem,7vw,3rem)}.board-coordinate{font-size:.49rem;right:2px}.speaking-prompt{padding:20px 16px}.speaking-record-controls button,.speaking-submit-controls button{font-size:.83rem;padding:9px 12px}.speaking-submit-controls button{flex:1}.speaking-record-controls span{flex-basis:100%}.speech-preview audio{flex-basis:100%}.speech-preview button{margin-left:auto}.promotion-choices{gap:6px}.promotion-choices button{padding:12px 6px;font-size:.7rem}}
.speaking-host-controls{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:20px;border-top:1px solid var(--line);padding-top:15px}.speaking-host-controls button{font-size:.8rem}.speaking-host-controls form{display:flex;gap:8px;flex:1;min-width:230px}.speaking-host-controls input{flex:1;min-width:0;font-size:.82rem}#speakingCaptureStatus.error{color:var(--danger)}#speakingTranslation{margin-bottom:12px;color:#bdd0e1}
@media(max-width:760px){.speaking-host-controls form{min-width:0;flex-basis:100%}.speaking-host-controls form button{font-size:.76rem;padding:9px}}
.game-settings .drawing-attribution{font-size:.68rem;line-height:1.6;color:#8fa4b9}
.speaking-transcription-note{font-size:.76rem;line-height:1.6;color:#b3c7d6;margin-top:-5px;margin-bottom:17px}
.checker.king:after{content:"K";font-family:inherit;font-weight:700}.game-panel{scroll-margin-top:15px}
.activity-groups{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;border:0;padding:0;margin:0 0 22px}.activity-groups label{position:relative;padding:13px 15px;background:#15263a;border:1px solid var(--line);border-radius:10px;cursor:pointer;gap:3px}.activity-groups label:has(input:checked){border-color:var(--green);background:#1c3836}.activity-groups input{position:absolute;opacity:0;width:1px;height:1px;min-height:0;padding:0}.activity-groups label:has(input:focus-visible){outline:2px solid var(--green);outline-offset:3px}.activity-groups strong{font-size:.9rem}.activity-groups small{font-size:.72rem;font-weight:400;color:var(--muted)}.mode-picker{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;margin-bottom:21px}.mode-card{min-height:122px;padding:14px 15px;gap:5px}.mode-card[data-group=watch]{grid-column:1/-1}.mode-card .mode-symbol{height:27px;font-size:1.4rem}.mode-card .mode-chess-icon{width:29px;height:29px;object-fit:contain}.mode-card small{font-size:.78rem}.invitation-landing{margin-bottom:22px}.invitation-landing .eyebrow{margin-bottom:9px}.invitation-landing h2{font-size:1.4rem;line-height:1.4;margin-bottom:9px}.invitation-landing>p{font-size:.9rem}.invitation-landing #invitationAvailability{font-size:.79rem}.invitation-landing label{max-width:400px;margin-top:17px}.setup-panel:has(#invitationLanding:not([hidden])) .setup-actions{padding-top:0;border:0}.setup-panel:has(#invitationLanding:not([hidden])) .join-controls{justify-content:flex-start;flex-wrap:wrap}.setup-panel:has(#invitationLanding:not([hidden])) .join-controls button{width:auto}.setup-panel:has(#invitationLanding:not([hidden])) #joinRoom{background:#287b69;border-color:#398c79;color:#fff}.room-toolbar{flex-wrap:wrap}.invitation-share{flex-basis:100%;border-top:1px solid var(--line);padding-top:13px}.invitation-share label{font-size:.78rem}.invitation-share input{font-size:.83rem;width:100%;font-weight:400}.invitation-share p{font-size:.78rem;margin:7px 0 10px}.checkbox-label{display:flex!important;flex-direction:row;align-items:center;gap:8px;font-weight:400}.checkbox-label input{width:17px;min-height:17px;height:17px;accent-color:var(--green)}.game-lobby{display:flex;align-items:center;justify-content:space-between;gap:17px;padding:13px 15px;border:1px solid #467a73;border-radius:9px;background:#18312f;margin-bottom:18px}.game-lobby p{font-size:.84rem;margin:0;color:#c6e5dc}.game-lobby button{white-space:nowrap}.chess-piece{display:block;width:84%;height:84%;object-fit:contain;pointer-events:none}.promotion-choices .chess-piece{width:50px;height:50px}.memory-board{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:20px 0}.memory-card{aspect-ratio:1.15;min-height:82px;padding:9px;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:5px;text-align:center;overflow-wrap:anywhere}.memory-card:disabled{opacity:1}.memory-card.hidden{background:repeating-linear-gradient(135deg,#1f4159,#1f4159 7px,#244c61 7px,#244c61 14px);border:1px solid #58839d}.memory-card.hidden:hover:enabled{border-color:var(--green);background:#2c5c6f}.memory-card.revealed{background:#ecf2f3;color:#143040;border-color:#d9e4e6}.memory-card.matched{background:#244b40;border-color:#639d84;color:#e1f4ea}.memory-card strong{font-size:clamp(.84rem,1.8vw,1.15rem);line-height:1.5}.memory-card small{font-size:.7rem;font-weight:400;line-height:1.4}.memory-card-back{font-size:1.7rem;color:#b2d9e7}.memory-matched-label{font-size:.62rem;font-weight:400;color:#a8d7c6}.memory-instructions{font-size:.85rem}.tic-tac-toe-board{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;width:min(100%,360px);margin:28px auto}.tic-tac-toe-cell{aspect-ratio:1;min-height:0;border-radius:10px;font-size:clamp(2rem,6vw,3.5rem);font-weight:600;background:#192f43}.tic-tac-toe-cell.mark-x{color:var(--blue)}.tic-tac-toe-cell.mark-o{color:var(--green)}.tic-tac-toe-cell.winning{border-color:#b5eacb;background:#254d3f}.poker-fictional{font-size:.8rem;color:#b9dacb;margin:0 0 16px}.poker-table{background:#153b35;border:1px solid #376a5f;border-radius:16px;padding:19px 18px}.poker-pot{text-align:center;margin-bottom:16px;color:#c7e8dc;font-size:.78rem}.poker-pot .caption-label{color:#9fc5b8}.poker-pot strong{font-size:1.7rem;margin-right:6px;color:#fff1c6}.poker-players{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin-bottom:22px}.poker-player{padding:9px 11px;border:1px solid #37615a;border-radius:9px;background:#11332f;min-width:0}.poker-player.current{border-color:#e5c77d;background:#28453b}.poker-player.folded{opacity:.65}.poker-player strong{display:block;font-size:.81rem;overflow-wrap:anywhere}.poker-player span{display:block;font-size:.77rem;color:#c9dfd7}.poker-player small{font-size:.66rem;color:#a9cbbf}.poker-your-hand>.caption-label{color:#b0d2c5;text-align:center}.poker-cards{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin-top:10px}.playing-card{display:flex;flex-direction:column;justify-content:space-between;align-items:center;width:clamp(48px,9vw,76px);height:clamp(74px,13vw,108px);background:#f5f2e8;color:#152535;border:2px solid #d6ddda;border-radius:7px;padding:6px;box-shadow:0 2px 3px #051d1c;min-height:0}.playing-card-rank{font-size:clamp(1rem,2.3vw,1.4rem);line-height:1;margin-right:auto}.playing-card-suit{width:60%;height:60%;object-fit:contain;pointer-events:none}.playing-card.red-suit{color:#b73945}.playing-card.card-back{background:repeating-linear-gradient(135deg,#284c69,#284c69 5px,#3a6582 5px,#3a6582 10px);border:3px solid #d4e0dc}.playing-card.discard-selected{transform:translateY(-7px);border-color:#ffd479;outline:2px solid #ddb764;outline-offset:2px}button.playing-card:hover{background:#fffdf4;border-color:#e4bf70}.poker-controls{margin-top:19px}.poker-controls>p{font-size:.85rem;margin-bottom:12px}.poker-bet-buttons{display:flex;gap:9px;flex-wrap:wrap}.poker-controls form{display:flex;align-items:flex-end;gap:10px;margin-top:14px}.poker-controls form label{font-size:.79rem;max-width:210px}.poker-controls form input{width:100%}#pokerNext{margin-top:20px}.poker-showdown{border-top:1px solid var(--line);padding-top:17px;margin-top:20px}.poker-showdown-hand{margin-bottom:19px}.poker-showdown-hand>strong{display:block;font-size:.86rem}.poker-showdown-hand>small{display:block;font-size:.77rem}#pokerNarration{font-size:.8rem;margin:17px 0 0}
body[data-desktop=true] .together-shell{padding:0 15px}body[data-desktop=true] .page-header{padding:10px 0}body[data-desktop=true] .page-heading,body[data-desktop=true] .page-footer{display:none}body[data-desktop=true] .setup-panel{margin-top:15px;padding:20px}body[data-desktop=true] .setup-panel .section-heading{margin-bottom:14px}body[data-desktop=true] .activity-groups{margin-bottom:17px}body[data-desktop=true] .mode-card{min-height:105px;padding:12px 14px}body[data-desktop=true] .room-toolbar{margin:13px 0 14px;padding:11px 15px}body[data-desktop=true] .room-code{display:none}body[data-desktop=true] .activity-bar{min-height:45px;margin-bottom:11px}body[data-desktop=true] .room-sidebar{margin-top:56px}body[data-desktop=true] .game-panel{padding:18px}body[data-desktop=true] .chess-board{margin:17px auto;max-width:480px}body[data-desktop=true] .game-panel .section-heading{margin-bottom:13px}body[data-desktop=true] .status:not(:empty){margin-top:10px}
@media(max-width:760px){.activity-groups{gap:7px;margin-bottom:18px}.activity-groups label{padding:12px 9px}.activity-groups strong{font-size:.76rem}.activity-groups small{font-size:.65rem;line-height:1.5}.mode-card{min-height:129px;padding:13px 12px}.mode-card small{font-size:.76rem}.invitation-landing h2{font-size:1.22rem}.game-lobby{flex-direction:column;align-items:stretch;gap:11px}.game-lobby button{width:100%}.memory-board{gap:7px}.memory-card{padding:7px 4px;aspect-ratio:.92;min-height:82px}.memory-card strong{font-size:.82rem}.memory-card small{font-size:.64rem}.memory-card-back{font-size:1.4rem}.poker-table{padding:15px 10px}.poker-players{gap:7px}.poker-player{padding:8px}.poker-player strong{font-size:.73rem}.poker-player span{font-size:.69rem}.poker-cards{gap:6px}.playing-card{width:46px;height:70px;padding:5px}.playing-card-rank{font-size:1.05rem}.poker-bet-buttons button{flex:1;font-size:.83rem}.poker-controls form button{font-size:.83rem}.poker-your-hand .caption-label{font-size:.59rem}body[data-desktop=true] .room-sidebar{margin-top:0}body[data-desktop=true] .setup-panel{padding:17px 14px}}

.link-video-stage{aspect-ratio:16/9;background:#070f19;border-radius:12px;overflow:hidden;margin:16px 0;min-height:200px}.link-video-stage iframe{width:100%;height:100%;border:0}#videoHostControls{flex-wrap:wrap}#videoPosition{max-width:110px}#videoLinkForm label{flex:1;min-width:180px}

.table-panel{--felt:#164e42;--paper:#fff8e7;--ink:#182936}.table-rules{margin:8px 0 16px;color:#b8c9d5}.table-rules summary{cursor:pointer}.table-players{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:12px}.table-player{padding:8px 12px;border:1px solid #3c5464;border-radius:24px;font-size:.85rem}.table-player.active{background:#184f45;border-color:#6de6c3;box-shadow:0 0 0 2px #6de6c325}.felt-table{background:radial-gradient(ellipse at center,#226b59,var(--felt));border:5px solid #624f3b;border-radius:28px;min-height:200px;display:grid;place-content:center;padding:24px 16px;margin:14px 0;box-shadow:inset 0 3px 20px #0005}.table-board,.table-hand{display:flex;flex-wrap:wrap;justify-content:center;gap:8px}.table-hand{justify-content:flex-start;margin:12px 0 18px}.playing-piece{color:var(--ink)!important;background:var(--paper)!important;border:2px solid #c6b997!important;border-radius:9px;min-width:58px;min-height:80px;padding:8px!important;font-weight:750;font-size:1.35rem!important;box-shadow:0 3px 0 #0003}.playing-piece.red{color:#af2836!important}.playing-piece:disabled{opacity:.42}.playing-piece:not(:disabled):hover{transform:translateY(-4px);border-color:#74e6c4!important}.table-board .playing-piece{opacity:1}.domino-piece{display:flex;align-items:center;min-width:100px;min-height:52px;gap:9px}.domino-half{display:grid;grid-template:repeat(3,7px)/repeat(3,7px);gap:3px;padding:4px}.domino-dot{border-radius:50%;background:#1c3037;width:7px;height:7px}.domino-divider{align-self:stretch;border-left:1px solid #8b918b}.table-clue{text-align:center;color:#fff5d7;font-size:1.1rem}.felt-table .muted{color:#d0e5dd;text-align:center}.letter-tile{background:var(--paper);color:var(--ink);padding:10px;border-radius:6px;font-size:1.8rem;font-weight:750;min-width:35px;text-align:center}#tableNotice{min-height:1.5em}#tableChoices{flex-wrap:wrap}#tableChoices label{min-width:120px}#tableHandTitle{font-size:.95rem;color:#b8c9d5} .playing-piece:focus-visible{outline:3px solid #fff;outline-offset:3px}
@media(max-width:600px){.felt-table{border-width:3px;padding:16px 8px}.playing-piece{min-width:48px;min-height:68px}.domino-piece{min-width:94px;min-height:48px}.table-hand{gap:6px}}@media(prefers-reduced-motion:reduce){.playing-piece:hover{transform:none!important}}

.felt-table button.letter-tile{background:var(--paper);color:var(--ink);border:2px solid #ddcfae;min-height:48px;font-size:1.15rem}.felt-table button.letter-tile:disabled{opacity:.6}.playing-piece:disabled{opacity:.65}#tableBuilt{font-weight:750;color:#99f2d5;max-width:100%;overflow-wrap:anywhere}

/* Room language capabilities stay visible before joining and during play. */
.language-policy-badge,.mode-card .mode-language-badge{display:inline-flex;align-items:center;max-width:100%;padding:6px 9px;border:1px solid #34645d;border-radius:7px;background:#123730;color:#a6f0d8;font-size:12px;font-weight:650;line-height:1.45;white-space:normal;overflow-wrap:anywhere}
.mode-card .mode-language-badge{grid-column:1/-1;justify-self:start;margin-top:8px;text-align:left;font-size:11px}
.concept-explainer{padding:16px 18px;margin:12px 0 16px;border:1px solid #355561;border-radius:12px;background:#122b36;color:#e7f3f5}
.concept-explainer p{margin:7px 0 0;color:#bcd0db;font-size:14px;line-height:1.65}
.concept-explainer [lang]{color:#a6f0d8;font-weight:650}
#setupPolicyBadge{margin:4px 0 12px}
.room-language-context{padding:14px 18px;margin:12px 0 16px}
.room-language-context p{margin:7px 0 0;font-size:14px;line-height:1.6;overflow-wrap:anywhere}
#raceSense{font-size:14px;line-height:1.6;max-width:65ch;margin:8px auto 0}
@media(max-width:600px){.concept-explainer,.room-language-context{padding:12px 14px}.mode-card .mode-language-badge{font-size:11px}}
@media(max-width:600px){body #studioLink{display:inline-flex}.page-header{flex-wrap:wrap;align-items:flex-start}.page-header nav{width:100%;justify-content:flex-start;flex-wrap:wrap;gap:10px}}

/* Shared chat stays readable without expanding the game canvas. */
.chat-language{display:flex;align-items:center;gap:8px;font-size:.78rem;margin:10px 0}.chat-language select{flex:1;min-width:0;padding:7px}.chat-voice-controls{display:flex;flex-wrap:wrap;gap:7px;margin-top:10px}.chat-voice-controls button{padding:8px 10px;font-size:.8rem}#chatVoiceStatus{font-size:.76rem;line-height:1.5;margin:9px 0}.chat-message audio,#chatVoicePreview{display:block;width:100%;max-width:100%;height:40px;margin:9px 0}.chat-message .caption-line{font-size:.9rem}.chat-message .caption-word{font-size:inherit}.chat-message .audio-expired{display:block;color:#f5c47d}.chat-copy:empty{display:none}.chat-panel{min-width:0}


/* Together interface system. Shared by hosted, mobile, and embedded desktop rooms.
   Keep game geometry and state-specific rules above; these tokens and components
   provide one visual language without downloading fonts or an icon library. */
:root {
  --bg: var(--vm-bg);
  --panel: var(--vm-surface);
  --raised: var(--vm-card);
  --line: var(--vm-border);
  --text: var(--vm-text);
  --muted: var(--vm-muted);
  --blue: #9ddcf7;
  --green: var(--vm-draft);
  --danger: #ffb5b8;
  --radius: var(--vm-radius);
  --field: var(--vm-inset);
}
body { font-family: "Segoe UI", system-ui, -apple-system, sans-serif; font-size: 15px; line-height: 1.55; }
h1 { font-size: 36px; font-weight: 650; letter-spacing: -.035em; margin-bottom: 8px; }
h2 { font-size: 18px; font-weight: 650; letter-spacing: -.02em; }
h3 { font-weight: 600; }
label { font-size: 13px; font-weight: 600; gap: 7px; }
button, input, select, textarea { border-radius: 8px; font-size: 14px; line-height: 1.45; }
button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 42px; padding: 9px 15px; border-color: #526e7e; font-weight: 600; transition: background .14s, border-color .14s; }
button:hover:enabled { background: #243b49; border-color: #668292; }
button.primary, .setup-panel:has(#invitationLanding:not([hidden])) #joinRoom { color: #082d29; background: var(--green); border-color: var(--green); }
button.primary:hover:enabled, .setup-panel:has(#invitationLanding:not([hidden])) #joinRoom:hover:enabled { background: #91ead7; border-color: #91ead7; }
button:disabled { opacity: .5; }
button.danger { background: #2b222b; border-color: #61414b; }
button.danger:hover:enabled { background: #402b35; border-color: #a56874; }
button.subtle { background: transparent; }
input, textarea { background: var(--field); }
select { background: var(--field); cursor: pointer; }
input::placeholder, textarea::placeholder { color: #8399a8; opacity: 1; }
input, select, textarea { min-height: 42px; padding: 9px 11px; border-color: #4b6575; }
.ui-icon { width: 22px; height: 22px; flex: none; vertical-align: middle; }
button .ui-icon { width: 18px; height: 18px; }
.together-shell { width: min(1280px, 100%); padding: 0 28px; }
.page-header { min-height: 72px; padding: 17px 0; }
.brand { font-size: 21px; font-weight: 700; gap: 9px; }
.brand-mark { width: 30px; height: 30px; background: #163330; color: var(--green); border-color: #3d6d66; }
.page-header nav { align-items: center; gap: 22px; font-size: 13px; }
.page-header nav a { color: #d4dfe6; }
#accountLink { border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; }
.page-heading { margin: 22px 0 18px; }
.lede { font-size: 15px; }
.badge { font-size: 12px; font-weight: 500; padding: 4px 9px; border-radius: 6px; background: #162733; white-space: normal; }
#connectionBadge { color: var(--muted); background: transparent; border: 0; padding: 0; font-size: 12px; }
#connectionBadge:not(.online) { max-width: 140px; }
#connectionBadge.online { color: var(--green); }
#connectionBadge.online:before { content: ""; width: 6px; height: 6px; background: var(--green); border-radius: 50%; margin-right: 7px; flex: none; }
.panel { box-shadow: 0 2px 4px #00000012; }
.setup-panel { max-width: 1040px; padding: 22px 24px 18px; }
#setupIntro { margin-bottom: 16px; }
#setupIntro h2 { font-size: 16px; }
.section-heading { gap: 16px; margin-bottom: 18px; }
.section-heading p { font-size: 13px; line-height: 1.6; }
.activity-groups { gap: 8px; margin-bottom: 20px; }
.activity-groups label { display: grid; grid-template-columns: 24px minmax(0,1fr); column-gap: 10px; row-gap: 2px; padding: 12px 14px; background: var(--field); border-radius: 9px; }
.activity-groups .ui-icon { grid-row: 1 / 3; align-self: center; color: #9fb4c2; }
.activity-groups strong { font-size: 14px; font-weight: 600; }
.activity-groups small { font-size: 11px; line-height: 1.5; }
.activity-groups label:hover { background: #1a2d3a; border-color: #5d7b8b; }
.activity-groups label:has(input:checked) { background: #173d36; border-color: #66cbb6; }
.activity-groups label:has(input:checked) .ui-icon, .activity-groups label:has(input:checked) strong { color: #99f0db; }
.language-fields { max-width: none; gap: 14px; margin-bottom: 18px; }
.mode-picker { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; margin-bottom: 20px; }
.mode-picker legend { margin-bottom: 10px; font-size: 12px; color: var(--muted); font-weight: 500; }
.mode-card, body[data-desktop=true] .mode-card { display: grid; grid-template-columns: 38px minmax(0,1fr) 16px; grid-template-rows: auto auto; gap: 3px 12px; min-height: 72px; padding: 11px 14px; background: var(--field); border-radius: 9px; align-content: center; }
.mode-card[data-group=watch] { grid-column: auto; min-height: 110px; }
.mode-card .mode-symbol { grid-row: 1 / 3; grid-column: 1; display: grid; place-items: center; align-self: center; width: 38px; height: 40px; color: #c0d2dc; background: #1c303e; border-radius: 8px; }
.mode-symbol .ui-icon { width: 25px; height: 25px; }
.mode-card strong { grid-column: 2; font-size: 14px; font-weight: 600; line-height: 1.4; }
.mode-card small { grid-column: 2; font-size: 12px; line-height: 1.5; color: #aebfcc; }
.mode-card input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.mode-card:after { content: ""; grid-row: 1 / 3; grid-column: 3; align-self: center; width: 14px; height: 14px; border: 1px solid #526d7d; border-radius: 50%; }
.mode-card:hover { background: #152a36; border-color: #617f8f; }
.mode-card:has(input:checked) { background: #16322f; border-color: #69cdb8; }
.mode-card:has(input:checked) .mode-symbol { color: #9debd7; background: #24473e; }
.mode-card:has(input:checked):after { width: 16px; height: 16px; border: 0; background-color: var(--green); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m4 8 3 3 5-6' fill='none' stroke='%23082d29' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.mode-card:has(input:focus-visible) { outline: 2px solid var(--green); outline-offset: 3px; }
.setup-actions { gap: 20px; padding-top: 18px; }
.create-controls, .join-controls { gap: 10px; flex-wrap: nowrap; }
.create-controls { flex: .9; }
.create-controls label { flex: 1; }
.create-controls button, .join-controls button { width: auto; }
.join-controls { flex: 1.15; border-left: 1px solid var(--line); padding-left: 22px; }
.join-controls label { min-width: 0; }
.divider-word { display: none; }
.setup-footnote { font-size: 12px; line-height: 1.65; margin-top: 14px; }
.room-lifetime-note { margin: 14px 0 0; color: #91a7b7; }
#screenLimitHint { font-size: 13px; }
.notice { border-color: #466374; background: #182d3b; font-size: 13px; line-height: 1.65; }
.invitation-landing h2 { font-size: 24px; letter-spacing: -.025em; }
.invitation-landing .eyebrow { letter-spacing: .08em; font-weight: 600; }
.setup-panel:has(#invitationLanding:not([hidden])) .join-controls { padding: 0; border: 0; }
body:has(#roomPanel:not([hidden])) .page-heading { display: none; }
.room-toolbar, body[data-desktop=true] .room-toolbar { background: transparent; border: 0; border-bottom: 1px solid var(--line); box-shadow: none; border-radius: 0; padding: 18px 0; margin: 0 0 20px; }
.room-identity { min-width: 0; gap: 10px; }
.room-identity strong { font-size: 22px; letter-spacing: -.025em; font-weight: 650; }
.room-code { font-size: 11px; letter-spacing: .02em; display: block; overflow-wrap: anywhere; }
.live-dot { width: 7px; height: 7px; }
.toolbar-actions { gap: 8px; }
.toolbar-actions button { min-height: 38px; font-size: 13px; padding: 8px 12px; }
#copyInvite { background: #15312e; border-color: #3b8172; color: #b8f5e4; }
.invitation-share { background: var(--panel); padding: 16px; border: 1px solid var(--line); border-radius: 10px; }
.invitation-share label, .invitation-share p { font-size: 12px; }
.room-layout { grid-template-columns: minmax(0,1fr) 320px; gap: 20px; }
.room-sidebar, body[data-desktop=true] .room-sidebar { gap: 16px; margin-top: 0; }
.activity-bar, body[data-desktop=true] .activity-bar { align-items: center; gap: 12px; min-height: 60px; padding: 10px 14px; margin: 0 0 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; }
.activity-bar label { font-size: 12px; gap: 8px; }
.activity-bar select { font-size: 13px; min-width: 170px; min-height: 36px; padding: 7px 9px; }
.activity-bar>span { font-size: 12px; line-height: 1.5; }
.activity-bar button { font-size: 12px; min-height: 36px; padding: 7px 12px; white-space: nowrap; }
.game-panel, body[data-desktop=true] .game-panel { padding: 20px; }
.game-panel>.muted { font-size: 13px; line-height: 1.65; }
.game-setup { background: #142633; padding: 16px; margin-bottom: 14px; }
.game-settings label { font-size: 12px; }
.game-settings p { font-size: 12px; line-height: 1.6; }
.game-lobby { padding: 12px 14px; background: #18342f; border-color: #3d7064; border-radius: 8px; }
.game-lobby p { font-size: 12px; }
.game-lobby button { min-height: 36px; font-size: 13px; }
.chess-board, .checkers-board, body[data-desktop=true] .chess-board { max-width: 480px; margin: 18px auto; border: 1px solid #749389; border-radius: 4px; }
.chess-square, .checkers-square { background: #e4e8d7!important; }
@supports not (aspect-ratio: 1) {
  .chess-square, .checkers-square { grid-template-columns: minmax(0, 1fr); }
  .chess-square::before, .checkers-square::before {
    content: "";
    grid-area: 1 / 1;
    justify-self: stretch;
    padding-top: 100%;
  }
  .chess-square .chess-piece, .checkers-square .checker,
  .checkers-square.legal:empty::after { grid-area: 1 / 1; }
}
.chess-square.dark, .checkers-square.dark { background: #668575!important; }
.checkers-square { padding: 0; grid-template-columns: minmax(0,1fr); grid-template-rows: minmax(0,1fr); }
.checker { width: 72%; height: auto; aspect-ratio: 1; border-width: 2px; }
.chess-square.legal, .checkers-square.legal { box-shadow: inset 0 0 0 3px #72e5b4; }
.chess-square.selected { box-shadow: inset 0 0 0 3px #f4ce7c; }
.board-coordinate { font-size: 10px; right: 3px; bottom: 1px; color: #233d33; line-height: 1.1; }
.chess-square.dark .board-coordinate { color: #f3fae9; }
.chess-piece { width: 81%; height: 81%; }
.chess-actions { border-top: 1px solid var(--line); padding-top: 14px; }
.chess-actions button { font-size: 12px; min-height: 36px; }
.answer-result:empty { display: none; }
.race-prompt, .speaking-prompt { background: #142b32; border-color: #365760; border-radius: 10px; padding: 24px; }
.race-prompt h3, .speaking-prompt h3 { color: #e9f4ef; font-weight: 600; }
.eyebrow { letter-spacing: .09em; font-weight: 600; }
.answer-form { margin-top: 16px; gap: 10px; }
.answer-form label { font-size: 13px; min-width: 0; }
.score-chip { background: #192e38; border-color: #3d5964; border-radius: 7px; font-size: 12px; }
.memory-board { max-width: 600px; margin: 18px auto; }
.memory-card { border-radius: 9px; aspect-ratio: 1.2; }
.memory-card.hidden { background: #1a3c48; border-color: #4a7480; }
.memory-card.hidden:hover:enabled { background: #25515c; border-color: #7acbbd; }
.memory-card.revealed { background: #edf1e5; }
.memory-card.matched { background: #25483e; }
.tic-tac-toe-cell { background: #1b303d; border-color: #405f71; }
.felt-table { background: #185344; border: 3px solid #637566; border-radius: 14px; box-shadow: inset 0 1px 12px #092a2933; }
.table-rules { font-size: 13px; }
.table-rules summary { color: var(--blue); padding: 5px 0; }
.table-player { border-radius: 8px; background: #192d38; font-size: 12px; }
.table-player.active { background: #1c443b; border-color: #66c8ad; box-shadow: none; }
.poker-table { background: #174639; border-color: #42695b; border-radius: 12px; }
.poker-player { background: #15372f; border-color: #456b5d; }
.poker-player.current { background: #2b4e3e; }
.playing-card.card-back { background: #254e60; }
.playing-piece.table-card { display: flex; flex-direction: column; justify-content: space-between; align-items: center; width: 64px; height: 92px; padding: 7px!important; font-weight: 600; }
.table-card .playing-card-rank { font-size: 20px; }
.table-card .playing-card-suit { width: 34px; height: 40px; }
.table-card .rank-choice { margin: auto; font-size: 25px; }
.table-board .playing-piece:disabled { opacity: 1; }
.table-clue { font-size: 16px; line-height: 1.6; margin: 12px 0 0; }
#tableNotice { font-size: 13px; line-height: 1.65; }
.people-panel, .chat-panel { padding: 16px; }
.people-panel h2, .chat-panel h2 { font-size: 15px; }
.people-panel .section-heading { margin-bottom: 5px; }
.player-list li { padding: 10px 0; gap: 9px; }
.avatar { width: 30px; height: 30px; background: #28463f; color: #c7f3e5; border: 1px solid #3c6258; font-size: 12px; }
.player-name { font-size: 13px; }
.player-info small { font-size: 11px; }
.player-list .remove-player { font-size: 11px; opacity: .85; padding: 4px 6px; }
.chat-panel .section-heading { padding-bottom: 13px; margin-bottom: 0; border-bottom: 1px solid var(--line); }
.chat-panel .section-heading p { font-size: 12px; }
.chat-messages { height: 260px; padding: 14px 0 4px; scrollbar-gutter: stable; }
.chat-message { padding: 9px 11px; border: 1px solid #354c5a; background: #203440; border-radius: 9px 9px 9px 2px; margin: 0 18px 12px 0; }
.chat-message.own-message { margin: 0 0 12px 18px; background: #1a3c37; border-color: #385f55; border-radius: 9px 9px 2px 9px; }
.chat-message.character-message { border-inline-start: 2px solid var(--green); }
.chat-message strong { color: #d4e9eb; font-size: 11px; font-weight: 600; }
.chat-message time { font-size: 10px; color: #a4bac4; }
.chat-message .caption-line { font-size: 14px; line-height: 1.65; margin-bottom: 0; }
.chat-message .caption-word { font-weight: 400; }
.chat-message .translate-message { min-height: 26px; font-size: 11px; margin-top: 3px; }
.chat-message .chat-translation { font-size: 13px; padding: 6px 9px; background: #183b3d; border-color: #74baac; }
.chat-messages .empty { font-size: 13px; text-align: center; padding: 48px 16px; margin: 0; color: #a9bdc9; }
.chat-language { flex-direction: row; font-size: 12px; margin: 12px 0 10px; }
.chat-language select { min-height: 34px; padding: 6px 8px; font-size: 12px; }
.chat-composer { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; }
.chat-composer .chat-form { display: contents; }
.chat-composer textarea { grid-column: 1 / -1; }
.chat-composer .chat-form>button { grid-column: 2; grid-row: 2; }
.chat-composer>audio, .chat-composer>p { grid-column: 1 / -1; }
.chat-form textarea { min-height: 64px; font-size: 13px; }
.chat-form button { min-height: 36px; font-size: 13px; margin: 0 0 0 auto; padding: 7px 17px; }
.chat-voice-controls { grid-column: 1; grid-row: 2; margin: 0; width: auto; gap: 7px; }
.chat-voice-controls button { min-height: 36px; padding: 7px 10px; font-size: 12px; }
.chat-voice-controls:has(#sendChatVoice:not([hidden])) { grid-column: 1 / -1; grid-row: 3; width: auto; margin: 0; }

#chatVoiceStatus, .chat-note { font-size: 11px; line-height: 1.65; margin: 10px 0 0; }
.chat-note { border-top: 1px solid var(--line); padding-top: 10px; color: #a2b8c5; }
.chat-message audio, #chatVoicePreview { height: 36px; margin-top: 8px; }
.watch-controls, .captions-section { padding: 18px; }
.watch-controls p, .caption-source p { font-size: 12px; line-height: 1.65; }
.caption-source { background: #162b37; border-radius: 9px; }
.screen-placeholder { max-width: 450px; }
.screen-placeholder>span { margin-bottom: 16px; }
.screen-placeholder .ui-icon { width: 48px; height: 48px; color: #819eac; }
.screen-placeholder h2 { font-size: 20px; }
.screen-placeholder p { font-size: 13px; }
.screen-stage { background: #080f17; }
.link-video-stage { position: relative; width: 100%; min-height: 0; background: #080f17; border: 1px solid var(--line); border-radius: 9px; }
.link-video-placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 16px; text-align: center; color: #a6becb; pointer-events: none; }
.link-video-placeholder .ui-icon { width: 38px; height: 38px; }
.link-video-placeholder p { font-size: 13px; margin: 0; }
#videoPanel>p { font-size: 12px; line-height: 1.65; }
#videoStatus { color: #d6e5e9; }
.speaking-record-controls button, .speaking-submit-controls button, .speaking-host-controls button { font-size: 13px; }
.speaking-privacy, .speaking-transcription-note, .speaking-check-note, .speaking-record-controls span { font-size: 12px; line-height: 1.65; }
.speech-preview { background: #17352f; border-color: #3d6759; }
.speech-submission { border-color: #354a55; }
dialog { padding: 24px; border-radius: 12px; border-color: #506b79; box-shadow: 0 20px 80px #0008; }
dialog::backdrop { background: #030a12b3; }
.dialog-heading h2 { font-size: 20px; }
.dialog-heading button { width: 34px; min-height: 34px; padding: 0; background: var(--raised); }
.word-meaning { font-size: 20px; color: #9de6d0; }
.word-definitions { font-size: 14px; line-height: 1.7; }
.page-footer { margin-top: 28px; padding: 18px 0; color: #8da4b3; font-size: 11px; }
body[data-desktop=true] .together-shell { padding: 0 16px; }
body[data-desktop=true] .page-header { padding: 10px 0; min-height: 52px; }
body[data-desktop=true] .setup-panel { padding: 18px; margin-top: 16px; }
body[data-desktop=true] .room-identity strong { font-size: 20px; }
body[data-desktop=true] .room-code { display: block; }
body[data-desktop=true] .activity-groups { margin-bottom: 16px; }
@media (min-width: 1550px) { .together-shell { padding: 0 28px; } .room-layout { grid-template-columns: minmax(0,1fr) 320px; } }
@media (max-width: 1100px) {
  .room-layout { grid-template-columns: minmax(0,1fr) 292px; gap: 16px; }
  .activity-bar { flex-wrap: wrap; }
  .activity-bar>span { order: 3; flex-basis: 100%; }
  .activity-bar label { flex: 1; }
  .activity-bar select { min-width: 0; flex: 1; }
  .mode-card, body[data-desktop=true] .mode-card { min-height: 82px; }
  .activity-groups label { padding: 11px; column-gap: 8px; }
  .activity-groups strong { font-size: 13px; }
  .activity-groups small { font-size: 11px; }
}
@media (max-width: 900px) {
  .room-layout { grid-template-columns: minmax(0,1fr); }
  .room-sidebar { grid-template-columns: 1fr; }
  .chat-messages { height: 300px; }
  .setup-actions { gap: 16px; }
  .create-controls { flex: .85; }
  .join-controls { padding-left: 16px; }
  .mode-card, body[data-desktop=true] .mode-card { gap: 3px 9px; padding: 12px; }
}
@media (max-width: 600px) {
  .together-shell, body[data-desktop=true] .together-shell { padding: 0 14px; }
  .page-header { min-height: 62px; padding: 12px 0; gap: 8px; }
  .brand { font-size: 18px; gap: 7px; }
  .brand-mark { width: 25px; height: 27px; font-size: 13px; }
  .page-header nav { gap: 10px; font-size: 12px; }
  #studioLink { display: none; }
  #connectionBadge { max-width: 100px; font-size: 11px; }
  #accountLink { padding: 6px 9px; }
  .page-heading { margin: 22px 0 18px; }
  h1 { font-size: 30px; }
  .lede { font-size: 14px; max-width: 320px; }
  .setup-panel, body[data-desktop=true] .setup-panel { padding: 16px 14px; }
  #setupIntro h2 { font-size: 15px; }
  .activity-groups { gap: 7px; margin-bottom: 18px; }
  .activity-groups label { display: flex; align-items: center; padding: 11px 5px; gap: 5px; text-align: center; }
  .activity-groups .ui-icon { width: 21px; height: 21px; }
  .activity-groups strong { font-size: 12px; line-height: 1.4; }
  .activity-groups small { display: none; }
  .language-fields { gap: 10px; }
  .language-fields label { font-size: 12px; }
  .language-fields select { font-size: 13px; }
  .mode-picker { grid-template-columns: minmax(0,1fr); gap: 8px; }
  .mode-card, body[data-desktop=true] .mode-card { min-height: 76px; padding: 11px 12px; }
  .mode-card[data-group=watch] { grid-column: auto; }
  .mode-card strong { font-size: 14px; }
  .mode-card small { font-size: 12px; }
  .setup-actions { flex-direction: column; align-items: stretch; gap: 18px; }
  .create-controls, .join-controls { flex: none; gap: 10px; }
  .create-controls button, .join-controls button { font-size: 13px; width: auto; }
  .join-controls { padding: 16px 0 0; border: 0; border-top: 1px solid var(--line); }
  .setup-footnote { font-size: 11px; }
  .room-toolbar, body[data-desktop=true] .room-toolbar { gap: 14px; padding: 16px 0; margin-bottom: 16px; }
  .room-identity strong { font-size: 22px; }
  .toolbar-actions { width: 100%; }
  .toolbar-actions button { flex: 1; font-size: 13px; min-height: 44px; }
  .room-code { font-size: 10px; }
  .activity-bar, body[data-desktop=true] .activity-bar { padding: 11px; gap: 10px; }
  .activity-bar label { font-size: 12px; }
  .activity-bar button { font-size: 12px; }
  .game-panel, body[data-desktop=true] .game-panel { padding: 16px 13px; }
  .game-panel h2 { font-size: 18px; }
  .game-panel .section-heading { gap: 10px; margin-bottom: 14px; }
  .section-heading p { font-size: 12px; }
  .game-lobby { gap: 10px; }
  .game-lobby p { font-size: 12px; }
  .board-coordinate { font-size: 8px; }
  .chess-board, .checkers-board, body[data-desktop=true] .chess-board { margin: 14px auto; }
  .chess-actions button { font-size: 12px; }
  .player-list { grid-template-columns: 1fr; }
  .player-list li:nth-child(2) { border-top: 1px solid var(--line); }
  .people-panel, .chat-panel { padding: 16px; }
  .chat-messages { height: 260px; }
  .chat-voice-controls button, .chat-form button { min-height: 44px; }
  .memory-card { aspect-ratio: .92; }
  .playing-piece.table-card { width: 52px; height: 78px; }
  .table-card .playing-card-suit { width: 28px; height: 32px; }
  .answer-form { gap: 8px; }
  .answer-form button { font-size: 12px; padding: 9px 11px; }
  .answer-form input { font-size: 14px; }
  .drawing-tools { flex-wrap: wrap; }
  .watch-controls, .captions-section { padding: 16px; }
  .caption-preferences button { font-size: 12px; }
  .manual-caption { flex-wrap: wrap; }
  .manual-caption label { flex-basis: 100%; }
  .manual-caption button { width: 100%; }
  .screen-placeholder h2 { font-size: 18px; }
  .screen-placeholder p { font-size: 12px; }
  .race-prompt, .speaking-prompt { padding: 20px 15px; }
  .speaking-host-controls form { flex-wrap: wrap; }
  .speaking-host-controls input { min-width: 0; }
  dialog { padding: 20px; }
  .page-footer { font-size: 10px; gap: 8px; }
}

/* Keep the selected activity and primary action discoverable in a long phone lobby. */
.lounge-welcome { display: grid; grid-template-columns: 1.05fr 1fr; align-items: center; gap: 22px; margin: 4px 0 22px; border-bottom: 1px solid var(--line); padding-bottom: 20px; }
.lounge-welcome .eyebrow { margin-bottom: 8px; }
.lounge-welcome h2 { font-size: clamp(19px,2.3vw,26px); line-height: 1.25; margin-bottom: 9px; }
.lounge-welcome p:last-child { font-size: 13px; color: var(--muted); margin: 0; max-width: 38ch; }
.lounge-welcome img { width: 100%; height: auto; max-height: 174px; object-fit: cover; border-radius: 10px; }
.activity-groups { grid-template-columns: repeat(4,minmax(0,1fr)); }
.activity-groups label { grid-template-columns: 44px minmax(0,1fr); padding: 12px 10px; min-width: 0; }
.activity-groups .category-art { grid-row: 1 / 3; align-self: center; width: 44px; height: 44px; }
.activity-groups label:has(input:focus-visible) { outline: 2px solid var(--green); outline-offset: 3px; }
.selected-activity-summary { padding: 14px 16px; border: 1px solid #38564f; border-left: 3px solid var(--green); border-radius: 9px; background: #122a29; margin: 0 0 20px; }
.selected-activity-summary > div { display: flex; align-items: baseline; flex-wrap: wrap; gap: 5px 12px; }
.selected-activity-summary .eyebrow { flex-basis: 100%; font-size: 10px; margin: 0; }
.selected-activity-summary strong { font-size: 16px; }
.selected-activity-summary .muted { font-size: 12px; }
.selected-activity-summary p { font-size: 12px; margin: 6px 0 0; color: #c8d9d7; }
.activity-bar { flex-wrap: wrap; }
.room-activity-widget { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; flex-basis: 100%; order: 5; padding: 8px 0 2px; font-size: 12px; }
.room-activity-widget a { margin-left: auto; text-underline-offset: 3px; }
#roomChatPanel { scroll-margin-top: 16px; }
.casino-rules { font-size: 12px; color: var(--muted); margin: 0 0 16px; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; }
.casino-rules summary { color: #d9e9e4; font-weight: 600; cursor: pointer; }
.casino-rules summary:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.casino-rules p { margin: 8px 0 0; }
.blackjack-felt { background: #123a32; border: 1px solid #376b5d; border-radius: 16px; padding: 18px; }
.blackjack-zone { text-align: center; padding: 10px 0 16px; }
.blackjack-zone + .blackjack-zone { border-top: 1px solid #426b5d; padding-top: 18px; }
.blackjack-zone h3 { font-size: 14px; margin: 0 0 3px; color: #e5f4ec; }
.blackjack-zone > .muted { font-size: 12px; color: #b7cfc5; }
.blackjack-zone > strong { font-size: 19px; color: #f3ddb1; }
.blackjack-actions { display: flex; gap: 10px; margin: 16px 0; }
.blackjack-actions button { min-height: 46px; flex: 1; }
.blackjack-players { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; margin: 18px 0; }
.blackjack-player { display: flex; flex-direction: column; gap: 3px; min-width: 0; padding: 11px 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--field); overflow-wrap: anywhere; }
.blackjack-player.active { border-color: #d3ba7a; box-shadow: inset 3px 0 #d3ba7a; }
.blackjack-player strong { font-size: 13px; }
.blackjack-player span, .blackjack-player small { font-size: 12px; }
.blackjack-result-cards { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 7px; }
.blackjack-result-cards .playing-card { width: 35px; height: 53px; padding: 4px; }
.blackjack-result-cards .playing-card-rank { font-size: 12px; }
.blackjack-results { padding: 12px 14px; border: 1px solid #486b5e; border-radius: 9px; background: #15332d; margin: 0 0 16px; }
.blackjack-results p { font-size: 13px; margin: 2px 0; }
#blackjackNotice { font-size: 12px; margin: 14px 0 0; }
@media (max-width: 1000px) {
  .activity-groups { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 600px) {
  .lounge-welcome { display: flex; flex-direction: column; align-items: stretch; gap: 12px; margin-bottom: 18px; padding-bottom: 16px; }
  .lounge-welcome img { max-height: 100px; object-position: center; }
  .lounge-welcome h2 { font-size: 20px; }
  .activity-groups label { display: grid; grid-template-columns: 35px minmax(0,1fr); text-align: left; padding: 10px 8px; gap: 2px 8px; }
  .activity-groups .category-art { width: 35px; height: 35px; }
  .activity-groups strong { font-size: 12px; }
  .activity-groups small { display: block; font-size: 10px; line-height: 1.4; }
  .selected-activity-summary { padding: 12px; }
  .room-activity-widget { gap: 7px 10px; }
  .room-activity-widget a { margin-left: 0; flex-basis: 100%; min-height: 34px; display: inline-flex; align-items: center; }
  .blackjack-felt { padding: 10px; }
  .blackjack-actions { flex-direction: column; }
  .blackjack-players { gap: 7px; }
  .blackjack-player { padding: 10px; }
  .casino-panel .section-heading { flex-wrap: wrap; }
}
.mobile-room-action { display: none; }
@media (max-width: 600px) {
  .mobile-room-action { position: sticky; top: 8px; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; margin: 0 0 18px; border: 1px solid var(--line); border-radius: 12px; background: #10212b; box-shadow: 0 5px 18px #0005; }
  .mobile-room-action[hidden] { display: none; }
  .mobile-room-action > div { min-width: 0; }
  .mobile-room-action small, .mobile-room-action strong { display: block; }
  .mobile-room-action small { color: var(--muted); font-size: 10px; margin-bottom: 3px; }
  .mobile-room-action strong { font-size: 13px; overflow-wrap: anywhere; }
  .mobile-room-action button { flex: none; min-height: 44px; padding: 9px 12px; font-size: 12px; }
}

/* Guest viewing is local presentation only; the captured source never changes. */
.watch-view-controls{display:flex;align-items:center;gap:12px;margin:12px 0;flex-wrap:wrap}
.watch-view-controls[hidden]{display:none}
.guest-screen-only .room-layout{grid-template-columns:minmax(0,1fr)}
.guest-screen-only .room-sidebar,.guest-screen-only .room-language-context,.guest-screen-only .activity-bar,.guest-screen-only .captions-section,.guest-screen-only #publicNameForm,.guest-screen-only .page-heading,.guest-screen-only .page-footer{display:none}
.guest-screen-only .screen-stage{min-height:50vh}
.guest-screen-only #sharedVideo{max-height:80vh;object-fit:contain}

/* Keep guest navigation and media inside narrow and initial viewports. */
.watch-view-buttons{display:flex;align-items:center;gap:8px;flex-wrap:wrap;min-width:0}
.watch-view-buttons button[aria-pressed=true]{background:#70dcca;color:#09242a;border-color:#70dcca}
.room-layout>*,.activity-column,.screen-stage,.watch-panel{min-width:0;box-sizing:border-box}
.screen-stage{width:100%;overflow:hidden}#sharedVideo{width:100%;max-width:100%;height:auto;object-fit:contain}
.guest-screen-only .screen-stage{min-height:0;aspect-ratio:16/9;max-height:calc(100dvh - 190px)}
.guest-screen-only #sharedVideo{height:100%;max-height:calc(100dvh - 190px);object-fit:contain}
@media(max-width:600px){.watch-view-controls{gap:8px;margin:8px 0}.guest-screen-only .screen-stage{max-height:65dvh}.room-toolbar{flex-wrap:wrap}.toolbar-actions{flex-wrap:wrap}}

.simple-sharing #loungeWelcome,.simple-sharing #activityGroups,.simple-sharing #activityPicker,.simple-sharing #selectedActivitySummary,.simple-sharing #setupConceptExample,.simple-sharing #setupPolicyBadge,.simple-sharing #drawingBankNote,.simple-sharing #quickCreateControls,.simple-sharing #setupDivider,.simple-sharing #screenLimitHint{display:none!important}
.simple-sharing:not(.share-invitation) #joinForm{display:none}
.simple-sharing .room-links > a:not(#accountLink),.simple-sharing #connectionBadge{display:none}
.share-host-help { margin: 12px 0 0; max-width: 64ch; }
.share-host-help strong { color: var(--text); }
.capture-error { flex-basis: 100%; margin: 0; color: var(--danger); font-size: .85rem; }
.simple-sharing.share-invitation .share-host-help { display: none; }

/* Guest language tools use the phone viewport, not a full-height movie lobby. */
.guest-tools-open .together-shell{padding:0 12px}
.guest-tools-open .page-header{padding:8px 0;gap:8px}
.guest-tools-open .page-heading,.guest-tools-open .page-footer{display:none}
.guest-tools-open .brand{font-size:15px}.guest-tools-open .brand-mark{width:24px;height:26px}
.guest-tools-open #publicNameForm{display:flex;flex-direction:row;align-items:center;flex-wrap:wrap;gap:6px;margin:8px 0;padding:7px;border-radius:7px;min-height:0}
.guest-tools-open #publicNameForm label{display:flex;flex-direction:row;align-items:center;gap:6px;flex:1 1 170px;min-width:0;font-size:12px}
.guest-tools-open #publicNameForm input{flex:1;min-width:0;width:100%}
.guest-tools-open #publicNameForm button{flex:0 0 auto;width:auto;padding:6px 10px}
.guest-tools-open #publicNameHelp{flex-basis:100%;font-size:11px;line-height:1.3;margin:0}
.guest-tools-open button,.guest-tools-open input,.guest-tools-open select{min-height:36px;padding:6px 9px;font-size:12px}
.guest-tools-open .room-toolbar{gap:6px;margin:0 0 8px;padding:7px 0}
.guest-tools-open .room-identity strong{font-size:15px}.guest-tools-open .room-code{font-size:11px}
.guest-tools-open .toolbar-actions{display:flex;flex-wrap:wrap;gap:6px;width:auto;flex:1 1 auto;justify-content:flex-end}
.guest-tools-open .toolbar-actions button{flex:0 0 auto;min-height:36px;font-size:12px;padding:6px 9px}
.guest-tools-open .invitation-share{padding-top:6px;display:flex;gap:6px;flex-wrap:wrap}
.guest-tools-open .invitation-share label{flex:1 1 140px;min-width:0;font-size:11px;gap:3px}
.guest-tools-open .invitation-share input{font-size:11px;padding:4px 7px;min-height:32px}
.guest-tools-open .invitation-share p{margin:0;font-size:11px}
.guest-tools-open .watch-view-controls{gap:6px;margin:6px 0;padding:5px 0}
.guest-tools-open .watch-view-buttons{gap:5px}.guest-tools-open #watchViewHint{font-size:11px}
.guest-tools-open .room-language-context{padding:7px 9px;margin:0 0 8px;font-size:12px}
.guest-tools-open .room-language-context p{margin:3px 0;font-size:11px}
.guest-tools-open .room-layout{gap:10px}.guest-tools-open .room-sidebar{margin-top:0}
.guest-tools-open .screen-stage{min-height:0;aspect-ratio:16/9;max-height:min(28dvh,220px)}
.guest-tools-open #sharedVideo{height:100%;max-height:min(28dvh,220px);object-fit:contain}
.guest-tools-open .watch-panel,.guest-tools-open .captions-section,.guest-tools-open .chat-panel,.guest-tools-open .people-panel{padding:10px}
.guest-tools-open .captions-section{margin-top:8px}.guest-tools-open .section-heading{margin-bottom:8px;gap:6px}
.guest-tools-open .chat-messages{height:150px;min-height:70px}
.guest-tools-open .caption-preferences,.guest-tools-open .chat-voice-controls{gap:5px;flex-wrap:wrap}
.guest-tools-open .caption-preferences button,.guest-tools-open .chat-form button,.guest-tools-open .chat-voice-controls button{min-height:36px}
@media(max-width:600px){
 .guest-tools-open button,.guest-tools-open input,.guest-tools-open select,.guest-tools-open .toolbar-actions button,.guest-tools-open .caption-preferences button,.guest-tools-open .chat-form button,.guest-tools-open .chat-voice-controls button{min-height:44px}
 .guest-tools-open .room-toolbar{align-items:center}.guest-tools-open .toolbar-actions{justify-content:flex-start}
 .guest-tools-open .room-layout{grid-template-columns:minmax(0,1fr)}
 .guest-tools-open .manual-caption{gap:5px}.guest-tools-open .manual-caption label{flex-basis:100%}.guest-tools-open .manual-caption button{width:auto}
}

/* Hold-to-record stays under the finger until release; never starts on room entry. */
#recordChatVoice { touch-action: none; user-select: none; -webkit-user-select: none; min-width: 38px; font-size: 18px; }
#recordChatVoice[aria-pressed="true"] { background: #883641; border-color: #dc6b77; color: #fff; }
#sendChatVoice, #discardChatVoice { min-width: 38px; font-size: 17px; }

.guest-tools-open .room-sidebar{display:flex;flex-direction:column;gap:10px}
.guest-tools-open .room-sidebar .chat-panel{order:0}.guest-tools-open .room-sidebar .people-panel{order:1}
.guest-tools-open .chat-messages{height:100px;min-height:60px;margin:0 0 8px}
.guest-tools-open .chat-language{display:flex;flex-direction:row;align-items:center;gap:6px;font-size:12px;margin:0 0 6px}
.guest-tools-open .chat-language select{flex:1;min-width:0}
.guest-tools-open .chat-form{gap:6px}.guest-tools-open .chat-form textarea{font-size:13px;min-height:44px;padding:6px 8px}
.guest-tools-open .chat-note{display:none}.guest-tools-open #chatVoiceStatus{font-size:11px;line-height:1.35;margin:5px 0 0}

/* One room has independent screen broadcasting and a hosted activity. */
.room-workspace-hub{display:grid;gap:8px;margin:10px 0;padding:10px 12px}
.room-workspace-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap;min-width:0}
.room-workspace-row button,.room-workspace-row select{height:36px;min-height:36px;padding:5px 10px;font-size:13px}
.room-workspace-tabs{border-bottom:1px solid var(--line);padding-bottom:8px}
.room-workspace-tabs button{flex:0 1 auto;min-width:0}
.room-workspace-watch .room-play-options,.room-workspace-play .room-watch-options{display:none}
.guest-screen-only .room-workspace-hub:not(:has(#roomPlayWorkspace:not([hidden]))){display:none}
.room-play-options{align-items:flex-end}
.room-watch-options #roomCaptureStatus{flex:1 1 110px}
.room-workspace-row button[aria-pressed=true]{background:#70dcca;color:#09242a;border-color:#70dcca}
.room-workspace-row #modeControl{flex:1 1 150px;min-width:0;margin:0;font-size:12px}
.room-play-options:has(#modeControl:not([hidden])) #roomWorkspaceStatus{display:none}
.room-workspace-row #roomMode{width:100%;min-width:0}.room-workspace-row [role=status]{font-size:12px;overflow-wrap:anywhere}
#roomRoleStatus{margin:0;font-size:11px;line-height:1.4}
.room-workspace-watch .game-panel,.room-workspace-watch .game-setup{display:none!important}
.room-workspace-watch #videoPanel:not([hidden]){display:block!important}
.room-workspace-play .watch-panel .captions-section{display:none}
.room-workspace-play .watch-panel .screen-stage{min-height:0;max-height:180px;aspect-ratio:16/9}
.room-workspace-play .watch-panel #sharedVideo{height:100%;max-height:180px;object-fit:contain}
@media(max-width:600px){.room-workspace-hub{padding:8px}}

/* The central room source action is the only browser capture entry. */
#screenHostControls #shareScreen{display:none}


/* Watching keeps the actual video and language tools ahead of duplicate game explanations. */
.room-workspace-watch .activity-bar,.room-workspace-watch .room-language-context{display:none}

/* Existing membership recovery stays inline with compact, fixed-height actions. */
.room-recovery{padding:12px;border:1px solid #4d7485;border-radius:8px;background:#182e3c;color:#e4edf4;margin:8px 0;overflow-wrap:anywhere}
.room-recovery p{margin:6px 0 10px;font-size:13px;line-height:1.4}
.room-recovery-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
.room-recovery-actions button{flex:0 0 auto!important;width:auto!important;min-height:34px!important;height:34px!important;max-height:34px!important;padding:5px 10px!important;font-size:13px!important;line-height:22px!important}
.room-recovery-actions button:first-child{border-color:#70dcca;color:#bff5e8}

/* Invitations ask for one deliberate join; account/guest identity is automatic. */
.room-invitation #joinForm{display:flex;align-items:center;flex-wrap:wrap;gap:8px;width:100%}
.room-invitation #joinRoom{flex:0 0 auto;min-height:42px;max-height:46px;padding:8px 18px;font-size:15px}
.room-invitation #cancelInvitation{flex:0 0 auto;min-height:36px;padding:6px 10px;font-size:13px}

.room-invitation .page-heading{display:none}
.room-invitation #publicNameForm{display:grid!important;grid-template-columns:minmax(0,1fr) 36px 36px!important;align-items:center!important;gap:6px!important;padding:10px;margin:12px 0}
.room-invitation #publicNameForm label{min-width:0;margin:0;display:flex;align-items:center;gap:8px;font-size:13px}
.room-invitation #publicNameForm input{width:100%;min-width:0;min-height:38px;height:38px;padding:6px 8px}
.room-invitation #publicNameForm button{width:36px!important;height:36px!important;min-height:36px!important;max-height:36px!important;flex:none!important;padding:4px!important;font-size:17px}
.room-invitation #publicNameHelp{grid-column:1/-1;font-size:12px;line-height:1.35}

.room-invitation #joinForm:has(#joinCodeField:not([hidden])){align-items:flex-end}
.character-seats { padding: 20px; }
.character-seats .drawing-tools { align-items: end; flex-wrap: wrap; }
.character-seats label { flex: 1 1 140px; min-width: 0; }
.character-seats select { max-width: 100%; width: 100%; }
.character-portrait { display: inline-block; width: 64px; height: 64px; border-radius: 14px; background-color: #152b3e; flex: none; }
.character-seats details { margin-top: 12px; font-size: .88rem; color: var(--muted); }
.character-seats summary { cursor: pointer; }
.avatar[data-character-id] { background-color: #152b3e; background-repeat: no-repeat; }
.spectator-panel { padding:20px; }
.spectator-panel .drawing-tools { flex-wrap:wrap; gap:10px; }
.spectator-panel .section-heading { flex-wrap:wrap; gap:12px; }
.player-list li { flex-wrap:wrap; }
.player-list .player-info { min-width:100px; }
.player-list .seat-invite { font-size:12px; padding:8px 10px; margin-left:auto; }
#joinRoleField { min-width:180px; }
#incomingSeatOffer { margin-top:16px; }
.partner-task-card { overflow-wrap: anywhere; }
.partner-task-card p { font-size: 1rem; }
.partner-task-card ul { margin: 10px 0 0; padding-inline-start: 1.25em; font-variant-numeric: tabular-nums; }
.partner-task-form { flex-wrap: wrap; align-items: end; }
.partner-task-form label { flex: 1 1 180px; }
.partner-task-form button { white-space: normal; }
#partnerTaskResult.partner-task-error { color: var(--danger); }

.game-conversation{margin:6px 0;padding:6px 9px;border:1px solid var(--line);border-radius:8px}
.game-conversation summary{cursor:pointer;padding:4px 2px;font-weight:650;min-height:32px}
.game-conversation p{margin:3px 2px 6px;line-height:1.45}
