:root{--shadow:none;--radius:12px;font:16px/1.5 system-ui,-apple-system,"Segoe UI",sans-serif}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text)}a{color:var(--text);text-decoration:none}a:hover{text-decoration:underline}button,input,select{font:inherit}button,a.secondary,.file{min-height:44px;border-radius:10px;padding:10px 16px;display:inline-flex;align-items:center;justify-content:center;gap:8px}button{background:var(--brand);color:var(--on-brand);border:1px solid var(--brand);cursor:pointer}button.secondary,a.secondary{background:var(--surface);border:1px solid var(--line);color:var(--text)}:focus-visible{outline:1px solid var(--focus);outline-offset:-1px}.topbar{padding:18px max(20px,calc((100vw - 1400px)/2));display:flex;align-items:center;justify-content:space-between;background:var(--surface);border-bottom:1px solid var(--line);gap:16px}.brand{font-size:26px;font-weight:750;letter-spacing:-.7px}.brand span{display:block;font-size:12px;letter-spacing:.05em;color:var(--muted);font-weight:600}main{max-width:1440px;padding:32px 20px;margin:auto}.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.login{max-width:480px;margin:clamp(20px,8vh,90px) auto;padding:clamp(24px,5vw,40px)}h1{font-size:clamp(25px,3vw,34px);line-height:1.2;margin:10px 0 18px}p{color:var(--muted)}.eyebrow{font-size:12px;font-weight:750;letter-spacing:.08em;margin:0;color:var(--text)}label{display:block;margin:14px 0 6px;font-weight:650}input,select{width:100%;min-width:0;min-height:46px;border:1px solid var(--line);border-radius:10px;background:var(--input);color:var(--text);padding:10px 12px}.login button{width:100%;margin-top:24px}.notice{padding:12px;border-radius:10px}.error{background:#ffeded;color:#942323}.heading{display:flex;justify-content:space-between;align-items:center;gap:20px;flex-wrap:wrap}.search{display:flex;align-items:end;gap:16px;padding:18px;flex-wrap:wrap}.search label{margin-top:0}.search>div:first-child{width:190px}.grow{flex:1;min-width:200px}.result-status{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap;margin:24px 0 12px;color:var(--muted)}.table-wrap{overflow:hidden}table{border-collapse:collapse;width:100%;table-layout:auto}th,td{text-align:left;padding:16px;border-bottom:1px solid var(--line);vertical-align:middle;overflow-wrap:anywhere}th{font-size:13px;color:var(--muted);background:var(--bg)}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:var(--bg)}small{display:block;color:var(--muted);font-weight:400}.unread td{font-weight:650}.files{display:flex;gap:8px;flex-wrap:wrap;min-width:150px}.file{background:var(--bg);font-size:13px;padding:8px 10px}.badge{background:var(--bg);color:var(--muted);border-radius:8px;padding:6px 9px;font-size:13px}.pagination{display:flex;gap:8px;flex-wrap:wrap;margin-top:20px}.pagination a{padding:8px 14px;background:var(--surface);border:1px solid var(--line);border-radius:8px}.pagination a[aria-current]{background:var(--brand);color:var(--on-brand)}footer{text-align:center;color:var(--muted);font-size:12px;margin:30px 20px}html[data-mode=dark] button:not(.secondary){color:var(--on-brand)}@media(max-width:800px){main{padding:22px 14px}.topbar{padding:14px}.search>div,.search>div:first-child{width:100%;flex-basis:100%}.search button,.search a{flex:1}.table-wrap{background:transparent;border:0;box-shadow:none}table,tbody,tr,td{display:block;width:100%}thead{display:none}tbody tr{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:10px;margin-bottom:12px}td{display:grid;grid-template-columns:minmax(90px,30%) minmax(0,1fr);gap:10px;padding:10px 6px}td:before{content:attr(data-label);font-weight:500;color:var(--muted);font-size:13px}.files{min-width:0}small{grid-column:2}.heading .secondary{margin-bottom:16px}}@media(prefers-reduced-motion:no-preference){button,a{transition:background .15s ease,color .15s ease}}@media print{.topbar,.search,.pagination,footer{display:none}main{max-width:none;padding:0}.card{box-shadow:none}a{color:inherit}}

/* Laboratory identity uses intrinsic wrapping, never a fixed viewport height. */
body{min-height:100vh;min-height:100svh;display:flex;flex-direction:column}
main{width:100%;flex:1;min-width:0}
.topbar .brand{min-width:0;overflow-wrap:anywhere;font-size:clamp(1.125rem,2.4vw,1.625rem);line-height:1.3;letter-spacing:-.02em}
.topbar .brand span{margin-top:4px;letter-spacing:.03em}
/* Header controls wrap as intrinsic groups, preserving native keyboard interaction. */
.topbar{flex-wrap:wrap}
.portal-controls{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:10px;max-width:100%;margin-left:auto}
.theme-options,.language-options{display:flex;align-items:center;flex-wrap:wrap;gap:6px;min-width:0}
.theme-options button,.language-options a{min-height:44px;min-width:44px;padding:8px 12px;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--text);line-height:1.35;text-align:center;text-decoration:none}
.language-options a{display:inline-flex;align-items:center;justify-content:center}
.theme-options button[aria-pressed=true],.language-options a[aria-current]{background:var(--brand);border-color:var(--text);color:var(--on-brand);font-weight:650}
html[data-mode=dark] .theme-options button,html[data-mode=dark] .language-options a{color:var(--text)}
html[data-mode=dark] .theme-options button[aria-pressed=true],html[data-mode=dark] .language-options a[aria-current]{color:var(--on-brand)}
@media(max-width:520px){.portal-controls{width:100%;justify-content:flex-start;margin-left:0}.topbar{gap:12px}.theme-options button,.language-options a{padding:8px 10px}}

.login{width:100%;margin:clamp(12px,6vh,64px) auto}
.laboratory-footer{width:min(100% - 28px,960px);margin:20px auto 24px;padding:18px 12px;border-top:1px solid var(--line);font-size:.875rem;overflow-wrap:anywhere}
.footer-identity{font-weight:650;color:var(--text)}
.laboratory-contact{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:8px 24px;margin:12px 0;font-style:normal}
.laboratory-contact a{display:inline-block;max-width:100%;padding:8px 0;text-decoration:underline;text-underline-offset:3px}
.laboratory-address{flex-basis:100%;white-space:pre-line}
.skip-link{position:absolute;left:16px;top:-120px;padding:10px 16px;background:var(--surface);border:1px solid var(--line);z-index:10}
.skip-link:focus{top:12px}
@media(max-width:360px){.topbar{gap:10px}.login{padding:20px}.laboratory-contact{flex-direction:column;gap:4px}}
@media print{.laboratory-footer{display:none}}
/* Authenticated workspace enhancement: no document scroll when the minimum controls fit. */
body.report-workspace.workspace-enhanced{height:100vh;height:100dvh;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr);overflow:hidden}
.report-workspace.workspace-enhanced>.topbar{padding:6px 14px;flex-wrap:nowrap;gap:12px;min-height:56px}
.report-workspace.workspace-enhanced>.topbar .brand{flex:1;min-width:0;font-size:1rem;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;line-height:1.25}
.report-workspace.workspace-enhanced>.topbar .brand span{display:none}
.report-workspace.workspace-enhanced>.topbar>button{flex-shrink:0;max-width:45%;min-height:44px;padding:6px 10px;font-size:.875rem}
.report-workspace.workspace-enhanced>main{width:100%;max-width:1600px;min-height:0;height:100%;margin:0 auto;padding:8px 14px;display:grid;grid-template-rows:auto auto minmax(0,1fr);gap:8px}
.report-workspace.workspace-enhanced .heading{gap:8px;flex-wrap:nowrap;min-width:0}
.report-workspace.workspace-enhanced .heading>div{min-width:0;flex:1}
.report-workspace.workspace-enhanced .heading .eyebrow{display:none}
.report-workspace.workspace-enhanced .heading h1{font-size:1rem;margin:0;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;line-height:1.4}
.report-workspace.workspace-enhanced .heading>.secondary,.report-workspace.workspace-enhanced .heading>button{min-height:44px;padding:6px 10px;font-size:.875rem;margin:0;flex-shrink:0}
.report-workspace.workspace-enhanced .result-status{margin:0;gap:4px 12px;font-size:.8rem;min-width:0}
.report-workspace.workspace-enhanced #live-status{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.report-workspace.workspace-enhanced #report-results{min-height:0;display:grid;grid-template-rows:minmax(0,1fr) auto;gap:6px}
.report-workspace.workspace-enhanced .table-wrap{min-height:0;border:1px solid var(--line);background:var(--surface);border-radius:10px;box-shadow:none;overflow:visible}
.report-workspace.workspace-enhanced table,.report-workspace.workspace-enhanced tbody{display:table;width:100%;table-layout:fixed}
.report-workspace.workspace-enhanced tbody{display:table-row-group}
.report-workspace.workspace-enhanced thead,.report-workspace.workspace-enhanced .report-original{display:none}
.report-workspace.workspace-enhanced tbody tr{display:table-row;border:0;border-radius:0;padding:0;margin:0;background:var(--surface)}
.report-workspace.workspace-enhanced td.report-summary{display:table-cell;padding:6px 10px;height:72px;border-bottom:1px solid var(--line);width:100%}
.report-workspace.workspace-enhanced td.report-summary:before{display:none}
.report-summary-content{display:flex;align-items:center;gap:12px;height:59px;min-width:0}
.report-summary-identity{display:flex;flex-direction:column;min-width:0;flex:1;line-height:1.4}
.report-summary-identity strong,.report-summary-identity span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.report-summary-identity strong{font-size:.875rem;color:var(--text)}
.report-summary-identity span{font-size:.95rem}
.report-summary-dates{font-size:.75rem;min-width:105px;flex-shrink:0}
.report-summary-files{display:flex;flex-wrap:nowrap;gap:6px;min-width:0;flex-shrink:0}
.report-summary-content>button{min-height:44px;padding:6px 10px;font-size:.875rem;flex-shrink:0}
.report-workspace.workspace-enhanced .pagination{display:flex;align-items:center;justify-content:center;gap:4px;margin:0;flex-wrap:wrap;font-size:.8rem}
.report-workspace.workspace-enhanced .pagination a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;min-width:44px;padding:4px 8px;border-width:1px}
.report-workspace.workspace-enhanced .pagination [aria-current]{padding:4px 6px}
.report-workspace.workspace-enhanced .page-history{display:flex;align-items:center;gap:8px;flex:1 0 100%;min-width:0}
.report-workspace.workspace-enhanced #report-page-slider{min-height:28px;height:28px;padding:0;flex:1;min-width:50px;cursor:pointer}
.report-workspace.workspace-enhanced #report-page-help{font-size:.75rem;white-space:nowrap;flex-shrink:0}
.workspace-dialog{background:var(--surface);color:var(--text);border:1px solid var(--line);border-radius:12px;padding:16px;width:min(94vw,760px);max-width:94vw;max-height:calc(100dvh - 24px);overflow:auto}
.workspace-dialog::backdrop{background:#0009}
.workspace-dialog h2{font-size:1.1rem;margin:0 0 12px;overflow-wrap:anywhere}
.workspace-dialog .search{margin:0;padding:0;border:0;box-shadow:none}
.workspace-dialog .portal-controls{justify-content:flex-start;margin:0}
.workspace-dialog .laboratory-footer{width:100%;margin:12px 0;padding:12px 0}
.workspace-dialog-close{display:flex;justify-content:flex-end;margin-top:12px}
.workspace-dialog-close button{min-height:44px}
.workspace-case-detail{margin:0;overflow-wrap:anywhere}
.workspace-case-detail dt{font-weight:650;color:var(--muted);margin-top:10px}
.workspace-case-detail dd{margin:3px 0 0;white-space:pre-wrap}
@media(max-width:1199px){.report-summary-files{display:none}}
@media(max-width:600px){.report-workspace.workspace-enhanced>.topbar{padding:6px 10px}.report-workspace.workspace-enhanced>main{padding:6px 10px;gap:6px}.report-summary-dates{display:none}.report-summary-content{gap:8px}.report-workspace.workspace-enhanced td.report-summary{padding:6px}.report-workspace.workspace-enhanced .result-status{font-size:.75rem}.report-workspace.workspace-enhanced #live-status{max-width:55%}}
/* Accessibility escape hatch: geometry cannot trump access at physically impossible zoom/viewports. */
body.report-workspace.workspace-enhanced.workspace-viewport-small{height:auto;min-height:100dvh;overflow:auto}
.report-workspace.workspace-enhanced.workspace-viewport-small>main{height:auto;grid-template-rows:auto auto auto}
.report-workspace.workspace-enhanced.workspace-viewport-small #report-results{grid-template-rows:minmax(72px,auto) auto}
@media print{body.report-workspace.workspace-enhanced{height:auto;display:block;overflow:visible}.report-workspace.workspace-enhanced>main{display:block}.report-workspace.workspace-enhanced .report-original{display:table-cell}.report-workspace.workspace-enhanced td.report-summary,.workspace-dialog{display:none}}

.report-workspace.workspace-enhanced .page-history{position:relative}
.report-workspace.workspace-enhanced .page-history label{margin:0;font-size:.75rem;font-weight:500;flex-shrink:0}
.report-workspace.workspace-enhanced #report-page-help{display:none;position:absolute;bottom:100%;left:0;z-index:3;white-space:normal;max-width:min(80vw,420px);padding:8px 10px;background:var(--surface);color:var(--text);border:1px solid var(--line);border-radius:8px;box-shadow:var(--shadow)}
.report-workspace.workspace-enhanced .page-history:hover #report-page-help,.report-workspace.workspace-enhanced .page-history:focus-within #report-page-help{display:block}

/* Mobile users retain natural touch/wheel scrolling inside the list, with pagination fixed below it. */
@media(max-width:800px){.report-workspace.workspace-enhanced .table-wrap{overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;touch-action:pan-y;scrollbar-gutter:stable}.report-workspace.workspace-enhanced .pagination{gap:4px}.report-workspace.workspace-enhanced .pagination a{font-size:.75rem;padding:4px 6px}.report-workspace.workspace-enhanced .page-position{font-size:.75rem;white-space:nowrap}}

.report-workspace.workspace-enhanced #report-size-form{display:none}
@media(max-width:800px){.report-workspace.workspace-enhanced #report-size-form{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;margin:0}.report-workspace.workspace-enhanced #report-size-form label{margin:0;font-size:.75rem}.report-workspace.workspace-enhanced #report-page-size{width:auto;min-height:38px;padding:4px 8px;font-size:.8rem}}

.report-workspace.workspace-enhanced tbody tr:not([data-workspace-row]) td{display:table-cell;padding:16px;height:72px;overflow-wrap:anywhere}
.report-workspace.workspace-enhanced tbody tr:not([data-workspace-row]) td:before{display:none}

/* Theme and language choices remain directly visible, including in the compact workspace. */
.report-workspace.workspace-enhanced>.topbar{flex-wrap:wrap}
.report-workspace.workspace-enhanced>.topbar .portal-controls{width:auto;flex-shrink:0;max-width:100%;margin-left:auto;gap:8px}
.report-workspace.workspace-enhanced>.topbar .workspace-contact-trigger{min-width:44px;min-height:44px;padding:6px;font-size:1.15rem}
@media(max-width:800px){.report-workspace.workspace-enhanced>.topbar{gap:6px}.report-workspace.workspace-enhanced>.topbar .brand{flex-basis:100%}.report-workspace.workspace-enhanced>.topbar .portal-controls{width:100%;margin:0;justify-content:flex-start;flex-wrap:nowrap;gap:8px}.report-workspace.workspace-enhanced>.topbar .theme-options,.report-workspace.workspace-enhanced>.topbar .language-options{flex-wrap:nowrap;gap:4px}.report-workspace.workspace-enhanced>.topbar .theme-options button,.report-workspace.workspace-enhanced>.topbar .language-options a{padding:6px 8px}}

/* Pagination guidance is available on hover and keyboard focus without moving results. */
.report-workspace.workspace-enhanced .pagination{position:relative}
.report-workspace.workspace-enhanced #report-nav-help{display:none;position:absolute;bottom:100%;left:0;z-index:4;max-width:min(90vw,480px);margin:0;padding:8px 10px;background:var(--surface);color:var(--text);border:1px solid var(--line);border-radius:8px;box-shadow:var(--shadow);font-size:.8rem;white-space:normal;text-align:left}
.report-workspace.workspace-enhanced .pagination [data-report-nav]:hover~#report-nav-help,.report-workspace.workspace-enhanced .pagination [data-report-nav]:focus~#report-nav-help{display:block}
/* Worklist search remains an inline native form; logout is the final right-hand action. */
.report-workspace.workspace-enhanced .workspace-heading-identity{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.report-workspace.workspace-enhanced>.topbar .brand .workspace-institution-caption{display:block;margin-top:2px;font-size:.75rem;line-height:1.25;font-weight:500;letter-spacing:0;color:var(--muted)}
.report-workspace.workspace-enhanced .heading{align-items:center}
.report-workspace.workspace-enhanced .workspace-inline-search{display:flex;flex:1;min-width:0;align-items:center;gap:6px;flex-wrap:nowrap;padding:0;margin:0;background:transparent;border:0;box-shadow:none}
.report-workspace.workspace-enhanced .workspace-inline-search label{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.report-workspace.workspace-enhanced .workspace-inline-search>div:first-of-type{flex:0 0 110px;width:110px;min-width:0}
.report-workspace.workspace-enhanced .workspace-inline-search .grow{flex:1;min-width:0;width:auto}
.report-workspace.workspace-enhanced .workspace-inline-search input:not([type=hidden]),.report-workspace.workspace-enhanced .workspace-inline-search select{min-height:44px;height:44px;padding:6px 8px;font-size:.875rem}
.report-workspace.workspace-enhanced .workspace-inline-search>button,.report-workspace.workspace-enhanced .workspace-inline-search>a{flex:0 0 auto;min-height:44px;margin:0;padding:6px 10px;font-size:.875rem}
.report-workspace.workspace-enhanced .workspace-inline-search>a{min-width:44px;font-size:1.25rem;padding:6px}
@media(max-width:480px){.report-workspace.workspace-enhanced .heading{align-items:flex-start;gap:6px}.report-workspace.workspace-enhanced .workspace-inline-search{display:grid;grid-template-columns:70px minmax(0,1fr);gap:4px}.report-workspace.workspace-enhanced .workspace-inline-search>div:first-of-type{width:70px}.report-workspace.workspace-enhanced .workspace-inline-search .grow{width:100%}.report-workspace.workspace-enhanced .workspace-inline-search>button{grid-column:1}.report-workspace.workspace-enhanced .workspace-inline-search>a{grid-column:2;justify-self:end;width:44px}.report-workspace.workspace-enhanced .heading>a.secondary{padding:6px;font-size:.75rem}}
/* Desktop restores semantic aligned columns; complete unclamped contents remain in Details. */
@media(min-width:801px){
 .report-workspace.workspace-enhanced thead{display:table-header-group}
 .report-workspace.workspace-enhanced th{padding:7px 8px;font-size:.8125rem;line-height:1.35;border-bottom:1px solid var(--line);vertical-align:middle}
 .report-workspace.workspace-enhanced th:nth-child(1),.report-workspace.workspace-enhanced td.report-original:nth-child(1){width:14%}
 .report-workspace.workspace-enhanced th:nth-child(2),.report-workspace.workspace-enhanced td.report-original:nth-child(2){width:21%}
 .report-workspace.workspace-enhanced th:nth-child(3),.report-workspace.workspace-enhanced td.report-original:nth-child(3){width:13%}
 .report-workspace.workspace-enhanced th:nth-child(5),.report-workspace.workspace-enhanced td.report-original:nth-child(5){width:300px}
 .report-workspace.workspace-enhanced td.report-summary{display:none}
 .report-workspace.workspace-enhanced td.report-original{display:table-cell;height:72px;padding:5px 6px;vertical-align:middle;font-size:.9375rem;border-bottom:1px solid var(--line)}
 .report-workspace.workspace-enhanced td.report-original .workspace-cell-content{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;overflow-wrap:anywhere;line-height:1.4;max-height:2.8em}
 .report-workspace.workspace-enhanced td.report-original small{font-size:.8125rem}
 .report-workspace.workspace-enhanced .report-original .workspace-report-actions{display:grid;grid-template-columns:182px minmax(0,1fr);grid-template-rows:44px;gap:2px 6px;align-items:center;min-width:0}
 .report-workspace.workspace-enhanced .report-original .files{grid-column:1;grid-row:1;display:grid;grid-template-columns:repeat(4,44px);gap:2px;min-width:0;flex-wrap:nowrap}
 .report-workspace.workspace-enhanced .report-original .report-file-slot{display:block;width:44px;height:44px;min-width:0}
 .report-workspace.workspace-enhanced .report-original .report-file-slot .file{display:flex;width:44px;height:44px;min-height:44px;min-width:0;padding:4px 2px;font-size:.75rem;line-height:1.15;overflow-wrap:anywhere;text-align:center}
 .report-workspace.workspace-enhanced .report-original .workspace-row-detail{grid-column:2;grid-row:1;min-width:0;min-height:44px;padding:5px 6px;font-size:.8125rem;align-self:center;justify-self:stretch}
 .report-workspace.workspace-enhanced .report-original .report-pending-status{grid-column:1;grid-row:1;padding:6px 8px;margin:0;background:var(--input);font-size:.875rem;font-weight:650;line-height:1.35;white-space:normal;text-align:center;color:var(--text);z-index:1}
}

/* Short mobile landscape keeps the first whole summary and its native action visible. */
@media(max-width:800px) and (max-height:440px){.report-workspace.workspace-enhanced td.report-summary{height:48px;padding:1px 6px}.report-workspace.workspace-enhanced .report-summary-content{height:45px;gap:8px}.report-workspace.workspace-enhanced .report-summary-identity{line-height:1.25}.report-workspace.workspace-enhanced .report-summary-identity strong{font-size:.75rem}.report-workspace.workspace-enhanced .report-summary-identity span{font-size:.8rem}.report-workspace.workspace-enhanced .report-summary-dates{font-size:.7rem}}

/* Canonical Lazarus builtin roles; no additional decorative colors. */
:root,html[data-theme="system.dark"]{color-scheme:dark;--bg:#282828;--surface:#282828;--input:#1d2021;--text:#ebdbb2;--muted:#ebdbb2;--line:#928374;--brand:#504945;--on-brand:#ebdbb2;--selection:#665c54;--focus:#ebdbb2;}
html[data-theme="system.light"]{color-scheme:light;--bg:#fbf1c7;--surface:#fbf1c7;--input:#f2e5bc;--text:#3c3836;--muted:#3c3836;--line:#7c6f64;--brand:#d5c4a1;--on-brand:#3c3836;--selection:#bdae93;--focus:#3c3836;}
html[data-theme="system.accessible"]{color-scheme:dark;--bg:#1d2021;--surface:#1d2021;--input:#1d2021;--text:#fbf1c7;--muted:#fbf1c7;--line:#fbf1c7;--brand:#504945;--on-brand:#fbf1c7;--selection:#504945;--focus:#fbf1c7;}
html[data-theme="system.dark.soft"]{color-scheme:dark;--bg:#32302f;--surface:#32302f;--input:#282828;--text:#ebdbb2;--muted:#ebdbb2;--line:#928374;--brand:#504945;--on-brand:#ebdbb2;--selection:#665c54;--focus:#ebdbb2;}
html[data-theme="system.dark.hard"]{color-scheme:dark;--bg:#1d2021;--surface:#1d2021;--input:#1d2021;--text:#ebdbb2;--muted:#ebdbb2;--line:#928374;--brand:#504945;--on-brand:#ebdbb2;--selection:#665c54;--focus:#ebdbb2;}
html[data-theme="system.light.soft"]{color-scheme:light;--bg:#f2e5bc;--surface:#f2e5bc;--input:#ebdbb2;--text:#3c3836;--muted:#3c3836;--line:#7c6f64;--brand:#d5c4a1;--on-brand:#3c3836;--selection:#bdae93;--focus:#3c3836;}
html[data-theme="system.light.hard"]{color-scheme:light;--bg:#f9f5d7;--surface:#f9f5d7;--input:#fbf1c7;--text:#3c3836;--muted:#3c3836;--line:#7c6f64;--brand:#d5c4a1;--on-brand:#3c3836;--selection:#bdae93;--focus:#3c3836;}
html[data-theme="system.accessible.light"]{color-scheme:light;--bg:#f9f5d7;--surface:#f9f5d7;--input:#fbf1c7;--text:#282828;--muted:#282828;--line:#504945;--brand:#3c3836;--on-brand:#fbf1c7;--selection:#3c3836;--focus:#282828;}
.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.theme-options{margin:0;display:block;min-width:0;max-width:100%;font-weight:400}
.theme-options select{width:21rem;max-width:100%;min-height:44px;padding:8px 32px 8px 12px;font-size:.9375rem}
.report-workspace.workspace-enhanced>.topbar .brand{display:block;font-size:clamp(1.125rem,1.5vw,1.5rem);line-height:1.3;overflow:visible;overflow-wrap:anywhere}
.report-workspace.workspace-enhanced>.topbar .brand .workspace-institution-caption{font-size:1rem;font-weight:550;line-height:1.4;margin-top:3px}
.report-workspace.workspace-enhanced .result-status{font-size:.875rem}
.report-workspace.workspace-enhanced .report-pending-status{color:var(--text);font-size:.875rem;font-weight:650}
@media(max-width:800px){.report-workspace.workspace-enhanced>.topbar{flex-wrap:wrap}.report-workspace.workspace-enhanced>.topbar .brand{flex-basis:100%}.report-workspace.workspace-enhanced .portal-controls{width:100%;margin:0;justify-content:flex-start}.theme-options{flex:1}.theme-options select{width:100%;font-size:.875rem}.report-workspace.workspace-enhanced .report-summary-content{height:auto;min-height:59px}.report-summary-identity span{font-size:1rem}}

/* Short landscape preserves one complete row by placing identity and settings side by side. */
@media(min-width:600px) and (max-width:800px) and (max-height:440px){
 .report-workspace.workspace-enhanced>.topbar{flex-wrap:nowrap}
 .report-workspace.workspace-enhanced>.topbar .brand{flex:1;min-width:0;font-size:1.125rem}
 .report-workspace.workspace-enhanced>.topbar .brand .workspace-institution-caption{font-size:.875rem}
 .report-workspace.workspace-enhanced>.topbar .portal-controls{width:auto;flex-shrink:0;max-width:68%}
 .report-workspace.workspace-enhanced .theme-options select{width:17rem}
 .report-workspace.workspace-enhanced .report-summary-content{min-height:45px}
}

@media(max-width:599px){
 .report-workspace.workspace-enhanced>.topbar .portal-controls{flex-wrap:wrap}
 .portal-controls .theme-options{flex:1 0 100%;width:100%}
 .portal-controls .theme-options select{width:100%;font-size:.8125rem}
}
@media(max-width:800px){.report-summary-identity .report-pending-status{display:block;white-space:normal;margin-top:3px;padding:2px 0;background:transparent;font-size:.8125rem;line-height:1.3}}

html[data-theme] .field-error{color:var(--text)}
html[data-theme] .verification input[aria-invalid=true]{border-color:var(--text)}
html[data-theme] .verified .file{color:var(--on-brand)}
.error{background:var(--input);color:var(--text);border:1px solid var(--line)}
input[type=range]{accent-color:var(--text)}

/* Status feedback is inert and outside document flow: inputs never move. */
.status-banner {
 position: fixed;
 inset-inline: 16px;
 inset-block-end: max(16px, env(safe-area-inset-bottom));
 z-index: 100;
 width: min(42rem, calc(100vw - 32px));
 margin: 0 auto;
 padding: 14px 24px;
 border: 0;
 border-radius: 4px;
 background: var(--brand);
 color: var(--on-brand);
 text-align: center;
 font-weight: 600;
 line-height: 1.5;
 overflow-wrap: anywhere;
 pointer-events: none;
}
#login-feedback.status-banner { margin: 0 auto; }
.status-banner::before { content: '\2139'; margin-inline-end: 8px; }
.status-banner[hidden] { display: none; }
.result-status [role=status] { min-block-size: 1.5em; }
@media print { .status-banner { display: none; } }

/* Admin-only filters remain within the existing search region at every width. */
.administrative-filters { display: grid; grid-template-columns: auto minmax(8rem,1fr) auto minmax(8rem,1fr); gap: 8px; align-items: center; }
.administrative-filters label { margin: 0; }
.administrative-filters select { min-width: 0; }
@media(max-width:800px) { .administrative-filters { grid-template-columns: auto minmax(0,1fr); width: 100%; } }

.report-workspace.workspace-enhanced #report-search.administrative-search { flex-wrap: wrap; }
.administrative-search .administrative-filters { flex: 1 0 100%; order: 3; }

/* Administrative filter labels must remain visible inside the compact search shell. */
.report-workspace.workspace-enhanced #report-search .administrative-filters { grid-column: 1 / -1; width: 100%; }
.report-workspace.workspace-enhanced #report-search .administrative-filters label { position: static; width: auto; height: auto; padding: 0; margin: 0; overflow: visible; clip-path: none; white-space: normal; }
.report-workspace.workspace-enhanced #report-search .administrative-filters select { width: 100%; }

@media(max-width:800px) {
 .report-workspace.workspace-enhanced .heading.administrative-heading { flex-wrap: wrap; }
 .report-workspace.workspace-enhanced .administrative-heading #report-search { flex-basis: 100%; }
 .report-workspace.workspace-enhanced .administrative-heading .logout { margin-left: auto; }
}

/* Programmatic focus preserves navigation/reader position, not a control-sized ring.
   Interactive keyboard targets retain the thin, theme-colored inset above. */
#main-content:focus, #report-results:focus { outline: none; }
