/* Olfe KVM console — graphite dark by default, light on request or by system. */
@font-face { font-family: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("/assets/fonts/geist-latin.woff2?v=9b6f5ff45b27") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("/assets/fonts/geist-latin-ext.woff2?v=58a6b173d5ca") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("/assets/fonts/geist-mono-latin.woff2?v=5f3d6ad60f29") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("/assets/fonts/geist-mono-latin-ext.woff2?v=745994b5cd95") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  color-scheme: dark;
  --bg: #0c0d10;
  --stage: #0a0b0d;
  --panel: #111316;
  --panel-2: #16181d;
  --raise: #1c1f25;
  --hover: #22262e;
  --field: #0f1114;
  --line: #1e2128;
  --line-2: #2a2e37;
  --line-3: #343944;
  --text: #eceef2;
  --text-2: #c9ced8;
  --muted: #a8afbc;
  --faint: #8a92a0;
  --placeholder: #5f6673;
  --accent: #3d63e6;
  --accent-hover: #4c71f0;
  --accent-ink: #8fa9ff;
  --accent-soft: rgba(79, 116, 240, .14);
  --ring: rgba(79, 116, 240, .32);
  --ok: #34b27b;
  --ok-ink: #6fd6a6;
  --ok-soft: rgba(52, 178, 123, .14);
  --warn: #e0a23a;
  --danger: #e5534b;
  --danger-ink: #ff8a83;
  --bubble-mine: #2a43a3;
  --bubble-mine-ink: #f1f4ff;
  --bubble: #1c1f25;
  --kbd-bg: #1d2027;
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, .45);
  --shadow-xl: 0 28px 70px rgba(0, 0, 0, .55);
  --screen-ring: #23262e;
  --scrim: rgba(5, 6, 8, .66);
  --logo-dark: block;
  --logo-light: none;
  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --bar-h: 56px;
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f6f9; --stage: #e9ecf1; --panel: #ffffff; --panel-2: #f7f8fa; --raise: #eef1f6; --hover: #e9edf3; --field: #ffffff;
  --line: #e3e6ec; --line-2: #d9dde5; --line-3: #c9ced8; --text: #141821; --text-2: #2b3240; --muted: #4b5465; --faint: #687183; --placeholder: #9aa1ad;
  --accent: #3d63e6; --accent-hover: #3357d6; --accent-ink: #2f52cf; --accent-soft: rgba(61, 99, 230, .1); --ring: rgba(61, 99, 230, .28);
  --ok: #1f9d64; --ok-ink: #17824f; --ok-soft: rgba(31, 157, 100, .12); --warn: #c78414; --danger: #d33b33; --danger-ink: #c2332b;
  --bubble-mine: #3d63e6; --bubble-mine-ink: #ffffff; --bubble: #eef1f6; --kbd-bg: #f3f5f8;
  --shadow-lg: 0 12px 32px rgba(20, 24, 33, .12); --shadow-xl: 0 28px 70px rgba(20, 24, 33, .18); --screen-ring: #d3d8e0; --scrim: rgba(20, 24, 33, .4);
  --logo-dark: none; --logo-light: block;
}
@media (prefers-color-scheme: light) {
  :root[data-theme="system"] {
    color-scheme: light;
    --bg: #f4f6f9; --stage: #e9ecf1; --panel: #ffffff; --panel-2: #f7f8fa; --raise: #eef1f6; --hover: #e9edf3; --field: #ffffff;
    --line: #e3e6ec; --line-2: #d9dde5; --line-3: #c9ced8; --text: #141821; --text-2: #2b3240; --muted: #4b5465; --faint: #687183; --placeholder: #9aa1ad;
    --accent: #3d63e6; --accent-hover: #3357d6; --accent-ink: #2f52cf; --accent-soft: rgba(61, 99, 230, .1); --ring: rgba(61, 99, 230, .28);
    --ok: #1f9d64; --ok-ink: #17824f; --ok-soft: rgba(31, 157, 100, .12); --warn: #c78414; --danger: #d33b33; --danger-ink: #c2332b;
    --bubble-mine: #3d63e6; --bubble-mine-ink: #ffffff; --bubble: #eef1f6; --kbd-bg: #f3f5f8;
    --shadow-lg: 0 12px 32px rgba(20, 24, 33, .12); --shadow-xl: 0 28px 70px rgba(20, 24, 33, .18); --screen-ring: #d3d8e0; --scrim: rgba(20, 24, 33, .4);
    --logo-dark: none; --logo-light: block;
  }
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); font: 400 14px/1.5 var(--font); -webkit-font-smoothing: antialiased; overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
.eyebrow { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); }

/* ---------- controls ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 9px; border: 1px solid transparent;
  background: transparent; cursor: pointer; font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; transition: background-color .15s, border-color .15s, color .15s, opacity .15s; }
.btn:disabled { opacity: .45; cursor: default; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); }
.btn-outline { border-color: var(--line-2); background: var(--panel-2); color: var(--text-2); font-weight: 500; }
.btn-outline:hover:not(:disabled) { background: var(--hover); color: var(--text); }
.btn-ghost { color: var(--text-2); font-weight: 500; }
.btn-ghost:hover { background: var(--hover); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn-xl { height: 46px; font-size: 15px; border-radius: 10px; }
.btn-danger { color: var(--danger-ink); border-color: color-mix(in srgb, var(--danger) 35%, transparent); background: transparent; }
.btn:focus-visible, .icon-btn:focus-visible, .dbtn:focus-visible, .item:focus-visible, .seg button:focus-visible, .switch:focus-visible, .link-btn:focus-visible, .keygrid button:focus-visible {
  outline: none; box-shadow: 0 0 0 3px var(--ring); }
.icon-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; border: 0; background: transparent; color: var(--muted); cursor: pointer; transition: background .15s, color .15s; }
.icon-btn:hover { background: var(--hover); color: var(--text); }
.icon-btn[aria-pressed="true"] { background: var(--hover); color: var(--text); }
.icon-btn svg { width: 17px; height: 17px; }
.link-btn { border: 0; background: none; padding: 2px 4px; border-radius: 6px; color: var(--accent-ink); font-size: 12.5px; font-weight: 500; cursor: pointer; }
.input { width: 100%; height: 44px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--field); color: var(--text); outline: none; transition: border-color .15s, box-shadow .15s; }
.input::placeholder { color: var(--placeholder); }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }
.input-code { height: 52px; font: 600 18px/1 var(--mono); letter-spacing: .18em; text-transform: uppercase; }
kbd { display: inline-flex; align-items: center; height: 22px; padding: 0 6px; border-radius: 5px; border: 1px solid var(--line-3); border-bottom-width: 2px; background: var(--kbd-bg); color: var(--text); font: 600 11px/1 var(--mono); }
.keys { display: inline-flex; gap: 3px; }
.seg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; padding: 3px; border-radius: 9px; background: var(--field); border: 1px solid var(--line); }
.seg button { height: 28px; border: 0; border-radius: 6px; background: transparent; color: var(--faint); font-size: 12.5px; font-weight: 500; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--hover); color: var(--text); }
:root[data-theme="light"] .seg button[aria-pressed="true"] { background: var(--panel); box-shadow: 0 1px 3px rgba(20, 24, 33, .12); }
.switch { position: relative; width: 40px; height: 24px; flex: none; border-radius: 999px; border: 0; background: var(--line-3); cursor: pointer; transition: background .15s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch[aria-checked="true"] { background: var(--accent); }
.switch[aria-checked="true"]::after { transform: translateX(16px); }
.select { height: 36px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--field); color: var(--text); font-size: 13px; }
.chip { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 500; white-space: nowrap; }
.chip svg { width: 13px; height: 13px; }
.chip-live { background: var(--ok-soft); color: var(--ok-ink); }
.chip-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.chip-owner { background: var(--accent-soft); color: var(--accent-ink); }
.chip-control { background: var(--ok-soft); color: var(--ok-ink); }
.chip-view { background: var(--raise); color: var(--muted); }
.chip-warn { background: color-mix(in srgb, var(--warn) 16%, transparent); color: var(--warn); }

/* avatars: one colour per participant, matching their pointer */
.av { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; flex: none; font-size: 11.5px; font-weight: 600; color: #0c0d10; background: var(--c); }
.av-xs { width: 20px; height: 20px; font-size: 9px; }
[data-color="blue"] { --c: #7c9cff; } [data-color="amber"] { --c: #f2b34b; } [data-color="teal"] { --c: #4fd1bd; }
[data-color="pink"] { --c: #f48fc0; } [data-color="violet"] { --c: #b39cff; } [data-color="lime"] { --c: #a6d867; }

/* ---------- entry ---------- */
.entry { display: flex; flex-wrap: wrap; min-height: 100vh; height: 100vh; overflow: auto; }
.entry-art { position: relative; flex: 1 1 520px; min-height: 280px; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; background: #0b1020; }
.entry-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.entry-shade { position: absolute; inset: 0; background: rgba(8, 12, 24, .66); }
.entry-logo { position: relative; align-self: flex-start; height: 36px; width: auto; margin: 40px 48px; }
.entry-claim { position: relative; padding: 0 48px 48px; max-width: 540px; }
.entry-claim h2 { margin: 0 0 16px; font-size: 40px; line-height: 1.12; font-weight: 600; letter-spacing: -.02em; color: #fff; }
.entry-claim p { margin: 0; font-size: 13px; color: rgba(255, 255, 255, .5); }
.entry-side { flex: 1 1 520px; display: flex; align-items: center; justify-content: center; padding: 48px 24px; background: var(--panel); }
.entry-form { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 24px; }
.entry-head { display: flex; flex-direction: column; gap: 10px; }
.entry-head h1 { margin: 0; font-size: 30px; line-height: 1.15; font-weight: 600; letter-spacing: -.02em; }
.entry-head p { margin: 0; font-size: 15px; color: var(--muted); }
.fields { display: flex; flex-direction: column; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field > span { font-size: 13px; font-weight: 500; color: var(--text-2); }
.form-error { margin: -8px 0 0; font-size: 13.5px; color: var(--danger-ink); }
.entry-note { display: flex; align-items: center; justify-content: center; gap: 8px; margin: -8px 0 0; font-size: 12.5px; color: var(--faint); }
.entry-note svg { width: 14px; height: 14px; }

/* ---------- app shell ---------- */
.app { display: flex; flex-direction: column; height: 100vh; }
.bar { position: relative; z-index: 20; display: flex; align-items: center; gap: 14px; min-height: var(--bar-h); padding: 0 12px 0 20px; background: var(--panel); border-bottom: 1px solid var(--line); flex: none; }
.bar-logo { height: 24px; width: auto; }
.logo-dark { display: var(--logo-dark); } .logo-light { display: var(--logo-light); }
.vr { width: 1px; height: 24px; background: var(--line); flex: none; }
.bar-session { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.bar-title { font-size: 15px; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-ref { font-size: 12px; color: var(--faint); white-space: nowrap; }
.bar-metrics { display: flex; align-items: center; gap: 16px; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.bar-metrics span { display: inline-flex; align-items: center; gap: 6px; }
.bar-metrics svg { width: 14px; height: 14px; }
.bar-metrics b { font-weight: 500; }
#m-time[data-kind="soon"] { color: var(--warn); } #m-time[data-kind="late"] { color: var(--danger-ink); }
.avatars { display: flex; align-items: center; }
.avatars .av { width: 28px; height: 28px; margin-left: -6px; box-shadow: 0 0 0 2px var(--panel); }
.avatars .av:first-child { margin-left: 0; }
.avatars .more { background: var(--raise); color: var(--muted); }
.bar-icons { display: flex; align-items: center; gap: 2px; }
.dot-badge { position: absolute; top: 6px; right: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--panel); }
#panel-toggle { display: none; }

.body { position: relative; flex: 1; min-height: 0; display: flex; }
.stage { position: relative; flex: 1; min-width: 0; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 24px 24px 92px; background: var(--stage); overflow: hidden; }
.stage.actual { overflow: auto; align-items: flex-start; justify-content: flex-start; }
.screen { position: relative; flex: none; display: flex; border-radius: 10px; overflow: hidden; outline: none; background: #000; box-shadow: 0 0 0 1px var(--screen-ring), var(--shadow-lg); transition: box-shadow .15s, opacity .25s; }
.screen:focus { box-shadow: 0 0 0 1px var(--accent), 0 0 0 4px var(--ring), var(--shadow-lg); }
body[data-view="loading"] .screen { opacity: 0; pointer-events: none; }
body.viewer .screen { cursor: crosshair; }
.screen > div:not(.pointers):not(.controller):not(.video-msg) { flex: none; }
.pointers { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.mark { position: absolute; pointer-events: none; }
.mark .r { position: absolute; width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%; border: 2px solid var(--c); animation: ring 1.1s ease-out 2; }
.mark .r + .r { animation-delay: .35s; }
.mark .d { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--c); animation: fade 2.4s ease-in forwards; }
.mark .t { position: absolute; left: 12px; top: 10px; display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 6px; background: var(--c); color: #0c0d10; font-size: 11.5px; font-weight: 600; white-space: nowrap; animation: fade 2.4s ease-in forwards; }
.controller { position: absolute; right: 12px; top: 12px; z-index: 4; display: inline-flex; align-items: center; gap: 8px; height: 28px; padding: 0 10px 0 4px; border-radius: 999px; background: rgba(17, 19, 22, .86); border: 1px solid #2a2e37; color: #d6dae2; font-size: 12px; pointer-events: none; }
.video-msg { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; background: var(--panel); color: var(--muted); text-align: center; }
.video-msg p { margin: 0; font-size: 14px; font-weight: 500; color: var(--text); }
.vm-icon { width: 32px; height: 32px; stroke-width: 1.5; }
.video-msg[data-state="unsupported"] .vm-icon { color: var(--warn); }
.vm-mark { width: 56px; height: auto; }

.hint { position: absolute; left: 50%; top: 14px; z-index: 6; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border-radius: 999px;
  background: var(--panel-2); border: 1px solid var(--line-2); color: var(--text-2); font-size: 12.5px; white-space: nowrap; box-shadow: var(--shadow-lg); }
.hint svg { width: 14px; height: 14px; color: #4fd1bd; }

/* dock */
.dock { position: absolute; left: 50%; bottom: 22px; z-index: 10; transform: translateX(-50%); display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 14px;
  background: var(--panel-2); border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); white-space: nowrap; }
body[data-view="loading"] .dock { opacity: 0; pointer-events: none; }
.dbtn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 9px; border: 0; background: transparent; color: var(--text-2);
  font-size: 13.5px; font-weight: 500; cursor: pointer; transition: background .15s, color .15s; }
.dbtn:hover:not(:disabled), .dbtn[aria-expanded="true"] { background: var(--hover); color: var(--text); }
.dbtn:disabled { color: var(--placeholder); cursor: not-allowed; }
.dbtn:disabled kbd { color: var(--placeholder); }
.dbtn svg { width: 17px; height: 17px; stroke-width: 1.8; }
.dsq { width: 36px; padding: 0; }
.dsep { width: 1px; height: 24px; background: var(--line-2); }
.dmenu { position: relative; }
.fs-off { display: none; } body.fs .fs-on { display: none; } body.fs .fs-off { display: block; }
.pop { position: absolute; left: 50%; bottom: calc(100% + 12px); z-index: 30; transform: translateX(-50%); min-width: 250px; padding: 4px; border-radius: 12px;
  background: var(--panel); border: 1px solid var(--line-2); box-shadow: var(--shadow-xl); white-space: normal; animation: pop-in .12s ease-out; }
.pop-label { padding: 8px 8px 4px; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.pop-label em { font-style: normal; font-weight: 500; letter-spacing: 0; text-transform: none; margin-left: 4px; }
.pop-sep { height: 1px; margin: 4px -4px; background: var(--line); }
.item { display: flex; align-items: center; gap: 9px; width: 100%; min-height: 34px; padding: 6px 9px; border: 0; border-radius: 8px; background: none; cursor: pointer; text-align: left; font-size: 13.5px; color: var(--text); }
.item > span:first-child:not(.keys), .item > svg + span { flex: 1; }
.item svg { color: var(--muted); }
.item:hover { background: var(--hover); }
.item.danger, .item.danger svg { color: var(--danger-ink); }
#pop-keys { width: 330px; }
.keygrid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; padding: 4px 6px 6px; }
.keygrid.k7 { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.keygrid button { height: 30px; border-radius: 7px; border: 1px solid var(--line-2); background: var(--panel-2); color: var(--text); font: 500 12px/1 var(--mono); cursor: pointer; }
.keygrid button:hover { background: var(--hover); }
.pop-type { width: 340px; padding: 4px 8px 8px; }
.pop-type textarea { display: block; width: 100%; min-height: 92px; resize: vertical; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--field); color: var(--text); font: 13px/1.5 var(--mono); outline: none; }
.pop-type textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }
.progress { height: 4px; margin-top: 8px; border-radius: 999px; background: var(--raise); overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .1s linear; }
.pop-foot { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); cursor: pointer; }
.check input { width: 15px; height: 15px; margin: 0; accent-color: var(--accent); }
.count { margin-left: auto; font-size: 12px; color: var(--faint); }
#pop-screen .seg { margin: 2px 6px 6px; }

/* side panel */
.side { width: 340px; flex: none; min-height: 0; display: flex; flex-direction: column; background: var(--panel); border-left: 1px solid var(--line); }
.people { padding: 16px 12px 8px; border-bottom: 1px solid var(--line); max-height: 52%; overflow-y: auto; }
.side-head { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 10px; }
.side h2 { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: .02em; }
.side h2 span { color: var(--faint); font-weight: 500; }
.request { display: flex; flex-direction: column; gap: 12px; margin: 0 0 10px; padding: 12px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line-2); animation: pop-in .15s ease-out; }
.request-who { display: flex; align-items: center; gap: 10px; }
.request-who div { flex: 1; min-width: 0; }
.request-who b { display: block; font-size: 13.5px; font-weight: 600; }
.request-who span { font-size: 12.5px; color: var(--muted); }
.request-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.plist { list-style: none; margin: 0; padding: 0; }
.prow { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 4px 0 6px; border-radius: 10px; }
.prow .who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.prow .who b { font-size: 13.5px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prow .who b em { font-style: normal; color: var(--faint); font-weight: 400; }
.prow .who small { font-size: 11.5px; color: var(--warn); }
.prow .offline { opacity: .55; }
.pmenu { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 8px 10px 52px; }
.pmenu button { height: 28px; padding: 0 10px; border-radius: 7px; border: 1px solid var(--line-2); background: var(--panel-2); color: var(--text-2); font-size: 12.5px; font-weight: 500; cursor: pointer; }
.pmenu button:hover { background: var(--hover); }
.pmenu .danger { color: var(--danger-ink); border-color: color-mix(in srgb, var(--danger) 35%, transparent); }
.chat { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.chat-title { padding: 14px 16px 6px; }
.chat-log { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 6px 16px 12px; }
.msg-sys { align-self: center; max-width: 92%; font-size: 12px; color: var(--faint); text-align: center; }
.msg { display: flex; flex-direction: column; gap: 3px; max-width: 86%; }
.msg .meta { font-size: 12px; color: var(--faint); }
.msg .meta b { color: var(--text-2); font-weight: 600; }
.msg .text { align-self: flex-start; padding: 8px 11px; border-radius: 4px 12px 12px 12px; background: var(--bubble); font-size: 13.5px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg.mine { align-self: flex-end; align-items: flex-end; }
.msg.mine .text { align-self: flex-end; border-radius: 12px 4px 12px 12px; background: var(--bubble-mine); color: var(--bubble-mine-ink); }
.chat-form { position: relative; padding: 10px 12px 14px; border-top: 1px solid var(--line); }
.chat-input { height: 38px; padding-right: 42px; font-size: 13.5px; }
.chat-send { position: absolute; right: 16px; top: 12px; color: var(--accent-ink); }

/* states drawn over the stage: loader */
.state { position: absolute; inset: 0; z-index: 8; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; background: var(--stage); }
.state-label { margin: 0; font-size: 14px; letter-spacing: .025em; color: var(--muted); }
.loader-mark { width: 112px; height: auto; }

/* full-page states: waiting, end */
.page-state { position: absolute; inset: var(--bar-h) 0 0 0; z-index: 15; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; padding: 32px 20px; text-align: center; background: var(--bg); }
.ps-text { display: flex; flex-direction: column; gap: 10px; max-width: 440px; }
.ps-text h1 { margin: 0; font-size: 26px; line-height: 1.2; font-weight: 600; letter-spacing: -.02em; }
.ps-text p { margin: 0; font-size: 15px; color: var(--muted); }
.ps-text .eyebrow { color: var(--accent-ink); letter-spacing: .2em; }
.ps-text .eyebrow:empty { display: none; }
.ps-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.facts { width: 100%; max-width: 440px; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; overflow: hidden; border-radius: 12px; border: 1px solid var(--line); background: var(--line); text-align: left; }
.facts div { padding: 14px 16px; background: var(--panel); }
.facts dt { font-size: 12px; color: var(--faint); }
.facts dd { margin: 4px 0 0; font-size: 14px; font-weight: 600; }
.end-mark { width: 64px; height: auto; opacity: .3; }
.end-mark * { animation: none !important; }
body[data-view="waiting"] .bar-metrics, body[data-view="waiting"] .avatars, body[data-view="end"] .bar-metrics, body[data-view="end"] .avatars,
body[data-view="waiting"] #panel-toggle, body[data-view="end"] #panel-toggle, body[data-view="end"] #leave { display: none !important; }

/* dialogs */
.dialog { width: min(520px, calc(100vw - 32px)); padding: 0; border-radius: 16px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); box-shadow: var(--shadow-xl); }
.dialog::backdrop { background: var(--scrim); }
.dialog[open] { animation: pop-in .15s ease-out; }
.dlg-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 22px 6px; }
.dlg-head h2 { margin: 0 0 6px; font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.dlg-head p { margin: 0; font-size: 13.5px; color: var(--muted); }
.dlg-body { display: flex; flex-direction: column; gap: 18px; padding: 18px 22px 22px; }
.dlg-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--line); }
.copy-row { display: flex; align-items: center; gap: 8px; padding: 5px 5px 5px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--field); }
.copy-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; color: var(--text-2); }
.code-box { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--field); border: 1px solid var(--line); }
.code-box div { display: flex; flex-direction: column; gap: 6px; }
.code-box span { font-size: 12.5px; color: var(--faint); }
.code-box strong { font-size: 24px; font-weight: 600; letter-spacing: .16em; }
.settings { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.setting { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; border-bottom: 1px solid var(--line); }
.setting:last-child { border-bottom: 0; }
.setting > div:first-child { display: flex; flex-direction: column; gap: 3px; }
.setting b { font-size: 14px; font-weight: 500; }
.setting span { font-size: 12.5px; color: var(--faint); }
.setting .seg { min-width: 230px; }
.confirm { width: min(400px, calc(100vw - 32px)); padding: 22px; }
.confirm h2 { margin: 0 0 6px; font-size: 16px; font-weight: 600; }
.confirm p { margin: 0 0 20px; font-size: 13.5px; color: var(--muted); }
.confirm p:empty { margin-bottom: 14px; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 8px; }

/* toasts */
.toasts { position: fixed; left: 50%; bottom: 96px; z-index: 60; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 8px 10px 8px 12px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line-2); box-shadow: var(--shadow-xl);
  font-size: 13.5px; font-weight: 500; pointer-events: auto; animation: toast-in .15s ease-out; }
.toast > svg { color: var(--ok); }
.toast[data-kind="err"] > svg { color: var(--danger-ink); }
.toast .btn { height: 28px; padding: 0 10px; font-size: 12.5px; }

/* OLFE loader (same as the customer panel) */
.olfe-loader { overflow: visible; --olfe-ink: #4f74f0; --olfe-lit: #ffffff; --olfe-glow: rgba(79, 116, 240, .55); --olfe-cycle: 3.2s; --olfe-hold: .6s; }
:root[data-theme="light"] .olfe-loader { --olfe-ink: #3d63e6; }
.olfe-loader-arc { fill: none; stroke: var(--olfe-ink); stroke-width: 24; stroke-linecap: round; stroke-dasharray: 850; stroke-dashoffset: 0; animation: olfe-arc var(--olfe-cycle) cubic-bezier(.65, .05, .36, 1) infinite; animation-delay: var(--olfe-hold); }
.olfe-loader-edge { stroke: var(--olfe-ink); stroke-width: 6; stroke-linecap: round; opacity: .9; animation: olfe-edge var(--olfe-cycle) ease-in-out infinite; animation-delay: calc(var(--d) + var(--olfe-hold) + .4s); }
.olfe-loader-node { fill: var(--olfe-ink); stroke: var(--olfe-ink); stroke-width: 0; transform-box: fill-box; transform-origin: center; animation: olfe-node var(--olfe-cycle) ease-in-out infinite; animation-delay: calc(var(--d) + var(--olfe-hold) + .4s); }
.olfe-loader-dot { fill: var(--olfe-ink); transform-box: fill-box; transform-origin: center; animation: olfe-dot var(--olfe-cycle) ease-in-out infinite; animation-delay: calc(var(--d) + var(--olfe-hold) + .4s); }
@keyframes olfe-arc { 0%, 18% { stroke-dashoffset: 0; } 48% { stroke-dashoffset: -850; } 48.01% { stroke-dashoffset: 850; } 80%, 100% { stroke-dashoffset: 0; } }
@keyframes olfe-edge { 0%, 50%, 100% { opacity: .9; } 14% { opacity: 1; } 28% { opacity: .45; } }
@keyframes olfe-node { 0%, 40%, 100% { fill: var(--olfe-ink); stroke-width: 0; transform: scale(1); filter: none; } 18% { fill: var(--olfe-lit); stroke-width: 6; transform: scale(1.28); filter: drop-shadow(0 0 8px var(--olfe-glow)); } }
@keyframes olfe-dot { 0%, 40%, 100% { opacity: 1; transform: scale(1); } 20% { opacity: .2; transform: scale(.6); } }
@keyframes ring { 0% { transform: scale(.4); opacity: 1; } 100% { transform: scale(2.4); opacity: 0; } }
@keyframes fade { 0%, 70% { opacity: 1; } 100% { opacity: 0; } }
@keyframes pop-in { from { opacity: 0; transform: translateX(-50%) translateY(4px) scale(.98); } }
.request, .dialog[open] { animation-name: none; }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) {
  .olfe-loader-arc, .olfe-loader-edge, .olfe-loader-node, .olfe-loader-dot, .mark .r { animation: none; }
  .olfe-loader { animation: olfe-breathe 2.4s ease-in-out infinite; }
  @keyframes olfe-breathe { 50% { opacity: .55; } }
  .pop, .toast { animation: none; }
}

/* fullscreen: bar and side panel step aside */
body.fs .bar { position: fixed; left: 0; right: 0; top: 0; transform: translateY(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); }
body.fs.reveal .bar { transform: none; }
body.fs .side { display: none; }
body.fs .stage { padding: 0 0 80px; background: #000; }
body.fs .screen { border-radius: 0; box-shadow: none; }

/* narrower screens: the side panel becomes a drawer */
@media (max-width: 1180px) {
  #panel-toggle { display: inline-flex; }
  .side { position: absolute; right: 0; top: 0; bottom: 0; z-index: 25; transform: translateX(100%); transition: transform .2s; box-shadow: var(--shadow-xl); }
  body.side-open .side { transform: none; }
  #m-res { display: none !important; }
}
@media (max-width: 860px) {
  .bar-metrics, .bar-ref, .avatars { display: none !important; }
  .dbtn span { display: none; }
  .dbtn { padding: 0 10px; }
  .stage { padding: 12px 12px 84px; }
}
@media (max-width: 560px) {
  .bar { gap: 8px; padding: 0 6px 0 12px; }
  .vr, #role-chip, #live-chip { display: none !important; }
  #share-open span, #ask-control span { display: none; }
  .side { width: 100%; }
  .pop { position: fixed; left: 8px; right: 8px; bottom: 84px; transform: none; width: auto !important; }
  .dock kbd { padding: 0 4px; font-size: 10px; }
  .entry-claim h2 { font-size: 30px; }
}
