/* ===========================================================
   GAMIAUX ONE — Phase 1 shell chrome (rev. 2)
   Top bar, menu bar, status bar, the shell-owned left rail
   (.g1-rail), the real persistent party column (.g1-party-rail,
   sized by --g1-rail-w — the grid genuinely reserves it, this is
   not a fixed-position overlay), and the desktop layer (palette,
   toasts, context menus). Additive only: every selector here is
   scoped under body.gm-shell-active (set by gamiaux-shell.js once
   it has moved the real .app into the shell wrapper) so nothing
   changes for a session that, for any reason, never boots the
   shell script.

   Reuses the app's own brand tokens (--surface/--border/--text/
   --muted/--gold/--gm-grad/...) defined in index.html's :root —
   no new palette, no prototype cyan/purple.

   Party rail, round 2: earlier rounds relocated #bpRight/#bpPartyRoster
   *wholesale* and fought their old fixed-width/absolute-position/hidden
   styles with !important overrides in party-navigation.css. Per the
   coordinator's "this is a rebuild, not more overrides" direction, that's
   gone. gamiaux-shell.js now pulls only the specific real, load-bearing
   sub-elements (roster count/list, the voice/video/leave-voice buttons,
   the real chat panel) out of their old wrapper chrome entirely, and
   they're styled fresh below, scoped under .g1-party-rail, with no
   !important needed — there's no competing old rule left to beat, since
   these elements are no longer inside the DOM subtree those old rules
   target. party-navigation.css's own rules go back to governing only
   what's left in the old wrappers (now parked, unrendered, in a holding
   div) — see that file's own comment block for what still applies there
   and why.
   =========================================================== */

body.gm-shell-active{overflow:hidden}
#gmShellRoot{display:flex;flex-direction:column;height:100%;min-height:0}

/* the site's own nav rail is fully replaced by .g1-rail below, on every
   route — not just Studio (where studio.css already forces it away via
   body.gm-studio-workspace .app.gm-left-ribbon>.bp-nav{display:none}).
   Leaving .bp-nav in the layout on the other 12 routes would double the
   chrome the same way the Studio rack header did. */
body.gm-shell-active .bp-nav{display:none!important}
body.gm-shell-active .app.gm-left-ribbon{
  height:auto!important;min-height:0;grid-template-columns:minmax(0,1fr)!important;
}

/* Party rail: click-only, closed by default on every route and every
   fresh profile (0-width 3rd track, no reserved column — the real app
   surface underneath gets the full width) — opens only via the top-bar
   Party button, ⌘\, or the two auto-open exceptions gamiaux-shell.js's
   initAutoOpenHooks() wires up (Home's own Quick-party create/join, or
   a `?room=` deep link). body.g1-party-open is the single source of
   truth; the grid-template-columns transition is what
   scheduleResizeAfterTransition()/initRailResizeBridge() in the JS wait
   on before firing a resize pass for Watch's cast grid, Studio's
   Program monitor and the Cut editor to refit to the new host width. */
#gmShellContentRow{
  flex:1 1 auto;min-height:0;display:grid;
  grid-template-columns:78px minmax(0,1fr) 0px;
  grid-template-rows:minmax(0,1fr);
  transition:grid-template-columns .22s ease;
}
body.g1-party-open #gmShellContentRow{
  grid-template-columns:78px minmax(0,1fr) var(--g1-rail-w,340px);
}
#gmShellContentRow > .app.gm-left-ribbon{grid-column:2;min-width:0;min-height:0;overflow:hidden}

/* ---------- Studio/Console own the far-left edge (2026-10-09) ----------
   Dennis: "the tabs in the studio replaces the main tab when in the
   studio" / "there will need to be a back button to bring up the main
   icon tabs of the platform when exiting the studio." .bp-nav is already
   gone everywhere the shell is active (line 41 above); this is the
   SHELL'S OWN .g1-rail, still mounted next to it. While Studio (or its
   Content sub-area, which is Studio itself with the Cut tab selected -
   see go()'s "cut" handling, which routes through bpNavTo('studio') and
   so sets body.gm-studio-workspace exactly like a direct Studio visit)
   or Console is active, that rail collapses to 0 and Studio's own vertical
   icon rail (.gs-studio-ribbon, inside #gmStudio/#gsControlRoom - its own
   "← Back" now restored, see studio.css) becomes the far-left edge
   control instead - same width/feel as .g1-rail, not a second nav beside
   it. body.gm-studio-workspace is studio.js's own authoritative flag
   (toggled by window.gmStudioOnNavigate, called from inside the real
   bpNavTo() for every navigation - menu, ⌘K, deep link, Back button
   alike - see index.html), so this reacts correctly no matter how Studio
   was entered or left. Console bypasses bpNavTo entirely (view:null, its
   own #vConsole) so it gets its own body class, toggled directly by
   enterConsoleControlRoom()/leaveConsoleControlRoom() below - every path
   in and out of Console already funnels through those two functions.
   Selectors are duplicated (not grouped with a shared ancestor) and each
   combined with .g1-party-open so they outrank the party-rail breakpoint
   rules further down this file at equal specificity regardless of source
   order (that are themselves scoped to body.g1-party-open #gmShellContentRow),
   rather than relying on placement in the cascade. ---- */
body.gm-studio-workspace #gmShellContentRow,
body.gm-console-workspace #gmShellContentRow{grid-template-columns:0px minmax(0,1fr) 0px!important}
body.gm-studio-workspace.g1-party-open #gmShellContentRow,
body.gm-console-workspace.g1-party-open #gmShellContentRow{grid-template-columns:0px minmax(0,1fr) var(--g1-rail-w,340px)!important}
body.gm-studio-workspace .g1-rail,
body.gm-console-workspace .g1-rail{display:none!important}

/* ---------- shell-owned left rail ---------- */
.g1-rail{grid-column:1;background:#080e1a;border-right:1px solid var(--border);
  padding:8px 5px;display:flex;flex-direction:column;gap:2px;overflow-y:auto;overflow-x:hidden;
  scrollbar-width:none;min-height:0}
.g1-rail::-webkit-scrollbar{display:none}
.g1-rail-item{background:none;border:1px solid transparent;border-radius:10px;color:var(--muted);
  padding:8px 2px;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:4px;
  position:relative;transition:.14s;font-family:inherit}
.g1-rail-item:hover{color:var(--text);background:var(--surface2)}
.g1-rail-item.active{color:var(--gold);background:var(--gold-dim);border-color:rgba(139,58,245,.4)}
.g1-rail-ico svg{width:18px;height:18px;stroke:currentColor;fill:none;stroke-width:1.7}
.g1-rail-lbl{font:600 8.3px/1.15 ui-sans-serif,sans-serif;text-align:center;letter-spacing:.01em}
.g1-rail-hint{display:none}

/* ---------- real persistent party column (rebuild) ---------- */
.g1-party-rail{grid-column:3;min-width:0;overflow:hidden;display:flex;flex-direction:column;
  background:var(--surface);border-left:1px solid var(--border);position:relative}
/* The native `hidden` attribute's UA-stylesheet display:none is beaten by
   any author rule that also sets `display` on the same element at equal
   specificity — every section below sets its own `display` for its
   normal (non-hidden) state, so this blanket override keeps `[hidden]`
   authoritative regardless of which section it's on. */
.g1-party-rail [hidden]{display:none!important}

/* -- header: room name/code + member count -- */
.g1p-hdr{flex:0 0 auto;min-height:44px;padding:10px 13px;border-bottom:1px solid var(--border);
  display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.g1p-title{font-weight:700;font-size:13.5px;color:var(--text);flex:0 1 auto;min-width:0;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.g1p-code{font-family:ui-monospace,monospace;font-size:11px;letter-spacing:.08em;
  background:var(--bg);border:1px solid var(--border);border-radius:999px;padding:3px 9px;
  color:var(--gold);cursor:pointer;flex:0 0 auto}
.g1p-code:hover{border-color:var(--gold)}
.g1p-count-mount{margin-left:auto;flex:0 0 auto;font-family:ui-monospace,monospace;font-size:10.5px;color:var(--muted)}
.g1p-count-mount .bp-party-roster-count{color:var(--muted)!important;font:inherit!important;background:none!important}
.g1p-hdr-act{width:26px;height:26px}
.g1p-hdr-act svg{width:13px;height:13px}

/* -- Watch: a real header line with title/room code (left) and Cast
   Manager · Launch · Party (right) — the workspace has no header row of
   its own in the real markup at all, and Cast Manager/Launch/Party all
   need to stay reachable with the party rail closed by default.
   Round 2 fix (canary defect, live screenshot): this used to be
   position:absolute, top-right — on a real cast grid that sat on top of
   Stream 4's own tile and clipped its fullscreen button. It's a normal
   in-flow flex row now, inserted as the first child of .wp-streams (see
   gamiaux-shell.js's addWatchToolbar() for exactly why that placement —
   short version: wpMeasureStage() already reserves space for every
   other visible in-flow child of .wp-streams the same way it does for
   .wp-topbar, so the cast grid genuinely starts below this, not just
   visually — no absolute positioning, no z-index stacking to get wrong
   against a real tile's own controls. */
.g1-watch-toolbar{flex:0 0 44px;height:44px;box-sizing:border-box;width:100%;
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:0 14px;background:var(--surface);border-bottom:1px solid var(--border)}
.g1wt-left{display:flex;align-items:center;gap:9px;min-width:0}
.g1wt-title{font-weight:700;font-size:13px;color:var(--text);white-space:nowrap;
  overflow:hidden;text-overflow:ellipsis}
.g1wt-code{font-family:ui-monospace,monospace;font-size:11px;letter-spacing:.08em;
  background:var(--bg);border:1px solid var(--border);border-radius:999px;padding:3px 9px;color:var(--gold)}
.g1wt-right{display:flex;align-items:center;gap:8px;flex:0 0 auto}
.g1-watch-castmgr{position:relative;display:inline-flex;align-items:center;gap:6px;height:30px;padding:0 12px;
  border-radius:8px;border:1px solid var(--border-light);background:var(--surface2);
  color:var(--text);font:600 11.5px ui-sans-serif,sans-serif;cursor:pointer;white-space:nowrap}
.g1-watch-castmgr:hover{border-color:var(--gold)}
.g1-watch-castmgr.on{color:var(--gold);border-color:var(--gold);background:var(--gold-dim)}
.g1-watch-castmgr svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:1.8}
/* The Party mirror reuses the top bar's own badge/pulse styling
   (.gm-shell-party-badge/.gm-shell-party-pulse), just repositioned to
   this button's own corner instead of the icon-only top-bar button's. */
.g1-watch-party-mirror .gm-shell-party-badge{right:-3px;bottom:-3px}
.g1-watch-party-mirror .gm-shell-party-pulse{top:-3px;right:-3px}

/* -- Stream Chat dock: a cast tile's "Chat" button opens the real
   #gmCastChat panel (stream-chat.js/stream-chat.css — untouched, every
   id/handler inside it stays exactly what it was). It ships as a
   position:fixed top-left overlay that covers Cast 1 — Dennis: "flowing
   to the left and sitting there" instead. .g1-watch-row is a new flex
   row (built by gamiaux-shell.js's initStreamChatDock(), which moves
   the real #gmCastChat + #gmCastChatBar nodes into it — nothing here is
   rebuilt) holding the dock, then the real .wp-layout/cast grid, filling
   whatever height is left below the Watch header. -- */
.g1-watch-row{flex:1 1 auto;min-height:0;display:flex;flex-direction:row;overflow:hidden}
.g1-watch-row>.wp-layout{flex:1 1 auto;min-width:0}
/* stream-chat.css sets #gmCastChat{position:fixed;left:...;top:...;
   width:340px;z-index:110;...} — loaded AFTER this file's own <link> in
   index.html, so same specificity (#gmCastChat, one ID either way) means
   cascade ORDER decides and theirs would win; !important is what
   actually wins here, same as every other cross-file override in this
   file. The display:none/flex toggle itself (base rule + the real
   .app.gm-stream-chat-open:has(#vWatch.active) rule) is left completely
   alone — only position/size are overridden, so opening/closing still
   goes through the app's own real logic untouched. */
#gmCastChat{
  position:relative!important;left:auto!important;top:auto!important;bottom:auto!important;
  inset:auto!important;z-index:auto!important;
  flex:0 0 var(--g1-streamchat-w,360px)!important;width:var(--g1-streamchat-w,360px)!important;
  min-width:300px!important;max-width:480px!important;height:100%!important;
  border-radius:0!important;border-right:1px solid var(--border);border-left:0;
}
/* Deliberately NOT transitioned: a live width transition would make an
   active drag lag behind the cursor (each mousemove's new width chasing
   the old one instead of tracking 1:1) — the party rail's own dock gets
   a transition because it only ever snaps between two fixed states
   (open/closed), never free-dragged live like this one. */
.g1-sc-resize{position:absolute;top:0;right:-3px;bottom:0;width:6px;cursor:col-resize;z-index:5}
.g1-sc-resize:hover,.g1-sc-resize.on{background:rgba(139,58,245,.28)}
/* The real per-cast tab strip, re-homed under the dock's own header —
   only shown once there's actually more than one live cast to flip
   between (gamiaux-shell.js toggles .g1-multi-cast from a real child
   count on the same real node); with 0-1 casts the panel's own header +
   #gmCastChatTitle subheader already say which cast this is. */
#gmCastChat #gmCastChatBar:not(.g1-multi-cast){display:none!important}
/* Launch (hyper full-screen): the dock is shell-adjacent chrome, not
   part of the fullscreen cast wall — same treatment as the shell's own
   rail/topbar via body.g1-rocket-active elsewhere in this file. display:
   none removes it from the flex row outright, so .wp-layout reclaims
   the width with no separate override needed; exiting restores it
   automatically since nothing here touched the real open/close state. */
body.g1-rocket-active #gmCastChat,body.g1-rocket-active .g1-sc-resize{display:none!important}

/* -- actions row: icon buttons with real tooltips -- */
.g1p-actions{flex:0 0 auto;display:flex;flex-wrap:wrap;gap:5px;padding:8px 11px;border-bottom:1px solid var(--border)}
.g1p-act{width:30px;height:30px;flex:0 0 30px;border-radius:8px;border:1px solid var(--border);background:var(--surface2);
  color:var(--muted);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;padding:0}
.g1p-act:hover{color:var(--text);border-color:var(--border-light)}
.g1p-act svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:1.8}
.g1p-act.dgr{color:#ff9db0;border-color:#7a2334}
.g1p-act.dgr:hover{background:rgba(255,84,112,.14)}
.g1p-act-mount:empty{display:none}
.g1p-act-mount #bpDockEndVoiceBtn{width:30px;height:30px;padding:0;display:inline-flex!important;
  align-items:center;justify-content:center;border-radius:8px;border:1px solid #7a2334;
  background:transparent;color:#ff9db0;font-size:0}
.g1p-act-mount #bpDockEndVoiceBtn::before{content:"\23FB";font-size:13px}
.g1p-act-mount #bpDockEndVoiceBtn:hover{background:rgba(255,84,112,.14)}

/* -- members list: vertical, own scroll, avatar+name+presence+mic/cam -- */
.g1p-members{flex:0 1 auto;min-height:0;max-height:38%;overflow-y:auto;border-bottom:1px solid var(--border)}
.g1p-members #bpPartyRosterList{
  display:flex!important;flex-direction:column!important;gap:2px!important;
  padding:6px!important;grid-template-columns:none!important;
}
.g1p-members .bp-party-roster-member{
  width:100%!important;aspect-ratio:auto!important;flex-direction:row!important;
  justify-content:flex-start!important;align-items:center!important;gap:9px!important;
  padding:6px 7px!important;border-radius:8px!important;border:1px solid transparent!important;
  background:transparent!important;box-shadow:none!important;
}
.g1p-members .bp-party-roster-member:hover{background:var(--surface2)!important;border-color:var(--border)!important}
.g1p-members .bp-party-roster-avatar{width:26px!important;height:26px!important;flex:0 0 26px!important;font-size:12px!important}
.g1p-members .bp-party-roster-copy{align-items:flex-start!important;flex:1!important;min-width:0!important}
.g1p-members .bp-party-roster-name{font-size:12px!important}
.g1p-members .bp-party-roster-status{display:none!important} /* presence is the dot below, not this text row */
.g1p-members .gm-contact-wave{width:20px!important;height:16px!important;flex:0 0 20px!important}
.g1p-members-empty{padding:14px 13px;font-size:11.5px;color:var(--muted)}

/* -- call bar: appears only while a real button inside is visible
   (voice/video toggle + leave-voice — the same dual-purpose buttons the
   app's own gmDeskPartyBtnsUpdate() already drives; unwrapped here, not
   duplicated). Equal-width buttons, wraps under the rail's min width. -- */
.g1p-callbar{flex:0 0 auto;display:flex;flex-wrap:wrap;gap:6px;padding:8px 11px;border-bottom:1px solid var(--border)}
.g1p-callbar #bpPartyVoiceBtn,
.g1p-callbar #bpPartyVideoBtn,
.g1p-callbar #bpPartyVoiceLeaveBtn{
  flex:1 1 30%!important;min-width:64px!important;width:auto!important;height:34px!important;
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  border-radius:8px!important;border:1px solid var(--border-light)!important;
  background:var(--surface2)!important;color:var(--text)!important;padding:0 6px!important;
  font:600 10px/1 ui-sans-serif,sans-serif!important;white-space:nowrap!important;
}
.g1p-callbar #bpPartyVoiceBtn svg,
.g1p-callbar #bpPartyVideoBtn svg{width:15px!important;height:15px!important}
.g1p-callbar #bpPartyVoiceBtn.active,
.g1p-callbar #bpPartyVideoBtn.active{border-color:var(--gold)!important;color:var(--gold)!important}
.g1p-callbar #bpPartyVoiceBtn.muted{border-color:#EF4444!important;color:#ff9db0!important}
.g1p-callbar #bpPartyVoiceLeaveBtn{border-color:#7a2334!important;color:#ff9db0!important;background:transparent!important}
.g1p-callbar #bpPartyVoiceLeaveBtn:hover{background:rgba(255,84,112,.14)!important}

/* -- out-of-room: Create/Join panel -- */
.g1p-noroom{padding:14px 13px;display:flex;flex-direction:column;gap:9px;overflow-y:auto}
.g1p-noroom p{margin:0;font-size:12px;color:var(--muted);line-height:1.5}
.fl-select{background:var(--bg);border:1px solid var(--border);color:var(--text);border-radius:8px;
  padding:8px 9px;font-size:12px;width:100%}
.g1-party-btn{width:100%;padding:10px;border-radius:8px;border:1px solid var(--border-light);
  background:var(--surface2);color:var(--text);font:600 12px ui-sans-serif,sans-serif;cursor:pointer}
.g1-party-btn:hover{border-color:var(--gold)}
.g1-party-btn.primary{background:var(--gm-grad);border-color:transparent;color:#fff}
.g1-party-join{display:flex;gap:6px}
.g1-party-join input{flex:1;min-width:0;background:var(--bg);border:1px solid var(--border);
  color:var(--text);border-radius:8px;padding:8px 9px;font-size:12px}
.g1-party-join .g1-party-btn{width:auto;padding:8px 14px;white-space:nowrap}

/* -- "no party" popover: the Party button's target while out of a party
   (the rail itself doesn't exist then — see gamiaux-shell.js's
   isPartyRailOpen()) — join by code, create with a visibility select,
   recent codes. Reuses .g1-party-btn/.g1-party-join/.fl-select verbatim
   for the same look as the rail's own (now dead-while-out-of-party)
   no-room panel used to have. -- */
.g1-pp{position:fixed;z-index:9800;width:280px;padding:12px;display:flex;flex-direction:column;gap:14px;
  background:var(--surface2);border:1px solid var(--border-light);border-radius:12px;
  box-shadow:0 22px 60px -18px #000;font-size:12px}
/* Same [hidden]-beaten-by-equal-specificity-display fix already needed
   for .g1-party-rail's own contents (see that selector's own comment) —
   every .display-setting rule below (.g1-pp itself, .g1-pp-sec) ties the
   UA [hidden]{display:none} rule's specificity and wins on source order
   (author beats UA) without this — covers the popover's own [hidden]
   plus #g1PpRecentSec's, toggled the same way. */
.g1-pp[hidden],.g1-pp [hidden]{display:none!important}
.g1-pp-sec{display:flex;flex-direction:column;gap:8px}
.g1-pp-lbl{font:700 10px/1 ui-sans-serif,sans-serif;letter-spacing:.06em;text-transform:uppercase;color:var(--muted)}
.g1-pp-recent-list{display:flex;flex-wrap:wrap;gap:6px}
.g1-pp-recent-chip{font-family:ui-monospace,monospace;font-size:11px;letter-spacing:.05em;
  background:var(--bg);border:1px solid var(--border);border-radius:999px;padding:5px 10px;
  color:var(--gold);cursor:pointer}
.g1-pp-recent-chip:hover{border-color:var(--gold)}

/* -- chat: takes all remaining height -- */
.g1p-chat{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.g1p-chat-hdr{flex:0 0 auto;padding:9px 9px 9px 13px;font:700 11px/1 ui-sans-serif,sans-serif;
  letter-spacing:.04em;text-transform:uppercase;color:var(--muted);border-bottom:1px solid var(--border);
  display:flex;align-items:center;justify-content:space-between;gap:8px}
.g1p-chat-collapse{width:24px;height:24px;flex:0 0 24px;border-radius:7px;border:1px solid transparent;
  background:none;color:var(--muted);display:inline-flex;align-items:center;justify-content:center;
  cursor:pointer;padding:0}
.g1p-chat-collapse svg{width:13px;height:13px;stroke:currentColor;fill:none;stroke-width:2;transition:transform .15s}
.g1p-chat-collapse:hover{color:var(--text);border-color:var(--border)}
.g1p-chat-collapse.open svg{transform:rotate(180deg)}
.g1p-chat-body{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;overflow:hidden}
/* Collapsed: keep the header (it's the "Show chat" doorway back), hide
   the feed+composer, and let the members list above grow into the
   freed height instead of leaving a dead gap. */
#g1PartyRail.g1-chat-collapsed .g1p-chat-body{display:none!important}
#g1PartyRail.g1-chat-collapsed .g1p-members{max-height:none!important;flex:1 1 auto!important}
.g1p-chat-body #pcTextPanel{flex:1!important;min-height:0!important;display:flex!important;flex-direction:column!important}
.g1p-chat-body #pcMsgs{flex:1!important;min-height:0!important;overflow-y:auto!important;
  padding:8px 11px!important;display:flex!important;flex-direction:column!important;gap:7px!important}
.g1p-chat-body #pcTyping{flex:0 0 auto!important}
.g1p-chat-body #pcUploadPreview:not(:empty){flex:0 0 auto!important}
.g1p-chat-body #pcInputBar{
  flex:0 0 auto!important;display:flex!important;align-items:center!important;gap:4px!important;
  padding:8px 9px!important;border-top:1px solid var(--border)!important;width:100%!important;
  box-sizing:border-box!important;position:relative!important;
}
/* Emoji/attach/GIF as a compact cluster (not three loosely-spaced
   full-size buttons) — this is what keeps #pcInput itself at or above
   200px of visible width at the 340px default rail width (measured
   live: 340 rail - chat-body padding/border - this cluster - the send
   button - gaps leaves ~216px for the input). */
.g1p-chat-body .pc-emoji-btn,.g1p-chat-body .pc-upload-btn,.g1p-chat-body .pc-gif-btn{
  flex:0 0 auto!important;width:22px!important;height:22px!important;min-width:0!important;
  padding:0!important;border:0!important;background:none!important;color:var(--muted)!important;
  font-size:12px!important;line-height:1!important;cursor:pointer!important;display:inline-flex!important;
  align-items:center!important;justify-content:center!important;margin:0!important;
}
.g1p-chat-body .pc-gif-btn{font:800 8px/1 ui-sans-serif,sans-serif!important;border:1px solid var(--border)!important;
  border-radius:4px!important;width:auto!important;padding:0 4px!important}
.g1p-chat-body .pc-emoji-btn:hover,.g1p-chat-body .pc-upload-btn:hover,.g1p-chat-body .pc-gif-btn:hover{color:var(--text)!important}
.g1p-chat-body #pcInput{
  flex:1 1 auto!important;min-width:0!important;width:auto!important;max-width:none!important;
  background:var(--bg)!important;border:1px solid var(--border)!important;color:var(--text)!important;
  border-radius:999px!important;padding:7px 12px!important;font-size:12.5px!important;box-sizing:border-box!important;
}
.g1p-chat-body #pcInput::placeholder{color:var(--muted)!important;opacity:1!important}
.g1p-chat-body #pcInput:focus{border-color:var(--gold)!important;outline:none!important}
.g1p-chat-body #pcInputBar>button:last-of-type{
  flex:0 0 auto!important;width:26px!important;height:26px!important;min-width:0!important;padding:0!important;
  border-radius:50%!important;border:0!important;background:var(--gm-grad)!important;color:#fff!important;
  display:inline-flex!important;align-items:center!important;justify-content:center!important;cursor:pointer!important;
}
.g1p-chat-body #pcMentionDrop:empty,.g1p-chat-body #pcEmojiPicker:empty{display:none!important}

/* System notices ("X joined the party.", "The clean program output has
   stopped.", ...) — collapsed by gamiaux-shell.js's chat-flooding filter
   (consecutive identical ones become one line + a ×N badge instead of
   N full-width lines). Styled muted/compact here so even a single one
   reads as background chatter, not a normal message. */
.g1p-chat-body .bp-msg.sys{padding:2px 0!important;opacity:.72}
.g1p-chat-body .bp-msg.sys .bp-msg-body{
  font-size:10.5px!important;color:var(--muted)!important;text-align:center!important;
  white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
.g1-sys-count{display:inline-block;margin-left:6px;font:700 9px/1 ui-monospace,monospace;
  color:var(--muted);background:var(--surface2);border:1px solid var(--border);border-radius:999px;
  padding:1px 6px}

/* -- resize handle: 260-380px, remembered. Kept fully inside the rail's
   own box (not straddling its left edge) so it can never register as
   content exceeding the rail's width. -- */
.g1p-resize{position:absolute;top:0;left:0;bottom:0;width:5px;cursor:col-resize;z-index:5}
.g1p-resize:hover,.g1p-resize.on{background:rgba(139,58,245,.28)}

/* ---------- top bar ---------- */
.gm-shell-topbar{
  flex:0 0 auto;display:flex;align-items:center;gap:12px;height:42px;padding:0 12px;
  background:var(--surface);border-bottom:1px solid var(--border);
  -webkit-app-region:drag;user-select:none;
}
.gm-shell-brand{display:flex;align-items:center;gap:8px;font-weight:800;letter-spacing:.4px;
  font-size:13px;color:var(--text);flex:0 0 auto}
.gm-shell-brand img{width:20px;height:20px;display:block}
.gm-shell-search{
  -webkit-app-region:no-drag;flex:1 1 320px;max-width:460px;display:flex;align-items:center;gap:8px;
  background:var(--bg);border:1px solid var(--border);border-radius:999px;padding:6px 12px;
  color:var(--muted);font-size:12.5px;cursor:text;
}
.gm-shell-search:hover{border-color:var(--border-light)}
.gm-shell-search svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2;flex:0 0 auto}
.gm-shell-search span.gm-shell-kbd{margin-left:auto;font:600 9.5px/1 ui-monospace,monospace;
  border:1px solid var(--border-light);border-radius:4px;padding:3px 6px;color:var(--muted)}
.gm-shell-topbar-right{-webkit-app-region:no-drag;margin-left:auto;display:flex;align-items:center;gap:8px}
.gm-shell-chip{display:inline-flex;align-items:center;gap:6px;font:700 9.5px/1 ui-sans-serif,sans-serif;
  letter-spacing:.05em;text-transform:uppercase;padding:5px 10px;border-radius:999px;
  border:1.5px solid var(--border-light);color:var(--muted);white-space:nowrap}
.gm-shell-chip .gm-shell-dot{width:5px;height:5px;border-radius:50%;background:currentColor}
.gm-shell-chip.ok{border-color:var(--win);color:var(--win)}
.gm-shell-chip.off{border-style:dashed;color:var(--muted)}
.gm-shell-rail-btn{-webkit-app-region:no-drag;position:relative;width:28px;height:28px;border-radius:8px;
  border:1px solid var(--border);background:var(--surface2);color:var(--muted);display:inline-flex;
  align-items:center;justify-content:center;cursor:pointer}
.gm-shell-rail-btn:hover{color:var(--text);border-color:var(--border-light)}
.gm-shell-rail-btn.on{color:var(--gold);border-color:var(--gold);background:var(--gold-dim)}
.gm-shell-rail-btn.in-call{border-color:var(--win);box-shadow:0 0 0 1px var(--win) inset}
.gm-shell-rail-btn svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:1.8}
/* Live badge: member count (bottom-right pill) + unread pulse (top-right
   dot) — the "Party" button's whole reason for existing while the rail
   itself is closed by default. */
.gm-shell-party-badge{position:absolute;right:-4px;bottom:-4px;min-width:14px;height:14px;padding:0 3px;
  border-radius:999px;background:var(--surface);border:1px solid var(--border-light);color:var(--text);
  font:700 8.5px/14px ui-monospace,monospace;text-align:center}
.gm-shell-party-pulse{position:absolute;top:-3px;right:-3px;width:9px;height:9px;border-radius:50%;
  background:#F97316;border:1.5px solid var(--surface);animation:gmPartyPulse 1.5s ease-in-out infinite}
@keyframes gmPartyPulse{0%,100%{transform:scale(1);opacity:1}50%{transform:scale(1.25);opacity:.65}}
.gm-shell-acct{-webkit-app-region:no-drag;display:flex;align-items:center;gap:7px;padding:3px 10px 3px 3px;
  border-radius:999px;border:1px solid var(--border);background:var(--surface2);cursor:pointer}
.gm-shell-acct-av{width:24px;height:24px;border-radius:50%;background:var(--gm-grad);display:flex;
  align-items:center;justify-content:center;font:700 10px/1 ui-sans-serif,sans-serif;color:#fff}
.gm-shell-acct-nm{font-size:11.5px;font-weight:600;color:var(--text);max-width:110px;overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}

/* ---------- menu bar ---------- */
.gm-shell-menubar{flex:0 0 auto;display:flex;align-items:center;gap:1px;height:26px;padding:0 8px;
  background:var(--surface);border-bottom:1px solid var(--border);user-select:none;overflow-x:auto;
  scrollbar-width:none}
.gm-shell-menubar::-webkit-scrollbar{display:none}
.gm-shell-menubar>button{flex:0 0 auto;background:none;border:0;color:var(--muted);font:600 11.5px ui-sans-serif,sans-serif;
  padding:3px 9px;border-radius:5px;cursor:pointer}
.gm-shell-menubar>button:hover,.gm-shell-menubar>button[aria-expanded="true"]{background:var(--surface2);color:var(--text)}
.gm-shell-menubar .gm-shell-menubar-right{margin-left:auto;display:flex;gap:10px;align-items:center;
  font:500 9px/1 ui-monospace,monospace;letter-spacing:.08em;color:var(--muted);padding-right:4px;white-space:nowrap}

.gm-shell-menu{position:fixed;z-index:9800;min-width:220px;padding:5px;background:var(--surface2);
  border:1px solid var(--border-light);border-radius:9px;box-shadow:0 22px 60px -18px #000;font-size:12px}
.gm-shell-menu button{display:flex;align-items:center;gap:10px;width:100%;background:none;border:0;
  color:var(--text);padding:6px 9px;border-radius:6px;cursor:pointer;text-align:left;font:inherit}
.gm-shell-menu button:hover:not(:disabled){background:var(--gold);color:#fff}
.gm-shell-menu button:disabled{color:var(--muted);opacity:.5;cursor:not-allowed}
.gm-shell-menu button .gm-shell-k{margin-left:auto;font:500 10px/1 ui-monospace,monospace;opacity:.75}
.gm-shell-menu button .gm-shell-ck{width:12px;font-size:11px;flex:0 0 auto}
.gm-shell-menu hr{border:0;border-top:1px solid var(--border);margin:4px 6px}
.gm-shell-menu .gm-shell-menu-lbl{padding:5px 9px 3px;font:700 8.5px/1 ui-monospace,monospace;
  letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}

/* ---------- status bar ---------- */
.gm-shell-statusbar{flex:0 0 auto;display:flex;align-items:center;gap:14px;padding:5px 13px;
  background:var(--bg);border-top:1px solid var(--border);font:500 10.5px/1 ui-monospace,monospace;
  color:var(--muted);flex-wrap:wrap}
.gm-shell-statusbar b{color:var(--text);font-weight:600}
.gm-shell-statusbar .gm-shell-status-dot{width:6px;height:6px;border-radius:50%;background:var(--win);
  display:inline-block;margin-right:5px;box-shadow:0 0 6px var(--win)}
.gm-shell-statusbar .gm-shell-status-dot.off{background:#EF4444;box-shadow:0 0 6px #EF4444}
.gm-shell-statusbar .gm-shell-status-right{margin-left:auto;display:flex;gap:14px;align-items:center}
#gmShellStatusMsg{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}

/* ---------- command palette ---------- */
.gm-shell-pal{position:fixed;inset:0;z-index:9900;background:rgba(4,6,11,.66);backdrop-filter:blur(4px);
  display:flex;align-items:flex-start;justify-content:center;padding-top:12vh}
.gm-shell-palbox{width:min(620px,92vw);background:var(--surface2);border:1px solid var(--border-light);
  border-radius:12px;box-shadow:0 40px 110px -30px #000;overflow:hidden}
.gm-shell-palbox input{width:100%;background:none;border:0;border-bottom:1px solid var(--border);
  color:var(--text);font:500 15px ui-sans-serif,sans-serif;padding:14px 16px;outline:none}
.gm-shell-palbox .gm-shell-pal-res{max-height:52vh;overflow-y:auto;padding:5px}
.gm-shell-palbox .gm-shell-pal-res button{display:flex;align-items:center;gap:11px;width:100%;
  background:none;border:0;color:var(--text);padding:9px 11px;border-radius:6px;cursor:pointer;
  text-align:left;font:inherit;font-size:13px}
.gm-shell-palbox .gm-shell-pal-res button[aria-selected="true"]{background:var(--gold);color:#fff}
.gm-shell-palbox .gm-shell-pal-res button .gm-shell-pal-grp{margin-left:auto;font:600 9px/1 ui-monospace,monospace;
  letter-spacing:.1em;text-transform:uppercase;opacity:.7;flex:0 0 auto}
.gm-shell-palbox .gm-shell-pal-none{padding:22px 16px;color:var(--muted);font-size:12.5px;text-align:center}

/* ---------- toasts ---------- */
.gm-shell-toasts{position:fixed;right:14px;bottom:14px;z-index:9850;display:flex;flex-direction:column;
  gap:6px;align-items:flex-end;pointer-events:none;max-width:min(360px,70vw)}
.gm-shell-toast{display:flex;align-items:flex-start;gap:8px;padding:8px 12px;border-radius:8px;
  background:var(--surface2);border:1px solid var(--border-light);box-shadow:0 14px 34px -14px #000;
  font-size:11.5px;color:var(--text);animation:gmShellToastIn .2s ease-out;pointer-events:auto}
.gm-shell-toast .gm-shell-toast-dot{width:6px;height:6px;border-radius:50%;background:var(--gold);
  margin-top:5px;flex:0 0 auto}
.gm-shell-toast.warn .gm-shell-toast-dot{background:#F97316}
.gm-shell-toast.out{animation:gmShellToastOut .28s ease-in forwards}
@keyframes gmShellToastIn{from{opacity:0;transform:translateY(8px) scale(.97)}to{opacity:1;transform:none}}
@keyframes gmShellToastOut{to{opacity:0;transform:translateX(14px)}}

/* ---------- context menu (reuses .gm-shell-menu look) ---------- */
.gm-shell-ctx{position:fixed;z-index:9800}

/* ---------- Party / Console / Extensions route content ---------- */
.gm-shell-view{padding:16px;overflow-y:auto;flex:1;min-height:0}
.gm-shell-view .gm-workspace-actions{margin-top:14px}
.gm-shell-party-row{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px}
.gm-shell-party-row .b{display:inline-flex;align-items:center;justify-content:center;gap:6px;
  font:600 12px/1 ui-sans-serif,sans-serif;padding:0 13px;height:32px;border-radius:8px;
  border:1px solid var(--border-light);background:var(--surface2);color:var(--text);cursor:pointer}
.gm-shell-party-row .b:hover{border-color:var(--gold)}
.gm-shell-party-row .b.dgr{border-color:#7a2334;color:#ff9db0;background:transparent}
.gm-shell-soon-badge{display:inline-flex;align-items:center;gap:6px;font:700 9.5px/1 ui-sans-serif,sans-serif;
  letter-spacing:.06em;text-transform:uppercase;padding:5px 10px;border-radius:999px;
  border:1.5px solid #F97316;color:#F97316}

/* ---------- Console: header line + the real, mounted Control Room ----------
   #vConsole itself is a plain flex column (set inline by addShellViews(),
   same discipline as .bp-view's own flex-column base) — no padding, no
   scroll of its own. The Control Room brings real internal scroll
   regions (left/right cards); a second one on the route around it would
   just be a second, confusing scrollbar, so this deliberately does NOT
   reuse .gm-shell-view (padded + overflow-y:auto, right for the still-
   placeholder Party/Extensions views, wrong here). */
.g1-console-hdr{flex:0 0 44px;height:44px;box-sizing:border-box;display:flex;align-items:center;
  gap:10px;padding:0 14px;background:var(--surface);border-bottom:1px solid var(--border)}
.g1-console-back{flex:0 0 auto;font:600 11px/1 ui-sans-serif,sans-serif;color:var(--muted);
  background:none;border:1px solid var(--border-light);border-radius:7px;padding:6px 10px;cursor:pointer}
.g1-console-back:hover,.g1-console-back:focus-visible{color:var(--text);border-color:var(--gold-dim)}
.g1-console-title{font-weight:700;font-size:13px;color:var(--text)}
.g1-console-chip{font:700 9.5px/1 ui-sans-serif,sans-serif;letter-spacing:.05em;text-transform:uppercase;
  padding:4px 9px;border-radius:999px;border:1.5px solid var(--border-light);color:var(--muted)}
.g1-console-chip.rec{border-color:#EF4444;color:#EF4444}
.g1-console-body{flex:1 1 auto;min-height:0;overflow:hidden;display:flex;flex-direction:column}
/* The mounted #gsControlRoom keeps its own studio.css sizing/scroll
   behavior completely verbatim — including its own real height calc,
   which is what actually gives Program its real height — since
   gamiaux-shell.js's enterConsoleControlRoom() gives the mount host the
   "gs" class so every ".gs ..." rule in studio.css still matches its new
   home exactly as it matched #gmStudio. No sizing override needed or
   added here; deliberately not fighting studio.css's own numbers. */
.g1-console-body .g1-mount-host{flex:1 1 auto;min-height:0;overflow:hidden}
/* The "gs" class enterConsoleControlRoom() adds to this host (so every
   ".gs <descendant>" rule in studio.css keeps matching #gsControlRoom in
   its new home) also matches studio.css's own bare ".gs{padding:22-28px
   depending on breakpoint; min-height:100%; ...}" — real self-styling
   meant for #gmStudio, the actual Studio workspace ROOT, which normally
   only reaches #gsControlRoom as inherited spacing from a distant
   ancestor, never applied directly to its immediate parent. Landing
   .gs on the immediate parent instead applies it directly, eating
   ~56px of real vertical height Bay 03 never had to give up (measured
   live: #gsControlRoom rendered 796px tall against an 852px slot before
   this). Descendant selectors are exactly what's wanted here; the root
   element's own self-styling is not — this cancels only that. */
.g1-console-body .g1-mount-host.gs{padding:0}
/* studio.css's own .gs .gs-control-room{height:calc(100vh - 214px)} was
   tuned for its old home (Studio's own rackhead+head+tabs chrome, which
   really did total ~214px there) — Console's chrome above/below it is
   shorter (a 44px header vs. Studio's much taller stack), so that fixed
   number leaves real, measured space unused at the bottom (771px used
   vs. 852px actually available at 1914x985) instead of giving Program
   its due share. Overriding to fill the real flex slot instead of a
   number written for a different context — same discipline as every
   other override in this file, !important because this ties the
   specificity of studio.css's own .gs .gs-control-room rule and would
   otherwise be decided by source order, not intent. studio.css itself
   stays untouched. */
.g1-console-body .gs-control-room{height:auto!important;max-height:none!important;flex:1 1 auto!important}

/* ---------- responsive: 1920 -> 420, no document scroll, no horizontal overflow ----------
   Closed-by-default (the 0px 3rd track above) already applies at every
   width, on every route — no separate workspace-route/narrow-width
   auto-hide logic is needed any more (that used to be the only thing
   keeping the rail out of the way below 1440px; now it's out of the way
   everywhere until the user opens it). These breakpoints only narrow
   the OPEN width so it doesn't eat the whole viewport on a small
   screen, down to fully suppressing it below 900px (an opened rail
   plus the icon-only rail at that width leaves no usable room for the
   real app surface — the same conservative floor the old pin-based
   version had). */
@media (max-width:1024px){
  .gm-shell-search{max-width:220px}
  body.g1-party-open #gmShellContentRow{grid-template-columns:64px minmax(0,1fr) var(--g1-rail-w,220px)}
  .g1-rail{width:64px}
}
@media (max-width:900px){
  .gm-shell-menubar .gm-shell-menubar-right{display:none}
  .gm-shell-search{display:none}
  #gmShellContentRow, body.g1-party-open #gmShellContentRow{grid-template-columns:56px minmax(0,1fr) 0px}
  .g1-rail-lbl{font-size:7.6px}
}
@media (max-width:760px){
  .gm-shell-topbar{height:38px}
  .gm-shell-brand span.gm-shell-brand-txt{display:none}
  .gm-shell-chip{display:none}
}
@media (max-width:480px){
  .gm-shell-topbar{gap:6px;padding:0 8px}
  .gm-shell-acct-nm{display:none}
  #gmShellContentRow{grid-template-columns:48px minmax(0,1fr) 0px}
  .g1-rail{width:48px;padding:6px 3px}
  .g1-rail-lbl{display:none}
}

/* ===== Launch ("hyper full-screen") =====
   Entering .bp-rocket puts .app itself at position:fixed/inset:0 (see
   gamiaux-shell.js's enforceShellChrome rocket branch) so it already
   visually covers the shell chrome underneath — this still explicitly
   steps the chrome aside rather than relying only on stacking order,
   and gives the always-visible "Exit launch" overlay button somewhere
   to sit above everything, .app included. */
body.g1-rocket-active .gm-shell-topbar,
body.g1-rocket-active .gm-shell-menubar,
body.g1-rocket-active .gm-shell-statusbar,
body.g1-rocket-active .g1-rail,
body.g1-rocket-active .g1-party-rail{display:none!important}
/* Visibility is governed by gamiaux-shell.js's syncLaunchExit() setting
   the native `hidden` attribute (the same rocket boolean that drives
   body.g1-rocket-active above) — this just styles it once shown. */
.g1-launch-exit{
  position:fixed;top:16px;right:16px;z-index:6000;display:inline-flex;align-items:center;gap:6px;
  height:34px;padding:0 14px 0 10px;border-radius:999px;border:1px solid rgba(255,255,255,.18);
  background:rgba(10,12,18,.72);backdrop-filter:blur(6px);color:#fff;
  font:600 12px ui-sans-serif,sans-serif;cursor:pointer;box-shadow:0 4px 18px rgba(0,0,0,.35);
}
.g1-launch-exit[hidden]{display:none!important}
.g1-launch-exit svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2}
.g1-launch-exit:hover{border-color:var(--gold);background:rgba(10,12,18,.88)}

/* ===========================================================
   Notification engine + Settings route
   Reuses the app's own brand tokens (--surface/--surface2/--border/
   --border-light/--text/--muted/--gold/--gm-grad/--red/--win) defined in
   index.html's :root — no separate theme system, works in whatever
   light/dark state the rest of the shell is already in.
   =========================================================== */

/* ---- toast stack (separate from the single-line #toast element other
   call sites reuse via showToast() — this one stacks, carries actions,
   and the inline reply composer) ---- */
#gmNotifyToasts{position:fixed;top:64px;right:16px;z-index:9950;display:flex;flex-direction:column;gap:8px;width:min(340px,calc(100vw - 24px));pointer-events:none}
.gm-notify-toast{pointer-events:auto;display:flex;flex-wrap:wrap;align-items:flex-start;gap:8px;padding:10px 12px;border-radius:10px;
  background:var(--surface,#0f1218);border:1px solid var(--border-light,rgba(255,255,255,.12));box-shadow:0 18px 50px -14px rgba(0,0,0,.6);
  opacity:0;transform:translateY(-6px) scale(.98);transition:opacity .18s ease,transform .18s ease;cursor:pointer}
.gm-notify-toast.in{opacity:1;transform:translateY(0) scale(1)}
.gm-notify-toast-icon{font-size:16px;line-height:1;flex-shrink:0}
.gm-notify-toast-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--text,#eaecf0)}
.gm-notify-toast-body strong{font-weight:700}
.gm-notify-toast-body span{color:var(--muted,#8892a6);font-size:11px;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.gm-notify-toast-close{margin-left:auto;background:none;border:none;color:var(--muted,#8892a6);font-size:16px;line-height:1;cursor:pointer;padding:0 2px}
.gm-notify-toast-close:hover{color:var(--text,#eaecf0)}

.gm-notify-actions{display:flex;gap:6px;width:100%;margin-top:2px}
.gm-notify-btn{flex:1;min-width:0;border:1px solid var(--border,rgba(255,255,255,.1));background:rgba(255,255,255,.04);color:var(--text,#eaecf0);
  border-radius:7px;padding:6px 8px;font:700 10.5px/1 ui-sans-serif,sans-serif;letter-spacing:.02em;cursor:pointer}
.gm-notify-btn:hover{filter:brightness(1.16)}
.gm-notify-btn.primary{background:var(--gm-grad,linear-gradient(135deg,#8B3AF5,#22D3EE));border-color:transparent;color:#fff}
.gm-notify-reply{display:flex;gap:6px;width:100%;margin-top:2px}
.gm-notify-reply input{flex:1;min-width:0;background:var(--surface2,#161a24);border:1px solid var(--border,rgba(255,255,255,.1));color:var(--text,#eaecf0);
  border-radius:7px;padding:6px 8px;font-size:11.5px}
.gm-notify-reply button{border:none;background:var(--gm-grad,linear-gradient(135deg,#8B3AF5,#22D3EE));color:#fff;border-radius:7px;padding:6px 10px;font:700 10.5px/1 ui-sans-serif,sans-serif;cursor:pointer}
.gm-notify-outcome{width:100%;font-size:10.5px;color:var(--win,#3ddc84);font-weight:700;letter-spacing:.02em}

/* ---- the panel becomes a grouped, filterable inbox (existing container
   ids/classes: #gmGlobalNotifPanel/#gmGlobalNotifList/.bp-notif-item —
   nothing here changes those, only what renders inside them) ---- */
.gm-notif-filters{display:flex;flex-wrap:wrap;gap:4px;padding:8px 10px;border-bottom:1px solid var(--border,rgba(255,255,255,.08));position:sticky;top:0;background:var(--surface2,#12151d);z-index:1}
.gm-notif-filter{border:1px solid var(--border,rgba(255,255,255,.1));background:transparent;color:var(--muted,#8892a6);border-radius:999px;padding:3px 9px;font:700 9px/1.6 ui-sans-serif,sans-serif;letter-spacing:.03em;cursor:pointer}
.gm-notif-filter.active{background:var(--gm-grad,linear-gradient(135deg,#8B3AF5,#22D3EE));border-color:transparent;color:#fff}
.gm-notif-markall{margin-left:auto;background:none;border:none;color:var(--muted,#8892a6);font-size:9.5px;font-weight:700;letter-spacing:.02em;cursor:pointer}
.gm-notif-markall:hover{color:var(--text,#eaecf0)}
.gm-notif-daylabel{padding:6px 12px 2px;font:800 9px/1.4 ui-sans-serif,sans-serif;letter-spacing:.08em;text-transform:uppercase;color:var(--muted,#8892a6)}
.gm-notify-item{flex-wrap:wrap;cursor:pointer}
.gm-notify-item .gm-notify-actions{margin-top:6px}
.gm-notif-outcome{margin-left:6px;font:700 9px/1 ui-sans-serif,sans-serif;letter-spacing:.02em;color:var(--win,#3ddc84);flex-shrink:0}

/* ---- Settings route (Cut-skin cards: dark surfaces, thin borders, the
   same rounded-card language Cut's own panels use) ---- */
#vSettings{overflow-y:auto}
.gm-set-wrap{max-width:820px;margin:0 auto;padding:28px 20px 60px}
.gm-set-hdr h2{margin:0 0 4px;font:800 22px/1.2 ui-sans-serif,sans-serif;color:var(--text,#eaecf0)}
.gm-set-hdr p{margin:0 0 20px;color:var(--muted,#8892a6);font-size:12.5px}
.gm-set-cards{display:flex;flex-direction:column;gap:14px}
.gm-set-card{background:var(--surface,#0f1218);border:1px solid var(--border-light,rgba(255,255,255,.1));border-radius:14px;padding:16px 18px}
.gm-set-card h3{margin:0 0 10px;font:800 13px/1.3 ui-sans-serif,sans-serif;letter-spacing:.02em;color:var(--text,#eaecf0)}
.gm-set-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:2px 16px}
.gm-set-divider{height:1px;background:var(--border,rgba(255,255,255,.08));margin:10px 0}
.gm-set-row{display:flex;align-items:center;gap:12px;padding:8px 0;min-height:34px}
.gm-set-row-inline{gap:8px}
.gm-set-row-inline input[type=time]{background:var(--surface2,#161a24);border:1px solid var(--border,rgba(255,255,255,.1));color:var(--text,#eaecf0);border-radius:6px;padding:4px 6px;font-size:11px}
.gm-set-row-copy{display:flex;flex-direction:column;gap:1px;flex:1;min-width:0}
.gm-set-row-copy strong{font-size:12px;color:var(--text,#eaecf0);font-weight:700}
.gm-set-row-copy small{font-size:10.5px;color:var(--muted,#8892a6);line-height:1.4}
.gm-set-row-actions{display:flex;align-items:center;gap:8px}
.gm-set-select{background:var(--surface2,#161a24);border:1px solid var(--border,rgba(255,255,255,.1));color:var(--text,#eaecf0);border-radius:7px;padding:6px 8px;font-size:11.5px;max-width:220px}
.gm-set-range{flex:1;max-width:220px}
.gm-set-hint{margin:6px 0 0;color:var(--muted,#8892a6);font-size:10.5px;line-height:1.5}
.gm-set-hint code{background:var(--surface2,#161a24);border-radius:4px;padding:1px 4px;font-size:10px}

/* toggle switch */
.gm-set-switch{position:relative;display:inline-flex;flex-shrink:0;width:36px;height:20px}
.gm-set-switch input{position:absolute;inset:0;opacity:0;margin:0;cursor:pointer;z-index:1}
.gm-set-switch-track{position:absolute;inset:0;border-radius:999px;background:var(--border,rgba(255,255,255,.16));transition:background .15s}
.gm-set-switch-track::after{content:"";position:absolute;top:2px;left:2px;width:16px;height:16px;border-radius:50%;background:#fff;transition:transform .15s;box-shadow:0 1px 3px rgba(0,0,0,.4)}
.gm-set-switch input:checked ~ .gm-set-switch-track{background:var(--gm-grad,linear-gradient(135deg,#8B3AF5,#22D3EE))}
.gm-set-switch input:checked ~ .gm-set-switch-track::after{transform:translateX(16px)}

@media (max-width:640px){
  .gm-set-wrap{padding:18px 12px 48px}
  .gm-set-grid{grid-template-columns:1fr}
  #gmNotifyToasts{left:8px;right:8px;width:auto;top:52px}
}

/* Appearance settings: density + reduced motion, applied at the
   document-root level so they affect the whole shell, not just Settings. */
html.gm-reduce-motion *{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important}
html.gm-density-compact .gm-set-row{min-height:28px;padding:5px 0}
html.gm-density-compact .gm-set-card{padding:12px 14px}
html.gm-tab-labels-off .g1-rail-lbl{display:none}
