.directory-page { padding:0 24px 24px; }
#review-queue-view { padding:0; }
#review-queue-view > .review-queue-metrics { grid-template-columns:repeat(4,minmax(0,1fr)); margin:0 24px 20px; }
.analytics-kpi .queue-kpi-value { flex-wrap:nowrap; justify-content:space-between; }
.queue-kpi-value > strong { flex-shrink:0; }
.queue-kpi-copy { flex:1; min-width:0; }
.queue-kpi-copy > strong { display:block; }
.queue-kpi-copy > p { margin:6px 0 0; }
.queue-kpi-trend { display:flex; flex-direction:column; align-items:flex-end; gap:4px; min-width:0; width:120px; margin-left:auto; }
.queue-kpi-sparkline { display:block; width:100%; min-width:0; height:40px; color:var(--accent); overflow:visible; }
.queue-kpi-sparkline polyline { fill:none; stroke:currentColor; stroke-width:2; stroke-linecap:round; stroke-linejoin:round; vector-effect:non-scaling-stroke; }
.queue-kpi-trend .analytics-change { flex-shrink:0; margin:0; }
.analytics-metric .queue-kpi-footer { display:grid; grid-template-columns:minmax(0,1fr) auto auto; align-items:center; column-gap:10px; min-height:52px; padding:10px 20px; }
.analytics-metric .queue-kpi-footer > span:first-child { line-height:18px; }
.analytics-metric .queue-kpi-footer > strong { margin:0; line-height:24px; font-variant-numeric:tabular-nums; }
.analytics-metric .queue-kpi-footer .analytics-change { margin:0; padding:3px 7px; border-radius:6px; line-height:18px; font-variant-numeric:tabular-nums; }
@media(max-width:800px) { #review-queue-view > .review-queue-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:480px) { #review-queue-view > .review-queue-metrics { grid-template-columns:1fr; } }
#detainee-record-view { --profile-gutter:24px; padding-inline:0; }
#detainee-record-view > .detainee-profile { margin-inline:var(--profile-gutter); }
.directory-toolbar { display:flex; align-items:center; justify-content:space-between; gap:16px; margin:0 0 16px; }
.directory-filters { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.directory-toolbar-right { display:flex; align-items:center; justify-content:flex-end; gap:12px; margin-left:auto; }
.detainee-profile { display:flex; align-items:center; gap:12px; margin:24px 0; padding:20px; border:1px solid var(--line); border-radius:8px; background:var(--canvas); }
.detainee-profile .directory-avatar { width:40px; height:40px; font-size:var(--text-sm); }
.detainee-profile h2 { margin:0 0 4px; font-size:var(--text-lg); font-weight:500; }
.detainee-profile p { margin:0; }
.detainee-notification-toggle { margin-left:auto; }
.detainee-history-title { margin:0; font-size:var(--text-md); font-weight:500; }
#detainee-record-view .detainee-history-title { margin-bottom:16px; }
#detainee-record-view .calls-toolbar { padding-inline:var(--profile-gutter); }
#detainee-record-view > .record-view-panel { padding:0; border:0; background:transparent; }
#detainee-record-view > .record-view-tabs { margin:0 var(--profile-gutter) 16px; border-bottom:1px solid var(--line); }
#detainee-record-view > :is(#detainee-panel-insights,#detainee-panel-relationships) { padding-inline:var(--profile-gutter); }
#detainee-panel-insights .analytics-metrics { grid-template-columns:repeat(4,minmax(0,1fr)); margin-top:16px; }
#detainee-panel-insights .analytics-card > .intent-badge { margin:0 6px 6px 0; }
.detainee-insight-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-bottom:16px; }
.detainee-insight-card .analytics-category { grid-template-columns:90px minmax(0,1fr) 40px; margin:12px 0; }
.detainee-number-row { display:grid; grid-template-columns:24px minmax(0,1fr) auto; align-items:center; gap:10px; min-height:40px; border-top:1px solid var(--line); font-size:var(--text-sm); }
.detainee-number-row strong { font-size:var(--text-xs); font-weight:500; white-space:nowrap; }
.detainee-repeated-quote { margin:12px 0; padding:12px 16px; border-left:2px solid var(--brand-color); color:var(--ink); font-size:var(--text-sm); line-height:22px; }
.detainee-repeated-sources { display:flex; flex-wrap:wrap; gap:12px; padding:0 16px 12px; }
.detainee-notification-item { display:block; padding:10px 0; border-top:1px solid var(--line); color:var(--ink); font-size:var(--text-sm); }
.directory-context,.directory-count,.directory-muted { color:var(--subtle); font-size:var(--text-xs); line-height:18px; }
.directory-count { white-space:nowrap; }
.directory-table-scroll { overflow:auto; border:1px solid var(--line); border-radius:8px; background:var(--canvas); }
.directory-table { width:100%; table-layout:fixed; border-collapse:collapse; text-align:left; font-size:var(--text-sm); }
.directory-table th { padding:12px 16px; border-bottom:1px solid var(--line); background:var(--surface-1); color:var(--muted); font-size:var(--text-xs); font-weight:500; }
.directory-table td { overflow-wrap:anywhere; padding:16px; border-bottom:1px solid var(--line); vertical-align:top; }
.directory-table tbody tr:last-child td { border-bottom:0; }
.directory-table tbody tr:hover { background:var(--surface-1); }
.directory-table tbody tr[data-profile-href] { cursor:pointer; }
.directory-table tbody tr[data-profile-href]:focus-visible { outline:2px solid var(--focus); outline-offset:-2px; }
.directory-sort { border:0; padding:0; background:transparent; color:inherit; font:inherit; text-align:left; cursor:pointer; }
.directory-identity { white-space:normal; display:flex; align-items:center; gap:10px; white-space:normal; }
.directory-identity strong { font-weight:500; }
.directory-avatar,.directory-phone-icon { display:grid; place-items:center; flex-shrink:0; width:28px; height:28px; border-radius:6px; background:var(--surface-4); color:var(--brand-color); font-size:var(--text-xs); }
.directory-phone-icon { border-radius:6px; }
.directory-tag { display:inline-flex; align-items:center; padding:3px 6px; margin:0 4px 4px 0; border:1px solid var(--line); border-radius:4px; color:var(--muted); font-size:var(--text-xs); line-height:18px; white-space:nowrap; }
.directory-tag-list,.directory-linked-people { min-width:0; max-width:320px; }
.directory-call-count { font-variant-numeric:tabular-nums; }
.directory-alerts { min-width:0; max-width:420px; }
.directory-alerts .intent-badge { margin:0 4px 4px 0; }
.directory-alert-list { display:flex; flex-wrap:wrap; align-items:center; gap:4px; }
.directory-alert-list .intent-badge { margin:0; max-width:100%; }
.directory-alert-list .intent-badge > span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.directory-alert-overflow { display:inline-flex; align-items:center; justify-content:center; min-height:30px; padding:4px 8px; border:1px solid var(--line); border-radius:6px; background:var(--surface-2); color:var(--muted); font-size:var(--text-xs); white-space:nowrap; }
.directory-source { color:var(--brand-color); font-size:var(--text-xs); white-space:nowrap; }
.directory-date { display:block; margin-top:4px; color:var(--subtle); font-size:var(--text-xs); white-space:nowrap; }
.directory-action { text-decoration:none; white-space:nowrap; }
.directory-empty { padding:28px; text-align:center; color:var(--subtle); font-size:var(--text-sm); }
.directory-empty h3 { color:var(--ink); font-size:var(--text-md); font-weight:500; }
.analytics-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; margin-bottom:24px; }
.analytics-metric,.analytics-card { padding:20px; border:1px solid var(--line); border-radius:8px; background:var(--canvas); }
.analytics-metric > span { display:block; color:var(--muted); font-size:var(--text-xs); }
.analytics-metric strong { display:block; margin:12px 0; font-size:var(--text-xxl); font-weight:500; }
.analytics-metric p { margin:0; color:var(--subtle); font-size:var(--text-xs); line-height:18px; }
.analytics-metric .analytics-change { display:inline-flex; align-items:center; margin-top:12px; padding:3px 7px; border-radius:999px; background:var(--surface-1); color:var(--muted); font-size:var(--text-xs); line-height:18px; white-space:nowrap; }
.analytics-metric .analytics-change.is-positive { background:color-mix(in srgb,#23845b 12%,var(--canvas)); color:#167348; }
.analytics-metric .analytics-change.is-negative { background:color-mix(in srgb,#c45151 11%,var(--canvas)); color:#a63c3c; }
.analytics-kpi { display:flex; flex-direction:column; padding:0; overflow:hidden; }
.analytics-kpi-body { flex:1; padding:24px; }
.analytics-kpi-heading { display:flex; align-items:center; gap:8px; margin-bottom:24px; }
.analytics-kpi-heading h3 { margin:0; color:var(--ink); font-size:var(--text-md); font-weight:500; }
.analytics-kpi-info { display:inline-grid; place-items:center; flex-shrink:0; width:16px; height:16px; border:1px solid var(--subtle); border-radius:50%; color:var(--subtle); font-size:var(--text-xs); line-height:1; }
.analytics-kpi-period { display:block; margin-bottom:12px; color:var(--subtle); font-size:var(--text-sm); }
.analytics-kpi-value { display:flex; align-items:center; flex-wrap:wrap; gap:12px; margin-bottom:12px; }
.analytics-kpi-value strong { margin:0; font-size:var(--text-xxl); font-weight:500; line-height:1.2; }
.analytics-kpi-value .analytics-change { margin:0; padding:4px 9px; }
.analytics-kpi-footer { display:flex; align-items:center; gap:8px; padding:14px 24px; border-top:1px solid var(--line); background:var(--surface-2); color:var(--subtle); font-size:var(--text-xs); }
.analytics-kpi-footer svg { width:16px; height:16px; flex-shrink:0; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.analytics-kpi-footer strong { display:inline; margin:0 0 0 auto; color:var(--ink); font-size:var(--text-sm); font-weight:500; }
[data-theme="dark"] .analytics-metric .analytics-change.is-positive { color:#8bd5ad; }
[data-theme="dark"] .analytics-metric .analytics-change.is-negative { color:#f0a0a0; }
.analytics-card h3 { margin:0 0 8px; font-size:var(--text-md); font-weight:500; }
.analytics-card .directory-context { margin:0 0 24px; }
.analytics-category { display:grid; grid-template-columns:180px minmax(0,1fr) 50px; align-items:center; gap:16px; margin:14px 0; }
.analytics-category .intent-badge { width:max-content; }
.analytics-bar { height:8px; background:var(--surface-2); border-radius:4px; overflow:hidden; }
.analytics-bar span { display:block; height:100%; border-radius:4px; background:var(--brand-color); opacity:.65; }
.analytics-category-count { text-align:right; font-size:var(--text-xs); color:var(--muted); }
.intent-distribution-summary { display:flex; align-items:baseline; flex-wrap:wrap; gap:8px; margin:20px 0 14px; }
.intent-distribution-summary strong { font-size:var(--text-xl); font-weight:500; font-variant-numeric:tabular-nums; }
.intent-distribution-bar { display:flex; gap:2px; height:12px; margin-bottom:20px; border-radius:4px; }
.intent-distribution-segment { display:block; min-width:3px; transition:opacity .15s ease; }
.intent-distribution-segment:first-child { border-radius:4px 0 0 4px; }
.intent-distribution-segment:last-child { border-radius:0 4px 4px 0; }
.intent-distribution-segment:only-child { border-radius:4px; }
.intent-distribution-segment:hover { opacity:.75; }
.intent-distribution-legend { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:4px 24px; }
.intent-distribution-entry { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:8px 4px; border-radius:4px; font-size:var(--text-xs); }
.intent-distribution-entry:hover { background:var(--surface-1); }
.intent-distribution-label { display:flex; align-items:center; gap:8px; min-width:0; color:var(--muted); }
.intent-distribution-label > span:last-child { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.intent-distribution-swatch { width:8px; height:8px; flex-shrink:0; border-radius:2px; }
.intent-distribution-entry strong { font-weight:500; font-variant-numeric:tabular-nums; }
.intent-distribution-entry .intent-badge { min-width:0; max-width:calc(100% - 36px); }
.intent-distribution-entry .intent-badge > span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
@media(max-width:480px) { .intent-distribution-legend { grid-template-columns:1fr; } }
.analytics-direction-body { display:flex; align-items:center; justify-content:center; flex-wrap:wrap; gap:28px; padding:20px 0; }
.analytics-direction-donut { position:relative; width:180px; height:180px; flex-shrink:0; }
.analytics-direction-donut svg { display:block; width:100%; height:100%; }
.analytics-direction-donut circle { fill:none; stroke-width:22; }
.analytics-direction-outbound { stroke:var(--accent); }
.analytics-direction-inbound { stroke:color-mix(in srgb,var(--accent) 40%,var(--canvas)); }
.analytics-direction-center { position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:4px; pointer-events:none; }
.analytics-direction-center strong { font-size:var(--text-xxl); font-weight:500; }
.analytics-direction-center span { color:var(--subtle); font-size:var(--text-xs); }
.analytics-direction-legend { flex:1; min-width:190px; max-width:280px; }
.analytics-direction-legend-row { display:grid; grid-template-columns:1fr auto 42px; align-items:center; gap:12px; padding:14px 0; border-bottom:1px solid var(--line); font-variant-numeric:tabular-nums; }
.analytics-direction-legend-row:last-child { border-bottom:0; }
.analytics-direction-legend-row strong { font-size:var(--text-sm); font-weight:500; }
.analytics-direction-legend-row > span:last-child { text-align:right; }
.analytics-direction-label { display:flex; align-items:center; gap:8px; font-size:var(--text-sm); }
.analytics-direction-swatch { width:10px; height:10px; border-radius:3px; background:var(--accent); flex-shrink:0; }
.analytics-direction-swatch.inbound { background:color-mix(in srgb,var(--accent) 40%,var(--canvas)); }
.review-heatmap { display:grid; gap:6px; overflow-x:auto; padding:2px; }
.review-heatmap-row { display:grid; grid-template-columns:minmax(110px,1.7fr) repeat(4,minmax(48px,1fr)); align-items:center; gap:6px; min-width:360px; }
.review-heatmap-heading { margin-bottom:4px; color:var(--subtle); font-size:var(--text-xs); }
.review-heatmap-heading > span:not(:first-child) { text-align:center; }
.review-heatmap-label { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:var(--text-xs); color:var(--muted); }
.review-heatmap-cell { display:grid; place-items:center; min-height:36px; border-radius:6px; background:color-mix(in srgb,var(--accent) var(--heat-strength),var(--surface-1)); color:var(--ink); font-size:var(--text-xs); font-variant-numeric:tabular-nums; }
.review-heatmap-cell:hover { outline:1px solid var(--accent); outline-offset:-1px; }
.analytics-intent-link { padding:6px; margin-inline:-6px; border-radius:6px; text-decoration:none; }
.analytics-intent-link:hover { background:var(--surface-1); }
.wording-chart-item { padding:16px 0; border-top:1px solid var(--line); }
.wording-chart-item .ops-term-heading { align-items:baseline; margin-bottom:10px; }
.wording-chart-item h4 { margin:0; font-size:var(--text-sm); font-weight:500; }
.wording-chart-item .detainee-repeated-quote { margin:12px 0; font-size:var(--text-xs); line-height:18px; }
.wording-tag-cloud { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; align-content:center; gap:12px 8px; min-height:360px; padding:28px 8px; margin-bottom:16px; border-radius:8px; background:var(--surface-1); }
.wording-tag-cloud .wording-cloud-tag.ui-button { height:auto; min-height:36px; padding:6px 10px; font-size:var(--word-size); line-height:1.3; font-weight:500; color:var(--accent); white-space:normal; text-align:center; }
.wording-tag-cloud .wording-cloud-tag:nth-child(even) { color:var(--muted); }
.wording-tag-cloud .wording-cloud-tag[aria-expanded="true"] { background:var(--surface-2); color:var(--accent); }
.wording-tag-detail { padding:16px 0 0; border-top:1px solid var(--line); }
.wording-tag-detail h4 { margin:0; font-size:var(--text-sm); font-weight:500; }
.wording-tag-detail .detainee-repeated-quote { margin:12px 0; font-size:var(--text-xs); line-height:18px; }
.wording-source-list { max-height:340px; overflow-y:auto; overscroll-behavior:contain; padding-right:8px; scrollbar-width:thin; scrollbar-color:transparent transparent; }
.wording-tag-detail:hover .wording-source-list,.wording-tag-detail:focus-within .wording-source-list { scrollbar-color:var(--subtle) transparent; }
.wording-source-list::-webkit-scrollbar { width:8px; }
.wording-source-list::-webkit-scrollbar-thumb { border:2px solid transparent; border-radius:8px; background:transparent; background-clip:padding-box; }
.wording-tag-detail:hover .wording-source-list::-webkit-scrollbar-thumb,.wording-tag-detail:focus-within .wording-source-list::-webkit-scrollbar-thumb { background:var(--subtle); background-clip:padding-box; }
.wording-source-item { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:16px; padding:12px 0; border-top:1px solid var(--line); }
.wording-source-item .detainee-repeated-quote { margin:0; }
.wording-source-item .ops-source-links { margin:2px 0 0; }
.wording-matrix { display:flex; gap:12px; margin:24px 0 12px; }
.wording-matrix-priority { display:flex; flex-direction:column; justify-content:space-between; width:92px; flex-shrink:0; padding:12px 0 62px; font-size:var(--text-xs); line-height:18px; color:var(--subtle); }
.wording-matrix-chart { flex:1; min-width:0; overflow-x:auto; padding:0 4px; }
.wording-matrix-plot { position:relative; min-width:740px; height:440px; border-left:1px solid var(--line); border-bottom:1px solid var(--line); background:repeating-linear-gradient(to bottom,transparent 0,transparent calc(25% - 1px),var(--line) calc(25% - 1px),var(--line) 25%); }
.wording-matrix-plot .wording-bubble.ui-button { position:absolute; display:grid; place-items:center; width:var(--bubble-size); height:var(--bubble-size); min-height:0; padding:6px; white-space:normal; overflow-wrap:normal; text-align:center; border:1px solid color-mix(in srgb,var(--bubble-color) 60%,var(--canvas)); border-radius:50%; transform:translate(-50%,-50%); background:color-mix(in srgb,var(--bubble-color) 30%,var(--canvas)); color:var(--ink); font-size:var(--text-xs); line-height:18px; font-variant-numeric:tabular-nums; }
.wording-matrix-plot .wording-bubble:hover,.wording-matrix-plot .wording-bubble[aria-expanded="true"] { z-index:2; background:color-mix(in srgb,var(--bubble-color) 50%,var(--canvas)); border-color:var(--bubble-color); }
.wording-matrix-plot .wording-bubble[aria-pressed="true"] { outline:2px solid var(--bubble-color); outline-offset:2px; box-shadow:0 0 0 4px color-mix(in srgb,var(--bubble-color) 15%,transparent); }
.wording-matrix-horizontal { min-width:740px; display:flex; justify-content:space-between; padding:12px 0; font-size:var(--text-xs); color:var(--subtle); }
.wording-matrix-chart > p { text-align:center; margin:0; }
.wording-matrix-note { color:var(--subtle); font-size:var(--text-xs); line-height:18px; margin:12px 0 20px; }
#analytics-view .analytics-secondary-grid { grid-template-columns:minmax(0,5fr) minmax(0,7fr); }
@media(max-width:1000px) { #analytics-view .analytics-secondary-grid { grid-template-columns:1fr; } }
.review-heatmap-legend { display:flex; align-items:center; justify-content:flex-end; gap:5px; margin-top:12px; color:var(--subtle); font-size:var(--text-xs); }
.review-heatmap-legend > span:first-child { margin-right:4px; }
.review-heatmap-legend > span:last-child { margin-left:4px; }
.review-heatmap-swatch { width:14px; height:14px; border-radius:3px; background:color-mix(in srgb,var(--accent) var(--heat-strength),var(--surface-1)); }
.directory-footnote { margin:16px 0 0; color:var(--subtle); font-size:var(--text-xs); }
.ops-demo-notice { margin:0 0 16px; padding:10px 12px; background:var(--surface-1); border:1px solid var(--line); border-radius:6px; color:var(--subtle); font-size:var(--text-xs); line-height:18px; }
.ops-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
#analytics-view .analytics-main-grid { grid-template-columns:minmax(0,5fr) minmax(0,7fr); align-items:start; }
.analytics-chart-column { display:grid; align-content:start; gap:16px; min-width:0; }
#analytics-view .analytics-main-grid .review-heatmap-row { grid-template-columns:minmax(110px,1.5fr) repeat(4,minmax(44px,1fr)); }
@media(max-width:1000px) { #analytics-view .analytics-main-grid { grid-template-columns:1fr; } }
#analytics-view .analytics-overview-metrics { gap:12px; margin-bottom:16px; }
#analytics-view .analytics-kpi-body { padding:18px 20px; }
#analytics-view .analytics-kpi-heading { margin-bottom:14px; }
#analytics-view .analytics-kpi-value { flex-wrap:nowrap; margin-bottom:0; }
#analytics-view .queue-kpi-copy p { margin-top:6px; }
#analytics-view .analytics-kpi-footer { min-height:44px; padding:8px 20px; }
#analytics-view .analytics-primary-grid { grid-template-columns:minmax(0,7fr) minmax(0,5fr); }
#analytics-view .ops-grid > .analytics-card { min-width:0; }
#analytics-view .analytics-card .directory-context { margin-bottom:16px; }
#analytics-view .analytics-card-header { margin:-20px -20px 16px; padding:16px 20px; border-bottom:1px solid var(--line); }
#analytics-view .analytics-card-header h3 { margin:0; }
#analytics-view .analytics-kpi-heading { margin:-18px -20px 16px; padding:14px 20px; border-bottom:1px solid var(--line); }
#analytics-view .ops-governance[open] > summary { margin:-20px -20px 16px; padding:16px 20px; border-bottom:1px solid var(--line); }
#analytics-view .analytics-primary-grid .analytics-category { grid-template-columns:170px minmax(0,1fr) 40px; gap:12px; margin:6px 0; }
#analytics-view .analytics-direction-card { display:flex; flex-direction:column; }
#analytics-view .analytics-direction-body { flex:1; gap:20px; padding:12px 0; }
#analytics-view .analytics-direction-donut { width:200px; height:200px; }
#analytics-view .analytics-direction-legend { min-width:160px; }
#analytics-view .analytics-secondary-grid .review-heatmap-row { grid-template-columns:minmax(130px,1.6fr) repeat(4,minmax(48px,1fr)); }
#analytics-view .wording-chart-item { padding:12px 0; }
#analytics-view .wording-chart-item:last-child { padding-bottom:0; }
#analytics-view .analytics-detail-grid { align-items:start; }
#analytics-view .analytics-detail-grid .ops-item { padding:12px 0; }
#analytics-view .analytics-detail-grid .detainee-repeated-quote { margin:10px 0; padding:10px 12px; font-size:var(--text-xs); line-height:18px; }
@media(min-width:1600px) { #analytics-view .analytics-overview-metrics { grid-template-columns:repeat(6,minmax(0,1fr)); } #analytics-view .analytics-overview-metrics .queue-kpi-trend { width:80px; } }
@media(max-width:1100px) { #analytics-view .analytics-direction-body { flex-direction:column; } #analytics-view .analytics-direction-legend { width:100%; max-width:none; flex:0; } }
@media(max-width:800px) { #analytics-view .analytics-overview-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); } #analytics-view .analytics-primary-grid,#analytics-view .analytics-secondary-grid { grid-template-columns:1fr; } #analytics-view .analytics-direction-body { flex-direction:row; } }
@media(max-width:480px) { #analytics-view .analytics-overview-metrics { grid-template-columns:1fr; } #analytics-view .analytics-primary-grid .analytics-category { grid-template-columns:140px minmax(0,1fr) 34px; gap:8px; } }
#analytics-view > .analytics-card,.ops-grid { margin-bottom:16px; }
.ops-status-row { display:flex; align-items:center; justify-content:space-between; gap:16px; min-height:36px; font-size:var(--text-sm); }
.ops-status-row strong { font-size:var(--text-sm); font-weight:500; font-variant-numeric:tabular-nums; }
.ops-subheading { margin:24px 0 12px; font-size:var(--text-sm); font-weight:500; }
.ops-item { padding:14px 0; border-top:1px solid var(--line); }
.ops-item h4 { margin:0 0 8px; font-size:var(--text-sm); font-weight:500; }
.ops-item p { margin:8px 0; font-size:var(--text-xs); line-height:18px; color:var(--subtle); }
.ops-item > .directory-muted { display:block; margin-top:8px; }
.ops-source-links { display:flex; flex-wrap:wrap; align-items:center; gap:12px; margin-top:10px; }
.ops-term-heading,.ops-term-actions { display:flex; flex-wrap:wrap; align-items:center; gap:12px; }
.ops-term-heading h4 { margin:0; }
.ops-term-actions { margin-top:12px; }
.ops-governance summary { font-size:var(--text-md); font-weight:500; cursor:pointer; }
.ops-governance[open] summary { margin-bottom:20px; }
@media(max-width:800px) { .ops-grid { grid-template-columns:1fr; } }
.call-traffic-card { margin-bottom:16px; }
.call-traffic-chart { display:grid; grid-template-columns:repeat(14,minmax(0,1fr)); align-items:end; gap:8px; min-height:190px; padding:12px 0 0; border-bottom:1px solid var(--line); }
.call-traffic-day { display:flex; flex-direction:column; align-items:center; justify-content:flex-end; gap:8px; height:176px; min-width:0; }
.call-traffic-bar { display:block; width:min(100%,32px); min-height:0; border-radius:4px 4px 0 0; background:var(--brand-color); opacity:.72; }
.call-traffic-bar[data-value="0"] { background:var(--surface-3); opacity:1; }
.call-traffic-label { color:var(--subtle); font-size:var(--text-xs); white-space:nowrap; }
.call-leaderboards { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-bottom:16px; }
.call-leaderboard { padding:16px; }
.call-leaderboard h3 { margin-bottom:12px; }
.call-leaderboard-row { display:grid; grid-template-columns:24px minmax(0,1fr) auto; align-items:center; gap:10px; min-height:40px; border-top:1px solid var(--line); color:var(--ink); text-decoration:none; }
.call-leaderboard-row:hover { color:var(--brand-color); }
.call-leaderboard-row strong { font-size:var(--text-xs); font-weight:500; white-space:nowrap; }
.queue-expand { display:inline-flex; align-items:center; justify-content:center; width:28px; height:32px; padding:0; margin-left:-4px; border:0; border-radius:6px; background:transparent; color:var(--subtle); cursor:pointer; vertical-align:middle; }
.queue-expand:hover { background:var(--surface-2); color:var(--ink); }
.queue-expand svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.5; transition:transform .22s ease; }
.queue-expand[aria-expanded="true"] svg { transform:rotate(180deg); }
.calls-table.is-review-queue :is(th,td).queue-expand-column { width:32px; padding:0 4px; text-align:center; }
.calls-table.is-review-queue .queue-expand { width:24px; margin:0; }
.calls-table.is-review-queue :is(th,td).call-play-column { padding-left:24px; }
.calls-table-with-details.is-review-queue :is(th,td).call-play-column { padding-left:12px; }
.calls-table tbody tr[aria-expanded="true"] { background:var(--canvas); }
.calls-table tbody .queue-reason-row > td { height:0; padding:0 !important; border:0; }
.calls-table tbody .queue-reason-row:hover { background:transparent; cursor:default; }
.queue-reason-collapse { display:grid; grid-template-rows:0fr; opacity:0; transition:grid-template-rows .24s ease,opacity .2s ease; }
.queue-reason-collapse.is-expanded { grid-template-rows:1fr; opacity:1; }
.queue-reason-clip { min-height:0; overflow:hidden; }
.queue-reason-panel { margin:0; padding:16px 24px; border:0; border-bottom:1px solid var(--line); border-radius:0; background:var(--surface-2); white-space:normal; }
.queue-reason-panel h3 { margin:0 0 12px; font-size:var(--text-sm); font-weight:500; }
.queue-reason-item { display:flex; align-items:flex-start; gap:14px; padding:14px 0; border-top:1px solid var(--line); }
.queue-reason-item > div { flex:1; min-width:0; }
.queue-reason-item p { margin:8px 0 0; color:var(--subtle); font-size:var(--text-sm); line-height:1.5; }
.queue-reason-arrow { color:var(--subtle); font-size:var(--text-md); }
.queue-reason-status { flex-shrink:0; color:var(--subtle); font-size:var(--text-xs); padding-top:4px; }
@media(max-width:640px) { .queue-reason-item { flex-wrap:wrap; } .queue-reason-status { margin-left:30px; } .queue-reason-panel { margin:0; padding:12px; } }
@media(prefers-reduced-motion:reduce) { .queue-reason-collapse,.queue-expand svg { transition:none; } }
.call-leaderboard-rank { color:var(--subtle); font-variant-numeric:tabular-nums; }
.call-leaderboard-main { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:var(--text-sm); }
.analytics-leaderboard-table { width:100%; }
.analytics-leaderboard-table th,.analytics-leaderboard-table td { padding:10px 12px; vertical-align:middle; }
.analytics-leaderboard-table th:nth-child(n+3),.analytics-leaderboard-table .leaderboard-number { text-align:right; white-space:nowrap; font-variant-numeric:tabular-nums; }
.analytics-leaderboard-table .leaderboard-person { display:flex; flex-direction:column; gap:3px; }
.analytics-leaderboard-table .leaderboard-person strong { font-size:var(--text-sm); }
.analytics-leaderboard-table .leaderboard-total { font-weight:600; color:var(--ink); }
.analytics-leaderboard-table .directory-identity:hover { color:var(--accent); }
@media(max-width:800px) { .directory-page { padding:0 12px 20px; } #detainee-record-view { --profile-gutter:12px; } .directory-toolbar { flex-wrap:wrap; } .analytics-metrics { grid-template-columns:1fr; } #detainee-panel-insights .analytics-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); } .analytics-category { grid-template-columns:140px minmax(0,1fr) 36px; gap:8px; } .detainee-insight-grid { grid-template-columns:1fr; } }
@media(max-width:480px) { #detainee-panel-insights .analytics-metrics { grid-template-columns:1fr; } }
@media(max-width:640px) { .call-traffic-chart { gap:3px; } .call-traffic-label { font-size:calc(12px * var(--font-scale,1)); writing-mode:vertical-rl; transform:rotate(180deg); } .call-leaderboards { grid-template-columns:1fr; } }

.queue-priority,.queue-review-status{display:inline-flex;align-items:center;gap:6px;font-size:var(--text-xs);line-height:1.5;white-space:normal}.queue-priority-dot,.queue-status-dot{width:6px;height:6px;border-radius:50%;background:currentColor;flex-shrink:0}.queue-priority-high{color:#9b343b}.queue-priority-medium{color:#8a5b00}.queue-priority-low{color:var(--subtle)}.queue-review-status{color:var(--muted)}.queue-status-open .queue-status-dot{background:var(--accent)}.queue-status-in-review .queue-status-dot{background:#a97a22}.queue-status-escalated .queue-status-dot{background:#b45c33}.queue-status-closed .queue-status-dot{background:#49886a}[data-theme=dark] .queue-priority-high{color:#efafb6}[data-theme=dark] .queue-priority-medium{color:#ddbb77}:root[data-high-contrast=true] .queue-priority{color:var(--ink)}

.calls-table.is-review-queue .call-play-button{padding-inline:4px}

.review-queue-controls{display:flex;align-items:center;flex-wrap:wrap;gap:12px}.queue-priority-filter{position:relative}.queue-priority-trigger.ui-button{min-height:36px;gap:10px}.queue-priority-options{position:absolute;top:calc(100% + 6px);left:0;min-width:180px;padding:4px;border:1px solid var(--line);border-radius:8px;box-shadow:0 4px 16px rgb(0 0 0 / .1);background:var(--canvas);z-index:40}.queue-priority-options .ui-button{display:flex;width:100%;justify-content:flex-start}.queue-priority-options [aria-selected=true]{background:var(--surface-3)}.queue-priority{display:inline-flex;align-items:center;gap:5px;padding:3px 6px;border-radius:4px;font-size:var(--text-xs);font-weight:500;text-transform:uppercase;line-height:18px;white-space:nowrap}.queue-priority svg{width:14px;height:14px;flex-shrink:0;fill:currentColor}.queue-priority-high{color:#a52c37;background:#fce4e7}.queue-priority-medium{color:#915c10;background:#fff1d6}.queue-priority-low{color:#526481;background:#edf2f8}[data-theme=dark] .queue-priority-high{color:#f3a5af;background:#48232b}[data-theme=dark] .queue-priority-medium{color:#e8c07a;background:#3c3019}[data-theme=dark] .queue-priority-low{color:#c1cde3;background:#293346}:root[data-high-contrast=true] .queue-priority{color:#101114;background:#ffdf00}

.call-duration-value{display:inline-flex;align-items:center;gap:4px;vertical-align:middle;white-space:nowrap}.call-duration-value svg{width:14px;height:14px;flex-shrink:0;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.queue-review-status{padding:3px 6px;border-radius:4px;font-weight:500;line-height:18px}.queue-status-open{color:#4455a7;background:#edf2ff}.queue-status-in-review{color:#895b12;background:#fff1d6}.queue-status-escalated{color:#a3482b;background:#fbe9e4}.queue-status-closed{color:#52616b;background:#edf0f2}.queue-review-status .queue-status-dot{background:currentColor}[data-theme=dark] .queue-status-open{color:#bdc9ff;background:#25314a}[data-theme=dark] .queue-status-in-review{color:#e8c07a;background:#3c3019}[data-theme=dark] .queue-status-escalated{color:#edb3a0;background:#442a25}[data-theme=dark] .queue-status-closed{color:#c4cbd1;background:#2c3338}:root[data-high-contrast=true] .queue-review-status{color:#101114;background:#ffdf00}

.queue-priority-trigger.ui-button>.queue-priority-chevron{width:14px;height:14px;flex-shrink:0;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;transition:transform 140ms ease}.queue-priority-trigger[aria-expanded=true]>.queue-priority-chevron{transform:rotate(180deg)}@media(prefers-reduced-motion:reduce){.queue-priority-chevron{transition:none}}

.queue-status-to-review{color:#6653a6;background:#f0ebff}
[data-theme="dark"] .queue-status-to-review{color:#d1c1fa;background:#34294b}
:root[data-high-contrast=true] .queue-status-to-review{color:#101114;background:#ffdf00}
.record-review-status{flex-shrink:0;margin-right:8px}

.call-review-controls{display:flex;align-items:center;gap:8px}
.call-review-trigger.ui-button{gap:8px;white-space:nowrap}
.call-review-trigger > svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;transition:transform 140ms ease}
.call-review-trigger[aria-expanded=true] > svg{transform:rotate(180deg)}
.call-review-assignee{display:flex;align-items:center;gap:6px;min-width:0}
.call-review-assignee .assignee-avatar{width:20px;height:20px;font-size:var(--text-xs)}
.call-review-menu{position:fixed;z-index:100;padding:4px;border:1px solid var(--floating-border,var(--line));border-radius:8px;background:var(--elevated-surface,var(--canvas));box-shadow:var(--floating-shadow,0 4px 16px #00000014);overflow:auto;scrollbar-width:thin;scrollbar-color:transparent transparent}
.call-review-menu[hidden]{display:none}
.call-review-menu:hover,.call-review-menu:focus-within{scrollbar-color:var(--subtle) transparent}
.call-review-menu::-webkit-scrollbar{width:6px}.call-review-menu::-webkit-scrollbar-thumb{border-radius:6px;background:transparent}.call-review-menu:hover::-webkit-scrollbar-thumb,.call-review-menu:focus-within::-webkit-scrollbar-thumb{background:var(--subtle)}
.call-review-menu > input{box-sizing:border-box;width:100%;height:36px;padding:8px;border:0;border-bottom:1px solid var(--line);background:transparent;color:var(--ink);font:inherit;font-size:var(--text-xs);margin-bottom:4px}
.call-review-menu .call-review-options > .ui-button{width:100%;justify-content:space-between;gap:12px;padding:6px 8px;min-height:36px;height:auto;text-align:left}
.call-review-menu [aria-selected=true]{background:var(--surface-2)}
.call-review-menu .directory-muted{padding:8px}
@media(max-width:800px){.record-view-toolbar{flex-wrap:wrap}.record-view-toolbar .record-header-actions{flex-wrap:wrap}.call-review-assignee > span:last-child{max-width:120px;overflow:hidden;text-overflow:ellipsis}}
@media(prefers-reduced-motion:reduce){.call-review-trigger > svg{transition:none}}

.assigned-filter{flex-shrink:0}.assigned-filter[hidden]{display:none}
.assigned-filter-trigger.ui-button{gap:10px;min-height:36px}
.assigned-filter-trigger.has-filter{border-color:var(--accent)}
.assigned-filter-trigger > svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;transition:transform 140ms ease}
.assigned-filter-trigger[aria-expanded=true] > svg{transform:rotate(180deg)}
@media(prefers-reduced-motion:reduce){.assigned-filter-trigger > svg{transition:none}}
