:root {
  color-scheme: dark;
  --night: #071527;
  --night-deep: #040d19;
  --panel: rgba(12, 31, 53, .91);
  --panel-soft: rgba(18, 42, 68, .76);
  --line: rgba(157, 188, 216, .15);
  --line-strong: rgba(110, 196, 221, .3);
  --ink: #f3f8fc;
  --muted: #9aaec1;
  --faint: #70869b;
  --cyan: #73e4ef;
  --cyan-bright: #93f4f4;
  --blue: #3589da;
  --danger: #ff9d9d;
  --success: #76e2ba;
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 13px;
  --ease: cubic-bezier(.22, .7, .2, 1);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: var(--night-deep); }
body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 48% 3%, rgba(22, 76, 119, .3), transparent 45rem),
    linear-gradient(145deg, #081a2e 0%, #071527 48%, #071321 100%);
}
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; }
svg { display: block; }
[hidden] { display: none !important; }

.skip-link {
  position: fixed;
  z-index: 50;
  top: 12px;
  left: 12px;
  transform: translateY(-150%);
  border-radius: 9px;
  padding: 10px 14px;
  color: #051322;
  background: var(--cyan-bright);
  font-size: 13px;
  font-weight: 750;
}
.skip-link:focus { transform: translateY(0); }
:focus-visible { outline: 2px solid var(--cyan-bright); outline-offset: 3px; }

.login-screen {
  isolation: isolate;
  position: relative;
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 24px;
  background:
    radial-gradient(ellipse at 75% 25%, rgba(34, 104, 154, .2), transparent 32rem),
    radial-gradient(ellipse at 21% 87%, rgba(30, 62, 132, .2), transparent 31rem),
    linear-gradient(135deg, #061323 0%, #0a1b31 52%, #08172b 100%);
}
.login-screen::before, .login-screen::after {
  position: absolute;
  z-index: -1;
  width: 60vw;
  height: 60vw;
  border: 1px solid rgba(110, 193, 222, .08);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}
.login-screen::before { top: -37vw; right: -10vw; box-shadow: 0 0 0 44px rgba(110, 193, 222, .025), 0 0 0 90px rgba(110, 193, 222, .018); }
.login-screen::after { bottom: -49vw; left: -15vw; width: 71vw; height: 71vw; }
.login-glow { position: absolute; z-index: -1; width: 280px; height: 280px; border-radius: 50%; filter: blur(90px); opacity: .17; }
.login-glow-a { top: 17%; left: 17%; background: #317fe6; }
.login-glow-b { right: 14%; bottom: 12%; background: #25cfdd; opacity: .1; }
.login-top {
  position: absolute;
  top: 30px;
  left: max(30px, calc((100vw - 1400px) / 2));
  right: max(30px, calc((100vw - 1400px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-mark {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border: 1px solid rgba(115, 228, 239, .28);
  border-radius: 13px;
  background: linear-gradient(145deg, rgba(22, 72, 107, .95), rgba(13, 40, 68, .88));
  box-shadow: inset 0 1px rgba(255, 255, 255, .08), 0 5px 18px rgba(0, 0, 0, .18);
}
.brand-mark svg { width: 26px; fill: var(--cyan); }
.brand-mark .brand-cut { fill: #163a59; }
.brand b { display: block; color: #f3f9fc; font-size: 14px; font-weight: 760; letter-spacing: -.02em; }
.brand small { display: block; margin-top: 2px; color: #91a9bd; font-size: 10px; font-weight: 620; letter-spacing: .11em; text-transform: uppercase; }
.language-switch { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 11px; background: rgba(4, 15, 28, .48); }
.language-option { min-width: 37px; height: 27px; border: 0; border-radius: 8px; color: #8197ab; background: transparent; font-size: 10px; font-weight: 800; letter-spacing: .08em; cursor: pointer; transition: color .2s ease, background .2s ease; }
.language-option:hover { color: var(--ink); }
.language-option.active { color: #092238; background: var(--cyan); box-shadow: 0 2px 9px rgba(58, 183, 200, .24); }
.login-card {
  width: min(100%, 455px);
  margin-top: 56px;
  border: 1px solid rgba(130, 190, 218, .17);
  border-radius: 28px;
  padding: 37px 39px 29px;
  background: linear-gradient(157deg, rgba(13, 34, 57, .96), rgba(9, 25, 44, .94));
  box-shadow: 0 30px 100px rgba(0, 0, 0, .35), inset 0 1px rgba(255, 255, 255, .035);
  animation: card-arrive .7s var(--ease) both;
}
@keyframes card-arrive { from { opacity: 0; transform: translateY(13px); } to { opacity: 1; transform: translateY(0); } }
.login-emblem {
  display: grid;
  width: 54px;
  height: 54px;
  margin-bottom: 26px;
  place-items: center;
  border: 1px solid rgba(111, 224, 239, .32);
  border-radius: 18px;
  background: linear-gradient(140deg, #155d86, #1678aa 56%, #2568ac);
  box-shadow: 0 10px 27px rgba(17, 117, 171, .23);
}
.login-emblem svg { width: 35px; fill: #e5fbff; }
.login-emblem .emblem-cut { fill: #1e7095; }
.login-emblem circle { fill: #8ef3f2; }
.eyebrow, .panel-kicker { margin: 0; color: #83bacb; font-size: 9px; font-weight: 780; letter-spacing: .16em; line-height: 1.4; }
.login-card h1 { margin: 12px 0 13px; font-size: clamp(31px, 5vw, 39px); font-weight: 710; letter-spacing: -.055em; line-height: 1.1; }
.login-card h1 em { color: var(--cyan); font-style: normal; }
.login-description { margin: 0 0 27px; color: #9eb0c2; font-size: 13px; line-height: 1.7; }
.login-form { display: grid; gap: 9px; }
.login-form label { margin-top: 2px; color: #c5d2dd; font-size: 11px; font-weight: 670; }
.login-form input {
  width: 100%;
  height: 47px;
  border: 1px solid rgba(149, 183, 209, .19);
  border-radius: 12px;
  padding: 0 14px;
  color: #f3f8fc;
  background: rgba(4, 16, 29, .7);
  font-size: 13px;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.login-form input::placeholder { color: #637c92; }
.login-form input:hover { border-color: rgba(149, 183, 209, .32); }
.login-form input:focus { border-color: rgba(115, 228, 239, .72); background: rgba(4, 16, 29, .92); box-shadow: 0 0 0 3px rgba(91, 202, 220, .1); outline: 0; }
.button-primary {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: 12px;
  color: #062032;
  background: linear-gradient(105deg, #84edf0, #62c8e5 68%, #72b7eb);
  box-shadow: 0 9px 25px rgba(63, 176, 210, .19), inset 0 1px rgba(255, 255, 255, .44);
  font-size: 12px;
  font-weight: 790;
  cursor: pointer;
  transition: transform .18s ease, filter .18s ease, box-shadow .18s ease;
}
.button-primary:hover { transform: translateY(-1px); filter: brightness(1.06); box-shadow: 0 13px 31px rgba(63, 176, 210, .26), inset 0 1px rgba(255, 255, 255, .5); }
.button-primary:active { transform: translateY(0); }
.button-primary:disabled { opacity: .62; cursor: wait; transform: none; }
.login-submit { width: 100%; margin-top: 9px; }
.login-submit svg { width: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.form-error { margin: 2px 0 0; color: var(--danger); font-size: 12px; line-height: 1.5; }
.login-foot { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 20px; color: #8096a9; font-size: 10px; }
.secure-dot { width: 6px; height: 6px; border-radius: 50%; background: #61d5ad; box-shadow: 0 0 10px rgba(97, 213, 173, .52); }
.login-footer { position: absolute; bottom: 24px; display: flex; gap: 8px; align-items: center; color: #668096; font-size: 9px; font-weight: 670; letter-spacing: .08em; }
.login-footer span:first-child { color: #86a4ba; }

.workspace { width: min(100% - 48px, 1500px); margin: 0 auto; padding: 24px 0 21px; animation: page-arrive .45s ease both; }
@keyframes page-arrive { from { opacity: 0; } to { opacity: 1; } }
.topbar { display: flex; min-height: 46px; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(159, 190, 213, .13); padding: 0 2px 16px; }
.topbar-right { display: flex; align-items: center; gap: 19px; }
.workspace-context { display: flex; align-items: center; gap: 9px; color: #b2c1cf; font-size: 11px; font-weight: 560; }
.context-icon { display: grid; width: 25px; height: 25px; place-items: center; border: 1px solid rgba(109, 206, 216, .2); border-radius: 8px; color: #8de4e8; background: rgba(42, 112, 139, .18); font-size: 8px; font-weight: 800; letter-spacing: .04em; }
.icon-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent; border-radius: 10px; color: #8ea3b8; background: transparent; font-size: 10px; font-weight: 680; cursor: pointer; transition: color .18s ease, border-color .18s ease, background .18s ease; }
.icon-button:hover { border-color: var(--line); color: var(--ink); background: rgba(255,255,255,.035); }
.icon-button svg { width: 17px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.logout-button { min-height: 32px; padding: 0 7px; }
.workspace-intro { display: flex; align-items: end; justify-content: space-between; gap: 20px; padding: 25px 2px 21px; }
.workspace-intro .eyebrow { color: #7c9bb1; }
.intro-note { max-width: 290px; margin: 0 0 2px; color: #839aae; font-size: 11px; line-height: 1.6; text-align: right; }
.workspace-grid { position: relative; display: grid; grid-template-columns: minmax(220px, .78fr) minmax(0, 2.53fr) 48px; align-items: stretch; gap: 15px; }
.results-expanded .workspace-grid { grid-template-columns: minmax(220px, .78fr) minmax(0, 1.58fr) minmax(280px, .95fr); }
.panel { min-width: 0; border: 1px solid var(--line); border-radius: var(--radius-xl); background: linear-gradient(150deg, rgba(14, 34, 57, .94), rgba(9, 26, 45, .94)); box-shadow: 0 16px 45px rgba(0, 0, 0, .13), inset 0 1px rgba(255,255,255,.025); }
.guide-panel { display: flex; min-height: 690px; flex-direction: column; padding: 20px 20px 16px; overflow: hidden; }
.panel-kicker { color: #759ab2; font-size: 8px; letter-spacing: .145em; }
.guide-panel > .panel-kicker { display: flex; align-items: center; gap: 7px; }
.live-pip, .provider-light { width: 6px; height: 6px; flex: 0 0 auto; border-radius: 50%; background: #64d8b3; box-shadow: 0 0 11px rgba(100, 216, 179, .48); }
.avatar-stage { position: relative; display: grid; min-height: 233px; margin: 17px -10px 1px; place-items: center; overflow: hidden; }
.avatar-stage::before { position: absolute; width: 199px; height: 199px; border: 1px solid rgba(105, 213, 228, .2); border-radius: 50%; background: radial-gradient(circle, rgba(41, 109, 150, .35) 0, rgba(17, 54, 84, .12) 62%, transparent 68%); box-shadow: 0 0 46px rgba(38, 140, 183, .13), inset 0 0 25px rgba(87, 195, 220, .06); content: ""; }
.avatar-stage::after { position: absolute; width: 226px; height: 226px; border: 1px dashed rgba(122, 203, 221, .1); border-radius: 50%; content: ""; animation: orbit-slow 33s linear infinite; }
@keyframes orbit-slow { to { transform: rotate(360deg); } }
.guide-avatar-svg { position: relative; z-index: 1; width: 225px; max-width: 100%; overflow: visible; filter: drop-shadow(0 16px 16px rgba(0, 0, 0, .18)); }
.guide-panel h2 { margin: 3px 0 6px; font-size: 18px; font-weight: 680; letter-spacing: -.035em; text-align: center; }
.guide-copy { max-width: 230px; margin: 0 auto; color: #95aabd; font-size: 11px; line-height: 1.65; text-align: center; }
.guide-state { display: flex; min-height: 34px; align-items: center; justify-content: center; gap: 7px; margin: 15px 0 14px; border: 1px solid rgba(126, 181, 205, .13); border-radius: 10px; color: #b1c4d2; background: rgba(6, 19, 33, .42); font-size: 10px; font-weight: 610; }
.state-indicator { width: 6px; height: 6px; border-radius: 50%; background: #81d5b8; box-shadow: 0 0 8px rgba(129, 213, 184, .37); }
.guide-panel[data-state="listening"] .state-indicator { background: #72d9f0; box-shadow: 0 0 11px rgba(114, 217, 240, .75); }
.guide-panel[data-state="thinking"] .state-indicator { background: #f3c876; box-shadow: 0 0 10px rgba(243, 200, 118, .53); animation: status-pulse .9s ease-in-out infinite alternate; }
.guide-panel[data-state="speaking"] .state-indicator { background: #8debd9; box-shadow: 0 0 11px rgba(141, 235, 217, .73); }
.guide-panel[data-state="error"] .state-indicator { background: #ff8585; box-shadow: 0 0 10px rgba(255, 133, 133, .53); }
@keyframes status-pulse { to { opacity: .38; } }
.state-detail { max-width: 110px; overflow: hidden; color: #6f899e; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.question-library { grid-column: 1 / -1; margin-top: 2px; border-top: 1px solid rgba(151, 181, 205, .12); }
.question-library-title { margin: 13px 0 5px; color: #bad0df; font-size: 11px; font-weight: 650; }
.question-library-hint { margin: 0 0 9px; color: #829bad; font-size: 10px; line-height: 1.5; }
.question-category { border-bottom: 1px solid rgba(151, 181, 205, .1); }
.question-category summary { display: flex; min-height: 42px; align-items: center; gap: 9px; padding: 6px 2px; color: #b4c8d7; cursor: pointer; list-style: none; font-size: 11px; }
.question-category summary::-webkit-details-marker { display: none; }
.question-category summary::after { content: ""; width: 6px; height: 6px; margin: 0 3px 2px 2px; border-right: 1px solid currentColor; border-bottom: 1px solid currentColor; transform: rotate(45deg); }
.question-category[open] summary::after { margin-top: 5px; transform: rotate(225deg); }
.question-category[open] summary { color: var(--cyan); }
.question-category summary:hover, .library-question:hover { color: #e2f7ff; background: rgba(75, 167, 191, .07); }
.question-category summary:focus-visible, .library-question:focus-visible { outline: 2px solid var(--cyan); outline-offset: -2px; border-radius: 6px; }
.question-category-icon { width: 19px; height: 19px; flex: 0 0 auto; fill: none; stroke: #79cadb; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.question-category-label { flex: 1; }
.question-category-count { min-width: 20px; padding: 2px 4px; border-radius: 5px; color: #87aabb; background: rgba(91, 163, 185, .09); text-align: center; font-size: 9px; font-variant-numeric: tabular-nums; }
.question-category-items { display: grid; max-height: 270px; gap: 3px; overflow-y: auto; padding: 0 3px 8px 27px; scrollbar-width: thin; scrollbar-color: rgba(112, 151, 176, .3) transparent; }
.library-question { width: 100%; min-height: 40px; border: 0; border-bottom: 1px solid rgba(151, 181, 205, .06); border-radius: 5px; padding: 9px 7px; color: #adc1d0; background: transparent; font: inherit; font-size: 11px; line-height: 1.55; text-align: left; overflow-wrap: anywhere; cursor: pointer; }

.provider-note { display: flex; align-items: center; gap: 7px; margin-top: auto; padding-top: 15px; color: #6f8799; font-size: 9px; }
.provider-light { width: 5px; height: 5px; background: #65bbd8; box-shadow: none; }

.conversation-panel { display: flex; min-height: 690px; flex-direction: column; padding: 21px 21px 14px; }
.conversation-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-bottom: 15px; border-bottom: 1px solid rgba(151, 181, 205, .12); }
.conversation-header h2 { margin: 5px 0 0; font-size: 16px; font-weight: 660; letter-spacing: -.025em; }
.quiet-toggle { display: inline-flex; align-items: center; gap: 7px; border: 0; padding: 5px 0 5px 6px; color: #8198ab; background: transparent; font-size: 9px; cursor: pointer; }
.quiet-toggle[aria-pressed="true"] { color: #c3d3de; }
.toggle-track { position: relative; width: 26px; height: 15px; border: 1px solid rgba(146, 174, 196, .21); border-radius: 9px; background: rgba(4, 16, 28, .74); transition: background .2s ease; }
.toggle-track span { position: absolute; top: 2px; left: 2px; width: 9px; height: 9px; border-radius: 50%; background: #74899b; transition: transform .2s ease, background .2s ease; }
.quiet-toggle[aria-pressed="true"] .toggle-track { border-color: rgba(95, 194, 207, .43); background: rgba(56, 149, 171, .3); }
.quiet-toggle[aria-pressed="true"] .toggle-track span { transform: translateX(11px); background: #84e8e9; }
.message-list { display: flex; min-height: 255px; max-height: 360px; flex: 1 1 auto; flex-direction: column; gap: 15px; overflow: auto; padding: 21px 3px 17px; scrollbar-color: rgba(112, 151, 176, .24) transparent; scrollbar-width: thin; }
.welcome-message, .chat-message { display: flex; max-width: 94%; align-items: flex-start; gap: 10px; animation: message-arrive .28s var(--ease) both; }
@keyframes message-arrive { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.message-avatar-mark { display: grid; width: 25px; height: 25px; flex: 0 0 auto; place-items: center; border: 1px solid rgba(113, 207, 218, .24); border-radius: 9px; color: #a4f0ef; background: linear-gradient(140deg, #185577, #132f4c); font-size: 11px; font-weight: 760; }
.message-content { min-width: 0; }
.message-content p { margin: 0; color: #d4e0e8; font-size: 12px; line-height: 1.72; white-space: pre-wrap; overflow-wrap: anywhere; }
.message-time { display: block; margin-top: 7px; color: #647d92; font-size: 9px; }
.chat-message.user { align-self: flex-end; flex-direction: row-reverse; }
.chat-message.user .message-content { max-width: calc(100% - 36px); border: 1px solid rgba(105, 168, 210, .17); border-radius: 14px 3px 14px 14px; padding: 10px 12px; background: linear-gradient(130deg, rgba(26, 75, 111, .58), rgba(20, 57, 91, .52)); }
.chat-message.user .message-avatar-mark { border-color: rgba(127, 167, 198, .2); color: #c6d6e4; background: rgba(86, 115, 143, .2); }
.chat-message.assistant .message-content { border: 1px solid rgba(122, 173, 197, .1); border-radius: 3px 13px 13px 13px; padding: 10px 12px; background: rgba(6, 19, 33, .28); }
.chat-message.error .message-content { border-color: rgba(239, 124, 124, .26); }
.chat-message.error .message-content p { color: #ffc1c1; }
.chat-message .message-time { margin-top: 6px; }
.analysis-text h3, .analysis-text h4 { margin: 14px 0 7px; color: #ddf5fa; font-size: 13px; line-height: 1.5; }
.analysis-text h3:first-child, .analysis-text h4:first-child { margin-top: 0; }
.analysis-text p, .analysis-text ul, .analysis-text ol { margin: 7px 0; font-size: 11px; line-height: 1.75; }
.analysis-text ul, .analysis-text ol { padding-left: 18px; }
.analysis-text li { margin-bottom: 6px; }
.suggestions { padding: 0 0 13px; }
.suggestion-heading { display: flex; align-items: center; gap: 9px; margin-bottom: 9px; color: #758da1; font-size: 9px; font-weight: 620; }
.suggestion-rule { height: 1px; flex: 1; background: rgba(151, 181, 205, .1); }
.suggestion-list { display: flex; flex-wrap: wrap; gap: 6px; }
.suggestion-chip { min-height: 28px; border: 1px solid rgba(125, 174, 202, .18); border-radius: 9px; padding: 5px 9px; color: #a8c0d1; background: rgba(11, 32, 52, .56); font-size: 9px; line-height: 1.35; text-align: left; cursor: pointer; transition: border-color .18s ease, color .18s ease, background .18s ease, transform .18s ease; }
.suggestion-chip:hover { transform: translateY(-1px); border-color: rgba(111, 221, 229, .4); color: #e0fafa; background: rgba(22, 70, 92, .5); }
.role-picker { display: flex; min-height: 31px; align-items: center; justify-content: flex-end; gap: 8px; margin: -4px 1px 9px; }
.role-picker label { color: #758da1; font-size: 9px; }
.role-picker select { max-width: 160px; min-height: 28px; border: 1px solid rgba(125, 174, 202, .18); border-radius: 8px; padding: 4px 25px 4px 8px; color: #a8c0d1; background: #0b2034; font: inherit; font-size: 9px; }
.knowledge-note { margin: 8px 0 0; color: #6f899e; font-size: 8px; line-height: 1.5; }
.composer { display: flex; min-height: 59px; align-items: flex-end; gap: 10px; border: 1px solid rgba(127, 178, 206, .21); border-radius: 15px; padding: 9px 9px 9px 13px; background: rgba(5, 18, 32, .76); transition: border-color .2s ease, box-shadow .2s ease; }
.composer:focus-within { border-color: rgba(111, 221, 229, .52); box-shadow: 0 0 0 3px rgba(91, 202, 220, .07); }
.composer textarea { width: 100%; min-height: 38px; max-height: 125px; resize: none; border: 0; outline: 0; padding: 9px 0; color: #e7f0f6; background: transparent; font-size: 11px; line-height: 1.5; }
.composer textarea::placeholder { color: #687f93; }
.send-button { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; border: 0; border-radius: 11px; color: #082137; background: linear-gradient(135deg, #8ae9eb, #65c6e7); box-shadow: 0 5px 14px rgba(62, 174, 202, .17); cursor: pointer; transition: filter .16s ease, transform .16s ease; }
.send-button:hover { transform: translateY(-1px); filter: brightness(1.08); }
.send-button:disabled { opacity: .45; cursor: wait; transform: none; }
.send-button svg { width: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.chat-error { margin: 8px 2px 0; color: var(--danger); font-size: 10px; line-height: 1.5; }
.action-notice { margin: 8px 2px 0; color: #8fe2c3; font-size: 10px; line-height: 1.5; }
.action-notice[data-tone="info"] { color: #8fdbe9; }
.action-notice[data-tone="error"] { color: var(--danger); }
.conversation-controls { display: flex; min-height: 37px; align-items: center; justify-content: space-between; gap: 10px; padding-top: 8px; }
.voice-controls { display: flex; flex-wrap: wrap; gap: 5px; }
.control-button, .interrupt-button { display: inline-flex; min-height: 27px; align-items: center; justify-content: center; gap: 6px; border: 1px solid transparent; border-radius: 8px; padding: 4px 7px; color: #8299ad; background: transparent; font-size: 9px; font-weight: 590; cursor: pointer; transition: color .17s ease, background .17s ease, border-color .17s ease; }
.control-button:hover:not(:disabled), .interrupt-button:hover:not(:disabled) { border-color: var(--line); color: #c9d9e4; background: rgba(255, 255, 255, .035); }
.control-button:disabled, .interrupt-button:disabled { opacity: .38; cursor: not-allowed; }
.control-button svg, .interrupt-button svg { width: 15px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.control-connect { color: #80dbe2; }
.control-connect[aria-pressed="true"] { border-color: rgba(102, 208, 195, .21); color: #9de9d1; background: rgba(59, 145, 133, .12); }
.control-button[aria-pressed="true"] { border-color: rgba(107, 214, 223, .26); color: #a3edf0; background: rgba(36, 126, 147, .16); }
.interrupt-button { color: #8594a3; }
.interrupt-button:not(:disabled) { color: #e5a9a9; }
.interrupt-button svg { width: 13px; }
.privacy-note { display: flex; align-items: center; gap: 6px; margin: 5px 1px 0; color: #667f93; font-size: 9px; }
.privacy-note svg { width: 13px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.mic-device-control { display: grid; grid-template-columns: minmax(88px, .4fr) minmax(0, 1fr); align-items: center; gap: 8px; margin: 8px 1px 0; color: #8299ad; font-size: 9px; }
.mic-device-control[hidden] { display: none; }
.mic-device-control select { width: 100%; min-width: 0; border: 1px solid rgba(134, 177, 202, .17); border-radius: 8px; padding: 6px 8px; color: #c8d9e4; background: rgba(5, 18, 32, .55); font: inherit; }
.mic-device-control select:disabled { opacity: .65; }

.results-panel { min-height: 690px; padding: 19px 18px 14px; }
.results-panel details { min-height: 100%; }
.results-summary { display: flex; min-height: 44px; align-items: center; justify-content: space-between; gap: 10px; list-style: none; cursor: pointer; border-radius: 8px; }
.results-summary:focus-visible { outline: 2px solid var(--accent, #67e6f4); outline-offset: 3px; }
.results-summary::-webkit-details-marker { display: none; }
.results-rail-icon { display: none; width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.results-panel:has(details:not([open])) { padding: 8px 1px; }
.results-panel details:not([open]) .results-summary { justify-content: center; gap: 0; }
.results-panel details:not([open]) .results-summary-label,
.results-panel details:not([open]) .disclosure-chevron { display: none; }
.results-panel details:not([open]) .results-rail-icon { display: block; }
.results-panel details:not([open]) .results-body { display: none; }
.results-heading { display: block; margin-top: 5px; color: #e8f1f6; font-size: 15px; font-weight: 665; letter-spacing: -.025em; }
.disclosure-chevron { display: block; flex: 0 0 17px; width: 17px; fill: none; stroke: #87a0b5; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; transform: rotate(90deg); }
.results-body { display: flex; flex-direction: column; min-height: 614px; }
.data-overview { display: grid; grid-template-columns: 1fr 1px 1fr; align-items: center; gap: 14px; margin: 16px 0 18px; border: 1px solid rgba(125, 171, 197, .12); border-radius: 13px; padding: 11px 12px; background: rgba(5, 18, 32, .4); }
.data-overview div { min-width: 0; }
.overview-label { display: block; color: #7b93a7; font-size: 9px; }
.data-overview strong { display: block; margin-top: 4px; color: #cde1ec; font-size: 17px; font-variant-numeric: tabular-nums; font-weight: 660; letter-spacing: -.03em; }
.overview-divider { height: 29px; background: rgba(144, 176, 199, .15); }
.results-heading-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.results-heading-row h3, .facets-section h3, .actions-section h3, .sources-section h3, .warnings-section h3 { margin: 0; color: #b9cbd7; font-size: 10px; font-weight: 660; }
.result-count { color: #6ed6de; font-size: 9px; font-variant-numeric: tabular-nums; }
.results-message { margin: 9px 0 10px; color: #768da0; font-size: 10px; line-height: 1.55; }
.result-list { display: grid; gap: 7px; }
.summary-table-wrap { width: 100%; max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; }
.summary-table { width: 100%; min-width: 360px; border-collapse: collapse; color: #d4e2eb; font-size: 9px; line-height: 1.45; }
.summary-table th, .summary-table td { border-bottom: 1px solid rgba(134, 177, 202, .13); padding: 8px 9px; overflow-wrap: anywhere; text-align: left; vertical-align: top; }
.summary-table th { color: #8fa9ba; font-weight: 650; }
.summary-table td { color: #c5d7e2; }
.result-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px; width: 100%; border: 1px solid rgba(134, 177, 202, .13); border-radius: 12px; padding: 10px; color: inherit; background: rgba(10, 29, 48, .61); text-align: left; cursor: pointer; transition: border-color .18s ease, background .18s ease, transform .18s ease; }
.result-card:hover { transform: translateY(-1px); border-color: rgba(111, 221, 229, .38); background: rgba(15, 44, 66, .8); }
.result-main { min-width: 0; }
.result-name { display: block; overflow: hidden; color: #d7e6ee; font-size: 10px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.result-meta { display: flex; flex-wrap: wrap; gap: 3px 8px; margin-top: 5px; color: #7d96a9; font-size: 9px; line-height: 1.4; }
.result-meta span { overflow: hidden; max-width: 145px; text-overflow: ellipsis; white-space: nowrap; }
.result-score { display: grid; min-width: 32px; height: 32px; place-items: center; border: 1px solid rgba(103, 203, 211, .2); border-radius: 10px; color: #8ee4e6; background: rgba(36, 130, 147, .12); font-size: 9px; font-weight: 700; font-variant-numeric: tabular-nums; }
.facets-section, .actions-section, .sources-section, .warnings-section { margin-top: 18px; border-top: 1px solid rgba(151, 181, 205, .1); padding-top: 13px; }
.facet-list { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.facet-chip { max-width: 100%; overflow: hidden; border: 1px solid rgba(129, 172, 200, .14); border-radius: 7px; padding: 5px 7px; color: #93abbc; background: rgba(5, 18, 32, .35); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.action-list { display: grid; gap: 7px; margin-top: 9px; }
.action-button { display: flex; width: 100%; min-height: 35px; align-items: center; justify-content: space-between; gap: 7px; border: 1px solid rgba(101, 198, 209, .18); border-radius: 9px; padding: 7px 9px; color: #9ce2e7; background: rgba(27, 103, 122, .1); font-size: 9px; font-weight: 620; text-align: left; text-decoration: none; cursor: pointer; }
.action-button:hover { border-color: rgba(101, 220, 230, .4); background: rgba(27, 103, 122, .22); }
.action-button.is-disabled { opacity: .48; cursor: not-allowed; }
.action-button svg { width: 14px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.sources-section ul, .warnings-section ul { display: grid; gap: 6px; margin: 8px 0 0; padding-left: 15px; color: #7990a3; font-size: 9px; line-height: 1.55; }
.source-document-button { border: 0; padding: 0; color: #8fcdd5; background: transparent; font: inherit; text-align: left; text-decoration: underline; text-decoration-color: rgba(143, 205, 213, .35); text-underline-offset: 2px; cursor: pointer; }
.source-document-button:hover { color: #c1f3f2; }
.warnings-section li::marker { color: #e7bc74; }
.export-button { display: flex; min-height: 37px; align-items: center; justify-content: center; gap: 7px; margin-top: auto; border: 1px solid rgba(121, 179, 201, .2); border-radius: 10px; padding: 8px; color: #a6dce3; background: rgba(28, 92, 109, .12); font-size: 9px; font-weight: 670; text-decoration: none; text-align: center; transition: border-color .17s ease, background .17s ease; }
.export-button:not(.is-disabled):hover { border-color: rgba(112, 221, 229, .45); background: rgba(28, 92, 109, .25); }
.export-button svg { width: 15px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.export-button.is-disabled { opacity: .5; cursor: not-allowed; }
.facets-hint { display: flex; align-items: flex-start; gap: 7px; margin-top: 11px; color: #6e8598; font-size: 8px; line-height: 1.5; }
.hint-mark { display: grid; width: 13px; height: 13px; flex: 0 0 auto; place-items: center; border: 1px solid rgba(114, 176, 195, .25); border-radius: 50%; color: #83a8ba; font-family: Georgia, serif; font-size: 9px; font-style: italic; }
.workspace-footer { display: flex; justify-content: space-between; padding: 15px 3px 0; color: #506a80; font-size: 8px; font-weight: 650; letter-spacing: .1em; }
.footer-dot { margin: 0 3px; color: #6f9ab0; }
.workspace-footer span:last-child { font-size: 9px; font-weight: 450; letter-spacing: 0; }

.workspace-mode-tabs { display: flex; flex: 0 0 auto; align-items: center; gap: 6px; margin: 0 0 12px; border-bottom: 1px solid var(--line); padding-bottom: 9px; }
.workspace-mode-tab { min-height: 34px; border: 1px solid transparent; border-radius: 9px; padding: 7px 11px; color: var(--muted); background: transparent; font: inherit; font-size: 10px; font-weight: 650; cursor: pointer; }
.workspace-mode-tab:hover { border-color: var(--line); color: var(--ink); }
.workspace-mode-tab[aria-selected="true"] { border-color: var(--line-strong); color: var(--ink); background: var(--panel-soft); }
.results-panel.workspace-tabs-active { display: flex; flex-direction: column; min-height: 0; padding: 13px; }
.workspace-right-pane { min-width: 0; min-height: 0; flex: 1 1 auto; }
.results-panel.workspace-tabs-active #recordsPane { overflow: auto; }
.results-panel.workspace-tabs-active #resultsDisclosure { min-height: 100%; }
.results-panel.workspace-tabs-active #resultsDisclosure:not([open]) .results-summary { justify-content: flex-start; }
.results-panel.workspace-tabs-active #resultsDisclosure:not([open]) .results-summary-label,
.results-panel.workspace-tabs-active #resultsDisclosure:not([open]) .disclosure-chevron { display: block; }
.results-panel.workspace-tabs-active #resultsDisclosure:not([open]) .results-rail-icon { display: none; }
.workspace-pane-header { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 5px 2px 14px; }
.workspace-pane-header h2, .desktop-workspace-heading h2 { margin: 5px 0 0; color: var(--ink); font-size: 17px; font-weight: 680; letter-spacing: -.025em; }
.answer-details-content { overflow: auto; max-height: calc(100% - 56px); padding: 15px 3px 20px; color: var(--ink); font-size: 13px; line-height: 1.7; overflow-wrap: anywhere; white-space: pre-wrap; }
.answer-details-content h1, .answer-details-content h2, .answer-details-content h3 { color: var(--ink); line-height: 1.35; }
.answer-details-content table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; font-size: 11px; }
.answer-details-content th, .answer-details-content td { border: 1px solid var(--line); padding: 7px 9px; text-align: left; vertical-align: top; }
.desktop-workspace { display: flex; flex-direction: column; gap: 10px; }
.desktop-workspace-header { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); padding: 2px 2px 11px; }
.desktop-session-meta { display: flex; align-items: center; gap: 7px; margin: 6px 0 0; color: var(--muted); font-size: 10px; }
.desktop-account { color: var(--muted); font-size: 10px; margin: 4px 0 0; }
.desktop-workspace-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; }
.desktop-control-button, .desktop-launch-button { min-height: 36px; border: 1px solid var(--line-strong); border-radius: 9px; padding: 7px 11px; color: var(--ink); background: var(--panel-soft); font: inherit; font-size: 10px; font-weight: 650; cursor: pointer; }
.desktop-control-button:hover, .desktop-launch-button:hover { filter: brightness(1.06); }
.desktop-control-button:disabled, .desktop-launch-button:disabled { cursor: wait; opacity: .58; }
.desktop-control-button[hidden] { display: none; }
.desktop-quick-stop { display: none; }
.desktop-stop-button { border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); color: var(--danger); }
.desktop-close-button { color: var(--muted); }
.desktop-session-message { flex: 0 0 auto; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; color: var(--muted); background: var(--panel-soft); font-size: 10px; line-height: 1.5; }
.desktop-session-message[data-tone="error"] { color: var(--danger); }
.desktop-screen { position: relative; display: grid; min-width: 0; min-height: 280px; flex: 1 1 auto; place-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: #0b111a; outline-offset: 2px; }
.desktop-screen img { display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; touch-action: none; }
.desktop-screen img[hidden] { display: none; }
.desktop-placeholder { display: grid; max-width: 420px; gap: 10px; justify-items: center; padding: 22px; color: #c4cfdb; text-align: center; font-size: 12px; line-height: 1.55; }
.desktop-placeholder p { margin: 0; }
.desktop-placeholder[hidden] { display: none; }
.desktop-launch-button { color: #081527; background: var(--cyan); }
.settings-range-field { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 7px 12px; }
.settings-range-field input { grid-column: 1 / -1; height: 28px; min-height: 28px; padding: 0; accent-color: var(--cyan); }
.settings-range-field output { grid-column: 2; grid-row: 1; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.desktop-active.workspace { width: min(100% - 20px, 1920px); padding: 10px 0; }
.desktop-active .workspace-intro, .desktop-active .workspace-footer { display: none; }
.desktop-active .workspace-grid { height: calc(100dvh - 78px); min-height: 500px; grid-template-columns: 72px minmax(300px, 340px) minmax(0, 1fr); gap: 11px; }
.desktop-active .guide-panel { min-height: 0; align-items: center; padding: 12px 5px; }
.desktop-active .guide-panel > :not(.guide-rail-mark) { display: none !important; }
.guide-rail-mark { display: none; width: 40px; height: 40px; place-items: center; border: 1px solid var(--line-strong); border-radius: 12px; color: var(--cyan); font-size: 10px; font-weight: 800; letter-spacing: .04em; }
.desktop-active .guide-rail-mark { display: grid; }
.desktop-active .conversation-panel { min-height: 0; padding: 16px 15px 11px; }
.desktop-active .message-list { min-height: 100px; max-height: none; }
.desktop-active .results-panel { min-height: 0; padding: 12px; overflow: hidden; }
.desktop-active .results-panel.workspace-tabs-active { padding: 10px; }
.desktop-active .results-panel.workspace-tabs-active .desktop-workspace { min-height: 0; }
.desktop-active .results-panel.workspace-tabs-active .desktop-screen { min-height: 250px; }
.desktop-active .results-panel.workspace-tabs-active .workspace-mode-tabs { margin-bottom: 8px; }
@media (max-width: 1120px) and (min-width: 721px) {
  .desktop-active.workspace { width: calc(100% - 18px); }
  .desktop-active .workspace-grid { grid-template-columns: 58px minmax(280px, 315px) minmax(0, 1fr); gap: 8px; }
}
@media (max-width: 720px) {
  .workspace-mode-tabs { overflow-x: auto; }
  .workspace-mode-tab { min-height: 40px; flex: 0 0 auto; }
  .results-panel.workspace-tabs-active { padding: 9px; }
  .desktop-workspace-header { align-items: flex-start; flex-direction: column; }
  .desktop-workspace-controls { width: 100%; justify-content: flex-start; }
  .desktop-control-button, .desktop-launch-button { min-height: 42px; padding: 9px 12px; }
  .desktop-screen { min-height: 38dvh; }
  .desktop-active.workspace { width: calc(100% - 20px); padding-top: 10px; }
  .desktop-active .workspace-intro, .desktop-active .workspace-footer { display: none; }
  .desktop-active .workspace-grid { display: flex; height: auto; min-height: 0; flex-direction: column; gap: 10px; }
  .desktop-active .guide-panel { display: none; }
  .desktop-active .conversation-panel { order: 0; min-height: 0; max-height: 55dvh; padding: 12px; }
  .desktop-active .conversation-header { padding-bottom: 9px; }
  .desktop-active .message-list { min-height: 70px; max-height: 19dvh; padding: 10px 2px; }
  .desktop-active .suggestions, .desktop-active .role-picker, .desktop-active .privacy-note, .desktop-active #micDeviceControl { display: none; }
  .desktop-active .conversation-controls { flex-wrap: wrap; }
  .desktop-active .desktop-quick-stop:not([hidden]) { display: inline-flex; }
  .desktop-active .results-panel { order: 1; min-height: 68dvh; padding: 8px; }
  .desktop-active .results-panel.workspace-tabs-active { min-height: 68dvh; overflow: visible; }
  .desktop-active .results-panel.workspace-tabs-active .desktop-screen { min-height: 48dvh; }
}

.modal-backdrop { position: fixed; z-index: 30; inset: 0; display: grid; place-items: center; overflow-y: auto; padding: 22px; background: rgba(1, 9, 17, .75); backdrop-filter: blur(10px); animation: modal-fade .18s ease both; }
@keyframes modal-fade { from { opacity: 0; } to { opacity: 1; } }
.lead-modal { width: min(100%, 720px); max-height: min(85vh, 820px); overflow: hidden; border: 1px solid rgba(134, 191, 212, .25); border-radius: 22px; background: linear-gradient(148deg, #102943, #0a1d32); box-shadow: 0 30px 100px rgba(0,0,0,.5); }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid rgba(151, 181, 205, .13); padding: 19px 21px 15px; }
.modal-header h2 { margin: 5px 0 0; color: #eff7fa; font-size: 17px; font-weight: 670; letter-spacing: -.03em; }
.modal-close { width: 31px; height: 31px; border-color: var(--line); }
.lead-modal-content { max-height: calc(min(85vh, 820px) - 75px); overflow: auto; padding: 18px 21px 22px; scrollbar-color: rgba(112, 151, 176, .3) transparent; scrollbar-width: thin; }
.modal-loading, .modal-empty { color: #96adbf; font-size: 12px; line-height: 1.6; }
.lead-field-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.lead-field-group { min-width: 0; border: 1px solid rgba(131, 178, 199, .13); border-radius: 13px; padding: 12px; background: rgba(5, 18, 32, .33); }
.lead-field-group h3 { margin: 0 0 10px; color: #8acbd4; font-size: 9px; font-weight: 730; letter-spacing: .09em; text-transform: uppercase; }
.lead-field { display: grid; grid-template-columns: minmax(90px, .8fr) minmax(0, 1.2fr); gap: 10px; border-top: 1px solid rgba(151, 181, 205, .08); padding: 7px 0; }
.lead-field:first-of-type { border-top: 0; padding-top: 0; }
.lead-field dt { color: #8299ac; font-size: 9px; line-height: 1.5; overflow-wrap: anywhere; }
.lead-field dd { min-width: 0; margin: 0; color: #d4e2eb; font-size: 10px; line-height: 1.5; overflow-wrap: anywhere; white-space: pre-wrap; }
.lead-flags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 14px; }
.lead-flag { border: 1px solid rgba(112, 193, 188, .22); border-radius: 8px; padding: 6px 8px; color: #8ce0c2; background: rgba(49, 126, 110, .11); font-size: 9px; }
.lead-flag.unavailable { border-color: rgba(151, 181, 205, .12); color: #92a3b2; background: rgba(95, 114, 132, .1); }
.visit-prep-button { display: flex; width: 100%; min-height: 39px; align-items: center; justify-content: center; margin: 0 0 14px; border: 1px solid rgba(101, 198, 209, .27); border-radius: 10px; padding: 8px 11px; color: #a9edf0; background: rgba(27, 103, 122, .18); font-size: 10px; font-weight: 660; cursor: pointer; }
.visit-prep-button:hover { border-color: rgba(101, 220, 230, .48); background: rgba(27, 103, 122, .3); }
.knowledge-document-text { margin: 0; color: #d4e2eb; font: inherit; font-size: 11px; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.lead-media-section { margin-top: 17px; border-top: 1px solid rgba(151, 181, 205, .13); padding-top: 14px; }
.lead-media-section h3 { margin: 0 0 10px; color: #aac0ce; font-size: 11px; font-weight: 660; }
.lead-images { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.lead-images img { width: 100%; aspect-ratio: 4 / 3; border: 1px solid rgba(151, 181, 205, .17); border-radius: 10px; object-fit: cover; background: rgba(4, 15, 27, .5); }
.lead-review { border-left: 2px solid rgba(111, 207, 216, .4); padding: 2px 0 2px 10px; color: #bbcbd5; font-size: 10px; line-height: 1.6; }
.lead-review + .lead-review { margin-top: 10px; }
.lead-review-meta { display: block; margin-top: 4px; color: #8199ac; font-size: 9px; }

.guide-avatar-svg #avatar-body { transform-origin: 130px 210px; animation: breathe 4.2s ease-in-out infinite; }
.guide-avatar-svg .avatar-head { transform-origin: 130px 122px; transform: rotate(var(--head-turn, 0deg)); transition: transform 2.3s ease-in-out; }
.guide-avatar-svg .avatar-eyelids { transform: scaleY(0); transform-box: fill-box; transform-origin: center; transition: transform .08s ease-out; }
.guide-avatar-svg .avatar-eyelids ellipse { transform-origin: center; }
.guide-avatar-svg .avatar-mouth { transform-origin: 130px 150px; }
.guide-avatar-svg #avatar-mouth-open { transition: opacity .07s linear; }
.guide-avatar-svg #avatar-mouth-closed, .guide-avatar-svg #avatar-mouth-line, .guide-avatar-svg #avatar-mouth-teeth { transition: opacity .08s linear; }
.guide-avatar-svg #avatar-body path { transform-box: fill-box; }
.avatar-stage[data-state="listening"] .guide-avatar-svg .avatar-head { transform: rotate(calc(var(--head-turn, 0deg) - 1.2deg)); }
.avatar-stage[data-state="thinking"] .guide-avatar-svg .avatar-head { transform: rotate(calc(var(--head-turn, 0deg) + 1.2deg)); }
.avatar-stage.is-blinking .guide-avatar-svg .avatar-eyelids { transform: scaleY(1); }
.avatar-stage.is-voicing .guide-avatar-svg #avatar-mouth-open { filter: drop-shadow(0 0 2px rgba(255, 159, 150, .44)); }
@keyframes breathe { 0%, 100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-1.7px) scale(1.008, 1.012); } }

.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; clip-path: inset(50%) !important; }

@media (min-width: 1400px) {
  .workspace { padding-top: 28px; }
  .workspace-grid { gap: 18px; }
  .guide-panel, .conversation-panel, .results-panel { min-height: 720px; }
  .message-list { max-height: 390px; }
}
@media (max-width: 1120px) {
  .workspace { width: min(100% - 36px, 960px); }
  .workspace-grid { grid-template-columns: minmax(215px, .76fr) minmax(0, 1.55fr) 48px; }
  .results-expanded .workspace-grid { grid-template-columns: minmax(215px, .76fr) minmax(0, 1.55fr) 48px; }
  .guide-panel { min-height: 680px; }
  .conversation-panel { min-height: 680px; }
  .results-panel { min-height: 680px; }
  .results-expanded .results-panel { position: absolute; z-index: 20; top: 0; right: 0; bottom: 0; width: min(360px, 75%); overflow-y: auto; }
  .results-body { min-height: unset; }
  .export-button { margin-top: 18px; }
}
@media (max-width: 720px) {
  body { background: radial-gradient(ellipse at 50% 0%, rgba(22, 76, 119, .24), transparent 32rem), #071527; }
  .login-screen { padding: 18px; }
  .login-top { top: 19px; right: 18px; left: 18px; }
  .brand-mark { width: 36px; height: 36px; }
  .brand-mark svg { width: 24px; }
  .login-card { margin-top: 63px; border-radius: 23px; padding: 28px 24px 23px; }
  .login-emblem { width: 48px; height: 48px; margin-bottom: 22px; border-radius: 16px; }
  .login-card h1 { font-size: 34px; }
  .login-footer { bottom: 15px; font-size: 8px; }
  .workspace { width: min(100% - 28px, 540px); padding-top: 15px; }
  .topbar { padding-bottom: 13px; }
  .topbar-right { gap: 9px; }
  .workspace-context { display: none; }
  .topbar .brand { gap: 8px; }
  .topbar .brand b { font-size: 13px; }
  .topbar .brand small { font-size: 9px; }
  .logout-button { font-size: 9px; }
  .workspace-intro { display: block; padding: 21px 2px 17px; }
  .intro-note { margin-top: 7px; text-align: left; font-size: 10px; }
  .workspace-grid { display: flex; flex-direction: column; gap: 11px; }
  .guide-panel { display: grid; grid-template-columns: minmax(0, 1fr) 112px; min-height: 0; padding: 16px 16px 13px; }
  .guide-panel > .panel-kicker { grid-column: 1 / -1; }
  .avatar-stage { grid-column: 2; grid-row: 2 / span 3; min-height: 133px; margin: 4px -11px 0 0; }
  .avatar-stage::before { width: 115px; height: 115px; }
  .avatar-stage::after { width: 131px; height: 131px; }
  .guide-avatar-svg { width: 143px; }
  .guide-panel h2 { align-self: end; margin: 16px 0 5px; text-align: left; font-size: 16px; }
  .guide-copy { grid-column: 1; align-self: start; max-width: 240px; margin: 0; text-align: left; }
  .guide-state { grid-column: 1 / -1; min-height: 31px; justify-content: flex-start; margin: 11px 0 9px; padding: 0 10px; }
  .provider-note { grid-column: 1 / -1; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(151, 181, 205, .08); }
  .conversation-panel { min-height: 590px; padding: 17px 15px 12px; }
  .conversation-header h2 { font-size: 15px; }
  .message-list { min-height: 235px; max-height: 360px; padding-top: 17px; }
  .role-picker { justify-content: space-between; margin-top: -2px; }
  .quiet-toggle { max-width: 124px; font-size: 8px; }
  .results-panel { min-height: auto; padding: 0 15px; }
  .results-panel:has(details:not([open])) { padding: 0 15px; }
  .results-expanded .results-panel { position: static; width: auto; overflow: visible; }
  .results-panel details:not([open]) .results-summary { justify-content: space-between; gap: 10px; }
  .results-panel details:not([open]) .results-summary-label,
  .results-panel details:not([open]) .disclosure-chevron { display: block; }
  .results-panel details:not([open]) .results-rail-icon { display: none; }
  .results-panel details { min-height: auto; }
  .results-summary { min-height: 65px; cursor: pointer; }
  .disclosure-chevron { transform: none; transition: transform .18s ease; }
  .results-panel details[open] .disclosure-chevron { transform: rotate(180deg); }
  .results-body { padding: 0 0 15px; }
  .results-panel details:not([open]) .results-body { display: none; }
  .data-overview { margin: 7px 0 16px; }
  .workspace-footer { padding: 12px 2px 0; font-size: 7px; }
  .workspace-footer span:last-child { font-size: 8px; }
  .lead-modal { max-height: 90vh; border-radius: 18px; }
  .lead-modal-content { max-height: calc(90vh - 75px); padding: 14px; }
  .lead-field-groups { grid-template-columns: 1fr; }
}
@media (max-width: 410px) {
  .login-card { padding: 25px 20px 21px; }
  .workspace { width: calc(100% - 22px); }
  .topbar-right { gap: 6px; }
  .topbar .language-switch { padding: 2px; }
  .topbar .language-option { min-width: 31px; height: 25px; }
  .conversation-controls { align-items: flex-start; }
  .voice-controls { gap: 1px; }
  .control-button, .interrupt-button { padding: 4px 5px; font-size: 8px; }
  .result-meta span { max-width: 112px; }
  .lead-field { grid-template-columns: minmax(75px, .8fr) minmax(0, 1.2fr); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.desktop-active.workspace .workspace-grid { grid-template-columns: 72px minmax(300px, 340px) minmax(0, 1fr); }
.desktop-active.workspace .results-panel { position: relative; top: auto; right: auto; bottom: auto; z-index: auto; width: auto; }
@media (max-width: 1120px) and (min-width: 721px) {
  .desktop-active.workspace .workspace-grid { grid-template-columns: 58px minmax(280px, 315px) minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .desktop-active.workspace .workspace-grid { display: flex; height: auto; min-height: 0; flex-direction: column; }
}
