.grimoire-page{margin:0;background:#1e2934;color:#eee9dd;color-scheme:dark;font-family:system-ui,-apple-system,"Segoe UI",sans-serif}
.g-dialog:not([open]){display:none}
.g-seat-token{position:relative;display:block;flex:none;min-width:0;padding:0;border:0;border-radius:50%;background:transparent;color:inherit;cursor:pointer;touch-action:inherit}.g-seat .g-seat-name{min-height:28px;color:#f8f5ec;font-size:14px;cursor:pointer;user-select:none;touch-action:manipulation}.g-seat .g-seat-name:hover{background:#4a535be6;border-color:#e8d29a}.g-seat .g-vote,.g-seat .g-alignment{pointer-events:none}
@media(max-width:700px){.g-seat .g-seat-name{font-size:11px}}
@media(max-width:360px){.g-seat .g-seat-name{font-size:10px}}
@media(max-height:600px) and (min-width:701px){.g-seat .g-seat-name{font-size:11px}}
@media(pointer:coarse){.g-seat .g-seat-name{min-height:32px}}
.grimoire-page>.site-header,.grimoire-page>.sidebar,.grimoire-page>footer{display:none!important}.grimoire-page main.content{margin:0!important;padding:0!important;max-width:none!important;width:100%!important;border:0!important;background:none!important;box-shadow:none!important}
.g-app{--g-surface:#222a30;--g-border:#697078;--g-gold:#f2d381;--g-muted:#bac3c9;position:relative;height:var(--g-viewport-height,100dvh);min-height:520px;isolation:isolate;overflow:hidden;background:#344353 url("../../theme/bg_day.png") center center/cover no-repeat;color:#f2eee6}
.g-app:not([data-ready=true]){background-image:none}
.g-app:before{content:"";position:absolute;inset:0;background:url("../../theme/bg_night.png") center center/cover no-repeat;opacity:0;pointer-events:none;z-index:-2}
.g-app[data-scene-transition=true]:before{transition:opacity 360ms ease}
.g-app[data-phase=night]:before{opacity:1}
.g-app:after{content:"";position:absolute;inset:0;background:url("../../theme/clouds.png") center center/cover no-repeat;opacity:.16;mask-image:linear-gradient(180deg,#000,#0004 32%,transparent 48%,#0003 68%,#000);pointer-events:none;z-index:-1}
.g-app[data-phase=night]:after{opacity:.08}
@media print{.g-app:after{display:none!important}}
.g-app *{box-sizing:border-box}.g-app [hidden]{display:none!important}.g-app button,.g-app input,.g-app select,.g-app textarea{font:inherit}.g-app button,.g-app a,.g-dialog button,.g-dialog input,.g-dialog select,.g-dialog textarea{touch-action:manipulation}
.g-sr-only{position:absolute!important;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;margin:0!important;padding:0!important}
.g-button{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:40px;padding:8px 12px;border:1px solid #ffffff1f;border-radius:6px;background:#454c52;color:#f3f0e9;text-decoration:none;cursor:pointer;font-size:14px;font-weight:550}.g-button:hover{background:#59616a}.g-button:disabled{opacity:.4;cursor:default}.g-button.primary{background:#e4c579;color:#242019;border-color:#ead59f;font-weight:700}.g-button.danger{color:#ffb5b3;border-color:#815654}.g-button.subtle{background:transparent}.g-button[aria-pressed=true]{background:#5a5550;border-color:#d8bc75}.g-app :focus-visible,.g-dialog :focus-visible{outline:3px solid #f4da96;outline-offset:3px}
.g-board{position:absolute;inset:0;overflow:hidden}.g-center{position:absolute;left:50%;top:var(--g-logo-y,50%);width:var(--g-logo-width,280px);height:var(--g-logo-height,224px);display:grid;place-items:center;transform:translate(-50%,-50%);pointer-events:none;z-index:0;overflow:hidden;filter:drop-shadow(0 3px 5px #0008)}.g-center img{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none}.g-center[data-fallback=true] img{transform:scale(1.8)}.g-board.list-mode .g-center{display:none}.g-seats{position:absolute;inset:0}.g-seat{position:absolute;left:var(--x);top:var(--y);width:calc(var(--token-size,112px) + 18px);min-height:calc(var(--token-size,112px) + 38px);padding:4px;transform:translate(-50%,-50%);display:flex;align-items:center;flex-direction:column;gap:4px;border:0;background:transparent;color:#f8f5ec;cursor:pointer;touch-action:none;border-radius:50%;z-index:1;filter:drop-shadow(0 3px 3px #08111d66)}.g-seat:hover .g-token{box-shadow:0 0 0 2px #ead395,0 4px 18px #0007}.g-seat.dragging{opacity:.55}.g-seat.drop-target .g-token{outline:3px dashed #ffdf8b;outline-offset:4px}
.g-token{position:relative;display:grid;place-items:center;width:var(--token-size,112px);height:var(--token-size,112px);border:2px solid #b8a581;border-radius:50%;background:radial-gradient(circle,transparent 52%,#6c4c2d22 64%,#74552f99 90%,#241f19 100%),url("../../../assets/skin/bg.png") center/240px, #e2d3ad;box-shadow:inset 0 0 15px #533f27aa,0 3px 9px #0008;color:#514436;flex:none;overflow:hidden}.g-token:before{content:"";position:absolute;inset:9%;border:1px solid #99846250;outline:1px solid #fcf1d544;outline-offset:4px;border-radius:50%;pointer-events:none}.g-token img{position:relative;width:78%;height:78%;object-fit:contain;filter:drop-shadow(0 1px 1px #fff8);margin-top:-14%}.g-token .g-question{font-family:Georgia,serif;font-size:calc(var(--token-size,112px) * .3);color:#75654c99}.g-token.townsfolk{border-color:#a7b9ba}.g-token.outsider{border-color:#a1b7ac}.g-token.minion{border-color:#bf9c8b}.g-token.demon{border-color:#b88677}.g-token.traveller{border-color:#b1a0bc}
.g-seat.dead .g-token{filter:none;opacity:1}.g-seat-name{max-width:calc(var(--token-size,112px) + 18px);padding:1px 7px;border:1px solid #e2ded16b;border-radius:5px;background:#252c33cc;font-size:14px;line-height:1.5;font-weight:550;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-shadow:0 1px 2px #000}.g-seat-role{position:absolute;bottom:9%;width:85%;font-family:"Microsoft YaHei","微软雅黑","PingFang SC",sans-serif;font-size:clamp(11px,calc(var(--token-size,112px) * .145),18px);font-weight:800;line-height:1.2;color:#37291e;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-shadow:0 1px 1px #fff,1px 0 1px #fff,-1px 0 1px #fff}.g-seat-role.unassigned{display:none}.g-vote{position:absolute;top:8%;right:0;min-width:27px;height:27px;display:grid;place-items:center;padding:0 4px;background:#17212bee;border:1px solid #d6d2c2;color:#fff;border-radius:50%;font-size:11px;white-space:nowrap}.g-vote.used{min-width:34px;border-style:dashed;color:#c1c5c9;font-size:10px}.g-alignment{position:absolute;left:0;bottom:34px;border:1px solid #a2c4d1;background:#183f5a;color:#d9edff;border-radius:5px;padding:3px 5px;font-size:10px}.g-alignment.evil{border-color:#d7a397;background:#662c2c;color:#ffe0d6}.g-reminders{position:absolute;left:-5px;right:-5px;top:32%;display:flex;justify-content:space-between;gap:4px;pointer-events:none}.g-reminders span{display:grid;place-items:center;max-width:44px;min-width:31px;min-height:31px;padding:3px;background:#30302a;border:1px solid #c8b993;color:#fff6dc;border-radius:50%;font-size:9px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;box-shadow:0 2px 3px #0008}.g-reminders span[data-kind=poison]{background:#732a26;border-color:#b57064}.g-reminders span[data-kind=drunk]{background:#224b78;border-color:#779bc6}
.g-summary{position:absolute;top:12px;left:12px;display:flex;gap:12px;width:320px;padding:10px 13px 10px 10px;border:1px solid #a4a8a17a;border-radius:9px;background:#1e252ce6;box-shadow:0 3px 10px #0004;z-index:4;backdrop-filter:blur(9px)}.g-emblem{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:2px;flex:none;width:57px;min-height:76px;color:#dcc48d;text-decoration:none;border:1px solid #a28b5d88;background:#313940;border-radius:4px}.g-emblem svg{width:39px;height:48px}.g-emblem span{font-size:9px;color:#d7c9a8}.g-summary-body{min-width:0;flex:1}.g-app-label{font-size:9px;color:#c9c7bb;margin:0 0 3px!important;letter-spacing:.1em}.g-app-label span{letter-spacing:0;color:#a9adb1;margin-left:5px}.g-summary #gTitle{font-size:18px;color:#f3d783;padding:0;margin:0 0 4px;border:0;line-height:1.35;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.g-composition{display:flex;gap:7px;flex-wrap:wrap;font-size:11px;line-height:1.5}.g-composition .townsfolk{color:#85c9ed}.g-composition .outsider{color:#7dd3d1}.g-composition .minion{color:#eab598}.g-composition .demon{color:#f19b91}.g-composition .traveller{color:#cbb4ee}.g-counts{font-size:12px;color:#e1e2df;line-height:1.6}.g-save{font-size:9px;color:#aaaead;margin:3px 0 0!important}
.g-view-actions{position:absolute;top:12px;right:12px;display:flex;gap:6px;z-index:4}.g-view-actions .g-button{min-height:42px;background:#222a32e6;backdrop-filter:blur(8px)}.g-side-tools{position:absolute;top:116px;display:flex;flex-direction:column;gap:10px;z-index:4}.g-left-tools{left:0}.g-right-tools{right:0}.g-rail-button{display:flex;align-items:center;justify-content:center;writing-mode:vertical-rl;letter-spacing:.2em;width:38px;min-height:66px;padding:10px 9px;border:1px solid #d4d3cc3a;border-left:0;border-radius:0 6px 6px 0;background:#202830e8;color:#e5e5e0;font-size:14px;cursor:pointer;box-shadow:0 2px 6px #0003;backdrop-filter:blur(8px)}.g-right-tools .g-rail-button{border-left:1px solid #d4d3cc3a;border-right:0;border-radius:6px 0 0 6px}.g-rail-button:hover{background:#4b535a;color:#ffe4a6}.g-bluffs{position:absolute;left:0;bottom:95px;z-index:4}
.g-dock{position:absolute;right:12px;bottom:max(12px,env(safe-area-inset-bottom));width:270px;padding:10px 11px 8px;border:1px solid #b8b49b88;border-radius:9px;background:#111a22ee;box-shadow:0 4px 16px #0006;backdrop-filter:blur(10px);z-index:4}.g-control-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:0 0 7px}.g-phase{color:#f3d783;font-size:16px;line-height:1.5}.g-fold{display:grid;place-items:center;width:30px;height:28px;padding:0;border:0;border-radius:4px;background:transparent;color:#c7c6bb;font-size:23px;cursor:pointer}.g-fold:hover{background:#ffffff15}.g-primary-tools{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-bottom:6px}.g-dock .g-button{min-height:34px;padding:6px 8px;font-size:13px}.g-advance{width:100%;margin:0 0 6px}.g-seat-stepper{display:flex;align-items:center;justify-content:space-between;gap:10px;height:30px;border-radius:5px;background:#ffffff0a;color:#d2d4d2;font-size:13px}.g-step{width:40px;height:30px;padding:0;border:0;border-radius:5px;background:transparent;color:#e5e3da;font-size:21px;cursor:pointer}.g-step:hover{background:#ffffff15}.g-step:disabled{opacity:.3;cursor:default}.g-privacy{font-size:9px;color:#aaaead;margin:5px 0 0!important;line-height:1.5}.g-start-hint{position:absolute;bottom:12px;left:12px;max-width:300px;font-size:11px;color:#e0e3df;background:#19232cc9;border-radius:5px;padding:6px 9px;margin:0;z-index:3;pointer-events:none}.g-warning{position:absolute;left:50%;top:132px;transform:translateX(-50%);width:min(700px,calc(100% - 96px));padding:12px 16px;border:1px solid #c59b64;border-radius:8px;background:#483724f5;display:flex;align-items:center;gap:10px;flex-wrap:wrap;font-size:13px;z-index:8;box-shadow:0 3px 18px #0005}.g-warning span{flex:1;min-width:160px}.g-warning .g-button{background:#665035}.g-toast{position:absolute;bottom:30px;left:50%;transform:translateX(-50%);max-width:calc(100% - 100px);background:#202d2bf0;color:#f5f1e3;border:1px solid #a6af92;padding:10px 16px;border-radius:8px;font-size:13px;z-index:12;pointer-events:none}.g-toast:empty{display:none}.grimoire-page [data-site-update]{z-index:30!important}
.g-board.list-mode{inset:132px 58px 20px;overflow:auto;padding:8px 16px 210px;overscroll-behavior:contain;border-radius:10px;background:#17233266;backdrop-filter:blur(4px)}.g-board.list-mode .g-seats{position:static;display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:12px}.g-board.list-mode .g-seat{position:relative;left:auto;top:auto;transform:none;width:100%;min-height:155px;padding:10px;background:#222d37c9;border:1px solid #bbb5a546;border-radius:9px;touch-action:pan-y}.g-board.list-mode .g-token{width:80px;height:80px}.g-board.list-mode .g-seat-role{font-size:12px}.g-board.list-mode .g-vote{right:calc(50% - 53px);top:9px}.g-board.list-mode .g-alignment{left:6px;bottom:8px}.g-board.list-mode .g-reminders{left:calc(50% - 57px);right:calc(50% - 57px);top:35px}

.g-dialog{--g-border:#465263;--g-gold:#dfc58d;color-scheme:dark;background:#202936;color:#eee9dd;border:1px solid #536176;border-radius:18px;padding:0;width:min(700px,calc(var(--g-viewport-width,100vw) - 32px));max-width:calc(var(--g-viewport-width,100vw) - 24px);max-height:calc(var(--g-viewport-height,100dvh) - 32px);box-shadow:0 20px 80px #0008}.g-dialog::backdrop{background:#080d16b8;backdrop-filter:blur(4px)}.g-modal-head{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:18px 22px;border-bottom:1px solid #465263;position:sticky;top:0;background:#202936;z-index:2}.g-modal-head h2{margin:0;font-size:20px;color:#f1e5c9}.g-modal-body{padding:20px 22px;overflow:auto;overscroll-behavior:contain;max-height:calc(var(--g-viewport-height,100dvh) - 130px)}
.g-dialog label{display:flex;flex-direction:column;gap:7px;font-size:13px;color:#c6d0db;margin:0 0 15px}.g-dialog input:not([type=checkbox]),.g-dialog select,.g-dialog textarea{width:100%;min-height:44px;background:#17202b;color:#f4efdf;border:1px solid #536176;border-radius:9px;padding:10px 12px;box-sizing:border-box}.g-dialog textarea{min-height:150px;resize:vertical;line-height:1.7}.g-row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.g-row>label{flex:1;min-width:140px}.g-hint{color:#b3bdc9;font-size:13px;line-height:1.7;margin:8px 0 16px}.g-dialog h3{font-size:15px;color:var(--g-gold);margin:22px 0 12px}.g-dialog h3:first-child{margin-top:0}.g-dialog details{margin-top:18px;border-top:1px solid #465263;padding-top:12px}.g-dialog summary{cursor:pointer;min-height:44px;display:flex;align-items:center;color:#d4c6aa;font-size:14px}.g-error{color:#ffd3a0;font-size:13px;white-space:pre-wrap}.g-list{display:grid;gap:8px}.g-library-item,.g-role-option{width:100%;text-align:left;display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px;border:1px solid #465263;border-radius:10px;background:#263242;color:#eee9dd;cursor:pointer;min-height:52px}.g-library-item small,.g-role-option small{display:block;font-size:11px;color:#bbc5d0;margin-top:4px}.g-library-item:disabled{opacity:.5;cursor:default}.g-role-option[aria-pressed=true]{border-color:#dfc58d;background:#3b3d3b}.g-role-option img{width:32px;height:32px;object-fit:contain;background:#e5dbc7;border-radius:50%}.g-picker{max-height:330px;overflow:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.g-picker .g-role-option>span{flex:1}.g-reminder-list{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:14px}.g-reminder-list button{min-height:44px;border:1px solid #8f7657;background:#4d3e31;color:#ffe5b8;border-radius:8px;padding:7px 10px}.g-role-sheet{padding:12px 0;border-bottom:1px solid #465263}.g-role-sheet strong{color:#e6d8b8}.g-role-sheet p{margin:7px 0;color:#e0e5eb;font-size:14px;line-height:1.8;white-space:pre-wrap}.g-role-sheet small{color:#acb9c7}.g-night-item{border:1px solid #465263;border-radius:12px;padding:14px;margin-bottom:12px}.g-night-item.done{opacity:.6}.g-night-item h3{margin:0 0 8px}.g-night-item p{font-size:14px;line-height:1.8;white-space:pre-wrap}.g-history{list-style:none;padding:0;margin:0}.g-history li{padding:10px 0;border-bottom:1px solid #465263;font-size:14px;line-height:1.6}.g-history small{display:block;color:#b3bdc9;font-size:11px}.g-menu-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.g-menu-grid .g-button{justify-content:flex-start;min-height:52px}.g-script-tabs{display:flex;gap:7px;margin:0 0 20px;flex-wrap:wrap}.g-inline-progress{font-size:14px;color:#dfc58d}.g-mode-note{padding:10px 12px;background:#17202b;border-radius:9px;font-size:12px;color:#bdc7d3;line-height:1.7}

@media(min-width:1600px){.g-summary{width:345px}.g-summary #gTitle{font-size:20px}.g-dock{width:280px}}
@media(max-width:700px){.g-summary{top:8px;left:8px;width:calc(100% - 108px);max-width:290px;gap:7px;padding:7px 9px 7px 7px}.g-emblem{width:37px;min-height:68px}.g-emblem svg{width:29px;height:39px}.g-emblem span{font-size:8px}.g-summary #gTitle{font-size:15px;margin-bottom:2px}.g-app-label{font-size:8px;letter-spacing:0}.g-app-label span{display:none}.g-composition{gap:4px;font-size:9px}.g-counts{font-size:10px}.g-save{font-size:8px}.g-view-actions{top:8px;right:8px;flex-direction:column;gap:5px}.g-view-actions .g-button{min-height:36px;min-width:80px;padding:5px 8px;font-size:11px}.g-side-tools{top:132px;gap:8px}.g-rail-button{width:32px;min-height:54px;padding:8px 6px;font-size:12px}.g-bluffs{bottom:166px}.g-dock{right:8px;bottom:max(8px,env(safe-area-inset-bottom));width:250px;padding:7px 9px}.g-control-heading{margin-bottom:5px}.g-phase{font-size:14px}.g-dock .g-button{min-height:32px;padding:5px 7px;font-size:12px}.g-fold{height:23px}.g-seat-stepper,.g-step{height:27px}.g-privacy{font-size:8px}.g-seat-name{font-size:11px;padding:1px 5px}.g-seat{gap:3px;min-height:calc(var(--token-size,68px) + 29px)}.g-token:before{outline-offset:2px}.g-reminders{left:-2px;right:-2px}.g-reminders span{min-width:24px;max-width:31px;min-height:24px;font-size:8px;padding:2px}.g-alignment{font-size:8px;bottom:29px;padding:2px 3px}.g-vote{top:4px;min-width:23px;height:23px;font-size:10px}.g-vote.used{min-width:30px;font-size:9px}.g-start-hint{display:none}.g-toast{bottom:185px;font-size:12px;max-width:calc(100% - 82px)}.g-warning{top:112px;padding:10px;font-size:12px;width:calc(100% - 76px)}.g-warning .g-button{font-size:11px;min-height:34px}.g-board.list-mode{inset:118px 40px 164px;padding:8px 6px 20px}.g-board.list-mode .g-seats{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.g-board.list-mode .g-seat{min-height:133px;padding:9px 4px}.g-board.list-mode .g-token{width:70px;height:70px}.g-board.list-mode .g-seat-role{font-size:11px}.g-board.list-mode .g-reminders{left:2px;right:2px;top:32px}.g-board.list-mode .g-vote{right:4px;top:5px}.g-board.list-mode .g-alignment{bottom:6px}.g-modal-head{padding:13px 15px}.g-modal-head h2{font-size:18px}.g-modal-body{padding:15px}.g-picker,.g-menu-grid{grid-template-columns:1fr}}
@media(max-width:360px){.g-dock{width:calc(100% - 78px)}.g-summary{gap:6px;padding-left:6px}.g-emblem{display:none}.g-summary #gTitle{font-size:15px}.g-view-actions .g-button{min-width:80px}.g-board.list-mode .g-token{width:58px;height:58px}.g-board.list-mode .g-seat{min-height:117px}.g-board.list-mode .g-seat-role{font-size:10px}.g-seat-name{font-size:10px}}
@media(max-height:600px) and (min-width:701px){.g-app{min-height:360px}.g-summary{width:230px;padding:7px;gap:7px}.g-emblem{width:36px;min-height:61px}.g-emblem svg{width:26px;height:38px}.g-summary #gTitle{font-size:15px}.g-app-label{display:none}.g-side-tools{top:105px;gap:6px}.g-rail-button{min-height:45px;font-size:12px}.g-dock{width:205px;padding:7px 9px}.g-control-heading{margin-bottom:4px}.g-dock .g-button{min-height:29px;font-size:11px}.g-privacy{display:none}.g-seat-name{font-size:11px}.g-board.list-mode{inset:112px 48px 12px;padding-bottom:180px}.g-start-hint{font-size:10px;max-width:200px}}
@media(prefers-reduced-motion:reduce){.g-app *,.g-dialog *,.g-app:before,.g-app:after{scroll-behavior:auto!important;animation:none!important;transition:none!important}}
.g-dialog.g-sheet-dialog{position:fixed;inset:8px 50px auto auto;margin:0;width:660px;max-width:calc(var(--g-viewport-width,100vw) - 76px);height:min(780px,calc(var(--g-viewport-height,100dvh) - 16px));max-height:calc(var(--g-viewport-height,100dvh) - 16px);padding:0;border:1px solid #777c7d;border-radius:10px;background:#111416ed;color:#dfdfd9;box-shadow:0 8px 32px #0008;backdrop-filter:blur(12px);overflow:hidden;z-index:20}
.g-sheet-dialog::backdrop{background:#07111b22;backdrop-filter:none}.g-sheet-dialog .g-modal-head{height:40px;padding:5px 12px;gap:8px;background:#1b1e20e6;border-color:#575c5b66;position:relative}.g-sheet-dialog .g-modal-head h2{flex:1;margin:0;font-size:13px;color:#bfc2be;line-height:1.5}.g-sheet-dialog #gSheetFloat{min-height:25px;padding:2px 9px;border:1px solid #676d6a;border-radius:15px;font-size:11px;font-weight:400;color:#d2d4ce;background:transparent}.g-sheet-dialog #gDialogClose{width:25px;height:25px;min-height:25px;padding:0;border:1px solid #676d6a;border-radius:50%;font-size:19px;font-weight:400;background:transparent;color:#d2d4ce;line-height:1}.g-sheet-dialog .g-modal-body{padding:0 12px 18px;max-height:none;height:calc(100% - 40px);overflow:auto;scrollbar-width:thin;scrollbar-color:#72787066 transparent;scrollbar-gutter:stable}.g-sheet-dialog .g-sheet-toolbar{display:flex;align-items:center;gap:14px;flex-wrap:wrap;position:sticky;top:0;margin:0 -12px 10px;padding:9px 12px;background:#1c2021f5;border-bottom:1px solid #555b5966;z-index:2}.g-sheet-dialog label.g-sheet-check{display:flex;flex-direction:row-reverse;align-items:center;justify-content:flex-end;gap:6px;margin:0;font-size:12px;color:#d4d6d0;cursor:pointer;min-height:23px}.g-sheet-check input{width:14px;height:14px;margin:0;accent-color:#4eacd4}.g-sheet-count{font-size:12px;color:#a3a9a3}.g-sheet-dialog .g-sheet-rules{padding:10px 11px;margin:0 0 17px;border:1px solid #2283a1;border-radius:9px;background:#1e39413b}.g-sheet-dialog .g-sheet-rules h3{font-size:13px;color:#9dd0e1;margin:0 0 5px}.g-sheet-dialog .g-sheet-rules p{font-size:13px;line-height:1.75;color:#d4dcd9;margin:0 0 7px;white-space:pre-wrap;overflow-wrap:anywhere}.g-sheet-dialog .g-sheet-rules p:last-child{margin-bottom:0}.g-sheet-dialog .g-sheet-group{margin:0 0 20px}.g-sheet-dialog .g-sheet-group h3{display:flex;align-items:center;gap:10px;font-size:13px;color:var(--sheet-team,#58b1e8);margin:0 0 13px;line-height:1.7}.g-sheet-group h3:after{content:"";height:1px;flex:1;background:var(--sheet-team,#58b1e8);opacity:.35}.g-sheet-group.townsfolk{--sheet-team:#50b9f4}.g-sheet-group.outsider{--sheet-team:#72d2d4}.g-sheet-group.minion{--sheet-team:#f09c80}.g-sheet-group.demon{--sheet-team:#ef7775}.g-sheet-group.traveller{--sheet-team:#c4a2e4}.g-sheet-group.fabled{--sheet-team:#e2c376}.g-sheet-group.loric{--sheet-team:#acba8b}.g-sheet-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:22px;row-gap:22px}.g-sheet-role{display:flex;align-items:flex-start;gap:9px;min-width:0;margin:0;padding:0 0 0 1px}.g-sheet-role.is-absent{opacity:.48}.g-sheet-icon{width:34px;min-width:34px;display:grid;place-items:start center;padding-top:2px}.g-sheet-icon img{width:32px;height:32px;object-fit:contain}.g-sheet-icon .g-question{font-size:24px;color:#b5ab8c;line-height:1.3}.g-sheet-copy{min-width:0}.g-sheet-role-heading{display:flex;align-items:baseline;gap:7px;flex-wrap:wrap}.g-sheet-role-heading strong{font-size:15px;color:#f2f0e8;line-height:1.5}.g-sheet-inplay{font-size:10px;color:#a5d3d9;white-space:nowrap}.g-sheet-role .g-sheet-copy p{font-size:13px;line-height:1.75;color:#c3c8c2;margin:2px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}.g-dialog.g-sheet-floating{inset:auto;left:var(--sheet-left,12px);top:var(--sheet-top,8px);z-index:20}.g-sheet-floating .g-modal-head{cursor:move;touch-action:none;user-select:none}.g-sheet-floating .g-modal-head button{cursor:pointer}.g-sheet-floating .g-modal-head:focus-visible{outline-offset:-3px}
.g-sheet-role .g-sheet-copy p{font-size:14px}
/* Mode classes are cleared on close; hide immediately before their positioning is removed. */
.grimoire-page #gDialog,.grimoire-page #gDialog::backdrop{animation:none!important;transition:none!important}
.grimoire-page #gDialog{opacity:1!important;transform:none!important}
.grimoire-page #gDialog:not([open]){display:none!important}
@media(max-width:700px){.g-dialog.g-sheet-dialog{inset:6px 6px auto;width:calc(var(--g-viewport-width,100vw) - 12px);max-width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-viewport-height,100dvh) - 12px);max-height:calc(var(--g-viewport-height,100dvh) - 12px);border-radius:9px}.g-sheet-dialog .g-modal-body{padding:0 12px 18px}.g-sheet-dialog .g-sheet-toolbar{gap:5px 12px;padding-block:7px}.g-sheet-grid{column-gap:16px;row-gap:18px}.g-sheet-dialog label.g-sheet-check{font-size:11px;min-height:28px}.g-sheet-dialog #gSheetFloat,.g-sheet-dialog #gDialogClose{min-height:30px;height:30px}.g-sheet-dialog #gDialogClose{width:30px}.g-sheet-dialog .g-modal-head{height:44px}.g-sheet-dialog .g-modal-body{height:calc(100% - 44px)}.g-dialog.g-sheet-floating{inset:auto;left:var(--sheet-left,6px);top:var(--sheet-top,6px)}}
@media(max-width:700px){.g-dialog.g-sheet-floating{width:calc(var(--g-viewport-width,100vw) - 24px);max-width:calc(var(--g-viewport-width,100vw) - 24px);height:min(620px,calc(var(--g-viewport-height,100dvh) - 96px));max-height:calc(var(--g-viewport-height,100dvh) - 96px)}}
@media(max-width:540px){.g-sheet-grid{grid-template-columns:1fr;row-gap:17px}.g-sheet-icon{width:35px;min-width:35px}.g-sheet-icon img{width:33px;height:33px}.g-sheet-role-heading strong{font-size:15px}.g-sheet-role .g-sheet-copy p{font-size:14px;line-height:1.75}.g-sheet-count{font-size:11px}}
.g-dialog.g-night-dialog{width:360px;height:min(780px,calc(var(--g-viewport-height,100dvh) - 16px));background:#111416f2}.g-night-dialog .g-modal-body{padding-bottom:14px}.g-night-toolbar{display:flex;gap:6px;flex-wrap:wrap;position:sticky;top:0;z-index:3;margin:0 -12px;padding:9px 12px;background:#1b1e20fa;border-bottom:1px solid #555b5966}.g-night-toolbar .g-button{min-height:31px;padding:4px 10px;font-size:12px;color:#c5c7c3;border-color:#636968;background:#090d0e}.g-night-toolbar .g-button[aria-pressed=true]{background:#4e514d;border-color:#d0c6a6;color:#fff6de}.g-night-summary{font-size:11px;line-height:1.7;color:#b6bfba;margin:10px 0 14px}.g-night-list{list-style:none;margin:0;padding:0}.g-night-dialog .g-night-step{--night-team:#50b9f4;display:grid;grid-template-columns:22px 30px minmax(0,1fr);gap:8px;margin:0 0 22px;padding:0;border:0;border-radius:0;background:none}.g-night-step.outsider{--night-team:#65d6de}.g-night-step.minion{--night-team:#ff9500}.g-night-step.demon{--night-team:#ee3535}.g-night-step.traveller{--night-team:#bb9ae6}.g-night-number{display:grid;place-items:center;width:22px;height:22px;margin-top:1px;border:1px solid #06090b;border-radius:50%;background:var(--night-team);color:#fff;font-size:12px;font-weight:750;box-shadow:0 1px 3px #0008}.g-night-icon{display:grid;place-items:start center;padding-top:2px}.g-night-icon img{width:29px;height:29px;object-fit:contain}.g-night-icon .g-question{font-size:25px;line-height:1.2}.g-night-copy{min-width:0}.g-night-heading{display:flex;align-items:baseline;gap:7px;flex-wrap:wrap;line-height:1.5}.g-night-heading strong{font-size:14px;color:#eeeae0}.g-night-seats{font-size:11px;color:#acb4ad;overflow-wrap:anywhere}.g-night-dialog .g-night-reminder{font-size:13px;line-height:1.75;white-space:pre-wrap;overflow-wrap:anywhere;color:#c5cac3;margin:3px 0 0}.g-night-actions{display:flex;gap:5px;flex-wrap:wrap;margin-top:7px}.g-night-actions .g-button{min-height:27px;padding:2px 8px;font-size:11px;font-weight:400;color:#b4bbb6;border-color:#555f5855}.g-night-actions .g-button[aria-pressed=true]{border-color:#c7b477;background:#4b4535;color:#f5df9e}.g-night-dialog .g-night-step.done{opacity:.65}.g-night-step.skipped .g-night-heading strong{text-decoration:line-through;color:#a5aaa6}.g-night-dialog .g-night-note{margin-top:4px}.g-night-dialog .g-night-note summary{min-height:34px;font-size:11px;color:#aab4ae}.g-night-note .g-hint{font-size:12px}.g-night-dialog #gNightFloat{min-height:25px;padding:2px 9px;border:1px solid #676d6a;border-radius:15px;font-size:11px;font-weight:400;color:#d2d4ce;background:transparent}
@media(max-width:700px){.g-dialog.g-night-dialog{width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-dialog.g-night-dialog.g-sheet-floating{width:calc(var(--g-viewport-width,100vw) - 24px);height:min(620px,calc(var(--g-viewport-height,100dvh) - 96px))}.g-night-dialog #gNightFloat{min-height:30px;height:30px}.g-night-toolbar .g-button{min-height:34px}.g-night-actions .g-button{min-height:32px}.g-night-dialog .g-night-reminder{font-size:14px}.g-night-dialog .g-night-step{margin-bottom:23px}}
.g-board.list-mode[data-layout=single] .g-seats{grid-template-columns:minmax(0,1fr)}.g-board.list-mode[data-layout=double] .g-seats{grid-template-columns:repeat(2,minmax(0,1fr))}.g-token-order{position:absolute;top:50%;display:grid;place-items:center;width:var(--night-badge-size,clamp(28px,calc(var(--token-size,112px)*.34),46px));height:var(--night-badge-size,clamp(28px,calc(var(--token-size,112px)*.34),46px));transform:translateY(-50%);border:3px solid #05080d;border-radius:50%;color:#fff;font-size:clamp(16px,calc(var(--token-size,112px)*.19),26px);font-weight:800;line-height:1;box-shadow:0 2px 4px #0009;pointer-events:none;z-index:3;text-shadow:0 1px 2px #000}.g-token-order.first{left:-8%;background:radial-gradient(circle at 42% 28%,#2f72f3,#07379e 62%,#03132f)}.g-token-order.other{right:-8%;background:radial-gradient(circle at 42% 28%,#ee2828,#a60000 62%,#290000)}.g-board.list-mode .g-seat-token{--night-badge-size:30px}.g-board.list-mode .g-token-order{font-size:17px}.g-seat.has-night-order>.g-vote{top:-5px}
.g-dialog.g-menu-dialog{width:340px;height:calc(var(--g-viewport-height,100dvh) - 16px);background:#111416f7}.g-menu-dialog .g-modal-body{padding:0 12px 16px;scrollbar-gutter:stable}.g-menu-dialog .g-menu-section{margin:14px 0 19px}.g-menu-dialog .g-menu-section h3{margin:0 0 7px;font-size:12px;line-height:1.5;color:#9a9f9a;font-weight:650}.g-menu-dialog .g-menu-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.g-menu-item svg,.g-signal-display svg{width:18px;height:18px;flex:none;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}.g-menu-dialog .g-menu-item{width:100%;min-height:41px;justify-content:flex-start;gap:8px;padding:8px 10px;border:1px solid #030606;border-radius:7px;background:#090d0e;color:#c4c7c1;box-shadow:inset 0 0 0 1px #ffffff07;font-size:13px;font-weight:550;line-height:1.45}.g-menu-item svg{color:#969e98}.g-menu-label{min-width:0;overflow-wrap:anywhere}.g-menu-dialog .g-menu-item:hover{color:#f3ead0;border-color:#8f7b4c;background:#20241e}.g-menu-dialog .g-menu-item[aria-pressed=true]{background:#39321b;color:#f4df9b;border-color:#8d7940}.g-menu-dialog .g-menu-item[aria-pressed=true] svg{color:#ddc372}.g-menu-dialog .g-menu-item.danger{border-color:#633f3a;color:#e9b6aa;background:#281a19}.g-menu-wide,.g-menu-script{grid-column:1/-1}.g-menu-script .g-menu-label{display:flex;flex-direction:column;gap:2px;min-width:0}.g-menu-script strong{font-size:14px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.g-menu-script small{font-size:10px;color:#969e98;line-height:1.6}.g-menu-dialog .g-menu-script{padding-block:10px}.g-menu-script>svg{color:#d8c07e;width:22px;height:22px}.g-menu-stepper{display:flex;align-items:center;border:1px solid #030606;border-radius:7px;background:#090d0e;min-width:0;overflow:hidden}.g-menu-dialog #gSeatCount{border:0;border-radius:0;background:transparent;min-width:0;min-height:41px;padding:5px 0;text-align:center;text-align-last:center;font-size:13px;appearance:none;color:#e0dfd3;flex:1}.g-menu-dialog .g-menu-step{flex:none;width:30px;min-height:41px;padding:0;border:0;border-radius:0;background:transparent;font-size:18px;color:#bbc3bc;cursor:pointer}.g-menu-step:hover{background:#ffffff15}.g-menu-step:disabled{opacity:.35;cursor:default}.g-menu-count{margin-left:auto;min-width:20px;display:grid;place-items:center;border-radius:4px;background:#ffffff0c;padding:2px 5px;font-size:11px;color:#d4c391}.g-menu-check{margin-left:auto;width:16px;height:16px;flex:none;border:1px solid #7c826c;border-radius:3px;display:grid;place-items:center;font-size:12px;line-height:1}.g-menu-item[aria-pressed=true] .g-menu-check{border-color:#eed48a;color:#ffe7a0;background:#8b7331}.g-menu-dialog .g-menu-footnote{font-size:10px;line-height:1.7;color:#a8aaa0;margin:7px 0 0}.g-menu-footer{font-size:10px;color:#8e9993;line-height:1.7;border-top:1px solid #464c4566;padding-top:11px;margin:4px 0 0}
#gDialog.g-signal-dialog[open]{position:fixed;inset:0;margin:0;width:var(--g-viewport-width,100vw);max-width:var(--g-viewport-width,100vw);height:var(--g-viewport-height,100dvh);max-height:var(--g-viewport-height,100dvh);border:0;border-radius:0;background:#090d10;opacity:1;animation:none;transform:none;transition:none;z-index:50}.g-signal-dialog::backdrop{background:#090d10}.g-signal-dialog .g-modal-head{background:#090d10}.g-signal-dialog .g-modal-body{height:calc(100% - 80px);max-height:none;display:grid;place-items:center;overflow:auto}.g-signal-display{display:flex;align-items:center;flex-direction:column;gap:30px;text-align:center;color:#eee4cb}.g-signal-display strong{font-size:clamp(32px,7vw,80px);line-height:1.4;overflow-wrap:anywhere}.g-signal-display svg{width:70px;height:70px;stroke-width:1}.g-signal-display.good{color:#84cbef}.g-signal-display.evil{color:#ee9c95}.g-signal-display p{font-size:13px;color:#a9b4af;margin:0}
@media(max-width:700px){.g-dialog.g-menu-dialog{width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-menu-dialog .g-menu-grid{gap:8px}.g-menu-dialog .g-menu-item{min-height:44px;font-size:13px}.g-menu-dialog #gSeatCount,.g-menu-dialog .g-menu-step{min-height:44px}.g-menu-dialog .g-menu-step{width:34px}.g-menu-dialog .g-menu-section{margin-bottom:19px}.g-menu-dialog .g-menu-section h3{font-size:12px}.g-token-order{border-width:2px}.g-board.list-mode .g-seat-token{--night-badge-size:28px}.g-board.list-mode .g-token-order{font-size:16px}.g-signal-display{gap:24px}}
@media print{.g-app{height:1000px;background:white!important}.g-app:before,.g-view-actions,.g-side-tools,.g-bluffs,.g-dock,.g-warning,.g-dialog,.g-toast,.g-start-hint{display:none!important}.g-summary{position:absolute;background:white;color:black}.g-summary #gTitle,.g-summary .g-counts,.g-summary .g-save{color:black}.g-seat-name{color:black;background:white}.g-board{inset:140px 0 0}}

/* Shared physical-token artwork and decorative rule leaves. */
.g-token{border:0;background:transparent url("../../theme/token1.png") center/100% 100% no-repeat;box-shadow:0 3px 9px #0007}
.g-token:before{display:none}
.g-token.g-token-hidden{background-image:url("../../theme/life1.png")}
.g-token-turn{position:relative;display:block;border-radius:50%;transform-style:preserve-3d;animation:g-token-flip 480ms cubic-bezier(.4,0,.2,1) both}
.g-token-turn>.g-token,.g-token-turn-back{backface-visibility:hidden;-webkit-backface-visibility:hidden}
.g-token-turn>.g-token{transform:rotateY(0deg)}
.g-token-turn-back{position:absolute;inset:0;border-radius:50%;background:transparent url("../../theme/life1.png") center/100% 100% no-repeat;transform:rotateY(180deg);pointer-events:none}
.g-token-hidden[data-public-state=dead-vote],.g-token-turn-back[data-public-state=dead-vote]{background-image:url("../../theme/life1.png"),url("../../theme/death1.png");background-size:50% 50%,100% 100%;background-position:center;background-repeat:no-repeat}
.g-token-hidden[data-public-state=dead-spent],.g-token-turn-back[data-public-state=dead-spent]{background-image:url("../../theme/death1.png")}
@keyframes g-token-flip{from{transform:perspective(700px) rotateY(180deg)}to{transform:perspective(700px) rotateY(0deg)}}
.g-eye-slash{display:none}.g-view-actions #gPlayerView[aria-pressed=true] .g-eye-slash{display:block}
.g-app[data-player-view=true] .g-view-actions #gPlayerView[aria-pressed=true]{background:#f2cc4a;border-color:#f2cc4a;color:#1c2226}
.g-token .g-token-leaf{position:absolute;inset:0;width:100%;height:100%;margin:0;object-fit:fill;filter:none;pointer-events:none;z-index:2}
.g-token .g-seat-role{z-index:3}
/* The upper cap is the life control; the middle of the role still opens role selection. */
.g-seat .g-life-toggle,.g-seat .g-life-shroud{--shroud-width:clamp(20px,calc(var(--token-size)*.34),46px);position:absolute;left:50%;top:4px;width:max(44px,var(--shroud-width));height:clamp(26px,calc(var(--token-size)*.32),40px);min-height:0!important;padding:0;border:0;border-radius:4px;background:transparent;transform:translateX(-50%)!important;transition:none!important;animation:none!important;z-index:5}
.g-life-toggle:before,.g-life-shroud:before{content:"";position:absolute;left:50%;top:0;width:var(--shroud-width);height:calc(var(--shroud-width)*1.4);transform:translateX(-50%);background:url("../../theme/shroud1.png") top center/contain no-repeat;pointer-events:none}
.g-life-toggle[data-death-cause=execution]:after,.g-replay-shroud.execution:after{content:'☠';position:absolute;left:50%;top:36%;transform:translateX(-50%);color:#f1e3c9;font:700 clamp(10px,calc(var(--token-size,112px)*.12),15px)/1 'Segoe UI Symbol',sans-serif;text-shadow:0 1px 2px #180c0c,0 0 2px #180c0c;pointer-events:none}
.g-app[data-split-shrouds=false] .g-replay-shroud.execution:after{display:none}
.g-death-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:8px 0 14px}.g-death-choice{display:grid!important;grid-template-columns:36px 1fr;column-gap:9px;align-items:center;text-align:left;min-height:68px;padding:10px!important}.g-death-choice-icon{grid-row:span 2;display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:#30282a;color:#e6d7c0;font:22px/1 'Segoe UI Symbol',sans-serif}.g-death-choice-icon.other{background:#263039;color:#b8c3c8}.g-death-choice-title{font-weight:700}.g-death-choice small{color:#aab2b0;line-height:1.3}.g-death-choice[aria-pressed=true]{border-color:#c9a967;background:#3a3528}
@media(max-width:380px){.g-death-choices{grid-template-columns:1fr}}
.g-seat.dead .g-life-toggle.is-covering:before{animation:g-shroud-cover 460ms cubic-bezier(.22,.7,.32,1) both}
@keyframes g-shroud-cover{from{transform:translate(-50%,-65%);clip-path:inset(0 0 100% 0);opacity:0}20%{opacity:1}to{transform:translate(-50%,0);clip-path:inset(0);opacity:1}}
@media(prefers-reduced-motion:reduce){.g-seat.dead .g-life-toggle.is-covering:before{animation:none}}
.g-seat .g-life-toggle{opacity:0;cursor:pointer;touch-action:manipulation}.g-seat:hover .g-life-toggle,.g-seat:focus-within .g-life-toggle,.g-seat.dead .g-life-toggle{opacity:1}
.g-seat:not(.dead) .g-life-toggle:before{opacity:0}.g-seat:not(.dead) .g-life-toggle:focus-visible:before{opacity:.4}
@media(hover:hover) and (pointer:fine){.g-seat:not(.dead) .g-life-toggle:hover:before{opacity:.35}}
.g-life-shroud{pointer-events:none}.g-seat.dragging .g-life-toggle{visibility:hidden}
.g-board.list-mode .g-life-toggle,.g-board.list-mode .g-life-shroud{--shroud-width:28px;top:10px;height:26px}
@media(hover:none),(pointer:coarse){.g-seat .g-life-toggle{opacity:1}}
@media(max-width:700px){.g-board.list-mode .g-life-toggle,.g-board.list-mode .g-life-shroud{--shroud-width:24px;top:9px}}
@media(max-width:360px){.g-board.list-mode .g-life-toggle,.g-board.list-mode .g-life-shroud{--shroud-width:20px;height:24px}}

/* Mild curved role names share the same full-token coordinate system. */
.g-token .g-seat-role-arc{position:absolute;inset:0;width:100%;height:100%;display:block;overflow:visible;pointer-events:none;text-shadow:none;font-family:"Microsoft YaHei","微软雅黑","PingFang SC",sans-serif;font-weight:500}
.g-token .g-seat-role-arc text{fill:#171411;stroke:#fff;stroke-width:1.15px;paint-order:stroke fill;stroke-linejoin:round}
.g-token .g-seat-role-arc.unassigned{display:none}
.g-seat.dead .g-token>img:not(.g-token-leaf){filter:brightness(.48) saturate(.65)}
.g-token[data-marker-alignment=good]{--g-alignment-icon-filter:grayscale(1) sepia(1) saturate(4200%) hue-rotate(168deg) brightness(.9)}
.g-token.minion[data-marker-alignment=good],.g-token.demon[data-marker-alignment=good]{--g-alignment-icon-filter:url(#gGoodIconFilter)}
.g-token.townsfolk[data-marker-alignment=good],.g-token.outsider[data-marker-alignment=good]{--g-alignment-icon-filter:none}
.g-token[data-marker-alignment=evil]{--g-alignment-icon-filter:grayscale(1) sepia(1) saturate(700%) hue-rotate(330deg) brightness(.7)}
.g-token.townsfolk[data-marker-alignment=evil],.g-token.outsider[data-marker-alignment=evil]{--g-alignment-icon-filter:url(#gEvilIconFilter)}
.g-token.minion[data-marker-alignment=evil],.g-token.demon[data-marker-alignment=evil]{--g-alignment-icon-filter:none}
.g-token[data-marker-alignment]>img:not(.g-token-leaf){filter:var(--g-alignment-icon-filter)}
.g-seat.dead .g-token[data-marker-alignment]>img:not(.g-token-leaf){filter:var(--g-alignment-icon-filter) brightness(.48) saturate(.65)}
.g-seat.dead .g-token-order{background:radial-gradient(circle at 42% 28%,#65686a,#343638 62%,#151718);color:#d4d4d2}
/* Death votes are public status; only the storyteller gets a clickable control. */
.g-seat-caption{position:relative;display:flex;justify-content:center;align-items:center;max-width:calc(var(--token-size,112px) + 18px);min-height:28px}
.g-board .g-seat.dead .g-seat-caption{max-width:calc(var(--token-size,112px)*.6)}
.g-board .g-seat .g-seat-caption .g-seat-name{max-width:100%;margin:0}
.g-board .g-seat .g-vote{position:absolute;left:calc(100% + 3px);right:auto;top:50%;width:32px;height:32px;min-width:0;min-height:0!important;display:grid;place-items:center;padding:0;border:0;border-radius:4px;background:transparent;color:#fff;opacity:1;box-shadow:none;transform:translateY(-50%)!important;transition:none!important;animation:none!important;pointer-events:none;z-index:6}
.g-board .g-seat .g-vote svg{width:24px;height:24px;filter:drop-shadow(0 1px 2px #000);pointer-events:none}
.g-board .g-seat button.g-vote-toggle{pointer-events:auto;cursor:pointer;touch-action:manipulation}
.g-board .g-seat .g-vote.used{opacity:.26}
.g-board.list-mode .g-seat.dead .g-seat-caption{max-width:min(80px,calc(100% - 64px))}

/* Keep the left rail below the measured summary, including wrapped status text. */
.g-side-tools.g-left-tools{top:calc(var(--g-summary-bottom,132px) + 16px)}

/* Private notes share panel movement, with an editor that never rebuilds while typing. */
.g-notes-panel{position:absolute;display:flex;flex-direction:column;overflow:hidden;box-sizing:border-box;border:1px solid #777c7d;border-radius:10px;color:#dfdfd9;box-shadow:0 8px 32px #0008;backdrop-filter:blur(10px);z-index:20;inset:calc(var(--g-summary-bottom,132px) + 16px) auto auto 46px;width:320px;max-width:calc(var(--g-viewport-width,100vw) - 80px);height:min(620px,calc(var(--g-viewport-height,100dvh) - var(--g-summary-bottom,132px) - 32px));max-height:calc(var(--g-viewport-height,100dvh) - var(--g-summary-bottom,132px) - 32px);background:#0e1418f2}

.g-notes-panel #gNotesText{flex:1;min-height:0;margin:0;padding:14px 15px;resize:none;border:0;border-radius:0;background:transparent;color:#e0e5df;box-shadow:none;font-size:14px;line-height:1.85;scrollbar-width:thin;overflow:auto;overscroll-behavior:contain}
.g-notes-panel #gNotesText::placeholder{color:#98a29a;opacity:1}.g-notes-panel #gNotesText:focus-visible{outline:1px solid #b6a778;outline-offset:-2px}
.g-notes-footer{flex:none;display:flex;flex-wrap:wrap;align-items:center;gap:7px;padding:9px 11px;border-top:1px solid #65716a55;background:#0d1317}
.g-notes-tools{display:flex;align-items:center;flex-wrap:wrap;gap:5px;width:100%}.g-notes-panel .g-notes-chip{min-height:28px;padding:3px 8px;border:1px solid #77807977;border-radius:14px;background:transparent;color:#c8cfc6;font-size:11px;line-height:1.4}
.g-notes-panel .g-notes-clear{margin-left:auto;min-height:30px;width:30px;padding:5px;border:0;background:transparent;color:#aaa99d}.g-notes-clear svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.g-notes-panel .g-notes-clear:hover{color:#ffc6bb;background:#6e383855}
.g-notes-status,.g-notes-count{font-size:10px;line-height:1.5;color:#a2ada4}.g-notes-status.is-unsaved{color:#ffbda8}.g-notes-count{margin-left:auto;white-space:nowrap}
.g-notes-panel #gNotesFloat{min-height:25px;padding:2px 9px;border:1px solid #676d6a;border-radius:15px;font-size:11px;font-weight:400;color:#d2d4ce;background:transparent}.g-left-tools #gNotes[aria-expanded=true]{color:#f2d381;border-color:#b29d5b;background:#39382de8}
.g-notes-panel.is-floating{inset:auto;left:var(--notes-left,46px);top:var(--notes-top,148px);height:min(620px,calc(var(--g-viewport-height,100dvh) - 32px));max-height:calc(var(--g-viewport-height,100dvh) - 32px)}
@media(max-width:700px){.g-notes-panel{left:40px;width:calc(var(--g-viewport-width,100vw) - 80px)}.g-notes-panel #gNotesFloat{min-height:30px;height:30px}.g-notes-panel #gNotesText{font-size:16px;padding:11px 12px}.g-notes-footer{padding:8px}.g-notes-panel .g-notes-chip{min-height:34px;font-size:11px;padding-inline:7px}.g-notes-panel .g-notes-clear{width:34px;min-height:34px}.g-notes-panel.is-floating{left:var(--notes-left,40px);top:var(--notes-top,132px)}}

.g-notes-head{display:flex;align-items:center;gap:8px;flex:none;height:40px;padding:5px 12px;border-bottom:1px solid #575c5b66;background:#1b1e20e6}.g-notes-head h2{flex:1;font-size:13px;color:#bfc2be;line-height:1.5;margin:0;padding:0;border:0}.g-notes-panel .g-notes-close{width:25px;height:25px;min-height:25px;padding:0;border:1px solid #676d6a;border-radius:50%;font-size:19px;font-weight:400;background:transparent;color:#d2d4ce;line-height:1}.g-notes-panel.is-floating .g-notes-head{cursor:move;touch-action:none;user-select:none}.g-notes-head:focus-visible{outline-offset:-3px}
.g-side-panel.g-sheet-dialog{display:block;width:var(--side-width,660px);right:var(--side-right,46px);animation:none!important;transition:none!important;opacity:1;transform:none!important}.g-side-panel.g-night-dialog{width:360px}.g-side-panel.g-sheet-floating{inset:auto;left:var(--sheet-left,12px);top:var(--sheet-top,8px);right:auto}.g-side-panel .g-side-close{width:25px;height:25px;min-height:25px;padding:0;border:1px solid #676d6a;border-radius:50%;font-size:19px;background:transparent;color:#d2d4ce;line-height:1}.g-side-panel #gNightFloat{min-height:25px;padding:2px 9px;border:1px solid #676d6a;border-radius:15px;font-size:11px;color:#d2d4ce;background:transparent}
.g-right-tools :is(#gSheet,#gNight)[aria-expanded=true]{color:#f2d381;border-color:#b29d5b;background:#39382de8}
@media(max-width:700px){.g-notes-head{height:44px}.g-notes-panel .g-notes-close{width:30px;height:30px;min-height:30px}.g-side-panel.g-sheet-dialog{inset:6px 40px auto;width:calc(var(--g-viewport-width,100vw) - 80px);max-width:calc(var(--g-viewport-width,100vw) - 80px);height:calc(var(--g-viewport-height,100dvh) - 12px);max-height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-side-panel.g-sheet-floating{inset:auto;left:var(--sheet-left,40px);top:var(--sheet-top,8px);width:calc(var(--g-viewport-width,100vw) - 80px);height:min(620px,calc(var(--g-viewport-height,100dvh) - 32px));max-height:calc(var(--g-viewport-height,100dvh) - 32px)}.g-side-panel .g-side-close{width:30px;height:30px;min-height:30px}.g-side-panel #gNightFloat{height:30px;min-height:30px}}
@media(max-width:480px){.g-side-panel .g-sheet-grid{grid-template-columns:1fr}}
@media print{.g-notes-panel,.g-side-panel{display:none!important}}

/* Leave display controls and the game dock reachable while fixed panels are open. */
.g-side-panel.g-sheet-dialog{top:var(--g-side-top,70px);height:min(780px,calc(var(--g-viewport-height,100dvh) - var(--g-side-top,70px) - var(--side-bottom,16px)));max-height:calc(var(--g-viewport-height,100dvh) - var(--g-side-top,70px) - var(--side-bottom,16px))}.g-side-panel.g-sheet-floating{top:var(--sheet-top,8px);height:min(780px,calc(var(--g-viewport-height,100dvh) - 16px));max-height:calc(var(--g-viewport-height,100dvh) - 16px)}
@media(max-width:700px){.g-side-panel.g-sheet-dialog{height:min(700px,calc(var(--g-viewport-height,100dvh) - var(--g-side-top,132px) - var(--side-bottom,16px)));max-height:calc(var(--g-viewport-height,100dvh) - var(--g-side-top,132px) - var(--side-bottom,16px))}.g-side-panel.g-sheet-floating{height:min(620px,calc(var(--g-viewport-height,100dvh) - 32px));max-height:calc(var(--g-viewport-height,100dvh) - 32px)}}

.g-app .g-dock{right:46px}
.g-app .g-side-tools.g-right-tools{top:0;gap:12px}.g-app .g-view-actions{top:2px;right:46px;display:block}.g-app .g-view-actions #gPlayerView{display:grid;place-items:center;min-width:46px;width:46px;min-height:46px;height:46px;padding:10px;border:1px solid #ffffff26;border-radius:10px;background:#30383fe8;color:#fff}.g-view-actions #gPlayerView svg{display:block;width:24px;height:24px;flex:none}.g-app .g-view-actions #gPlayerView:hover{background:#475159}.g-app .g-view-actions #gPlayerView[aria-pressed=true]{background:#4d5146;border-color:#cfb96f}
.g-dialog.g-script-dialog[data-script-tab=official]{height:fit-content}.g-script-dialog .g-button{transition:none!important;animation:none!important}
.g-dialog.g-script-dialog{width:min(1000px,calc(var(--g-viewport-width,100vw) - 24px));max-width:calc(var(--g-viewport-width,100vw) - 12px);height:min(860px,calc(var(--g-viewport-height,100dvh) - 24px));max-height:calc(var(--g-viewport-height,100dvh) - 24px);border:1px solid #656b65;border-radius:12px;background:#111415;color:#d8dad1;overflow:hidden}.g-script-dialog .g-modal-head{height:60px;position:relative;padding:12px 20px;background:#111415;border:0}.g-script-dialog .g-modal-head h2{font-size:22px;font-weight:500;color:#efeadf}.g-script-dialog #gDialogClose{width:32px;height:32px;min-height:32px;padding:0;border:1px solid #626861;border-radius:50%;font-size:23px;color:#e2e4db;line-height:1}.g-script-dialog .g-modal-body{display:flex;flex-direction:column;overflow:hidden;max-height:none;height:calc(100% - 60px);padding:0 20px 16px}
.g-script-nav{display:flex;flex:none;gap:14px;border-bottom:1px solid #53594d66;overflow-x:auto;margin-bottom:12px}.g-script-nav .g-button{flex:none;min-height:42px;padding:8px 12px;border:0;border-bottom:2px solid transparent;border-radius:0;background:transparent;font-size:15px;font-weight:600;color:#949c94}.g-script-nav .g-button[aria-selected=true]{border-bottom-color:#e5cc7a;color:#eeddaa;background:transparent}.g-script-nav .g-button:hover{background:#f4df9d08;color:#efe8d0}.g-script-views{flex:1;min-height:0;overflow:hidden}.g-script-view{height:100%;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#66715f66 transparent;padding:0 2px 4px}.g-script-help{font-size:12px;line-height:1.7;color:#9ba598;margin:0 0 12px}.g-script-status{border:1px solid #8b784d77;border-radius:6px;background:#42391d33;padding:9px 11px;font-size:12px;line-height:1.7;color:#d3c597;white-space:pre-wrap;overflow-wrap:anywhere;margin:0 0 10px}
.g-script-presets{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.g-script-card{min-width:0;border:1px solid #4b5248;border-radius:10px;background:#080c0d;align-self:start;overflow:hidden}.g-script-dialog .g-script-preset{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:7px;width:100%;border:0;border-radius:9px;background:transparent;padding:18px 9px 6px;color:#f0dfa8;min-height:150px}.g-script-preset strong{font-size:16px;line-height:1.5;color:#eedda8;text-align:center;overflow-wrap:anywhere}.g-script-players{font-size:12px;color:#a9ada2;font-weight:400}.g-script-logo{flex:none;display:block;object-fit:contain;width:64px;height:50px;margin:0;filter:none}.g-script-preset .g-script-logo{width:140px;max-width:100%;height:74px;margin-bottom:3px}.g-script-preset:hover{background:#ead79d08}.g-script-dialog .g-script-intro{margin:0;padding:0 10px 8px;border:0}.g-script-dialog .g-script-intro summary{display:block;min-height:25px;padding:0;text-align:center;font-size:12px;color:#cbb66d;cursor:pointer;line-height:25px}.g-script-intro summary:after{content:' ▾'}.g-script-intro[open] summary:after{content:' ▴'}.g-script-intro p{font-size:12px;color:#b9c2b1;line-height:1.8;margin:8px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}
.g-script-dialog[data-script-tab=official]{height:auto}.g-script-dialog[data-script-tab=official] .g-modal-body{height:auto;max-height:calc(var(--g-viewport-height,100dvh) - 84px)}.g-script-dialog[data-script-tab=official] .g-script-views{flex:auto;max-height:calc(var(--g-viewport-height,100dvh) - 150px)}
#gScriptView_library{display:flex;flex-direction:column}.g-script-library-tools{flex:none}.g-script-dialog #gLibrarySearch{min-height:37px;background:#070b0c;border-color:#4d564b;border-radius:6px;margin-bottom:10px;padding:8px 11px;font-size:13px}.g-script-filter{display:flex;align-items:center;flex-wrap:wrap;gap:5px;margin-bottom:8px}.g-script-filter>span{min-width:24px;font-size:11px;color:#87917f;margin-right:2px}.g-script-filter .g-button{min-height:25px;padding:3px 9px;border:1px solid #555e4d88;border-radius:16px;background:#121712;font-size:11px;line-height:1.4;color:#a8b09f}.g-script-filter .g-button[aria-pressed=true]{background:#49411f;border-color:#c2a347;color:#f1d986}.g-script-library-sort{display:flex;gap:8px;margin:0 0 8px}.g-script-dialog .g-script-library-sort select{width:auto;max-width:70%;min-height:30px;padding:4px 24px 4px 9px;border:1px solid #4e5848;border-radius:5px;background:#10160f;color:#bcc7af;font-size:11px}.g-script-library-sort #gLibraryCategory{flex:1}.g-script-library-sort #gLibrarySort{width:120px}.g-script-dialog #gLibraryCount{flex:none;margin:0 0 9px;font-size:11px}.g-script-results{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;align-content:start;padding:2px 3px 3px 0}.g-script-dialog .g-script-library-item{display:flex;align-items:center;justify-content:flex-start;gap:10px;min-width:0;min-height:78px;padding:8px 11px;border:1px solid #3b463c;border-radius:7px;background:#090d0e;text-align:left;color:#eee3b8}.g-script-library-item:hover{background:#d7c47b0d;border-color:#a28e51}.g-script-library-item:disabled{opacity:.5}.g-script-library-copy{min-width:0;flex:1}.g-script-library-copy strong{display:block;font-size:14px;line-height:1.5;overflow-wrap:anywhere;color:#e8dba9}.g-script-dialog .g-script-library-copy small{display:block;font-size:11px;line-height:1.5;color:#9eaa95;margin:2px 0}.g-script-library-category{display:block;font-size:10px;line-height:1.5;color:#7f907d;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.g-script-dialog #gLibraryMore{flex:none;align-self:center;min-height:30px;padding:4px 18px;margin-top:7px;border-color:#59644b;font-size:12px;color:#c1cea7}.g-script-empty{font-size:13px;color:#b0bda5;line-height:1.8;grid-column:1/-1;margin:10px 0}
.g-script-current{font-size:12px;line-height:1.7;color:#e2d19c;border:1px solid #9d812d;border-radius:6px;background:#423b1c55;padding:8px 11px;margin:0 0 13px;overflow-wrap:anywhere}.g-script-dialog .g-script-recent h3{font-size:12px;color:#9ba68e;margin:0 0 7px}.g-script-recent-chips{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:12px}.g-script-recent-chip{display:inline-flex;max-width:100%;align-items:center;border:1px solid #475241;border-radius:6px;background:#080d0a;overflow:hidden}.g-script-dialog .g-script-recent-chip .g-button{min-height:32px;border:0;border-radius:0;font-size:12px;background:transparent;color:#cbd4bc;padding:5px 8px;white-space:normal;overflow-wrap:anywhere}.g-script-dialog .g-script-recent-chip .g-button:last-child{flex:none;min-width:28px;padding-inline:6px;color:#89957d;font-size:18px}.g-script-file-tools{display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin-bottom:11px}.g-script-dialog .g-script-file-tools .g-button{min-height:34px;font-size:12px;padding:7px 10px;border:1px solid #526047;border-radius:6px;background:#080d0b;color:#c6d3b7}.g-script-editor-link{font-size:12px;color:#d4c067;line-height:1.6;padding:4px}.g-script-url-row{display:flex;gap:8px;margin-bottom:11px}.g-script-dialog .g-script-url-row input{min-width:0;flex:1;min-height:37px;font-size:12px;padding:8px 10px;background:#070c0a;border:1px solid #4d5846;border-radius:6px}.g-script-dialog #gScriptFetch{flex:none;min-height:37px;padding:6px 14px;font-size:12px;border:1px solid #526048;border-radius:6px;color:#c1d1b0}.g-script-dialog #gScriptJSON{display:block;min-height:190px;max-height:400px;width:100%;resize:vertical;line-height:1.65;font:12px/1.75 Consolas,monospace;padding:11px;background:#070c0a;border:1px solid #4a5542;border-radius:7px;color:#cbd9bc;margin-bottom:10px}.g-script-dialog #gScriptLoad{min-height:36px;margin-bottom:12px;padding:7px 18px;font-size:13px}.g-script-import-preview{display:grid;gap:6px}.g-script-dialog .g-script-import-item{justify-content:flex-start;gap:10px;min-height:60px;padding:7px 10px;background:#080d0b;border-color:#4e5c44;color:#d0ddbe;text-align:left;font-size:13px}.g-script-import-item .g-script-logo{width:50px;height:38px}
@media(max-width:700px){.g-dialog.g-script-dialog{width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-viewport-height,100dvh) - 12px);max-height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-script-dialog .g-modal-head{height:52px;padding:9px 12px}.g-script-dialog .g-modal-head h2{font-size:19px}.g-script-dialog .g-modal-body{height:calc(100% - 52px);padding:0 12px 10px}.g-script-nav{gap:5px;margin-bottom:9px}.g-script-nav .g-button{min-height:39px;padding:7px 9px;font-size:13px}.g-script-presets{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.g-script-preset .g-script-logo{width:110px;height:65px}.g-script-dialog .g-script-preset{min-height:139px;padding:13px 7px 5px}.g-script-preset strong{font-size:14px}.g-script-players{font-size:11px}.g-script-dialog #gLibrarySearch,.g-script-dialog #gScriptURL,.g-script-dialog #gScriptJSON{font-size:16px}.g-script-filter{gap:4px;margin-bottom:6px}.g-script-filter .g-button{min-height:29px;padding-inline:8px}.g-script-results{grid-template-columns:1fr;gap:6px}.g-script-dialog .g-script-library-item{min-height:73px;padding:7px 9px}.g-script-library-item .g-script-logo{width:52px;height:44px}.g-script-library-copy strong{font-size:13px}.g-script-library-sort{gap:6px}.g-script-dialog #gScriptJSON{min-height:180px}.g-script-dialog[data-script-tab=official]{height:auto}.g-script-dialog[data-script-tab=official] .g-modal-body{height:auto;max-height:calc(var(--g-viewport-height,100dvh) - 64px)}.g-script-dialog[data-script-tab=official] .g-script-views{max-height:calc(var(--g-viewport-height,100dvh) - 116px)}}
@media(max-height:500px) and (min-width:701px){.g-script-dialog .g-modal-head{height:46px;padding-block:7px}.g-script-dialog .g-modal-body{height:calc(100% - 46px);padding-bottom:8px}.g-script-nav{margin-bottom:6px}.g-script-nav .g-button{min-height:34px;padding-block:5px}.g-script-filter{margin-bottom:4px}.g-script-dialog #gLibrarySearch{margin-bottom:5px}.g-script-dialog[data-script-tab=official] .g-modal-body{height:auto;max-height:calc(var(--g-viewport-height,100dvh) - 70px)}.g-script-dialog[data-script-tab=official] .g-script-views{max-height:calc(var(--g-viewport-height,100dvh) - 122px)}}
.g-bag-actions svg{flex:none;width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
@media(max-width:700px){.g-app .g-dock{right:40px;width:min(250px,calc(var(--g-viewport-width,100vw) - 88px))}}

/* Draft a role bag without changing seats until the Storyteller distributes it. */
.g-dialog.g-distribution-dialog{width:min(1120px,calc(var(--g-viewport-width,100vw) - 32px));max-width:calc(var(--g-viewport-width,100vw) - 16px);height:min(940px,calc(var(--g-viewport-height,100dvh) - 24px));max-height:calc(var(--g-viewport-height,100dvh) - 24px);border:1px solid #676b66;border-radius:12px;background:#101213;color:#dddcd5;overflow:hidden}
.g-distribution-dialog .g-modal-head{height:60px;padding:12px 20px;background:#101213;border:0;position:relative}.g-distribution-dialog .g-modal-head h2{font-size:21px;font-weight:500;color:#eeeae1}.g-distribution-dialog #gDialogClose{width:32px;height:32px;min-height:32px;border:1px solid #646762;border-radius:50%;padding:0;font-size:23px;line-height:1;color:#dddcd5}
.g-distribution-dialog .g-modal-body{display:flex;flex-direction:column;padding:0 20px;height:calc(100% - 60px);max-height:none;overflow:hidden}.g-bag-tools{display:flex;align-items:center;gap:10px;flex-wrap:wrap;flex:none;padding:0 0 10px}.g-bag-tools .g-button{min-height:35px;background:#090c0d;border-color:#565b55;color:#dadbd5;border-radius:6px;font-size:13px;padding:6px 11px}.g-bag-source-hint{flex:1;color:#9da29b;font-size:11px;min-width:130px}.g-distribution-dialog #gBagSearch{width:250px;min-height:35px;font-size:12px;background:#090c0d;border-color:#454d48;border-radius:6px;padding:7px 10px}
.g-bag-scroll{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#656e6566 transparent;padding:2px 3px 12px}.g-bag-group{--bag-color:#2782ff;display:grid;grid-template-columns:46px minmax(0,1fr);gap:14px;margin:0 0 12px}.g-bag-group.outsider{--bag-color:#31d0ef}.g-bag-group.minion{--bag-color:#ff8b20}.g-bag-group.demon{--bag-color:#f43131}.g-bag-group.traveller{--bag-color:#c6a4e6}.g-distribution-dialog .g-bag-group h3{display:flex;align-items:center;flex-direction:column;gap:6px;font-size:11px;line-height:1.5;font-weight:400;color:#adb0a8;margin:8px 0 0}.g-bag-type-count{display:grid;place-items:center;width:44px;height:44px;border:2px solid var(--bag-color);border-radius:50%;color:var(--bag-color);background:#080b0d;font:600 14px/1 system-ui,sans-serif;font-variant-numeric:tabular-nums}.g-bag-type-count.is-over{border-style:dashed}
.g-bag-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(114px,1fr));gap:9px 12px;align-items:start}.g-bag-choice{position:relative;min-width:0;max-width:148px;justify-self:center;width:100%}.g-distribution-dialog .g-role-option{width:100%;aspect-ratio:1;display:grid;place-items:center;position:relative;min-height:0;padding:3px;border:0;border-radius:50%;background:transparent;opacity:.42;touch-action:manipulation}.g-distribution-dialog .g-role-option:hover{opacity:.78;background:transparent}.g-distribution-dialog .is-selected .g-role-option{opacity:1;background:transparent}.g-distribution-dialog .g-role-option:disabled{cursor:default}.g-distribution-dialog .g-role-option:disabled:hover{opacity:.42}.g-distribution-dialog .is-selected .g-role-option:disabled:hover{opacity:1}.g-distribution-dialog .g-role-option .g-token{--token-size:120px;width:min(120px,100%);height:auto;aspect-ratio:1;margin:0;flex:none}.g-distribution-dialog .g-role-option .g-token>img:not(.g-token-leaf){width:76%;height:76%;margin-top:0;background:transparent;border-radius:0}.g-distribution-dialog .g-role-option .g-token-leaf{width:100%;height:100%;background:transparent;border-radius:0}.g-distribution-dialog .g-role-option:focus-visible{outline:2px solid #f4d587;outline-offset:0}.g-bag-quantity{position:absolute;right:3px;top:3px;border-radius:12px;background:#080c10e6;color:#f7d98d;font:600 12px/1.5 system-ui,sans-serif;min-width:24px;text-align:center;pointer-events:none}.g-bag-quantity:empty{display:none}.g-distribution-dialog .g-bag-minus{position:absolute;bottom:0;right:0;display:grid;place-items:center;min-height:30px;width:30px;padding:0;border:1px solid #b9a26a;border-radius:50%;background:#211d17;color:#f5d88d;font-size:22px;z-index:2}
.g-bag-empty{font-size:12px;line-height:1.6;color:#a4aaa2;margin:12px 0}.g-bag-grid .g-bag-empty{grid-column:1/-1}.g-bag-footer{flex:none;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px 14px;align-items:center;padding:12px 0 13px;border-top:1px solid #4a504655;background:#101213}.g-bag-settings{display:flex;align-items:flex-start;flex-direction:column;gap:5px}.g-distribution-dialog label.g-bag-duplicates{display:flex;flex-direction:row;gap:7px;align-items:center;margin:0;font-size:12px;line-height:1.5;color:#d1d7cf;cursor:pointer}.g-bag-duplicates input{width:14px;height:14px;margin:0;accent-color:#d9c078}.g-bag-total{font-size:12px;color:#9cacc1;font-variant-numeric:tabular-nums}.g-distribution-dialog #gBagClear{min-height:24px;padding:0;font-size:11px;color:#9ca39b;border:0;border-radius:3px;text-decoration:underline}.g-bag-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}.g-bag-actions .g-button{min-height:44px;border-radius:9px;padding:10px 17px;font-size:14px;white-space:nowrap}.g-bag-actions #gBagRandom{background:#080b0c;border:1px solid #70766d;color:#e3e4db}.g-bag-actions #gDistribute{background:#b30812;color:#fff;border:1px solid #e1242a}.g-bag-actions #gDistribute:hover{background:#d1111b}.g-bag-message{grid-column:1/-1;font-size:11px;line-height:1.6;color:#b4ab8e;overflow-wrap:anywhere;margin:0}
@media(max-width:700px){.g-dialog.g-distribution-dialog{width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-viewport-height,100dvh) - 12px);max-height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-distribution-dialog .g-modal-head{height:54px;padding:10px 12px}.g-distribution-dialog .g-modal-head h2{font-size:17px}.g-distribution-dialog .g-modal-body{height:calc(100% - 54px);padding:0 12px}.g-bag-tools{gap:6px;padding-bottom:8px}.g-bag-source-hint{font-size:10px}.g-distribution-dialog #gBagSearch{width:100%;font-size:16px;min-height:36px}.g-bag-group{grid-template-columns:34px minmax(0,1fr);gap:8px;margin-bottom:12px}.g-bag-type-count{width:34px;height:34px;font-size:11px}.g-distribution-dialog .g-bag-group h3{font-size:10px;gap:5px}.g-bag-grid{grid-template-columns:repeat(auto-fill,minmax(78px,1fr));gap:8px 5px}.g-distribution-dialog .g-role-option{padding:2px}.g-distribution-dialog .g-role-option .g-token{--token-size:96px;width:min(96px,100%)}.g-bag-footer{padding:9px 0;gap:7px}.g-bag-actions{gap:7px}.g-bag-actions .g-button{font-size:12px;padding:9px 10px}.g-bag-quantity{right:0;top:0;min-width:20px;font-size:11px}}
@media(max-width:480px){.g-bag-footer{grid-template-columns:1fr}.g-bag-settings{flex-direction:row;align-items:center;flex-wrap:wrap;gap:5px 12px}.g-distribution-dialog #gBagClear{margin-left:auto}.g-bag-actions{display:grid;grid-template-columns:1fr 1.4fr}.g-bag-actions .g-button{width:100%}.g-bag-message{font-size:10px}}
@media(max-height:500px) and (min-width:481px){.g-distribution-dialog .g-modal-head{height:46px;padding-block:7px}.g-distribution-dialog .g-modal-body{height:calc(100% - 46px)}.g-bag-tools{padding-bottom:5px}.g-bag-footer{padding-block:6px}.g-bag-settings{flex-direction:row;align-items:center;flex-wrap:wrap;gap:6px}.g-bag-message{font-size:10px}.g-bag-actions .g-button{min-height:38px;padding-block:7px}}
.g-bag-scroll[data-duplicates=true] .g-bag-choice{padding-bottom:40px}
.g-distribution-dialog .g-bag-minus,.g-distribution-dialog .g-bag-plus{position:absolute;bottom:0;right:auto;display:grid;place-items:center;min-height:34px;height:34px;width:34px;padding:0;border:1px solid #b9a26a;border-radius:50%;background:#211d17;color:#f5d88d;font-size:22px;line-height:1;z-index:2;touch-action:manipulation}
.g-distribution-dialog .g-bag-minus{left:calc(50% - 36px)}.g-distribution-dialog .g-bag-plus{left:calc(50% + 2px)}
.g-distribution-dialog .g-bag-plus:disabled{opacity:.35;cursor:default}
.g-night-dialog .g-night-step.dead{opacity:.5}.g-night-step.dead .g-night-number{background:#393d3e;color:#ccc}.g-night-step.dead .g-night-icon{filter:brightness(.6) saturate(.45)}.g-night-player.dead,.g-night-step:not(.dead) .g-night-actions.dead{opacity:.5}.g-night-step.dead .g-night-player.dead{opacity:1}.g-night-action-seat{font-size:11px;color:#acb4ad;align-self:center}.g-night-step.dead .g-night-actions.dead{opacity:1}
.g-role-wiki-link{align-self:start;min-height:32px;color:inherit;text-decoration:none;border-radius:5px;cursor:pointer}.g-role-wiki-link:hover{background:#efd08920}.g-role-wiki-link:focus-visible{outline:2px solid #e9cc73;outline-offset:2px}

/* Compact game summary; its folded control joins the left rail. */
.g-app .g-summary{top:4px;left:4px;width:354px;min-height:84px;padding:8px 28px 8px 10px;gap:10px;align-items:center;border:1px solid #080b0e;border-radius:0 8px 8px 0;background:#30363de8;box-shadow:0 2px 5px #0004}.g-summary .g-summary-logo{display:block;position:relative;flex:none;width:96px;height:58px;min-height:0;padding:0;border:0;border-radius:4px;background:transparent;overflow:hidden;cursor:pointer;transition:none!important;animation:none!important;transform:none!important}.g-summary-logo img{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none}.g-summary-logo[data-fallback=true] img{transform:scale(1.8)}.g-summary-logo:hover{background:#ffffff0a}.g-summary-logo:disabled{cursor:default;opacity:1}.g-app .g-summary #gTitle{font-size:18px;line-height:1.2;margin:0 0 2px;font-weight:750}.g-summary .g-composition{gap:6px;flex-wrap:wrap;font-size:13px;line-height:1.35}.g-summary-team{white-space:nowrap}.g-summary .g-summary-target{color:#aeb3b7}.g-summary .g-composition .townsfolk{color:#51a5f1}.g-summary .g-composition .outsider{color:#59d1d3}.g-summary .g-composition .minion{color:#ef8b58}.g-summary .g-composition .demon{color:#f4484d}.g-summary .g-counts{font-size:13px;line-height:1.5;color:#d2d5d6;white-space:nowrap}.g-summary .g-summary-toggle{position:absolute;top:4px;right:3px;display:grid;place-items:center;width:25px;height:28px;min-height:0;padding:0;border:0;border-radius:4px;background:transparent;color:#bdc2c4;font-size:24px;line-height:1;cursor:pointer;transform:none!important;transition:none!important;animation:none!important}.g-summary-toggle:hover{background:#ffffff16;color:#fff}.g-left-tools #gSummaryOpen{color:#e5e5e0}.g-left-tools #gSummaryOpen:focus-visible{outline-offset:0}
@media(max-width:700px){.g-app .g-summary{left:4px;top:4px;width:calc(100% - 96px);max-width:354px;min-height:72px;padding:6px 20px 6px 6px;gap:6px}.g-summary .g-summary-logo{width:46px;height:46px}.g-app .g-summary #gTitle{font-size:14px;line-height:1.25}.g-summary .g-composition{font-size:10px;gap:4px}.g-summary .g-counts{font-size:10.5px;line-height:1.4}.g-summary .g-summary-toggle{width:20px;height:30px;top:3px;right:0;font-size:20px}}
@media(max-height:600px) and (min-width:701px){.g-app .g-summary{width:320px;min-height:72px}.g-summary .g-summary-logo{width:70px;height:46px}}

/* Floating panels share a pointer and keyboard resize grip. Fixed layouts keep their own sizes. */
.g-notes-panel.is-floating,.g-side-panel.g-sheet-floating{box-sizing:border-box;width:var(--float-width,320px);height:var(--float-height,min(620px,calc(var(--g-viewport-height,100dvh) - 12px)));max-width:calc(var(--g-viewport-width,100vw) - 12px);max-height:calc(var(--g-viewport-height,100dvh) - 12px)}
.g-side-panel.g-sheet-floating{display:flex;flex-direction:column;width:var(--float-width,660px);height:var(--float-height,min(780px,calc(var(--g-viewport-height,100dvh) - 12px)))}
.g-side-panel.g-night-dialog.g-sheet-floating{width:var(--float-width,360px)}
.g-side-panel.g-sheet-floating .g-modal-head{flex:none;min-width:0}.g-side-panel.g-sheet-floating .g-modal-head h2{min-width:0}
.g-side-panel.g-sheet-floating .g-modal-body{flex:1;min-height:0;height:auto;padding-bottom:30px}
.g-side-panel.g-sheet-floating .g-sheet-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,250px),1fr))}
.g-notes-panel.is-floating .g-notes-footer{padding-right:30px}
.g-panel-resize.g-button{display:none;position:absolute;right:1px;bottom:1px;z-index:3;width:28px;height:28px;min-height:0;padding:0;border:0;border-radius:6px 0 8px 0;background:transparent;color:#969e9c;cursor:nwse-resize;touch-action:none;user-select:none;transform:none!important;transition:none!important;animation:none!important}
.g-notes-panel.is-floating>.g-panel-resize,.g-side-panel.g-sheet-floating>.g-panel-resize{display:block}
.g-panel-resize svg{position:absolute;right:6px;bottom:6px;width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.g-panel-resize.g-button:hover{background:#3e4548;color:#f3d78f}.g-panel-resize.g-button:focus-visible{outline:2px solid #edcb79;outline-offset:-3px}
.g-notes-panel.is-resizing,.g-side-panel.is-resizing{user-select:none;cursor:nwse-resize}
@media(pointer:coarse){.g-panel-resize.g-button{width:36px;height:36px}.g-notes-panel.is-floating .g-notes-footer{padding-right:38px}.g-side-panel.g-sheet-floating .g-modal-body{padding-bottom:38px}}

/* Compact player card opened from a seat name. */
.g-seat-dialog,.g-seat-dialog button{animation:none!important;transition:none!important}
.g-dialog.g-seat-dialog{width:480px;max-width:calc(var(--g-viewport-width,100vw) - 16px);max-height:calc(var(--g-viewport-height,100dvh) - 16px);border:2px solid #030404;border-radius:13px;background:#111413f7;color:#c1c4be;box-shadow:0 10px 45px #0008}
.g-seat-dialog .g-modal-head{padding:15px 20px 8px;border:0;background:transparent;gap:12px;position:relative;min-height:52px}
.g-seat-dialog #gDialogTitle{display:flex;align-items:center;gap:8px;flex:1;min-width:0;color:#b8bab5;font-size:20px;font-weight:600;line-height:1.3}
.g-seat-number{font-size:12px;color:#828983;flex:none}.g-seat-dialog #gSeatName{width:100%;min-width:0;max-width:270px;padding:2px 0;margin:0;border:0;border-radius:0;background:transparent;color:#e1e2dc;font:inherit;box-shadow:none;min-height:30px}
.g-seat-dialog #gSeatName::placeholder{color:#939990;opacity:.8}.g-seat-pencil{color:#737c75;font-size:15px;font-weight:400;flex:none}.g-seat-dialog #gDialogTitle .g-seat-pencil{margin-right:auto}
.g-seat-dialog #gDialogClose{width:32px;height:32px;min-height:32px;padding:0;border:2px solid #4b514e;border-radius:50%;background:transparent;color:#d3d7d0;font-size:24px;line-height:1;flex:none}
.g-seat-dialog .g-modal-body{padding:4px 20px 18px;max-height:calc(var(--g-viewport-height,100dvh) - 86px);overflow:auto;scrollbar-width:thin;scrollbar-gutter:stable}
.g-seat-profile{display:flex;align-items:flex-start;gap:12px;margin:0 0 6px;min-width:0}.g-seat-portrait{width:80px;flex:0 0 80px;padding:0;align-self:center}.g-seat-portrait .g-token{--token-size:80px;display:grid;width:80px;height:80px;box-shadow:0 2px 6px #0005;pointer-events:none}.g-seat-portrait.dead .g-token{filter:brightness(.5) saturate(.45)}
.g-seat-profile-copy{flex:1;min-width:0}.g-seat-profile-heading{display:flex;gap:5px;align-items:center;justify-content:space-between;min-height:26px}.g-seat-role-edit{display:flex!important;position:relative;align-items:baseline;gap:4px;min-width:0;margin:0!important;color:#469bfa;font-size:15px;font-weight:650;cursor:pointer}.g-seat-role-edit.outsider{color:#65c7e2}.g-seat-role-edit.minion{color:#e98c6d}.g-seat-role-edit.demon{color:#ef676c}.g-seat-role-edit.traveller{color:#b69cda}.g-seat-role-edit>span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.g-seat-team{font-size:12px;font-weight:400;color:#959c94;white-space:nowrap}.g-seat-role-edit #gSeatRole{position:absolute;inset:0;width:100%;height:100%;min-height:0;padding:0;margin:0;opacity:0;cursor:pointer}.g-seat-role-edit:focus-within{outline:2px solid #d9bd7a;outline-offset:3px;border-radius:2px}.g-seat-advice{color:#c8ac5c;font-size:11px;white-space:nowrap;text-decoration:none;flex:none}.g-seat-advice:hover{text-decoration:underline}
.g-seat-dialog label.g-seat-role-edit{flex-direction:row;color:#469bfa;font-size:15px}.g-seat-dialog .g-seat-role-edit.outsider{color:#65c7e2}.g-seat-dialog .g-seat-role-edit.minion{color:#e98c6d}.g-seat-dialog .g-seat-role-edit.demon{color:#ef676c}.g-seat-dialog .g-seat-role-edit.traveller{color:#b69cda}
.g-seat-ability{margin:3px 0 0;padding:7px 9px;border-radius:7px;background:#ffffff0a;color:#c5c9c0;font-size:12px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere}
.g-seat-status{margin:0 0 11px;color:#7f8b80;font-size:11px}.g-seat-status>summary{cursor:pointer;width:max-content;max-width:100%;padding:3px 0;min-height:24px}.g-seat-status-tools{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:6px 0}.g-seat-status-tools .g-button{font-size:11px;min-height:30px;padding:4px 8px}.g-seat-status-tools label{display:flex;align-items:center;gap:5px;margin:0;font-size:11px}.g-seat-status-tools select{width:auto;font-size:11px;padding:4px 6px;min-height:30px;margin:0;background:#101411}
.g-seat-dialog details.g-seat-status{margin:0 0 11px;padding:0;border:0}.g-seat-dialog .g-seat-status>summary{display:list-item;min-height:24px;font-size:11px;color:#8c9986}.g-seat-status-tools label{flex-direction:row}
.g-seat-dialog h3{margin:0 0 7px;font-size:12px;font-weight:650;color:#899087}.g-seat-reminder-section{margin:0 0 14px}.g-seat-reminder-list{display:flex;gap:7px;flex-wrap:wrap}.g-seat-reminder-list:empty{display:none}.g-seat-reminder-list .g-reminder-token{position:relative;inset:auto;width:46px;height:46px;margin:0 0 7px;flex:none}.g-seat-dialog .g-seat-add-marker{display:block;border:1px dashed #485148;border-radius:12px;background:transparent;padding:1px 10px;min-height:24px;font-size:11px;color:#a5ada3}
.g-seat-note-form{padding:7px 8px 6px;border:2px solid #030604;border-radius:9px;background:#090c0b}.g-seat-dialog #gSeatNoteText{display:block;width:100%;min-height:50px;height:50px;max-height:180px;margin:0 0 7px;padding:1px 1px 4px;border:0;border-radius:0;resize:vertical;background:transparent;box-shadow:none;color:#d6dbd2;font:inherit;font-size:13px;line-height:1.6}.g-seat-dialog #gSeatNoteText::placeholder{color:#707a6e;opacity:1}.g-seat-note-tools{display:flex;align-items:center;gap:4px;flex-wrap:wrap}.g-seat-dialog .g-seat-note-chip{padding:1px 6px;min-height:22px;border:1px solid #343d33;border-radius:12px;background:transparent;font-size:10px;font-weight:400;color:#a1ab9b}.g-seat-note-status{font-size:10px;color:#859b77;flex:1;min-width:0;overflow-wrap:anywhere}.g-seat-dialog .g-seat-note-record{margin-left:auto;padding:3px 9px;min-height:27px;background:#11170f;border:1px solid #030603;border-radius:8px;color:#c4d1ba;font-size:11px}.g-seat-note-record:disabled{opacity:.35}
.g-seat-note-list{list-style:none;margin:0;padding:0;max-height:220px;overflow:auto;scrollbar-width:thin}.g-seat-note-list li{position:relative;margin:7px 0 0;padding:8px 28px 8px 9px;border:1px solid #30382f;border-radius:7px;background:#ffffff03}.g-seat-note-list small{font-size:10px;color:#8e9b84}.g-seat-note-list p{margin:3px 0 0;font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere;color:#c8d0c2}.g-seat-dialog .g-seat-note-remove{position:absolute;right:3px;top:4px;width:24px;height:24px;min-height:24px;padding:0;background:transparent;border:0;color:#8c9786;font-size:18px}
.g-seat-actions{display:flex;gap:8px;margin-top:12px}.g-seat-actions .g-button{min-height:40px;padding:7px 10px;border:2px solid #030604;border-radius:9px;background:#090d0b;font-size:13px;color:#c4c8bf;white-space:nowrap}.g-seat-actions .g-seat-clear-role{flex:1}.g-seat-actions .danger{color:#d98983}.g-seat-swap-form{display:flex;align-items:flex-end;gap:7px;margin-top:10px}.g-seat-swap-form label{flex:1;min-width:0;font-size:12px;margin:0}.g-seat-swap-form select{margin:5px 0 0;padding:6px;font-size:12px;min-height:34px}.g-seat-swap-form .g-button{font-size:12px;padding:6px;min-height:34px}.g-seat-dialog button:hover:not(:disabled){filter:brightness(1.2)}
@media(max-width:480px){.g-seat-dialog .g-modal-head{padding:12px 12px 8px}.g-seat-dialog .g-modal-body{padding:4px 12px 12px}.g-seat-dialog #gSeatName{font-size:18px}.g-seat-portrait,.g-seat-portrait .g-token{--token-size:68px;width:68px;height:68px}.g-seat-portrait{flex-basis:68px}.g-seat-profile{gap:9px}.g-seat-profile-heading{flex-wrap:wrap;gap:3px}.g-seat-role-edit{font-size:14px}.g-seat-advice{font-size:10px}.g-seat-ability{font-size:12px;padding:6px 7px}.g-seat-actions{gap:5px}.g-seat-actions .g-button{font-size:12px;padding:6px 8px;min-height:40px}.g-seat-dialog #gSeatNoteText{font-size:16px;min-height:56px}.g-seat-dialog .g-seat-note-chip{min-height:28px}.g-seat-dialog .g-seat-note-record{min-height:30px}.g-seat-note-status{flex-basis:30px}.g-seat-dialog .g-seat-add-marker{min-height:30px}}
@media(max-height:500px){.g-seat-dialog .g-modal-body{max-height:calc(var(--g-viewport-height,100dvh) - 78px)}.g-seat-dialog .g-modal-head{padding-top:8px;min-height:44px}}

/* Prepare an explicit message, then cover the entire grimoire for the player. */
.g-signal-compose button{animation:none!important;transition:none!important}
.g-dialog.g-signal-compose{width:520px;max-width:calc(var(--g-viewport-width,100vw) - 16px);max-height:calc(var(--g-viewport-height,100dvh) - 16px);border:2px solid #030504;border-radius:12px;background:#111413f7;color:#c6cac1;animation:none!important;transition:none!important}
.g-signal-compose .g-modal-head{position:relative;min-height:56px;padding:15px 20px 8px;gap:12px;border:0;background:transparent}.g-signal-compose .g-modal-head h2{font-family:KaiTi,STKaiti,"Songti SC",serif;font-size:23px;font-weight:650;color:#e6e8df}.g-signal-compose #gDialogClose{flex:none;width:32px;height:32px;min-height:32px;padding:0;border:2px solid #4d534d;border-radius:50%;background:transparent;color:#d7dcd1;font-size:23px;line-height:1}
.g-signal-compose .g-modal-body{padding:4px 20px 20px;max-height:calc(var(--g-viewport-height,100dvh) - 88px);scrollbar-width:thin;scrollbar-gutter:stable}.g-signal-help{margin:0 0 12px;color:#91998e;font-size:12px;line-height:1.75}
.g-signal-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.g-signal-compose .g-signal-option{justify-content:flex-start;min-width:0;min-height:32px;padding:5px 8px;border:2px solid #030604;border-radius:8px;background:#090d0a;color:#a3aca0;font-size:12px;line-height:1.4;text-align:left;white-space:normal;overflow-wrap:anywhere;animation:none!important;transition:none!important}.g-signal-compose .g-signal-option[aria-pressed=true]{background:#373315;border-color:#efd000;color:#fff1b2}.g-signal-compose .g-signal-option:hover{border-color:#848263;color:#f1efdb}
.g-signal-attachments{margin:14px 0 12px}.g-signal-compose h3,.g-signal-compose label{margin:0 0 8px;color:#8e9889;font-size:12px;font-weight:650}.g-signal-slots{display:flex;gap:9px;flex-wrap:wrap}.g-signal-slot{position:relative;width:80px;height:80px;flex:none}.g-signal-compose .g-signal-role{display:block;width:80px;height:80px;min-height:0;padding:0;border:0;border-radius:50%;background:transparent;animation:none!important;transition:none!important}.g-signal-slot .g-token{--token-size:80px;width:80px;height:80px;box-shadow:0 2px 7px #0004;pointer-events:none}.g-signal-empty>span{font-size:25px;color:#8a8871;font-weight:400}.g-signal-compose .g-signal-role-remove{position:absolute;top:-2px;right:-3px;z-index:2;width:23px;height:23px;min-height:23px;padding:0;border:1px solid #737966;border-radius:50%;background:#171e15;color:#dddaca;font-size:17px;line-height:1}
.g-signal-compose #gSignalCustom{width:100%;min-height:37px;padding:7px 10px;border:2px solid #030604;border-radius:8px;background:#090d0a;font-size:13px;color:#e1e4d9}.g-signal-compose #gSignalCustom::placeholder{color:#737d6d;opacity:1}.g-signal-compose .g-signal-show{display:flex;width:100%;min-height:40px;justify-content:center;margin-top:12px;padding:8px 14px;border:2px solid #030604;border-radius:8px;background:#c80008;color:#fff;font-size:14px;font-weight:700}.g-signal-compose .g-signal-show:hover{background:#e01921}
#gDialog.g-signal-player{background:#090d10!important;animation:none!important;transition:none!important}.g-signal-player .g-modal-head{display:none}.g-signal-player .g-modal-body{display:block;height:100%;max-height:100%;padding:0;overflow:auto;background:#090d10}.g-signal-player .g-signal-screen{box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:clamp(20px,4vh,48px);width:100%;min-height:100%;margin:0;padding:clamp(24px,5vw,64px);border:0;border-radius:0;background:#090d10!important;color:#eee4cb;cursor:pointer;text-align:center;white-space:normal;animation:none!important;transition:none!important;transform:none!important}.g-signal-screen>strong{max-width:1100px;font-size:clamp(30px,6vw,76px);font-weight:750;line-height:1.45;overflow-wrap:anywhere;white-space:pre-wrap}.g-signal-screen>small{font-size:13px;font-weight:400;color:#8b978e}.g-signal-screen:focus-visible{outline:2px solid #d6bc78;outline-offset:-6px}.g-signal-player-roles{display:flex;justify-content:center;flex-wrap:wrap;gap:clamp(12px,4vw,50px);max-width:100%}.g-signal-player-roles .g-token{--token-size:clamp(84px,18vw,200px);width:var(--token-size);height:var(--token-size);pointer-events:none}
#gDialog.g-signal-player #gSignalScreen{min-height:var(--g-viewport-height,100dvh)}
@media(max-width:700px){.g-signal-compose .g-modal-head{padding:12px 12px 8px;min-height:52px}.g-signal-compose .g-modal-body{padding:4px 12px 12px;max-height:calc(var(--g-viewport-height,100dvh) - 80px)}.g-signal-options{gap:5px}.g-signal-compose .g-signal-option{min-height:39px;padding:5px 6px;font-size:11px}.g-signal-help{font-size:11px;margin-bottom:10px}.g-signal-compose #gSignalCustom{font-size:16px;min-height:42px}.g-signal-compose .g-signal-show{min-height:43px}.g-signal-slot,.g-signal-compose .g-signal-role,.g-signal-slot .g-token{--token-size:76px;width:76px;height:76px}.g-signal-player .g-signal-screen{padding:24px 16px}.g-signal-player-roles .g-token{--token-size:clamp(76px,25vw,130px)}}
@media(max-width:360px){.g-signal-options{grid-template-columns:repeat(2,minmax(0,1fr))}.g-signal-player-roles{gap:10px}}
@media(max-height:500px) and (min-width:701px){.g-signal-compose .g-modal-head{min-height:44px;padding-top:8px}.g-signal-compose .g-modal-body{max-height:calc(var(--g-viewport-height,100dvh) - 72px)}.g-signal-player .g-signal-screen{padding:20px 28px;gap:16px}.g-signal-player-roles .g-token{--token-size:clamp(80px,22vh,130px)}.g-signal-screen>strong{font-size:clamp(28px,5vw,48px)}}

/* Individual assignment can browse the complete catalog without changing the draft game. */
.g-seat-role-picker .g-seat-role-toolbar{position:sticky;top:-14px;z-index:4;padding:12px 0 8px;background:#101416fa}.g-seat-role-search{display:flex;align-items:center;gap:8px;margin:0 0 9px}.g-seat-role-search #gTokenSearch{flex:1;min-width:0;margin:0}.g-seat-role-picker .g-seat-role-search .g-button{flex:none;min-height:35px;padding:6px 11px;white-space:nowrap;background:#242b2c;border-color:#4a534c;font-size:12px}.g-seat-role-picker #gSeatRoleScope[aria-pressed=true]{background:#494a3c;border-color:#bdbb96;color:#f0eacd}.g-seat-role-picker #gDialogClose{width:32px;height:32px;min-height:32px;padding:0;border-radius:50%;font-size:23px;line-height:1}
.g-role-source-filters{display:flex;align-items:flex-start;gap:8px;margin-bottom:8px}.g-role-filter-label{flex:none;color:#939c93;font-size:11px;line-height:26px}.g-role-source-buttons{display:flex;align-items:center;flex-wrap:wrap;gap:5px}.g-seat-role-picker .g-role-source-buttons .g-button{min-height:25px;padding:3px 9px;border-radius:15px;border:1px solid #5b6459;background:#090e10;color:#aeb7ac;font-size:11px;line-height:1.4;font-weight:500}.g-seat-role-picker .g-role-source-buttons .g-button[aria-pressed=true]{border-color:#e3dfc8;background:#4a5147;color:#fff9e5}.g-seat-role-picker .g-seat-role-types{margin-bottom:8px}.g-seat-role-picker .g-seat-role-types .g-button{min-height:26px;padding:3px 10px;font-size:11px}.g-seat-role-picker .g-role-more-filters{display:flex;flex-direction:row;align-items:center;gap:8px;margin:0;font-size:11px}.g-seat-role-picker #gRoleCategory{width:auto;max-width:320px;min-width:0;min-height:29px;margin:0;padding:4px 28px 4px 8px;background:#090e10;border-color:#4a564d;border-radius:14px;font-size:11px}
.g-bag-sources{flex:none;min-width:0}.g-bag-sources[hidden],.g-bag-selected[hidden]{display:none}.g-distribution-dialog .g-bag-sources .g-button{min-height:28px;padding:3px 9px;border-radius:15px;border:1px solid #5b6459;background:#090e10;color:#aeb7ac;font-size:11px;line-height:1.4;font-weight:500;white-space:nowrap}.g-distribution-dialog .g-bag-sources .g-button[aria-pressed=true]{border-color:#e3dfc8;background:#4a5147;color:#fff9e5}.g-bag-selected{margin:2px 0 15px;padding:10px;border:1px solid #41463f;border-radius:7px}.g-distribution-dialog .g-bag-selected h3{margin:0 0 6px;color:#aaa99b;font-size:12px}.g-bag-selected-grid{display:flex;flex-wrap:wrap;gap:8px}.g-distribution-dialog .g-bag-selected-role{position:relative;flex:none;width:108px;min-height:0;padding:2px;border:0;border-radius:50%;background:transparent;box-shadow:none}.g-bag-selected-role .g-token{--token-size:104px;width:100%;aspect-ratio:1}.g-bag-selected-role:hover{filter:brightness(1.15)}.g-bag-selected-role:focus-visible{outline:2px solid #efd48d;outline-offset:2px}
@media(max-width:700px),(max-height:500px){.g-bag-sources .g-role-source-buttons{flex-wrap:nowrap;overflow-x:auto;min-width:0;padding:0 0 4px;scrollbar-width:thin}.g-distribution-dialog .g-bag-sources .g-button{flex:none;min-height:30px}.g-bag-sources{margin-bottom:5px}.g-bag-selected{padding:7px;margin-bottom:10px}.g-distribution-dialog .g-bag-selected-role{width:84px}.g-bag-selected-role .g-token{--token-size:80px}.g-bag-selected-grid{gap:5px}}
.g-seat-role-picker .g-seat-role-status{font-size:11px;line-height:1.6;margin:7px 0;color:#909c92}.g-seat-role-picker .g-role-scope-section>.g-role-scope-title{margin:16px 0 12px;padding-bottom:7px;border-bottom:1px solid #414b42;font-size:12px;font-weight:650;color:#aeb7a8}.g-seat-role-picker .g-token-group.minion h3{color:#eda45c}.g-seat-role-picker .g-token-group.demon h3{color:#ed6a64}.g-seat-role-picker .g-token-group.traveller h3{color:#c097da}
@media(max-width:700px){.g-seat-role-picker .g-seat-role-toolbar{position:static;padding:0 0 7px}.g-seat-role-search{flex-wrap:wrap;gap:6px}.g-seat-role-search #gTokenSearch{flex-basis:100%;font-size:16px;min-height:40px}.g-seat-role-picker .g-seat-role-search .g-button{min-height:34px}.g-seat-role-picker .g-role-source-buttons .g-button{min-height:30px;padding:4px 8px}.g-role-filter-label{line-height:30px}.g-seat-role-picker .g-seat-role-types .g-button{min-height:30px;padding:4px 9px}.g-seat-role-picker #gRoleCategory{flex:1;max-width:calc(100% - 38px);min-height:34px;font-size:12px}.g-seat-role-picker .g-seat-role-status{font-size:10px}}

/* Keep custom imports and their confirmation in one compact, scrollable workspace. */
.g-script-dialog[data-script-tab=custom]{height:min(680px,calc(var(--g-viewport-height,100dvh) - 24px))}#gScriptView_custom{display:flex;flex-direction:column;overflow:hidden;padding-bottom:0}.g-script-custom-scroll{display:flex;flex:1;min-height:0;flex-direction:column;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;padding:0 2px 10px}.g-script-custom-scroll>div{flex:none}.g-script-dialog #gScriptCurrent{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;margin-bottom:12px;padding:8px 10px}.g-script-current>span{flex:1;min-width:180px;font-weight:600}.g-script-dialog #gScriptOfficialShortcut{flex:none;min-height:27px;padding:3px 7px;border:0;background:transparent;color:#edd382;font-size:11px;text-decoration:underline;text-underline-offset:3px}.g-script-dialog .g-script-recent h3{margin:0 0 7px;color:#939b8e}.g-script-recent-chips{max-height:116px;overflow:auto;scrollbar-width:thin;align-items:flex-start}.g-script-recent-chip{max-width:100%;border-color:#363d34;background:#080b09}.g-script-recent-chip.is-current{border-color:#a48c47;background:#342d1955}.g-script-dialog .g-script-recent-chip .g-button:first-child{display:flex;gap:4px;align-items:center;min-width:0;max-width:260px;text-align:left}.g-script-recent-name{font-size:13px;font-weight:600;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.g-script-recent-chip small{flex:none;color:#818a7b;font-size:11px}.g-script-dialog .g-script-recent-chip .g-button:last-child{width:26px;min-width:26px;align-self:stretch;padding:5px;color:#7c8876}.g-script-recent-chip svg{width:13px;height:13px;fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round}.g-script-dialog .g-script-recent-chip .g-button:last-child:hover{background:#7c302033;color:#f6b1a0}.g-script-recent-empty{margin:0 0 12px;color:#808d7e;font-size:11px;line-height:1.7}.g-script-dialog .g-script-file-tools{margin-bottom:9px;gap:6px}.g-script-dialog #gScriptDraft{border-color:transparent;background:transparent;color:#a8b79c;padding-inline:4px}.g-script-dialog .g-script-editor-link{font-size:11px}.g-script-dialog .g-script-url-row{margin-bottom:10px}.g-script-dialog .g-script-custom-scroll #gScriptJSON{flex:1 0 180px;min-height:180px;max-height:none;height:auto;resize:vertical;margin:0;border-color:#343e35;border-radius:6px}.g-script-dialog .g-script-custom-scroll #gScriptJSON:focus{border-color:#b69b53;outline-color:#b69b53}.g-script-custom-footer{flex:none;padding:10px 0 0;border-top:1px solid #48524166}.g-script-custom-actions{display:flex;align-items:center;justify-content:space-between;gap:12px}.g-script-custom-actions .g-script-help{flex:1;margin:0;font-size:11px;line-height:1.6}.g-script-dialog .g-script-custom-actions #gScriptLoad{flex:none;min-height:38px;margin:0;padding:8px 22px;border:1px solid #d6b663;background:#c9ac68;color:#1b1b12;border-radius:6px}.g-script-custom-footer .g-script-status{margin:0 0 8px;max-height:min(100px,20dvh);overflow:auto}.g-script-custom-scroll #gScriptImportList:empty{display:none}.g-script-custom-scroll #gScriptImportList{flex:none;max-height:230px;overflow:auto;margin:0 0 10px}.g-script-custom-scroll #gScriptImportList .g-script-help{margin-bottom:3px}
@media(max-width:700px){.g-script-dialog[data-script-tab=custom]{height:calc(var(--g-viewport-height,100dvh) - 12px)}.g-script-custom-scroll{padding-bottom:8px}.g-script-dialog #gScriptCurrent{gap:3px;padding:7px 9px;font-size:11px;margin-bottom:10px}.g-script-current>span{min-width:0;flex-basis:100%}.g-script-dialog #gScriptOfficialShortcut{padding-left:0}.g-script-dialog .g-script-recent-chip .g-button{min-height:36px}.g-script-dialog .g-script-recent-chip .g-button:first-child{max-width:calc(var(--g-viewport-width,100vw) - 84px);font-size:12px}.g-script-recent-chips{max-height:82px;margin-bottom:9px}.g-script-dialog .g-script-file-tools .g-button{min-height:36px;padding:6px 8px}.g-script-dialog #gScriptDraft{padding-inline:2px}.g-script-dialog .g-script-custom-scroll #gScriptJSON{flex-basis:160px;min-height:160px}.g-script-custom-footer{padding-top:8px}.g-script-custom-actions{gap:8px}.g-script-custom-actions .g-script-help{font-size:10px}.g-script-dialog .g-script-custom-actions #gScriptLoad{min-height:40px;padding-inline:15px}.g-script-custom-footer .g-script-status{padding:6px 8px;font-size:11px}}
@media(max-height:500px) and (min-width:701px){.g-script-recent-chips{max-height:78px}.g-script-dialog #gScriptCurrent{margin-bottom:8px}.g-script-custom-scroll{padding-bottom:7px}.g-script-dialog .g-script-custom-scroll #gScriptJSON{min-height:120px;flex-basis:120px}.g-script-custom-footer{padding-top:6px}.g-script-dialog .g-script-custom-actions #gScriptLoad{min-height:34px;padding-block:5px}.g-script-custom-footer .g-script-status{margin-bottom:5px;max-height:65px}}

/* Small desktop windows retain their horizontal control bar; tablets use desktop corners. */
@media (pointer:fine) and (min-width:701px) and (max-width:1099px) and (min-height:600px){
 .g-app .g-dock{left:50%;right:auto;bottom:max(8px,env(safe-area-inset-bottom));transform:translateX(-50%);width:min(640px,calc(100% - 112px));padding:8px 10px}
 #gControlBody{display:flex;align-items:center;gap:8px}.g-dock .g-primary-tools{flex:1;margin:0}.g-dock .g-advance{flex:1;width:auto;margin:0}.g-dock .g-seat-stepper{min-width:128px}.g-dock .g-privacy{display:none}.g-dock .g-control-heading{margin-bottom:6px}
 .g-board.list-mode{bottom:112px;padding-bottom:20px}
}
@media (pointer:coarse){
 .g-app{min-height:0}.grimoire-page{overscroll-behavior:none}
 .g-side-panel .g-side-close,.g-notes-panel .g-notes-close{width:36px;height:36px;min-height:36px}
 .g-side-panel .g-modal-head,.g-notes-head{min-height:48px;height:48px}
 .g-side-panel :is(#gSheetFloat,#gNightFloat),.g-notes-panel #gNotesFloat{min-height:36px;padding:4px 10px}
 .g-dock .g-button,.g-dock .g-step,.g-dock .g-fold{min-height:40px}
 .g-dock .g-seat-stepper{height:40px}
 .g-timer-panel #gTimerClose{width:36px;height:36px;min-height:36px}
 .g-app .g-seat-advice{display:inline-flex;align-items:center;min-height:32px}
}
@media (pointer:coarse) and (max-height:500px){
 .g-app .g-dock{width:220px;padding:6px 8px}.g-dock .g-button,.g-dock .g-step,.g-dock .g-fold{min-height:34px}.g-dock .g-seat-stepper{height:34px}
 .g-app .g-summary{min-height:64px}.g-board.list-mode{top:88px;bottom:8px;padding-bottom:190px}.g-side-tools{gap:4px}
 .g-right-tools .g-rail-button{min-height:42px;padding:5px 6px;line-height:1.1;writing-mode:horizontal-tb;letter-spacing:0}
}

/* Phone tables keep the circular seating map; fine-pointer desktop layouts are unchanged. */
.g-phone-ui .g-board.phone-table{inset:0 0 calc(var(--g-bottom-height,170px) + max(8px,env(safe-area-inset-bottom)) + 16px);overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-gutter:stable;touch-action:pan-x pan-y pinch-zoom}
.g-phone-ui .g-board.phone-table[data-wide=true]{overflow-x:auto}
.g-phone-ui .phone-table .g-seats{width:var(--g-phone-width,100%);height:var(--g-phone-height,100%);bottom:auto}
.g-phone-ui .phone-table .g-center{left:calc(var(--g-phone-width,var(--g-viewport-width,100vw))*.5)}
.g-phone-ui .phone-table .g-seat{width:calc(var(--token-size) + 14px);min-height:0;padding:0;gap:0;border:0;background:transparent;border-radius:50%;transform:translate(-50%,calc(var(--token-size)*-.5))}
.g-phone-ui .phone-table .g-seat-caption{width:var(--g-phone-caption-width);max-width:var(--g-phone-caption-width);min-height:22px}
.g-phone-ui .phone-table .g-seat .g-seat-name{width:100%;min-height:22px;max-width:100%;padding:1px 3px;border-radius:10px;border-color:#b6a58a;background:#21180edb;font-size:10px;line-height:1.3}
.g-phone-ui .phone-table .g-seat .g-token-order{--night-badge-size:24px;width:24px;height:24px;font-size:13px;border-width:2px}
.g-phone-ui .phone-table .g-seat .g-reminder-tokens{--reminder-size:40px}
.g-phone-ui .phone-table .g-seat .g-reminder-add{background:transparent;border-color:transparent;box-shadow:none}
.g-phone-ui .phone-table .g-seat .g-reminder-add:before{content:'+';font-size:28px;color:#d9c293;text-shadow:0 1px 2px #0009}
.g-app.g-phone-ui .g-dock{left:auto;right:max(8px,env(safe-area-inset-right));width:min(194px,calc(var(--g-viewport-width,100vw) - 88px));padding:6px 8px;transform:none}
.g-phone-ui #gControlBody{display:block}
.g-phone-ui .g-control-heading{min-height:30px;margin-bottom:4px;gap:6px}
.g-phone-ui .g-dock .g-fold{min-height:30px;height:30px}
.g-phone-ui .g-dock .g-button{min-height:36px;padding:5px 6px;font-size:12px}
.g-phone-ui .g-primary-tools{margin-bottom:5px;gap:5px}
.g-phone-ui .g-dock .g-advance{width:100%;margin-bottom:5px}
.g-phone-ui .g-dock .g-seat-stepper{min-width:0;height:32px;font-size:12px}
.g-phone-ui .g-dock .g-step{min-height:32px;height:32px}
.g-phone-ui .g-dock .g-privacy{display:none}
@media(max-height:499px){.g-phone-ui .g-board.phone-table{left:40px;right:218px;bottom:0}}

/* Portrait phones keep the three bluff slots beside the game controls, like the live table. */
@media(min-height:500px){
 .g-app.g-phone-ui{--g-phone-dock-width:clamp(142px,calc(var(--g-viewport-width,100vw)*.4),190px)}
 .g-app.g-phone-ui .g-dock{width:var(--g-phone-dock-width)}
 .g-phone-ui .g-dock .g-primary-tools{grid-template-columns:repeat(2,minmax(0,1fr))}
 .g-phone-ui .g-dock .g-primary-tools .g-button{padding-inline:2px;white-space:nowrap}
 .g-phone-ui .g-bluffs{bottom:max(8px,env(safe-area-inset-bottom))}
 .g-app.g-phone-ui .g-bluff-panel{left:calc(32px + env(safe-area-inset-left));right:auto;bottom:max(8px,env(safe-area-inset-bottom));width:calc(var(--g-viewport-width,100vw) - var(--g-phone-dock-width) - 52px - env(safe-area-inset-left) - env(safe-area-inset-right));max-height:calc(var(--g-viewport-height,100dvh) - 140px);padding:6px;--g-bluff-token-size:clamp(30px,calc((var(--g-viewport-width,100vw) - var(--g-phone-dock-width) - 78px - env(safe-area-inset-left) - env(safe-area-inset-right))/3),64px)}
 .g-phone-ui .g-bluff-panel .g-aux-heading{gap:2px;margin-bottom:2px}
 .g-phone-ui .g-bluff-panel .g-aux-heading h2{font-size:11px;white-space:nowrap}
 .g-phone-ui .g-bluff-panel .g-bluff-show{font-size:0;width:28px;min-width:28px;min-height:30px;padding:0}
 .g-phone-ui .g-bluff-panel .g-bluff-show:before{content:'◉';font-size:15px}
 .g-phone-ui .g-bluff-panel .g-aux-close{width:26px;min-width:26px;min-height:30px;height:30px}
 .g-phone-ui .g-bluff-panel .g-bluff-slots{gap:3px}
 .g-phone-ui .g-bluff-panel .g-catalog-token{min-height:36px;padding:4px 0}
 .g-phone-ui .g-bluff-panel .g-token{--token-size:var(--g-bluff-token-size);width:var(--g-bluff-token-size);height:var(--g-bluff-token-size)}
 .g-phone-ui .g-bluff-panel .g-aux-warning{font-size:10px;line-height:1.4;margin-top:3px}
 .g-phone-ui .g-board.list-mode{bottom:calc(var(--g-bottom-height,170px) + env(safe-area-inset-bottom) + 16px)}
}
.g-app.g-tablet-ui .g-dock{left:auto;right:max(12px,env(safe-area-inset-right));bottom:max(12px,env(safe-area-inset-bottom));transform:none;width:270px}
.g-tablet-ui #gControlBody{display:block}
.g-tablet-ui .g-board.list-mode{bottom:calc(var(--g-dock-height,200px) + max(12px,env(safe-area-inset-bottom)) + 12px);padding-bottom:20px}
@media(max-width:999px) and (min-height:500px){.g-app.g-tablet-ui .g-dock{width:240px}}

/* Touch rails stay clear of notches; short landscapes keep controls beside the scrolling roster. */
@media (pointer:coarse){
 .g-app .g-summary{left:max(4px,env(safe-area-inset-left));top:max(4px,env(safe-area-inset-top))}.g-view-actions{right:max(8px,env(safe-area-inset-right));top:max(8px,env(safe-area-inset-top))}
 .g-left-tools,.g-bluffs{left:env(safe-area-inset-left)}.g-right-tools{right:env(safe-area-inset-right)}
 #gDialog:not(.g-signal-player){inset-inline-start:env(safe-area-inset-left);inset-inline-end:env(safe-area-inset-right);max-width:calc(var(--g-viewport-width,100vw) - env(safe-area-inset-left) - env(safe-area-inset-right) - 16px)}
 .g-notes-panel:not(.is-floating){left:calc(46px + env(safe-area-inset-left));max-width:calc(var(--g-viewport-width,100vw) - env(safe-area-inset-left) - env(safe-area-inset-right) - 92px)}
 .g-side-panel.g-sheet-dialog:not(.g-sheet-floating){right:calc(var(--side-right,46px) + env(safe-area-inset-right));max-width:calc(var(--g-viewport-width,100vw) - env(safe-area-inset-left) - env(safe-area-inset-right) - 80px)}
 .g-app .g-timer-panel{left:calc(46px + env(safe-area-inset-left))}
 .g-side-panel .g-modal-body{height:calc(100% - 48px)}.g-side-panel.g-sheet-floating .g-modal-body{height:auto}
}
@media (pointer:coarse) and (max-width:700px){
 .g-notes-panel:not(.is-floating){left:calc(40px + env(safe-area-inset-left));max-width:calc(var(--g-viewport-width,100vw) - env(safe-area-inset-left) - env(safe-area-inset-right) - 80px)}
 .g-app .g-timer-panel{left:calc(40px + env(safe-area-inset-left));right:calc(40px + env(safe-area-inset-right))}
}
/* The keyboard can shrink and pan the visible viewport without resizing the page. */
@media(pointer:coarse){
 .g-app input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]),.g-app textarea,.g-app select{font-size:16px!important}
 .g-app #gSeatName{font-size:18px!important}
 #gDialog:not(.g-signal-player){inset-block-start:var(--g-visible-top,0px);inset-block-end:var(--g-visible-bottom,0px);max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 16px)}
 #gDialog:not(.g-signal-player):not(.g-script-dialog) .g-modal-body{max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 90px)}
 .g-notes-panel:not(.is-floating){top:max(calc(var(--g-summary-bottom,132px) + 16px),calc(var(--g-visible-top,0px) + 8px));height:min(620px,calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - max(0px,calc(var(--g-summary-bottom,132px) + 16px - var(--g-visible-top,0px))) - 16px));max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 16px)}
 .g-notes-panel.is-floating,.g-side-panel.g-sheet-floating{max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 12px)}
 .g-side-panel.g-sheet-dialog:not(.g-sheet-floating){top:max(var(--g-side-top,70px),calc(var(--g-visible-top,0px) + 8px));max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - max(0px,calc(var(--g-side-top,70px) - var(--g-visible-top,0px))) - 16px)}
 .g-app .g-timer-panel{max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 16px)}
}
@media (pointer:coarse) and (max-width:700px) and (min-height:501px){.g-board.list-mode{bottom:calc(var(--g-dock-height,164px) + env(safe-area-inset-bottom) + 16px)}}
@media (pointer:coarse) and (max-height:500px){
 .g-bluffs{bottom:max(8px,env(safe-area-inset-bottom))}.g-app .g-dock,.g-app.g-phone-ui .g-dock{right:calc(40px + env(safe-area-inset-right))}
 .g-board.list-mode{left:calc(40px + env(safe-area-inset-left));right:calc(276px + env(safe-area-inset-right));padding:8px 6px 12px}
 .g-board.list-mode .g-seats{grid-template-columns:repeat(auto-fill,minmax(min(100%,140px),1fr))}
}

/* Matte charcoal surfaces: quiet edges, shallow highlights, no moving geometry. */
.grimoire-page .g-app{--g-border:#77766b66;--g-gold:#dcc28b;--g-muted:#b8b9af;--g-panel-fill:linear-gradient(145deg,#242829f7,#13191af7);--g-panel-shadow:0 12px 30px #03080755,inset 0 1px #f2e7c509}
.grimoire-page .g-app :is(.g-notes-panel,.g-side-panel.g-sheet-dialog,.g-aux-panel,.g-timer-panel){background:var(--g-panel-fill);border-color:var(--g-border);box-shadow:var(--g-panel-shadow);backdrop-filter:blur(6px)}
.grimoire-page .g-app :is(.g-notes-head,.g-side-panel .g-modal-head){background:#292e2db3;border-bottom-color:#cfbf9629}
.grimoire-page .g-app .g-notes-footer{background:#11171599;border-top-color:#cfbf9622}
.grimoire-page .g-app #gNotesText{background:transparent;color:#deddd3;caret-color:#dfc28a}
.grimoire-page .g-app #gNotesText::placeholder{color:#a5aaa1;opacity:1}
.grimoire-page .g-app :is(.g-summary,.g-dock){background:linear-gradient(135deg,#303638f2,#1b2325f2);border-color:#93876a73;box-shadow:0 5px 16px #02080744,inset 0 1px #f2e7c50b;backdrop-filter:blur(5px)}
.grimoire-page .g-app :is(.g-rail-button,.g-view-actions .g-button){background:#1d2523ef;border-color:#b7ad8a33;box-shadow:0 3px 8px #02080733,inset 0 1px #f2e7c508;backdrop-filter:none}
.grimoire-page .g-app :is(.g-dock,.g-timer-panel) .g-button:not(.primary):not(.subtle):not([aria-pressed=true]){background-color:#353d3c;border-color:#b5ab8b40}
.grimoire-page .g-app .g-button.primary{background:#cdb47c;color:#231f16;border-color:#e2c990;box-shadow:inset 0 1px #fff0c126,0 2px 4px #0002}
.grimoire-page .g-app .g-button.primary:hover{background:#dec58c}
.grimoire-page .g-app .g-seat-name{border-color:#c5b99470;background-color:#1b231fe0;text-shadow:0 1px 1px #0008}
.grimoire-page .g-app .g-token{box-shadow:0 2px 5px #05090766}
.grimoire-page .g-app .g-seat:hover .g-token{box-shadow:0 0 0 1px #d7c29199,0 4px 9px #03080766}
.grimoire-page .g-app .g-token-order{border-color:#141916;box-shadow:0 2px 3px #0006,inset 0 1px #ffffff18;text-shadow:0 1px 1px #0006}
.grimoire-page .g-app .g-seat:not(.dead) .g-token-order.first{background:linear-gradient(150deg,#255aa6,#193d77)}
.grimoire-page .g-app .g-seat:not(.dead) .g-token-order.other{background:linear-gradient(150deg,#a53332,#702322)}
/* Animate only paint/compositing, never panel bounds or marker coordinates. */
@media(prefers-reduced-motion:no-preference){
 .grimoire-page .g-app :is(.g-notes-panel,.g-side-panel.g-sheet-dialog,.g-aux-panel,.g-timer-panel):not([hidden]){animation:g-panel-arrive 220ms cubic-bezier(.22,.7,.32,1) both!important}
 .grimoire-page .g-app :is(.g-button,.g-rail-button,.g-seat-name,.g-fold){transition:background-color 140ms ease,border-color 140ms ease,color 140ms ease,box-shadow 140ms ease!important}
 .grimoire-page .g-app :is(.g-token,.g-reminder-add){transition:box-shadow 160ms ease,opacity 140ms ease}
 .grimoire-page .g-app :is(.g-dock .g-button,.g-rail-button):active:not(:disabled){box-shadow:inset 0 2px 7px #0007!important}
}
@keyframes g-panel-arrive{from{opacity:.8}65%{opacity:.97}to{opacity:1}}
@keyframes g-content-arrive{from{opacity:.55}to{opacity:1}}
/* Opaque touch surfaces avoid repeatedly blurring a scrolling table. */
@media(pointer:coarse){.grimoire-page .g-app :is(.g-notes-panel,.g-side-panel.g-sheet-dialog,.g-aux-panel,.g-timer-panel,.g-dock){backdrop-filter:none}}

/* Default material for every ordinary modal, including future feature screens. */
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal){background:var(--g-glass-fill);border-color:var(--g-glass-edge);box-shadow:var(--g-glass-shadow);backdrop-filter:var(--g-glass-filter)}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal)>.g-modal-head{background:var(--g-glass-head);border-bottom-color:#ffffff14}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal)>.g-modal-body{background:transparent}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal)::backdrop{background:#00000042;backdrop-filter:blur(2px)}

.grimoire-page .g-app #gNotesText:focus-visible{outline:1px solid #b8a67c80;outline-offset:-1px}

/* Menu hierarchy: one quiet surface, readable groups, distinct actions and switches. */
.grimoire-page #gDialog.g-menu-dialog[open]{display:flex;flex-direction:column;width:380px;border-color:#8b867b66;border-radius:12px;background:linear-gradient(155deg,#252b2c,#171e20);box-shadow:0 16px 44px #0007,inset 0 1px #f1e3c30b;overflow:hidden}
.grimoire-page #gDialog.g-menu-dialog>.g-modal-head{flex:none;min-height:54px;padding:10px 16px;background:#22292bef;border-bottom-color:#cabd9d26}
.grimoire-page #gDialog.g-menu-dialog .g-modal-head h2{font-size:16px;font-weight:650;letter-spacing:.08em;color:#ece5d5}
.grimoire-page #gDialog.g-menu-dialog #gDialogClose{width:32px;min-width:32px;height:32px;min-height:32px;padding:0;border-color:#b1b3a43b;background:transparent;color:#c9cec6;font-size:20px}
.grimoire-page #gDialog.g-menu-dialog>.g-modal-body{flex:1;min-height:0;max-height:none;padding:2px 16px 18px;scrollbar-width:thin;scrollbar-color:#9e9b8955 transparent;scrollbar-gutter:stable;overscroll-behavior:contain}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section{margin:17px 0 22px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section h3{display:flex;align-items:center;gap:10px;margin:0 0 10px;font-size:11px;line-height:1.5;font-weight:600;letter-spacing:.08em;color:#aeb5ac}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section h3:after{content:'';height:1px;flex:1;background:#c8be9c16}
.grimoire-page #gDialog.g-menu-dialog .g-menu-grid{gap:7px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item{position:relative;min-height:44px;padding:9px 11px;gap:9px;border:1px solid #b6b39d26;border-radius:7px;background:#ffffff04;color:#d9ded4;font-size:13px;font-weight:500;text-align:left;line-height:1.5;box-shadow:inset 0 1px #ffffff04}
.grimoire-page #gDialog.g-menu-dialog .g-menu-label{min-width:0;text-align:left}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item>svg{width:17px;height:17px;color:#a7b1a5;stroke-width:1.5}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item:hover:not(:disabled){background:#b7c3b610;border-color:#b8bd9c55;color:#f2ebda}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true]{background:#d6b87613;border-color:#b59b5e80;color:#eddbac;box-shadow:inset 2px 0 #c8ad70}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true]>svg{color:#d2bb81}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item:disabled{opacity:.36}
.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{display:grid;grid-template-columns:32px minmax(0,1fr) 32px;align-items:center;gap:3px;padding:4px;min-height:44px;border:1px solid #b6b39d26;border-radius:7px;background:#ffffff04;box-shadow:none}
.grimoire-page #gDialog.g-menu-dialog .g-menu-step{width:32px;height:34px;min-height:34px;border-radius:5px;color:#adb9ad;background:transparent;border:0}
.grimoire-page #gDialog.g-menu-dialog #gSeatCount{width:100%;min-height:34px;padding:4px 0;background:transparent;border:0;color:#e8e3d5;font-size:14px;font-weight:600;font-variant-numeric:tabular-nums}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script{min-height:66px;padding:12px 27px 12px 12px;background:#c6ac6d09;border-color:#b5a16d45}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script>svg{width:22px;height:22px;color:#d1b87c}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script strong{display:block;font-size:14px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#e7ddc1}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script small{display:block;margin-top:4px;font-size:10px;line-height:1.5;font-weight:400;color:#a8b0a5;overflow-wrap:anywhere}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script:after{content:'›';position:absolute;right:10px;top:50%;transform:translateY(-50%);color:#b1ad94;font-size:22px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-check{position:relative;flex:none;width:30px;height:18px;margin-left:auto;border:1px solid #aab5a74d;border-radius:12px;background:#0c1418;color:transparent;font-size:0}
.grimoire-page #gDialog.g-menu-dialog .g-menu-check:after{content:'';position:absolute;left:3px;top:3px;width:10px;height:10px;border-radius:50%;background:#86948b;box-shadow:0 1px 2px #0005}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true] .g-menu-check{border-color:#c2ad7577;background:#b9a36b30}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true] .g-menu-check:after{left:15px;background:#dec58b}
.grimoire-page #gDialog.g-menu-dialog .g-menu-count{min-width:21px;padding:1px 6px;border-radius:5px;background:#ffffff08;color:#d3c7a6;font-variant-numeric:tabular-nums}
.grimoire-page #gDialog.g-menu-dialog .g-menu-footnote{margin:9px 2px 0;font-size:10px;line-height:1.7;color:#9ba79e}
.grimoire-page #gDialog.g-menu-dialog .g-menu-footer{color:#8e9c92;border-top-color:#c8be9c20;font-size:10px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item.danger{color:#d4a09a;border-color:#ad73662f;background:#b5614d08}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item.danger>svg{color:#bc8b82}
@media(max-width:700px){
 .grimoire-page #gDialog.g-menu-dialog[open]{width:calc(var(--g-viewport-width,100vw) - 12px)}
 .grimoire-page #gDialog.g-menu-dialog>.g-modal-head{padding-inline:14px}
 .grimoire-page #gDialog.g-menu-dialog>.g-modal-body{padding-inline:13px}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-item,.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{min-height:46px}
 .grimoire-page #gDialog.g-menu-dialog #gDialogClose{width:36px;min-width:36px;height:36px;min-height:36px}
}

/* Player add/remove icons share the same stroke as the menu tools. */
.g-app :is(.g-menu-step,.g-step){display:grid;place-items:center}
.g-app :is(.g-menu-step,.g-step)>svg{display:block;width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}

/* Seat controls keep breathing room around the small person icons. */
.grimoire-page #gDialog.g-menu-dialog .g-menu-step>svg{width:16px;height:16px;stroke-width:1.6}
.grimoire-page #gDialog.g-menu-dialog .g-menu-step:hover:not(:disabled){background:#c3cfbb12;color:#e4dfcd}
.grimoire-page #gDialog.g-menu-dialog .g-menu-step:disabled{opacity:.3}
@media(pointer:coarse){.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{grid-template-columns:36px minmax(0,1fr) 36px;padding:3px}.grimoire-page #gDialog.g-menu-dialog .g-menu-step{width:36px;height:38px;min-height:38px}}
/* Sticky filters soften content beneath them without adding an opaque strip. */
.grimoire-page #gDialog.g-seat-role-picker{--g-picker-surface:var(--g-glass-toolbar)}
.grimoire-page #gDialog.g-seat-role-picker .g-seat-role-toolbar{background:var(--g-picker-surface);backdrop-filter:blur(8px) saturate(.7);border-bottom:1px solid #ffffff14}
.grimoire-page #gDialog.g-seat-role-picker #gTokenSearch{background:var(--g-glass-control);border-color:#ffffff26;box-shadow:inset 0 1px 3px #0002}
.grimoire-page #gDialog.g-seat-role-picker :is(.g-token-filters,.g-role-source-buttons) .g-button{background:#ffffff04;border-color:#a3ac983d;color:#bfc7bc}
.grimoire-page #gDialog.g-seat-role-picker :is(.g-token-filters,.g-role-source-buttons) .g-button[aria-pressed=true]{background:#c0ac7220;border-color:#c5b17a80;color:#e9dbb4}
.grimoire-page #gDialog.g-seat-role-picker :is(#gRoleCategory,.g-seat-role-search .g-button){background:#242c2c;border-color:#8e9a8540}
.grimoire-page #gDialog.g-seat-role-picker #gSeatRoleScope[aria-pressed=true]{background:#c0ac7220;border-color:#c5b17a80;color:#e9dbb4}

/* Black tinted matte glass for the summary and menu preview. */
.grimoire-page .g-app .g-summary{background:rgba(7,10,12,.80);border-color:#ffffff26;box-shadow:0 5px 18px #0005,inset 0 1px #ffffff08;backdrop-filter:blur(14px) saturate(.7)}
.grimoire-page #gDialog.g-menu-dialog[open]{background:rgba(7,10,12,.84);border-color:#ffffff26;box-shadow:0 16px 40px #0007,inset 0 1px #ffffff08;backdrop-filter:blur(14px) saturate(.7)}
.grimoire-page #gDialog.g-menu-dialog>.g-modal-head{background:#10141638;border-bottom-color:#ffffff14}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section h3:after{background:#ffffff10}
.grimoire-page #gDialog.g-menu-dialog :is(.g-menu-item,.g-menu-stepper){border-color:#ffffff18}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true]{border-color:#b59b5e80}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script{border-color:#b5a16d45}
@media(pointer:coarse){.grimoire-page .g-app .g-summary,.grimoire-page #gDialog.g-menu-dialog[open]{backdrop-filter:blur(8px) saturate(.7)}}
@supports not (backdrop-filter:blur(1px)){.grimoire-page .g-app .g-summary,.grimoire-page #gDialog.g-menu-dialog[open]{background:rgba(7,10,12,.94)}}

/* The storyteller tools share the approved black tinted glass. */
.grimoire-page{--g-glass-fill:rgba(7,10,12,.84);--g-glass-head:#10141638;--g-glass-toolbar:rgba(7,10,12,.36);--g-glass-control:rgba(3,6,8,.48);--g-glass-card:rgba(0,0,0,.24);--g-glass-edge:#ffffff26;--g-glass-filter:blur(14px) saturate(.7);--g-glass-shadow:0 12px 30px #0006,inset 0 1px #ffffff08}
.grimoire-page .g-app :is(.g-notes-panel,.g-side-panel.g-sheet-dialog,.g-aux-panel,.g-timer-panel,.g-dock){background:var(--g-glass-fill);border-color:var(--g-glass-edge);box-shadow:var(--g-glass-shadow);backdrop-filter:var(--g-glass-filter)}
.grimoire-page .g-app :is(.g-notes-head,.g-side-panel .g-modal-head){background:#10141638;border-bottom-color:#ffffff14}
.grimoire-page .g-app .g-notes-footer{background:#0a0d0f40;border-top-color:#ffffff14}
.grimoire-page .g-app .g-side-panel :is(.g-sheet-toolbar,.g-night-toolbar){background:var(--g-glass-toolbar);backdrop-filter:blur(8px) saturate(.7);border-bottom-color:#ffffff14}
.grimoire-page .g-app :is(.g-rail-button,.g-view-actions .g-button){background:#070a0cd6;border-color:#ffffff21;box-shadow:0 3px 9px #0004,inset 0 1px #ffffff06;backdrop-filter:blur(8px) saturate(.7)}
@media(pointer:coarse){.grimoire-page{--g-glass-filter:blur(8px) saturate(.7)}}
@supports not (backdrop-filter:blur(1px)){.grimoire-page{--g-glass-fill:rgba(7,10,12,.94);--g-glass-toolbar:rgba(7,10,12,.94)}}

/* Role labels open up slightly; hover and keyboard focus expose a private ability tip. */
.g-token .g-seat-role-arc text{letter-spacing:.45px}
.g-seat-token.is-role-hovered .g-seat-role-arc text{fill:#fff;stroke:#171411;stroke-width:1.15px}
.g-role-tooltip{position:fixed;z-index:60;width:max-content;max-width:min(360px,calc(var(--g-viewport-width,100vw) - 16px));padding:9px 11px;border:1px solid #ffffff29;border-radius:8px;background:#070a0cf2;color:#eeeae2;box-shadow:0 7px 20px #0007;pointer-events:none;overflow:hidden;backdrop-filter:blur(8px);font-size:13px;line-height:1.65}
.g-role-tooltip-heading{display:flex;align-items:baseline;gap:7px;margin:0 0 2px}
.g-role-tooltip-heading strong{font-size:14px;font-weight:650}
.g-role-tooltip-heading>span{font-size:11px;color:#aeb5af}
.g-role-tooltip-heading .townsfolk{color:#63b6ff}.g-role-tooltip-heading .outsider{color:#72d3dd}.g-role-tooltip-heading .minion{color:#f3aa77}.g-role-tooltip-heading .demon{color:#f78078}.g-role-tooltip-heading .traveller{color:#cba2eb}
.g-role-tooltip p{margin:0;white-space:pre-wrap;overflow-wrap:anywhere}
@media(prefers-reduced-motion:no-preference){.g-role-tooltip:not([hidden]){animation:g-content-arrive 100ms ease-out}}

/* Free placement moves complete seats, while normal tables retain drag-to-swap. */
.g-board.free-layout .g-seat-token{cursor:grab}
.g-board.free-layout .g-seat.dragging{opacity:.9;z-index:3}
.g-board.free-layout .g-seat.dragging .g-seat-token{cursor:grabbing}
.g-board.free-layout .g-seat.dragging .g-token{box-shadow:0 0 0 1px #ddc58b88,0 7px 15px #0007}
.g-offline-screen{box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:18px;min-height:100%;width:min(100%,640px);margin:auto;padding:max(28px,env(safe-area-inset-top)) 24px max(28px,env(safe-area-inset-bottom));text-align:center;color:#eee4cb}
.g-offline-screen h2,.g-offline-screen h3,.g-offline-screen p{margin:0;overflow-wrap:anywhere}
.g-offline-screen h2{font-size:clamp(22px,4vw,32px);font-weight:600}.g-offline-progress,.g-offline-team{color:#a5ada9;font-size:13px}
.g-offline-screen>.g-button{width:min(100%,320px);min-height:48px;justify-content:center}.g-offline-screen>.subtle{margin-top:14px;background:transparent;color:#a5ada9;border-color:#ffffff26;font-size:12px}
.g-offline-role{display:flex;flex-direction:column;align-items:center;gap:12px;width:100%}.g-offline-screen .g-token{--token-size:clamp(116px,23vh,180px);width:var(--token-size);height:var(--token-size);flex:none;pointer-events:none}
.g-offline-ability{font-size:16px;line-height:1.85;white-space:pre-wrap;text-align:left;width:100%}.g-offline-role h3{font-size:23px;font-weight:600}.g-offline-back .g-question{font-size:54px}
.grimoire-page #gDialog.g-offline-draw>.g-modal-body{height:100%;max-height:none;background:#090d10;animation:none!important;transition:none!important;scrollbar-gutter:auto}
.g-offline-draw #gDialogError{max-width:600px;margin:16px auto;padding:0 24px}
@media(max-width:480px){.g-bag-actions #gOfflineStart{grid-column:1/-1}}
@media(max-height:500px){.g-offline-screen{gap:12px;padding-block:18px}.g-offline-screen .g-token{--token-size:100px}}
.g-app[data-custom-background=true]{background-image:linear-gradient(rgb(0 0 0 / var(--g-background-dim,0)),rgb(0 0 0 / var(--g-background-dim,0))),var(--g-custom-background);background-position:center;background-size:cover;background-repeat:no-repeat}
.g-app[data-custom-background=true]:before,.g-app[data-custom-background=true]:after{display:none}
.g-background-dialog .g-modal-body{display:flex;flex-direction:column;gap:14px}.g-background-dialog .g-hint{margin:0;line-height:1.7}
.g-background-preview{position:relative;aspect-ratio:16/9;min-height:120px;flex:none;overflow:hidden;border:1px solid #ffffff26;border-radius:10px;background:#1e2934}.g-background-preview img{display:block;width:100%;height:100%;object-fit:cover;position:absolute;inset:0}.g-background-preview:after{content:"";position:absolute;inset:0;background:#000;opacity:var(--g-background-dim,0);pointer-events:none}
.g-background-preview[hidden]{display:none}.g-background-dialog input[type=file]{width:100%;max-width:100%;padding:10px;border:1px solid #ffffff26;border-radius:7px;background:#ffffff05;font-size:14px}.g-background-dialog input[type=range]{width:100%;accent-color:#ccb77e}.g-background-actions{display:flex;gap:10px;flex-wrap:wrap}.g-background-actions .g-button{flex:1;min-height:44px}
.g-dialog.g-background-dialog{width:560px;max-width:calc(var(--g-viewport-width,100vw) - 16px)}

/* Shared inset surfaces use the same neutral black tint as their parent glass. */
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal) :is(input:not([type=checkbox]):not([type=range]):not([id=gSeatName]),select,textarea){background-color:var(--g-glass-control);border-color:#ffffff26}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal) :is(.g-script-card,.g-script-library-item,.g-script-recent-chip,.g-script-import-item,.g-seat-note-form,.g-library-item){background:var(--g-glass-card);border-color:#ffffff26;box-shadow:inset 0 1px #ffffff04}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal) .g-bag-footer{background:transparent;border-top-color:#ffffff14}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal) :is(.g-sheet-toolbar,.g-night-toolbar){background:var(--g-glass-toolbar);backdrop-filter:blur(8px) saturate(.7);border-bottom-color:#ffffff14}
.grimoire-page #gDialog :is(.g-script-nav,.g-script-custom-footer){border-color:#ffffff14}
/* Explicit reuse hook for future non-modal panels. */
.grimoire-page .g-glass-surface{background:var(--g-glass-fill);border:1px solid var(--g-glass-edge);box-shadow:var(--g-glass-shadow);backdrop-filter:var(--g-glass-filter)}

/* Review timeline: black matte glass with quietly separated day/night sections. */
.g-side-panel.g-review-panel:not(.g-sheet-floating){width:440px;max-width:calc(var(--g-viewport-width,100vw) - 80px)}
.g-review-panel .g-modal-body{padding:0 0 14px;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable}
.g-review-panel #gReviewFloat{min-height:28px;padding:2px 9px;border:1px solid #ffffff26;border-radius:16px;background:transparent;color:#bdc4c7;font-size:11px}
.g-right-tools #gHistory[aria-expanded=true]{color:#eddbac;border-color:#a18b55;background:#332e23cc}
.g-review-toolbar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:10px 16px;border-bottom:1px solid #ffffff14;background:var(--g-glass-toolbar)}
.g-review-status{font-size:11px;color:#a4adb2}.g-review-toolbar .g-button{min-height:30px;padding:4px 8px;font-size:11px}
.g-review-toolbar{flex-wrap:wrap}.g-review-toolbar .g-review-status{flex:1;min-width:100px}.g-review-export{display:grid;gap:12px;min-width:0}.g-review-export-options{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px}.g-review-export-options label{display:flex;flex-direction:row;align-items:center;gap:7px;font-size:13px}.g-review-export-options input{width:17px;height:17px;accent-color:#cbb77d}.g-review-export-options select{width:auto;min-width:110px;max-width:150px}.g-review-export-preview{display:block;width:100%;height:auto;max-width:640px;margin:auto;border:1px solid #ffffff26;background:#fff}.g-review-export #gReviewExportDownload{justify-self:end}
.g-review-stage{padding:18px 16px 16px;border-bottom:1px solid #ffffff10;background:var(--g-glass-card);overflow-wrap:anywhere}
.g-review-stage.is-current{box-shadow:inset 2px 0 #ccb47780}
.g-review-heading{display:flex;align-items:center;gap:8px;margin-bottom:14px}.g-review-heading h3{margin:0;padding:0;border:0;font-size:21px;font-weight:550;color:#eee9dd;white-space:nowrap}.g-review-symbol{font-size:25px;line-height:1;color:#cbbb92}.g-review-phase-en{color:#889398;font-size:12px}.g-review-current{margin-left:auto;border:1px solid #ccb47738;border-radius:4px;padding:2px 5px;color:#d3c095;font-size:10px;white-space:nowrap}
.g-review-entries{list-style:none;padding:0;margin:0}.g-review-entry{display:flow-root;padding:10px 0;border:0;border-bottom:1px solid #ffffff0d;border-radius:0;background:transparent}.g-review-entry:last-child{border-bottom:0}
.g-review-entry{position:relative;padding-left:28px}.g-review-panel .g-review-entry>.g-review-drag{position:absolute;left:-5px;top:6px;min-width:30px;width:30px;min-height:36px;padding:0;border:0;background:transparent;color:#8e9a9f;font-size:22px;line-height:1;cursor:grab;touch-action:none;user-select:none;-webkit-user-select:none}.g-review-drag:disabled{opacity:.3;cursor:default}.g-review-entry.is-sorting{background:#cbb77d0d;outline:1px dashed #cbb77d70;outline-offset:-1px}.g-review-entry.is-sorting>.g-review-drag{cursor:grabbing;color:#eddbac}.g-review-entry.is-drop-before::before,.g-review-entry.is-drop-after::after{content:'';position:absolute;left:0;right:0;height:2px;background:#d6c18c;pointer-events:none}.g-review-entry.is-drop-before::before{top:-1px}.g-review-entry.is-drop-after::after{bottom:-1px}.g-review-panel .is-review-sorting{user-select:none;-webkit-user-select:none;scroll-behavior:auto;overflow-anchor:none}
.g-review-copy{display:inline}.g-review-copy p{display:inline;margin:0;color:#e1e5e7;font-size:14px;font-weight:400;line-height:1.85;white-space:pre-wrap}.g-review-copy strong{font-weight:500}.g-review-copy .g-review-result{color:#c6cdd1}.g-review-storyteller{color:#dbc894}
.g-review-panel .g-review-entries .g-review-identity:is(.townsfolk,.outsider){color:#a3c8da}.g-review-panel .g-review-entries .g-review-identity:is(.minion,.demon){color:#dfb1a7}.g-review-panel .g-review-entries .g-review-identity.traveller{color:#bdc9d2}.g-review-panel .g-review-entries .g-review-player.g-review-role-label{display:inline-block;max-width:100%;vertical-align:baseline;color:#d5dfe4}.g-review-entries .g-review-player-role{color:#b8c2c8;font-weight:400}.g-review-panel .g-review-entries .g-review-storyteller,.g-review-panel .g-review-entries .g-review-group{color:#ccd6db}.g-review-entries :is(.g-review-status-effect,.g-review-votes,.g-review-changed-alignment){color:#e1e5e7;white-space:nowrap}.g-review-entries .g-review-role-icon{width:17px;height:17px;margin-inline:2px;vertical-align:-3px}.g-review-entries .g-review-role-icon img{filter:saturate(.75)}.g-review-player-name{display:inline-block;max-width:100%;vertical-align:baseline;overflow-wrap:anywhere}
.g-review-votes{color:#d3c095;font-variant-numeric:tabular-nums}
.g-review-status-effect{color:#e5b47b}.g-review-source-fields{display:grid;gap:8px;min-width:0}
.g-review-role-change{display:grid;gap:10px;min-width:0;padding:10px;border:1px solid #ffffff18;border-radius:6px;background:var(--g-glass-card)}.g-review-role-tools{display:flex;align-items:flex-end;gap:6px;min-width:0}.g-review-role-tools label{flex:1;min-width:0}.g-review-role-tools .g-button{flex:none;min-height:36px;padding:5px 7px;font-size:11px}.g-review-role-selection{font-size:13px;line-height:1.8;overflow-wrap:anywhere}
.g-review-role-options{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,135px),1fr));gap:5px;max-height:220px;overflow:auto;overscroll-behavior:contain}.g-review-role-options .g-review-role-option{justify-content:flex-start;min-width:0;min-height:36px;padding:6px 7px;text-align:left;font-size:12px;border-color:#ffffff14;background:#ffffff03;overflow-wrap:anywhere}.g-review-role-option[aria-pressed=true]{border-color:#cbb77d99;background:#cbb77d18}.g-review-role-options .g-review-player{min-width:0;white-space:normal}.g-review-changed-alignment.good{color:#80cbea}.g-review-changed-alignment.evil{color:#ee9393}
.g-review-three-roles{display:grid;gap:8px;min-width:0}.g-review-three-slots{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.g-review-three-slots .g-review-role-slot{flex-direction:column;align-items:flex-start;gap:5px;min-width:0;min-height:64px;padding:7px 5px;text-align:left;font-size:11px;white-space:normal;overflow-wrap:anywhere;background:var(--g-glass-control)}.g-review-role-slot[aria-pressed=true]{border-color:#cbb77d99;background:#cbb77d18}.g-review-role-slot>span:first-child{color:#adb9bf;font-size:10px}.g-review-role-slot .g-review-role-icon{width:17px;height:17px;vertical-align:-4px}
.g-review-menu-heading{color:#c8b889;font-size:11px;padding:8px 2px 3px}.g-review-menu-list .g-review-ability-action{display:flex;flex-wrap:wrap;align-items:center;gap:4px 10px;border-color:#cbb77d40;background:#cbb77d0b}.g-review-ability-fields{display:grid;gap:10px;min-width:0;border:1px solid #cbb77d38;border-radius:6px;padding:10px;background:var(--g-glass-card)}.g-review-ability-fields>.g-hint{color:#c2c8cb;white-space:pre-wrap;line-height:1.8;font-size:12px}
#gReviewAbilityRoleSlots{grid-template-columns:repeat(2,minmax(0,1fr))}#gReviewAbilityNightReminder{font-size:12px;line-height:1.8}#gReviewAbilityNightReminder p{white-space:pre-wrap;overflow-wrap:anywhere}
.g-review-target-order{display:grid;gap:8px;margin:8px 0}.g-review-target-order:empty{display:none}.g-review-target-order select{width:100%;min-width:0}
.g-review-role-options .g-review-role-option.has-role-versions{flex-direction:column;align-items:flex-start;gap:3px}.g-review-role-source{color:#bdc5ca;font-size:10px}.g-review-role-version{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;color:#aeb9bf;font-size:11px;line-height:1.45;font-weight:400}
.g-review-validation{margin:10px 0 6px;padding:8px 10px;border-left:2px solid #cbb77d80;background:#cbb77d0a;color:#d8cba4;font-size:12px;line-height:1.5}
.g-review-ability-texts{display:grid;gap:10px}.g-review-ability-texts textarea{width:100%;min-width:0;resize:vertical}.g-review-using-role{color:#aebac1;font-weight:400}.g-review-using-role .g-review-role-label{font-size:inherit;font-weight:inherit}
.g-review-form-settings,.g-review-record-preview{display:grid;gap:8px;min-width:0;padding:10px;border:1px solid #cbb77d38;border-radius:6px;background:var(--g-glass-card)}.g-review-form-settings details{display:block;margin:0;padding:0;border:0}.g-review-form-settings label{margin:0}.g-review-form-settings summary{min-height:36px}.g-review-editor #gReviewIdentityCorrection{margin:0;padding:0;border:0}.g-review-editor #gReviewIdentityCorrection>summary{min-height:32px;font-size:12px}.g-review-form-settings details>*{margin-top:8px}.g-review-form-settings summary{cursor:pointer;color:#c8b889;font-size:12px}.g-review-form-settings label:has(input[type=checkbox]){flex-direction:row;align-items:center}.g-review-form-settings [role=status]:empty{display:none}.g-review-record-preview p{margin:0;white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.8;color:#dce0e2}.g-review-record-preview h4{color:#c8b889}.g-night-record-actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:6px}.g-night-record-actions .g-button{min-height:34px;padding:5px 8px;font-size:12px}.g-finish-actions{display:grid;gap:10px}.g-finish-option{display:grid;gap:6px;padding:12px;border:1px solid #ffffff20;border-radius:6px;background:var(--g-glass-card)}.g-finish-option .g-button{min-height:44px}@media(pointer:coarse){.g-night-record-actions .g-button,.g-review-form-settings .g-button{min-height:44px}}
.g-review-panel .g-review-player.townsfolk{color:#70c5ee}.g-review-panel .g-review-player.outsider{color:#79d4d9}.g-review-panel .g-review-player.minion{color:#eea276}.g-review-panel .g-review-player.demon{color:#ee8585}.g-review-panel .g-review-player.traveller{color:#d3a7eb}
.g-review-player{font-weight:550;overflow-wrap:anywhere}.g-review-player-role{display:inline-block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom;font-weight:inherit}.g-review-role-icon{display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;margin-inline:1px;vertical-align:-5px}.g-review-role-icon img{display:block;width:100%;height:100%;object-fit:contain}.g-review-role-icon .g-question{font-size:13px;line-height:1}.g-review-actor-preview{font-size:12px;line-height:1.8;padding:0 2px}.g-review-actor-preview:has(>.g-review-storyteller){display:none}
.g-review-entry-tools{display:flex;float:right;justify-content:flex-end;gap:6px;margin:2px 0 0 12px}.g-review-entry-tools .g-button{border:0;min-height:24px;padding:2px 4px;background:transparent;color:#929da3;font-size:11px}.g-review-entry-tools .g-button:is(:hover,:focus-visible){color:#e1e5e7;background:#ffffff08}
.g-review-empty{font-size:12px;color:#7e8a91;margin:0 0 12px}.g-review-stage-tools{display:flex;flex-wrap:wrap;gap:7px;margin-top:12px}
.g-review-stage-tools .g-button{min-height:32px;padding:5px 9px;font-size:12px;background:#ffffff04;border-color:#ffffff1c;color:#c5cdd0}.g-review-stage-tools .g-review-delete-stage{font-size:11px;color:#9f9894;background:transparent;border-color:transparent}
.g-review-panel .g-review-add-stage{display:flex;width:calc(100% - 32px);margin:16px;border:1px dashed #ffffff30;background:#ffffff05;min-height:42px;color:#d2c6a7;font-size:13px}.g-review-panel .g-modal-body>.g-hint{margin:0 16px;font-size:10px;color:#89969d}
.g-review-editor{padding:14px 12px;margin-top:14px;border:1px solid #cbb77d38;border-radius:8px;background:var(--g-glass-card);display:grid;gap:12px}.g-review-editor h4{margin:0;font-size:13px;color:#dbc894;font-weight:550}.g-review-editor label{display:flex;flex-direction:column;gap:6px;font-size:12px;color:#abb6bd;min-width:0}
.g-review-editor :is(input:not([type=checkbox]),select,textarea){min-width:0;width:100%;padding:9px;border:1px solid #ffffff26;border-radius:5px;background:var(--g-glass-control);color:#e0e5e7;font-size:13px}.g-review-editor textarea{resize:vertical;min-height:78px;max-height:260px}.g-review-fields{display:grid;grid-template-columns:1fr;gap:10px}.g-review-editor-tools{display:flex;gap:8px;justify-content:flex-end}.g-review-editor-tools .g-button{min-height:36px;font-size:12px}.g-review-editor .g-hint{font-size:10px;margin:0;line-height:1.6}
.g-review-action-control{position:relative;min-width:0}.g-review-action-control #gReviewAction{padding-right:54px}.g-review-action-control>.g-review-action-toggle{position:absolute;inset:0 0 0 auto;width:44px;height:100%;min-height:0;padding:0;border:0;border-left:1px solid #ffffff18;border-radius:0 5px 5px 0;background:#ffffff04}.g-review-action-toggle:after{content:'';position:absolute;right:18px;top:calc(50% - 5px);width:7px;height:7px;border-right:1.5px solid #bbc5cb;border-bottom:1.5px solid #bbc5cb;transform:rotate(45deg)}.g-review-action-toggle[aria-expanded=true]:after{transform:rotate(225deg);top:calc(50% - 2px)}
.g-review-action-groups{display:grid;gap:7px;min-width:0;padding:8px;border:1px solid #cbb77d40;border-radius:6px;background:var(--g-glass-card)}.g-review-action-groups[hidden],#gReviewActionPreset[hidden]{display:none!important}.g-review-action-category{min-width:0;border:1px solid #ffffff1c;border-radius:5px;background:var(--g-glass-control)}.g-review-action-category>summary{display:flex;align-items:center;gap:7px;padding:10px;cursor:pointer;list-style:none;font-size:12px;color:#d7c79e}.g-review-action-category>summary::-webkit-details-marker{display:none}.g-review-action-category>summary:before{content:'▸';color:#aeb9bf}.g-review-action-category[open]>summary:before{content:'▾'}.g-review-action-category>summary small{margin-left:auto;color:#89969e;font-size:10px;white-space:nowrap}.g-review-category-options{display:grid;gap:4px;padding:0 7px 7px}.g-review-action-groups .g-review-preset-choice{min-width:0;width:100%;justify-content:flex-start;text-align:left;white-space:normal;overflow-wrap:anywhere;min-height:36px;padding:8px;font-size:12px;background:#ffffff03;border-color:#ffffff14}.g-review-action-groups .g-review-preset-choice[aria-pressed=true]{border-color:#cbb77d70;background:#cbb77d14;color:#e2d2a8}.g-review-action-category>summary:focus-visible{outline:2px solid #b4c9da;outline-offset:1px}

.g-review-wizard-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.g-review-subjects{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}.g-review-wizard .g-button{min-height:42px;white-space:normal;overflow-wrap:anywhere;font-size:12px;text-align:left;justify-content:flex-start}.g-review-wizard-head .g-button{min-height:32px}.g-review-menu-list{display:grid;gap:5px;min-width:0}.g-review-menu-list .g-button{width:100%;border-color:#ffffff12;background:var(--g-glass-control)}.g-review-subjects .g-button{background:var(--g-glass-control);border-color:var(--g-glass-edge)}.g-review-group{font-weight:550}.g-review-group.townsfolk,.g-review-group.good,.g-review-subject[data-review-subject="group:townsfolk"],.g-review-subject[data-review-subject="group:good"]{color:#70c5ee}.g-review-group.minions,.g-review-group.evil,.g-review-subject[data-review-subject="group:minions"],.g-review-subject[data-review-subject="group:evil"]{color:#ee9393}.g-review-group.all{color:#dbc894}
.g-review-progress{display:flex;flex-wrap:wrap;gap:5px;color:#aeb8bc;font-size:11px}.g-review-progress span{padding:4px 7px;border:1px solid #ffffff20;border-radius:4px}.g-review-progress [aria-current=step]{color:#f4e5b4;border-color:#cbb77d88;background:#cbb77d18}
.g-review-quick-steps{display:flex;flex-wrap:wrap;gap:6px}.g-review-quick-steps[hidden]{display:none}.g-review-quick-steps .g-button{min-height:36px;font-size:12px}@media(pointer:coarse){.g-review-quick-steps .g-button{min-height:44px}}
.g-review-guided{display:grid;gap:8px;padding:10px;border:1px solid #cbb77d55;border-radius:6px;background:var(--g-glass-card)}.g-review-guided strong{color:#f4e5b4}.g-review-guided-nav{display:flex;flex-wrap:wrap;gap:6px}.g-review-guided-nav .g-button{min-height:36px}.g-review-guided-hidden{display:none!important}@media(pointer:coarse){.g-review-guided-nav .g-button{min-height:44px}}
.g-review-guided.is-guided+.g-review-quick-steps{display:none}
.g-review-player-picker,.g-review-recent-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;min-width:0}.g-review-player-picker .g-button,.g-review-recent-actions .g-button{min-width:0;width:100%;padding:8px;border-color:#ffffff18;background:var(--g-glass-control)}.g-review-player-picker .g-review-player-role{display:block;white-space:normal}.g-review-recent-actions .g-button{display:flex;align-items:flex-start;flex-direction:column;gap:5px}.g-review-recent-actions .g-button>span:last-child{font-size:11px;color:#b5c0c6}.g-review-editor-tools{position:sticky;bottom:0;z-index:2;flex-wrap:wrap;padding:8px 0;background:#14191c;box-shadow:0 -1px 0 #ffffff14}.g-review-entry-tools{flex-wrap:wrap}.g-review-editor-tools #gReviewSaveNext{border-color:#b7a66d70;color:#e0d3ad}
.g-review-suggestion{clear:both;display:grid;gap:6px;padding-top:10px;min-width:0}.g-review-suggestion-caption{margin:0;color:#8f9aa1;font-size:11px;line-height:1.5}.g-review-suggestion>.g-button{display:block;width:100%;min-width:0;min-height:40px;padding:8px 10px;text-align:left;white-space:normal;line-height:1.7;border-color:#cbb77d38;background:var(--g-glass-control);font-size:12px}.g-review-suggestion .g-review-player{font-weight:500}.g-review-suggestion-plus{color:#cbb77d;margin-right:5px}.g-review-suggestion-effect{margin-left:5px;color:#d9bd85}.g-review-suggestion-confirm{display:inline-block;margin-left:8px;color:#c4ba9e;font-size:11px}
.g-review-suggestion{gap:8px;padding-top:12px}.g-review-panel .g-review-suggestion>.g-button{min-height:48px;font-size:14px}.g-review-suggestion-caption,.g-review-suggestion-confirm{font-size:13px}
.g-review-targets{border:1px solid #ffffff18;border-radius:5px;padding:9px;background:var(--g-glass-control);font-size:12px;color:#bdc6cb}.g-review-targets summary{cursor:pointer}.g-review-target-grid{display:grid;gap:9px;margin-top:12px;max-height:210px;overflow:auto}.g-review-target-grid label{flex-direction:row;align-items:center;justify-content:flex-start;line-height:1.6;color:#c7cdd0}.g-review-target-grid input{flex:none;accent-color:#cbb77d}
.g-review-targets #gReviewTargetSearch{width:100%;margin-top:10px;min-width:0}.g-review-target-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;overscroll-behavior:contain}.g-review-target-grid label{min-width:0;min-height:44px;padding:6px;border:1px solid #ffffff12;border-radius:5px;background:#ffffff03;cursor:pointer;font-size:12px}.g-review-target-grid label.is-selected{border-color:#cbb77d99;background:#cbb77d18}.g-review-target-grid label:has(input:disabled){opacity:.4;cursor:default}.g-review-target-grid .g-review-player{min-width:0}.g-review-target-grid .g-review-player-role{display:block;white-space:normal;font-size:11px}.g-review-player-slots{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;margin-top:10px}.g-review-player-slots .g-review-slot-pick{display:flex;flex-direction:column;align-items:flex-start;min-width:0;gap:5px;padding:7px;font-size:12px;text-align:left;white-space:normal;background:var(--g-glass-card)}.g-review-player-slots .g-review-slot-pick>span:first-child{color:#aeb9bf;font-size:11px}.g-review-player-slots .g-review-slot-pick[aria-pressed=true]{border-color:#cbb77d99;background:#cbb77d18}.g-review-player-slots .g-review-player-role{display:block;white-space:normal}.g-review-selected-players{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}.g-review-selected-players>.g-button{min-height:30px;min-width:0;max-width:100%;padding:4px 6px;font-size:11px;border-color:#cbb77d40;background:#cbb77d0b}.g-review-selected-players .g-review-player-role{display:none}.g-review-role-filters{display:flex;flex-wrap:wrap;gap:5px}.g-review-role-filters>.g-button{min-height:30px;padding:4px 7px;font-size:11px}.g-review-role-filters>.g-button[aria-pressed=true]{color:#e5d7b2;border-color:#cbb77d99;background:#cbb77d18}.g-review-recent-roles{display:grid;gap:5px}.g-review-recent-roles>.g-hint{font-size:11px}.g-review-recent-roles .g-review-role-options{max-height:100px}
@media(pointer:coarse){.g-review-panel :is(.g-review-stage-tools,.g-review-entry-tools) .g-button,.g-review-panel #gReviewFloat{min-height:36px}.g-review-editor :is(input:not([type=checkbox]),select,textarea){font-size:16px}.g-review-target-grid label{min-height:36px}}
@media(max-width:700px){.g-side-panel.g-review-panel:not(.g-sheet-floating){width:calc(var(--g-viewport-width,100vw) - 80px)}.g-review-stage{padding:16px 12px}.g-review-heading{gap:6px;flex-wrap:wrap}.g-review-heading h3{font-size:20px}.g-review-phase-en{font-size:11px}.g-review-current{margin-left:0}.g-review-toolbar{padding:8px 12px;flex-wrap:wrap}}
@media(pointer:coarse) and (min-width:701px) and (max-height:500px){.g-side-panel.g-review-panel:not(.g-sheet-floating){right:calc(250px + env(safe-area-inset-right));left:auto;width:min(440px,calc(var(--g-viewport-width,100vw) - 290px));max-width:calc(var(--g-viewport-width,100vw) - 290px)}}

/* Neutral grey actions match the supplied button reference. */
.grimoire-page .g-app .g-dock :is(#gScript,#gAssign){background:#303338;border-color:#ffffff14;color:#f0f0f1;box-shadow:none}
.grimoire-page .g-app .g-dock :is(#gScript,#gAssign):hover{background:#3a3e44;border-color:#ffffff26}
.grimoire-page .g-app .g-dock :is(#gScript,#gAssign):active{background:#282b30}
.g-app[data-page-zoom]:not([data-page-zoom="100"]){min-height:0}
.g-menu-zoom{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0;padding:5px 10px;border:1px solid #ffffff18;border-radius:7px;background:#ffffff04;color:#d9ded4;font-size:13px}
.g-menu-zoom-buttons{display:flex;align-items:center;gap:3px}.g-menu-zoom-buttons .g-button{min-height:34px;padding:4px 7px;border:0;color:inherit}.g-menu-zoom-buttons :is(#gZoomOut,#gZoomIn){width:30px;font-size:18px}.g-menu-zoom-buttons #gZoomReset{min-width:58px;font-size:12px;font-variant-numeric:tabular-nums}
.g-zoom-table-ui .g-board.phone-table{inset:0 0 calc(var(--g-dock-height,170px) + 20px);overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;touch-action:pan-x pan-y pinch-zoom}
.g-zoom-table-ui .phone-table .g-seats{width:var(--g-phone-width,100%);height:var(--g-phone-height,100%);bottom:auto}
.g-zoom-table-ui .phone-table .g-center{left:calc(var(--g-phone-width,100%) / 2)}
.g-zoom-table-ui .phone-table .g-seat{width:calc(var(--token-size) + 18px);min-height:0;padding:0;transform:translate(-50%,calc(var(--token-size)*-.5))}

/* Only artwork/content composites animate; geometry and private covers stay immediate. */
.g-background-transition{position:absolute;inset:0;z-index:-1;background-position:center;background-size:cover;background-repeat:no-repeat;pointer-events:none}
.g-offline-track{width:min(100%,320px);height:3px;border-radius:3px;overflow:hidden;background:#ffffff14;flex:none}
.g-offline-track span{display:block;width:100%;height:100%;background:#cdb47c;transform-origin:left center}
@media(prefers-reduced-motion:no-preference){
 .g-background-preview:after{transition:opacity 90ms linear}
 #gBackgroundStatus.is-busy:before{content:'';display:inline-block;width:11px;height:11px;margin-right:7px;border:2px solid #cdb47c33;border-top-color:#cdb47c;border-radius:50%;vertical-align:-2px;animation:g-loading-turn 750ms linear infinite}
 .grimoire-page #gDialog .g-script-card{transition:border-color 150ms ease,box-shadow 150ms ease}
}
@media(prefers-reduced-motion:no-preference) and (hover:hover) and (pointer:fine){
 .grimoire-page #gDialog .g-script-card:hover{border-color:#cdb47c66;box-shadow:inset 0 0 0 1px #cdb47c12}
 .g-script-preset .g-script-logo{transition:transform 180ms ease}
 .g-script-preset:hover .g-script-logo{transform:scale(1.035)}
}
@keyframes g-loading-turn{to{transform:rotate(360deg)}}

.g-review-player-slot-card{position:relative;min-width:0;display:flex}.g-review-player-slot-card .g-review-slot-pick{width:100%;height:100%}.g-review-player-slot-card:has(.g-review-clear-slot) .g-review-slot-pick>span:first-child{padding-right:22px}.g-review-player-slot-card .g-review-clear-slot{position:absolute;right:0;top:0;min-width:30px;min-height:30px;padding:3px;border:0;background:transparent;color:#b7c0c5;font-size:17px}

/* Recap navigation stays local to the private panel. */
.g-review-navigator{position:sticky;top:0;z-index:3;display:grid;gap:7px;padding:10px 14px;background:var(--g-glass-toolbar);border-bottom:1px solid #ffffff1c;box-shadow:0 5px 12px #00000030;min-width:0}
.g-review-stage-nav,.g-review-quick-tools,.g-review-log-search{display:flex;align-items:center;gap:6px;min-width:0}.g-review-stage-nav select,.g-review-log-search input{flex:1;min-width:0;width:0;padding:7px 8px;border:1px solid #ffffff26;border-radius:5px;background:var(--g-glass-control);color:#e0e5e7;font-size:13px}.g-review-stage-nav .g-button,.g-review-quick-tools .g-button,.g-review-log-search .g-button{flex:none;min-height:34px;padding:5px 8px;font-size:12px}.g-review-stage-nav :is(#gReviewPreviousStage,#gReviewNextStage){font-size:21px;line-height:1;min-width:28px;padding:3px 6px}.g-review-quick-tools{flex-wrap:wrap}.g-review-quick-tools :is(#gReviewQuickAdd,#gReviewQuickText){border-color:#cbb77d55;color:#dfd0a5}.g-review-navigator #gReviewSearchStatus{margin:0;font-size:11px;line-height:1.55;color:#b9c4ca}.g-review-stage-count{font-size:11px;color:#99a8b0;white-space:nowrap}.g-review-heading{flex-wrap:wrap}.g-review-fold{margin-left:auto;min-height:30px;padding:3px 7px;font-size:11px}.g-review-current{margin-left:0}.g-review-entry>.g-review-editor{clear:both;margin-top:12px}.g-review-stage[hidden],.g-review-entry[hidden],.g-review-entries[hidden],.g-review-stage-tools[hidden],.g-review-log-search[hidden],#gReviewSearchStatus[hidden]{display:none!important}
@media(pointer:coarse){.g-review-stage-nav select,.g-review-log-search input{font-size:16px}.g-review-navigator .g-button,.g-review-fold{min-height:36px}}
@media(max-height:500px){.g-review-navigator{position:static;box-shadow:none}}
@media(max-width:700px){.g-review-navigator{padding:8px 10px}.g-review-quick-tools{gap:5px}.g-review-quick-tools .g-button{padding:5px 6px}.g-review-entry>.g-review-editor{margin-left:-20px}}

.g-review-editor{scroll-margin-top:115px}@media(max-height:500px){.g-review-editor{scroll-margin-top:10px}}

/* Historical boards are separate read-only surfaces; live controls stay untouched. */
.g-app .g-replay-seat,.g-app .g-replay-seat:active{transform:translate(-50%,-50%)!important;transition:background-color .15s,border-color .15s}.g-app .g-replay-board.is-crowded .g-replay-seat{transform:none!important}.g-replay-token{background-image:url('../../theme/token1.png');background-size:cover}.g-replay-mark-count{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.g-dialog.g-replay-dialog{width:min(1160px,calc(var(--g-viewport-width,100vw) - 24px))}.g-replay-controls{display:grid;grid-template-columns:auto minmax(100px,1fr) auto minmax(140px,1fr);gap:8px;align-items:center}.g-replay-layout{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(270px,1fr);gap:18px}.g-replay-board-wrap{min-width:0}.g-replay-board{position:relative;aspect-ratio:1/1.12;border:1px solid var(--g-glass-border,#ffffff25);border-radius:18px;background:radial-gradient(ellipse at center,#38495290,#11171de0),url('../../theme/bg_day.png') center/cover;overflow:hidden;container-type:inline-size}.g-replay-board[data-phase=day]{background:radial-gradient(ellipse at center,#4c50586b,#171b1fe8)}.g-replay-center{position:absolute;left:29%;top:38%;width:42%;display:grid;gap:10px;text-align:center;color:#e8d7a6;pointer-events:none;overflow-wrap:anywhere}.g-replay-center strong{font-size:18px}.g-replay-center span{font-size:22px}.g-replay-center small{font-size:12px;color:#b9c2c7}.g-replay-seat{position:absolute;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;width:20%;max-width:108px;padding:3px 1px;gap:3px;background:transparent;border:1px solid transparent;border-radius:10px;color:#d6e5eb;cursor:pointer;min-height:44px;line-height:1.35}.g-replay-token{display:flex;flex-direction:column;align-items:center;justify-content:center;width:clamp(42px,13cqw,78px);height:clamp(42px,13cqw,78px);border-radius:50%;border:2px solid #aa9774;background:radial-gradient(circle,#efe7cd,#a68b60);box-shadow:0 3px 9px #0008;overflow:hidden}.g-replay-token>img{width:65%;height:65%;object-fit:contain}.g-replay-role-name{color:#292621;font-size:clamp(9px,2.4cqw,13px);font-weight:700;max-width:96%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.g-replay-name{max-width:100%;font-size:clamp(10px,2.5cqw,13px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#edf1ef}.g-replay-life,.g-replay-mark-count{font-size:11px;padding:0 4px;border-radius:3px;background:#182629;color:#c6d9ce}.g-replay-seat.is-dead .g-replay-token{filter:grayscale(.7);border-color:#7c858e}.g-replay-seat.is-dead .g-replay-life{background:#503037;color:#ffbdba}.g-replay-mark-count{color:#ffe0a0;background:#504326}.g-replay-seat.is-focused{background:#e5c77822;border-color:#f1d391;box-shadow:0 0 0 2px #e1c78155}.g-replay-selected{padding:12px 4px;min-height:70px}.g-replay-selected article{padding:10px 12px;margin:6px 0;border:1px solid #ddc98b44;border-radius:8px;background:var(--g-glass-control,#11171acc)}.g-replay-selected p{font-size:13px;line-height:1.6;margin:6px 0}.g-replay-records{min-width:0}.g-replay-record{padding:12px;margin:10px 0;border:1px solid #ffffff24;border-radius:10px;background:var(--g-glass-control,#11171acc)}.g-replay-record.is-active{border-color:#d9bf81;background:#c2a56615}.g-replay-record .g-review-copy{font-size:14px;line-height:1.85}.g-replay-record .g-button{margin-top:6px}.g-replay-empty{position:absolute;top:65%;left:15%;width:70%;text-align:center;font-size:13px;color:#c2c7c9}.g-replay-board.is-crowded{aspect-ratio:auto;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;padding:12px}.g-replay-board.is-crowded .g-replay-center{position:static;width:auto;grid-column:1/-1;padding:10px}.g-replay-board.is-crowded .g-replay-seat{position:static;transform:none;width:100%;max-width:none}.g-review-toolbar{flex-wrap:wrap}.g-review-toolbar .g-review-status{flex-basis:100%}
.g-expiry-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:12px 0}.g-expiry-item{padding:14px;border:1px solid #ffffff25;border-radius:10px;margin:10px 0;background:var(--g-glass-control,#11171acc)}.g-expiry-item.is-due{border-color:#dcb46a;background:#c99b3810}.g-expiry-item h3{margin:0}.g-expiry-open{width:100%;margin-top:7px}.g-expiry-open.is-due{border-color:#dbb963;color:#ffe7a6;background:#524125}.g-reminder-token.is-expired{outline:2px solid #f2bc5d;outline-offset:2px}.g-reminder-actions .g-reminder-clock{font-size:20px}
@media(max-width:760px){.g-replay-layout{grid-template-columns:minmax(0,1fr)}.g-replay-controls{grid-template-columns:1fr 1fr}.g-replay-controls #gReplayStage{grid-column:1;grid-row:1}.g-replay-controls #gReplayMoment{grid-column:2;grid-row:1}.g-replay-center strong{font-size:14px}.g-replay-center span{font-size:18px}.g-replay-board{aspect-ratio:1/1.22}.g-replay-life,.g-replay-mark-count{font-size:10px}.g-expiry-fields{grid-template-columns:1fr}.g-dialog.g-replay-dialog .g-modal-body{padding:12px}.g-replay-record .g-button{min-height:44px}.g-replay-selected .g-review-player{font-size:15px}}

.g-review-navigator{background:linear-gradient(var(--g-glass-toolbar),var(--g-glass-toolbar)),#12181b}.g-review-navigator.is-editing{position:static;box-shadow:none}.g-review-navigator .g-review-quick-tools[hidden]{display:none!important}.g-review-panel:has(.g-review-editor) .g-review-editor{scroll-margin-top:12px}

.g-review-action-groups details.g-review-action-category{margin:0;padding:0;border:1px solid #ffffff1c}.g-review-action-category>summary{box-sizing:border-box;min-height:40px;padding:8px 9px;line-height:1.45;font-size:13px}@media(pointer:coarse){.g-review-action-category>summary{min-height:42px}}

.g-replay-token{background:radial-gradient(circle,transparent 55%,#604c3444),url('../../theme/token1.png') center/cover,#e6d5af}.g-replay-record>.g-review-copy{display:block;float:none;width:auto}.g-replay-record>.g-button{display:flex}.g-replay-record .g-review-copy p{margin:0}

/* Replay shares the grimoire's paper tokens, role arcs and reminder artwork. */
.g-dialog.g-replay-dialog{width:min(1200px,calc(var(--g-viewport-width,100vw) - 24px))}
.g-replay-layout{display:block}.g-replay-board-wrap{max-width:1100px;margin:auto}
.g-replay-board-tools{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.g-replay-board-tools .g-hint{margin:0;font-size:12px}.g-replay-board-tools .g-button{flex:none}
.g-replay-viewport{overflow:auto;max-width:100%;border-radius:14px;border:1px solid #ffffff29;overscroll-behavior:contain;scrollbar-color:#8a805f #172025}
.g-replay-board{width:100%;aspect-ratio:1/1.03;border:0;border-radius:0;background:linear-gradient(#08131618,#08131625),url('../../theme/bg_night.png') center/cover;--token-size:var(--replay-token-size,12.5cqw)}
.g-replay-board[data-phase=day]{background:linear-gradient(#0813160a,#08131620),url('../../theme/bg_day.png') center/cover}
.g-replay-viewport.is-enlarged .g-replay-board{width:160%;max-width:none}
.g-replay-center{left:34%;top:34%;width:32%;gap:5px;color:#f7e2a6;text-shadow:0 2px 4px #000}
.g-replay-center>img{width:100%;height:22cqw;object-fit:contain;filter:drop-shadow(0 2px 4px #0007)}.g-replay-center strong{font-size:clamp(12px,2cqw,22px)}.g-replay-center span{font-size:clamp(12px,2.3cqw,26px)}.g-replay-center small{font-size:clamp(10px,1.3cqw,14px);color:#e3e5de}
.g-replay-seat{width:calc(var(--token-size) + 3cqw);max-width:none;gap:4px;padding:0;border:0;border-radius:50%;z-index:2;min-height:0;outline-offset:5px}
.g-replay-portrait{position:relative;display:block;width:var(--token-size);height:var(--token-size)}
.g-replay-face.g-token{width:var(--token-size);height:var(--token-size);overflow:hidden;filter:none;opacity:1}.g-replay-face.g-token>img:not(.g-token-leaf){width:78%;height:78%;margin-top:-14%}
.g-replay-name{display:block;max-width:100%;padding:1px 6px;border:1px solid #d5d0b75c;background:#1c251fe6;border-radius:4px;font-size:clamp(10px,1.6cqw,17px);line-height:1.5;text-shadow:0 1px 2px #000}
.g-replay-seat.is-focused{background:none;border:0;box-shadow:none}.g-replay-seat.is-focused .g-token{outline:3px solid #ffe5a3;outline-offset:4px;box-shadow:0 0 22px #eccb6e88}
.g-replay-shroud{position:absolute;left:33%;top:0;width:34%;height:58%;background:url('../../theme/shroud1.png') top center/contain no-repeat;z-index:4;pointer-events:none}
.g-replay-seat.is-dead .g-replay-face>img:not(.g-token-leaf){filter:brightness(.48) saturate(.65)}
.g-replay-portrait .g-token-order{width:3.9cqw;height:3.9cqw;border-width:clamp(1px,.3cqw,3px);font-size:clamp(10px,2.5cqw,27px);top:50%}.g-replay-seat.is-dead .g-token-order{background:radial-gradient(circle at 42% 28%,#65686a,#343638 62%,#151718);color:#ddd}
.g-replay-vote{position:absolute;right:-4%;bottom:0;font-size:clamp(12px,2.3cqw,24px);color:white;line-height:1;text-shadow:0 2px 2px #000}.g-replay-vote.used{color:#9ba4a8}
.g-replay-markers{position:absolute;width:5.8cqw;height:5.8cqw;z-index:3;transform:translate(-50%,-50%);display:flex;gap:.5cqw;flex-direction:column;align-items:center}
.g-replay-board .g-replay-markers .g-reminder-token.g-button{--reminder-size:5.8cqw;width:var(--reminder-size);height:var(--reminder-size);min-width:var(--reminder-size);min-height:var(--reminder-size);max-width:var(--reminder-size);max-height:var(--reminder-size);aspect-ratio:1;transform:none!important;cursor:pointer;box-shadow:0 2px 5px #000b}
.g-replay-board:not(.is-crowded) .g-replay-markers>*{position:absolute}
.g-replay-markers .g-reminder-token .g-reminder-caption-arc{font-size:20px}.g-replay-markers.is-focused .g-reminder-token{outline:2px solid #e9cc82;outline-offset:1px}
.g-replay-board .g-replay-markers .g-replay-more.g-button{padding:0;min-height:25px;min-width:25px;max-height:25px;width:25px;height:25px;border-radius:50%;font-size:12px;background:#31223de8;color:#ffdfa2}
.g-replay-selected{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr));gap:10px;margin-top:10px;padding:0}.g-replay-selected article{margin:0;padding:16px}
.g-replay-detail-markers{display:flex;flex-wrap:wrap;gap:10px;margin-top:12px}.g-replay-detail-markers .g-reminder-token.g-button{--reminder-size:74px;transform:none!important}
.g-replay-records{max-width:1100px;margin:22px auto 0}.g-replay-records h3{font-size:17px}.g-replay-record{border-radius:8px}.g-replay-record .g-review-copy{font-size:15px}
.g-replay-board.is-crowded{padding:18px;gap:20px 10px;--token-size:14cqw}.g-replay-board.is-crowded .g-replay-center>img{display:none}.g-replay-board.is-crowded .g-replay-center{padding:8px;gap:4px}.g-replay-board.is-crowded .g-replay-seat{width:100%;max-width:none}.g-replay-cell{min-width:0}.g-replay-board.is-crowded .g-replay-markers{position:static;transform:none;width:auto;height:auto;flex-direction:row;flex-wrap:wrap;justify-content:center;margin-top:8px}.g-replay-board.is-crowded .g-replay-vote{right:3%}
@media(max-width:760px){.g-replay-board{aspect-ratio:1/1.18}.g-replay-board-tools{align-items:flex-start}.g-replay-board-tools .g-button{font-size:12px;padding:6px 10px}.g-replay-board-tools .g-hint{font-size:11px}.g-replay-center{top:36%}.g-replay-name{padding:0 3px}.g-replay-portrait .g-token-order{width:4.5cqw;height:4.5cqw}.g-replay-seat{gap:3px}.g-replay-detail-markers .g-reminder-token{--reminder-size:68px}.g-replay-board.is-crowded{grid-template-columns:repeat(3,minmax(0,1fr));--token-size:19cqw;gap:14px 8px;padding:12px}.g-replay-board.is-crowded .g-replay-markers .g-reminder-token{--reminder-size:9cqw}.g-replay-board.is-crowded .g-replay-portrait .g-token-order{width:6cqw;height:6cqw;font-size:4cqw}}
@media(max-width:760px){.g-replay-board.is-crowded .g-replay-markers .g-reminder-token.g-button{--reminder-size:9cqw}.g-replay-detail-markers .g-reminder-token.g-button{--reminder-size:68px}}

/* Keep the stage controls and grimoire in view while browsing the record list. */
.g-replay-board-tools{flex-wrap:wrap}.g-replay-board-tools>.g-hint{flex:1;min-width:150px}.g-replay-board-tools>.g-button{font-size:12px;padding:6px 9px}.g-replay-share-status a,#gReplayShareStatus a{color:#f4d184}
@media(max-height:500px){.g-replay-board:not(.is-crowded) .g-replay-seat{height:var(--token-size)}.g-replay-board:not(.is-crowded) .g-replay-name{position:absolute;top:100%;pointer-events:none}.g-replay-board:not(.is-crowded) .g-replay-vote{bottom:-15px;pointer-events:none}}
.grimoire-page #gDialog.g-replay-dialog[open]{display:flex;flex-direction:column;width:min(1480px,calc(var(--g-viewport-width,100vw) - 24px));height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 24px);max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 24px);overflow:hidden}
.grimoire-page #gDialog.g-replay-dialog>.g-modal-head{flex:none;padding:10px 16px;min-height:52px}
.grimoire-page #gDialog.g-replay-dialog>.g-modal-body{flex:1;min-height:0;max-height:none;height:auto;padding:12px 16px;overflow:hidden}
.g-replay{display:flex;flex-direction:column;height:100%;min-height:0;gap:8px}
.g-replay>.g-hint{flex:none;margin:0;font-size:11px;line-height:1.5}
.g-replay-controls{flex:none;gap:6px}.g-replay-controls select{min-width:0}
.g-replay-layout{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1fr) minmax(300px,34%);gap:16px}
.g-replay-board-wrap{display:flex;flex-direction:column;min-height:0;max-width:none;width:100%;margin:0}
.g-replay-board-tools{flex:none;margin:0 0 6px;gap:8px}.g-replay-board-tools .g-hint{font-size:11px;line-height:1.45}
.g-replay-viewport{flex:1;min-height:0;width:100%;container-type:size;background:#091013;position:relative}
.g-replay-viewport .g-replay-board{width:min(100cqw,calc(100cqh / 1.03));margin-inline:auto}
.g-replay-viewport.is-enlarged .g-replay-board{width:max(100cqw,calc(160cqh / 1.03));margin:0}
.g-replay-viewport .g-replay-board.is-crowded{width:100%;min-height:100%;align-content:start}.g-replay-viewport.is-enlarged .g-replay-board.is-crowded{width:160%}
.g-replay-sidebar{display:flex;flex-direction:column;min-width:0;min-height:0;gap:10px}
.g-replay-sidebar .g-replay-selected{flex:none;min-height:0;max-height:35%;overflow:auto;display:block;margin:0;padding:0;overscroll-behavior:contain;scrollbar-width:thin}
.g-replay-selected>.g-hint{margin:0;padding:8px;font-size:12px}.g-replay-selected article{padding:10px;margin-bottom:6px}.g-replay-selected article:last-child{margin-bottom:0}.g-replay-selected p{font-size:12px;margin:4px 0}
.g-replay-sidebar .g-replay-records{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;margin:0;width:100%;padding-right:5px}
.g-replay-records h3{margin:0;padding:8px 0;font-size:15px;position:sticky;top:0;z-index:1;background:#111719}
.g-replay-record{padding:9px 10px;margin:0 0 8px}.g-replay-record .g-review-copy{font-size:13px;line-height:1.75}.g-replay-record .g-button{font-size:12px;min-height:32px;padding:4px 8px}
.g-replay-tabs{display:none}
@media(max-width:760px){
 .grimoire-page #gDialog.g-replay-dialog[open]{width:calc(var(--g-viewport-width,100vw) - 12px);height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 12px);max-height:calc(var(--g-visible-height,var(--g-viewport-height,100dvh)) - 12px)}
 .grimoire-page #gDialog.g-replay-dialog>.g-modal-body{padding:8px 10px}.g-replay{gap:6px}.g-replay-controls .g-button,.g-replay-controls select{min-height:38px;font-size:12px}
 .g-replay-tabs{display:flex;gap:6px;flex:none}.g-replay-tabs .g-button{flex:1;min-height:38px;padding:4px;font-size:13px}.g-replay-tabs .g-button[aria-pressed=true]{border-color:#d6bc79;background:#d6bc7920;color:#ffe6a3}
 .g-replay-layout{display:flex;gap:0}.g-replay-board-wrap,.g-replay-sidebar{width:100%}
 .g-replay[data-pane=board] .g-replay-sidebar,.g-replay:not([data-pane=board]) .g-replay-board-wrap{display:none}
 .g-replay[data-pane=records] .g-replay-selected,.g-replay[data-pane=selected] .g-replay-records{display:none}
 .g-replay[data-pane=selected] .g-replay-selected{flex:1;max-height:none;width:100%}
 .g-replay-viewport .g-replay-board{width:min(100cqw,calc(100cqh / 1.18))}.g-replay-viewport.is-enlarged .g-replay-board{width:max(160cqw,calc(160cqh / 1.18))}
 .g-replay-record .g-button{min-height:38px}.g-replay-detail-markers .g-reminder-token.g-button{--reminder-size:68px}
}

/* Review links and game library reuse shared glass and controls. */
.g-review-link-options,.g-stage-changes{padding:12px;border:1px solid var(--g-glass-edge);border-radius:10px;margin:10px 0;background:var(--g-glass-card)}
.g-stage-changes ul{padding-left:1.3em;margin:8px 0}.g-stage-changes li{margin:5px 0;overflow-wrap:anywhere}
.g-game-library-tools,.g-game-library-row{display:flex;gap:8px;flex-wrap:wrap}.g-game-library-row{padding:12px 0;border-bottom:1px solid var(--g-glass-edge)}.g-game-library-row h3,.g-game-library-row p{flex-basis:100%;margin:0;overflow-wrap:anywhere}
@media(max-width:600px){.g-game-library-tools>button{flex:1 1 140px}}


.g-review-export-phases{min-width:0;margin:0;padding:12px;border:1px solid var(--g-glass-edge);border-radius:10px;background:var(--g-glass-card)}
.g-review-export-phases legend{font-size:14px;padding:0 6px}.g-review-export-phase-tools{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:8px}.g-review-export-phase-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-height:190px;overflow:auto;overscroll-behavior:contain;padding:2px}
.g-review-export-phase-list label{display:flex;flex-direction:row;align-items:center;gap:8px;font-size:13px;min-width:0;overflow-wrap:anywhere;background:var(--g-glass-control);padding:8px;border-radius:6px}.g-review-export-phase-list input{width:18px;height:18px;flex:none;accent-color:#cbb77d}.g-review-export .is-warning{color:#edcf8e}
@media(max-width:600px){.g-review-export-phase-list{grid-template-columns:minmax(0,1fr);max-height:165px}.g-review-export-options{justify-content:flex-start}.g-review-export #gReviewExportGenerate,.g-review-export #gReviewExportDownload{min-height:42px}}

.g-review-export-save{display:flex;justify-content:flex-end;position:sticky;top:0;z-index:2;padding:8px;background:var(--g-glass-fill);border-radius:8px;border:1px solid var(--g-glass-edge)}

.g-share-link{display:grid;gap:12px;min-width:0}.g-share-link fieldset{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-height:240px;overflow:auto;border:1px solid var(--g-glass-edge);border-radius:12px;padding:12px}.g-share-link label{display:flex;align-items:center;gap:8px;min-height:44px;line-height:1.6}.g-share-link input[type=checkbox]{width:20px;height:20px;flex:none}.g-share-link iframe{width:100%;height:560px;max-height:65dvh;border:1px solid var(--g-glass-edge);border-radius:12px;background:#0b1114}.g-share-link [hidden]{display:none}.g-share-link article{padding:12px;background:var(--g-glass-card);border:1px solid var(--g-glass-edge);border-radius:12px;margin-bottom:10px;overflow-wrap:anywhere}.g-share-link textarea{width:100%;min-width:0;font-size:14px}.g-share-link article button{min-height:44px;margin-right:8px}@media(max-width:600px){.g-share-link fieldset{grid-template-columns:1fr}.g-share-link>button{min-height:44px}}


.g-seat-dialog .g-seat-review-add{width:100%;min-height:44px;margin:4px 0 8px}
.g-seat-quick-records{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 8px}.g-seat-quick-records .g-button{flex:1 1 90px;min-height:40px}
.g-review-record-preview .g-review-preview-part{display:inline;min-height:0;margin:0;padding:0 2px;border:0;border-bottom:1px dashed currentColor;border-radius:0;background:transparent;color:inherit;font:inherit;line-height:inherit;white-space:normal;cursor:pointer}.g-review-record-preview .g-review-preview-part:focus-visible{outline:2px solid #e5ca86;outline-offset:2px}
.g-seat-dialog .g-seat-quick-status{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:0;margin:0 0 8px}
.g-seat-dialog .g-seat-quick-status .g-button{min-height:44px;padding:8px;font-size:13px;white-space:normal}

/* One portrait stage for every player count: side rails and corner controls overlay the table. */
.g-centered-phone-ui .g-board.phone-table{inset:0;scrollbar-gutter:auto}
.g-centered-phone-ui .phone-table .g-seat .g-seat-name{width:auto;min-width:32px;max-width:100%;border-radius:8px;padding-inline:4px}
.g-centered-phone-ui .phone-table .g-seat.dead .g-seat-caption{max-width:var(--g-phone-caption-width)}
.g-centered-phone-ui .phone-table .g-seat .g-reminder-tokens{--reminder-size:32px}

/* Keep an unfinished action focused on its form; the normal log returns after save/cancel. */
.g-review-panel:has(.g-review-editor) :is(.g-review-navigator,.g-review-stage-tools,.g-review-heading,.g-review-empty,.g-review-add-stage){display:none!important}
.g-review-panel:has(.g-review-editor) .g-review-stage:not(:has(.g-review-editor)),.g-review-panel:has(.g-review-editor) .g-review-entry:not(:has(.g-review-editor)){display:none!important}
.g-review-panel:has(.g-review-editor) .g-review-toolbar :is(#gReviewReplay,#gReviewExport,#gReviewHistory),.g-review-entry:has(.g-review-editor)>:is(.g-review-copy,.g-review-entry-tools,.g-review-drag,.g-review-suggestion,.g-hint){display:none!important}

.g-night-review-flow{display:grid;gap:7px;padding:10px;margin:10px 0 14px;border:1px solid #cbb77d40;border-radius:7px;background:var(--g-glass-card)}.g-night-review-flow>strong{color:#d8c894;font-size:13px}.g-night-review-flow .g-hint{margin:0;font-size:11px;line-height:1.65}.g-night-review-badge{font-size:10px;color:#c5cdbd;line-height:1.5;align-self:center}.g-night-review-flow .g-night-record-actions{margin:0}.g-night-record-actions [data-night-review-skip]{font-size:11px;color:#b4bcbf}.g-night-record-actions [data-night-review-status]{flex:0 0 auto}@media(pointer:coarse){.g-night-review-flow .g-button,.g-night-record-actions [data-night-review-skip]{min-height:44px}}

/* Keep reading uninterrupted; per-record actions open only on request. */
.g-review-panel .g-review-entry{min-height:44px;padding:8px 34px 8px 22px;box-sizing:border-box}
.g-review-panel .g-review-entry>.g-review-drag{left:-7px;top:3px;width:26px;min-width:26px;min-height:36px;font-size:18px;color:#68767d}
.g-review-entry>.g-review-copy{display:block;min-width:0}.g-review-entry>.g-review-copy p{line-height:1.65}
.g-review-entry>.g-review-more{position:absolute;right:-3px;top:3px;width:32px;min-width:32px;min-height:36px;padding:0;border:0;background:transparent;color:#849198;font-size:23px;line-height:1}
.g-review-entry>.g-review-more:is(:hover,:focus-visible,[aria-expanded=true]){color:#e0d4b4;background:#ffffff08}
.g-review-entry>.g-review-entry-tools{float:none;clear:both;justify-content:flex-start;margin:8px -26px 0 0;padding:8px;border:1px solid #ffffff18;border-radius:5px;background:var(--g-glass-card);gap:6px}
.g-review-entry-tools[hidden]{display:none!important}.g-review-entry-tools>.g-hint{flex:0 0 100%;margin:0 0 3px;font-size:10px;line-height:1.5}
.g-review-panel:has(.g-review-editor) .g-review-more{display:none!important}
@media(pointer:coarse){.g-review-panel .g-review-entry{min-height:48px;padding-top:10px;padding-bottom:10px}.g-review-entry>.g-review-more{top:2px;min-height:44px}.g-review-entry>.g-review-entry-tools .g-button{min-height:44px}}

.g-review-token-options{display:grid;gap:8px;min-width:0;padding:10px;border:1px solid #cbb77d40;border-radius:6px;background:var(--g-glass-card)}.g-review-token-options[hidden]{display:none!important}.g-review-token-options .g-review-token-toggle{flex-direction:row;align-items:center;justify-content:space-between;gap:10px;margin:0;color:#d8c894}.g-review-token-toggle input{flex:none;width:20px;height:20px;accent-color:#cbb77d}.g-review-token-options label{margin:0}.g-review-token-options .g-hint{margin:0;line-height:1.7}
.g-centered-phone-ui .phone-table .g-seat .g-reminder-tokens{--reminder-size:32px}
.g-centered-phone-ui .phone-table .g-seat .g-life-toggle{width:min(44px,var(--token-size))}

.g-history-correction{display:grid;gap:12px}.g-history-correction label{display:grid;gap:6px}.g-history-correction input,.g-history-correction select,.g-history-correction textarea{width:100%;min-width:0;box-sizing:border-box}.g-history-correction h3{margin:0}

.g-history-preview{padding:10px;border:1px solid var(--g-glass-border,rgba(255,255,255,.15));border-radius:8px;overflow-wrap:anywhere}.g-history-preview ul{margin:0;padding-left:20px}.g-history-preview li{white-space:pre-wrap;margin:4px 0}

.g-setup-warning{border:1px solid #bf7626;border-radius:8px;background:rgba(111,56,8,.25);color:#f1ce80;padding:9px 11px;font-size:12px;text-align:left;overflow-wrap:anywhere}.g-setup-warning ul{margin:6px 0;padding-left:18px;max-height:150px;overflow:auto}.g-setup-warning summary{cursor:pointer}.g-setup-warning .g-hint{color:inherit;margin:5px 0 0}.g-setup-warning[hidden]{display:none}

/* Keep the distribution footer compact; long setup notes must not consume the role list. */
.g-distribution-dialog .g-bag-footer{gap:8px 14px;padding:9px 0;max-height:45%;overflow:auto;box-sizing:border-box;overscroll-behavior:contain}
.g-distribution-dialog .g-bag-settings{flex-direction:row;align-items:center;flex-wrap:wrap;gap:8px 16px}
.g-distribution-dialog #gBagClear{margin-left:0;padding:4px 0}
.g-distribution-dialog #gBagSetupWarning{grid-column:1/-1;display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px;padding:7px 10px;line-height:1.5}
.g-distribution-dialog #gBagSetupWarning[hidden]{display:none}
.g-distribution-dialog #gBagSetupWarning>strong{flex:none}
.g-distribution-dialog #gBagSetupWarning ul{display:flex;flex:1;flex-wrap:wrap;gap:3px 14px;list-style:none;margin:0;padding:0;max-height:76px;min-width:140px}
.g-distribution-dialog #gBagSetupWarning li{margin:0}
.g-distribution-dialog #gBagSetupWarning .g-hint{flex-basis:100%;margin:0;font-size:11px}
@media(max-width:700px){
 .g-distribution-dialog .g-bag-footer{grid-template-columns:minmax(0,1fr);gap:6px}
 .g-distribution-dialog .g-bag-settings{gap:6px 12px}
 .g-distribution-dialog #gBagClear{margin-left:auto}
 .g-distribution-dialog .g-bag-actions{display:grid;grid-template-columns:1fr 1.4fr 1fr;gap:6px}
 .g-distribution-dialog .g-bag-actions .g-button{width:100%;padding:8px 5px;white-space:normal;min-height:40px}
 .g-distribution-dialog .g-bag-actions #gOfflineStart{grid-column:auto}
 .g-distribution-dialog #gBagSetupWarning{gap:3px 8px;font-size:11px}
}

.g-bag-setup-badge{position:absolute;top:3px;left:3px;z-index:3;display:grid;place-items:center;width:22px;height:22px;box-sizing:border-box;border:1px solid #ffe5a0;border-radius:50%;background:#ac510d;color:#fff4cb;font:800 17px/1 system-ui,sans-serif;box-shadow:0 1px 5px #000b;pointer-events:none}
@media(max-width:700px){.g-bag-setup-badge{width:20px;height:20px;font-size:15px;top:1px;left:1px}}

/* Grimoire finish: charcoal glass, restrained brass accents, unchanged table geometry. */
.grimoire-page .g-app{--g-glass-fill:rgba(12,17,22,.94);--g-glass-card:rgba(24,30,36,.86);--g-glass-control:rgba(8,13,18,.8);--g-glass-toolbar:rgba(13,19,25,.96);--g-glass-edge:rgba(213,190,137,.2);--g-glass-shadow:0 12px 32px #05090f55,inset 0 1px #ffffff0b;--g-muted:#adb9c4;--g-gold:#ead29a;box-shadow:inset 0 0 120px #07111e48;-webkit-font-smoothing:antialiased}
.grimoire-page .g-app :is(.g-summary,.g-dock){background:linear-gradient(145deg,#20272cf2,#0d1319f5);border-color:#d5be893d;box-shadow:0 8px 28px #040b164d,inset 0 1px #fff1;border-radius:14px}
.grimoire-page .g-app .g-summary #gTitle{color:#f0d99f;letter-spacing:.035em;text-shadow:0 1px 3px #0008}
.grimoire-page .g-app #gCounts{color:#c2ccd2;font-variant-numeric:tabular-nums}
.grimoire-page .g-app .g-summary-target{opacity:.66}
.grimoire-page .g-app .g-phase{color:#eed69a;letter-spacing:.04em}
.grimoire-page .g-app :is(.g-rail-button,.g-view-actions .g-button){background:linear-gradient(155deg,#263038f5,#12191ff5);border-color:#d6c3953d;box-shadow:0 3px 12px #07101c42,inset 0 1px #ffffff12;color:#e3e8e7}
.grimoire-page .g-app .g-left-tools .g-rail-button{border-radius:0 10px 10px 0}
.grimoire-page .g-app .g-right-tools .g-rail-button{border-radius:10px 0 0 10px}
.grimoire-page .g-app .g-rail-button[aria-expanded=true]{background:#393629;border-color:#d7bd78;color:#ffe6ad;box-shadow:inset 3px 0 #d7bd78,0 3px 10px #0005}
.grimoire-page .g-app .g-dock :is(#gScript,#gAssign){background:linear-gradient(#343e46,#252e36);border-color:#b7c5ce30;color:#e4e9eb;border-radius:9px;box-shadow:inset 0 1px #ffffff09}
.grimoire-page .g-app .g-dock #gAdvance{background:linear-gradient(135deg,#e4cf9b,#c1a66d);color:#211d15;border-color:#f0dca6;border-radius:9px;box-shadow:inset 0 1px #fff6,0 3px 10px #0003;text-shadow:0 1px #fff3}
.grimoire-page .g-app .g-seat .g-seat-name{background:linear-gradient(#1d2933f2,#111b24f5);border-color:#ddca965e;color:#f6eedb;box-shadow:0 2px 7px #030a124d,inset 0 1px #ffffff0b;font-weight:600;letter-spacing:.015em}
.grimoire-page .g-app .g-token-order{border-color:#16212c;box-shadow:0 3px 7px #08101b70,inset 0 1px #ffffff40;font-variant-numeric:tabular-nums;text-shadow:0 1px 2px #0007}
.grimoire-page .g-app .g-seat:not(.dead) .g-token-order.first{background:linear-gradient(145deg,#336ca2,#193c65)}
.grimoire-page .g-app .g-seat:not(.dead) .g-token-order.other{background:linear-gradient(145deg,#ac4846,#682c31)}
.grimoire-page .g-app .g-start-hint{background:#10202cdb;border:0;box-shadow:inset 0 0 0 1px #b8cbd11c;color:#d2dde1;border-radius:8px}
.grimoire-page .g-app .g-privacy{color:#a1adb6}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal){border-color:#d5be893d;box-shadow:0 22px 70px #02060c99,inset 0 1px #ffffff10}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal) .g-modal-head{border-bottom-color:#d5be8926}
@media(hover:hover){.grimoire-page .g-app :is(.g-rail-button,.g-view-actions .g-button):hover{background:#33404a;color:#ffe2a0;border-color:#e7c87f88}.grimoire-page .g-app .g-seat .g-seat-name:hover{background:#2a3a46;border-color:#e4ce92}.grimoire-page .g-app .g-dock :is(#gScript,#gAssign):hover{background:#3a4955;border-color:#d9c58c77}}

.grimoire-page .g-centered-phone-ui .phone-table .g-seat .g-seat-name{padding-inline:2px;letter-spacing:0;font-weight:550;font-size:10px}
.g-tool-transfer-status{display:flex;flex-wrap:wrap;gap:8px;padding:10px;border:1px solid #d5be8955;border-radius:8px;background:var(--g-glass-card);overflow-wrap:anywhere}
.g-tool-transfer-status[hidden]{display:none}
.g-tool-transfer-status .g-hint{flex-basis:100%;margin:0;line-height:1.65}
.g-tool-transfer-status a.g-button{text-decoration:none}

/* Typography only: retain token artwork, diameter, caption boxes and seat geometry. */
.grimoire-page .g-token .g-seat-role-arc{font-family:"Songti SC","Noto Serif CJK SC","SimSun",serif;font-weight:700}
.grimoire-page .g-token .g-seat-role-arc text{fill:#211b17;stroke:#fff5df;stroke-width:.8px}
.grimoire-page .g-seat-token.is-role-hovered .g-seat-role-arc text{fill:#fff7e8;stroke:#211b17;stroke-width:.8px}
.grimoire-page .g-reminder-token .g-reminder-caption{font-family:"PingFang SC","Microsoft YaHei",sans-serif;font-weight:650}
.grimoire-page .g-reminder-caption text{fill:#fff8e9;stroke:#1e1427;stroke-width:1.6px;filter:none}
.grimoire-page .g-app .g-seat .g-seat-name{font-size:clamp(10px,calc(var(--token-size,112px)*.125),15px);line-height:21px;font-weight:600;letter-spacing:.025em;font-variant-numeric:tabular-nums;text-shadow:0 1px 1px #000b}
.grimoire-page .g-centered-phone-ui .phone-table .g-seat .g-seat-name{font-size:10.5px;line-height:13px;letter-spacing:0}

/* Tabletop palette: keep the existing tokens and dark glass controls. */
.grimoire-page .g-app[data-custom-background=false]{background-image:radial-gradient(ellipse at 50% 46%,transparent 28%,#10111b55 100%),linear-gradient(145deg,#231d2e55,#16212a38 48%,#241b2e66),url("../../theme/bg_day.png")}
.grimoire-page .g-app[data-custom-background=false]:before{background-image:radial-gradient(ellipse at 50% 46%,transparent 26%,#090b1499 100%),linear-gradient(145deg,#28193566,#14192644 48%,#1d142b88),url("../../theme/bg_night.png")}
.grimoire-page .g-center{filter:drop-shadow(0 5px 10px #07050cbb)}
.grimoire-page .g-seat .g-token{box-shadow:0 4px 10px #08050dbb,0 0 0 1px #d6c28c55}
.grimoire-page .g-seat:hover .g-token{box-shadow:0 0 0 2px #e5ca85,0 5px 18px #08050dbb}
.grimoire-page .g-app .g-seat .g-seat-name{background:#151319e8;border-color:#cfbd8b66;color:#f7eddb;box-shadow:0 2px 5px #0008}
.grimoire-page .g-app .g-rail-button{background:#16131def;border-color:#a78d5c66;color:#efe6d4;box-shadow:0 3px 10px #08050a88,inset 0 1px #f6d78b12}
.grimoire-page .g-app .g-rail-button:hover,.grimoire-page .g-app .g-rail-button[aria-expanded=true]{background:#342639;color:#ffe6ac;border-color:#c9ad70aa}
.grimoire-page .g-app :is(.g-summary,.g-dock){border-color:#c9ad705c;box-shadow:0 8px 24px #08050a88,inset 0 1px #ead39c1a}
.grimoire-page .g-emblem{border-color:#bd9b5c88;background:linear-gradient(145deg,#302638,#171820)}
@media(max-width:700px){.grimoire-page .g-seat .g-seat-name{box-shadow:0 1px 3px #0009}}

/* Quiet, cohesive tabletop chrome; no geometry or private presentation changes. */
.grimoire-page .g-app :is(.g-summary,.g-dock){background:linear-gradient(155deg,#22232aef,#10141bf7);border-color:#d7c39838;box-shadow:0 10px 28px #090a1180,inset 0 1px #ffffff12}
.grimoire-page .g-app .g-control-heading{border-bottom:1px solid #dec99824;padding-bottom:7px}
.grimoire-page .g-app .g-phase{color:#f0dca9;text-shadow:0 1px 4px #0009}
.grimoire-page .g-app .g-seat-stepper{background:#080d13a8;box-shadow:inset 0 0 0 1px #d6c2951c;color:#dfdfd8}
.grimoire-page .g-app .g-seat .g-seat-name{background:linear-gradient(180deg,#262329f2,#121319f5);border-color:#cdb98266;box-shadow:0 2px 6px #07080db3,inset 0 1px #fff1;color:#faf1db}
.grimoire-page .g-app .g-rail-button{background:linear-gradient(145deg,#29242ef5,#15171ef7);border-color:#cbb78940;color:#e9e3d8;box-shadow:0 4px 12px #08091080,inset 0 1px #ffffff12}
.grimoire-page .g-app .g-rail-button[aria-expanded=true]{background:#3a3034;border-color:#d2b77d;color:#ffedc5;box-shadow:inset 3px 0 #d5bc83,0 3px 10px #0007}
.grimoire-page .g-app .g-view-actions .g-button{background:linear-gradient(145deg,#292b32f2,#151820f7);border-color:#cbb78940}
.grimoire-page .g-app .g-dock :is(#gScript,#gAssign){background:linear-gradient(#30323a,#22242b);border-color:#dbccab38;color:#eeeae1}
.grimoire-page .g-app .g-dock #gAdvance{background:linear-gradient(135deg,#ecd9aa,#c7ab72);border-color:#f0dba7;color:#252017}
.grimoire-page .g-app .g-start-hint{background:#171b22df;color:#d9dedc;box-shadow:inset 0 0 0 1px #d6c29522}
@media(hover:hover) and (pointer:fine){.grimoire-page .g-app .g-rail-button:hover{background:#403440;border-color:#d4ba8077;color:#ffedc5}.grimoire-page .g-app .g-seat .g-seat-name:hover{background:#393039;border-color:#e4ce92}.grimoire-page .g-app .g-dock :is(#gScript,#gAssign):hover{background:#41404a;border-color:#d9c58c77}}

/* Menu: compact sections, a clearer current-script card and quieter supporting text. */
.grimoire-page #gDialog.g-menu-dialog>.g-modal-head{min-height:58px;padding-inline:18px;background:var(--g-glass-toolbar);border-bottom:1px solid var(--g-glass-edge)}
.grimoire-page #gDialog.g-menu-dialog .g-modal-head h2{font-size:17px;letter-spacing:.04em;color:#f1e7d2}
.grimoire-page #gDialog.g-menu-dialog>.g-modal-body{padding:4px 17px 22px;scrollbar-color:#b7a98266 transparent}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section{margin:16px 0 20px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section h3{margin-bottom:8px;color:#d1c6ae;font-size:12px;letter-spacing:.05em}
.grimoire-page #gDialog.g-menu-dialog .g-menu-section h3:after{background:linear-gradient(90deg,#d9c49438,transparent)}
.grimoire-page #gDialog.g-menu-dialog .g-menu-grid{gap:7px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item{border-radius:9px;background:var(--g-glass-card);border-color:#ffffff1c;color:#e6e7e1;box-shadow:inset 0 1px #ffffff08}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item>svg{color:#aeb9b5}
.grimoire-page #gDialog.g-menu-dialog .g-menu-item[aria-pressed=true]{background:#b9a16c20;border-color:#c9ae7488;color:#f6e4b8;box-shadow:inset 3px 0 #d7bd80}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script{grid-column:1/-1;min-height:70px;background:linear-gradient(125deg,#ac95632b,#ffffff05);border-color:#c6ae7459}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script-logo{flex:none;width:58px;height:44px;object-fit:contain;filter:drop-shadow(0 2px 3px #0009)}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script strong{color:#f3e5c2;font-size:15px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-script small{color:#b7bdb5;font-size:11px}
.grimoire-page #gDialog.g-menu-dialog #gToolTo_editor{grid-column:1/-1}
.grimoire-page #gDialog.g-menu-dialog .g-menu-transfer-note{margin:0 2px;color:#aab4b5;font-size:11px;line-height:1.6}
.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{background:var(--g-glass-card);border-color:#ffffff1c;border-radius:9px}
.grimoire-page #gDialog.g-menu-dialog .g-menu-footer{margin-top:8px;padding-top:14px;line-height:1.6}
@media(hover:hover) and (pointer:fine){.grimoire-page #gDialog.g-menu-dialog .g-menu-item:hover:not(:disabled){background:#d7c3921c;border-color:#d0ba8877;color:#fff2d5}}
@media(max-width:700px){.grimoire-page #gDialog.g-menu-dialog>.g-modal-head{padding-inline:16px}.grimoire-page #gDialog.g-menu-dialog>.g-modal-body{padding-inline:14px;padding-bottom:max(22px,env(safe-area-inset-bottom))}.grimoire-page #gDialog.g-menu-dialog .g-menu-section{margin:15px 0 20px}.grimoire-page #gDialog.g-menu-dialog .g-menu-item,.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{min-height:46px}}

/* Shared dark matte glass for menus and tool panels. */
.grimoire-page .g-app{--g-glass-fill:rgba(7,9,12,.87);--g-glass-toolbar:rgba(10,12,15,.84);--g-glass-edge:rgba(255,255,255,.12);--g-glass-filter:blur(20px) saturate(.65);--g-glass-shadow:0 12px 32px #0008,inset 0 1px #ffffff08}
.grimoire-page .g-app :is(.g-side-panel.g-sheet-dialog,.g-notes-panel,.g-aux-panel,.g-timer-panel){background:var(--g-glass-fill);border-color:var(--g-glass-edge);box-shadow:var(--g-glass-shadow);-webkit-backdrop-filter:var(--g-glass-filter);backdrop-filter:var(--g-glass-filter)}
.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal){background:var(--g-glass-fill);border-color:var(--g-glass-edge);box-shadow:var(--g-glass-shadow);-webkit-backdrop-filter:var(--g-glass-filter);backdrop-filter:var(--g-glass-filter)}
.grimoire-page .g-app :is(.g-side-panel>.g-modal-head,.g-notes-head),.grimoire-page #gDialog:not(.g-signal-player):not(.g-signal-dialog):not(.g-bluff-reveal)>.g-modal-head{background:rgba(13,15,18,.65);border-bottom-color:#ffffff14}
.grimoire-page .g-app .g-side-panel .g-modal-head h2{color:#e7e6e2}
.grimoire-page .g-app .g-side-panel :is(.g-sheet-toolbar,.g-night-toolbar){border-bottom-color:#ffffff12}
.grimoire-page .g-app .g-side-panel :is(#gSheetFloat,#gNightFloat,.g-side-close){border-color:#ffffff2b;background:#16191c80;color:#dedfdd}
@media(pointer:coarse){.grimoire-page .g-app{--g-glass-filter:blur(10px) saturate(.65);--g-glass-fill:rgba(7,9,12,.92)}}
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){.grimoire-page .g-app{--g-glass-fill:rgba(7,9,12,.97);--g-glass-toolbar:rgba(10,12,15,.97)}}

/* Matte charcoal rail buttons, matching the compact tabletop controls. */
.grimoire-page .g-app .g-rail-button:not(.is-running):not(.is-finished):not([aria-expanded=true]),.grimoire-page .g-app .g-view-actions #gPlayerView:not([aria-pressed=true]){background:#30363beF;border-color:#ffffff0d;color:#f0f0ed;box-shadow:none;backdrop-filter:none;-webkit-backdrop-filter:none}
.grimoire-page .g-app .g-rail-button[aria-expanded=true]{background:#424a50;border-color:#ffffff2b;color:#fff;box-shadow:inset 2px 0 #d5c39b}
@media(hover:hover) and (pointer:fine){.grimoire-page .g-app .g-rail-button:not(.is-running):not(.is-finished):hover,.grimoire-page .g-app .g-view-actions #gPlayerView:not([aria-pressed=true]):hover{background:#464e54;border-color:#ffffff24;color:#fff}}

/* Built-in tabletop backgrounds retain the current game's day/night state. */
.grimoire-page .g-app[data-custom-background=false][data-background-preset=day]:before,.grimoire-page .g-app[data-custom-background=false][data-background-preset=night]:before,.grimoire-page .g-app[data-custom-background=false][data-background-preset=violet]:before{display:none}
.grimoire-page .g-app[data-custom-background=false][data-background-preset=night]{background-image:linear-gradient(#14182755,#12121d77),url("../../theme/bg_night.png")}
.grimoire-page .g-app[data-custom-background=false][data-background-preset=violet]{background-image:linear-gradient(145deg,#48315599,#1d16317d 55%,#24172ca6),url("../../theme/bg_night.png")}
.g-background-presets{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-bottom:20px}
.g-background-dialog .g-background-preset{position:relative;display:flex;align-items:flex-end;min-height:85px;padding:9px;border:1px solid #ffffff30;border-radius:8px;color:#fff;text-align:left;text-shadow:0 1px 3px #000;background:linear-gradient(0deg,#0b1019ef,transparent 75%),url("../../theme/bg_day.png") center/cover;overflow:hidden}
.g-background-dialog .g-background-preset[data-preset=night]{background-image:linear-gradient(0deg,#0b1019ef,transparent 75%),url("../../theme/bg_night.png")}
.g-background-dialog .g-background-preset[data-preset=violet]{background-image:linear-gradient(0deg,#160c21ef,#58336d66),url("../../theme/bg_night.png")}
.g-background-dialog .g-background-preset[aria-pressed=true]{border-color:#e4ca8c;box-shadow:inset 0 0 0 1px #e4ca8c;color:#fff3d4}
.g-background-dialog .g-background-preset:focus-visible{outline:3px solid #f4da96;outline-offset:2px}
.grimoire-page .g-app[data-custom-background=false][data-background-preset^=damask-]:before,.grimoire-page .g-app[data-custom-background=false][data-background-preset^=damask-]:after{display:none}
.grimoire-page .g-app[data-custom-background=false][data-background-preset=damask-purple]{background-image:url("../../theme/table-purple.png")}
.grimoire-page .g-app[data-custom-background=false][data-background-preset=damask-red]{background-image:url("../../theme/table-red.png")}
.grimoire-page .g-app[data-custom-background=false][data-background-preset=damask-gold]{background-image:url("../../theme/table-gold.png")}
.g-background-dialog .g-background-preset[data-preset=damask-purple]{background-image:linear-gradient(0deg,#0b1019df,transparent 75%),url("../../theme/table-purple.png")}
.g-background-dialog .g-background-preset[data-preset=damask-red]{background-image:linear-gradient(0deg,#0b1019df,transparent 75%),url("../../theme/table-red.png")}
.g-background-dialog .g-background-preset[data-preset=damask-gold]{background-image:linear-gradient(0deg,#0b1019df,transparent 75%),url("../../theme/table-gold.png")}

/* Night fog stays behind the board and never catches pointer input. */
.grimoire-page .g-app[data-phase=night][data-background-preset]:after{display:block;inset:0;opacity:.14;filter:blur(2px);mask-image:none;-webkit-mask-image:none;background-image:linear-gradient(0deg,#10182d80,#11152324 65%,transparent),url("../../theme/clouds.png");background-repeat:no-repeat,repeat-x;background-size:cover,95% auto;background-position:center,0% center;pointer-events:none}
@keyframes g-night-cloud-drift{from{background-position:center,-160px center}to{background-position:center,160px center}}
@media(prefers-reduced-motion:no-preference){.grimoire-page .g-app[data-phase=night]:after{animation:g-night-cloud-drift 60s linear infinite alternate}}
@media(pointer:coarse){.grimoire-page .g-app[data-phase=night][data-background-preset]:after{opacity:.12;background-size:cover,110% auto}}

/* Compact phone reminders stay grouped around their own role. */
.g-centered-phone-ui .phone-table .g-seat .g-reminder-tokens{--reminder-size:30px}
.grimoire-page .g-centered-phone-ui .phone-table .g-seat .g-reminder-tokens :is(.g-reminder-token,.g-reminder-add){width:var(--reminder-size);height:var(--reminder-size);min-width:var(--reminder-size);min-height:var(--reminder-size);aspect-ratio:1}
.g-centered-phone-ui .phone-table .g-reminder-tokens>[hidden]{display:none!important}
.g-centered-phone-ui .phone-table .g-reminder-add:before{font-size:22px}
/* Empty seat container must not cover controls on a neighboring seat. */
.g-centered-phone-ui .phone-table .g-seat{pointer-events:none}
.g-centered-phone-ui .phone-table .g-seat :is(.g-seat-token,.g-seat-name,.g-life-toggle,.g-reminder-item,.g-reminder-add,.g-reminder-more){pointer-events:auto}
/* Keep player names usable when a fixed marker row crosses a caption. */
.g-centered-phone-ui .phone-table .g-seat .g-seat-caption{z-index:6}

/* Compact phone menu: anchored group shortcuts and a single scroll surface. */
.g-menu-jump{display:none}
@media(max-width:700px){
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump{position:sticky;top:-4px;z-index:10;display:flex;gap:6px;overflow-x:auto;overscroll-behavior-inline:contain;scrollbar-width:none;margin:0 -14px 4px;padding:8px 14px;background:rgba(12,15,18,.96);border-bottom:1px solid #ffffff16;-webkit-overflow-scrolling:touch}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump::-webkit-scrollbar{display:none}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump-button{flex:none;min-height:36px;padding:6px 12px;border:1px solid #ffffff24;border-radius:18px;background:#ffffff09;color:#ddd9cb;font-size:12px;white-space:nowrap;touch-action:manipulation}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump-button:active{background:#cab7832b;border-color:#dbc68b}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-item,.grimoire-page #gDialog.g-menu-dialog .g-menu-stepper{min-height:48px}
 .grimoire-page #gDialog.g-menu-dialog #gDialogClose{width:44px;min-width:44px;height:44px;min-height:44px}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-label{overflow-wrap:anywhere}
}
@media(max-width:700px) and (min-height:500px){
 .grimoire-page #gDialog.g-menu-dialog[open]{inset:auto max(4px,env(safe-area-inset-right)) max(4px,env(safe-area-inset-bottom)) max(4px,env(safe-area-inset-left));width:auto;max-width:none;height:min(88dvh,850px);max-height:calc(var(--g-viewport-height,100dvh) - 20px);border-radius:16px 16px 10px 10px}
}
@media(max-width:700px) and (max-height:499px){
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump{padding-block:4px}
 .grimoire-page #gDialog.g-menu-dialog .g-menu-jump-button{min-height:32px}
}

.g-distribution-dialog label.g-bag-order{display:flex;flex-direction:row;align-items:center;gap:7px;margin:0;font-size:12px;color:#d1d7cf}.g-bag-order select{width:auto;min-height:36px;padding:5px 25px 5px 9px;font-size:12px}
@media (pointer:coarse){.grimoire-page #gDialog.g-seat-dialog .g-seat-add-marker{min-height:44px;padding:8px 14px;font-size:14px}.grimoire-page #gDialog.g-reminder-dialog .g-reminder-chips .g-button{min-height:44px;padding:8px 12px}}

/* Board artwork and labels are controls, not selectable page text. */
.grimoire-page .g-board{-webkit-user-select:none;user-select:none}

/* Offline nomination records the players who raised their hands, not game rulings. */
.g-dock .g-nomination-open{width:100%;min-height:36px;margin:0 0 6px}
.g-dock .g-nomination-open[hidden]{display:none!important}
#gDialog.g-nomination-dialog{width:min(640px,calc(var(--g-viewport-width,100vw) - 24px))}
.g-nomination-form{display:grid;gap:12px}.g-nomination-form>label{display:grid;gap:6px}.g-nomination-form select,.g-nomination-form input[type=number]{width:100%;min-height:42px}.g-nomination-voters{border:1px solid #ffffff26;border-radius:10px;padding:10px;display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:6px}.g-nomination-voters legend{padding:0 5px;color:#dcc997;font-size:13px}.g-nomination-voter{display:flex;align-items:center;gap:9px;min-height:42px;padding:6px 8px;background:#ffffff0a;border-radius:7px;font-size:13px}.g-nomination-voter input{width:19px;height:19px;flex:none;accent-color:#d3bc7c}.g-nomination-voter span{overflow-wrap:anywhere}.g-nomination-count{color:#e5d39b;font-size:13px}.g-nomination-form .g-hint{margin:0;line-height:1.6}.g-nomination-form #gNominationStatus:empty{display:none}.g-nomination-form #gNominationSave{min-height:44px}
@media(max-width:480px){.g-nomination-voters{grid-template-columns:repeat(2,minmax(0,1fr))}.g-nomination-voter{font-size:12px}}
#gDialog.g-nomination-record-dialog{width:min(640px,calc(var(--g-viewport-width,100vw) - 24px))}
.g-nomination-record-dialog #gNominationRecordsAdd{min-height:44px;margin:0 0 14px}.g-nomination-record-group{margin:0 0 16px}.g-nomination-record-group h3{font-size:13px;color:#d9c493;border-bottom:1px solid #d9c49340;padding-bottom:8px}.g-nomination-record{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px 12px;padding:12px;margin:8px 0;border:1px solid #ffffff25;border-radius:8px;background:#ffffff09}.g-nomination-record-title,.g-nomination-record-result{margin:0;line-height:1.6;overflow-wrap:anywhere}.g-nomination-record-title{font-weight:600}.g-nomination-record-votes{color:#f1d795;font-weight:650;white-space:nowrap}.g-nomination-record-result{grid-column:1/-1;color:#bdc6c3;font-size:13px}

/* Local vote overlay: the board remains visible, while each seat is a vote toggle. */
.g-vote-round{position:absolute;left:0;top:0;z-index:12;pointer-events:none;overflow:visible}
.g-vote-round-pointers{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none}
.g-vote-pointer-fixed,.g-vote-pointer-moving{stroke-width:4;stroke-linecap:round;filter:drop-shadow(0 2px 2px #000)}
.g-vote-pointer-fixed{stroke:#61b7ed}.g-vote-pointer-moving{stroke:#f1bc58}.g-vote-pointer-fixed-head{fill:#61b7ed;stroke:#153b55;stroke-width:2}.g-vote-pointer-moving-head{fill:#f1bc58;stroke:#5a3212;stroke-width:2}
.g-vote-seat.g-button{position:absolute;transform:translate(-50%,-50%);width:var(--vote-seat-size);height:var(--vote-seat-size);min-width:var(--vote-seat-size);min-height:var(--vote-seat-size);padding:0;border:2px solid #e5d2a1;border-radius:50%;background:#201731dd;color:#e1c9ff;font:bold clamp(30px,6vw,62px)/1 system-ui,sans-serif;text-shadow:0 2px 4px #000;box-shadow:0 3px 9px #0009;pointer-events:auto;touch-action:manipulation}.g-vote-seat.g-button.is-voted{background:#4a181bdc;color:#fff2cf;border-color:#f2c674;font-size:clamp(25px,5vw,48px)}
.g-vote-round-controls{position:absolute;transform:translate(-50%,-50%);width:min(240px,46vw);box-sizing:border-box;padding:9px;border:1px solid #d6be7c88;border-radius:10px;background:#101217ed;color:#f5ead0;box-shadow:0 4px 16px #000b;text-align:center;pointer-events:auto;font-size:12px}.g-vote-round-title{display:block;line-height:1.4;overflow-wrap:anywhere}.g-vote-round-status{margin:5px 0;color:#e8ce8c;line-height:1.3}.g-vote-round-count{display:block;margin:3px 0;font-weight:700}.g-vote-round-controls label{display:inline-flex;align-items:center;gap:4px;margin:3px;font-size:11px}.g-vote-round-controls input,.g-vote-round-controls select{width:auto;max-width:78px;min-height:32px;padding:3px 5px;font-size:14px}.g-vote-round-actions{display:flex;flex-wrap:wrap;justify-content:center;gap:5px;margin-top:6px}.g-vote-round-actions .g-button{min-height:36px;padding:5px 8px;font-size:12px}
@media(max-width:700px){.g-vote-round-controls{width:min(180px,48vw);padding:6px;font-size:11px}.g-vote-round-actions .g-button{min-height:40px;padding:4px 6px}.g-vote-round-controls input,.g-vote-round-controls select{max-width:62px;min-height:32px}}
/* 投票状态叠在角色牌上，保留辨认角色的余地。 */
.g-vote-seat.g-button{background:radial-gradient(circle,#1a142bd9 0%,#161423a8 55%,#0b0d14b8 100%);border-color:#d1c1a5b8;color:#d7c3ff;text-shadow:0 2px 3px #000,0 0 10px #563a90;box-shadow:inset 0 0 0 2px #ffffff16,0 3px 9px #0009}
.g-vote-seat.g-button.is-voted{background:radial-gradient(circle,#731d1de6,#3a1015c9 70%);border-color:#efd49a;color:#fff2cf}
.g-vote-seat.g-button.is-spent{background:#17191cde;border-color:#717781;color:#82848c}
.g-vote-seat.is-dead::after{content:attr(data-vote-status);position:absolute;left:50%;bottom:-9px;transform:translateX(-50%);white-space:nowrap;padding:2px 5px;border-radius:8px;background:#251f2e;color:#f1ddb4;font:600 10px/1.25 system-ui,sans-serif;text-shadow:none;box-shadow:0 1px 4px #0009}
.g-vote-seat.is-spent::after{background:#34373b;color:#e0e0e0}
.g-vote-round-controls{border-color:#d5bb8380;background:linear-gradient(160deg,#181c21f5,#0b0d11f5);box-shadow:0 8px 24px #000b,inset 0 1px #ffffff12}
.g-vote-round-title{color:#f3ddad}.g-vote-round-count{font-size:14px;color:#fff4d3}.g-vote-round-controls label.g-vote-execution{display:flex;justify-content:center;gap:6px;margin:4px 0;color:#e4d4af;cursor:pointer}.g-vote-round-controls .g-vote-execution input{width:16px;height:16px;min-height:0;margin:0;accent-color:#c5a663}
.g-seat-dialog .g-seat-nominate{width:100%;min-height:44px;margin:0 0 8px;border-color:#b79c6399;color:#f1dba7}
.g-quick-nomination{position:fixed;z-index:90;left:50%;top:max(12px,env(safe-area-inset-top));transform:translateX(-50%);display:flex;align-items:center;gap:12px;max-width:min(90vw,560px);padding:9px 12px;border:1px solid #c4a86c99;border-radius:12px;background:#12161cf2;color:#f6e7c5;box-shadow:0 5px 24px #000a;font-size:14px;line-height:1.4}.g-quick-nomination .g-button{flex:none;min-height:40px;padding:5px 12px}
.g-seat-name.g-nomination-pick{border-color:#e5bd68;box-shadow:0 0 0 2px #d4a64c80,0 2px 8px #000b}.g-seat-name.g-nomination-actor{border-color:#67bfe8;box-shadow:0 0 0 2px #43a6d080,0 2px 8px #000b}
@media(max-width:700px){.g-quick-nomination{top:max(8px,env(safe-area-inset-top));width:max-content;font-size:12px;gap:8px;padding:7px 9px}}
.g-nominee-layer{position:absolute;left:0;top:0;z-index:12;pointer-events:none;overflow:visible}
.g-nominee-hand.g-button{position:absolute;transform:translate(-50%,-50%)!important;display:grid;place-items:center;width:var(--nominee-size,60px);height:var(--nominee-size,60px);min-width:44px;min-height:44px;padding:0;border:2px solid #e4c991;border-radius:50%;background:#26151cdb;color:#fff;font-size:clamp(27px,calc(var(--nominee-size,60px)*.66),52px);line-height:1;text-shadow:0 2px 4px #000;box-shadow:0 2px 8px #000a;pointer-events:auto;touch-action:manipulation}
.g-nominee-hand.g-button:hover,.g-nominee-hand.g-button:focus-visible{background:#763023ec;border-color:#fff0bb;outline:2px solid #f8e3ab;outline-offset:2px}
.g-app.g-selecting-nominee .g-seat :is(.g-seat-token,.g-life-toggle,.g-vote-toggle,.g-reminders){pointer-events:none!important}
.g-quick-nomination{pointer-events:none}.g-quick-nomination .g-button{pointer-events:auto}
.g-reminder-token.g-button .g-reminder-execution-skull{position:absolute;inset:3% 0 26%;display:grid;place-items:center;color:#f5e9d0;font:700 calc(var(--reminder-size,48px)*.58)/1 'Segoe UI Symbol',sans-serif;text-shadow:0 2px 3px #0d0610;pointer-events:none}
/* 投票时用公开的圆牌背面覆盖角色；死亡票状态保留原有正反面。 */
.g-vote-seat.g-button,.g-vote-seat.g-button.is-voted{box-sizing:border-box;border:0;background:transparent url('../../theme/life1.png') center/100% 100% no-repeat;color:#dbcaff;text-shadow:0 2px 2px #000,0 0 3px #140924;box-shadow:0 3px 9px #0008}
.g-vote-seat.g-button.is-dead:not(.is-spent){background-image:url('../../theme/life1.png'),url('../../theme/death1.png');background-size:50% 50%,100% 100%}
.g-vote-seat.g-button.is-spent{background:transparent url('../../theme/death1.png') center/100% 100% no-repeat;color:#b1a9b8}
.g-vote-seat.g-button.is-voted{color:#fff;font-size:clamp(25px,5vw,48px)}
.g-vote-pointer-fixed,.g-vote-pointer-moving,.g-vote-pointer-fixed-head,.g-vote-pointer-moving-head{visibility:hidden}
.g-vote-pointer-art{overflow:hidden;pointer-events:none;filter:drop-shadow(0 2px 2px #000a)}
.g-execution-seat{position:absolute;inset:0;display:grid;place-items:center;border-radius:50%;background:transparent url('../../theme/token1.png') center/100% 100% no-repeat;pointer-events:none}
.g-execution-seat svg{width:58%;height:58%;overflow:visible;filter:drop-shadow(0 2px 3px #000)}
.g-execution-seat path{fill:#fff;stroke:#1c1816;stroke-width:2.5;stroke-linejoin:round}.g-execution-seat circle{fill:#514b43;stroke:#181512;stroke-width:1.5}
.g-vote-transition-shield{position:absolute;inset:0;pointer-events:auto;touch-action:manipulation}
.g-vote-round.is-flipping .g-vote-seat{pointer-events:none}
.g-vote-seat.g-button,.g-vote-seat.g-button.is-voted,.g-vote-seat.g-button.is-spent{transform:translate(-50%,-50%)!important;background:none;border:0;box-shadow:none}
.g-vote-seat-face{position:absolute;inset:0;display:grid;place-items:center;border-radius:50%;background:transparent url('../../theme/life1.png') center/100% 100% no-repeat;box-shadow:0 3px 9px #0008;pointer-events:none;backface-visibility:hidden}
.g-vote-seat.is-dead:not(.is-spent) .g-vote-seat-face{background-image:url('../../theme/life1.png'),url('../../theme/death1.png');background-size:50% 50%,100% 100%}
.g-vote-seat.is-spent .g-vote-seat-face{background-image:url('../../theme/death1.png')}
.g-nomination-warning:not(:empty){margin:0;padding:9px 11px;border:1px solid #b98948;border-radius:8px;background:#382819;color:#f4d59a;font-size:13px;line-height:1.5}
.g-nomination-warning:empty{display:none}.g-nominee-hand.is-nominated::after{content:'已被提名';position:absolute;left:50%;bottom:-8px;transform:translateX(-50%);white-space:nowrap;padding:2px 5px;border-radius:8px;background:#382819;color:#f4d59a;font:600 10px/1.2 system-ui,sans-serif}
.g-vote-seat-symbol{display:block;line-height:1;transform-origin:50% 80%;pointer-events:none}
.g-vote-seat-symbol{position:relative;width:52%;height:52%;filter:drop-shadow(0 2px 2px #120d09aa)}
.g-vote-symbol-label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.g-vote-seat-symbol svg{display:block;width:100%;height:100%;overflow:visible}
.g-vote-symbol-cross{fill:none;stroke:#806a59;stroke-width:5;stroke-linecap:round;opacity:.9}
.g-vote-symbol-hand{fill:#d9c08b;stroke:#5d4933;stroke-width:2;stroke-linejoin:round;stroke-linecap:round}
.g-vote-seat.is-spent .g-vote-symbol-cross{stroke:#aaa6a0}
.g-vote-pointer-art image{filter:saturate(.68) brightness(.86)}
.g-vote-round-controls{border-color:#c9b17a88;background:linear-gradient(155deg,#22272bed,#0c1014f5);box-shadow:0 8px 24px #000b,inset 0 1px #f3dfb51c;backdrop-filter:blur(12px)}
.g-vote-round-title{font-size:13px;letter-spacing:.03em}.g-vote-round-status{color:#baae91}.g-vote-round-count{color:#ead49f}
.g-vote-round-controls input,.g-vote-round-controls select{border:1px solid #b9a67a55;border-radius:5px;background:#10161b;color:#ede5d2}
.g-vote-round-actions .g-button{border-color:#b7a27650;background:#222b30;color:#e9e2d0}.g-vote-round-actions .g-button.primary{background:#d4bd87;color:#211c15}
.g-nominee-hand.g-button,.g-nominee-hand.g-button:hover{border:0;background:transparent;box-shadow:none;outline-offset:2px}
.g-nominee-hand svg{width:86%;height:86%;overflow:visible;transform:rotate(calc(var(--nominee-angle,0rad) + 90deg));filter:drop-shadow(0 2px 2px #000b);pointer-events:none}
.g-nominee-hand-shape{fill:#faf8ee;stroke:#22201b;stroke-width:3.4;stroke-linejoin:round;stroke-linecap:round}
.g-nominee-hand-detail{fill:none;stroke:#22201b;stroke-width:3;stroke-linecap:round;stroke-linejoin:round}

/* On phones the round table keeps just the shortcuts used during play. */
.grimoire-page .g-phone-ui :is(#gSummary, #gSummaryOpen, #gNotes, #gHistory,
  #gNominationRecords, .g-token-order, #gMenuNightOrder) {
  display: none;
}
.grimoire-page .g-phone-ui .g-side-tools.g-left-tools {
  top: max(8px, env(safe-area-inset-top));
}
.grimoire-page .g-phone-ui #gFabled {
  order: -1;
}
.grimoire-page .g-phone-ui #gTimerCenter {
  position: fixed;
  left: 50% !important;
  top: max(52px, calc(env(safe-area-inset-top) + 48px)) !important;
}

.g-phone-game-tools, .g-phone-ticket, .g-phone-nomination { display: none; }

.g-phone-ui[data-player-view="false"] .g-phone-game-tools {
  position: absolute;
  z-index: 9;
  top: max(4px, env(safe-area-inset-top));
  left: calc(44px + env(safe-area-inset-left));
  right: calc(98px + env(safe-area-inset-right));
  display: flex;
  justify-content: center;
  gap: 4px;
  pointer-events: none;
}
.g-phone-game-tools .g-button {
  min-height: 44px;
  padding: 4px 8px;
  font-size: 12px;
  white-space: nowrap;
  pointer-events: auto;
}
.g-phone-ui.g-selecting-nominee .g-phone-game-tools,
.g-phone-ui:has(#gVoteRound) .g-phone-game-tools { display: none; }

.g-phone-ui .g-seat-token :is(.g-phone-ticket, .g-phone-nomination) {
  position: absolute;
  z-index: 3;
  left: 50%;
  transform: translateX(-50%);
  display: block;
  padding: 2px 4px;
  border: 1px solid #ac9369;
  border-radius: 5px;
  background: #242322;
  color: #fff0c9;
  font: 600 10px/1.15 system-ui, sans-serif;
  white-space: nowrap;
  pointer-events: none;
}
.g-phone-ui .g-seat-token .g-phone-ticket { bottom: 2px; }
.g-phone-ui .g-phone-ticket[data-available="true"] { background: #204a44; color: #fff; }
.g-phone-ui .g-phone-ticket[data-available="false"] { background: #38383b; color: #eee; }
.g-phone-ui .g-seat-token .g-phone-nomination { top: 1px; }
.g-phone-ui .g-phone-nomination[data-received="true"] { background: #57353a; }
