﻿:root {
  color-scheme: dark;
  --bg: #0b0c0e;
  --sidebar: #0e0f12;
  --surface: #121418;
  --surface-2: #17191e;
  --surface-3: #1c1f24;
  --line: #292c32;
  --line-strong: #3a3e45;
  --text: #f3f1ec;
  --muted: #aaa7a0;
  --quiet: #8b8a87;
  --brand: #f15a24;
  --brand-hover: #ff7143;
  --brand-ink: #ffffff;
  --red: #ff756d;
  --amber: #e4b05a;
  --green: #6cc292;
  --blue: #82aef6;
  --focus: #ff9a75;
  --on-brand: #ffffff;
  --accent-text: #ff9f7c;
  --accent-soft: rgba(241,90,36,.07);
  --accent-line: rgba(241,90,36,.42);
  --success-text: #91d6ae;
  --success-soft: rgba(108,194,146,.07);
  --success-line: rgba(108,194,146,.35);
  --danger-text: #ff9b95;
  --danger-soft: rgba(255,117,109,.07);
  --danger-line: rgba(255,117,109,.34);
  --warning-text: #f0c980;
  --warning-soft: rgba(228,176,90,.07);
  --warning-line: rgba(228,176,90,.34);
  --info-soft: rgba(130,174,246,.08);
  --banner: #111318;
  --row-hover: rgba(255,255,255,.018);
  --placeholder: #858680;
  --skeleton: #1e2126;
  --shimmer: rgba(255,255,255,.045);
  --avatar-bg: #2b211e;
  --avatar-text: #ffb397;
  --overlay-bg: rgba(0,0,0,.56);
  --modal-overlay: rgba(0,0,0,.65);
  --elevation-shadow: rgba(0,0,0,.38);
  --mobile-header-bg: rgba(11,12,14,.97);
  --mobile-nav-bg: rgba(14,15,18,.985);
  --radius: 8px;
  --sidebar-width: 232px;
  --mobile-nav-height: 70px;
  --mobile-header-height: 58px;
  --ease: 170ms ease;
  font-family: "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: oklch(98% .004 45);
  --sidebar: oklch(96.5% .006 45);
  --surface: oklch(100% 0 0);
  --surface-2: oklch(96% .005 45);
  --surface-3: oklch(92.5% .007 45);
  --line: oklch(87% .006 45);
  --line-strong: oklch(72% .009 45);
  --text: oklch(22% .012 45);
  --muted: oklch(42% .012 45);
  --quiet: oklch(48% .01 45);
  --brand: #e9551f;
  --brand-hover: #d94814;
  --brand-ink: #ffffff;
  --red: #b42318;
  --amber: #8a5b0a;
  --green: #167044;
  --blue: #245f9e;
  --focus: #c94010;
  --accent-text: #a9360d;
  --accent-soft: #fff1eb;
  --accent-line: #e9a78e;
  --success-text: #17623e;
  --success-soft: #edf8f1;
  --success-line: #9bc9ad;
  --danger-text: #a92d25;
  --danger-soft: #fff2f0;
  --danger-line: #e5aaa5;
  --warning-text: #77500d;
  --warning-soft: #fff8e8;
  --warning-line: #dec58e;
  --info-soft: #edf4fb;
  --banner: #f1f3f4;
  --row-hover: #f4f5f5;
  --placeholder: #686a67;
  --skeleton: #e8eaeb;
  --shimmer: rgba(255,255,255,.72);
  --avatar-bg: #fee8df;
  --avatar-text: #923511;
  --overlay-bg: rgba(24,25,27,.34);
  --modal-overlay: rgba(24,25,27,.42);
  --elevation-shadow: rgba(24,25,27,.16);
  --mobile-header-bg: rgba(247,247,246,.97);
  --mobile-nav-bg: rgba(244,245,245,.985);
}

* { box-sizing: border-box; }
html, body { width: 100%; min-height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); overflow: hidden; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
[hidden] { display: none !important; }
svg { display: block; }
.svg-sprite { position: absolute; }
.icon { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon--sm { width: 16px; height: 16px; }
.icon--lg { width: 24px; height: 24px; }
.icon--xl { width: 30px; height: 30px; }
.numeric { font-variant-numeric: tabular-nums; }
.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; }

.app-shell { min-height: 100dvh; display: grid; grid-template-columns: var(--sidebar-width) minmax(0, 1fr); }
.sidebar {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 18px 14px 14px;
  border-right: 1px solid var(--line);
  background: var(--sidebar);
}
.brand { width: 100%; min-height: 44px; display: flex; align-items: center; gap: 11px; padding: 0 9px; border: 0; background: transparent; color: inherit; cursor: pointer; text-align: left; }
.brand-mark { width: 32px; height: 32px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 8px; background: var(--brand); color: #fff; }
.brand-mark svg { width: 19px; height: 19px; fill: currentColor; stroke: none; }
.brand-mark.brand-mark--logo {
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.brand-mark--logo img { width: 100%; height: 100%; padding: 3px; object-fit: contain; }
.brand-copy { min-width: 0; }
.brand-copy strong, .brand-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-copy strong { font-size: 15px; letter-spacing: -.015em; }
.brand-copy span { margin-top: 2px; color: var(--quiet); font-size: 11px; }

.primary-nav { display: grid; gap: 3px; margin-top: 26px; }
.nav-item {
  position: relative;
  width: 100%; min-height: 42px;
  display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 9px;
  padding: 0 11px; border: 0; border-radius: 7px; background: transparent; color: var(--muted);
  cursor: pointer; text-align: left; transition: background var(--ease), color var(--ease);
}
.nav-item::before { content: ""; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 2px; background: transparent; }
.nav-item:hover { background: var(--surface); color: var(--text); }
.nav-item.is-active { background: var(--surface-2); color: var(--text); }
.nav-item.is-active::before { background: var(--brand); }
.nav-item > span:not(.nav-count) { font-size: 14px; font-weight: 600; }
.nav-count { min-width: 20px; height: 20px; display: grid; place-items: center; padding: 0 5px; border-radius: 6px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; }
.nav-count--quiet { border: 1px solid var(--line-strong); background: transparent; color: var(--muted); }
.sidebar-status { margin: 25px 9px 0; padding-top: 18px; border-top: 1px solid var(--line); }
.status-line { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.status-line + p { margin: 7px 0 0; color: var(--quiet); font-size: 12px; line-height: 1.45; }
.status-dot { width: 7px; height: 7px; flex: 0 0 auto; border-radius: 50%; background: var(--green); }
.status-dot--amber { background: var(--amber); }
.status-dot--red { background: var(--red); }
.sidebar-spacer { flex: 1; }
.prototype-trigger { width: calc(100% - 12px); min-height: 36px; margin: 0 6px 9px; border: 1px dashed var(--line-strong); border-radius: 7px; background: transparent; color: var(--quiet); cursor: pointer; font-size: 11px; }
.prototype-trigger:hover { color: var(--text); border-color: #5b5f66; }
.account-row { display: grid; grid-template-columns: minmax(0,1fr) 40px; align-items: center; gap: 4px; }
.account-button { width: 100%; min-height: 52px; display: grid; grid-template-columns: minmax(0,1fr) 18px; align-items: center; gap: 9px; padding: 9px 8px 9px 10px; border: 0; border-radius: 8px; background: transparent; cursor: pointer; text-align: left; }
.account-button:hover { background: var(--surface); }
.quick-theme-toggle { width: 40px; height: 40px; display: grid; place-items: center; padding: 0; border: 1px solid var(--line); border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; }
.quick-theme-toggle:hover { border-color: var(--line-strong); background: var(--surface-2); color: var(--text); }
.quick-theme-toggle .theme-icon { grid-area: 1 / 1; }
.theme-icon--moon { display: none; }
html[data-theme="light"] .theme-icon--sun { display: none; }
html[data-theme="light"] .theme-icon--moon { display: block; }
.avatar { width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 8px; background: var(--avatar-bg); color: var(--avatar-text); font-size: 12px; font-weight: 750; cursor: pointer; }
.account-copy { min-width: 0; }
.account-copy strong, .account-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-copy strong { font-size: 13px; }
.account-copy span { margin-top: 2px; color: var(--quiet); font-size: 11px; }

.workspace { position: relative; min-width: 0; height: 100dvh; overflow: hidden; }
.mobile-header, .mobile-nav { display: none; }
.app-view { height: 100%; overflow: hidden; }
.view-scroll { height: 100%; overflow: auto; scrollbar-gutter: stable; }
.page { min-height: 100%; }
.page-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 26px; padding: 30px 34px 23px; }
.page-header--border { border-bottom: 1px solid var(--line); }
.page-header__copy { max-width: 760px; }
.eyebrow { margin: 0 0 8px; color: var(--muted); font-size: 12px; font-weight: 650; }
.page-header h1 { margin: 0; font-size: 29px; line-height: 1.15; letter-spacing: -.035em; font-weight: 680; }
.page-header p:not(.eyebrow) { max-width: 720px; margin: 9px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.page-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 9px; }

.button {
  min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--surface-2); color: var(--text);
  cursor: pointer; font-size: 13px; font-weight: 650; text-decoration: none; transition: border-color var(--ease), background var(--ease), color var(--ease), opacity var(--ease);
}
.button:hover { border-color: #575b63; background: var(--surface-3); }
.button--primary { border-color: var(--brand); background: var(--brand); color: #fff; }
.button--primary:hover { border-color: var(--brand-hover); background: var(--brand-hover); color: #fff; }
.button--quiet { background: transparent; }
.button--text { min-height: 34px; padding: 0; border: 0; background: transparent; color: var(--muted); }
.button--text:hover { background: transparent; color: var(--text); }
.button--danger { color: var(--danger-text); }
.button:disabled { cursor: not-allowed; opacity: .45; }
.icon-button { width: 40px; height: 40px; flex: 0 0 auto; display: grid; place-items: center; padding: 0; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--surface-2); color: var(--muted); cursor: pointer; }
.icon-button:hover { color: var(--text); background: var(--surface-3); }
.tag { display: inline-flex; align-items: center; gap: 6px; min-height: 24px; padding: 0 8px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); font-size: 10px; font-weight: 650; }
.tag--orange { border-color: var(--accent-line); color: var(--accent-text); }
.tag--green { border-color: var(--success-line); color: var(--success-text); }
.tag--amber { border-color: var(--amber); color: var(--warning-text); }
.tag--red { border-color: var(--red); color: var(--danger-text); }
.text-link { display: inline-flex; align-items: center; gap: 7px; padding: 0; border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 12px; }
.text-link:hover { color: var(--text); }

.section-tabs { display: flex; gap: 22px; margin: 0 34px; border-bottom: 1px solid var(--line); }
.section-tab { position: relative; min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--quiet); cursor: pointer; font-size: 12px; font-weight: 650; white-space: nowrap; }
.section-tab:hover { color: var(--text); }
.section-tab.is-active { color: var(--text); }
.section-tab.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--brand); }
.section-tab .tab-count { margin-left: 6px; color: var(--accent-text); font-variant-numeric: tabular-nums; }

.global-banner { min-height: 42px; display: flex; align-items: center; gap: 10px; padding: 8px 24px; border-bottom: 1px solid var(--line); color: var(--muted); background: var(--banner); font-size: 12px; line-height: 1.4; }
.global-banner strong { color: var(--text); }
.global-banner .button { min-height: 30px; margin-left: auto; font-size: 11px; }
.global-banner--warn { border-bottom-color: rgba(228,176,90,.28); }
.global-banner--error { border-bottom-color: rgba(255,117,109,.3); }
.global-banner--offline { border-bottom-color: rgba(130,174,246,.26); }

/* Za pažnju */
.attention-layout {
  height: 100%; display: grid; grid-template-columns: minmax(520px, 1fr) minmax(350px, 390px);
  align-items: start; overflow-y: auto; scrollbar-gutter: stable;
}
.attention-layout--single { grid-template-columns: 1fr; }
.attention-main { min-width: 0; min-height: 100%; }
.attention-main .page-header { padding-bottom: 18px; }
.attention-content { padding: 0 34px 36px; }
.list-heading { min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); }
.attention-content > .list-heading > div { display: flex; align-items: center; gap: 18px; }
.list-heading strong { font-size: 13px; }
.list-heading span { color: var(--quiet); font-size: 12px; }
.priority-list { display: grid; }
.priority-row {
  position: relative; width: 100%; display: grid; grid-template-columns: 31px minmax(0,1fr) auto; gap: 13px; align-items: start;
  padding: 19px 12px 19px 8px; border: 0; border-bottom: 1px solid var(--line); background: transparent; cursor: pointer; text-align: left;
}
.priority-row::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 2px; background: transparent; }
.priority-row:hover { background: var(--row-hover); }
.priority-row.is-selected { background: var(--surface); }
.priority-row.is-selected::before { background: var(--brand); }
.priority-rank { width: 25px; height: 25px; display: grid; place-items: center; margin-top: 1px; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--muted); font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; }
.priority-row.is-selected .priority-rank { border-color: rgba(241,90,36,.66); color: var(--accent-text); }
.priority-copy { min-width: 0; }
.priority-copy strong { display: block; font-size: 15px; line-height: 1.35; letter-spacing: -.012em; }
.priority-copy p { margin: 6px 0 0; color: var(--muted); font-size: 13px; line-height: 1.47; }
.meta-line { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 9px; color: var(--quiet); font-size: 11px; overflow-wrap: anywhere; }
.meta-line .status-dot { width: 6px; height: 6px; }
.priority-value { min-width: 92px; padding-top: 1px; text-align: right; }
.priority-value strong { display: block; font-size: 17px; line-height: 1.2; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.priority-value span { display: block; margin-top: 4px; color: var(--quiet); font-size: 11px; }
.quiet-summary { display: flex; align-items: flex-start; gap: 11px; margin-top: 24px; padding: 16px 0; border-top: 1px solid var(--line); color: var(--muted); }
.quiet-summary > .icon { flex: 0 0 auto; color: var(--green); }
.quiet-summary strong { display: block; color: var(--text); font-size: 13px; }
.quiet-summary p { margin: 3px 0 0; color: var(--quiet); font-size: 12px; line-height: 1.45; }
.quiet-summary .text-link { margin-left: auto; }
.attention-detail { min-width: 0; min-height: 100%; border-left: 1px solid var(--line); background: var(--surface); }
.detail-content { padding: 27px 27px 34px; }
.detail-topline { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: var(--quiet); font-size: 11px; }
.detail-category { display: inline-flex; align-items: center; gap: 7px; color: var(--accent-text); }
.detail-category::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }
.detail-title { margin: 20px 0 0; font-size: 22px; line-height: 1.23; letter-spacing: -.025em; }
.impact-line { display: flex; align-items: baseline; gap: 8px; margin-top: 23px; }
.impact-line strong { font-size: 31px; line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.impact-line span { color: var(--quiet); font-size: 12px; }
.detail-section { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.detail-section h3, .action-section h3 { margin: 0 0 9px; color: var(--muted); font-size: 12px; font-weight: 650; }
.detail-section p, .action-section p { margin: 0; color: var(--text); font-size: 13px; line-height: 1.55; }
.comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-top: 17px; }
.comparison > div { padding-left: 11px; border-left: 2px solid var(--line-strong); }
.comparison > div:first-child { border-left-color: var(--brand); }
.comparison span, .comparison strong { display: block; }
.comparison span { color: var(--quiet); font-size: 10px; }
.comparison strong { margin-top: 4px; font-size: 16px; font-variant-numeric: tabular-nums; }
.source-button { width: 100%; min-height: 52px; display: grid; grid-template-columns: 36px minmax(0,1fr) 18px; gap: 10px; align-items: center; padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; text-align: left; }
.source-button:hover .source-icon { border-color: #565a61; }
.source-icon { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); }
.source-copy { min-width: 0; }
.source-copy strong, .source-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.source-copy strong { font-size: 12px; }
.source-copy span { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.action-section { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.action-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.action-note { margin: 14px 0 0; color: var(--quiet); font-size: 10px; line-height: 1.5; }
.draft-panel { margin-top: 14px; border-top: 1px solid var(--line); }
.draft-status { display: flex; align-items: center; gap: 8px; padding: 14px 0; color: var(--muted); font-size: 11px; }
.draft-field { padding: 12px 0; border-top: 1px solid var(--line); }
.draft-field span { display: block; margin-bottom: 5px; color: var(--quiet); font-size: 10px; }
.draft-field strong, .draft-field p { margin: 0; color: var(--text); font-size: 12px; line-height: 1.55; white-space: pre-line; }
.lifecycle-line { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; }
.lifecycle-step { display: inline-flex; align-items: center; gap: 6px; color: var(--quiet); font-size: 10px; }
.lifecycle-step + .lifecycle-step::before { content: "›"; margin-right: 1px; color: #555961; }
.lifecycle-step.is-current { color: var(--success-text); }

/* Generic rows and state surfaces */
.content-narrow { width: min(900px, calc(100% - 68px)); margin: 0 auto; padding: 28px 0 50px; }
.content-wide { padding: 26px 34px 50px; }
.section-block + .section-block { margin-top: 36px; }
.section-heading { min-height: 42px; display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.section-heading h2 { margin: 0; font-size: 16px; letter-spacing: -.015em; }
.section-heading p { margin: 5px 0 0; color: var(--quiet); font-size: 12px; line-height: 1.45; }
.data-list { display: grid; }
.data-row { width: 100%; min-height: 68px; display: grid; grid-template-columns: 38px minmax(0,1fr) auto; gap: 12px; align-items: center; padding: 12px 3px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; text-align: left; }
button.data-row { cursor: pointer; }
button.data-row:hover { background: var(--row-hover); }
.row-icon { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); }
.row-copy { min-width: 0; }
.row-copy strong, .row-copy span { display: block; }
.row-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; line-height: 1.35; }
.row-copy span { margin-top: 4px; color: var(--quiet); font-size: 11px; line-height: 1.45; }
.row-end { min-width: 90px; display: flex; justify-content: flex-end; align-items: center; gap: 10px; color: var(--quiet); font-size: 11px; text-align: right; }
.row-end strong { display: block; color: var(--text); font-size: 12px; }
.row-end span { display: block; margin-top: 3px; }
.state-panel { min-height: 310px; display: grid; place-items: center; padding: 46px 20px; }
.state-panel__inner { max-width: 460px; text-align: center; }
.state-icon { width: 46px; height: 46px; display: grid; place-items: center; margin: 0 auto 17px; border: 1px solid var(--line-strong); border-radius: 9px; color: var(--muted); }
.state-panel h2 { margin: 0; font-size: 20px; letter-spacing: -.02em; }
.state-panel p { margin: 9px auto 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.state-panel .action-buttons { justify-content: center; margin-top: 20px; }
.permission-note { display: flex; align-items: flex-start; gap: 11px; margin: 16px 0; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--muted); }
.permission-note .icon { flex: 0 0 auto; margin-top: 1px; }
.permission-note strong { display: block; color: var(--text); font-size: 12px; }
.permission-note p { margin: 4px 0 0; font-size: 11px; line-height: 1.5; }
.callout { display: flex; gap: 11px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--muted); }
.callout .icon { flex: 0 0 auto; margin-top: 1px; }
.callout strong { display: block; color: var(--text); font-size: 12px; }
.callout p { margin: 4px 0 0; font-size: 11px; line-height: 1.5; }
.skeleton { position: relative; overflow: hidden; border-radius: 4px; background: var(--skeleton); color: transparent !important; }
.skeleton::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, var(--shimmer), transparent); animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }

/* Brain */
.brain-shell { height: 100%; display: grid; grid-template-rows: auto minmax(0,1fr); }
.brain-topbar { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 15px 24px; border-bottom: 1px solid var(--line); }
.brain-heading { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brain-heading h1 { margin: 0; font-size: 17px; letter-spacing: -.02em; }
.brain-heading p { margin: 3px 0 0; color: var(--quiet); font-size: 11px; }
.context-chip { min-height: 28px; display: inline-flex; align-items: center; gap: 6px; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); font-size: 10px; }
.roi-chip { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 11px; border: 1px solid var(--success-line); border-radius: 7px; background: var(--success-soft); color: var(--success-text); cursor: pointer; line-height: 1; }
.roi-chip strong { font-size: 13px; font-variant-numeric: tabular-nums; }
.roi-chip span { color: var(--muted); font-size: 10px; }
.roi-chip:hover { border-color: var(--green); background: var(--success-soft); }
.brain-grid { min-height: 0; display: grid; grid-template-columns: minmax(0,1fr) 300px; }
.thread { position: relative; min-width: 0; min-height: 0; display: grid; grid-template-rows: minmax(0,1fr) auto; }
.messages { overflow: auto; padding: 34px max(28px, calc((100% - 760px)/2)) 28px; }
.brain-empty { max-width: 670px; margin: min(12vh, 100px) auto 0; }
.brain-empty .state-icon { margin-left: 0; }
.brain-empty h2 { margin: 0; font-size: 25px; letter-spacing: -.03em; }
.brain-empty > p { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.suggestion-list { display: grid; margin-top: 28px; border-top: 1px solid var(--line); }
.suggestion { min-height: 56px; display: grid; grid-template-columns: minmax(0,1fr) 20px; gap: 10px; align-items: center; padding: 10px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.suggestion:hover { color: var(--text); }
.suggestion strong { display: block; font-size: 13px; }
.suggestion span { display: block; margin-top: 4px; color: var(--quiet); font-size: 10px; }
.message { max-width: 720px; margin: 0 auto 26px; }
.message--user { display: flex; justify-content: flex-end; }
.message--user .message-content { max-width: 78%; padding: 11px 14px; border: 1px solid var(--line); border-radius: 8px 8px 2px 8px; background: var(--surface-2); }
.message-content p { margin: 0; font-size: 14px; line-height: 1.58; }
.brain-answer { display: grid; grid-template-columns: 30px minmax(0,1fr); gap: 12px; }
.brain-answer__mark { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--accent-text); }
.brain-answer-title { max-width: 620px; margin: 0; font-size: clamp(20px, 2.2vw, 28px); line-height: 1.16; letter-spacing: -.035em; }
.answer-lead { font-size: 16px !important; line-height: 1.5 !important; }
.brain-answer-title + .answer-lead { max-width: 630px; margin: 10px 0 0; color: var(--muted); }
.answer-block { margin-top: 19px; }
.answer-block h3 { margin: 0 0 8px; color: var(--quiet); font-size: 10px; text-transform: uppercase; letter-spacing: .055em; }
.answer-block p { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.answer-list { margin: 0; padding-left: 18px; color: var(--text); font-size: 13px; line-height: 1.55; }
.answer-list li + li { margin-top: 5px; }
.answer-points { display: grid; gap: 13px; margin-top: 18px; }
.answer-point { display: grid; grid-template-columns: 21px minmax(0,1fr); gap: 9px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.answer-point > span { width: 21px; height: 21px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); font-size: 10px; }
.answer-point strong { color: var(--text); }
.answer-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 20px; }
.answer-source { min-height: 34px; display: inline-flex; align-items: center; gap: 7px; padding: 0 10px; border: 1px solid var(--line); border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer; font-size: 11px; }
.answer-source:hover { border-color: var(--line-strong); color: var(--text); }
.tts-button { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer; }
.answer-suggestion { margin-top: 17px; padding: 14px 0 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.5; }
.answer-suggestion button { margin-top: 8px; padding: 0; border: 0; background: transparent; color: var(--accent-text); cursor: pointer; font-weight: 650; }
.proactive-insight { margin-top: 18px; padding: 15px 16px; border: 1px solid var(--accent-line); border-radius: 7px; background: var(--accent-soft); }
.proactive-label { display: block; margin-bottom: 7px; color: var(--accent-text); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.proactive-insight strong { display: block; font-size: 13px; line-height: 1.5; }
.proactive-insight p { margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.answer-next { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.answer-next > span { color: var(--quiet); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.answer-next p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.answer-next-list { display: grid; gap: 7px; margin: 9px 0 0; padding-left: 20px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.answer-next-list li::marker { color: var(--accent-text); font-weight: 700; }
.answer-next button { min-height: 34px; display: inline-flex; align-items: center; gap: 5px; margin-top: 9px; padding: 0; border: 0; background: transparent; color: var(--accent-text); cursor: pointer; font-size: 12px; font-weight: 700; }
.correction-note { display: flex; gap: 9px; margin-top: 16px; padding: 12px; border: 1px solid rgba(130,174,246,.25); border-radius: 7px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.correction-note strong { color: var(--text); }
.composer-wrap { padding: 12px max(24px, calc((100% - 760px)/2)) 20px; background: linear-gradient(180deg, transparent, var(--bg) 28%); }
.composer { min-height: 58px; display: grid; grid-template-columns: minmax(0,1fr) auto auto; align-items: center; gap: 8px; padding: 8px; border: 1px solid var(--line-strong); border-radius: 9px; background: var(--surface-2); }
.composer:has([data-action="add-source"]) { grid-template-columns: auto minmax(0,1fr) auto auto; }
.composer textarea { width: 100%; height: 40px; min-height: 40px; max-height: 130px; resize: none; padding: 10px 4px; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 14px; line-height: 20px; }
.composer textarea::placeholder { color: var(--placeholder); }
.composer .icon-button { border-color: transparent; background: transparent; }
.composer .mic-button { color: var(--accent-text); }
.evidence-rail { min-width: 0; overflow: auto; padding: 25px 21px; border-left: 1px solid var(--line); background: var(--surface); }
.evidence-rail h2 { margin: 0; font-size: 13px; }
.evidence-rail > p { margin: 7px 0 12px; color: var(--quiet); font-size: 11px; line-height: 1.5; }
.rail-source { width: 100%; min-width: 0; display: grid; grid-template-columns: 30px minmax(0,1fr) 16px; align-items: start; gap: 10px; padding: 13px 2px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; color: inherit; cursor: pointer; text-align: left; font: inherit; }
.rail-source:hover { background: var(--row-hover); }
.rail-source--static { grid-template-columns: 30px minmax(0,1fr); cursor: default; }
.rail-source--static:hover { background: transparent; }
.rail-source__icon { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); background: var(--surface-2); }
.rail-source__body { min-width: 0; display: block; }
.rail-source__body strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); font-size: 11px; line-height: 1.35; }
.rail-source__body small { display: -webkit-box; overflow: hidden; margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.45; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.rail-source__body > span { display: block; margin-top: 6px; color: var(--quiet); font-size: 9px; }
.rail-source > .icon { align-self: center; color: var(--quiet); }
.rail-footer { margin-top: 18px; padding-top: 15px; border-top: 1px solid var(--line); color: var(--quiet); font-size: 10px; line-height: 1.5; }

/* Knowledge */
.knowledge-overview { max-width: 1040px; }
.knowledge-status { display: grid; grid-template-columns: 46px minmax(0,1fr) auto; align-items: center; gap: 16px; padding: 20px; border: 1px solid var(--success-line); border-radius: 10px; background: var(--success-soft); }
.knowledge-status__mark { width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid var(--success-line); border-radius: 10px; color: var(--success-text); background: var(--surface); }
.knowledge-status__copy { min-width: 0; }
.knowledge-status__copy .tag { margin-bottom: 9px; }
.knowledge-status__copy h2 { margin: 0; font-size: 19px; line-height: 1.3; letter-spacing: -.02em; }
.knowledge-status__copy p { max-width: 680px; margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.knowledge-status__complete { display: inline-flex; align-items: center; gap: 6px; color: var(--success-text); font-size: 11px; font-weight: 650; }
.knowledge-review-block { margin-top: 32px !important; }
.review-queue { padding-top: 4px; }
.review-item { padding: 21px 0; border-bottom: 1px solid var(--line); }
.review-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.review-item h3 { margin: 0; font-size: 17px; line-height: 1.35; letter-spacing: -.015em; }
.review-item > p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.proof-quote { margin-top: 15px; padding: 12px 14px; border-left: 2px solid var(--line-strong); background: var(--surface); color: var(--text); font-size: 12px; line-height: 1.65; white-space: pre-line; }
.proof-quote p { margin: 0; color: var(--text); font-size: 12px; line-height: 1.55; }
.proof-quote span { display: block; margin-top: 7px; color: var(--quiet); font-size: 10px; }
.review-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.map-summary { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 22px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.map-summary > div { padding: 17px 14px; border-right: 1px solid var(--line); }
.map-summary > div:first-child { padding-left: 0; }
.map-summary > div:last-child { border-right: 0; }
.map-summary strong, .map-summary span { display: block; }
.map-summary strong { font-size: 20px; letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
.map-summary span { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.source-type-grid { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); gap: 8px; margin-top: 18px; }
.source-type { min-height: 105px; display: flex; flex-direction: column; justify-content: space-between; padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: inherit; cursor: pointer; text-align: left; }
.source-type:hover { border-color: var(--line-strong); }
.source-type .icon { color: var(--muted); }
.source-type strong { display: block; font-size: 12px; }
.source-type span { display: block; margin-top: 3px; color: var(--quiet); font-size: 10px; line-height: 1.4; }
.record-preview { display: grid; gap: 1px; margin-top: 18px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--line); }
.record-row { display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 12px; padding: 13px 14px; background: var(--surface); font-size: 11px; }
.record-row--head { color: var(--quiet); background: var(--surface-2); font-size: 10px; font-weight: 650; }
.record-row span:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.language-term { min-height: 72px; display: grid; grid-template-columns: minmax(160px,.65fr) minmax(0,1.4fr) auto; gap: 18px; align-items: center; padding: 13px 3px; border-bottom: 1px solid var(--line); }
.language-term strong { font-size: 13px; }
.language-term p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.language-term small { display: block; margin-top: 4px; color: var(--quiet); font-size: 10px; }

/* Research */
.research-layout { display: grid; grid-template-columns: minmax(320px, 390px) minmax(0,1fr); gap: 0; min-height: calc(100dvh - 148px); }
.research-input-pane { padding: 28px 30px 42px 34px; border-right: 1px solid var(--line); }
.field { display: grid; gap: 8px; }
.field + .field { margin-top: 18px; }
.field label { color: var(--muted); font-size: 11px; font-weight: 650; }
.field input, .field textarea, .field select { width: 100%; min-height: 42px; padding: 10px 11px; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--surface); color: var(--text); font-size: 13px; line-height: 1.5; }
.field textarea { min-height: 150px; resize: vertical; }
.field-help { margin: 7px 0 0; color: var(--quiet); font-size: 10px; line-height: 1.45; }
.research-input-pane .button { margin-top: 16px; width: 100%; }
.recent-research { margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--line); }
.recent-research > strong { display: block; margin-bottom: 8px; color: var(--muted); font-size: 11px; }
.recent-item { width: 100%; min-height: 48px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 10px; align-items: center; padding: 7px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.recent-item strong { display: block; font-size: 11px; }
.recent-item span { display: block; margin-top: 3px; color: var(--quiet); font-size: 9px; }
.dossier { margin-top: 26px; }
.dossier-hero { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: start; gap: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.dossier-identity { min-width: 0; }
.dossier-identity .eyebrow { margin: 0 0 7px; color: var(--quiet); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .055em; }
.dossier-identity h2 { margin: 0; font-size: 25px; line-height: 1.2; letter-spacing: -.03em; }
.dossier-identity > p:last-child { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.score-card { min-width: 104px; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 2px 5px; padding: 12px 13px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); font-variant-numeric: tabular-nums; }
.score-card > span { grid-column: 1 / -1; margin-bottom: 5px; color: var(--muted); font-size: 10px; font-weight: 650; }
.score-card > strong { font-size: 25px; line-height: 1; letter-spacing: -.035em; }
.score-card > small { color: var(--quiet); font-size: 9px; }
.score-card--good { border-color: var(--success-line); background: var(--success-soft); color: var(--success-text); }
.score-card--neutral { border-color: var(--warning-line); background: var(--warning-soft); color: var(--warning-text); }
.score-card--bad { border-color: var(--danger-line); background: var(--danger-soft); color: var(--danger-text); }
.dossier > .review-meta { margin-top: 14px; margin-bottom: 0; }
.dossier-metrics { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); margin-top: 18px; padding: 15px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dossier-metric { min-width: 0; padding: 0 14px; border-right: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.dossier-metric:first-child { padding-left: 0; }
.dossier-metric:last-child { border-right: 0; }
.dossier-metric span, .dossier-metric strong, .dossier-metric small { display: block; }
.dossier-metric span { color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.dossier-metric strong { margin-top: 6px; font-size: 18px; }
.dossier-metric small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.dossier-metric--good strong, .dossier-metric--good small { color: var(--success-text); }
.dossier-metric--neutral strong, .dossier-metric--neutral small { color: var(--warning-text); }
.dossier-metric--bad strong, .dossier-metric--bad small { color: var(--danger-text); }
.dossier-verdict { margin-top: 18px; padding: 16px 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.dossier-verdict > span { display: block; color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .055em; }
.dossier-verdict > strong { display: block; margin-top: 5px; font-size: 16px; line-height: 1.35; }
.dossier-verdict > p { margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.dossier-verdict--good { border-color: var(--success-line); background: var(--success-soft); }
.dossier-verdict--neutral { border-color: var(--warning-line); background: var(--warning-soft); }
.dossier-verdict--bad { border-color: var(--danger-line); background: var(--danger-soft); }
.dossier-next { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 18px; align-items: center; margin-top: 16px; padding: 16px 17px; border: 1px solid var(--line); border-radius: 8px; }
.dossier-next span { display: block; color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.dossier-next strong { display: block; margin-top: 6px; font-size: 13px; line-height: 1.5; }
.dossier-next--good { border-color: var(--success-line); background: var(--success-soft); }
.dossier-next--neutral { border-color: var(--warning-line); background: var(--warning-soft); }
.dossier-next--bad { border-color: var(--danger-line); background: var(--danger-soft); }
.dossier-overview { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 4px; }
.dossier-overview .detail-section { min-width: 0; }
.proactive-insight--good { border-color: var(--success-line); background: var(--success-soft); }
.proactive-insight--good .proactive-label { color: var(--success-text); }
.proactive-insight--neutral { border-color: var(--warning-line); background: var(--warning-soft); }
.proactive-insight--neutral .proactive-label { color: var(--warning-text); }
.proactive-insight--bad { border-color: var(--danger-line); background: var(--danger-soft); }
.proactive-insight--bad .proactive-label { color: var(--danger-text); }
.dossier-details { margin-top: 22px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dossier-details > summary, .roi-details > summary { min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 16px; cursor: pointer; list-style: none; }
.dossier-details > summary::-webkit-details-marker, .roi-details > summary::-webkit-details-marker { display: none; }
.dossier-details > summary strong, .dossier-details > summary small, .roi-details > summary strong, .roi-details > summary small { display: block; }
.dossier-details > summary strong, .roi-details > summary strong { font-size: 12px; }
.dossier-details > summary small, .roi-details > summary small { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.dossier-details[open] > summary .icon, .roi-details[open] > summary .icon { transform: rotate(90deg); }
.dossier-details .detail-section { margin: 0; padding: 18px 0; }
.dossier-pane { min-width: 0; padding: 29px 34px 50px; overflow: auto; }
.dossier-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.dossier-head h2 { margin: 0; font-size: 24px; letter-spacing: -.03em; }
.dossier-head p { margin: 7px 0 0; color: var(--muted); font-size: 12px; }
.decision { min-width: 170px; padding-left: 14px; border-left: 2px solid var(--green); }
.decision strong, .decision span { display: block; }
.decision strong { font-size: 13px; }
.decision span { margin-top: 5px; color: var(--quiet); font-size: 10px; }
.dossier-summary { display: grid; grid-template-columns: repeat(3, 1fr); padding: 17px 0; border-bottom: 1px solid var(--line); }
.dossier-summary > div { padding: 0 15px; border-right: 1px solid var(--line); }
.dossier-summary > div:first-child { padding-left: 0; }
.dossier-summary > div:last-child { border-right: 0; }
.dossier-summary strong, .dossier-summary span { display: block; }
.dossier-summary strong { font-size: 16px; }
.dossier-summary span { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.dossier-section { padding: 20px 0; border-bottom: 1px solid var(--line); }
.dossier-section h3 { margin: 0 0 9px; color: var(--muted); font-size: 11px; }
.dossier-section p { margin: 0; font-size: 13px; line-height: 1.58; }
.dossier-section ul { margin: 0; padding-left: 17px; color: var(--text); font-size: 12px; line-height: 1.6; }
.dossier-section li + li { margin-top: 7px; }
.dossier-section strong { color: var(--text); }
.dossier-section--approach { margin: 8px 0; padding: 18px; border: 1px solid var(--success-line); border-radius: 8px; background: var(--success-soft); }
.dossier-section--approach h3 { color: var(--success-text); }
.outreach-draft { padding: 14px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); }
.outreach-draft span { display: block; margin-bottom: 6px; color: var(--quiet); font-size: 10px; }
.source-cluster { display: flex; flex-wrap: wrap; gap: 7px; }
.source-cluster button { min-height: 31px; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; background: transparent; color: var(--muted); cursor: default; font-size: 10px; }
.source-caveat { margin-top: 11px !important; color: var(--quiet) !important; font-size: 11px !important; }
.source-summary-grid { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 20px; border-top: 1px solid var(--line); }
.source-summary-grid > div { min-width: 0; padding: 14px 12px 14px 0; border-bottom: 1px solid var(--line); }
.source-summary-grid > div:nth-child(even) { padding-left: 12px; border-left: 1px solid var(--line); }
.source-summary-grid span, .source-summary-grid strong { display: block; }
.source-summary-grid span { color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.source-summary-grid strong { overflow-wrap: anywhere; margin-top: 5px; font-size: 11px; line-height: 1.45; }
.proactive-insight--sniper { margin-top: 20px; }
.dossier-sources { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.sniper-source-list { display: grid; border-top: 1px solid var(--line); }
.sniper-source-row { min-width: 0; display: grid; grid-template-columns: 24px minmax(0,1fr) 16px; gap: 9px; align-items: start; padding: 12px 0; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.sniper-source-row > .icon { margin-top: 1px; color: var(--quiet); }
.sniper-source-row[href]:hover { color: var(--accent-text); }
.sniper-source-copy { min-width: 0; }
.sniper-source-copy strong, .sniper-source-copy > span { display: block; }
.sniper-source-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.sniper-source-copy > span { display: -webkit-box; overflow: hidden; margin-top: 4px; color: var(--muted); font-size: 10px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.dossier-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.mobile-drill-list { display: none; }
.candidate-list { display: grid; margin-top: 18px; border-top: 1px solid var(--line); }
.candidate-row { width: 100%; min-height: 72px; display: grid; grid-template-columns: minmax(0,1fr) 20px; align-items: center; gap: 12px; padding: 12px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.candidate-row strong { display: block; font-size: 13px; }
.candidate-row span { display: block; margin-top: 5px; color: var(--quiet); font-size: 11px; line-height: 1.4; }
.research-page { padding-bottom: 54px; }
.research-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 142px;
  gap: 12px;
  align-items: end;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}
.research-input textarea {
  width: 100%;
  min-height: 116px;
  resize: vertical;
  padding: 14px 15px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  outline: 0;
  background: var(--surface-2);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}
.research-input textarea::placeholder { color: var(--placeholder); }
.research-input textarea:focus-visible { border-color: var(--focus); outline: 2px solid var(--focus); outline-offset: 1px; }
.research-input .button { width: 100%; min-height: 44px; }
.criteria-intro { display: grid; grid-template-columns: 38px minmax(0,1fr); gap: 13px; align-items: start; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.criteria-intro > .icon { margin-top: 3px; color: var(--muted); }
.criteria-intro span { display: block; color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .055em; }
.criteria-intro h2 { margin: 5px 0 0; font-size: 20px; letter-spacing: -.025em; }
.criteria-intro p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.training-card { max-width: 680px; margin: 22px 0 0; padding: 21px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.training-card--active { border-color: var(--success-line); background: var(--success-soft); }
.training-card__head { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
.training-card h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.training-card > p { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.training-card--candidate > .eyebrow { display: block; margin-bottom: 6px; color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .055em; }
.candidate-summary { margin-top: 15px; padding: 13px 14px; border-left: 2px solid var(--line-strong); background: var(--bg); color: var(--text); font-size: 12px; line-height: 1.5; }
.training-evidence { margin-top: 20px; }
.training-progress { display: grid; grid-template-columns: 1fr 1fr; margin-top: 20px; border-top: 1px solid var(--success-line); }
.training-progress > div { padding: 15px 14px 0 0; }
.training-progress > div + div { padding-left: 14px; border-left: 1px solid var(--success-line); }
.training-progress strong, .training-progress span { display: block; }
.training-progress strong { color: var(--text); font-size: 20px; font-variant-numeric: tabular-nums; }
.training-progress span { margin-top: 3px; color: var(--muted); font-size: 10px; }

/* Watch configuration */
.check-row { min-height: 78px; grid-template-columns: 38px minmax(0,1fr) minmax(130px,auto) 20px; }
.check-row .row-end { min-width: 130px; }
.schedule-preview { display: grid; gap: 1px; margin-top: 18px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--line); }
.schedule-row { display: grid; grid-template-columns: minmax(0,1.3fr) minmax(120px,.7fr) minmax(120px,.7fr) auto; gap: 12px; align-items: center; padding: 14px; background: var(--surface); font-size: 11px; }
.schedule-row strong { font-size: 12px; }
.schedule-row span { color: var(--quiet); }
.attention-review { margin-top: 25px; padding-top: 6px; border-top: 1px solid var(--line); }
.attention-review .list-heading { border-bottom: 0; }

/* Učinak */
.roi-hero { padding: 4px 0 24px; border-bottom: 1px solid var(--line); }
.roi-hero > .tag { display: inline-flex; }
.roi-hero > strong { display: block; margin-top: 14px; font-size: 43px; line-height: 1; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
.roi-hero > p { margin: 9px 0 0; color: var(--muted); font-size: 12px; }
.roi-hero > p + p { margin-top: 5px; }
.roi-metrics { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.roi-metrics > div { min-width: 0; padding: 16px 13px; border-right: 1px solid var(--line); }
.roi-metrics > div:first-child { padding-left: 0; }
.roi-metrics > div:last-child { border-right: 0; }
.roi-metrics span, .roi-metrics strong, .roi-metrics small { display: block; }
.roi-metrics span { color: var(--quiet); font-size: 9px; }
.roi-metrics strong { margin-top: 6px; font-size: 20px; font-variant-numeric: tabular-nums; }
.roi-metrics small { margin-top: 4px; color: var(--muted); font-size: 9px; line-height: 1.35; }
.roi-takeaway { display: flex; gap: 11px; margin-top: 20px; padding: 15px; border: 1px solid var(--success-line); border-radius: 8px; background: var(--success-soft); }
.roi-takeaway > .icon { flex: 0 0 auto; margin-top: 2px; color: var(--success-text); }
.roi-takeaway strong { display: block; font-size: 12px; }
.roi-takeaway p { margin: 5px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.roi-details { margin-top: 20px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.roi-details__toggle { width: 100%; min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; text-align: left; }
.roi-details__toggle strong, .roi-details__toggle small { display: block; }
.roi-details__toggle strong { font-size: 12px; }
.roi-details__toggle small { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.roi-details__toggle > .icon { transition: transform var(--ease); }
.roi-details__toggle[aria-expanded="true"] > .icon { transform: rotate(90deg); }
.roi-details .roi-breakdown { padding-bottom: 10px; }
.roi-caveat { margin: 5px 0 18px; color: var(--quiet); font-size: 9px; line-height: 1.5; }
.roi-breakdown { display: grid; }
.roi-breakdown > div { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); }
.roi-breakdown span { color: var(--muted); font-size: 12px; }
.roi-breakdown strong { font-size: 13px; font-variant-numeric: tabular-nums; }
.roi-breakdown .roi-total { margin-top: 5px; border-bottom: 0; }
.roi-breakdown .roi-total span, .roi-breakdown .roi-total strong { color: var(--text); font-weight: 700; }
.context-passages,
.run-history { display: grid; gap: 10px; }
.context-passage,
.run-row { padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
.context-passage.is-match { border-color: var(--brand); background: var(--accent-soft); }
.context-passage small { display: block; margin-bottom: 8px; color: var(--quiet); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.context-passage p,
.run-row p { margin: 0; color: var(--text); font-size: 12px; line-height: 1.6; }
.run-row__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.run-row__head .tag { margin: 0; }
.run-row__head time { color: var(--quiet); font-size: 9px; }
.run-row .field-error { margin-top: 8px; }
.wizard-steps { display: flex; gap: 6px; margin-bottom: 24px; }
.wizard-step { flex: 1; height: 3px; border-radius: 2px; background: var(--line); }
.wizard-step.is-done, .wizard-step.is-current { background: var(--brand); }
.choice-list { display: grid; gap: 8px; margin-top: 16px; }
.choice { width: 100%; min-height: 70px; display: grid; grid-template-columns: 38px minmax(0,1fr) 20px; gap: 12px; align-items: center; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: inherit; cursor: pointer; text-align: left; }
.choice:hover, .choice.is-selected { border-color: rgba(241,90,36,.65); }
.choice strong { display: block; font-size: 12px; }
.choice span { display: block; margin-top: 4px; color: var(--quiet); font-size: 10px; line-height: 1.4; }
.mapping-list { display: grid; gap: 8px; margin-top: 16px; }
.mapping-row { display: grid; grid-template-columns: minmax(100px,.7fr) 24px minmax(120px,1fr); align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 11px; }
.mapping-row select { min-height: 38px; padding: 0 9px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); color: var(--text); }

/* Settings */
.settings-layout { height: 100%; display: grid; grid-template-columns: 220px minmax(0,1fr); }
.settings-nav { padding: 27px 18px; border-right: 1px solid var(--line); background: var(--sidebar); }
.settings-nav h1 { margin: 0 10px 20px; font-size: 18px; }
.settings-nav button { width: 100%; min-height: 40px; display: flex; align-items: center; gap: 9px; padding: 0 10px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; text-align: left; font-size: 12px; }
.settings-nav button:hover, .settings-nav button.is-active { background: var(--surface-2); color: var(--text); }
.settings-mobile-tabs { display: none; }
.settings-main { overflow: auto; }
.settings-content { width: min(760px, calc(100% - 68px)); margin: 0 auto; padding: 31px 0 60px; }
.settings-content > header { padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.settings-content > header h2 { margin: 0; font-size: 23px; letter-spacing: -.025em; }
.settings-content > header p { margin: 8px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.settings-section { padding: 22px 0; border-bottom: 1px solid var(--line); }
.settings-section h3 { margin: 0 0 14px; font-size: 13px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .field + .field { margin-top: 0; }
.session-row, .team-row { min-height: 66px; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.session-row:last-child, .team-row:last-child { border-bottom: 0; }
.session-row strong, .team-row strong { display: block; font-size: 12px; }
.session-row span, .team-row span { display: block; margin-top: 4px; color: var(--quiet); font-size: 10px; line-height: 1.4; }
.plain-list { display: grid; gap: 10px; margin: 12px 0 0; padding-left: 20px; color: var(--muted); }
.plain-list li { padding-left: 4px; line-height: 1.55; }
.brand-preview { display: flex; align-items: center; gap: 12px; margin-top: 18px; padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.accent-swatches { display: flex; gap: 8px; margin-top: 10px; }
.swatch { width: 32px; height: 32px; border: 2px solid transparent; border-radius: 8px; cursor: pointer; }
.swatch.is-active { border-color: var(--text); box-shadow: 0 0 0 2px var(--bg); }
.theme-picker { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; }
.theme-picker button { min-height: 74px; display: flex; flex-direction: column; justify-content: center; gap: 5px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text); cursor: pointer; text-align: left; }
.theme-picker button:hover { border-color: var(--line-strong); background: var(--surface-2); }
.theme-picker button.is-active { border-color: var(--brand); background: var(--accent-soft); }
.theme-picker strong { font-size: 12px; }
.theme-picker span { color: var(--muted); font-size: 10px; line-height: 1.35; }
.danger-zone { padding-top: 24px; }
.danger-zone h3 { color: var(--danger-text); }

/* Drawer, modal, voice, onboarding */
.overlay { position: fixed; inset: 0; z-index: 180; background: var(--overlay-bg); opacity: 0; transition: opacity var(--ease); }
.overlay.is-open { opacity: 1; }
.drawer { position: fixed; top: 0; right: 0; z-index: 190; width: min(520px, 100vw); height: 100dvh; transform: translateX(102%); border-left: 1px solid var(--line-strong); background: var(--surface); box-shadow: -24px 0 70px rgba(0,0,0,.36); transition: transform 220ms ease; overflow: hidden; }
.drawer--wide { width: min(920px, 100vw); }
.drawer.is-open { transform: translateX(0); }
.drawer-shell { height: 100%; display: grid; grid-template-rows: auto minmax(0,1fr) auto; }
.drawer-head { min-height: 66px; display: grid; grid-template-columns: 40px minmax(0,1fr) 40px; align-items: center; gap: 10px; padding: 12px 17px; border-bottom: 1px solid var(--line); }
.drawer-head > div { min-width: 0; }
.drawer-head h2 { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; letter-spacing: -.015em; text-align: center; }
.drawer-head p { margin: 3px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--quiet); font-size: 10px; text-align: center; }
.drawer-scroll { min-height: 0; overflow: auto; padding: 24px 25px 34px; }
.drawer-footer { display: flex; gap: 8px; padding: 12px 17px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--surface); }
.drawer-footer .button { flex: 1; }
.drawer .action-section > .action-buttons,
.drawer .draft-panel > .action-buttons { display: none; }
.modal-layer { position: fixed; inset: 0; z-index: 220; display: none; place-items: center; padding: 18px; background: var(--modal-overlay); }
.modal-layer.is-open { display: grid; }
.modal-card { width: min(460px, 100%); max-height: calc(100dvh - 36px); overflow: auto; padding: 24px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface-2); box-shadow: 0 26px 80px rgba(0,0,0,.45); }
.modal-card h2 { margin: 0; font-size: 19px; letter-spacing: -.02em; }
.modal-card > p { margin: 9px 0 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.modal-card .action-buttons { justify-content: flex-end; margin-top: 22px; }
.evidence-table { display: grid; grid-template-columns: minmax(110px,.55fr) minmax(0,1fr); margin: 12px 0 0; border-top: 1px solid var(--line); }
.evidence-table dt, .evidence-table dd { margin: 0; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 11px; line-height: 1.45; }
.evidence-table dt { color: var(--quiet); }
.evidence-table dd { color: var(--text); text-align: right; overflow-wrap: anywhere; }
.evidence-card-list { display: grid; gap: 10px; margin-top: 18px; }
.evidence-card { padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
.evidence-card__head { display: flex; align-items: center; gap: 9px; }
.evidence-card__icon { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); background: var(--surface); }
.evidence-card__head strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.evidence-card blockquote { margin: 11px 0 0; padding: 0; border: 0; color: var(--muted); font-size: 11px; line-height: 1.55; white-space: pre-line; }
.evidence-context { margin-top: 22px; }
.evidence-context h3 { margin: 0 0 10px; color: var(--muted); font-size: 11px; }
.evidence-context blockquote { margin: 0; padding: 13px 14px; border-left: 2px solid var(--brand); background: var(--bg); color: var(--text); font-size: 12px; line-height: 1.6; }
.saved-proof { display: flex; gap: 10px; margin-top: 20px; color: var(--quiet); font-size: 10px; line-height: 1.5; }
.saved-proof .icon { flex: 0 0 auto; }
.voice-stage { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 18px 0; text-align: center; }
.voice-orb { width: 70px; height: 70px; display: grid; place-items: center; border: 1px solid var(--accent-line); border-radius: 50%; color: var(--accent-text); background: var(--accent-soft); }
.voice-stage h2 { margin: 21px 0 0; font-size: 24px; letter-spacing: -.03em; }
.voice-stage > p { max-width: 360px; margin: 9px auto 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.voice-timer { margin-top: 18px; font-size: 22px; font-variant-numeric: tabular-nums; }
.waveform { height: 34px; display: flex; align-items: center; justify-content: center; gap: 4px; margin-top: 14px; }
.waveform span { width: 3px; border-radius: 2px; background: var(--brand); animation: wave .9s ease-in-out infinite alternate; }
.waveform span:nth-child(1), .waveform span:nth-child(5) { height: 10px; }
.waveform span:nth-child(2), .waveform span:nth-child(4) { height: 22px; animation-delay: .15s; }
.waveform span:nth-child(3) { height: 31px; animation-delay: .3s; }
@keyframes wave { to { transform: scaleY(.45); opacity: .58; } }
.transcript-editor { width: 100%; margin-top: 22px; text-align: left; }
.transcript-editor label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 11px; }
.transcript-editor textarea { width: 100%; min-height: 130px; resize: vertical; padding: 12px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.5; }
.history-list { display: grid; }
.history-row { width: 100%; min-height: 66px; display: grid; grid-template-columns: minmax(0,1fr) 34px; gap: 10px; align-items: center; padding: 11px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.history-row-wrap { display: grid; grid-template-columns: minmax(0,1fr) 38px; align-items: center; border-bottom: 1px solid var(--line); }
.history-row-wrap .history-row { border-bottom: 0; }
.history-manage { width: 34px; height: 34px; border-color: transparent; background: transparent; color: var(--quiet); }
.history-manage:hover { border-color: var(--line-strong); color: var(--text); }
.history-row strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.history-row span { display: block; margin-top: 4px; color: var(--quiet); font-size: 10px; }
.history-row .icon-button { width: 34px; height: 34px; border-color: transparent; background: transparent; }
.sniper-history-list { display: grid; gap: 0; margin-top: 18px; border-top: 1px solid var(--line); }
.sniper-history-row { display: grid; grid-template-columns: minmax(0,1fr) 42px; align-items: center; gap: 7px; }
.sniper-history-main { min-width: 0; min-height: 82px; display: grid; grid-template-columns: 40px minmax(0,1fr) auto 18px; align-items: center; gap: 13px; padding: 12px 2px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; text-align: left; }
.sniper-history-main:hover { background: var(--row-hover); }
.sniper-history-avatar { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--accent-line); border-radius: 50%; background: var(--accent-soft); color: var(--accent-text); font-size: 11px; font-weight: 750; letter-spacing: .025em; }
.sniper-history-person { min-width: 0; }
.sniper-history-person > strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.sniper-history-role, .sniper-history-date { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sniper-history-role { margin-top: 4px; color: var(--muted); font-size: 11px; }
.sniper-history-date { margin-top: 3px; color: var(--quiet); font-size: 9px; }
.sniper-history-score { min-width: 84px; display: grid; grid-template-columns: auto auto; align-items: baseline; justify-content: end; gap: 1px 3px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-2); font-variant-numeric: tabular-nums; }
.sniper-history-score strong { font-size: 15px; }
.sniper-history-score small { grid-column: 1 / -1; color: currentColor; font-size: 8px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.sniper-history-score > span { color: var(--quiet); font-size: 9px; }
.sniper-history-score--good { border-color: var(--success-line); background: var(--success-soft); color: var(--success-text); }
.sniper-history-score--neutral { border-color: var(--warning-line); background: var(--warning-soft); color: var(--warning-text); }
.sniper-history-score--bad { border-color: var(--danger-line); background: var(--danger-soft); color: var(--danger-text); }
.sniper-history-main > .icon { color: var(--quiet); }
.sniper-history-row > .icon-button { width: 36px; height: 36px; border-color: transparent; background: transparent; color: var(--quiet); }
.sniper-history-row > .icon-button:hover { border-color: var(--danger-line); background: var(--danger-soft); color: var(--danger-text); }
.research-job { display: grid; grid-template-columns: 28px minmax(0,1fr); gap: 12px; align-items: start; margin: 14px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface-raised); }
.research-job strong { display: block; font-size: 12px; }
.research-job p { margin: 5px 0 0; color: var(--quiet); font-size: 11px; line-height: 1.5; }
.research-job--running { border-color: var(--brand-line); background: var(--brand-soft); }
.research-job--failed { border-color: var(--danger-line); background: var(--danger-soft); }
.criteria-status { margin: 17px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.onboarding-shell { min-height: 100%; display: grid; grid-template-columns: 190px minmax(0,1fr); }
.onboarding-steps { padding: 18px 16px; border-right: 1px solid var(--line); background: var(--sidebar); }
.onboarding-steps .brand { padding-left: 0; }
.step-list { display: grid; gap: 5px; margin-top: 28px; }
.step { display: grid; grid-template-columns: 25px minmax(0,1fr); gap: 9px; align-items: center; min-height: 39px; color: var(--quiet); font-size: 10px; }
.step-num { width: 25px; height: 25px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 6px; font-variant-numeric: tabular-nums; }
.step.is-current { color: var(--text); }
.step.is-current .step-num { border-color: var(--brand); color: var(--accent-text); }
.step.is-done .step-num { border-color: rgba(108,194,146,.38); color: var(--green); }
.onboarding-main { min-width: 0; max-width: 720px; padding: 39px 38px 42px; }
.onboarding-main h2 { margin: 0; max-width: 620px; font-size: 27px; line-height: 1.2; letter-spacing: -.035em; }
.onboarding-main > p { max-width: 620px; margin: 12px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.onboarding-progress { margin-top: 24px; padding: 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.onboarding-progress__head { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; }
.onboarding-progress__head strong { font-size: 26px; font-variant-numeric: tabular-nums; }
.onboarding-progress__head span { color: var(--muted); font-size: 11px; }
.progress-track { height: 7px; margin-top: 14px; overflow: hidden; border-radius: 999px; background: var(--surface-2); }
.progress-track > span { display: block; height: 100%; border-radius: inherit; background: var(--brand); transition: width .3s ease; }
.onboarding-counts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: 20px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--line); }
.onboarding-counts > div { padding: 14px; background: var(--bg); }
.onboarding-counts strong, .onboarding-counts span { display: block; }
.onboarding-counts strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.onboarding-counts span { margin-top: 4px; color: var(--quiet); font-size: 9px; line-height: 1.35; }
.drop-zone { position: relative; width: 100%; min-height: 180px; display: grid; place-items: center; align-content: center; gap: 8px; margin-top: 25px; overflow: hidden; border: 1px dashed var(--line-strong); border-radius: 9px; background: var(--surface); color: var(--muted); cursor: pointer; }
.drop-zone:hover { border-color: rgba(241,90,36,.65); }
.drop-zone strong { color: var(--text); font-size: 13px; }
.drop-zone span { color: var(--quiet); font-size: 10px; }
.drop-zone--recommended { min-height: 150px; margin-top: 18px; border-style: solid; border-color: color-mix(in srgb, var(--brand), var(--line) 55%); background: color-mix(in srgb, var(--brand), transparent 94%); }
.source-review-list { display: grid; gap: 8px; margin-top: 16px; }
.source-review-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(132px,auto); align-items: center; gap: 14px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.source-review-copy { min-width: 0; }
.source-review-copy strong, .source-review-copy span { display: block; }
.source-review-copy strong { overflow: hidden; color: var(--text); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.source-review-copy span { margin-top: 4px; color: var(--quiet); font-size: 10px; line-height: 1.4; }
.source-review-row select { min-width: 132px; }
@media (max-width: 760px) {
  .source-review-row { grid-template-columns: 1fr; }
  .source-review-row select { width: 100%; }
}
.folder-file-choice { position: relative; min-height: 42px; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; color: var(--muted); cursor: pointer; font-size: 11px; }
.folder-file-choice:hover { border-color: var(--line-strong); background: var(--surface); color: var(--text); }
.onboarding-result { margin-top: 24px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.onboarding-result__main { padding: 18px 0; }
.onboarding-result__main h3 { margin: 0; font-size: 17px; }
.onboarding-result__main p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.onboarding-footer { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 24px; }
.onboarding-footer > span { color: var(--quiet); font-size: 10px; }

.prototype-panel { position: fixed; left: 16px; bottom: 16px; z-index: 260; width: 330px; max-height: calc(100dvh - 32px); overflow: auto; padding: 15px; border: 1px solid var(--line-strong); border-radius: 9px; background: var(--surface-2); box-shadow: 0 18px 55px var(--elevation-shadow); }
.prototype-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.prototype-head strong { display: block; font-size: 12px; }
.prototype-head span { display: block; margin-top: 4px; color: var(--quiet); font-size: 9px; }
.prototype-head button { border: 0; background: transparent; color: var(--quiet); cursor: pointer; }
.prototype-label { display: block; margin: 15px 0 7px; color: var(--quiet); font-size: 9px; text-transform: uppercase; letter-spacing: .06em; }
.prototype-options { display: flex; flex-wrap: wrap; gap: 6px; }
.prototype-options button { min-height: 31px; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--muted); cursor: pointer; font-size: 10px; }
.prototype-options button.is-active { border-color: var(--brand); color: var(--accent-text); }
.prototype-shortcuts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.prototype-shortcuts button { min-height: 34px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--muted); cursor: pointer; font-size: 10px; }
.toast-region { position: fixed; right: 18px; bottom: 18px; z-index: 300; display: grid; gap: 8px; pointer-events: none; }
.toast { min-width: 260px; max-width: 360px; display: flex; align-items: flex-start; gap: 10px; padding: 13px 14px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface-2); box-shadow: 0 16px 44px rgba(0,0,0,.38); color: var(--muted); font-size: 11px; line-height: 1.45; }
.toast .icon { flex: 0 0 auto; color: var(--green); }
.toast strong { color: var(--text); }

@media (min-width: 1181px) {
  .attention-layout {
    width: min(1060px, calc(100% - 64px));
    margin-inline: auto;
  }
}

@media (min-width: 901px) {
  body[data-route="attention"] .page.view-scroll > .attention-header,
  body[data-route="research"] .page-header,
  body[data-route="knowledge"] .page-header,
  body[data-route="research"] .section-tabs,
  body[data-route="knowledge"] .section-tabs {
    width: min(900px, calc(100% - 68px));
    margin-left: auto;
    margin-right: auto;
  }

  body[data-route="research"] .page-header,
  body[data-route="knowledge"] .page-header {
    padding-left: 0;
    padding-right: 0;
  }

  body[data-route="attention"] .page.view-scroll > .attention-header > .page-header {
    padding-left: 0;
    padding-right: 0;
  }

  body[data-route="attention"] .page.view-scroll > .attention-header > .section-tabs {
    margin-left: 0;
    margin-right: 0;
  }

  .brain-topbar {
    padding-left: 18px;
  }
}

@media (max-width: 1180px) {
  .attention-layout { grid-template-columns: 1fr; }
  .attention-detail { display: none; }
  .brain-grid { grid-template-columns: minmax(0,1fr) 270px; }
  .research-layout { grid-template-columns: 340px minmax(0,1fr); }
}

@media (max-width: 900px) {
  :root { --sidebar-width: 210px; }
  .page-header { padding-left: 26px; padding-right: 26px; }
  .section-tabs { margin-left: 26px; margin-right: 26px; }
  .attention-content, .content-wide { padding-left: 26px; padding-right: 26px; }
  .content-narrow { width: calc(100% - 52px); }
  .brain-grid { grid-template-columns: 1fr; }
  .evidence-rail { display: none; }
  .research-layout { grid-template-columns: 1fr; }
  .research-input-pane { border-right: 0; }
  .dossier-pane { border-top: 1px solid var(--line); }
  .source-type-grid { grid-template-columns: repeat(3, 1fr); }
  .record-row { grid-template-columns: 1fr 1fr; }
  .record-row--head { display: none; }
}

@media (max-width: 760px) {
  :root { --mobile-nav-height: 70px; --mobile-header-height: 58px; }
  body { overflow: hidden; }
  .app-shell { display: block; }
  .sidebar { display: none; }
  .workspace { height: 100dvh; display: flex; flex-direction: column; padding-top: var(--mobile-header-height); padding-bottom: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom)); }
  .mobile-header { position: fixed; inset: 0 0 auto; z-index: 70; height: var(--mobile-header-height); display: flex; align-items: center; justify-content: space-between; padding: 0 15px; border-bottom: 1px solid var(--line); background: var(--mobile-header-bg); }
  .mobile-header-actions { display: flex; align-items: center; gap: 7px; }
  .mobile-header .quick-theme-toggle { width: 36px; height: 36px; }
  .mobile-header .mobile-settings-button { width: 36px; height: 36px; }
  .mobile-brand { min-width: 0; display: flex; align-items: center; gap: 10px; padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; }
  .mobile-brand .brand-mark { width: 29px; height: 29px; border-radius: 7px; }
  .mobile-brand .brand-mark svg { width: 17px; height: 17px; }
  .mobile-brand-copy { min-width: 0; display: grid; line-height: 1.05; text-align: left; }
  .mobile-brand strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
  .mobile-brand-copy > span { display: block; margin-top: 3px; color: var(--quiet); font-size: 9px; }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 70; height: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom)); display: grid; grid-template-columns: repeat(4,1fr); padding: 5px 5px env(safe-area-inset-bottom); border-top: 1px solid var(--line); background: var(--mobile-nav-bg); }
  .mobile-nav__item { position: relative; min-width: 0; min-height: 60px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 0; border-radius: 7px; background: transparent; color: var(--quiet); cursor: pointer; font-size: 9px; }
  .mobile-nav__item.is-active { color: var(--text); background: var(--surface-2); }
  .mobile-nav__item .nav-count { position: absolute; top: 5px; left: calc(50% + 7px); min-width: 16px; height: 16px; padding: 0 4px; font-size: 9px; }
  .app-view { min-height: 0; height: auto; flex: 1; }
  .page-header { display: block; padding: 22px 17px 17px; }
  .page-header h1 { font-size: 24px; }
  .page-header p:not(.eyebrow) { font-size: 12px; }
  .page-actions { justify-content: flex-start; margin-top: 16px; }
  .page-actions .button { flex: 1; }
  .section-tabs { display: grid; grid-template-columns: repeat(2,1fr); gap: 0; margin: 0 17px; }
  .section-tabs--three { grid-template-columns: repeat(3,1fr); }
  .section-tab { padding: 0 5px; text-align: center; font-size: 10px; white-space: normal; }
  #globalBanner { position: relative; z-index: 55; flex: 0 0 auto; }
  .global-banner { min-height: 42px; padding: 8px 13px; }
  .global-banner .button { display: none; }
  .attention-main .page-header { padding-bottom: 12px; }
  .attention-content, .content-wide { padding: 0 17px 30px; }
  .content-narrow { width: calc(100% - 34px); padding-top: 20px; }
  .list-heading { min-height: 40px; }
  .list-heading span { display: none; }
  .priority-row { grid-template-columns: 27px minmax(0,1fr); gap: 10px; padding: 16px 4px 16px 1px; }
  .priority-value { grid-column: 2; min-width: 0; display: flex; align-items: baseline; gap: 6px; padding: 0; text-align: left; }
  .priority-value strong { font-size: 15px; }
  .priority-value span { margin: 0; }
  .priority-copy strong { font-size: 14px; }
  .priority-copy p { font-size: 12px; }
  .meta-line { font-size: 9px; }
  .quiet-summary .text-link { display: none; }
  .brain-shell { grid-template-rows: auto minmax(0,1fr); }
  .brain-topbar { min-height: 58px; padding: 9px 13px; }
  .brain-topbar .page-actions { flex-wrap: nowrap; gap: 6px; margin-top: 0; }
  .brain-heading h1 { font-size: 14px; }
  .context-chip { display: none; }
  .brain-history-label { display: none; }
  .roi-chip { min-height: 36px; padding: 0 9px; }
  .roi-chip span { display: none; }
  .messages { padding: 22px 15px 18px; }
  .brain-empty { margin-top: 5vh; }
  .brain-empty h2 { font-size: 22px; }
  .message--user .message-content { max-width: 90%; }
  .brain-answer { grid-template-columns: 27px minmax(0,1fr); gap: 9px; }
  .brain-answer__mark { width: 27px; height: 27px; }
  .answer-lead { font-size: 14px !important; }
  .answer-block p, .answer-list { font-size: 12px; }
  .answer-source { max-width: calc(100% - 42px); height: auto; min-height: 34px; padding-top: 7px; padding-bottom: 7px; line-height: 1.35; text-align: left; }
  .proactive-insight { padding: 13px; }
  .composer-wrap { padding: 8px 10px calc(10px + env(safe-area-inset-bottom)); }
  .composer { min-height: 54px; }
  .composer .icon-button { width: 44px; height: 44px; }
  .map-summary { grid-template-columns: 1fr; }
  .map-summary > div { padding: 14px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .map-summary > div:last-child { border-bottom: 0; }
  .source-type-grid { grid-template-columns: 1fr 1fr; }
  .source-type { min-height: 96px; }
  .data-row { grid-template-columns: 36px minmax(0,1fr) 18px; }
  .data-row .row-end { grid-column: 2; min-width: 0; justify-content: flex-start; text-align: left; }
  .check-row { grid-template-columns: 36px minmax(0,1fr) 18px; }
  .check-row .row-end { grid-column: 2; min-width: 0; justify-content: flex-start; text-align: left; }
  .record-preview { border-left: 0; border-right: 0; border-radius: 0; }
  .record-row { grid-template-columns: 1fr; gap: 5px; padding: 14px 2px; }
  .record-row span { color: var(--muted); }
  .record-row span::before { content: attr(data-label); display: inline-block; width: 90px; color: var(--quiet); font-size: 9px; }
  .record-row span:last-child { text-align: left; }
  .language-term { grid-template-columns: 1fr auto; gap: 8px; }
  .language-term p { grid-column: 1 / -1; }
  .research-layout { min-height: 100%; }
  .research-input-pane { order: 2; padding: 24px 17px 30px; border-top: 1px solid var(--line); border-right: 0; }
  .research-input { grid-template-columns: 1fr; gap: 10px; padding-bottom: 22px; }
  .research-input textarea { min-height: 112px; }
  .sniper-history-main { grid-template-columns: 38px minmax(0,1fr) auto; gap: 10px; padding-right: 3px; }
  .sniper-history-avatar { width: 38px; height: 38px; }
  .sniper-history-main > .icon { display: none; }
  .sniper-history-score { min-width: 54px; padding-left: 7px; padding-right: 7px; }
  .field textarea { min-height: 115px; }
  .dossier-pane { order: 1; padding: 21px 17px 36px; border-top: 0; }
  .dossier-head { display: block; padding-bottom: 15px; }
  .dossier-head h2 { font-size: 21px; }
  .decision { margin-top: 15px; }
  .dossier-summary { grid-template-columns: 1fr 1fr; padding: 13px 0; }
  .dossier-summary > div { padding: 5px 11px; }
  .dossier-summary > div:first-child { padding-left: 0; }
  .dossier-summary > div:nth-child(2) { border-right: 0; }
  .dossier-summary > div:nth-child(3) { grid-column: 1 / -1; margin-top: 10px; padding: 10px 0 0; border-top: 1px solid var(--line); border-right: 0; }
  .dossier-section--support { display: none; }
  .dossier-section--approach { margin-top: 13px; }
  .mobile-drill-list { display: grid; margin-top: 18px; border-top: 1px solid var(--line); }
  .dossier-actions .button { flex: 1; }
  .schedule-preview { border-left: 0; border-right: 0; border-radius: 0; }
  .schedule-row { grid-template-columns: 1fr auto; padding: 14px 2px; }
  .schedule-row span { grid-column: 1 / -1; }
  .settings-layout { display: block; }
  .settings-nav { display: none; }
  .settings-mobile-tabs { display: grid; grid-template-columns: repeat(3,1fr); margin-top: 6px; }
  .settings-content { width: calc(100% - 34px); padding-top: 22px; }
  .settings-content > header h2 { font-size: 21px; }
  .theme-picker { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .field + .field { margin-top: 0; }
  .drawer { width: 100vw; border-left: 0; }
  .drawer-head { min-height: var(--mobile-header-height); padding: 8px 10px; }
  .drawer-scroll { padding: 20px 17px 30px; }
  .drawer.is-open ~ * { touch-action: none; }
  .modal-layer { align-items: end; padding: 0; }
  .modal-card { width: 100%; max-height: 88dvh; padding: 22px 17px calc(20px + env(safe-area-inset-bottom)); border-radius: 12px 12px 0 0; }
  .onboarding-shell { display: block; }
  .onboarding-steps { display: none; }
  .onboarding-main { padding: 27px 18px 34px; }
  .onboarding-main h2 { font-size: 24px; }
  .onboarding-counts { grid-template-columns: 1fr 1fr; }
  .onboarding-footer { align-items: stretch; flex-direction: column-reverse; }
  .onboarding-footer .button { width: 100%; }
  .prototype-panel { left: 9px; right: 9px; bottom: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom) + 8px); width: auto; max-height: 62dvh; }
  .prototype-trigger { display: none; }
  .toast-region { left: 10px; right: 10px; bottom: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom) + 9px); }
  .toast { min-width: 0; max-width: none; width: 100%; }
  body[data-route="settings"] .mobile-nav { display: none; }
  body[data-route="settings"] .workspace { padding-bottom: 0; }
}

@media (max-width: 640px) {
  .knowledge-status { grid-template-columns: 40px minmax(0,1fr); padding: 16px; }
  .knowledge-status__mark { width: 40px; height: 40px; }
  .knowledge-status > .button, .knowledge-status__complete { grid-column: 2; justify-self: start; }
  .dossier-hero { grid-template-columns: minmax(0,1fr) auto; gap: 12px; }
  .dossier-identity h2 { font-size: 21px; }
  .score-card { min-width: 82px; padding: 10px; }
  .score-card > strong { font-size: 21px; }
  .dossier-metrics { grid-template-columns: 1fr 1fr; gap: 0; }
  .dossier-metric { padding: 10px 12px; border-bottom: 1px solid var(--line); }
  .dossier-metric:first-child { padding-left: 12px; }
  .dossier-metric:nth-child(2) { border-right: 0; }
  .dossier-metric:nth-last-child(-n+2) { border-bottom: 0; }
  .dossier-next { grid-template-columns: 1fr; }
  .dossier-next .button { width: 100%; }
  .dossier-overview { grid-template-columns: 1fr; gap: 0; }
  .dossier-verdict { padding: 14px; }
  .roi-metrics { grid-template-columns: 1fr; }
  .roi-metrics > div { padding: 13px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .roi-metrics > div:last-child { border-bottom: 0; }
  .sniper-history-score { min-width: 62px; }
  .sniper-history-score small { display: none; }
}

@media (max-width: 360px) {
  .page-header h1 { font-size: 22px; }
  .section-tab { font-size: 9px; }
  .button { padding-left: 11px; padding-right: 11px; }
  .source-type-grid { grid-template-columns: 1fr; }
  .priority-copy strong { font-size: 13px; }
  .answer-point { grid-template-columns: 19px minmax(0,1fr); gap: 7px; font-size: 12px; }
  .answer-point > span { width: 19px; height: 19px; }
  .drawer-footer { flex-direction: column-reverse; }
}

@media (pointer: coarse) {
  .button, .icon-button, .text-link, .section-tab, .nav-item { min-height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* Production runtime additions. The approved prototype rules above stay unchanged. */
:root {
  --border: var(--line);
  --surface2: var(--surface-2);
  --text-secondary: var(--muted);
  --text-muted: var(--quiet);
  --text-dim: var(--placeholder);
  --orange: var(--brand);
  --accent: var(--accent-text);
}

body > .app-shell {
  position: relative;
  z-index: 0;
  isolation: isolate;
}

#prototypePanel,
.prototype-panel,
.prototype-trigger,
[data-prototype-only] {
  display: none !important;
}

/* Watch panes scroll independently. The border is the only split indicator. */
.attention-layout {
  align-items: stretch;
  overflow: hidden;
  scrollbar-gutter: auto;
}

.attention-main,
.attention-detail {
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.attention-main::-webkit-scrollbar,
.attention-detail::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.attention-main::-webkit-scrollbar-button,
.attention-detail::-webkit-scrollbar-button,
.attention-main::-webkit-scrollbar-track,
.attention-detail::-webkit-scrollbar-track {
  display: none;
}

.attention-detail {
  border-left: 1px solid var(--line);
}

/* Authentication uses the same quiet surfaces and controls as the product. */
.login-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  padding: max(20px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right))
    max(20px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  background: var(--bg);
}

.login-box {
  width: min(390px, 100%);
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}

.login-box .logo-icon,
.login-box .brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
}

.login-box .logo-icon svg,
.login-box .brand-mark svg {
  width: 27px;
  height: 27px;
  fill: currentColor;
}

#login-brand-name {
  margin: 0 0 22px;
  color: var(--text);
  font-size: 20px;
  line-height: 1.25;
  letter-spacing: -.025em;
  text-align: center;
}

.login-input {
  width: 100%;
  min-height: 46px;
  margin: 0 0 12px;
  padding: 10px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  outline: 0;
  background: var(--surface-2);
  color: var(--text);
  font-size: 14px;
}

.login-input::placeholder {
  color: var(--placeholder);
  opacity: 1;
}

.login-input:hover {
  border-color: color-mix(in srgb, var(--line-strong), var(--text) 20%);
}

.login-input:focus-visible {
  border-color: var(--focus);
  outline: 2px solid var(--focus);
  outline-offset: 1px;
}

.pw-wrap {
  position: relative;
  width: 100%;
}

.pw-wrap .login-input {
  padding-right: 48px;
}

.pw-toggle {
  position: absolute;
  top: 1px;
  right: 1px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.pw-toggle:hover {
  background: var(--surface-3);
  color: var(--text);
}

.pw-toggle svg {
  width: 18px;
  height: 18px;
}

.login-btn {
  width: 100%;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border: 1px solid var(--brand);
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  transition: border-color var(--ease), background var(--ease), opacity var(--ease);
}

.login-btn:hover {
  border-color: var(--brand-hover);
  background: var(--brand-hover);
}

.login-btn:active {
  transform: translateY(1px);
}

.login-btn:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.login-error {
  margin: 11px 0 0;
  color: var(--danger-text);
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

.login-switch {
  margin: 14px 0 0 !important;
  color: var(--muted) !important;
  font-size: 12px !important;
  line-height: 1.5;
  text-align: center;
}

.login-switch a {
  color: var(--accent-text) !important;
  text-underline-offset: 3px;
}

@media (max-width: 760px) {
  .drawer,
  .drawer--wide {
    inset: 0;
    width: 100%;
    max-width: none;
    height: 100dvh;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .drawer-shell {
    height: 100dvh;
  }

  .drawer-head {
    min-height: calc(var(--mobile-header-height) + env(safe-area-inset-top));
    padding-top: calc(8px + env(safe-area-inset-top));
  }

  .drawer-scroll {
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
  }

  .login-overlay {
    align-items: flex-start;
    padding-top: max(28px, 8svh);
  }

  .login-box {
    width: 100%;
    padding: 26px 20px 28px;
  }
}

.partial-notice,
.danger-notice {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  margin: 12px 0;
  padding: 12px 14px;
  border: 1px solid var(--warning-line);
  border-radius: 8px;
  background: var(--warning-soft);
  color: var(--text);
}

.partial-notice strong,
.danger-notice strong {
  display: block;
  font-size: 12px;
}

.partial-notice p,
.danger-notice p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.partial-notice-wrap {
  padding-top: 10px;
}

.partial-notice-wrap .partial-notice {
  margin: 0;
}

.danger-notice {
  grid-template-columns: minmax(0, 1fr);
  border-color: var(--danger-line);
  background: var(--danger-soft);
}

.correction-form {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.correction-form > h3 {
  margin: 0 0 15px;
  font-size: 14px;
}

.wizard-steps > span {
  flex: 1;
  padding: 8px 10px;
  border-bottom: 2px solid var(--line);
  color: var(--quiet);
  font-size: 10px;
  font-weight: 700;
}

.wizard-steps > span.is-active,
.wizard-steps > span.is-done {
  border-color: var(--brand);
  color: var(--text);
}

.check-list {
  display: grid;
  gap: 8px;
  margin: 20px 0 0;
  padding: 0;
  border: 0;
}

.check-list legend {
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 750;
}

.check-option {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  cursor: pointer;
}

.check-option:has(input:checked) {
  border-color: color-mix(in srgb, var(--brand), var(--line) 38%);
  background: color-mix(in srgb, var(--brand), transparent 92%);
}

.check-option input {
  margin: 2px 0 0;
  accent-color: var(--brand);
}

.check-option strong,
.check-option small {
  display: block;
}

.check-option strong {
  font-size: 12px;
}

.check-option small {
  margin-top: 4px;
  color: var(--quiet);
  font-size: 10px;
  line-height: 1.45;
}

.field-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 110px;
  gap: 12px;
}

.field-error {
  margin: 12px 0 0;
  color: var(--danger-text);
  font-size: 11px;
}

@media (max-width: 760px) {
  .partial-notice {
    grid-template-columns: 20px minmax(0, 1fr);
    margin: 10px 17px;
  }

  .partial-notice .button {
    grid-column: 2;
    justify-self: start;
  }

  .field-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media (forced-colors: active) {
  button:focus-visible,
  a:focus-visible,
  input:focus-visible,
  textarea:focus-visible,
  select:focus-visible,
  [tabindex]:focus-visible {
    outline: 2px solid CanvasText;
  }
}

@media (prefers-reduced-motion: reduce) {
  .drawer,
  .overlay,
  .login-btn {
    transition: none !important;
  }

  .waveform span {
    animation: none !important;
  }
}
