/* Shared visual system: monochrome workspace, generous spacing, quiet surfaces. */
:root {
  --ink: #171719;
  --muted: #6d6d75;
  --line: #e5e5e9;
  --paper: #fff;
  --white: #fff;
  --surface: #f5f5f7;
  --surface-strong: #ebebef;
  --teal: #171719;
  --teal-soft: #ebebef;
  --amber: #805d29;
  --amber-soft: #f8f1e6;
  --radius: 16px;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; font-size: 14px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, a, input, select, summary { touch-action: manipulation; }
button, summary { cursor: pointer; }
button:disabled { cursor: default; opacity: .48; }
:where(button, a, input, select, textarea, summary, [tabindex]):focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon-definitions { position: absolute; width: 0; height: 0; overflow: hidden; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 32px; letter-spacing: -1.2px; line-height: 1.35; font-weight: 750; }
h2 { font-size: 18px; letter-spacing: -.55px; font-weight: 700; }
h3 { font-size: 17px; letter-spacing: -.45px; }
small { font-size: 12px; }
[hidden] { display: none !important; }
.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; }
.skip-link { position: fixed; z-index: 30; top: -100px; left: 20px; background: var(--ink); color: #fff; border-radius: 8px; padding: 10px 20px; }
.skip-link:focus { top: 12px; }

/* A compact navigation rail leaves the workspace to the actual call data. */
.app-shell { display: flex; min-height: 100vh; padding: 16px 16px 16px 18px; gap: 0; }
.sidebar { width: 96px; flex-shrink: 0; position: sticky; top: 16px; height: calc(100dvh - 32px); display: flex; flex-direction: column; align-items: center; padding: 20px 10px 16px; border-radius: 22px; background: #101011; color: #fff; z-index: 10; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #4c4c55 transparent; }
.sidebar>.rail-brand, .sidebar>.main-nav, .sidebar>.sidebar-bottom { flex-shrink: 0; }
.rail-brand { display: grid; place-items: center; width: 64px; height: 70px; font-family: Arial, sans-serif; font-size: 39px; font-weight: 800; letter-spacing: -3px; line-height: 1; border-radius: 12px; }
.main-nav { display: flex; flex-direction: column; gap: 14px; width: 100%; margin-top: 42px; }
.nav-link { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 70px; padding: 12px 3px; border-radius: 12px; font-size: 10px; color: #b8b8bd; transition: background .15s, color .15s; }
.nav-link svg { width: 24px; height: 24px; stroke-width: 1.6; }
.nav-link:hover { background: #242426; color: #fff; }
.nav-link.active { background: #fff; color: #111; font-weight: 700; }
.sidebar-bottom { margin-top: auto; padding-top: 26px; width: 100%; }
.rail-logout { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 7px; border: 0; background: transparent; color: #c8c8ce; font-size: 10px; border-radius: 12px; padding: 12px 0; width: 100%; }
.rail-logout:hover { background: #242426; color: #fff; }
.sidebar :focus-visible { outline-color: #bcbcc4; }
.main-shell { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.topbar { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 42px; }
.breadcrumb { display: flex; align-items: center; gap: 16px; font-size: 12px; color: var(--muted); }
.breadcrumb a { font-weight: 700; color: var(--ink); }
.breadcrumb>span { color: #c0c0c7; }
.breadcrumb strong { font-weight: 400; }
.topbar-right { display: flex; align-items: center; gap: 22px; font-size: 11px; }
.topbar-date { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.account-menu { position: relative; }
.account-menu>summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 6px 0 6px 6px; border-radius: 8px; }
.account-menu>summary::-webkit-details-marker { display: none; }
.avatar { width: 34px; height: 34px; background: var(--surface-strong); color: #35353b; display: grid; place-items: center; border-radius: 10px; font-size: 13px; font-weight: 650; flex-shrink: 0; }
.account-display { max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.account-chevron { width: 14px; height: 14px; color: var(--muted); }
.account-dropdown { position: absolute; z-index: 20; top: calc(100% + 8px); right: 0; width: 230px; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px; box-shadow: 0 12px 40px #00000012; }
.account-dropdown>strong, .account-dropdown>span { display: block; overflow-wrap: anywhere; }
.account-dropdown>strong { font-size: 13px; }
.account-dropdown>span { font-size: 11px; color: var(--muted); margin: 4px 0 15px; }
.account-dropdown>a { display: flex; align-items: center; gap: 9px; font-size: 12px; border-top: 1px solid var(--line); padding-top: 14px; }
.account-dropdown svg { width: 15px; height: 15px; }
main#main { padding: 28px 42px 42px; flex: 1; max-width: 1600px; width: 100%; margin: 0 auto; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 32px; }
.eyebrow { font-size: 10px; letter-spacing: 1.8px; color: var(--muted); font-weight: 650; margin-bottom: 10px; }
.page-description { color: var(--muted); font-size: 13px; margin-top: 11px; line-height: 1.85; }
.page-heading.page-banner { padding: 16px 0; background: #fff; border-radius: 0; margin-bottom: 16px; }
.page-banner h1 { font-size: 25px; letter-spacing: -.8px; }
.page-banner .page-description { font-size: 12px; margin-top: 4px; }
.badge { font-size: 11px; line-height: 1.6; border-radius: 6px; padding: 5px 9px; display: inline-flex; align-items: center; white-space: nowrap; font-weight: 500; }
.badge.neutral { background: #f0f0f3; color: #66666f; }
.badge.teal { background: #e9e9ed; color: #303036; }
.badge.amber { background: var(--amber-soft); color: var(--amber); }
.muted { color: var(--muted); font-size: 12px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.panel-header { min-height: 80px; padding: 22px 25px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.panel-header h2+.muted { font-size: 12px; display: block; margin-top: 5px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 42px; padding: 10px 19px; border-radius: 8px; font-weight: 600; font-size: 12px; border: 1px solid transparent; transition: background .15s; white-space: nowrap; }
.button svg { width: 16px; height: 16px; }
.button.primary { background: #141416; color: #fff; }
.button.primary:hover { background: #343439; }
.button.secondary { background: #fff; border-color: #dddde2; color: #3e3e46; }
.button.secondary:hover { background: #efeff2; }
input, select { border: 1px solid #dddde3; background: #fff; padding: 11px 12px; border-radius: 8px; width: 100%; color: var(--ink); height: 44px; min-width: 0; }
input::placeholder { color: #85858e; opacity: 1; }
select { color-scheme: light; }
input[type=checkbox] { width: auto; height: auto; accent-color: var(--ink); }
input[type=date] { font-variant-numeric: tabular-nums; }
input[type=date]::-webkit-date-and-time-value { text-align: left; }

/* Saved cases: compact counts, useful filters and quiet, rounded table rows. */
.results-panel { border: 0; border-radius: 0; overflow: visible; }
.case-filters { padding: 18px 20px; display: flex; flex-direction: column; gap: 14px; background: var(--surface); border: 1px solid #e6e6ec; border-radius: 14px; }
.filter-top-row { display: grid; grid-template-columns: minmax(150px,1.05fr) minmax(220px,1.85fr) minmax(260px,1.45fr) auto; gap: 12px 14px; align-items: end; }
.filter-select-grid { display: grid; grid-template-columns: repeat(3,minmax(110px,.9fr)) repeat(2,minmax(145px,1.35fr)) repeat(2,minmax(115px,1fr)); gap: 12px; padding-top: 14px; border-top: 1px solid #e3e3ea; align-items: end; }
.filter-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.case-filters label, .filter-period legend { display: flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; color: #52525c; margin-bottom: 6px; padding: 0; line-height: 1.3; letter-spacing: -.1px; }
.filter-field.is-active label, .filter-field.is-active legend { color: var(--ink); }
.filter-field.is-active label::after, .filter-field.is-active legend::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); flex-shrink: 0; }
.case-filters input, .case-filters select { height: 38px; font-size: 12px; padding: 7px 11px; border: 1px solid #dcdce4; border-radius: 8px; background: #fff; transition: border-color .15s, box-shadow .15s, background-color .15s; }
.case-filters input:hover, .case-filters select:hover { border-color: #b4b4c0; }
.case-filters input:focus, .case-filters select:focus { border-color: var(--ink); box-shadow: 0 0 0 3px #17171912; outline: none; }
.filter-input-wrap { position: relative; display: flex; align-items: center; }
.filter-input-icon { position: absolute; left: 11px; width: 14px; height: 14px; color: #8a8a94; pointer-events: none; transition: color .15s; }
.filter-input-wrap input { padding-left: 31px; }
.filter-field.is-active .filter-input-icon, .filter-input-wrap:focus-within .filter-input-icon { color: var(--ink); }
.filter-select-wrap { position: relative; display: flex; align-items: center; }
.filter-select-wrap select { appearance: none; -webkit-appearance: none; padding-right: 28px; text-overflow: ellipsis; white-space: nowrap; overflow: hidden; cursor: pointer; }
.select-chevron { position: absolute; right: 10px; width: 13px; height: 13px; color: #787882; pointer-events: none; transition: color .15s; }
.filter-select-wrap:hover .select-chevron, .filter-field.is-active .select-chevron { color: var(--ink); }
.filter-date-range { display: grid; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); align-items: center; gap: 4px; height: 38px; padding: 0 8px; background: #fff; border: 1px solid #dcdce4; border-radius: 8px; transition: border-color .15s, box-shadow .15s; }
.filter-date-range:hover { border-color: #b4b4c0; }
.filter-date-range:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px #17171912; }
.filter-date-range input[type=date] { height: 34px; border: 0; padding: 0 2px; background: transparent; font-size: 12px; box-shadow: none; }
.filter-date-range input[type=date]:focus { box-shadow: none; outline: none; }
.date-range-sep { font-size: 12px; color: #8a8a94; padding: 0 2px; user-select: none; }
.filter-field.is-active .filter-input-wrap input, .filter-field.is-active select, .filter-field.is-active .filter-date-range { border-color: #27272d; background: #fff; font-weight: 600; box-shadow: 0 1px 2px #0000000a; }
.filter-actions { display: flex; align-items: center; gap: 8px; height: 38px; }
.filter-actions .button { min-height: 38px; height: 38px; padding: 0 16px; font-size: 12px; gap: 6px; border-radius: 8px; }
.filter-actions .button svg { width: 14px; height: 14px; }
.active-filter-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--ink); color: #fff; font-size: 10px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.filter-errors { margin: 15px 0 20px; padding: 14px 18px; background: var(--amber-soft); border-radius: 8px; font-size: 12px; color: var(--amber); }
.results-summary { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 20px; padding: 14px 3px 8px; color: var(--muted); font-size: 11px; }
.results-summary-counts { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 18px; }
.results-summary-counts span { white-space: nowrap; }
.results-summary-counts strong { font-size: inherit; font-weight: 650; color: var(--ink); margin-left: 4px; }
.filtered-result-pill { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; background: var(--ink); color: #fff; font-size: 11px; font-weight: 500; }
.results-summary-counts .filtered-result-pill strong { color: #fff; font-weight: 700; margin: 0 2px 0 4px; }
.results-summary-updated { font-size: 10px; white-space: nowrap; }
.results-summary-updated time { margin-left: 6px; font-variant-numeric: tabular-nums; }
.table-scroll { overflow-x: auto; }
.table-scroll-hint { display: none; }
.table-scroll[tabindex]:focus-visible { outline-offset: 0; border-radius: 10px; }
.results-table { border-collapse: separate; border-spacing: 0 8px; width: 100%; text-align: left; font-size: 12px; }
.results-table th { padding: 8px 18px; color: var(--muted); background: transparent; font-size: 11px; font-weight: 500; white-space: nowrap; }
.results-table td { padding: 19px 18px; background: var(--surface); border: 0; vertical-align: middle; color: #38383f; font-size: 12px; transition: background .15s; }
.results-table td:first-child { border-radius: 11px 0 0 11px; }
.results-table td:last-child { border-radius: 0 11px 11px 0; }
.results-table tbody tr:hover td { background: #eeeef2; }
.results-table td small { display: block; font-size: 10px; color: var(--muted); margin-top: 5px; }
.case-number { font-weight: 750; color: var(--ink); font-variant-numeric: tabular-nums; font-size: 13px; }
.case-number:hover { text-decoration: underline; text-underline-offset: 4px; }
.case-number span { font-size: 11px; color: #8a8a92; margin-left: 3px; }
.result-name { max-width: 230px; overflow-wrap: anywhere; }
.results-table .no-results { text-align: center; padding: 60px 25px; color: var(--muted); }
.cases-table { table-layout: fixed; min-width: 1100px; }
.results-table.cases-table td { background: #f0f0f3; }
.results-table.cases-table tbody tr:hover td { background: #e1e1e7; }
.cases-table th, .cases-table td { padding-left: 14px; padding-right: 14px; }
.cases-table th:nth-child(1) { width: 7.5%; }
.cases-table th:nth-child(2) { width: 8.5%; }
.cases-table th:nth-child(3) { width: 6.5%; }
.cases-table th:nth-child(4) { width: 7.5%; }
.cases-table th:nth-child(5) { width: 5.5%; }
.cases-table th:nth-child(6) { width: 17.5%; }
.cases-table th:nth-child(7) { width: 8.5%; }
.cases-table th:nth-child(8) { width: 38.5%; }
.cases-table td { overflow-wrap: anywhere; line-height: 1.65; }
.cases-table .case-category { word-break: keep-all; }
.cases-table .case-recordings { font-weight: 500; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cases-table .case-recordings small { white-space: nowrap; }
.category-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-weight: 500; color: #27272e; }
.case-alert-badge { display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 999px; background: var(--amber-soft); color: var(--amber); font-size: 10px; font-weight: 700; line-height: 1.3; white-space: nowrap; }
.summary-cell-header { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 6px; }
.summary-cell-header:empty { display: none; margin-bottom: 0; }
/* Distinguish active work from recordings excluded after screening. */
.cases-table .badge.case-status-processing { background: #eaf2ff; color: #2457a7; gap: 6px; }
.cases-table .badge.case-status-processing::before { content: ""; width: 5px; height: 5px; flex: 0 0 auto; border-radius: 50%; background: currentColor; }
.cases-table .badge.case-status-announcement { background: #f1f1f3; color: #62626b; }
.summary-meta-tag { display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 6px; background: #e3e4ea; color: #4a4b55; font-size: 10px; font-weight: 600; line-height: 1.3; white-space: nowrap; }
.pagination { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; padding: 18px 3px 24px; font-size: 11px; color: var(--muted); }
.pagination nav { display: flex; align-items: center; gap: 17px; }
.pagination nav a { border: 1px solid var(--line); background: #fff; border-radius: 6px; padding: 5px 11px; color: var(--ink); }
.pagination nav a:hover { background: var(--surface); }
.page-size-controls { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.page-size-controls label { white-space: nowrap; margin: 0; font-size: 11px; }
.page-size-controls select { width: 77px; border-radius: 6px; padding: 5px 8px; height: 32px; font: inherit; }
.page-size-controls .button { min-height: 32px; padding: 5px 11px; font-size: 11px; }
.panel-footnote { border-top: 1px solid var(--line); padding: 14px 24px; display: flex; gap: 8px; align-items: center; font-size: 10px; color: var(--muted); }
.results-panel>.panel-footnote { padding-left: 3px; padding-right: 3px; }
.panel-footnote svg { width: 13px; height: 13px; }
.bottom-note { display: flex; align-items: center; gap: 9px; font-size: 11px; color: var(--muted); margin-top: 22px; }
.small-dot { width: 4px; height: 4px; border-radius: 50%; background: #9c9ca6; flex-shrink: 0; }
.site-footer { padding: 18px 42px 8px; display: flex; justify-content: space-between; gap: 20px; font-size: 10px; color: #7e7e88; }

/* Case context and recording cards. */
.back-link { display: inline-block; font-size: 12px; color: var(--muted); margin-bottom: 23px; }
.back-link:hover { color: var(--ink); }
.section-title { display: flex; align-items: center; justify-content: space-between; margin: 30px 0 18px; gap: 12px; }
.section-title h2 span { color: var(--muted); font-weight: 450; margin-left: 6px; }
.recording-agents { display: flex; align-items: baseline; gap: 8px 16px; font-size: 11px; line-height: 1.7; color: var(--muted); }
.recording-agents>span { flex-shrink: 0; }
.recording-agents ul { list-style: none; padding: 0; margin: 0; min-width: 0; }
.recording-agents code { font-size: 11px; overflow-wrap: anywhere; color: #555560; }
.historical-note { padding: 13px 15px; background: #eaeaf0; color: #62626d; font-size: 11px; border-radius: 8px; margin-top: 17px; }
.asset-issues { color: var(--amber); background: var(--amber-soft); padding: 13px 15px; font-size: 11px; border-radius: 8px; margin: 15px 0; }
.history-panel { margin-top: 32px; border: 0; border-radius: 0; }
.history-panel>.panel-header { padding-left: 0; padding-right: 0; }
.import-notice { margin-bottom: 20px; }
.review-entry { display: flex; gap: 12px; flex-wrap: wrap; margin: 0 0 24px; }

/* Empty states, monitoring and workspace settings. */
.review-path { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 23px 26px; margin-bottom: 28px; background: var(--surface); border-radius: var(--radius); }
.review-path>div { display: flex; align-items: center; gap: 12px; }
.step-number { font-size: 10px; font-weight: 650; color: var(--muted); }
.review-path svg { width: 23px; height: 23px; }
.review-path strong { display: block; font-size: 12px; }
.review-path small { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; }
.path-arrow { color: #b4b4bd; font-size: 18px; }
.search-placeholder { display: flex; align-items: center; gap: 8px; background: var(--surface); color: var(--muted); border-radius: 8px; padding: 10px 12px; font-size: 11px; }
.search-placeholder svg { width: 15px; height: 15px; }
.empty-table { border-collapse: collapse; width: 100%; white-space: nowrap; }
.empty-table thead { background: var(--surface); }
.empty-table th { text-align: left; padding: 13px 25px; color: var(--muted); font-size: 11px; font-weight: 500; }
.empty-state { text-align: center; padding: 60px 25px 48px; }
.empty-state h3 { font-size: 17px; margin-top: 26px; }
.empty-state p { font-size: 13px; line-height: 1.9; color: var(--muted); margin-top: 12px; }
.empty-caption { display: inline-block; border-radius: 6px; background: var(--surface); font-size: 11px; color: var(--muted); padding: 7px 12px; margin-top: 22px; }
.empty-illustration { position: relative; width: 94px; height: 82px; margin: auto; }
.illustration-card { width: 63px; height: 77px; background: var(--surface); border: 1px solid #dddde3; border-radius: 9px; transform: rotate(-6deg); padding: 19px 13px; }
.illustration-card span { display: block; height: 3px; background: #d1d1db; margin: 7px 0; border-radius: 3px; }
.illustration-card span:last-child { width: 60%; }
.illustration-audio { position: absolute; bottom: 0; right: 3px; display: grid; place-items: center; background: #ededf1; width: 46px; height: 45px; border-radius: 12px; border: 3px solid #fff; color: #555560; }
.metric-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; margin-bottom: 28px; }
.metric { background: var(--surface); border-radius: var(--radius); padding: 24px 27px; }
.metric span { color: #54545e; font-size: 13px; }
.metric strong { display: block; font-size: 36px; font-weight: 700; margin: 10px 0; color: #a4a4ae; }
.metric small { color: var(--muted); font-size: 11px; }
.pipeline-steps { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 25px; background: var(--surface); }
.pipeline-steps span { border-radius: 8px; padding: 10px 17px; background: #fff; color: #52525e; font-size: 12px; }
.pipeline-steps b { font-weight: 400; color: #aaaab4; }
.compact-empty { text-align: center; padding: 56px 25px; }
.compact-empty>svg { color: #72727e; width: 40px; height: 40px; margin-bottom: 20px; }
.compact-empty h3 { font-size: 17px; }
.compact-empty p { color: var(--muted); margin-top: 12px; font-size: 13px; line-height: 1.9; }
.compact-empty.tall { padding: 80px 25px; }
.compact-empty .button { margin-top: 28px; }
.round-icon { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; background: var(--surface-strong); margin: 0 auto 24px; }
.round-icon svg { width: 28px; height: 28px; }
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.status-list { margin: 0; padding: 0 25px 10px; }
.status-list>div { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; border-top: 1px solid var(--line); gap: 15px; font-size: 12px; }
.status-list dt { color: var(--muted); }
.status-list dd { margin: 0; font-size: 12px; }
.status-list dd .badge { margin-left: 7px; font-size: 10px; }
.roles { padding: 0 25px; }
.roles>div { border-top: 1px solid var(--line); padding: 17px 0; }
.roles strong { font-size: 13px; }
.roles p { font-size: 12px; color: var(--muted); margin-top: 3px; }
.account-management { padding: 10px 25px 25px; }
.notice { display: flex; align-items: center; gap: 15px; margin-top: 25px; padding: 20px 24px; background: var(--surface); border-radius: 12px; color: #53535f; }
.notice strong { font-size: 13px; color: #33333c; }
.notice p { font-size: 12px; margin-top: 5px; color: var(--muted); }

/* Accounts share the same typography and grayscale surfaces. */
.form-panel { max-width: 580px; padding: 30px; }
.form-panel label, .login-card label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 8px; margin-top: 22px; color: #454550; }
.help-text { font-size: 12px; color: var(--muted); margin: 10px 0; }
.help-text ul { padding-left: 18px; }
.form-panel .button { margin-top: 23px; }
.field-errors, .errorlist { font-size: 12px; color: #943e35; padding-left: 16px; }
.form-error { background: #fbf0ef; border: 1px solid #eed6d2; border-radius: 8px; color: #923e34; font-size: 12px; padding: 13px; margin: 20px 0; }
.messages { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-bottom: 20px; }
.login-layout { min-height: 100dvh; display: grid; grid-template-columns: 1fr 1fr; padding: 20px; gap: 20px; }
.login-story { display: flex; flex-direction: column; background: #111113; color: #fff; border-radius: 24px; padding: 45px 54px; }
.brand { display: flex; align-items: center; gap: 12px; line-height: 1.3; font-weight: 700; font-size: 16px; letter-spacing: -.5px; }
.brand .rail-brand { width: 48px; height: 52px; font-size: 31px; letter-spacing: -2px; border-radius: 10px; background: #fff; color: #111; flex-shrink: 0; }
.brand-copy { flex: 1; min-width: 0; }
.brand-title-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand-name { white-space: nowrap; }
.brand-partner { display: flex; align-items: center; flex-shrink: 0; }
.brand-partner img { display: block; width: 104px; height: auto; }
.brand small { display: block; font-size: 11px; letter-spacing: 0; color: #a5a5af; font-weight: 500; margin-top: 7px; }
.story-content { margin: auto 0; max-width: 480px; padding: 64px 0; }
.story-content .eyebrow { color: #a5a5af; }
.story-content h1 { font-size: 38px; font-weight: 650; letter-spacing: -1.8px; line-height: 1.5; margin-top: 20px; }
.story-content>p:not(.eyebrow) { font-size: 14px; color: #b6b6c0; line-height: 1.9; margin-top: 24px; }
.login-footnote { font-size: 11px; color: #a5a5af; }
.wave-art { display: flex; align-items: center; gap: 6px; height: 105px; margin-top: 38px; }
.wave-art i { width: 4px; background: #797980; border-radius: 5px; height: 18px; transform-origin: center; transition: background-color .18s ease; }
.wave-art.is-reacting i { background: #b5b5bf; will-change: transform; }
.wave-art i:nth-child(3n) { height: 37px; }
.wave-art i:nth-child(4n) { height: 67px; }
.wave-art i:nth-child(5n) { height: 49px; }
.wave-art i:nth-child(7n) { height: 89px; background: #fff; }
.wave-art i:nth-child(9n) { height: 28px; }
.story-caption { display: flex; gap: 17px; font-size: 14px; color: #b6b6c0; margin-top: 6px; }
.story-caption span { color: #76767e; }
.login-form-side { display: flex; align-items: center; justify-content: center; padding: 50px; }
.login-card { width: 100%; max-width: 360px; }
.login-intro { text-align: center; }
.login-illustration { display: block; width: clamp(180px, 24vh, 240px); max-width: 75%; height: auto; margin: 0 auto 18px; }
.login-card h2 { font-size: 27px; letter-spacing: -1px; font-weight: 700; margin-top: 0; }
.form-description { color: var(--muted); font-size: 13px; margin-top: 11px; }
.login-intro .form-description { margin-top: 8px; }
.login-card form { margin-top: 24px; }
.login-card form label { margin-top: 18px; }
.login-card input { height: 48px; background: var(--surface); border-color: transparent; }
.login-card input:focus { background: #fff; }
.login-submit { width: 100%; margin-top: 24px; height: 48px; justify-content: space-between; padding: 12px 18px; }
.login-help { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 18px; display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.login-help svg { width: 13px; height: 13px; }

@media (max-width: 1280px) {
  .filter-top-row { grid-template-columns: minmax(140px,1fr) minmax(190px,1.4fr) minmax(240px,1.35fr) auto; }
  .filter-select-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
@media (max-width: 1300px) {
  .table-scroll-hint { display: block; font-size: 10px; color: var(--muted); margin: 1px 0 10px 3px; }
}
@media (max-width: 1200px) {
  .topbar { padding: 0 28px; }
  main#main { padding: 28px; }
  .site-footer { padding-left: 28px; padding-right: 28px; }
  .review-path small, .step-number { display: none; }
}
@media (max-width: 1000px) {
  .filter-top-row, .filter-select-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .filter-actions { justify-content: flex-end; }
  .topbar-date { display: none; }
  .search-placeholder { display: none; }
  .settings-grid { grid-template-columns: 1fr; }
  .pipeline-steps { flex-wrap: wrap; justify-content: center; }
  .login-story { padding: 35px; }
  .story-content h1 { font-size: 32px; }
}
@media (max-width: 700px) {
  .app-shell { display: block; padding: 10px; }
  .sidebar { position: static; width: 100%; height: auto; flex-direction: row; justify-content: space-between; padding: 7px 10px; border-radius: 16px; overflow: visible; }
  .rail-brand { width: 46px; height: 54px; font-size: 29px; letter-spacing: -2px; flex-shrink: 0; }
  .main-nav { flex-direction: row; gap: 4px; width: auto; margin: 0; }
  .nav-link { min-height: 53px; padding: 7px 11px; gap: 4px; font-size: 9px; border-radius: 9px; }
  .nav-link svg { width: 19px; height: 19px; }
  .sidebar-bottom { padding: 0; margin: 0; width: auto; }
  .rail-logout { padding: 8px; gap: 5px; font-size: 9px; }
  .rail-logout svg { width: 19px; height: 19px; }
  .topbar { min-height: 65px; padding: 0 10px; gap: 10px; }
  .breadcrumb { gap: 10px; font-size: 11px; }
  .breadcrumb>span, .breadcrumb>strong { display: none; }
  .topbar-right { gap: 14px; }
  .account-display { display: none; }
  .avatar { width: 29px; height: 29px; font-size: 12px; border-radius: 8px; }
  main#main { padding: 18px 10px 30px; }
  h1 { font-size: 26px; }
  h2 { font-size: 17px; }
  .page-heading { margin-bottom: 25px; gap: 14px; align-items: flex-start; }
  .page-heading>.badge { font-size: 10px; }
  .page-description { font-size: 12px; }
  .page-heading.page-banner { padding: 16px 0; gap: 10px; }
  .page-banner h1 { font-size: 23px; }
  .panel-header { padding: 20px; }
  .panel-header h2+.muted { font-size: 11px; }
  .case-filters { padding: 16px; gap: 12px; }
  .filter-top-row, .filter-select-grid { grid-template-columns: 1fr; }
  .case-filters label, .filter-period legend { font-size: 11px; }
  .case-filters input, .case-filters select, .filter-date-range { height: 40px; font-size: 12px; }
  .filter-actions { width: 100%; height: 40px; }
  .filter-actions .button { flex: 1; min-height: 40px; height: 40px; padding: 0 12px; }
  .results-summary { padding-top: 14px; font-size: 10px; gap: 5px; }
  .results-summary-counts { gap: 4px 12px; }
  .results-summary-updated { width: 100%; font-size: 10px; }
  .pagination { font-size: 10px; padding: 14px 0 20px; gap: 14px; }
  .page-size-controls { order: 1; flex-basis: 100%; }
  .page-size-controls label, .page-size-controls .button { font-size: 10px; }
  .pagination nav { gap: 12px; }
  .panel-footnote { padding: 14px 18px; font-size: 10px; align-items: flex-start; }
  .panel-footnote svg { margin-top: 3px; }
  .bottom-note { font-size: 10px; align-items: flex-start; }
  .bottom-note .small-dot { margin-top: 7px; }
  .site-footer { padding: 16px 10px 10px; gap: 12px; font-size: 9px; flex-wrap: wrap; }
  .section-title { align-items: flex-start; }
  .section-title>.muted { font-size: 10px; text-align: right; }
  .section-title h2 { white-space: nowrap; }
  .recording-agents { flex-direction: column; gap: 3px; }
  .history-panel .panel-header { flex-wrap: wrap; }
  .history-panel .table-scroll { overflow-x: auto; }
  .history-panel .results-table { min-width: 650px; }
  .metric-grid { gap: 9px; }
  .metric { padding: 18px 13px; border-radius: 12px; }
  .metric span, .metric small { font-size: 10px; }
  .metric strong { font-size: 27px; }
  .pipeline-steps { padding: 20px; gap: 9px; }
  .pipeline-steps span { font-size: 11px; padding: 7px 10px; }
  .review-path { gap: 6px; padding: 18px 15px; }
  .review-path svg { display: none; }
  .review-path strong { font-size: 10px; }
  .path-arrow { font-size: 12px; }
  .empty-state { padding: 44px 18px; }
  .empty-state h3 { font-size: 16px; }
  .empty-state p, .compact-empty p { font-size: 12px; }
  .compact-empty.tall { padding: 55px 20px; }
  .notice { padding: 18px; align-items: flex-start; }
}
@media (max-width: 900px) {
  .login-layout { display: block; padding: 12px; }
  .login-story { padding: 25px; border-radius: 16px; }
  .brand { gap: 8px; }
  .brand .rail-brand { width: 40px; height: 44px; font-size: 26px; letter-spacing: -2px; }
  .brand-title-row { gap: 8px; }
  .brand-name { font-size: clamp(11px, 3.3vw, 16px); }
  .brand-partner img { width: clamp(64px, 20vw, 96px); }
  .story-content, .login-footnote { display: none; }
  .login-form-side { padding: 28px 22px; }
  .login-card { max-width: 380px; }
  .login-illustration { width: 160px; margin-bottom: 14px; }
  .login-card h2 { font-size: 25px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
.summary-notes { margin: 12px 0 16px; color: #5d626b; font-size: 13px; line-height: 1.6; }
.summary-notes p { margin: 0 0 4px; }
.summary-notes summary { cursor: pointer; }
.summary-notes ul { margin: 6px 0 0; padding-left: 20px; }
.memo-preview { margin: 0; font-size: 12px; line-height: 1.55; color: #2f2f37; white-space: normal; overflow-wrap: anywhere; word-break: keep-all; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }

/* Daily Monitoring Dashboard */
.monitoring-header-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.monitoring-daemon-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 24px; }
.daemon-strip-item { background: #fff; padding: 16px 20px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.daemon-strip-label { font-size: 11px; color: var(--muted); font-weight: 600; }
.daemon-strip-item strong { font-size: 14px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.daemon-strip-item small { font-size: 11px; color: var(--muted); line-height: 1.45; }
.monitoring-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 26px; }
.monitoring-kpi-grid .metric { padding: 22px 24px; display: flex; flex-direction: column; justify-content: space-between; }
.monitoring-kpi-grid .metric strong { font-size: 30px; color: var(--ink); margin: 8px 0 6px; font-variant-numeric: tabular-nums; line-height: 1.2; }
.monitoring-kpi-grid .metric strong.text-amber { color: var(--amber); }
.metric-unit { font-style: normal; font-size: 14px; font-weight: 550; color: var(--muted); margin-left: 3px; }
.text-amber { color: var(--amber) !important; }
.monitoring-daily-panel { margin-bottom: 24px; }
.monitoring-panel-header { flex-wrap: wrap; }
.monitoring-period-tabs { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.period-tab { display: inline-flex; align-items: center; justify-content: center; height: 34px; padding: 0 13px; border-radius: 8px; font-size: 12px; font-weight: 600; color: #52525c; background: var(--surface); border: 1px solid transparent; transition: background .15s, color .15s; }
.period-tab:hover { background: var(--surface-strong); color: var(--ink); }
.period-tab.active { background: var(--ink); color: #fff; }
.daily-trend-box { margin: 0 22px 18px; padding: 18px 20px; background: var(--surface); border-radius: 14px; border: 1px solid #e6e6ec; }
.daily-trend-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.daily-trend-title { font-size: 12px; font-weight: 650; color: #383842; }
.daily-trend-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; font-size: 11px; color: var(--muted); }
.daily-trend-legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend-dot { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.legend-dot.done, .bar-seg.done { background: #1d1d22; }
.legend-dot.progress, .bar-seg.progress { background: #7b7b88; }
.legend-dot.warn, .bar-seg.warn { background: #b87b28; }
.legend-dot.muted, .bar-seg.muted { background: #d5d5de; }
.daily-trend-bars { display: grid; grid-template-columns: repeat(auto-fit, minmax(54px, 1fr)); gap: 10px; align-items: end; }
.daily-bar-col { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 8px 4px; border-radius: 10px; transition: background .15s; text-align: center; }
.daily-bar-col:hover { background: #e8e8ef; }
.daily-bar-col.is-selected { background: #e2e2ec; outline: 1.5px solid var(--ink); }
.daily-bar-rate { font-size: 10px; font-weight: 650; color: var(--muted); font-variant-numeric: tabular-nums; }
.daily-bar-track { width: 24px; height: 92px; background: #e7e7ee; border-radius: 6px; display: flex; align-items: flex-end; overflow: hidden; padding: 2px; }
.daily-bar-stack { width: 100%; border-radius: 4px; overflow: hidden; display: flex; flex-direction: column-reverse; min-height: 4px; }
.bar-seg { display: block; width: 100%; min-height: 2px; }
.daily-bar-count { font-size: 11px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.daily-bar-date { font-size: 10px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.daily-monitoring-table { min-width: 1080px; }
.daily-monitoring-table th, .daily-monitoring-table td { padding: 14px 13px; font-variant-numeric: tabular-nums; }
.daily-row-selected td { background: #e7e7ef !important; }
.daily-date-cell { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.daily-metric-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.daily-rate-cell { min-width: 145px; }
.rate-bar-wrap { display: flex; align-items: center; gap: 8px; }
.rate-bar-track { flex: 1; height: 7px; background: #e0e0e8; border-radius: 999px; overflow: hidden; min-width: 64px; }
.rate-bar-fill { height: 100%; background: var(--ink); border-radius: 999px; }
.rate-bar-fill.has-warn { background: #8f6528; }
.rate-bar-label { font-size: 12px; font-weight: 700; color: var(--ink); min-width: 42px; text-align: right; }
.daily-row-actions { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.daily-action-link { display: inline-flex; align-items: center; padding: 4px 9px; border-radius: 6px; background: #fff; border: 1px solid #dcdce4; font-size: 11px; font-weight: 600; color: #32323a; }
.daily-action-link:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.monitoring-two-col { display: grid; grid-template-columns: 1.15fr 1fr; gap: 20px; }
.monitoring-status-pills { flex-wrap: wrap; justify-content: flex-start; gap: 10px; }
.monitoring-status-pills a { display: inline-flex; align-items: center; gap: 8px; padding: 10px 15px; border-radius: 9px; background: #fff; border: 1px solid #e2e2ea; font-size: 12px; transition: border-color .15s, transform .1s; }
.monitoring-status-pills a:hover { border-color: var(--ink); }
.monitoring-status-pills a strong { font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.stage-health-list { padding: 8px 24px 20px; display: flex; flex-direction: column; }
.stage-health-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 12px; }
.stage-health-row:first-child { border-top: 0; }
.stage-health-badges { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-variant-numeric: tabular-nums; }

@media (max-width: 1100px) {
  .monitoring-daemon-strip, .monitoring-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .monitoring-two-col { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .monitoring-daemon-strip, .monitoring-kpi-grid { grid-template-columns: 1fr; }
}
