:root {
  color-scheme: dark;
  --hy-bg: oklch(0% 0 0);
  --hy-panel: oklch(7% .008 270);
  --hy-panel-strong: oklch(11% .013 270);
  --hy-hover: oklch(17% .022 270);
  --hy-line: oklch(62% .055 280 / .25);
  --hy-text: oklch(96% .012 260);
  --hy-muted: oklch(76% .027 265);
  --hy-cyan: oklch(83% .15 205);
  --hy-blue: oklch(76% .15 270);
  --hy-violet: oklch(77% .18 315);
  --hy-pink: oklch(78% .19 350);
  --hy-green: oklch(83% .16 155);
  --hy-amber: oklch(87% .16 85);
  --hy-red: oklch(78% .15 25);
  --hy-glow: oklch(65% .2 310 / .16);
  --hy-spectrum: var(--hy-red) 0deg, var(--hy-pink) 45deg, var(--hy-violet) 90deg, var(--hy-blue) 145deg, var(--hy-cyan) 210deg, var(--hy-green) 260deg, var(--hy-amber) 320deg, var(--hy-red) 360deg;
  --hy-glass: linear-gradient(175deg, var(--hy-panel-strong), var(--hy-panel) 23%, var(--hy-bg) 72%, var(--hy-panel));
  --hy-mono: ui-monospace, SFMono-Regular, Consolas, monospace;
  --hy-shadow: 0 18px 58px oklch(0% 0 0 / .4);
  --hy-ease: cubic-bezier(.22, 1, .36, 1);
  --hy-rainbow: conic-gradient(from 0deg, var(--hy-cyan), var(--hy-blue), var(--hy-violet), var(--hy-pink), var(--hy-amber), var(--hy-green), var(--hy-cyan));
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}
:root[data-theme="light"] {
  color-scheme: light;
  --hy-bg: oklch(98% .009 265);
  --hy-panel: oklch(96% .014 265);
  --hy-panel-strong: oklch(100% 0 0);
  --hy-hover: oklch(92% .025 265);
  --hy-line: oklch(43% .05 275 / .27);
  --hy-text: oklch(22% .035 265);
  --hy-muted: oklch(43% .04 265);
  --hy-cyan: oklch(42% .095 215);
  --hy-blue: oklch(44% .16 270);
  --hy-violet: oklch(43% .16 310);
  --hy-pink: oklch(44% .18 350);
  --hy-green: oklch(42% .11 155);
  --hy-amber: oklch(43% .085 70);
  --hy-red: oklch(45% .16 25);
  --hy-glow: oklch(64% .16 310 / .12);
  --hy-shadow: 0 18px 50px oklch(30% .04 260 / .12);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { width: 100%; height: 100%; margin: 0; background: var(--hy-bg); color: var(--hy-text); overflow: hidden; }
body { overscroll-behavior: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
button { cursor: pointer; }
button:disabled { opacity: .5; cursor: default; }
a { color: var(--hy-cyan); text-underline-offset: .18em; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, [tabindex]:focus-visible, summary:focus-visible { outline: 2px solid var(--hy-cyan); outline-offset: 3px; }
input, textarea, select { font-size: 16px; }
button { transition: border-color .18s ease, background-color .18s ease, color .18s ease, transform .18s var(--hy-ease); }
button:active:not(:disabled) { transform: scale(.98); }
.hy-icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.hy-v16 { height: var(--hy-app-height, 100dvh); width: 100%; display: grid; grid-template-columns: 68px 264px minmax(0, 1fr); isolation: isolate; }
.hy-v16::before { content: ""; position: fixed; z-index: -1; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 76% -20%, var(--hy-glow), transparent 65%); }
.hy-rail { display: flex; flex-direction: column; align-items: center; gap: 18px; min-height: 0; padding: calc(16px + env(safe-area-inset-top, 0px)) 8px calc(16px + env(safe-area-inset-bottom, 0px)); border-right: 1px solid var(--hy-line); background: var(--hy-panel); }
.hy-mark { display: grid; place-items: center; width: 46px; height: 46px; border: 1px solid var(--hy-line); border-radius: 16px; background: var(--hy-panel-strong); box-shadow: 0 0 28px var(--hy-glow); }
.hy-mark img { width: 34px; height: 34px; border-radius: 50%; }
.hy-rail-nav { display: grid; gap: 10px; width: 100%; }
.hy-rail-spacer { flex: 1; }
.hy-rail-btn { display: grid; place-items: center; gap: 5px; width: 100%; min-height: 56px; padding: 8px 2px; border: 1px solid transparent; border-radius: 14px; background: transparent; color: var(--hy-muted); font-size: 11px; }
.hy-rail-btn:hover, .hy-rail-btn[aria-current="page"] { color: var(--hy-cyan); border-color: var(--hy-line); background: var(--hy-hover); }
.hy-sidebar { display: flex; flex-direction: column; min-width: 0; min-height: 0; overflow: hidden; border-right: 1px solid var(--hy-line); background: color-mix(in oklch, var(--hy-panel) 72%, var(--hy-bg)); }
.hy-sidebar-head { padding: 18px 14px; flex: none; }
.hy-sidebar-brand { display: flex; align-items: center; gap: 10px; }
.hy-sidebar-brand img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.hy-sidebar-brand strong { display: block; font-size: 15px; }
.hy-sidebar-brand small, #role-label { display: block; color: var(--hy-muted); font-size: 11px; margin-top: 2px; }
.hy-sidebar-tools { display: flex; gap: 6px; margin-top: 18px; }
.hy-sidebar-tools .hy-btn { flex: 1; }
.hy-sidebar-filters { display: grid; grid-template-columns: minmax(0, 1fr) 82px 44px; gap: 4px; padding: 0 12px 12px; }
.hy-sidebar-filters input, .hy-sidebar-filters select { width: 100%; min-width: 0; min-height: 44px; padding: 7px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-panel); font-size: 16px; }
.hy-thread-list { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 4px 12px 20px; scrollbar-width: thin; }
.hy-thread-group { margin: 18px 8px 8px; color: var(--hy-muted); font-size: 11px; font-weight: 600; }
.hy-thread-row { position: relative; margin: 4px 0; border: 1px solid transparent; border-radius: 12px; }
.hy-thread-row:has([aria-current="true"]) { border-color: var(--hy-line); background: var(--hy-hover); }
.hy-thread { display: flex; align-items: center; gap: 9px; min-height: 54px; width: 100%; padding: 9px 10px; border: 0; border-radius: inherit; background: transparent; text-align: left; }
.hy-thread:hover { background: var(--hy-hover); }
.hy-thread-dot { width: 5px; height: 5px; flex: none; border-radius: 50%; background: var(--hy-violet); }
.hy-thread-copy { display: block; min-width: 0; flex: 1; }
.hy-thread-title { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.hy-thread-meta { display: block; margin-top: 4px; color: var(--hy-muted); font-size: 11px; }
.hy-thread-actions { display: none; gap: 4px; padding: 0 6px 6px; }
.hy-thread-row:focus-within .hy-thread-actions, .hy-thread-row:hover .hy-thread-actions { display: flex; }
.hy-thread-action { min-width: 44px; min-height: 44px; padding: 5px; border: 1px solid var(--hy-line); border-radius: 9px; background: var(--hy-panel); color: var(--hy-muted); }
.hy-main { position: relative; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; min-width: 0; min-height: 0; overflow: hidden; }
.hy-topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; min-height: 72px; padding: calc(12px + env(safe-area-inset-top, 0px)) 24px 12px; border-bottom: 1px solid var(--hy-line); background: color-mix(in oklch, var(--hy-bg) 90%, transparent); }
.hy-topbar-left, .hy-topbar-actions { display: flex; align-items: center; gap: 8px; min-width: 0; }
.hy-title { min-width: 0; }
.hy-title strong { display: block; font-size: 15px; letter-spacing: -.015em; }
.hy-title small { display: block; margin-top: 3px; color: var(--hy-muted); font-size: 11px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hy-mobile-menu { display: none !important; }
.hy-status { display: inline-flex; align-items: center; gap: 7px; color: var(--hy-green); font-size: 11px; white-space: nowrap; max-width: 180px; overflow: hidden; }
.hy-status i, .hy-task-dot { width: 6px; height: 6px; flex: none; border-radius: 50%; background: currentColor; box-shadow: 0 0 12px currentColor; }
.hy-btn, .hy-icon-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 44px; border: 1px solid var(--hy-line); border-radius: 12px; background: var(--hy-panel-strong); }
.hy-btn { padding: 8px 14px; font-size: 12px; font-weight: 550; }
.hy-icon-btn { width: 44px; flex: none; padding: 0; font-size: 18px; }
.hy-btn:hover, .hy-icon-btn:hover { border-color: var(--hy-violet); background: var(--hy-hover); }
.hy-btn.primary { color: var(--hy-cyan); border-color: color-mix(in oklch, var(--hy-cyan) 50%, transparent); }
.hy-btn.danger { color: var(--hy-red); }
.hy-thread-viewport { position: relative; z-index: 0; min-height: 0; min-width: 0; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--hy-line) transparent; scroll-padding-block: 24px; }
.hy-thread-wrap { width: min(880px, 100%); margin: 0 auto; padding: 32px clamp(16px, 3vw, 36px) 24px; min-width: 0; }
.hy-welcome { display: grid; justify-items: center; text-align: center; gap: 20px; padding: clamp(18px, 5vh, 64px) 0 30px; }
.hy-welcome h1 { font-size: clamp(28px, 3vw, 40px); font-weight: 650; letter-spacing: -.045em; line-height: 1.15; margin: 0 0 12px; }
.hy-welcome p { margin: 0 auto; max-width: 480px; color: var(--hy-muted); line-height: 1.65; font-size: 14px; text-wrap: pretty; }
.hy-orbit { position: relative; display: grid; place-items: center; isolation: isolate; width: 112px; height: 112px; border-radius: 50%; background: var(--hy-bg); box-shadow: 0 0 65px var(--hy-glow); }
.hy-orbit::before { content: ""; position: absolute; z-index: -2; inset: -3px; border-radius: inherit; background: var(--hy-rainbow); animation: hy-spin 14s linear infinite; }
.hy-orbit::after { content: ""; position: absolute; z-index: -1; inset: 1px; border-radius: inherit; background: var(--hy-bg); box-shadow: inset 0 0 22px var(--hy-glow); }
.hy-orbit img { width: 74px; height: 74px; object-fit: cover; border-radius: 50%; opacity: .88; }
.hy-quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-width: 580px; margin: 0 auto 28px; }
.hy-quick button { display: flex; align-items: center; gap: 12px; text-align: left; min-height: 76px; padding: 14px 16px; border: 1px solid var(--hy-line); border-radius: 16px; background: var(--hy-panel); }
.hy-quick .hy-icon { color: var(--hy-violet); width: 22px; height: 22px; }
.hy-quick b { display: block; font-size: 13px; margin-bottom: 5px; }
.hy-quick span { display: block; color: var(--hy-muted); font-size: 12px; }
.hy-quick button:hover { border-color: var(--hy-violet); background: var(--hy-hover); }
.hy-main[data-has-messages="true"] .hy-welcome, .hy-main[data-has-messages="true"] .hy-quick { display: none; }
.hy-messages { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.hy-message { display: flex; min-width: 0; align-items: flex-start; animation: hy-enter .24s var(--hy-ease) both; }
.hy-message.user { justify-content: flex-end; }
.hy-bubble { min-width: 0; width: 100%; padding: 18px 20px; border: 1px solid var(--hy-line); border-radius: 20px; background: var(--hy-panel); overflow-wrap: anywhere; }
.hy-message.user .hy-bubble { width: fit-content; max-width: 86%; background: color-mix(in oklch, var(--hy-violet) 7%, var(--hy-panel)); border-color: color-mix(in oklch, var(--hy-violet) 26%, var(--hy-line)); border-bottom-right-radius: 7px; }
.hy-message.assistant .hy-bubble { border-top-left-radius: 7px; }
.hy-message[data-busy="true"] .hy-bubble { border-color: color-mix(in oklch, var(--hy-violet) 65%, var(--hy-line)); box-shadow: 0 0 26px var(--hy-glow); }
.hy-message-head { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin-bottom: 12px; min-height: 24px; }
.hy-message-avatar { width: 25px; height: 25px; border-radius: 50%; object-fit: cover; }
.hy-speaker { font-size: 12px; font-weight: 650; color: var(--hy-pink); }
.hy-message.user .hy-speaker { color: var(--hy-amber); }
.hy-user-text, .hy-plain-text { white-space: pre-wrap; line-height: 1.65; }
.hy-prose { font-size: 15px; line-height: 1.75; white-space: normal; min-width: 0; }
.hy-prose > :first-child { margin-top: 0; }
.hy-prose > :last-child { margin-bottom: 0; }
.hy-prose p { margin: 0 0 1em; }
.hy-prose h1, .hy-prose h2, .hy-prose h3, .hy-prose h4, .hy-prose h5, .hy-prose h6 { font-weight: 650; letter-spacing: -.02em; line-height: 1.35; margin: 1.4em 0 .6em; text-wrap: balance; }
.hy-prose h1 { font-size: 1.6em; }
.hy-prose h2 { font-size: 1.35em; }
.hy-prose h3 { font-size: 1.16em; }
.hy-prose h4, .hy-prose h5, .hy-prose h6 { font-size: 1em; }
.hy-prose strong { font-weight: 700; }
.hy-prose ul, .hy-prose ol { padding-left: 1.5em; margin: .7em 0 1em; }
.hy-prose li { margin: .3em 0; }
.hy-prose li > p { margin-bottom: .4em; }
.hy-prose input[type="checkbox"] { accent-color: var(--hy-green); width: 15px; height: 15px; margin-right: 6px; }
.hy-prose blockquote { margin: 1em 0; padding: 10px 16px; border-left: 3px solid var(--hy-violet); background: var(--hy-hover); border-radius: 0 10px 10px 0; color: var(--hy-muted); }
.hy-prose blockquote p:last-child { margin-bottom: 0; }
.hy-prose hr { border: 0; border-top: 1px solid var(--hy-line); margin: 1.5em 0; }
.hy-prose :not(pre) > code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; padding: 2px 5px; background: var(--hy-hover); color: var(--hy-amber); border-radius: 5px; font-size: .9em; }
.hy-code-block { margin: 16px 0; min-width: 0; overflow: hidden; border: 1px solid var(--hy-line); border-radius: 13px; background: var(--hy-bg); }
.hy-code-head { display: flex; justify-content: space-between; align-items: center; min-height: 46px; padding: 3px 8px 3px 14px; background: var(--hy-panel-strong); border-bottom: 1px solid var(--hy-line); color: var(--hy-muted); font-size: 11px; }
.hy-code-block pre { margin: 0; overflow: auto; max-width: 100%; padding: 16px; tab-size: 2; white-space: pre; }
.hy-code-block code { display: block; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 13px; line-height: 1.7; color: var(--hy-text); }
.hy-table-scroll { max-width: 100%; overflow: auto; margin: 16px 0; border: 1px solid var(--hy-line); border-radius: 12px; }
.hy-table-scroll table { border-collapse: collapse; min-width: 100%; font-size: 13px; }
.hy-table-scroll th, .hy-table-scroll td { padding: 10px 13px; text-align: left; border-bottom: 1px solid var(--hy-line); min-width: 110px; vertical-align: top; }
.hy-table-scroll th { background: var(--hy-panel-strong); font-weight: 650; }
.hy-table-scroll tr:last-child td { border-bottom: 0; }
.hy-message-actions { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 14px; padding-top: 8px; border-top: 1px solid var(--hy-line); }
.hy-action-btn { min-height: 44px; min-width: 44px; padding: 7px 10px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: var(--hy-muted); font-size: 11px; }
.hy-action-btn:hover { border-color: var(--hy-line); color: var(--hy-cyan); background: var(--hy-hover); }
.hy-typing { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--hy-muted); }
.hy-typing i { display: block; width: 6px; height: 6px; border-radius: 50%; background: var(--hy-violet); animation: hy-breathe 1.8s ease-in-out infinite; }
.hy-task-card { margin: 9px 0; padding: 0 12px; border: 1px solid var(--hy-line); border-radius: 12px; background: var(--hy-bg); }
.hy-task-card summary { display: flex; align-items: center; gap: 9px; min-height: 48px; font-size: 12px; cursor: pointer; list-style: none; }
.hy-task-card summary::-webkit-details-marker { display: none; }
.hy-task-card summary::after { content: '+'; color: var(--hy-muted); }
.hy-task-card[open] summary::after { content: '−'; }
.hy-task-card p { margin: 0 0 12px; font-size: 12px; line-height: 1.65; color: var(--hy-muted); }
.hy-task-card small { display: block; margin-bottom: 10px; color: var(--hy-muted); }
.hy-task-dot { color: var(--hy-green); }
.hy-task-card[data-status="running"] .hy-task-dot { color: var(--hy-violet); animation: hy-breathe 1.5s ease-in-out infinite; }
.hy-task-card[data-status="error"] .hy-task-dot { color: var(--hy-red); }
.hy-task-state { margin-left: auto; font-size: 11px; color: var(--hy-muted); }
.hy-part-card { margin-top: 12px; padding: 14px; border: 1px solid var(--hy-line); border-radius: 14px; background: var(--hy-panel-strong); min-width: 0; }
.hy-part-label { margin-bottom: 8px; color: var(--hy-cyan); font-size: 11px; font-weight: 650; }
.hy-part-card[data-part-type="error"] { border-color: color-mix(in oklch, var(--hy-red) 55%, var(--hy-line)); }
.hy-part-card[data-part-type="error"] .hy-part-label { color: var(--hy-red); }
.hy-source { display: grid; gap: 5px; margin-top: 9px; font-size: 12px; line-height: 1.6; }
.hy-source span, .hy-part-card small { color: var(--hy-muted); }
.hy-document-card { border-left: 3px solid var(--hy-blue); }
.hy-document-card p { font-size: 13px; color: var(--hy-muted); }
.hy-media-thumb { display: block; width: min(480px, 100%); padding: 0; margin: 10px 0; overflow: hidden; border: 1px solid var(--hy-line); border-radius: 12px; background: var(--hy-bg); cursor: zoom-in; }
.hy-media-thumb img, .hy-media-thumb video { display: block; width: 100%; height: auto; max-height: 420px; object-fit: contain; }
.hy-composer-wrap { position: relative; z-index: 2; width: min(920px, 100%); min-width: 0; margin: 0 auto; padding: 6px clamp(12px, 3vw, 32px) calc(12px + env(safe-area-inset-bottom, 0px)); background: var(--hy-bg); }
.hy-composer { position: relative; isolation: isolate; display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px 44px; align-items: end; gap: 5px; padding: 9px; border: 1px solid color-mix(in oklch, var(--hy-violet) 45%, var(--hy-line)); border-radius: 22px; background: var(--hy-panel-strong); box-shadow: var(--hy-shadow), 0 0 26px var(--hy-glow); }
/* The Chroma perimeter is defined below with its own foreground layer. */
.hy-composer:focus-within { border-color: var(--hy-cyan); }
.hy-composer-col { min-width: 0; }
.hy-composer textarea { display: block; width: 100%; min-height: 44px; max-height: min(180px, 26dvh); resize: none; padding: 11px 5px; border: 0; outline: 0; background: transparent; line-height: 1.5; font-size: 16px; }
.hy-composer textarea::placeholder { color: var(--hy-muted); }
.hy-composer .hy-icon-btn { border: 0; background: transparent; }
.hy-composer #send { color: var(--hy-bg); background: var(--hy-cyan); border-radius: 14px; }
.hy-composer-hint { display: flex; justify-content: space-between; gap: 12px; padding: 10px 7px 0; color: var(--hy-muted); font-size: 11px; line-height: 1.4; }
.hy-composer-tools { display: flex; gap: 6px; min-width: 0; overflow: auto; padding: 6px 2px 10px; scrollbar-width: none; }
.hy-prompt-contexts { display: flex; flex-wrap: wrap; gap: 5px; min-height: 0; padding: 3px 2px; }
.hy-context-chip, .hy-prompt-slot { display: inline-flex; align-items: center; min-height: 25px; border: 1px solid color-mix(in oklch, var(--hy-violet) 35%, var(--hy-line)); border-radius: 8px; padding: 3px 7px; background: var(--hy-glass); color: var(--hy-muted); font: 600 10px var(--hy-mono); }
.hy-prompt-slots { display: flex; align-items: center; gap: 5px; padding: 2px 5px 0; }
.hy-prompt-slot { min-height: 24px; border: 0; background: transparent; }
button.hy-prompt-slot { cursor: pointer; color: var(--hy-cyan); }
.hy-ui-task-rows, .hy-ui-tool-chips, .hy-ui-approval, .hy-ui-streaming-text { display: grid; gap: 9px; margin-top: 12px; }
.hy-ui-task-row { margin: 0; }
.hy-ui-task-body { padding: 0 12px 12px 38px; color: var(--hy-muted); }
.hy-ui-tool-chip { display: inline-flex; align-items: center; gap: 7px; width: fit-content; min-height: 28px; padding: 5px 9px; border: 1px solid var(--hy-line); border-radius: 99px; background: var(--hy-glass); color: var(--hy-muted); font-size: 11px; }
.hy-ui-tool-chip + .hy-ui-tool-chip { margin-left: 5px; }
.hy-ui-tool-glyph { color: var(--hy-cyan); }
.hy-ui-approval { padding: 14px; border-left: 3px solid var(--hy-amber); }
.hy-ui-approval-actions, .hy-ui-stream-footer { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; }
.hy-ui-approval-tool { color: var(--hy-amber); }
.hy-ui-streaming-text { margin-top: 0; }
.hy-ui-stream-footer { border-top: 1px solid var(--hy-line); padding-top: 8px; color: var(--hy-muted); font-size: 11px; }
.hy-tool-chip { display: inline-flex; align-items: center; gap: 6px; flex: none; min-height: 44px; padding: 7px 11px; border: 1px solid var(--hy-line); border-radius: 99px; background: var(--hy-panel); color: var(--hy-muted); font-size: 11px; }
.hy-tool-chip .hy-icon { width: 16px; height: 16px; color: var(--hy-cyan); }
.hy-tool-chip:hover, .hy-tool-chip.active { border-color: var(--hy-violet); color: var(--hy-text); background: var(--hy-hover); }
.hy-drop-zone { display: none; place-items: center; min-height: 60px; margin-bottom: 8px; border: 1px dashed var(--hy-cyan); border-radius: 14px; background: var(--hy-panel); color: var(--hy-cyan); }
.hy-drop-zone.visible { display: grid; }
.hy-pending-files { display: flex; flex-wrap: wrap; gap: 6px; }
.hy-pending-file { padding: 8px; margin-bottom: 6px; border: 1px solid var(--hy-line); border-radius: 9px; color: var(--hy-muted); font-size: 12px; }
.hy-jump { position: absolute; left: 50%; top: -44px; transform: translateX(-50%); z-index: 5; box-shadow: var(--hy-shadow); }
.hy-voice-dock { display: flex; align-items: center; gap: 10px; min-height: 56px; margin: 0 0 8px; padding: 5px 8px 5px 12px; border: 1px solid var(--hy-line); border-radius: 16px; background: var(--hy-panel); }
.hy-dock-avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; flex: none; border: 1px solid var(--hy-cyan); box-shadow: 0 0 calc(10px + var(--hy-audio-level, 0) * 24px) var(--hy-glow); filter: brightness(calc(1 + min(var(--hy-audio-level, 0), .7) * .22)); transition: filter .12s linear, box-shadow .12s linear; }
.hy-dock-copy { flex: 1; min-width: 0; }
.hy-dock-copy strong { display: block; font-size: 12px; }
.hy-dock-copy small { display: block; margin-top: 3px; color: var(--hy-muted); font-size: 11px; }
.hy-dock-level { display: flex; align-items: center; gap: 3px; width: 46px; height: 30px; }
.hy-dock-level i { width: 3px; height: 20px; border-radius: 3px; background: var(--hy-cyan); transform: scaleY(calc(.12 + var(--hy-audio-level, 0) * .88)); transition: transform .08s linear; }
.hy-dock-level i:nth-child(2n) { height: 30px; }
.hy-dock-level i:nth-child(3n) { height: 14px; }
.hy-voice-dock[data-state="speaking"] .hy-dock-avatar { animation: hy-voice-breathe 2.8s ease-in-out infinite; }
.hy-drawer-backdrop { display: none; position: fixed; z-index: 30; inset: 0; background: oklch(0% 0 0 / .55); }
.hy-drawer-backdrop.open { display: block; }
.hy-drawer { position: fixed; z-index: 31; inset: 0 auto 0 0; width: min(344px, 92vw); transform: translateX(-105%); transition: transform .25s var(--hy-ease); background: var(--hy-panel-strong); box-shadow: var(--hy-shadow); }
.hy-drawer.open { transform: translateX(0); }
.hy-drawer .hy-sidebar { display: flex; height: 100%; padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
.hy-modal-backdrop { display: none; position: fixed; z-index: 40; inset: 0; padding: 24px; background: oklch(0% 0 0 / .65); backdrop-filter: blur(8px); place-items: center; }
.hy-modal-backdrop.open { display: grid; }
.hy-modal { display: flex; flex-direction: column; width: min(720px, 100%); max-height: calc(100dvh - 48px); min-height: 0; min-width: 0; border: 1px solid var(--hy-line); border-radius: 24px; background: var(--hy-panel-strong); box-shadow: var(--hy-shadow); overflow: hidden; }
.hy-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex: none; padding: 14px 20px; border-bottom: 1px solid var(--hy-line); }
.hy-modal-head h2 { margin: 0; font-size: 17px; }
.hy-modal-body { min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 20px; }
.hy-tabs { display: flex; overflow: auto; gap: 5px; padding-bottom: 10px; }
.hy-tab { flex: none; min-height: 44px; padding: 8px 12px; border: 1px solid var(--hy-line); border-radius: 10px; background: transparent; font-size: 12px; }
.hy-tab[aria-selected="true"] { color: var(--hy-cyan); border-color: var(--hy-cyan); background: var(--hy-hover); }
.hy-setting-row, .hy-memory-row, .hy-evidence-row { display: flex; justify-content: space-between; gap: 16px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--hy-line); font-size: 13px; }
.hy-setting-row small, .hy-memory-row small { display: block; margin-top: 5px; color: var(--hy-muted); line-height: 1.6; }
.hy-setting-row input[type="checkbox"] { width: 22px; height: 22px; flex: none; accent-color: var(--hy-violet); }
.hy-pill { display: inline-flex; flex: none; padding: 5px 9px; border: 1px solid var(--hy-line); border-radius: 99px; color: var(--hy-cyan); font-size: 11px; }
.hy-voice { text-align: center; }
.hy-voice .hy-orbit { width: 140px; height: 140px; margin: 18px auto 24px; }
.hy-voice .hy-orbit img { width: 96px; height: 96px; }
.hy-voice .hy-orbit { filter: drop-shadow(0 0 calc(12px + var(--hy-audio-level, 0) * 28px) var(--hy-glow)); }
.hy-voice .hy-orbit img { filter: brightness(calc(1 + min(var(--hy-audio-level, 0), .7) * .22)); transition: filter .12s linear; }
.hy-voice-copy { max-width: 380px; margin: 12px auto 18px; color: var(--hy-muted); font-size: 13px; line-height: 1.7; }
.hy-wave { display: flex; justify-content: center; align-items: center; gap: 4px; height: 48px; margin: 16px 0; }
.hy-wave i { width: 4px; height: 32px; border-radius: 5px; background: var(--hy-cyan); transform: scaleY(calc(.1 + var(--hy-audio-level, 0) * .9)); transition: transform .08s linear; }
.hy-wave i:nth-child(2n) { height: 44px; }
.hy-wave i:nth-child(3n) { height: 22px; }
.hy-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 12px 0; }
.hy-metric { padding: 10px; background: var(--hy-panel); border: 1px solid var(--hy-line); border-radius: 12px; }
.hy-metric b, .hy-metric small { display: block; font-size: 11px; }
.hy-metric small { margin-top: 4px; color: var(--hy-muted); }
.hy-cobrowse { display: grid; gap: 14px; }
.hy-cobrowse input, .hy-setting-input { width: 100%; min-height: 44px; padding: 10px; border: 1px solid var(--hy-line); border-radius: 12px; background: var(--hy-panel); }
.hy-cobrowse-frame { min-height: 200px; display: grid; place-items: center; gap: 10px; border: 1px solid var(--hy-line); border-radius: 14px; overflow: hidden; color: var(--hy-muted); text-align: center; }
.hy-cobrowse-shot { width: 100%; max-height: 55dvh; object-fit: contain; }
.hy-cobrowse-receipt-title, .hy-cobrowse-receipt-url, .hy-cobrowse-receipt-meta { display: block; overflow-wrap: anywhere; }
.hy-media-modal { width: min(1080px, 100%); }
.hy-media-modal img, .hy-media-modal video { display: block; max-width: 100%; max-height: 75dvh; margin: auto; border-radius: 12px; }
.hy-empty { padding: 24px 12px; color: var(--hy-muted); text-align: center; font-size: 13px; }
.hy-error { color: var(--hy-red); font-size: 13px; line-height: 1.6; }
.hy-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.hy-toast { position: fixed; z-index: 60; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); left: 50%; transform: translateX(-50%); max-width: min(440px, 90vw); padding: 12px 18px; border: 1px solid var(--hy-cyan); border-radius: 14px; background: var(--hy-panel-strong); box-shadow: var(--hy-shadow); font-size: 13px; }
@keyframes hy-spin { to { transform: rotate(360deg); } }
@keyframes hy-breathe { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
@keyframes hy-enter { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
/* V16 Blackhole Chroma. Adapted from the owner-provided V16 design contract.
   A masked perimeter sits ABOVE the black surface; it never paints a gradient
   plane behind content. Only the shell, prompt, voice dock and active response
   breathe. Completed work stays quiet. No animation implies fake progress. */
@property --hy-edge-angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes hy-edge-orbit { to { --hy-edge-angle: 360deg; } }
@keyframes hy-edge-breathe { 0%, 100% { opacity: .67; } 50% { opacity: 1; } }
@keyframes hy-edge-soft { 0%, 100% { opacity: .24; } 50% { opacity: .54; } }
@keyframes hy-task-scan { from { transform: translateX(-130%); } to { transform: translateX(340%); } }
@keyframes hy-status-orbit { to { transform: rotate(360deg); } }
@keyframes hy-cursor { 0%, 44% { opacity: 1; } 55%, 100% { opacity: .25; } }

.hy-main { margin: 12px 12px 12px 0; border: 1px solid transparent; border-radius: 24px; background: var(--hy-glass); }
.hy-main::before, .hy-composer::before, .hy-voice-dock::before, .hy-message[data-busy="true"] .hy-bubble::before {
  content: ''; position: absolute; z-index: 6; inset: -1px; padding: 1.5px; border-radius: inherit;
  pointer-events: none; background: conic-gradient(from var(--hy-edge-angle), var(--hy-spectrum));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); mask-composite: exclude;
  animation: hy-edge-orbit 16s linear infinite, hy-edge-breathe 4.8s ease-in-out infinite;
}
.hy-main::before { inset: 0; opacity: .78; animation-duration: 24s, 6.2s; }
.hy-composer::before { padding: 2px; }
.hy-composer::after, .hy-voice-dock::after {
  content: ''; position: absolute; z-index: -1; inset: -4px; padding: 4px; border-radius: inherit;
  pointer-events: none; background: conic-gradient(from var(--hy-edge-angle), var(--hy-spectrum));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); mask-composite: exclude;
  filter: blur(4px); opacity: .4; animation: hy-edge-orbit 16s linear infinite, hy-edge-soft 4.8s ease-in-out infinite;
}
.hy-composer:hover::before, .hy-composer:focus-within::before { animation-duration: 8s, 2.8s; }
:root:is([data-activity="submitting"], [data-activity="streaming"], [data-activity="finalizing"]) .hy-composer::before { animation-duration: 7s, 2.8s; }
:root:is([data-activity="submitting"], [data-activity="streaming"], [data-activity="finalizing"]) #send { color: var(--hy-red); background: color-mix(in oklch, var(--hy-red) 12%, var(--hy-panel)); }
.hy-main .hy-topbar { background: var(--hy-glass); border-bottom-color: color-mix(in oklch, var(--hy-blue) 20%, var(--hy-line)); }
.hy-session-mark { position: relative; width: 38px; height: 38px; flex: none; display: grid; place-items: center; padding: 2px; border-radius: 50%; background: var(--hy-rainbow); box-shadow: 0 0 20px var(--hy-glow); }
.hy-session-mark img { width: 100%; height: 100%; padding: 3px; border-radius: inherit; object-fit: cover; background: var(--hy-bg); }
.hy-title strong { letter-spacing: -.025em; font-size: 16px; }
.hy-rail { background: var(--hy-bg); border-right-color: color-mix(in oklch, var(--hy-line) 60%, transparent); }
.hy-mark { border-color: var(--hy-blue); background: var(--hy-glass); }
.hy-sidebar { margin-right: 12px; border-right: 0; background: var(--hy-bg); }
.hy-sidebar-brand strong { font-size: 20px; letter-spacing: -.045em; }
.hy-sidebar-brand strong span { color: var(--hy-cyan); }
.hy-sidebar-brand small { font: 9px/1.5 var(--hy-mono); letter-spacing: .07em; }
.hy-sidebar-filters { grid-template-columns: minmax(0, 1fr) 44px; }
.hy-sidebar-filters input { grid-column: 1 / -1; }
.hy-sidebar-filters select { padding-inline: 10px; }
.hy-thread-row:has([aria-current="true"]) { border-color: color-mix(in oklch, var(--hy-violet) 60%, var(--hy-line)); background: var(--hy-glass); box-shadow: inset 2px 0 0 var(--hy-violet); }
.hy-thread-dot { color: var(--hy-violet); box-shadow: 0 0 8px color-mix(in oklch, currentColor 50%, transparent); }
.hy-status { padding: 8px 10px; border: 1px solid color-mix(in oklch, currentColor 24%, var(--hy-line)); border-radius: 99px; background: var(--hy-panel); }
.hy-btn, .hy-icon-btn { background: var(--hy-glass); }
.hy-btn.primary { color: var(--hy-cyan); border-color: color-mix(in oklch, var(--hy-cyan) 60%, var(--hy-line)); }
#voice { color: var(--hy-pink); border-color: color-mix(in oklch, var(--hy-pink) 45%, var(--hy-line)); }
#cobrowse { color: var(--hy-blue); }
#settings { color: var(--hy-muted); }
#theme-toggle-mobile { color: var(--hy-amber); }
.hy-rail-btn:nth-child(1) .hy-rail-icon { color: var(--hy-pink); }
.hy-rail-btn:nth-child(2) .hy-rail-icon { color: var(--hy-blue); }
.hy-rail-btn:nth-child(3) .hy-rail-icon { color: var(--hy-green); }
.hy-rail-btn:nth-child(4) .hy-rail-icon { color: var(--hy-violet); }
.hy-rail-btn[aria-current="page"] { background: var(--hy-glass); border-color: color-mix(in oklch, var(--hy-pink) 50%, var(--hy-line)); }
.hy-thread-wrap { padding-top: 28px; }
.hy-welcome { padding-block: clamp(12px, 4vh, 44px) 28px; gap: 26px; }
.hy-welcome h1 { max-width: 560px; margin: 0; font-size: clamp(26px, 3vw, 37px); }
.hy-welcome .hy-orbit { box-shadow: 0 0 16px color-mix(in oklch, var(--hy-pink) 20%, transparent), 0 0 50px var(--hy-glow); }
.hy-quick button { background: var(--hy-glass); }
.hy-quick button > span:first-child { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border: 1px solid color-mix(in oklch, var(--hy-violet) 35%, var(--hy-line)); border-radius: 11px; background: var(--hy-bg); }
.hy-quick button:nth-child(1) .hy-icon { color: var(--hy-blue); }
.hy-quick button:nth-child(2) .hy-icon { color: var(--hy-green); }
.hy-quick button:nth-child(3) .hy-icon { color: var(--hy-pink); }
.hy-quick button:nth-child(4) .hy-icon { color: var(--hy-amber); }
.hy-bubble { position: relative; isolation: isolate; background: var(--hy-glass); box-shadow: 0 9px 24px color-mix(in oklch, var(--hy-bg) 45%, transparent); }
.hy-message.user .hy-bubble { border-color: color-mix(in oklch, var(--hy-amber) 35%, var(--hy-line)); background: linear-gradient(160deg, color-mix(in oklch, var(--hy-amber) 6%, var(--hy-panel)), var(--hy-bg)); }
.hy-message.assistant .hy-bubble { border-top-left-radius: 20px; border-color: color-mix(in oklch, var(--hy-pink) 20%, var(--hy-line)); }
.hy-message[data-busy="true"] .hy-bubble { box-shadow: 0 0 24px var(--hy-glow); }
.hy-message[data-busy="true"] .hy-bubble::before { padding: 1px; animation-duration: 10s, 3.4s; }
.hy-message-head { padding-bottom: 11px; border-bottom: 1px solid var(--hy-line); margin-bottom: 16px; }
.hy-message-avatar { width: 27px; height: 27px; padding: 2px; border: 1px solid color-mix(in oklch, var(--hy-pink) 55%, var(--hy-line)); background: var(--hy-bg); }
.hy-speaker { font: 700 12px/1.4 var(--hy-mono); letter-spacing: .06em; }
.hy-message.user .hy-message-head { border-bottom: 0; margin-bottom: 8px; padding-bottom: 0; }
.hy-message-head .hy-typing { margin-left: auto; color: var(--hy-violet); min-height: 25px; }
.hy-typing .hy-thinking-orbit { position: relative; display: inline-block; flex: none; width: 17px; height: 17px; border: 2px solid color-mix(in oklch, var(--hy-violet) 22%, transparent); border-top-color: var(--hy-pink); border-right-color: var(--hy-cyan); border-radius: 50%; animation: hy-status-orbit 1.6s linear infinite; box-shadow: 0 0 9px var(--hy-glow); }
.hy-thinking-orbit::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; background: var(--hy-bg); }
.hy-message[data-busy="true"] .hy-prose > :last-child::after { content: ''; display: inline-block; width: 5px; height: 1em; vertical-align: text-bottom; margin-left: 5px; border-radius: 1px; background: var(--hy-pink); animation: hy-cursor 1.2s ease-in-out infinite; }
.hy-prose h1, .hy-prose h2 { color: var(--hy-text); padding-bottom: .38em; border-bottom: 1px solid color-mix(in oklch, var(--hy-violet) 35%, var(--hy-line)); }
.hy-prose h3 { color: var(--hy-blue); }
.hy-prose ul > li::marker { color: var(--hy-violet); }
.hy-prose ol > li::marker { color: var(--hy-cyan); font-weight: 650; }
.hy-prose strong { color: var(--hy-text); }
.hy-code-block { border-color: color-mix(in oklch, var(--hy-blue) 45%, var(--hy-line)); background: var(--hy-bg); }
.hy-code-head { background: var(--hy-glass); color: var(--hy-blue); font-family: var(--hy-mono); }
.hy-code-head > span::before { content: '›_ '; color: var(--hy-cyan); }
.hy-table-scroll th { color: var(--hy-blue); background: var(--hy-glass); }
.hy-table-scroll tbody tr:nth-child(2n) { background: color-mix(in oklch, var(--hy-panel-strong) 45%, transparent); }
.hy-task-card { --hy-task-color: var(--hy-green); position: relative; overflow: hidden; background: var(--hy-glass); border-color: color-mix(in oklch, var(--hy-task-color) 30%, var(--hy-line)); }
.hy-task-card summary { position: relative; }
.hy-task-card .hy-task-dot { width: 8px; height: 8px; color: var(--hy-task-color); }
.hy-task-card .hy-task-dot:has(.hy-icon) { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: transparent; box-shadow: none; }
.hy-task-card .hy-task-dot .hy-icon { width: 15px; height: 15px; }
.hy-task-state { color: var(--hy-task-color); border: 1px solid color-mix(in oklch, var(--hy-task-color) 28%, transparent); background: color-mix(in oklch, var(--hy-task-color) 6%, var(--hy-bg)); border-radius: 99px; padding: 4px 7px; font: 10px/1.4 var(--hy-mono); }
.hy-task-card[data-status="running"] { --hy-task-color: var(--hy-violet); }
.hy-task-card[data-status="error"], .hy-task-card[data-status="failed"] { --hy-task-color: var(--hy-red); }
.hy-task-card[data-status="cancelled"], .hy-task-card[data-status="denied"], .hy-task-card[data-status="declined"], .hy-task-card[data-status="interrupted"], .hy-task-card[data-status="pending"] { --hy-task-color: var(--hy-amber); }
.hy-task-card[data-status="running"]::after { content: ''; position: absolute; height: 2px; width: 35%; left: 0; bottom: 0; border-radius: 99px; background: linear-gradient(90deg, var(--hy-violet), var(--hy-pink), var(--hy-cyan)); animation: hy-task-scan 2.8s ease-in-out infinite; }
.hy-part-card { --hy-part-color: var(--hy-cyan); position: relative; border-color: color-mix(in oklch, var(--hy-part-color) 35%, var(--hy-line)); background: var(--hy-glass); }
.hy-part-label { display: flex; align-items: center; gap: 7px; color: var(--hy-part-color); text-transform: uppercase; letter-spacing: .08em; font: 600 10px/1.5 var(--hy-mono); }
.hy-part-label::before { content: ''; width: 5px; height: 5px; flex: none; border-radius: 2px; background: currentColor; }
.hy-part-card[data-part-type="health_context_card"], .hy-part-card[data-part-type="peptide_card"] { --hy-part-color: var(--hy-green); }
.hy-part-card[data-part-type="image"] { --hy-part-color: var(--hy-pink); }
.hy-part-card[data-part-type="video"], .hy-part-card[data-part-type="library_source_card"] { --hy-part-color: var(--hy-violet); }
.hy-part-card[data-part-type="error"] { --hy-part-color: var(--hy-red); }
.hy-part-card[data-part-type="approval"], .hy-bubble:has([data-action="approve-tools"]) .hy-part-card[data-part-type="status"] { --hy-part-color: var(--hy-amber); }
.hy-part-card a { display: inline-flex; align-items: center; min-height: 44px; width: fit-content; max-width: 100%; color: var(--hy-part-color); }
.hy-document-card { --hy-part-color: var(--hy-blue); padding: 16px 16px 12px 18px; border-left-width: 3px; }
.hy-document-card strong { display: block; font-size: 15px; line-height: 1.55; }
.hy-document-card a { margin-top: 10px; padding: 8px 11px; border: 1px solid color-mix(in oklch, var(--hy-blue) 40%, var(--hy-line)); border-radius: 10px; text-decoration: none; background: var(--hy-bg); }
.hy-source + .hy-source { border-top: 1px solid var(--hy-line); padding-top: 12px; }
.hy-message-actions [data-action="approve-tools"] { background: color-mix(in oklch, var(--hy-green) 10%, var(--hy-bg)); border-color: var(--hy-green); color: var(--hy-green); }
.hy-message-actions [data-action="deny-tools"] { border-color: var(--hy-line); color: var(--hy-muted); }
.hy-message-actions:has([data-action="approve-tools"]) { border-top-color: color-mix(in oklch, var(--hy-amber) 40%, var(--hy-line)); padding-block: 12px 2px; }
.hy-composer-wrap { background: linear-gradient(180deg, var(--hy-bg), var(--hy-panel)); padding-top: 8px; }
.hy-composer { background: var(--hy-glass); border-color: transparent; box-shadow: 0 8px 25px color-mix(in oklch, var(--hy-bg) 55%, transparent), 0 0 22px var(--hy-glow); }
.hy-composer:focus-within { border-color: transparent; }
.hy-composer #send { background: linear-gradient(135deg, var(--hy-cyan), var(--hy-blue)); color: var(--hy-bg); box-shadow: 0 0 13px color-mix(in oklch, var(--hy-cyan) 18%, transparent); }
.hy-composer #attach { color: var(--hy-violet); }
.hy-composer #dictate { color: var(--hy-pink); }
.hy-tool-chip { --hy-tool-color: var(--hy-cyan); color: var(--hy-muted); border-radius: 12px; background: var(--hy-glass); }
.hy-tool-chip .hy-icon { color: var(--hy-tool-color); }
.hy-tool-chip[data-tool-key="web"] { --hy-tool-color: var(--hy-blue); }
.hy-tool-chip[data-tool-key="cobrowse"] { --hy-tool-color: var(--hy-cyan); }
.hy-tool-chip[data-tool-key="evidence"] { --hy-tool-color: var(--hy-amber); }
.hy-tool-chip[data-tool-key="peptide"] { --hy-tool-color: var(--hy-green); }
.hy-tool-chip[data-tool-key="lab"] { --hy-tool-color: var(--hy-violet); }
.hy-tool-chip[data-tool-key="image"] { --hy-tool-color: var(--hy-pink); }
.hy-tool-chip[data-tool-key="video"] { --hy-tool-color: var(--hy-violet); }
.hy-tool-chip[data-tool-key="office"] { --hy-tool-color: var(--hy-blue); }
.hy-tool-chip:hover, .hy-tool-chip.active, .hy-tool-chip[aria-pressed="true"] { color: var(--hy-text); border-color: var(--hy-tool-color); background: color-mix(in oklch, var(--hy-tool-color) 9%, var(--hy-bg)); }
.hy-tool-chip.active, .hy-tool-chip[aria-pressed="true"] { box-shadow: inset 0 -2px 0 var(--hy-tool-color); }
.hy-voice-dock { position: relative; isolation: isolate; background: var(--hy-glass); border-color: transparent; border-radius: 18px; }
.hy-voice-dock::before { padding: 1.5px; animation-duration: 18s, 4.8s; }
.hy-voice-dock[data-state="speaking"]::before { animation-duration: 7s, 2.8s; }
.hy-voice-dock[data-state="speaking"], .hy-voice[data-state="speaking"] { box-shadow: 0 0 calc(10px + var(--hy-audio-level, 0) * 28px) var(--hy-glow); }
.hy-voice-dock[data-state="processing"]::before, .hy-voice-dock[data-state="reconnecting"]::before, .hy-voice[data-state="processing"]::before, .hy-voice[data-state="reconnecting"]::before { animation: hy-voice-breathe 2.6s ease-in-out infinite; }
.hy-voice-dock[data-state="muted"]::before, .hy-voice-dock[data-state="error"]::before { animation-play-state: paused; opacity: .65; }
.hy-voice-dock[data-state="error"] #dock-state { color: var(--hy-red); }
.hy-voice-dock[data-state="muted"] #dock-state { color: var(--hy-amber); }
.hy-dock-copy strong { color: var(--hy-pink); font-size: 12px; }
.hy-dock-avatar { box-shadow: 0 0 calc(12px + var(--hy-audio-level, 0) * 24px) var(--hy-glow); }
.hy-dock-level i:nth-child(2n), .hy-wave i:nth-child(2n) { background: var(--hy-pink); }
.hy-dock-level i:nth-child(3n), .hy-wave i:nth-child(3n) { background: var(--hy-violet); }
#voice-hangup { color: var(--hy-red); border-color: color-mix(in oklch, var(--hy-red) 32%, var(--hy-line)); }
#voice-mute[aria-pressed="true"] { color: var(--hy-amber); border-color: var(--hy-amber); }
.hy-modal { background: var(--hy-glass); border-color: color-mix(in oklch, var(--hy-violet) 50%, var(--hy-line)); }
.hy-modal.open, .hy-modal-backdrop.open .hy-modal { animation: hy-enter .28s var(--hy-ease) both; }
.hy-drawer .hy-sidebar { margin: 0; }
.hy-drawer .hy-sidebar-filters { grid-template-columns: minmax(0, 1fr); }
.hy-drawer .hy-sidebar-brand strong { font-size: 17px; }
:root[data-theme="light"] .hy-main, :root[data-theme="light"] .hy-bubble { box-shadow: var(--hy-shadow); }
:root[data-theme="light"] .hy-composer::after, :root[data-theme="light"] .hy-voice-dock::after { opacity: .2; filter: blur(2px); }
:root[data-theme="light"] .hy-message.user .hy-bubble { background: color-mix(in oklch, var(--hy-amber) 4%, var(--hy-panel-strong)); }
@media (hover: hover) and (pointer: fine) {
  .hy-quick button:hover { transform: translateY(-2px); }
  .hy-tool-chip:hover { box-shadow: 0 0 10px color-mix(in oklch, var(--hy-tool-color) 14%, transparent); }
}

@media (max-width: 1280px) {
  .hy-topbar-actions .hy-button-label { display: none; }
  .hy-topbar-actions .hy-btn { width: 44px; padding: 0; flex: none; }
  .hy-topbar-actions .hy-status { max-width: 140px; }
}
@media (max-width: 1100px) {
  .hy-v16 { grid-template-columns: 60px minmax(0, 1fr); }
  .hy-main { margin-left: 8px; }
  .hy-v16 > .hy-sidebar { display: none; }
  .hy-mobile-menu { display: inline-flex !important; }
  .hy-topbar { padding-inline: 16px; }
}
@media (max-width: 700px) {
  .hy-v16 { grid-template-columns: minmax(0, 1fr); }
  .hy-main { margin: 6px; border-radius: 20px; }
  .hy-main::before { padding: 1.5px; }
  .hy-session-mark { width: 30px; height: 30px; }
  .hy-voice-dock { gap: 8px; }
  .hy-dock-level { width: 36px; gap: 2px; }
  .hy-dock-copy strong, .hy-dock-copy small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .hy-title strong { font-size: 15px; }
  .hy-topbar-left { gap: 6px; }
  .hy-main .hy-topbar { padding-inline: 7px; }
  .hy-topbar-actions #settings { display: none; }
  .hy-message-head .hy-typing { margin-left: 0; }
  .hy-bubble .hy-message-head { gap: 7px; }
  .hy-quick button > span:first-child { width: 30px; height: 34px; border-radius: 10px; }
  .hy-rail { display: none; }
  .hy-topbar { min-height: 64px; padding: calc(8px + env(safe-area-inset-top, 0px)) max(10px, env(safe-area-inset-right, 0px)) 8px max(10px, env(safe-area-inset-left, 0px)); gap: 8px; }
  .hy-topbar-actions { gap: 4px; }
  .hy-topbar-actions .hy-button-label, .hy-topbar-actions .hy-status { display: none; }
  .hy-topbar-actions .hy-btn { padding: 0; width: 44px; }
  .hy-title small { max-width: 118px; }
  .hy-thread-wrap { padding: 20px 12px; }
  .hy-welcome { padding-top: 18px; gap: 20px; }
  .hy-welcome p { max-width: 330px; font-size: 13px; }
  .hy-orbit { width: 88px; height: 88px; }
  .hy-orbit img { width: 58px; height: 58px; }
  .hy-quick { gap: 8px; }
  .hy-quick button { padding: 12px; gap: 9px; min-height: 80px; }
  .hy-quick b { font-size: 12px; }
  .hy-quick span { font-size: 11px; line-height: 1.5; }
  .hy-quick .hy-icon { width: 18px; }
  .hy-messages { gap: 18px; }
  .hy-bubble { padding: 15px 14px; border-radius: 17px; }
  .hy-message.user .hy-bubble { max-width: 92%; }
  .hy-prose, .hy-user-text { font-size: 15px; }
  .hy-message-head { gap: 7px; }
  .hy-typing { font-size: 11px; }
  .hy-composer-wrap { padding-inline: max(10px, env(safe-area-inset-right, 0px)); padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px)); }
  .hy-composer { gap: 2px; padding: 6px; border-radius: 19px; }
  .hy-composer-hint > span:first-child { display: none; }
  .hy-composer-hint { justify-content: center; padding-top: 7px; font-size: 11px; }
  .hy-composer-tools { padding-bottom: 7px; }
  .hy-tool-chip { min-height: 44px; padding-inline: 10px; }
  .hy-modal-backdrop { padding: 10px; align-items: end; }
  .hy-modal { max-height: calc(var(--hy-app-height, 100dvh) - 20px - env(safe-area-inset-top, 0px)); border-radius: 22px; }
  .hy-modal-head { padding: 12px 14px; }
  .hy-modal-body { padding: 16px 14px calc(16px + env(safe-area-inset-bottom, 0px)); }
  .hy-thread-actions { display: flex; }
  .hy-sidebar-filters input, .hy-sidebar-filters select { font-size: 16px; }
}
@media (max-width: 374px) {
  .hy-title small { max-width: 85px; }
  .hy-session-mark { display: none; }
  .hy-topbar-actions #settings { display: none; }
  .hy-quick { grid-template-columns: minmax(0, 1fr); }
  .hy-quick button { min-height: 64px; }
  .hy-composer { grid-template-columns: 44px minmax(0, 1fr) 44px; }
  #dictate { display: none; }
}
@media (min-width: 1800px) { .hy-thread-wrap { width: min(1040px, 100%); } .hy-composer-wrap { width: min(1080px, 100%); } .hy-prose { font-size: 16px; } }
@media (max-height: 540px) { .hy-main { margin-block: 3px; } .hy-main .hy-topbar { padding-block: 4px; } .hy-composer-tools, .hy-composer-hint { display: none; } .hy-topbar { min-height: 52px; padding-block: 4px; } .hy-voice-dock { min-height: 48px; margin-bottom: 4px; } .hy-welcome { padding: 10px 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
:root[data-page-hidden="true"] *, :root[data-page-hidden="true"] *::before, :root[data-page-hidden="true"] *::after { animation-play-state: paused !important; }

@media(max-width:700px){.hy-composer-hint{align-items:center;}.hy-composer-hint>span:first-child{display:none;}}

.hy-jump:active:not(:disabled) { transform: translateX(-50%) scale(.98); }

.hy-status:has([data-state="error"]) { color:var(--hy-red); }
.hy-status:has([data-state="error"]) i { background:var(--hy-red); }
.hy-status:has([data-state="cancelled"]) { color:var(--hy-amber); }
.hy-status:has([data-state="cancelled"]) i { background:var(--hy-amber); }
.hy-status:has([data-state="streaming"]), .hy-status:has([data-state="submitting"]), .hy-status:has([data-state="finalizing"]) { color:var(--hy-violet); }
.hy-status:has([data-state="streaming"]) i, .hy-status:has([data-state="submitting"]) i, .hy-status:has([data-state="finalizing"]) i { background:var(--hy-violet); }

/* Beautiful UI native primitives — actual user-supplied component grammar.
   JS owns elapsed time, data, transitions and completion. These animations
   only decorate an explicitly active operation; they never resolve work. */
.hy-ui-loader, .hy-ui-trace, .hy-ui-recommendation, .hy-ui-context-card, .hy-ui-filter-table, .hy-ui-surface {
  --hy-ui-hue: var(--hy-violet); min-width: 0; max-width: 100%; color: var(--hy-text);
  border: 1px solid color-mix(in oklch, var(--hy-ui-hue) 24%, var(--hy-line)); border-radius: 16px; background: var(--hy-glass);
}
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="blue"] { --hy-ui-hue: var(--hy-blue); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="cyan"] { --hy-ui-hue: var(--hy-cyan); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="violet"] { --hy-ui-hue: var(--hy-violet); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="pink"] { --hy-ui-hue: var(--hy-pink); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="green"] { --hy-ui-hue: var(--hy-green); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="amber"] { --hy-ui-hue: var(--hy-amber); }
:is(.hy-ui-context-card, .hy-ui-recommendation, .hy-ui-badge, .hy-ui-tag)[data-tone="red"] { --hy-ui-hue: var(--hy-red); }
.hy-ui-card-header, .hy-ui-head { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; min-width: 0; padding: 14px 16px 10px; }
.hy-ui-card-header strong, .hy-ui-title { min-width: 0; flex: 1; font-size: 14px; font-weight: 650; line-height: 1.5; letter-spacing: -.015em; overflow-wrap: anywhere; }
.hy-ui-card-body, .hy-ui-body { min-width: 0; padding: 0 16px 14px; font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
.hy-ui-card-body > :first-child { margin-top: 0; }
.hy-ui-card-body > :last-child { margin-bottom: 0; }
.hy-ui-card-footer, .hy-ui-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 10px 16px 14px; }
.hy-ui-card-footer { border-top: 1px solid var(--hy-line); }
.hy-ui-label { color: var(--hy-ui-hue, var(--hy-cyan)); font: 600 10px/1.5 var(--hy-mono); letter-spacing: .08em; text-transform: uppercase; }
.hy-ui-meta, .hy-ui-table-count, .hy-ui-empty { color: var(--hy-muted); font-size: 12px; line-height: 1.6; }
.hy-ui-empty { padding: 18px 16px; text-align: center; }
.hy-ui-button, .hy-ui-icon-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; min-width: 44px; padding: 8px 12px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-panel); color: var(--hy-text); font-size: 12px; }
.hy-ui-icon-button { width: 44px; padding: 0; flex: none; }
.hy-ui-button:hover, .hy-ui-icon-button:hover { border-color: var(--hy-ui-hue, var(--hy-violet)); background: var(--hy-hover); }
.hy-ui-badge, .hy-ui-tag { display: inline-flex; align-items: center; gap: 5px; max-width: 100%; padding: 4px 8px; border: 1px solid color-mix(in oklch, var(--hy-ui-hue, var(--hy-violet)) 32%, var(--hy-line)); border-radius: 8px; background: color-mix(in oklch, var(--hy-ui-hue, var(--hy-violet)) 7%, var(--hy-bg)); color: var(--hy-ui-hue, var(--hy-violet)); font: 11px/1.4 var(--hy-mono); overflow-wrap: anywhere; }
.hy-ui-chevron { width: 16px; height: 16px; flex: none; color: var(--hy-muted); transition: transform .18s var(--hy-ease); }
:where(details[open]) > summary .hy-ui-chevron, [aria-expanded="true"] > .hy-ui-chevron { transform: rotate(180deg); }

.hy-ui-loader { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 12px 14px; margin: 8px 0; }
.hy-ui-loader.compact { min-height: 44px; padding: 4px 0; margin: 0; border: 0; border-radius: 0; background: transparent; }
.hy-ui-pixel-grid { display: grid; grid-template-columns: repeat(3, 8px); grid-template-rows: repeat(3, 8px); gap: 3px; width: 30px; height: 30px; flex: none; place-content: center; }
.hy-ui-pixel-grid i { display: block; width: 8px; height: 8px; border-radius: 2px; background: var(--hy-violet); opacity: .68; transform: scale(.85); }
.hy-ui-pixel-grid i:nth-child(1) { --hy-pixel-delay: 0ms; background: var(--hy-cyan); }
.hy-ui-pixel-grid i:nth-child(2) { --hy-pixel-delay: 90ms; background: var(--hy-blue); }
.hy-ui-pixel-grid i:nth-child(3) { --hy-pixel-delay: 180ms; background: var(--hy-violet); }
.hy-ui-pixel-grid i:nth-child(4) { --hy-pixel-delay: 270ms; background: var(--hy-green); }
.hy-ui-pixel-grid i:nth-child(5) { --hy-pixel-delay: 360ms; background: var(--hy-pink); }
.hy-ui-pixel-grid i:nth-child(6) { --hy-pixel-delay: 450ms; background: var(--hy-violet); }
.hy-ui-pixel-grid i:nth-child(7) { --hy-pixel-delay: 540ms; background: var(--hy-amber); }
.hy-ui-pixel-grid i:nth-child(8) { --hy-pixel-delay: 630ms; background: var(--hy-green); }
.hy-ui-pixel-grid i:nth-child(9) { --hy-pixel-delay: 720ms; background: var(--hy-cyan); }
:is(.hy-ui-loader, .hy-ui-trace)[data-active="true"] .hy-ui-pixel-grid i { animation: hy-ui-pixel-drive var(--hy-pixel-duration, 1.55s) ease-in-out var(--hy-pixel-delay, 0ms) infinite; }
.hy-ui-pixel-grid[data-variant="Dots" i] i { border-radius: 50%; }
:is(.hy-ui-loader, .hy-ui-trace)[data-active="true"] .hy-ui-pixel-grid[data-variant="Dots" i] i { animation-name: hy-ui-pixel-dots; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(5) { visibility: hidden; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(1) { --hy-pixel-delay: 0ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(2) { --hy-pixel-delay: 120ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(3) { --hy-pixel-delay: 240ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(6) { --hy-pixel-delay: 360ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(9) { --hy-pixel-delay: 480ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(8) { --hy-pixel-delay: 600ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(7) { --hy-pixel-delay: 720ms; }
.hy-ui-pixel-grid[data-variant="Orbit" i] i:nth-child(4) { --hy-pixel-delay: 840ms; }
:is(.hy-ui-loader, .hy-ui-trace)[data-active="true"] .hy-ui-pixel-grid[data-variant="Orbit" i] i { animation-name: hy-ui-pixel-orbit; animation-duration: var(--hy-pixel-duration, 1.3s); }
.hy-ui-loader-copy { display: grid; gap: 3px; min-width: 0; flex: 1; }
.hy-ui-loader-copy small { color: var(--hy-muted); font-size: 11px; line-height: 1.5; }
.hy-ui-shimmer { display: inline-block; min-width: 0; color: var(--hy-text); font-size: 13px; font-weight: 550; line-height: 1.6; }
:is(.hy-ui-loader, .hy-ui-trace)[data-active="true"] .hy-ui-shimmer { background: linear-gradient(110deg, var(--hy-muted) 25%, var(--hy-text) 45%, var(--hy-cyan) 50%, var(--hy-text) 55%, var(--hy-muted) 75%); background-size: 240% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: hy-ui-label-shimmer 3s linear infinite; }
.hy-ui-elapsed { flex: none; margin-left: auto; color: var(--hy-muted); font: 11px/1.5 var(--hy-mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
@keyframes hy-ui-pixel-drive { 0%, 100% { opacity: .25; transform: scale(.72); } 35%, 60% { opacity: 1; transform: scale(1); } }
@keyframes hy-ui-pixel-dots { 0%, 100% { opacity: .25; transform: translateY(0) scale(.76); } 40% { opacity: 1; transform: translateY(-2px) scale(1); } }
@keyframes hy-ui-pixel-orbit { 0%, 70%, 100% { opacity: .24; transform: scale(.78); } 18%, 35% { opacity: 1; transform: scale(1); } }
@keyframes hy-ui-label-shimmer { from { background-position: 150% 0; } to { background-position: -90% 0; } }
@keyframes hy-ui-word-arrive { from { opacity: .45; filter: blur(1px); } to { opacity: 1; filter: blur(0); } }

.hy-ui-trace { margin: 12px 0; overflow: hidden; }
.hy-ui-trace > summary { display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 10px 14px; cursor: pointer; list-style: none; font-size: 13px; }
.hy-ui-trace > summary::-webkit-details-marker, .hy-ui-sources > summary::-webkit-details-marker, .hy-ui-alternatives > summary::-webkit-details-marker { display: none; }
.hy-ui-trace > summary::after, .hy-ui-sources > summary::after, .hy-ui-alternatives > summary::after { content: '+'; margin-left: auto; color: var(--hy-muted); font: 16px/1 var(--hy-mono); }
.hy-ui-trace[open] > summary::after, .hy-ui-sources[open] > summary::after, .hy-ui-alternatives[open] > summary::after { content: '−'; }
.hy-ui-trace > summary:has(.hy-ui-chevron)::after, .hy-ui-sources > summary:has(.hy-ui-chevron)::after, .hy-ui-alternatives > summary:has(.hy-ui-chevron)::after { display: none; }
.hy-ui-trace > summary .hy-ui-loader { flex: 1; min-height: 30px; padding: 0; margin: 0; border: 0; background: none; }
.hy-ui-trace[open] > summary { border-bottom: 1px solid var(--hy-line); }
.hy-ui-trace-rows { display: grid; gap: 4px; margin: 0; padding: 12px 14px 8px; list-style: none; }
.hy-ui-trace-row { --hy-ui-step-color: var(--hy-muted); position: relative; display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; min-width: 0; padding: 4px 0 12px; }
.hy-ui-trace-row:not(:last-child)::before { content: ''; position: absolute; top: 32px; bottom: -4px; left: 11.5px; width: 1px; background: var(--hy-line); }
.hy-ui-trace-row[data-status="complete"], .hy-ui-trace-row[data-status="done"] { --hy-ui-step-color: var(--hy-green); }
.hy-ui-trace-row[data-status="running"], .hy-ui-trace-row[data-status="thinking"] { --hy-ui-step-color: var(--hy-violet); }
.hy-ui-trace-row[data-status="error"], .hy-ui-trace-row[data-status="failed"] { --hy-ui-step-color: var(--hy-red); }
.hy-ui-trace-row[data-status="cancelled"], .hy-ui-trace-row[data-status="declined"], .hy-ui-trace-row[data-status="pending"] { --hy-ui-step-color: var(--hy-amber); }
.hy-ui-trace-dot { position: relative; display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid color-mix(in oklch, var(--hy-ui-step-color) 45%, var(--hy-line)); border-radius: 50%; color: var(--hy-ui-step-color); background: var(--hy-bg); font: 10px/1 var(--hy-mono); }
.hy-ui-trace-dot svg { width: 13px; height: 13px; }
.hy-ui-trace-row[data-status="running"] .hy-ui-trace-dot::after { content: ''; position: absolute; inset: -2px; border: 2px solid transparent; border-top-color: var(--hy-violet); border-right-color: var(--hy-cyan); border-radius: inherit; animation: hy-status-orbit 1.5s linear infinite; }
.hy-ui-trace-row strong { display: block; padding-top: 2px; color: var(--hy-text); font-size: 12px; font-weight: 550; line-height: 1.6; overflow-wrap: anywhere; }
.hy-ui-trace-row small { display: block; margin-top: 4px; color: var(--hy-muted); font-size: 11px; line-height: 1.65; overflow-wrap: anywhere; }
.hy-ui-trace-row .hy-ui-elapsed { font-size: 10px; }

.hy-ui-stream-text { min-width: 0; font-size: 15px; line-height: 1.75; overflow-wrap: anywhere; }
.hy-ui-stream-word { animation: hy-ui-word-arrive .18s ease-out both; }
.hy-ui-stream-cursor { display: none; width: 4px; height: 1em; margin-left: 4px; border-radius: 2px; vertical-align: text-bottom; background: var(--hy-pink); }
.hy-ui-stream-cursor[data-active="true"] { display: inline-block; animation: hy-cursor 1.2s ease-in-out infinite; }
.hy-ui-source-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; min-width: 44px; max-width: 100%; margin: 2px 5px 2px 0; padding: 6px 9px; border: 1px solid color-mix(in oklch, var(--hy-blue) 35%, var(--hy-line)); border-radius: 10px; background: var(--hy-panel); color: var(--hy-blue); font: 11px/1.5 var(--hy-mono); text-decoration: none; vertical-align: middle; overflow-wrap: anywhere; }
.hy-ui-source-chip:hover { background: var(--hy-hover); border-color: var(--hy-blue); }
.hy-ui-source-chip img, .hy-ui-source-chip .hy-ui-source-avatar { width: 20px; height: 20px; flex: none; object-fit: cover; border-radius: 5px; }
.hy-ui-sources { margin: 10px 0; }
.hy-ui-sources > summary, .hy-ui-sources-summary { display: flex; align-items: center; gap: 8px; min-height: 44px; width: fit-content; max-width: 100%; padding: 6px 10px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-panel); color: var(--hy-muted); cursor: pointer; list-style: none; font-size: 12px; }
.hy-ui-avatar-stack { display: inline-flex; flex: none; padding-left: 3px; }
.hy-ui-avatar-stack img { width: 23px; height: 23px; margin-left: -3px; object-fit: cover; border: 2px solid var(--hy-bg); border-radius: 50%; }
.hy-ui-source-list { display: grid; gap: 4px; min-width: 0; margin-top: 8px; padding: 5px; border: 1px solid var(--hy-line); border-radius: 12px; background: var(--hy-panel); }
.hy-ui-source-row, .hy-ui-source-list > a { display: flex; align-items: center; gap: 9px; min-width: 0; min-height: 48px; padding: 8px; border: 0; border-radius: 8px; color: var(--hy-text); font-size: 12px; text-decoration: none; }
.hy-ui-source-row:hover, .hy-ui-source-list > a:hover { background: var(--hy-hover); }
.hy-ui-source-avatar { width: 28px; height: 28px; flex: none; object-fit: cover; border-radius: 7px; }
.hy-ui-source-copy { display: grid; gap: 3px; min-width: 0; flex: 1; }
.hy-ui-source-copy strong { font-weight: 550; font-size: 12px; overflow-wrap: anywhere; }
.hy-ui-source-copy small { color: var(--hy-muted); font: 10px/1.5 var(--hy-mono); overflow-wrap: anywhere; }
.hy-ui-followups, .hy-ui-follow-ups { display: grid; gap: 4px; margin-top: 12px; }
.hy-ui-followup, .hy-ui-follow-up { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 9px 10px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-panel); color: var(--hy-text); text-align: left; font-size: 12px; line-height: 1.5; }
.hy-ui-followup:hover, .hy-ui-follow-up:hover { border-color: var(--hy-violet); background: var(--hy-hover); }
.hy-ui-followup svg, .hy-ui-follow-up svg { width: 15px; height: 15px; color: var(--hy-violet); flex: none; }

.hy-ui-recommendation { --hy-ui-hue: var(--hy-violet); margin: 12px 0; }
.hy-ui-recommendation .hy-ui-card-header > svg { width: 22px; height: 22px; flex: none; color: var(--hy-ui-hue); }
.hy-ui-recommendation .hy-ui-card-body { color: var(--hy-muted); }
.hy-ui-recommendation .hy-ui-card-body strong { color: var(--hy-text); }
.hy-ui-alternatives { border-top: 1px solid var(--hy-line); margin: 0; padding: 0 14px; }
.hy-ui-alternatives > summary { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 2px; color: var(--hy-muted); font-size: 12px; cursor: pointer; list-style: none; }
.hy-ui-alternatives > summary:hover { color: var(--hy-text); }
.hy-ui-alternative, .hy-ui-alternatives button { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 5px 10px; width: 100%; min-height: 52px; margin-bottom: 8px; padding: 10px; border: 1px solid var(--hy-line); border-radius: 11px; background: var(--hy-panel); color: var(--hy-text); text-align: left; }
.hy-ui-alternative:hover, .hy-ui-alternatives button:hover { border-color: var(--hy-ui-hue, var(--hy-violet)); background: var(--hy-hover); }
.hy-ui-alternative-title { flex: 1; min-width: 0; font-size: 12px; font-weight: 600; line-height: 1.5; overflow-wrap: anywhere; }
.hy-ui-alternative-meta { color: var(--hy-ui-hue, var(--hy-violet)); font: 11px/1.6 var(--hy-mono); }
.hy-ui-alternative-copy { width: 100%; color: var(--hy-muted); font-size: 12px; line-height: 1.6; }
.hy-ui-alternatives button[aria-selected="true"], .hy-ui-alternatives button[aria-pressed="true"] { border-color: var(--hy-green); background: color-mix(in oklch, var(--hy-green) 7%, var(--hy-bg)); }

.hy-ui-context-list, .hy-ui-context-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; min-width: 0; margin: 12px 0; }
.hy-ui-context-list > .hy-ui-card-header { grid-column: 1 / -1; padding: 0 2px 2px; }
.hy-ui-context-list > .hy-ui-card-header > small { margin-left: auto; color: var(--hy-muted); font: 11px/1.5 var(--hy-mono); }
.hy-ui-context-card { --hy-ui-hue: var(--hy-blue); display: flex; flex-direction: column; min-width: 0; padding: 13px 14px; }
.hy-ui-context-card > strong, .hy-ui-context-title { display: block; min-width: 0; margin: 0; color: var(--hy-text); font-size: 13px; font-weight: 650; line-height: 1.6; overflow-wrap: anywhere; }
.hy-ui-context-card > p, .hy-ui-context-content { margin: 9px 0; color: var(--hy-muted); font-size: 12px; line-height: 1.7; overflow-wrap: anywhere; }
.hy-ui-context-head { display: flex; align-items: center; gap: 9px; min-width: 0; }
.hy-ui-context-icon { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border: 1px solid color-mix(in oklch, var(--hy-ui-hue) 35%, var(--hy-line)); border-radius: 9px; background: var(--hy-bg); color: var(--hy-ui-hue); }
.hy-ui-context-icon svg { width: 17px; height: 17px; }
.hy-ui-context-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: auto; padding-top: 8px; color: var(--hy-ui-hue); font: 10px/1.6 var(--hy-mono); overflow-wrap: anywhere; }
.hy-ui-context-card .hy-ui-actions { padding: 10px 0 0; }
.hy-ui-context-card > a { display: inline-flex; align-items: center; min-height: 44px; margin-top: 8px; color: var(--hy-ui-hue); font-size: 12px; overflow-wrap: anywhere; }
.hy-ui-context-card details > summary { min-height: 44px; padding-block: 10px; color: var(--hy-ui-hue); font-size: 12px; cursor: pointer; }

.hy-ui-filter-table { --hy-ui-hue: var(--hy-blue); margin: 12px 0; overflow: hidden; }
.hy-ui-filters { display: flex; align-items: center; gap: 7px; min-width: 0; padding: 10px 12px; overflow-x: auto; border-bottom: 1px solid var(--hy-line); scrollbar-width: thin; }
.hy-ui-filters button { display: inline-flex; align-items: center; gap: 7px; flex: none; min-height: 44px; min-width: 44px; padding: 8px 11px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-panel); color: var(--hy-muted); font-size: 12px; }
.hy-ui-filters button[aria-pressed="true"] { color: var(--hy-blue); border-color: var(--hy-blue); background: color-mix(in oklch, var(--hy-blue) 8%, var(--hy-bg)); }
.hy-ui-filters button:hover { background: var(--hy-hover); color: var(--hy-text); }
.hy-ui-filters button small { display: grid; place-items: center; min-width: 20px; padding: 1px 4px; border-radius: 5px; background: var(--hy-bg); color: currentColor; font: 10px/1.5 var(--hy-mono); font-variant-numeric: tabular-nums; }
.hy-ui-filter-search { width: min(240px, 100%); min-width: 140px; min-height: 44px; padding: 8px 10px; border: 1px solid var(--hy-line); border-radius: 10px; background: var(--hy-bg); color: var(--hy-text); font-size: 16px; }
.hy-ui-table-count { padding: 9px 12px; font-variant-numeric: tabular-nums; }
.hy-ui-table-wrap, .hy-ui-filter-table > .hy-table-scroll { min-width: 0; max-width: 100%; max-height: min(520px, 70dvh); margin: 0; overflow: auto; overscroll-behavior: contain; border: 0; border-radius: 0; scrollbar-width: thin; }
.hy-ui-filter-table table, .hy-ui-records-table { width: 100%; min-width: 480px; border-collapse: collapse; font-size: 12px; line-height: 1.6; }
.hy-ui-filter-table th, .hy-ui-filter-table td { padding: 11px 13px; border-bottom: 1px solid var(--hy-line); text-align: left; vertical-align: middle; overflow-wrap: anywhere; }
.hy-ui-filter-table th { position: sticky; top: 0; z-index: 1; color: var(--hy-blue); background: var(--hy-panel-strong); font-weight: 600; }
.hy-ui-filter-table th button { display: flex; align-items: center; justify-content: space-between; gap: 6px; width: 100%; min-height: 44px; min-width: 44px; padding: 0; border: 0; background: transparent; color: inherit; text-align: left; font-size: inherit; }
.hy-ui-filter-table tbody tr:last-child td { border-bottom: 0; }
.hy-ui-filter-table tbody tr:hover { background: var(--hy-panel); }
.hy-ui-filter-table tr[data-selected="true"] { background: color-mix(in oklch, var(--hy-blue) 7%, var(--hy-bg)); }
.hy-ui-status { --hy-ui-status-color: var(--hy-muted); display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border: 1px solid color-mix(in oklch, var(--hy-ui-status-color) 35%, var(--hy-line)); border-radius: 99px; background: color-mix(in oklch, var(--hy-ui-status-color) 6%, var(--hy-bg)); color: var(--hy-ui-status-color); font: 10px/1.5 var(--hy-mono); white-space: nowrap; }
.hy-ui-status[data-status="complete"], .hy-ui-status[data-status="completed"], .hy-ui-status[data-status="done"], .hy-ui-status[data-status="healthy"] { --hy-ui-status-color: var(--hy-green); }
.hy-ui-status[data-status="running"], .hy-ui-status[data-status="active"], .hy-ui-status[data-status="processing"] { --hy-ui-status-color: var(--hy-violet); }
.hy-ui-status[data-status="failed"], .hy-ui-status[data-status="error"] { --hy-ui-status-color: var(--hy-red); }
.hy-ui-status[data-status="pending"], .hy-ui-status[data-status="queued"], .hy-ui-status[data-status="cancelled"], .hy-ui-status[data-status="declined"] { --hy-ui-status-color: var(--hy-amber); }

.hy-code-block .hy-ui-code-body { display: block; width: 100%; min-width: 0; max-width: 100%; max-height: min(560px, 70dvh); margin: 0; padding: 12px 0; overflow: auto; overscroll-behavior: contain; white-space: pre; tab-size: 2; scrollbar-width: thin; font: 12.5px/1.75 var(--hy-mono); background: var(--hy-bg); }
.hy-ui-code-body pre, .hy-ui-code-body code { display: block; margin: 0; padding: 0; overflow: visible; background: none; font: inherit; color: var(--hy-text); }
.hy-ui-code-line { display: grid; grid-template-columns: 4.5ch minmax(max-content, 1fr); min-width: 100%; width: max-content; padding-right: 18px; min-height: 1.75em; font: inherit; white-space: pre; }
.hy-ui-line-number { display: block; padding: 0 10px 0 8px; border-right: 1px solid var(--hy-line); color: var(--hy-muted); opacity: .8; text-align: right; user-select: none; font-variant-numeric: tabular-nums; }
.hy-ui-line-code { display: block; min-width: 0; padding-left: 13px; white-space: pre; }
.hy-ui-token-keyword, .hy-ui-token-tag { color: var(--hy-pink); }
.hy-ui-token-string { color: var(--hy-green); }
.hy-ui-token-number { color: var(--hy-amber); }
.hy-ui-token-comment { color: var(--hy-muted); font-style: italic; }
.hy-ui-token-function { color: var(--hy-cyan); }
.hy-ui-token-property { color: var(--hy-blue); }
.hy-ui-token-operator { color: var(--hy-violet); }
.hy-ui-token-punctuation { color: var(--hy-muted); }
.hy-ui-code-line:is([data-change="add"], [data-change="added"], [data-change="insert"]) { background: color-mix(in oklch, var(--hy-green) 8%, var(--hy-bg)); box-shadow: inset 3px 0 0 var(--hy-green); }
.hy-ui-code-line:is([data-change="delete"], [data-change="deleted"], [data-change="remove"], [data-change="del"]) { background: color-mix(in oklch, var(--hy-red) 8%, var(--hy-bg)); box-shadow: inset 3px 0 0 var(--hy-red); }
.hy-ui-diff-piece:is([data-change="add"], [data-change="added"], [data-change="insert"]) { color: var(--hy-green); background: color-mix(in oklch, var(--hy-green) 14%, transparent); border-radius: 3px; }
.hy-ui-diff-piece:is([data-change="delete"], [data-change="deleted"], [data-change="remove"], [data-change="del"]) { color: var(--hy-red); background: color-mix(in oklch, var(--hy-red) 14%, transparent); border-radius: 3px; text-decoration: line-through; text-decoration-thickness: 1px; }
.hy-ui-code-filename { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hy-ui-code-language, .hy-ui-code-stats { color: var(--hy-muted); font: 10px/1.5 var(--hy-mono); }
@media (max-width: 700px) {
  .hy-ui-loader { gap: 9px; padding: 10px 11px; }
  .hy-ui-context-list, .hy-ui-context-grid { grid-template-columns: minmax(0, 1fr); }
  .hy-ui-card-header, .hy-ui-head { padding: 12px 13px 9px; }
  .hy-ui-card-body, .hy-ui-body { padding: 0 13px 12px; }
  .hy-ui-card-footer, .hy-ui-actions { padding: 10px 13px 12px; }
  .hy-ui-trace > summary { padding-inline: 11px; }
  .hy-ui-trace-rows { padding-inline: 11px; }
  .hy-ui-trace-row { gap: 8px; }
  .hy-ui-filters { padding: 8px; gap: 6px; }
  .hy-ui-source-chip { font-size: 10px; }
  .hy-code-block .hy-ui-code-body { font-size: 12px; }
  .hy-ui-line-number { padding-right: 7px; }
  .hy-ui-line-code { padding-left: 10px; }
}
@media (max-height: 540px) { .hy-ui-table-wrap, .hy-code-block .hy-ui-code-body { max-height: 220px; } }
@media (prefers-reduced-motion: reduce) { :is(.hy-ui-loader, .hy-ui-trace)[data-active="true"] .hy-ui-shimmer { background: none; color: var(--hy-text); } .hy-ui-stream-word { filter: none; } }

/* Final DOM alignment: primitives receive only application state and safe text. */
.hy-ui-loader { flex-wrap: wrap; }
.hy-ui-loader > .hy-ui-shimmer { flex: 1; }
.hy-ui-focus-break { flex: 0 0 100%; min-width: 0; border-top: 1px solid var(--hy-line); }
.hy-ui-focus-break > summary { min-height: 44px; padding-block: 11px; color: var(--hy-muted); font-size: 12px; cursor: pointer; }
.hy-ui-focus-break video { display: block; width: 100%; max-height: 260px; border-radius: 10px; background: var(--hy-bg); }
.hy-ui-trace-row > .hy-ui-trace-dot { grid-column: 1; grid-row: 1 / span 3; }
.hy-ui-trace-row > strong, .hy-ui-trace-row > small { grid-column: 2; }
.hy-ui-trace-row > small { margin-top: 0; }
.hy-ui-trace-row { row-gap: 3px; text-decoration: none; }
.hy-ui-trace-query { margin: 0 0 10px 34px; color: var(--hy-cyan); font: 11px/1.6 var(--hy-mono); overflow-wrap: anywhere; }
.hy-ui-diff-stat { color: var(--hy-muted); font: 10px/1.5 var(--hy-mono); font-variant-numeric: tabular-nums; }
.hy-ui-source-list > summary { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 7px 10px; color: var(--hy-blue); cursor: pointer; list-style: none; font-size: 12px; }
.hy-ui-source-list > summary::-webkit-details-marker { display: none; }
.hy-ui-source-list > summary::after { content: '+'; margin-left: auto; color: var(--hy-muted); font: 16px/1 var(--hy-mono); }
.hy-ui-source-list[open] > summary::after { content: '−'; }
.hy-ui-source-list > .hy-ui-source-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; }
.hy-ui-source-list > .hy-ui-source-row > strong { min-width: 0; color: var(--hy-text); font-size: 12px; font-weight: 550; line-height: 1.6; overflow-wrap: anywhere; }
.hy-ui-source-list > .hy-ui-source-row > p { grid-column: 1 / -1; margin: 0; color: var(--hy-muted); font-size: 12px; line-height: 1.65; overflow-wrap: anywhere; }
.hy-ui-source-row .hy-ui-source-chip { max-width: 160px; margin: 0; }
.hy-ui-recommendation.hy-part-card { padding: 0; }
.hy-ui-card-header { font-size: 14px; font-weight: 600; line-height: 1.5; }
.hy-ui-signal { flex: 1; color: var(--hy-violet); font: 11px/1.5 var(--hy-mono); }
.hy-ui-context-card > .hy-ui-context-meta { margin-top: 0; padding-top: 0; align-items: baseline; }
.hy-ui-context-meta > strong { flex: 1; min-width: 0; color: var(--hy-text); font: 600 13px/1.6 ui-sans-serif, system-ui, sans-serif; overflow-wrap: anywhere; }
.hy-ui-context-meta > small { color: var(--hy-muted); font: 10px/1.6 var(--hy-mono); }
.hy-ui-filter-table > h3 { margin: 0; padding: 14px 16px 10px; font-size: 14px; font-weight: 600; line-height: 1.5; }
.hy-ui-status[data-status="progress"] { --hy-ui-status-color: var(--hy-violet); }
.hy-ui-status[data-status="todo"], .hy-ui-status[data-status="interrupted"] { --hy-ui-status-color: var(--hy-amber); }
.hy-code-head:has(.hy-ui-code-tools) { flex-wrap: wrap; gap: 6px; }
.hy-ui-code-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; margin-left: auto; }
.hy-ui-code-body code:has(> .hy-ui-code-line) { white-space: normal; }
.hy-ui-code[data-wrap="true"] .hy-ui-code-line { width: 100%; grid-template-columns: 4.5ch minmax(0, 1fr); }
.hy-ui-code[data-wrap="true"] .hy-ui-line-code { white-space: pre-wrap; overflow-wrap: anywhere; }
.hy-ui-follow-ups > h4 { margin: 0 0 5px; color: var(--hy-muted); font-size: 12px; font-weight: 550; }
.hy-ui-selection-tools { position: absolute; z-index: 12; top: 80px; right: 24px; display: flex; align-items: center; flex-wrap: wrap; gap: 3px; width: max-content; max-width: calc(100% - 32px); padding: 4px; border: 1px solid color-mix(in oklch, var(--hy-pink) 55%, var(--hy-line)); border-radius: 13px; background: var(--hy-panel-strong); box-shadow: var(--hy-shadow); }
.hy-ui-selection-tools .hy-action-btn { color: var(--hy-text); }
.hy-ui-selection-tools .hy-action-btn:hover { color: var(--hy-pink); }
.hy-ui-stream-chunk { animation: hy-ui-word-arrive .14s ease-out both; }
@media (max-width: 700px) { .hy-ui-selection-tools { top: 70px; right: 12px; max-width: calc(100% - 24px); } }
.hy-ui-status[data-status="blocked"], .hy-ui-status[data-status="review"], .hy-ui-status[data-status="queued"] { --hy-ui-status-color: var(--hy-amber); }
.hy-ui-status[data-status="neutral"] { --hy-ui-status-color: var(--hy-muted); }
.hy-ui-trace-row[data-status="blocked"], .hy-ui-trace-row[data-status="review"], .hy-ui-trace-row[data-status="queued"] { --hy-ui-step-color: var(--hy-amber); }

/* Personality settings — bounded style layer, V16-native */
.hy-personality-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding:4px 0 14px;border-bottom:1px solid var(--hy-line)}
.hy-personality-head strong{display:block;font-size:15px}.hy-personality-head small{display:block;margin-top:5px;color:var(--hy-muted);line-height:1.55}
.hy-personality-lock{display:flex;gap:11px;align-items:flex-start;margin:14px 0;padding:12px 14px;border:1px solid color-mix(in oklch,var(--hy-green) 35%,var(--hy-line));border-radius:13px;background:color-mix(in oklch,var(--hy-green) 5%,var(--hy-panel))}
.hy-personality-lock>span{font-size:18px}.hy-personality-lock strong{display:block;font-size:12px;color:var(--hy-green)}.hy-personality-lock small{display:block;margin-top:4px;color:var(--hy-muted);font-size:11px;line-height:1.5}
.hy-personality-section{margin-top:18px}.hy-personality-section>strong,.hy-personality-section-head strong{font-size:12px}.hy-personality-section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:9px}
.hy-personality-presets{display:flex;flex-wrap:wrap;gap:7px;margin-top:9px}.hy-personality-presets button{min-height:38px;padding:7px 11px;border:1px solid var(--hy-line);border-radius:99px;background:var(--hy-panel);font-size:11px}.hy-personality-presets button:hover{border-color:var(--hy-violet);background:var(--hy-hover)}
.hy-personality-controls{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:16px}
.hy-personality-toggle,.hy-personality-field{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:68px;padding:11px 12px;border:1px solid var(--hy-line);border-radius:12px;background:var(--hy-panel)}
.hy-personality-toggle strong,.hy-personality-field strong{display:block;font-size:12px}.hy-personality-toggle small,.hy-personality-field small{display:block;margin-top:3px;color:var(--hy-muted);font-size:10px;line-height:1.35}
.hy-personality-toggle input[type=checkbox]{width:22px;height:22px;flex:none;accent-color:var(--hy-violet)}.hy-personality-field select{min-height:38px;padding:6px 8px;border:1px solid var(--hy-line);border-radius:9px;background:var(--hy-panel-strong)}
.hy-personality-field input[type=range]{width:120px;accent-color:var(--hy-violet)}
.hy-personality-modules{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
.hy-personality-module{display:flex;align-items:center;justify-content:space-between;gap:9px;padding:10px 11px;border:1px solid var(--hy-line);border-radius:11px;background:var(--hy-panel)}
.hy-personality-module[data-active=true]{border-color:color-mix(in oklch,var(--hy-violet) 55%,var(--hy-line));background:color-mix(in oklch,var(--hy-violet) 7%,var(--hy-panel))}
.hy-personality-module-copy{min-width:0}.hy-personality-module-copy strong{display:block;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.hy-personality-module-copy small{display:block;margin-top:3px;color:var(--hy-muted);font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hy-personality-module input{width:20px;height:20px;flex:none;accent-color:var(--hy-violet)}
.hy-personality-conflicts{margin-top:8px;color:var(--hy-muted);font-size:11px;line-height:1.55}.hy-personality-conflicts[data-state=clean]{color:var(--hy-green)}.hy-personality-conflicts[data-state=warn]{color:var(--hy-amber)}.hy-personality-conflicts[data-state=error]{color:var(--hy-red)}
.hy-personality-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:18px;padding-top:14px;border-top:1px solid var(--hy-line)}
/* V17 product surface, layered inside the existing Blackhole Chroma foreground. */
.hy-v17-controls{display:flex;align-items:center;gap:9px;flex-wrap:wrap;padding:9px 24px;border-bottom:1px solid var(--hy-line);background:color-mix(in oklch,var(--hy-panel) 82%,transparent)}
.hy-mode-control,.hy-context-picker,.hy-activity-disclosure,.hy-context-meter{font-size:11px;color:var(--hy-muted)}.hy-mode-control{display:flex;align-items:center;gap:7px}.hy-mode-control select{min-height:34px;padding:5px 27px 5px 10px;border:1px solid color-mix(in oklch,var(--hy-violet) 42%,var(--hy-line));border-radius:10px;background:var(--hy-panel-strong);color:var(--hy-text);font:600 11px var(--hy-mono)}
.hy-context-picker summary,.hy-activity-disclosure summary{display:flex;align-items:center;gap:7px;min-height:34px;padding:7px 10px;border:1px solid var(--hy-line);border-radius:10px;background:var(--hy-panel);cursor:pointer;list-style:none}.hy-context-picker summary::-webkit-details-marker,.hy-activity-disclosure summary::-webkit-details-marker{display:none}.hy-context-picker[open] summary,.hy-activity-disclosure[open] summary{border-color:var(--hy-violet);color:var(--hy-text)}
.hy-context-menu{position:absolute;z-index:20;width:min(520px,calc(100vw - 32px));margin-top:6px;padding:13px;border:1px solid color-mix(in oklch,var(--hy-violet) 40%,var(--hy-line));border-radius:14px;background:var(--hy-panel-strong);box-shadow:var(--hy-shadow)}.hy-context-menu p,.hy-activity-disclosure p{margin:0 0 10px;color:var(--hy-muted);font-size:10px;line-height:1.5}.hy-context-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.hy-context-options label{display:flex;align-items:flex-start;gap:6px;padding:9px;border:1px solid var(--hy-line);border-radius:9px;background:var(--hy-panel);color:var(--hy-text);font-size:11px}.hy-context-options small{display:block;color:var(--hy-muted);font-size:9px;line-height:1.3}.hy-context-options input{accent-color:var(--hy-violet);margin-top:2px}
.hy-activity-disclosure{position:relative}.hy-activity-disclosure summary span{color:var(--hy-violet);font:10px var(--hy-mono)}.hy-activity-disclosure p{position:absolute;z-index:10;top:40px;left:0;width:220px;padding:10px;border:1px solid var(--hy-line);border-radius:10px;background:var(--hy-panel-strong);box-shadow:var(--hy-shadow)}.hy-context-meter{display:flex;align-items:center;gap:7px;margin-left:auto}.hy-context-meter meter{width:100px;height:7px;accent-color:var(--hy-violet)}.hy-context-meter small{font:10px var(--hy-mono);white-space:nowrap}
@media(max-width:700px){.hy-v17-controls{padding:8px 12px}.hy-context-options{grid-template-columns:repeat(2,minmax(0,1fr))}.hy-context-meter{width:100%;margin-left:0}.hy-context-meter meter{flex:1}.hy-mode-control{flex:1}.hy-mode-control select{flex:1}}
@media(max-width:600px){.hy-personality-controls,.hy-personality-modules{grid-template-columns:1fr}.hy-personality-field input[type=range]{width:100px}.hy-personality-actions{justify-content:stretch}.hy-personality-actions .hy-btn{flex:1}}

.hy-load-earlier{display:block;margin:8px auto 18px}.hy-trace-meta{font:600 12px/1.4 var(--hy-mono);opacity:.72;margin-bottom:12px}.hy-trace-row{padding:10px 12px;border:1px solid var(--hy-border);border-radius:12px;margin:8px 0;background:var(--hy-panel)}
.hy-compaction-provenance{display:block;margin:-4px 0 10px;color:var(--hy-muted);font:10px var(--hy-mono)}.hy-trace-receipt{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px 12px;padding:9px 0;border-bottom:1px solid var(--hy-line)}.hy-trace-receipt small{grid-column:1/-1;color:var(--hy-muted);white-space:pre-wrap}.hy-trace-receipt span{color:var(--hy-violet);font:10px var(--hy-mono)}

@media(max-width:700px){button,.hy-btn,.hy-icon-btn,select,.hy-context-picker summary{min-height:44px}.hy-context-options label{min-height:44px}}

.hy-voice-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}.hy-voice-actions .hy-btn{flex:1;min-width:110px}
.hy-modal-head #voice-minimize { margin-left: auto; }
@keyframes hy-voice-breathe { 0%,100% { transform: scale(1); opacity: .86; } 50% { transform: scale(1.035); opacity: 1; } }
@media(max-width:700px){
  .hy-v17-controls{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px 10px;padding:8px 12px}
  .hy-mode-control{grid-column:1}.hy-context-picker{grid-column:2;position:relative}
  .hy-activity-disclosure{grid-column:1}.hy-context-meter{grid-column:2;width:auto;margin-left:0}
  .hy-context-meter meter{width:82px;flex:none}
  .hy-context-menu{left:auto;right:0;width:calc(100vw - 32px);max-height:52dvh;overflow:auto}
  .hy-context-options{grid-template-columns:1fr}
  .hy-tabs{overflow-x:auto;flex-wrap:nowrap;scrollbar-width:none;-webkit-overflow-scrolling:touch;padding-bottom:2px}.hy-tabs::-webkit-scrollbar{display:none}.hy-tabs .hy-tab{flex:0 0 auto}
  .hy-voice-actions{display:grid;grid-template-columns:1fr 1fr}
}

.hy-ridealong-panel{position:fixed;inset:0;z-index:9850;background:var(--hy-bg,#090b10);flex-direction:column}.hy-ridealong-head{display:flex;align-items:center;gap:8px;padding:10px 14px;border-bottom:1px solid var(--hy-line);min-height:52px}.hy-ridealong-head strong{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.hy-ridealong-panel iframe{flex:1;min-height:0;width:100%;border:0;background:#fff}
@media(max-width:700px){.hy-mode-control select{min-height:44px}#prompt-slash,#prompt-model{min-height:44px}.hy-prompt-slots{min-height:44px}}

.hy-audio-preview{width:100%;max-width:560px;margin-top:8px}
@media(max-width:700px){.hy-mode-control select,#prompt-slash,#prompt-model,.hy-prompt-slots{min-height:44px}}
