/* Design comun (QA 2026-10-16, runda 7). Loaded last on every page: one look per role, whatever page or editor it is in.
   The browser inventory of 209 views found the same role drawn in several ways (6 kinds of links, 7 sub-headings, 5 tab and
   step systems, 12 badges, fields of 40/41/44 px). Each block below names the role and keeps a single variant. */

/* Text links share the brand hue; navigation and explicit button variants retain their own states. */
:where(.workspace) a:where(:not(.button-link):not(.backup-link):not(.primary):not(.secondary)) { color:hsl(var(--primary)); text-underline-offset:2px; }

/* Controls: fields, selects, the calendar button and every button keep the 44 px of the pages, in the editors too (the
   denser 38 px fields of doc 259 are given up for one height everywhere). */
.form-editor-page :is(#fields, #ac-fields) :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]), select),
.form-editor-page #fields .date-ro-open,
.workspace :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]), select),
dialog :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]), select) { min-height:var(--control-height); }
.date-ro-open { min-height:var(--control-height); min-width:var(--control-height); }
.workspace button.secondary, .workspace button.quiet, .workspace .button-link { min-height:var(--control-height); }

/* Links: an action written as text is blue and underlined; a quiet action (.quiet) is blue without underline. The way back
   to a list is the same everywhere («← Toate dosarele», «← Toate formularele»). */
.link-button { color:hsl(var(--primary)); }
.link-button:hover { color:hsl(var(--primary-hover)); }
/* A text action in a step of the dossier stands at the left, like the other actions, not stretched and centred. */
#case-wizard .link-button { justify-self:start; align-self:start; justify-content:flex-start; width:auto; }
.back-link, .all-forms-link { display:inline-flex; align-items:center; gap:.35rem; min-height:var(--control-height); margin:0 0 .35rem;
  padding:0 .5rem 0 0; color:hsl(var(--primary)); font-size:.9375rem; font-weight:500; line-height:1.3; text-decoration:none; }
/* The explorer's way back to the tree is only for the one-column layout (explorer.css), whatever the common look above. */
.back-link.explorer-back-to-tree { display:none; }
@media (max-width:1100px) { .back-link.explorer-back-to-tree { display:inline-flex; } }
.back-link:hover, .all-forms-link:hover { text-decoration:underline; }

/* Headings: page title, section, sub-section, item. One weight. */
.page-heading h2, .active-form-heading, .workspace .active-form-heading, .case-detail #detail-title { font-size:1.5rem; font-weight:650; line-height:1.25; }
.workspace h3:not(#detail-title):not(.sr-only) { font-size:1.05rem; font-weight:650; line-height:1.3; }
.workspace h4, .cu-subheading { font-size:1rem; font-weight:650; line-height:1.3; }
.workspace h5 { font-size:.95rem; font-weight:600; line-height:1.3; }
dialog h2, .layout-dialog h2, .applicant-reuse-dialog > h2 { font-size:1.25rem; font-weight:650; line-height:1.3; }
.deadline-watch summary h3 { display:inline; }

/* Messages: error (red), notice (amber), next step (neutral), help (grey text); status lines are readable. */
.notice, .case-deadlines-note { margin:.5rem 0; padding:.65rem .9rem; border:1px solid hsl(var(--accent)/.45); border-radius:var(--radius);
  background:hsl(var(--accent)/.12); color:hsl(var(--accent-foreground)); font-size:.875rem; }
ul.notice { padding-left:1.9rem; }
ul.notice li + li { margin-top:.25rem; }
.case-next-step { padding:.65rem .9rem; border:1px solid hsl(var(--border)); border-left-width:1px; border-radius:var(--radius);
  background:hsl(var(--muted)/.55); font-size:.875rem; }
.status { font-size:.875rem; }

/* Badges: one size; the colours keep their meaning (blue running, green done, amber waiting, red late or refused, grey ended). */
.state-badge, .deadline-badge, .library-badge { display:inline-flex; align-items:center; min-height:24px; padding:.1rem .55rem;
  border-radius:999px; font-size:.75rem; font-weight:600; line-height:1.3; white-space:nowrap; vertical-align:middle; }
/* QA 2026-10-19 (IA-04): four colours with one meaning each — red late/refused, amber attention, green done, grey information.
   The neutral badges share the grey of «Închis»; a retired HCL or text is information, not an error. */
.state-badge:not(.state-active):not(.state-waiting):not(.state-done):not(.state-ended):not(.state-rejected),
.library-badge.library-badge-retired { background:hsl(220 14% 94%); border-color:hsl(220 10% 78%); color:hsl(220 10% 34%); }

/* Tables: the column headings of every table read like those of the dossier list. */
.workspace table thead th { background:hsl(var(--muted)/.7); color:hsl(var(--muted-foreground)); font-size:.78rem; font-weight:600; text-align:left; }

/* Tabs underline the current section. Form section links are interactive; dossier stages are not buttons. */
.detail-tabs .detail-section-link { min-height:var(--control-height); font-size:.9375rem; }
.ac-page, .cu-section-nav a, .shared-section-nav a { min-height:40px; border:1px solid hsl(var(--border)); border-radius:999px;
  background:hsl(var(--card)); font-size:.86rem; }
.cu-section-nav a:hover, .shared-section-nav a:hover { border-color:hsl(var(--primary)); color:hsl(var(--primary)); }

/* Cards and groups share the corner of the cards. */
.case-participant-properties, .workspace fieldset.field-group { border-radius:var(--radius); }

/* A title focused by the page (after opening a dossier or a step) is not drawn as a field. */
.cases-page #detail-title:focus, .cases-page #wizard-start-title:focus, :is(h1,h2,h3,h4,h5)[tabindex="-1"]:focus,
/* Round 15: a status line focused only so that a screen reader reads it carries no focus ring either. */
:is([role="status"],[aria-live])[tabindex="-1"]:focus { outline:none; }

/* Registers on a phone (QA 2026-10-16, RS-1): the history tables become cards whose content wraps, so the page never scrolls
   sideways; a table that still needs more width scrolls inside its own box. */
.registers-handover-history, .registers-public-history { max-width:100%; overflow-x:auto; }
@media (max-width:760px) {
  .registers-history-table td > *, .registers-history-table .state-badge { max-width:100%; white-space:normal; overflow-wrap:anywhere; }
}

/* Accounts (QA 2026-10-16, RS-5): «Mai multe» opens its actions under the button, without breaking the row. */
.accounts-list .account-more { position:relative; }
.accounts-list .account-more[open] > .account-more-actions { position:absolute; right:0; top:calc(100% + .25rem); z-index:5; display:flex; flex-direction:column;
  align-items:stretch; gap:.35rem; min-width:12rem; margin:0; padding:.5rem; border:1px solid hsl(var(--border)); border-radius:var(--radius);
  background:hsl(var(--card)); box-shadow:0 8px 24px rgb(15 23 42 / .12); }
.accounts-list .account-more-actions .link-button { white-space:nowrap; }

/* A button aligned with the fields of its row keeps the place of a label, without a label of its own. */
.field-spacer { display:block; margin:.5rem 0 .35rem; }

/* A short action beside a long title keeps its words on one line («Vezi în foldere»). */
.section-heading .button-link.quiet { white-space:nowrap; }

/* «Taste rapide» reads the same in every editor (QA 2026-10-16, F-6): a quiet disclosure, not the grey pill of the AC groups. */
.ac-editor-page .completion-help.keyboard-help > summary { padding:0; background:none; border-radius:0; font-weight:500; min-height:32px; }

/* QA 2026-10-16 (AU-14): one look for the folded sections of a dossier: a chevron that turns, bold text, a 44 px row
   (the action buttons that open a form keep their button look). */
.procedure-guide > summary, .extension-details > summary, .archived-act-details > summary, .archived-extension-details > summary, .document-review-history > summary, .document-review-clarification > summary, #registry-numbering-details > summary {
  list-style:none; display:flex; align-items:center; gap:.5rem; min-height:44px; cursor:pointer; font-weight:600; color:hsl(var(--foreground)); }
.procedure-guide > summary::-webkit-details-marker, .extension-details > summary::-webkit-details-marker, .archived-act-details > summary::-webkit-details-marker, .archived-extension-details > summary::-webkit-details-marker, .document-review-history > summary::-webkit-details-marker, .document-review-clarification > summary::-webkit-details-marker, #registry-numbering-details > summary::-webkit-details-marker { display:none; }
.procedure-guide > summary::before, .extension-details > summary::before, .archived-act-details > summary::before, .archived-extension-details > summary::before, .document-review-history > summary::before, .document-review-clarification > summary::before, #registry-numbering-details > summary::before {
  content:'›'; flex:none; display:inline-block; width:.75rem; margin:0; font-size:1.25rem; line-height:1; color:hsl(var(--primary)); transition:transform .15s; }
.procedure-guide[open] > summary::before, .extension-details[open] > summary::before, .archived-act-details[open] > summary::before, .archived-extension-details[open] > summary::before, .document-review-history[open] > summary::before, .document-review-clarification[open] > summary::before, #registry-numbering-details[open] > summary::before { content:'›'; transform:rotate(90deg); }
/* QA 2026-10-16 (AU-14, browser check): the small folds that tell more («Calculul», «Despre această orientare», the
   signatory's other data, the technical details of the history) join the quiet link with ▾ / ▴ of app.css. */
details.case-fee-lines > summary, .procedure-guide details > summary, details.uat-signatory-more > summary, details.history-technical-details > summary {
  list-style:none; display:block; cursor:pointer; font-size:.88rem; font-weight:500; color:hsl(var(--primary)); }
details.case-fee-lines > summary::-webkit-details-marker, .procedure-guide details > summary::-webkit-details-marker, details.uat-signatory-more > summary::-webkit-details-marker, details.history-technical-details > summary::-webkit-details-marker { display:none; }
details.case-fee-lines > summary::after, .procedure-guide details > summary::after, details.uat-signatory-more > summary::after, details.history-technical-details > summary::after { content:" ▾"; font-size:.75rem; }
details.case-fee-lines[open] > summary::after, .procedure-guide details[open] > summary::after, details.uat-signatory-more[open] > summary::after, details.history-technical-details[open] > summary::after { content:" ▴"; }

/* Shared section navigation: a quiet underline, not another row of outlined action buttons. */
:is(.workspace-tabs,.settings-tabs) { display:flex; flex-wrap:wrap; gap:.15rem .45rem; padding:0; margin:.5rem 0 1rem; border:0; border-bottom:1px solid hsl(var(--border)); border-radius:0; background:hsl(var(--card)); }
:is(.workspace-tabs,.settings-tabs) > :is(a,button) { display:inline-flex; align-items:center; justify-content:center; min-height:44px; margin:0 0 -1px; padding:.55rem .75rem; border:0; border-bottom:2px solid transparent; border-radius:0; background:transparent; box-shadow:none; color:hsl(var(--muted-foreground)); font-size:.9375rem; font-weight:500; text-decoration:none; }
:is(.workspace-tabs,.settings-tabs) > :is(a,button):hover { background:hsl(var(--muted)/.5); color:hsl(var(--foreground)); }
.workspace-tabs > :is([aria-pressed="true"],[aria-selected="true"],[aria-current="page"]), .settings-tabs > a[aria-current="page"],
.workspace-tabs > :is([aria-pressed="true"],[aria-selected="true"],[aria-current="page"]):hover, .settings-tabs > a[aria-current="page"]:hover { color:hsl(var(--primary)); border-bottom-color:hsl(var(--primary)); font-weight:650; }
:is(.workspace-tabs,.settings-tabs) > :is(a,button):focus-visible { outline:2px solid hsl(var(--primary)); outline-offset:-2px; }
.case-workspace .detail-tabs { position:sticky; top:var(--cases-scroll-offset); z-index:5; }
.case-current-step .wizard-body { padding:1rem; gap:.65rem; }
.case-workspace .case-wizard { margin:.75rem 0; gap:.7rem; }
.case-workspace .wizard-actions { align-items:center; gap:.5rem .75rem; }
.case-workspace .wizard-actions > .primary { margin-right:.25rem; }
.case-workspace .wizard-other-actions > button { margin:.25rem; }
.case-workspace .case-quick-actions:empty { display:none; }
.case-summary-data .detail-overview > * { min-width:0; overflow-wrap:anywhere; }
.case-summary-data .detail-overview { gap:.75rem 1.25rem; }
.case-summary-data .detail-overview > div { padding:.45rem 0; border:0; border-bottom:1px solid hsl(var(--border)/.65); border-radius:0; background:transparent; }
.case-summary-data .detail-overview dt { font-size:.8rem; }
.case-summary-data .detail-overview dd { margin:.25rem 0 0; font-weight:500; }
@media(max-width:700px) {
  :is(.workspace-tabs,.settings-tabs) { gap:0; }
  :is(.workspace-tabs,.settings-tabs) > :is(a,button) { padding-inline:.6rem; white-space:normal; }
  .case-workspace .detail-tabs { position:static; overflow:visible; flex-wrap:wrap; }
  .case-current-step .wizard-body { padding:.8rem; }
  .case-workspace .wizard-other-actions { margin-left:0; }
}
/* QA 2026-10-19 (ME-4, DL-10): the chooser of a new document is one compact row (the form, then «Creează documentul»), so the
   documents of the dossier are seen without scrolling past a large box. */
@media (min-width:641px) {
  .prepare-form-box { grid-template-columns:minmax(0,1fr) auto; column-gap:.75rem; align-items:end; }
  .prepare-form-box > * { grid-column:1 / -1; }
  .prepare-form-box > select[data-form-code] { grid-column:1; grid-row:2; }
  .prepare-form-box > button[data-prepare-case] { grid-column:2; grid-row:2; justify-self:end; }
}
/* QA 2026-10-19 (ME-3, DL-10): in «Verificări» the daily work comes first (what was received, what was checked); the manual
   change of the dossier's state, rarely needed, closes the section. */
.case-workspace .detail-grid > #detail-tracking-card { order:1; }
/* QA 2026-10-19 (IA-09): in a long form the filled button is «Continuă» while a page follows; saving (or registering the
   request) becomes the filled button on the last page. «Înapoi» is not shown on the first page. */
.workspace:has(#ac-page-nav:not([hidden]) #ac-page-next:not([hidden])) :is(#ac-save, #register-request-btn),
.workspace:has(#form-page-nav:not([hidden]) #form-page-next:not([hidden])) :is(#save-btn, #register-request-btn) {
  background:hsl(var(--card)); color:hsl(var(--foreground)); border-color:hsl(var(--input)); box-shadow:0 1px 2px rgb(0 0 0 / .05); }
:is(#form-page-back, #ac-page-back):disabled { display:none; }
/* RV-2: in the window over a dossier the editor enables its buttons again after loading; the first page is read from the
   page bar itself, not from the button's state. */
#form-pages:has(.ac-page[data-page="1"][aria-current="step"]) ~ #form-page-nav #form-page-back { display:none; }
/* QA 2026-10-19 (IA-02, DL-14, DL-15): the deadlines summary is one box, not a box in a box; the separator before the
   situations to record is the line of that part (no «·» left alone on a phone); a term still in time is information (grey),
   so blue keeps one meaning («Înregistrat») and colour marks only what needs attention. */
.cases-page .deadline-watch { padding:0; border:0; background:none; }
.deadline-watch-count-separator { display:none; }
.legal-pending:not(.legal-soon) .deadline-badge { background:hsl(220 14% 94%); border-color:hsl(220 10% 78%); color:hsl(220 10% 34%); }
/* QA 2026-10-19 (IA-01): the whole row opens its dossier; the «Deschide» of each row is a quiet link (still a button for the
   keyboard), not 25 outlined boxes one under the other. The same for «Descarcă» in the registers list. */
.cases-table button[data-open-case] { background:none; border-color:transparent; box-shadow:none; color:hsl(var(--primary)); padding-inline:.5rem; }
.cases-table button[data-open-case]:hover { background:hsl(var(--primary) / .07); }
.registry-entry-actions a { border-color:transparent; background:none; box-shadow:none; color:hsl(var(--primary)); }
.registry-entry-actions a:hover { background:hsl(var(--primary) / .07); }
.cases-table tr.case-row { cursor:pointer; }
.cases-table tr.case-row:hover { background:hsl(var(--muted) / .45); }
/* QA 2026-10-19 (DL-08): «Alte acțiuni» looks the same in every procedure — a quiet link at the end of the actions — and, opened,
   lists its actions under it, not on the same row as the main ones. */
.wizard-actions .wizard-other-actions { margin-left:auto; }
.wizard-actions .wizard-other-actions > summary { min-height:44px; padding:.5rem .65rem; border:0; background:none; box-shadow:none;
  color:hsl(var(--primary)); font-weight:500; }
.wizard-actions .wizard-other-actions > summary::after { content:' ▾'; font-size:.75rem; }
.wizard-actions .wizard-other-actions[open] > summary::after { content:' ▴'; }
.wizard-actions .wizard-other-actions[open] { flex-basis:100%; display:flex; flex-direction:column; align-items:flex-start; gap:.4rem;
  margin-left:0; padding-top:.5rem; border-top:1px solid hsl(var(--border)); }
.case-workspace .wizard-actions .wizard-other-actions[open] > button { margin:0; }
/* QA 2026-10-19 (RS-16): «Lista», «De la» and «Până la» of the public lists stand on one row on a wide screen. */
@media (min-width:1100px) { .registers-period-grid { grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) minmax(0,1fr); } }
/* QA 2026-10-19 (FF-07): a page only visited is not «done»: its number is neutral grey, not green; the page with problems keeps
   its red ring. */
.ac-page.visited .ac-page-number { background:hsl(220 10% 46%); color:#fff; }
/* QA 2026-10-19 (FC-12): «Termene și taxe» is never an empty page: when the procedure has neither panel, one line says so. */
.case-management-empty { display:none; }
#case-advanced[data-tab="management"]:not(:has(#case-legal-deadlines:not([hidden]))):not(:has(#case-fees:not([hidden]))) .case-management-empty { display:block; }
/* QA 2026-10-19 (FC-14): with a fee form open, its «Păstrează» is the one filled button; «Calculează taxa» above turns outlined. */
.case-fees:has(.case-fees-form fieldset) button.primary:not(.case-fees-form button) {
  background:hsl(var(--card)); color:hsl(var(--foreground)); border-color:hsl(var(--input)); box-shadow:0 1px 2px rgb(0 0 0 / .05); }
/* QA 2026-10-19 (IA-06, IA-07): on the cards of texts and HCLs «Editează» stays a button; retiring (or reactivating) is the rarer
   act, a quiet text action beside it, so the cards do not read as rows of identical boxes. */
.library-card-actions button[data-action="status"] { background:none; border-color:transparent; box-shadow:none; color:hsl(var(--primary));
  text-decoration:none; }
.library-card-actions button[data-action="status"]:hover { background:hsl(var(--primary) / .07); text-decoration:underline; text-underline-offset:2px; }
/* QA 2026-10-19 (proposal 2): the summary of a dossier shows what the header does not: no empty «—» rubric, no repetition of the
   applicant, request number and date, noted term or automatic name (the edit form still has them all). */
#detail-overview > .overview-empty, #detail-overview > .overview-repeat { display:none; }
.case-quick-actions .case-due-left { color:hsl(var(--muted-foreground)); font-size:.875rem; }
.case-quick-actions .case-due-left::before { content:'· '; }
/* QA 2026-10-19 (proposal 6, FF-04, RS-12): beside the applicant one button takes data in («Persoane salvate»); saving the
   typed person and taking the data of an earlier request are quiet text actions, not three identical boxes in a row. */
button.directory-save, button.applicant-reuse-launch { background:none; border-color:transparent; box-shadow:none; color:hsl(var(--primary));
  text-decoration:none; padding-inline:.5rem; }
button.directory-save:hover, button.applicant-reuse-launch:hover { background:hsl(var(--primary) / .07); text-decoration:underline; text-underline-offset:2px; }
/* QA 2026-10-19 (proposal 10): «Istoric» by day — the day once as a heading, the account only when it changes, a repeated line once. */
#detail-history.history-grouped > li.history-day { list-style:none; margin:1rem 0 .25rem -1.25rem; font-weight:650; font-size:.9375rem; color:hsl(var(--foreground)); }
#detail-history.history-grouped > li.history-day:first-child { margin-top:0; }
#detail-history.history-grouped .history-day-part, #detail-history.history-grouped .history-sep { display:none; }
/* «Arată parola» next to a password field (login and «Parola mea»). */
.password-field { display:flex; align-items:stretch; gap:.5rem; }
.password-field > input { flex:1 1 auto; min-width:0; }
.password-field > .password-reveal { flex:none; min-height:44px; min-width:44px; padding:.4rem .75rem; }
.history-time-part { margin-left:.35rem; color:hsl(var(--muted-foreground)); font-variant-numeric:tabular-nums; }
#detail-history.history-grouped .history-time-part { margin:0 .5rem 0 0; }
#detail-history.history-grouped > li.history-same-actor .history-actor-part { display:none; }
#detail-history.history-grouped > li.history-repeat { display:none; }
#detail-history.history-grouped .history-times { color:hsl(var(--muted-foreground)); font-size:.85rem; }
/* QA 2026-10-19 (proposal 4): the records of an opinion line under one quiet «Consemnează ▾»; opened, they list under it. */
.case-opinion-menu { display:inline-block; margin-left:.35rem; }
.case-opinion-menu > summary { display:inline-flex; align-items:center; min-height:32px; cursor:pointer; list-style:none; color:hsl(var(--primary)); font-weight:500; font-size:.9rem; }
.case-opinion-menu > summary::-webkit-details-marker { display:none; }
.case-opinion-menu > summary::after { content:' ▾'; font-size:.75rem; }
.case-opinion-menu[open] > summary::after { content:' ▴'; }
.case-opinion-menu[open] { display:block; }
.case-opinion-menu[open] > .case-opinion-actions { display:flex; flex-wrap:wrap; gap:.25rem .75rem; padding:.25rem 0 .25rem .75rem; }
/* QA 2026-10-19 (proposal 7): a dossier is two short lines — its name; then number, procedure and date — with the address on one
   line (the whole of it on hover); the «Tip» column is gone (said on the second line) and «Termen» shows only when a dossier of the
   page has one. About nine dossiers fit the first screen instead of two. */
#case-list-section .cases-table th:nth-child(2), #case-list-section .cases-table td[data-label="Tip"] { display:none; }
#case-list-section .cases-table.no-deadlines th:nth-child(4), #case-list-section .cases-table.no-deadlines td[data-label="Termen"] { display:none; }
/* QA 2026-10-19 (RO-1): without the «Tip» column the visible columns still fill the card (fixed layout keeps the widths it is given). */
@media (min-width:761px) { #case-list-section .cases-table th:nth-child(1) { width:auto; } #case-list-section .cases-table th:nth-child(3) { width:16%; } #case-list-section .cases-table th:nth-child(4) { width:14%; } #case-list-section .cases-table th:nth-child(5) { width:14%; } }
/* QA 2026-10-19 (RF-2): a wrong date in «Evidențe» is said under its rubric. */
.directories-form input[aria-invalid="true"] { border-color:hsl(var(--destructive)); }
.directories-field-error { color:hsl(var(--destructive)); margin:.25rem 0 0; }
.cases-table td { padding-top:.55rem; padding-bottom:.55rem; vertical-align:middle; }
.cases-table .case-cell { display:grid; gap:.1rem; min-width:0; }
.cases-table .case-subline { display:block; max-width:62ch; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
@media (max-width:760px) { .cases-table .case-subline { max-width:100%; } }
/* QA 2026-10-19 (proposal 5, FF-03): one navigation in a long form — while the form is read page by page, the page bar leads and
   the header's «Secțiuni» shortcuts step aside (they come back with «Arată tot formularul»). The signatories' chooser follows
   the page of the signatories. */
body:has(.ac-page[aria-current="step"]) #header-section-navigation { display:none; }
#signatory-chooser.signatory-offpage { display:none; }
@media (min-width:900px) {
  #fields > fieldset.uat-managed-group .form-grid { grid-template-columns:repeat(auto-fit, minmax(15rem, 1fr)); }/* Runda 20: its .cu-grid has the 12 columns of the others */
  #fields > fieldset.uat-managed-group { padding-top:.5rem; padding-bottom:.5rem; }
}
/* QA 2026-10-19 (round 8, proposal 13): «Evidențe» is its own Settings tab; the other sections step aside while it is shown. */
#directories-settings { display:none; }
.settings-directories #directories-settings { display:block; }
.settings-audit :is(#uat-panel, #library-settings, #fees-settings, #deadlines-settings, #numbering-settings, #accounts-settings, #directories-settings) { display:none !important; }
.settings-accounts #audit-settings { display:none !important; }
.settings-audit #audit-settings { margin-top:0; }
.library-category { margin:.65rem 0; border:1px solid hsl(var(--border)); border-radius:var(--radius); }
.library-category > summary { padding:.65rem .8rem; font-weight:600; cursor:pointer; }
.library-category > .library-card { margin:.5rem .65rem; }
.settings-directories :is(#uat-panel, #library-settings, #fees-settings, #deadlines-settings, #numbering-settings, #accounts-settings, #audit-settings) { display:none !important; }
.directories-search { display:flex; flex-wrap:wrap; align-items:end; gap:.5rem .75rem; margin:.75rem 0; }
.directories-search .field { flex:1 1 18rem; margin:0; }
.directories-results { margin:.25rem 0 .75rem; padding-left:1.1rem; display:grid; gap:.15rem; }
.directories-card { margin-top:.75rem; }

/* Review 356: group information, not controls. Preserve legible fields and 44px actions. */
.case-back-nav { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.15rem .75rem; margin-bottom:.35rem; }
.case-back-nav > :is(.back-link,.button-link) { margin:0; }
.case-detail > .section-heading { margin-bottom:.5rem; }
.case-workspace .detail-tabs { margin:.5rem 0 .75rem; }
#detail-history.history-timeline { list-style:none; padding-left:0; }
#detail-history.history-timeline > li.history-day { margin-left:0; }
#detail-history .history-day-heading { margin:0; font:inherit; }
.document-create-disclosure { margin:.75rem 0; }
.document-create-disclosure > summary { min-height:44px; cursor:pointer; color:hsl(var(--primary)); font-weight:500; }
.document-create-disclosure .prepare-form-box { margin-top:.25rem; }
/* Round 25 (S-06): folds come in three families: a section (dark title, grey chevron), a quiet «more» (blue text with ▾) and an
   action (outlined button with ▾, dark text). The tool folds of Setări («Verifică un calcul», «Verifică un termen», «Dezactivare și
   recuperare conturi») and the journal's «Detalii tehnice» are quiet folds, as «Calendarul anului» on the same page. */
.settings-page details:is(.fees-check,.deadlines-check,.account-recovery) > summary, .settings-page details.audit-technical > summary { list-style:none; }
.settings-page details:is(.fees-check,.deadlines-check,.account-recovery) > summary::-webkit-details-marker, .settings-page details.audit-technical > summary::-webkit-details-marker { display:none; }
.settings-page details:is(.fees-check,.deadlines-check,.account-recovery) > summary::before, .settings-page details.audit-technical > summary::before,
.settings-page details.audit-technical[open] > summary::before { content:none; display:none; }
.settings-page details:is(.fees-check,.deadlines-check,.account-recovery) > summary::after, .settings-page details.audit-technical > summary::after { content:" ▾"; font-size:.75rem; }
.settings-page details:is(.fees-check,.deadlines-check,.account-recovery)[open] > summary::after, .settings-page details.audit-technical[open] > summary::after { content:" ▴"; }
.action-disclosure.document-create-disclosure > summary { color:hsl(var(--foreground)); }
.form-editor-page .active-form-heading { margin:.15rem 0 .5rem; }
.form-editor-page .standalone-note { margin:.25rem 0; }
.settings-page details.field-group > summary, .uat-signatory-more > summary { min-height:44px; align-content:center; }
@media(max-width:700px) {
  .case-back-nav { margin-bottom:.25rem; }
  .case-back-nav > .button-link { padding-inline:.35rem; }
  .case-current-step .wizard-body { padding:.65rem; }
  .form-editor-page .form-heading { margin-block:.35rem; }
  .form-editor-page .uat-summary.uat-ok { margin-bottom:.2rem; }
}
/* QA 2026-10-20: on a phone a step with its note («Neconsemnată integral») wraps the note under the step's name instead of
   widening the page (the steps stay on one line each otherwise). */
@media (max-width:600px) {
  .wizard-steps > .wizard-step:has(.wizard-check-note) { white-space:normal; flex-wrap:wrap; max-width:100%; }
  .wizard-steps .wizard-check-note { flex-basis:100%; padding-left:1.9rem; }
}
/* QA 2026-10-20 (ND-11): two actions in one cell of the publications table stay apart («Pachetul publicat», «Anulează»). */
.registers-history-table td .link-button + .link-button { margin-left:.75rem; }
/* QA 2026-10-20 (UX-14): the quiet «more» folds (blue text with ▾) share one row height and alignment on every page; the
   section folds and the action folds keep their own looks. */
details:is(.about-disclosure,.registry-about,.wizard-more,.deadline-lines,.explorer-rules,.library-history,.case-fee-lines,.uat-signatory-more,.history-technical-details) > summary {
  display:inline-flex; align-items:center; gap:.2rem; min-height:32px; }
/* QA 2026-10-20 (UX-07): a long dossier name takes at most two lines in the list (the whole name on hover and in the dossier). */
.cases-table .case-name-line { display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; line-clamp:2; overflow:hidden; }
/* QA 2026-10-20 (UX-08): «Mai multe filtre» reads the same in Dosare and in Registre. */
.case-filters-toggle { font-weight:500; }
/* Review CR9b-10: on a phone the quiet folds keep the 44 px target of the other controls. */
@media (max-width:600px) {
  details:is(.about-disclosure,.registry-about,.wizard-more,.deadline-lines,.explorer-rules,.library-history,.case-fee-lines,.uat-signatory-more,.history-technical-details) > summary { min-height:44px; }
  /* A disclosure title and its explanation read top to bottom. The shared mobile
     touch-target rule must not squeeze them into two competing flex columns. */
  .settings-page details.field-group > summary:has(> .help) { display:list-item; }
}

/* Round 14: modules/settings. Entries of a stopped module disappear; a page of a stopped module shows one message. */
[data-module-off] { display:none !important; }
.app-nav a[hidden] { display:none; }
.module-stopped-page > :not(.module-stopped-note) { display:none !important; }
.module-stopped-note { display:flex; flex-wrap:wrap; align-items:baseline; gap:.5rem 1rem; padding:1.25rem 0; }
.module-stopped-note p { margin:0; font-weight:600; }

/* ===== Round 15 (Z1): the common visual language. Variables are in app.css (--space-1…6, --text-*, --tone-*, --danger,
   --radius-card, --button-border). Later zones use these classes: .danger, .empty-state, .panel/.card, badges, .no-chevron. ===== */
.page-heading h2, .active-form-heading, .workspace .active-form-heading, .case-detail #detail-title { font-size:var(--text-page); font-weight:700; line-height:1.25; }
.page-heading { margin-bottom:var(--space-6); }
/* Round 19 (G2): one heading rhythm; the page's tabs or first block follow the title closely. */
.workspace > .page-heading { margin-bottom:var(--space-5); }
.workspace h3:not(#detail-title):not(.sr-only) { font-size:var(--text-section); font-weight:650; }
.workspace :is(.detail-card, .panel, .card) h3:not(#detail-title):not(.sr-only), .workspace h4 { font-size:var(--text-card); font-weight:650; }
.help, .muted { font-size:var(--text-help); color:hsl(var(--muted-foreground)); }
.group-label { font-size:var(--text-label); font-weight:600; color:hsl(var(--muted-foreground)); }

/* Cards: one corner, one border; a second level inside a card is a line and a title, not another card. */
.registry-panel, .case-form-panel, .detail-card, .deadline-watch, .panel, .card { border-radius:var(--radius-card); }
.panel, .card { min-width:0; padding:var(--space-4); border:1px solid hsl(var(--border)); background:hsl(var(--card)); }
@media (min-width:641px) { .panel, .card { padding:var(--space-5) var(--space-5) var(--space-4); } }

/* Buttons on three levels: filled (.primary), outlined (.secondary, softer border), blue text without underline (.link-button);
   dangerous = red text (.danger). Underline only on hover and focus; links inside sentences stay underlined. */
.secondary, .button-link { border-color:hsl(var(--button-border)); }
/* Round 25 (S25-7): every text action has the same weight as «Despre registru» and «Mai multe filtre». */
.link-button { text-decoration:none; font-weight:500; }
.link-button:hover, .link-button:focus-visible { text-decoration:underline; text-decoration-thickness:1px; text-underline-offset:3px; }
.danger, .link-button.danger { color:hsl(var(--danger)); }
.link-button.danger:hover { color:hsl(0 65% 32%); }
:is(button, .button-link).danger { background:none; border-color:transparent; box-shadow:none; }
:is(button, .button-link).danger:hover:not(:disabled) { background:hsl(var(--danger) / .08); color:hsl(var(--danger)); border-color:transparent; }
.link-button.danger:hover:not(:disabled) { background:none; }
/* Runda 7.11 (B5): the value of a locked field (a document opened for reading) has the colour of the ordinary text, on a lightly shaded ground. */
:is(input:not([type=checkbox], [type=radio], [type=range], [type=color]), select, textarea):disabled { opacity:1; background:hsl(var(--muted) / .55); color:hsl(var(--foreground)); -webkit-text-fill-color:hsl(var(--foreground)); border-color:hsl(var(--border)); }
:is(input, textarea):disabled::placeholder { color:hsl(var(--muted-foreground)); -webkit-text-fill-color:hsl(var(--muted-foreground)); }
/* Runda 7.11 (N1, N3): a question has «Renunță» on the left and the action on the right; red is only the action that destroys something, only in a window that asks. */
.app-ask .app-ask-actions { justify-content:flex-end; }
dialog :is(button, .button-link).primary.destructive { border-color:hsl(var(--danger)); background:hsl(var(--danger)); color:hsl(0 0% 100%); }
dialog :is(button, .button-link).primary.destructive:hover:not(:disabled) { background:hsl(var(--danger) / .88); border-color:hsl(var(--danger)); color:hsl(0 0% 100%); }

/* Badges: neutral grey without border (Înregistrat, Închis, Retrasă); amber attention, red problem, green success. */
.state-badge, .deadline-badge, .library-badge { font-size:var(--text-label); }
.state-badge.state-active, .state-badge.state-ended,
.state-badge:not(.state-active):not(.state-waiting):not(.state-done):not(.state-ended):not(.state-rejected),
.library-badge.library-badge-retired { background:hsl(var(--tone-neutral-bg)); border-color:transparent; color:hsl(var(--tone-neutral-fg)); }
.state-badge.state-waiting { background:hsl(var(--tone-attn-bg)); border-color:hsl(var(--tone-attn-border)); color:hsl(var(--tone-attn-fg)); }
.state-badge.state-rejected { background:hsl(var(--tone-problem-bg)); border-color:hsl(var(--tone-problem-border)); color:hsl(var(--tone-problem-fg)); }
.state-badge.state-done { background:hsl(var(--tone-ok-bg)); border-color:hsl(var(--tone-ok-border)); color:hsl(var(--tone-ok-fg)); }
/* Round 19 (G1): in the dossier list the usual state (in work, ended) is quiet text; a pill stays for what asks attention or is done. */
.cases-table .state-badge:is(.state-active, .state-ended) { min-height:0; padding-inline:0; background:none; border-color:transparent; color:hsl(var(--muted-foreground)); font-weight:500; }
/* Round 19 (G5): secondary text a little darker, for contrast at 13 px. */
:root { --muted-foreground: 215 16% 36%; }
/* Round 19 (C3): a disabled main button is neutral grey, not a washed-out blue that looks broken. */
:is(button, .button-link).primary:is(:disabled, [aria-disabled="true"]) { opacity:1; background:hsl(var(--muted)); border-color:hsl(var(--border)); color:hsl(var(--muted-foreground)); box-shadow:none; }

/* Messages and lists. */
.field-error { font-size:var(--text-help); }
.cases-table th, .workspace table thead th { font-size:var(--text-label); letter-spacing:.02em; }
.empty-state { display:flex; flex-wrap:wrap; align-items:center; gap:var(--space-2) var(--space-4); padding:var(--space-5) var(--space-4); color:hsl(var(--muted-foreground)); font-size:.9375rem; }
.empty-state > :is(p, span):first-child { margin:0; }

/* Folds: an own chevron (turns when open), a row of 44 px, visible on a phone as well. Low specificity on purpose: a fold with its
   own marker in the CSS of its page is left out below, and any other can opt out with the class .no-chevron. */
:where(.workspace details:not(.no-chevron, .about-disclosure, .registry-about, .wizard-more, .deadline-lines, .explorer-rules, .library-history, .case-fee-lines, .uat-signatory-more, .history-technical-details, .case-opinion-menu, .wizard-other-actions, .account-more, .ac-group, .ac-authority, .ac-rare, .procedure-guide, .extension-details, .archived-act-details, .archived-extension-details, .document-review-history, .document-review-clarification, .case-secondary-disclosure, .dossier-fold, .action-disclosure, .deadline-watch-details, .audit-technical, .editor-context, .model-notes, #registry-numbering-details):not(.deadline-watch details, .procedure-guide details)) > summary:is(summary) {
  list-style:none; display:block; min-height:44px; padding:.7rem 0; cursor:pointer; font-weight:600; }
:where(.workspace details:not(.no-chevron, .about-disclosure, .registry-about, .wizard-more, .deadline-lines, .explorer-rules, .library-history, .case-fee-lines, .uat-signatory-more, .history-technical-details, .case-opinion-menu, .wizard-other-actions, .account-more, .ac-group, .ac-authority, .ac-rare, .procedure-guide, .extension-details, .archived-act-details, .archived-extension-details, .document-review-history, .document-review-clarification, .case-secondary-disclosure, .dossier-fold, .action-disclosure, .deadline-watch-details, .audit-technical, .editor-context, .model-notes, #registry-numbering-details):not(.deadline-watch details, .procedure-guide details)) > summary::-webkit-details-marker { display:none; }
:where(.workspace details:not(.no-chevron, .about-disclosure, .registry-about, .wizard-more, .deadline-lines, .explorer-rules, .library-history, .case-fee-lines, .uat-signatory-more, .history-technical-details, .case-opinion-menu, .wizard-other-actions, .account-more, .ac-group, .ac-authority, .ac-rare, .procedure-guide, .extension-details, .archived-act-details, .archived-extension-details, .document-review-history, .document-review-clarification, .case-secondary-disclosure, .dossier-fold, .action-disclosure, .deadline-watch-details, .audit-technical, .editor-context, .model-notes, #registry-numbering-details):not(.deadline-watch details, .procedure-guide details)) > summary::before {
  content:''; display:inline-block; flex:none; margin:0 .65rem 0 .15rem; vertical-align:.15em; width:.5rem; height:.5rem; border-right:2px solid hsl(var(--muted-foreground)); border-bottom:2px solid hsl(var(--muted-foreground)); transform:rotate(-45deg); transition:transform .15s; }
:where(.workspace details[open]:not(.no-chevron, .about-disclosure, .registry-about, .wizard-more, .deadline-lines, .explorer-rules, .library-history, .case-fee-lines, .uat-signatory-more, .history-technical-details, .case-opinion-menu, .wizard-other-actions, .account-more, .ac-group, .ac-authority, .ac-rare, .procedure-guide, .extension-details, .archived-act-details, .archived-extension-details, .document-review-history, .document-review-clarification, .case-secondary-disclosure, .dossier-fold, .action-disclosure, .deadline-watch-details, .audit-technical, .editor-context, .model-notes, #registry-numbering-details):not(.deadline-watch details, .procedure-guide details)) > summary::before { transform:rotate(45deg); }

/* Frame: the side menu with icons, a quiet current item (accent background and a 3 px yellow bar), the account at the bottom. */
@media (min-width:1024px) { .sidebar { display:flex; flex-direction:column; } }
@media (max-width:1023px) { body.menu-open .sidebar { flex-direction:column; } }
.sidebar-brand { flex:none; }
.app-nav { flex:none; padding:var(--space-3) var(--space-3) 0; gap:var(--space-1); }
.app-nav a { gap:.75rem; padding:.6rem .75rem; border-radius:var(--radius); color:hsl(var(--sidebar-foreground) / .85); font-weight:500; }
.app-nav a svg { flex:none; width:20px; height:20px; }
.app-nav a:hover { color:hsl(var(--sidebar-foreground)); }
.app-nav a[aria-current="page"], .app-nav a[aria-current="page"]:hover, .app-nav a[aria-current="location"], .app-nav a[aria-current="location"]:hover {
  background:hsl(var(--sidebar-accent)); color:hsl(var(--sidebar-foreground)); box-shadow:inset 3px 0 0 hsl(var(--sidebar-primary)); }
.sidebar-account { flex:none; margin:auto 0 0; padding:var(--space-4); border:0; gap:var(--space-1); }
.sidebar-account .account-label { display:none; }
.sidebar-account [data-account] { display:flex; align-items:center; gap:.75rem; min-width:0; font-size:.875rem; }
.account-avatar { flex:none; display:grid; place-items:center; width:36px; height:36px; border-radius:50%; background:hsl(var(--sidebar-accent)); color:hsl(var(--sidebar-foreground)); font-weight:650; text-transform:uppercase; }
.account-text { display:grid; min-width:0; line-height:1.3; }
.account-name { font-weight:600; overflow-wrap:anywhere; }
.account-role { font-size:var(--text-label); color:hsl(var(--sidebar-foreground) / .7); }
.sidebar .sidebar-account :is(button, .account-settings-link) { width:auto; justify-self:start; padding-inline:.25rem; background:none; border-color:transparent; box-shadow:none; color:hsl(var(--sidebar-foreground) / .8); font-weight:500; }
.sidebar .sidebar-account :is(button, .account-settings-link):is(:hover, :focus-visible):not(:disabled) { background:none; border-color:transparent; color:hsl(var(--sidebar-foreground)); text-decoration:underline; text-underline-offset:3px; }
/* Review 16 (T1-U8): on a phone a message appears at the top, under the fixed bar, so it never covers the step, the deadline or
   the bottom bar of a form. */
@media (max-width:600px) {
  body :is(.toast-box,.toast-status:not(:empty):not(.toast-text)),
  body:is(.form-editor-page, :has(.settings-page .uat-form > .form-actions)) :is(.toast-box,.toast-status:not(:empty):not(.toast-text)),
  body.ac-editor-page :is(.toast-box,.toast-status:not(:empty):not(.toast-text)) {
    top:calc(64px + var(--toast-stack-offset,0px)); bottom:auto; left:.75rem; right:.75rem; max-width:none; }
  /* The names of the other steps leave the screen but stay for screen readers (display:none removed them). */
  body .ac-pages .ac-page:not([aria-current="step"]) > span:not(.ac-page-number) { display:block; position:absolute; width:1px; height:1px; margin:-1px; padding:0; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; border:0; }
}
/* Review 16 (T2-U11): on the dark menu the close button keeps light text when focused or hovered (it gets focus when the menu opens). */
.sidebar .mobile-nav-close:is(:hover, :focus, :focus-visible):not(:disabled) { background:hsl(var(--sidebar-accent)); color:hsl(var(--sidebar-foreground)); border-color:hsl(var(--sidebar-foreground) / .45); }
@media (max-width:1023px) {
  body.menu-open .sidebar { display:flex; }
  .site-header .wrap { min-height:56px; padding:.25rem var(--space-2); justify-content:flex-start; gap:var(--space-2); }
  .site-header .wrap > div { min-width:0; flex:1; }
  .menu-button { width:44px; min-width:44px; padding:0; background:none; border-color:transparent; box-shadow:none; color:hsl(var(--foreground)); }
  .menu-button svg { width:22px; height:22px; }
  .site-header h1 { position:static; width:auto; height:auto; overflow:hidden; clip-path:none; white-space:nowrap; text-overflow:ellipsis; font-size:1.0625rem; font-weight:650; line-height:1.3; }
  .site-header .subtitle { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
}

/* Login: one card centred in the window with the brand above it, the same on a desktop and on a phone. */
.login-page .login-main { min-height:100vh; min-height:100dvh; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:var(--space-5); padding:var(--space-4); }
.login-page .login-brand { gap:.75rem; }
.login-page .login-brand .brand-mark { width:40px; height:40px; }
.login-page .login-brand strong { font-size:1.25rem; line-height:1.2; }
.login-page .login-card { width:min(100%,420px); border-radius:var(--radius-card); }
.login-page .login-card h1 { font-size:var(--text-page); font-weight:700; }
.login-page .login-card form { gap:var(--space-4); }
.login-page .login-card .help { margin:var(--space-4) 0 0; }

/* «Arată parola»: an eye inside the field (44 × 44), its name says what a press does. */
.password-field { position:relative; display:block; }
.password-field > input { padding-right:48px; }
.password-field > .password-reveal { position:absolute; top:0; right:0; display:grid; place-items:center; width:44px; min-width:44px; height:100%; min-height:44px; padding:0; border:0; background:none; box-shadow:none; color:hsl(var(--muted-foreground)); }
.password-field > .password-reveal:hover:not(:disabled) { background:none; color:hsl(var(--primary)); }
.password-reveal svg { width:20px; height:20px; }
.password-reveal .eye-slash { opacity:0; }
.password-reveal[data-shown="true"] .eye-slash { opacity:1; }

/* «Parola mea»: one level of border, the warning at the button, «Renunță» as text. */
/* QA 2026-10-28 (round 2): the page has no settings-page class; the fields are not a card (its shadow drew a second line). */
#password-form .field-group { padding:0; border:0; margin:0; box-shadow:none; background:none; }
#password-form .password-actions { display:flex; flex-wrap:wrap; align-items:center; gap:var(--space-2) var(--space-4); margin-top:var(--space-4); }
#password-form .password-actions > .notice { flex:1 1 100%; margin:0 0 var(--space-1); }

/* A compact task surface: keep readable 44px controls, reduce repeated framing
   and leave explanations beside the task that needs them. No warnings are hidden. */
.cases-page .registry-tools { margin:.15rem 0 .5rem; gap:.15rem .75rem; }
.cases-page .registry-tools > .registry-about { margin:0; }
.cases-page .registry-tools > .registry-about[open] { flex-basis:100%; }
.cases-page .registry-tools > .registry-export-row { margin:0 0 0 auto; }
.cases-page .registry-filter-grid { margin:.35rem 0 .25rem; }
.cases-page .registry-filter-grid > .field > label { margin-top:0; }
.case-workspace .detail-card { padding:.8rem .9rem; }
.case-workspace .detail-card > :is(h3,h4) { margin:0 0 .35rem; }
.case-workspace .detail-card > :is(.help,.empty) { margin:.3rem 0 .6rem; }
.case-workspace .detail-card > .action-disclosure { margin-top:.6rem; padding-top:.5rem; }
.case-workspace .detail-card .inline-form { margin:.65rem 0 .25rem; padding-top:.5rem; }
.case-workspace .incoming-list .empty { margin:.25rem 0; }
.case-workspace #case-compliance:not(:has(> details[open])) { padding:.25rem .9rem; border-color:transparent; }
.settings-page .field-group { padding:.9rem 1rem; margin-bottom:.8rem; }
.settings-page .uat-settings-grid { gap:0 1rem; }
.settings-page .uat-settings-grid .field { margin-bottom:.6rem; }
.settings-page .uat-settings-grid .field > label { margin-top:.35rem; }
.settings-page .uat-settings-grid .field > .help { margin:.25rem 0 0; line-height:1.4; }
.registry-activity .uat-settings-grid .field { margin-bottom:.5rem; }
.registry-activity .registers-presets { margin:.15rem 0; gap:.25rem .75rem; }
.registry-activity .registers-presets > button { background:transparent; border-color:transparent; box-shadow:none;
  color:hsl(var(--primary)); text-decoration:none; }
.registry-activity .registers-presets > button:hover { background:hsl(var(--primary)/.07); text-decoration:underline; text-underline-offset:2px; }
.registry-activity .registers-presets > button[aria-pressed="true"] { background:hsl(var(--primary)/.1); color:hsl(var(--primary)); font-weight:650; text-decoration:none; }
@media (min-width:761px) {
  .cases-page #case-list-section:not(.filters-open) .case-filter-grid { grid-template-columns:minmax(0,2fr) minmax(10rem,1fr); }
  .cases-page #case-list-section:not(.filters-open) .case-filter-grid .field:first-child { grid-column:auto; }
  .cases-page #registry:not(.filters-open) .registry-filter-grid { grid-template-columns:minmax(0,2fr) minmax(10rem,1fr); }
  .cases-page #case-list-section .cases-table th:nth-child(3) { width:9.5rem; }
  .cases-page #case-list-section .cases-table th:last-child { width:7rem; }
  .cases-page #case-list-section [data-open-case] { white-space:nowrap; overflow-wrap:normal; word-break:normal; }
}
@media (max-width:760px) {
  .cases-page .registry-tools > .registry-export-row { margin-left:0; }
  .case-workspace .detail-card { padding:.7rem; }
  .settings-page .field-group { padding:.8rem; }
}

/* Round 13 (T1-18, cases/forms zone): the results of «Imobile salvate» read from the left. */
.property-directory-dialog .applicant-reuse-results button { text-align:left; justify-items:start; align-items:start; }
/* Round 13 (T1-20, cases/forms zone): on a phone every checkbox is a target of at least 24 px; the tabs stay on one row and scroll,
   the chosen one centred by setDetailTab, instead of wrapping on three rows that jump. */
@media (max-width:600px) {
  :is(.cases-page, .form-editor-page) :is(input[type=checkbox], input[type=radio], .field > label.choice-inline input) { width:1.5rem; min-width:1.5rem; height:1.5rem; min-height:1.5rem; }
  .case-workspace .detail-tabs { flex-wrap:nowrap; overflow-x:auto; scrollbar-width:thin; }
  .case-workspace .detail-tabs > * { flex:0 0 auto; }
  /* Round 26: the side where the strip goes on fades out, so a tab cut at the edge («ează») never reads as a broken word. */
  .case-workspace .detail-tabs[data-more-right="true"] { -webkit-mask-image:linear-gradient(to right, #000 calc(100% - 2.5rem), transparent); mask-image:linear-gradient(to right, #000 calc(100% - 2.5rem), transparent); }
  .case-workspace .detail-tabs[data-more-left="true"] { -webkit-mask-image:linear-gradient(to left, #000 calc(100% - 2.5rem), transparent); mask-image:linear-gradient(to left, #000 calc(100% - 2.5rem), transparent); }
  .case-workspace .detail-tabs[data-more-left="true"][data-more-right="true"] { -webkit-mask-image:linear-gradient(to right, transparent, #000 2.5rem, #000 calc(100% - 2.5rem), transparent); mask-image:linear-gradient(to right, transparent, #000 2.5rem, #000 calc(100% - 2.5rem), transparent); }
}

/* Round 21: «Cerere depusă în altă zi?» next to «Înregistrează cererea»: a small link; the date opens under it. */
.request-date-choice { display:flex; flex-direction:column; align-items:flex-start; gap:.4rem; font-size:.875rem; }
/* Review 21: the choice stands on its own line under the action buttons; its message reads as an error. */
.form-actions > .request-date-choice { order:99; flex:1 1 100%; }
.request-date-choice .inline-error { margin:.25rem 0 0; color:hsl(var(--danger)); font-size:var(--text-help); }
.request-date-choice .request-date-link { min-height:44px; display:inline-flex; align-items:center; color:hsl(var(--primary)); }
.request-date-choice .request-date-box { margin:0; width:min(24rem,100%); max-width:100%; }
@media (max-width:640px) { .request-date-choice { width:100%; } .request-date-choice .request-date-box { width:100%; } }

/* Lot A, from the beneficiaries' list (27.10.2026), items 9 and 17: «Nu se aplică» and the library's «…» stand on the
   label's row, at the right; the control keeps the full width under them. */
.field:has(> .cu-option, > .cu-absence:not([hidden]), > .library-pick:not([hidden]), > div > label > [data-na], > .person-directory-actions) { display:grid; grid-template-columns:minmax(0,1fr) auto auto; column-gap:.75rem; align-content:start; }
.field:where(:has(> .cu-option, > .cu-absence:not([hidden]), > .library-pick:not([hidden]), > div > label > [data-na], > .person-directory-actions)) > * { grid-column:1 / -1; }
.field:where(:has(> .cu-option, > .cu-absence:not([hidden]), > .library-pick:not([hidden]), > div > label > [data-na], > .person-directory-actions)) > label:first-child { grid-column:1; grid-row:1; align-self:end; }
.field > .cu-absence:not([hidden]), .field > .library-pick:not([hidden]), .field > div:has(> label > [data-na]) { display:contents; }
.field > .cu-absence > :not(.cu-option), .field > .library-pick > .library-sources, .field > div:has(> label > [data-na]) > :not(label) { grid-column:1 / -1; }
.field > .cu-option, .field > .cu-absence > .cu-option, .field > div > label:has(> [data-na]) { grid-column:2; grid-row:1; align-self:end; justify-self:end; display:flex; align-items:center; gap:.4rem; min-height:0; margin:0 0 .3rem; font-size:.82rem; font-weight:400; white-space:nowrap; }
.field > .library-pick > button { grid-column:3; grid-row:1; align-self:end; min-height:28px; min-width:2.4rem; padding:0 .55rem; margin:0 0 .25rem; line-height:1; font-weight:700; letter-spacing:.06em; }
@media (max-width:700px) { .field > .library-pick > button, .field > .cu-option, .field > .cu-absence > .cu-option, .field > div > label:has(> [data-na]) { min-height:40px; } }
/* Runda 10 (QA): on a wide screen the «Nu se aplică» box beside a label is no taller than the label (the editors gave their options
   34–44 px), so the inputs of a row stay level; on a phone it keeps its touch height. */
@media (min-width:701px) { .cu-editor .field.field > .cu-option, .cu-editor .field.field > .cu-absence > .cu-option, .field.field > div > label:has(> [data-na]) { min-height:0; } }
/* Runda 10 (QA): a locked rubric is read, not resized. */
textarea[readonly] { resize:none; }

/* Runda 10 (QA): a row of provisions (Prevederea n): «Nu se aplică» and the library's «…» stand on its title line, at the right. */
.cu-rule-row > legend.rule-head { float:left; width:100%; box-sizing:border-box; display:flex; align-items:center; justify-content:space-between; gap:.75rem; padding:0; margin:0 0 .4rem; }
.cu-rule-row > legend.rule-head ~ * { clear:both; }
.cu-rule-row > legend.rule-head .rule-tools { display:flex; align-items:center; gap:.75rem; margin-left:auto; }
.cu-rule-row > legend.rule-head .cu-option { min-height:0; margin:0; gap:.4rem; font-size:.82rem; font-weight:400; white-space:nowrap; }
.cu-rule-row > legend.rule-head .rule-tools > button { min-height:28px; min-width:2.4rem; padding:0 .55rem; line-height:1; font-weight:700; letter-spacing:.06em; }
@media (max-width:700px) { .cu-rule-row > legend.rule-head .cu-option, .cu-rule-row > legend.rule-head .rule-tools > button { min-height:40px; } }

/* Lot A, item 2 and item 28: on a wide form the short rubrics share a row (CNP, series, number, dates, the address details),
   and the applicant's name and CNP stand together. */
@media (min-width:900px) {
  :is(.form-editor-page,.ac-editor-page) .cu-grid { grid-template-columns:repeat(12,minmax(0,1fr)); }/* Runda 20: 12 columns, so a rubric can be as narrow as its value */
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field { grid-column:span 6; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > :is(.field.cu-wide,.cu-choice-group) { grid-column:1 / -1; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field:has(> .date-ro-control, > div > .date-ro-control, > :is(input,select):is([id$=".cnp"],[id$="/cnp"],[id$=".series"],[id$="/series"],[id$=".number"],[id$="/number"],[id$=".staircase"],[id$="/staircase"],[id$=".floor"],[id$="/floor"],[id$=".apartment"],[id$="/apartment"],[id$=".block"],[id$="/block"],[id$=".issuer"],[id$="/issuer"],[id$="postcode"],[id$="postalCode"],[id$="postCode"])) { grid-column:span 3; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.field:has(> .date-time-parts) { grid-column:span 6; }
  /* Runda 10 (QA): the narrow rubrics put «Nu se aplică» on the label row as well (decision of the meeting): no exception under the box. */
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-wide:has(> [id$="applicant.name"]):has(+ .field > [id$="applicant.cnp"]) { grid-column:span 9; }
}

/* Lot A, item 10: the note on keeping the entries in the browser tab is not shown under the forms. */
[data-editor-guidance-key="persistenceHelp"] { display:none !important; }

/* Lot A, item 35: the date and the hour of one rubric, side by side. */
.date-time-parts { display:flex; flex-wrap:wrap; gap:.5rem; align-items:center; }
.date-time-parts > .date-ro-control { flex:1 1 11rem; max-width:15rem; }
.date-time-parts .date-time-hour { width:8rem; min-height:38px; }

/* Lot B, item 27: a value that comes from Datele UAT is shown, not edited, in the form. */
.field :is(input,textarea):is(.uat-fixed,.from-request) { background:hsl(var(--muted)); color:hsl(var(--foreground)); cursor:default; }
/* Runda 9 (QA): a value that cannot be changed here is told apart from a typed one by a dashed edge (an inline image is refused by
   the page's security policy, so no lock picture). */
.field :is(input,textarea):is(.uat-fixed,.from-request) { border-style:dashed; border-color:hsl(var(--muted-foreground) / .55); }

/* Lot B, item 28: «Preia dintr-o cerere anterioară» (and the saved persons, where they stay) on the name's label row. */
.field > .person-directory-actions { grid-column:2 / -1; grid-row:1; justify-self:end; align-self:end; margin:0 0 .2rem; }
@media (min-width:701px) { .field > .person-directory-actions > button { min-height:28px; padding-block:0; } }

/* Beneficiaries, item 6: an issued act (or a request whose act is issued) is read and printed, not saved again. */
body.registered-locked #save-btn, body.registered-locked #pdf-btn, body.registered-locked #reset-btn, body.registered-locked #finalize-btn { display:none !important; }
/* Round E: the link beside a label («Preia dintr-o cerere anterioară») does not make its label row taller than the neighbour's,
   so the boxes of one row stay on one line. */
@media (min-width:701px) { .field > .person-directory-actions { margin:-.4rem 0 0; } .field > .person-directory-actions > button { min-height:26px; } }
/* Beneficiaries, item 7: the line over an act whose grey rubrics come from the request. */
.request-values-note { display:flex; flex-wrap:wrap; align-items:center; gap:.4rem .75rem; }
.request-values-note > button { min-height:32px; padding:.2rem .75rem; font-size:.85rem; }
/* QA 2026-10-28: an issued act is read only: nothing is prefilled into it either. */
body.registered-locked #permit-prefill { display:none !important; }
/* QA 2026-10-28: a request or an act opened only to be read offers nothing to take into it. */
body.registered-locked .applicant-reuse-launch, body.registered-locked .person-directory-actions { display:none !important; }
.request-values-diff { flex-basis:100%; display:grid; gap:.25rem; margin:.25rem 0; font-size:.85rem; }
.request-values-diff label { display:flex; gap:.5rem; align-items:flex-start; margin:0; font-weight:400; }

/* Runda 3 (QA 2026-10-28): «Ghidul de utilizare» above the account, at the bottom of the menu. */
.sidebar-guide { display:flex; align-items:center; gap:.5rem; margin:auto var(--space-3) 0; padding:.55rem .75rem; border-radius:var(--radius); color:hsl(var(--sidebar-foreground) / .85); font-size:.875rem; font-weight:500; text-decoration:none; }
.sidebar-guide::before { content:'?'; display:inline-grid; place-items:center; width:1.15rem; height:1.15rem; border:1.5px solid currentColor; border-radius:50%; font-size:.72rem; font-weight:700; }
.sidebar-guide:hover { background:hsl(var(--sidebar-accent)); color:hsl(var(--sidebar-foreground)); }
.sidebar-guide + .sidebar-account { margin-top:0; }
/* Runda 23.11: «Noutăți» under «Ghidul de utilizare»; the page «Noutăți» is a column of boxes with the version on the edge. */
.sidebar-guide + .sidebar-guide { margin-top:0; }
.sidebar-news::before { content:'i'; font-style:italic; font-family:Georgia,serif; }
.sidebar-news[aria-current="page"] { background:hsl(var(--sidebar-accent)); color:hsl(var(--sidebar-foreground)); }
.news-page .news-list { display:grid; gap:var(--space-4); max-width:56rem; }
.news-page .news-version { margin:0; }
.news-page .news-version ul { margin:0; padding-left:1.15rem; display:grid; gap:.4rem; line-height:1.45; }
.news-page #news-installed { margin:.25rem 0 0; }
/* Runda 3: in a form consulted by the read role, choices do not change either. */
.reader-locked :is(select, input[type=checkbox], input[type=radio], .cu-option, .choice-list label) { pointer-events:none; }
/* Runda 3 (QA 2026-10-28): the technical details of each journal row are a small grey line, not a second heading per row. */
.audit-technical summary { min-height:32px; padding:.2rem .25rem; font-size:.78rem; font-weight:400; }

/* Runda 4 (beneficiarii, 28.10.2026, «cât mai tabelar», ca registrul arătat în ședință): ferestre peste pagină în locul
   secțiunilor care se desfac, tabele dense cu coloană de stare și coloană de acțiuni, filtrele într-un singur chenar. */
dialog.section-modal { width:min(40rem, 94vw); max-height:88vh; padding:0; border:1px solid hsl(var(--border)); border-radius:var(--radius);
  background:hsl(var(--card)); color:hsl(var(--foreground)); box-shadow:0 18px 48px hsl(222 47% 11% / .28); overflow:hidden; }
dialog.section-modal[open] { display:flex; flex-direction:column; }
dialog.section-modal.section-modal-wide { width:min(62rem, 94vw); }
dialog.section-modal::backdrop { background:hsl(222 47% 11% / .45); }
.section-modal-bar { display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:.7rem 1rem .7rem 1.25rem;
  border-bottom:1px solid hsl(var(--border)); background:hsl(var(--muted) / .45); }
.section-modal-bar h2 { margin:0; font-size:1.05rem; font-weight:650; line-height:1.3; }
/* Runda 6: a long title wraps; «Închide» keeps its width and one line. */
.section-modal-bar > button { flex:none; white-space:nowrap; }
.section-modal-body { padding:1rem 1.25rem 1.25rem; overflow:auto; }
.section-modal-body > :first-child { margin-top:0; }
.cases-page .case-workspace .section-modal-body > :is(.detail-card, section, div) { margin:0; padding:0; border:0; border-radius:0; box-shadow:none; background:transparent; }
/* Runda 5 (QA): a part is set apart only from a part shown before it; a hidden one before it draws no line at the window's top. */
.section-modal-body > :is(.detail-card, section, div):not([hidden]) ~ :is(.detail-card, section, div):not([hidden]) { margin-top:1rem !important; padding-top:1rem !important; border-top:1px solid hsl(var(--border)) !important; }
.case-secondary-disclosure .section-modal-body > section > h4:first-child { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.section-modal-body form.inline-form, .section-modal-body .inline-form { margin:0; }
.section-modal-body .action-disclosure { margin-top:1rem; }
/* The rows that open a window end with «›», not with a chevron that turns. */
.cases-page .dossier-fold > summary::after, .cases-page .case-secondary-disclosure > summary::before { transform:rotate(-45deg) !important; }
.cases-page .dossier-fold[open] > summary, .cases-page .case-secondary-disclosure[open] > summary { background:hsl(var(--muted) / .5); }
/* An action that opens a window is an outlined button, without the ▾ of a fold. */
.action-disclosure > summary::after, .action-disclosure[open] > summary::after { content:none !important; }
.action-disclosure[open] > summary { margin-bottom:0; }

/* Tabele: titlurile coloanelor mici, cu majuscule; rânduri joase cu o linie între ele; acțiunile la dreapta, pe un rând. */
.workspace table.data-table { width:100%; border-collapse:collapse; font-size:.875rem; }
.workspace table.data-table thead th { padding:.6rem .75rem; border-bottom:1px solid hsl(var(--border)); background:hsl(var(--muted) / .7);
  color:hsl(var(--muted-foreground)); font-size:.7rem; font-weight:650; letter-spacing:.05em; text-transform:uppercase; text-align:left; white-space:nowrap; vertical-align:bottom; }
.workspace table.data-table tbody td { padding:.55rem .75rem; border-bottom:1px solid hsl(var(--border)); vertical-align:middle; }
.workspace table.data-table tbody tr:hover > td { background:hsl(var(--muted) / .4); }
.workspace table.data-table th.col-actions, .workspace table.data-table td.col-actions { text-align:right; white-space:nowrap; width:1%; }
.workspace table.data-table td.col-nowrap, .workspace table.data-table th.col-nowrap { white-space:nowrap; }
.workspace table.data-table .cell-sub { display:block; margin-top:.1rem; color:hsl(var(--muted-foreground)); font-size:.78rem; }
.row-actions { display:inline-flex; flex-wrap:wrap; justify-content:flex-end; align-items:center; gap:.35rem; }
.workspace .row-actions :is(a, button):is(.secondary, .act-btn, .link-button, .button-link), .workspace .act-btn {
  display:inline-flex; align-items:center; gap:.35rem; min-height:32px; padding:.25rem .65rem; border:1px solid hsl(var(--input)); border-radius:calc(var(--radius) - 2px);
  background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.8125rem; font-weight:500; line-height:1.2; text-decoration:none; white-space:nowrap; cursor:pointer; }
.workspace .row-actions :is(a, button):is(.secondary, .act-btn, .link-button, .button-link):hover, .workspace .act-btn:hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); background:hsl(var(--primary) / .06); }
.workspace .row-actions .act-btn.act-primary { border-color:hsl(var(--primary)); background:hsl(var(--primary)); color:hsl(var(--primary-foreground)); }
.workspace .row-actions .act-btn.act-primary:hover { background:hsl(var(--primary-hover)); color:hsl(var(--primary-foreground)); }
.act-btn svg, .row-actions svg { flex:none; width:15px; height:15px; }

/* Filtrele: un chenar cu toate câmpurile pe un rând și «Resetează» la capăt. */
.filter-card { margin:0 0 1rem; padding:.75rem 1rem 1rem; border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); }
.filter-card-title { margin:0 0 .5rem; padding-left:.5rem; border-left:3px solid hsl(var(--sidebar-primary)); color:hsl(var(--muted-foreground)); font-size:.7rem; font-weight:650; letter-spacing:.06em; text-transform:uppercase; }

/* Lista dosarelor ca registru: Nr. | Data | Solicitant | Obiectul | Stare | Termen | Responsabil | Acțiuni. */
.cases-page .case-filter-card .case-filter-grid { grid-template-columns:minmax(220px,2fr) repeat(auto-fit,minmax(150px,1fr)); margin:0; }
.cases-page .case-filter-card .list-toolbar { display:flex; justify-content:flex-end; margin:.5rem 0 0; }
.cases-page .case-filter-card .list-toolbar:not(:has(> :not([hidden]))) { display:none; }
.cases-page .case-filter-card ~ .case-deadline-help, .cases-page .case-deadline-help { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.case-register { table-layout:auto; }
.case-register .case-col-number { width:6.5rem; }
.case-register .case-col-date { width:6.5rem; }
.case-register .case-col-applicant { width:18%; }
.case-register .case-col-state { width:9.5rem; }
.case-register .case-col-due { width:8rem; }
.case-register .case-col-responsible { width:8rem; }
.case-register td.case-col-applicant, .case-register td.case-col-object { overflow-wrap:anywhere; }
.case-register .case-number-value { font-weight:650; font-variant-numeric:tabular-nums; }
.case-register .case-name-line { font-weight:600; }
.case-register .case-object-line { display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; line-clamp:2; overflow:hidden; }
.case-register.no-deadlines .case-col-due, .case-register.no-responsible .case-col-responsible { display:none; }
.case-register tr.case-row { cursor:pointer; }
.case-register .case-due { display:block; font-variant-numeric:tabular-nums; }
.case-register .case-due.due-overdue { color:hsl(var(--tone-problem-fg)); font-weight:600; }
.case-register .case-due.due-soon { color:hsl(var(--tone-attn-fg)); font-weight:600; }
.case-register .case-due.due-reason { white-space:normal; color:hsl(var(--muted-foreground)); font-size:.78rem; }
.case-register .due-note { display:inline; font-size:.75rem; color:hsl(var(--muted-foreground)); }
.case-register .due-note + .due-note::before { content:' · '; }
.case-register .due-note-overdue { color:hsl(var(--tone-problem-fg)); font-weight:600; }
.case-register .due-note-soon { color:hsl(var(--tone-attn-fg)); font-weight:600; }
/* Runda 14.11 (D-06): the list fits its frame at every width, with «Acțiuni» whole (at 1280 and 1024 px it was 10 px wider than the frame): from 901 to 1365 px the cells are a little narrower;
   the object, which gives way, already breaks in two lines. */
@media (min-width:901px) and (max-width:1365px) { .workspace table.data-table.case-register :is(thead th, tbody td) { padding-left:.5rem; padding-right:.5rem; } }
@media (max-width:900px) {
  .case-register thead { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
  .case-register, .case-register tbody, .case-register tr, .case-register td { display:block; width:auto !important; }
  .case-register tr.case-row { display:grid; grid-template-columns:auto auto 1fr; gap:.2rem .75rem; padding:.65rem .75rem; border-bottom:1px solid hsl(var(--border)); }
  .case-register tr.case-row td { padding:0; border:0; }
  .case-register td.case-col-applicant, .case-register td.case-col-object { grid-column:1 / -1; }
  .case-register td.case-col-number { grid-row:1; }
  .case-register td.case-col-date { grid-row:1; color:hsl(var(--muted-foreground)); }
  .case-register td.case-col-state { grid-row:1; justify-self:end; }
  .case-register td.case-col-due::before, .case-register td.case-col-responsible::before { content:attr(data-label) ': '; color:hsl(var(--muted-foreground)); font-size:.78rem; }
  .case-register td.case-col-due .case-due { display:inline; }
  .case-register td.col-actions { grid-column:1 / -1; text-align:left; }
  .case-register td.col-actions .row-actions { justify-content:flex-start; }
}
/* Pages of lists and settings use the width of the screen, as a desktop register; the form editors keep their column. */
@media (min-width:1024px) { .cases-page .workspace, .planning-page .workspace, .workspace.settings-page { max-width:min(1680px, 100%); } }
.workspace .row-actions .act-btn.act-primary.row-open { border-color:hsl(var(--input)); background:hsl(var(--card)); color:hsl(var(--foreground)); }
.workspace .row-actions .act-btn.act-primary.row-open:hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); background:hsl(var(--primary) / .06); }
.case-register tr.case-row:hover .act-btn.row-open { border-color:hsl(var(--primary)); color:hsl(var(--primary)); }

/* Registrul documentelor: Nr. | Data | Document | Solicitant | Dosar | Stare | Acțiuni. */
.cases-page .registry-filter-card .registry-filter-grid { grid-template-columns:minmax(220px,2fr) repeat(auto-fit,minmax(13rem,1fr)); margin:0; } /* Runda 7.11 (N7): «Cerere sau documente anexate» is read whole */
.registry-register th { width:auto !important; }
.registry-register .registry-number { font-weight:650; font-variant-numeric:tabular-nums; }
.registry-register .registry-entry-title { font-weight:550; }
.registry-register .registry-act-notes { color:hsl(0 70% 38%); }
.registry-register td .doc-actions { margin:0; }
@media (max-width:900px) {
  .registry-register thead { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
  .registry-register, .registry-register tbody, .registry-register tr, .registry-register td { display:block; width:auto !important; }
  .registry-register tr.registry-row { display:grid; grid-template-columns:auto 1fr auto; gap:.2rem .75rem; padding:.65rem .75rem; border-bottom:1px solid hsl(var(--border)); }
  .registry-register tr.registry-row td { padding:0; border:0; }
  .registry-register td:nth-child(2) { color:hsl(var(--muted-foreground)); }
  .registry-register td:nth-child(3), .registry-register td:nth-child(4) { grid-column:1 / -1; }
  .registry-register td.col-actions { grid-column:1 / -1; text-align:left; }
  .registry-register td.col-actions .row-actions { justify-content:flex-start; }
}
.registry-register .registry-case-link { display:inline; margin:0; white-space:nowrap; }
details.section-window > summary::after, details.section-window[open] > summary::after { content:none !important; }
.cases-page .deadline-watch-details.section-window > summary::after, .cases-page .deadline-watch-details.section-window[open] > summary::after { content:'' !important; transform:rotate(-45deg) !important; top:1.2rem !important; }
/* «Dosar nou»: every procedure is in view; the less common ones follow the usual ones, without a fold. */
#wizard-more > summary { display:none; }
#wizard-more > .wizard-procedures { margin-top:.75rem; }
@media (max-width:900px) {
  /* The card of a row on a phone: no cell lines or cell padding of the wide table (stronger than .data-table td). */
  .workspace table.case-register tbody tr.case-row > td, .workspace table.registry-register tbody tr.registry-row > td { padding:0; border:0; background:none; }
  .workspace table.case-register, .workspace table.registry-register { min-width:0; }
  .case-register tr.case-row { grid-template-columns:auto 1fr auto; }
  .case-register td.case-col-date { justify-self:start; }
  .case-register td.case-col-due, .case-register td.case-col-responsible { grid-column:auto; }
  .case-register td.case-col-responsible { grid-column:2 / -1; }
}
@media (max-width:900px) {
  .case-register td.case-col-due .due-note { margin-left:.35rem; }
  .case-register td.case-col-due:has(> .case-due:empty):not(:has(.due-note)) { display:none; }
}
/* A table with no rows yet shows nothing but the button that adds the first row (no lone column headings). */
.workspace table.data-table:has(> tbody:empty):not(:has(> tbody:not(:empty))) { display:none; }
/* In a window, the actions of a section are buttons of one look, without the lines that separated the folds in the page. */
.cases-page .section-modal-body .action-disclosure { margin-top:.75rem; padding-top:0; border-top:0; }
.cases-page .section-modal-body #state-disclosure > summary { padding:.55rem 1rem; border:1px solid hsl(var(--input)); border-radius:calc(var(--radius) - 2px); background:hsl(var(--card)); color:hsl(var(--foreground)); }
.cases-page .section-modal-body #state-disclosure > summary:hover { text-decoration:none; border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); }

/* Telefon (QA runda 4): filtrele pe o coloană (două pentru câmpurile scurte), insignele lungi din antetul dosarului se rup pe
   rânduri, iar tabelele de istoric derulează în cutia lor, fără să taie insignele literă cu literă. */
@media (max-width:700px) {
  .filter-card .filter-grid, .cases-page .case-filter-card .case-filter-grid, .cases-page .registry-filter-card .registry-filter-grid { grid-template-columns:repeat(2, minmax(0,1fr)) !important; }
  .filter-card .filter-grid > .field:first-child { grid-column:1 / -1; }
  .filter-card .filter-grid > .field, .filter-card :is(select, input) { min-width:0; max-width:100%; }
  .filter-card .date-ro-field, .filter-card .date-ro-wrap { min-width:0; }
  .case-detail #detail-meta .state-badge { white-space:normal; text-align:left; max-width:100%; }
  .registers-history-table .state-badge { white-space:nowrap; overflow-wrap:normal; word-break:normal; }
}
/* «Despre registru» opens a window: its button keeps its place in the bar of exports. */
.cases-page .registry-tools > .registry-about.section-window[open] { order:3; flex:0 0 auto; flex-basis:auto; }
/* A cell that says «nothing here» spans its row as a cell of the table, not as a box. */
.workspace table td.empty-state { display:table-cell; }
#numbering-settings .numbering-init .numbering-form { margin-top:0; padding-top:0; border-top:0; }
/* A step form shown in its window: no second frame inside the window. */
dialog.row-dialog form:is(.wizard-inline, .wizard-handover) { margin:0; padding:0; border:0; border-radius:0; background:transparent; box-shadow:none; }
/* On a laptop screen the object keeps a readable width; the short columns take only what they need. */
.case-register .case-col-number { width:5.5rem; }
.case-register .case-col-date { width:6rem; }
.case-register .case-col-applicant { width:16%; }
.case-register .case-col-state { width:auto; white-space:nowrap; }
.case-register .case-col-due, .case-register .case-col-responsible { width:7rem; }
.case-register td.case-col-object { min-width:12rem; }
@media (max-width:1400px) and (min-width:901px) { .case-register thead th, .case-register tbody td { padding-left:.55rem; padding-right:.55rem; } }
/* The applicant and the object keep readable widths; names wrap between words, never inside one. */
.case-register .case-col-applicant { width:auto; }
.case-register td.case-col-applicant { min-width:11rem; overflow-wrap:break-word; }
.case-register td.case-col-object { min-width:13rem; overflow-wrap:break-word; }
.case-register .case-col-state { width:1%; }
.case-register td.case-col-applicant { min-width:9.5rem; }
.case-register td.case-col-object { min-width:11rem; }
/* A laptop screen keeps the whole row in view: the responsible (also a filter) is shown from 1400 px up. */
@media (max-width:1399px) and (min-width:901px) { .case-register .case-col-responsible { display:none; } }
/* Runda 9 (reverificare): a 1024 px window beside the menu keeps «Termen» and «Acțiuni» in view — the request's date (said in the
   dossier too) gives way and the text columns narrow. */
@media (min-width:761px) and (max-width:1180px) {
  .case-register .case-col-date { display:none; }
  .case-register td.case-col-applicant, .case-register td.case-col-object { min-width:6.5rem; }
  .case-register .case-col-state, .case-register .case-col-state .state-badge { white-space:normal; }
  .case-register .case-col-due { width:5.6rem; }
  .case-register .case-col-number { width:4.8rem; }
  .case-register thead th, .case-register tbody td { padding-left:.4rem; padding-right:.4rem; }
}

/* Runda 5 (QA): «Alte acțiuni» is a menu floating under its button, as «Adaugă» in the dossier's heading. */
.case-workspace .wizard-actions .wizard-other-actions[open], .wizard-other-actions[open] { display:block; flex-basis:auto; position:relative; margin-left:auto; padding-top:0; border-top:0; }
@media (max-width:700px) { .case-workspace .wizard-actions .wizard-other-actions[open], .wizard-other-actions[open] { margin-left:0; } }
.case-workspace .wizard-actions .wizard-other-actions[open] > summary { flex:none; }
.wizard-other-menu { position:absolute; right:0; top:calc(100% + .25rem); z-index:20; display:flex; flex-direction:column; align-items:stretch; min-width:16rem; padding:.35rem;
  border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); box-shadow:0 10px 28px hsl(222 47% 11% / .16); }
.wizard-other-menu > :is(button, a) { justify-content:flex-start; width:100%; margin:0 !important; min-height:38px; padding:.4rem .65rem; border:0 !important; border-radius:calc(var(--radius) - 2px);
  background:none !important; color:hsl(var(--foreground)) !important; text-align:left; box-shadow:none !important; font-weight:500; }
.wizard-other-menu > :is(button, a):hover { background:hsl(var(--muted)) !important; }
.wizard-other-menu > :is(button, a).danger, .wizard-other-menu > :is(button, a)[data-danger] { color:hsl(var(--destructive, 0 72% 45%)) !important; }
@media (max-width:900px) {
  /* Runda 5 (QA): on a phone the term and the responsible are each a line of the card, never wider than it. */
  .case-register td.case-col-due, .case-register td.case-col-responsible { grid-column:1 / -1 !important; }
  .case-register tr.case-row > td { min-width:0; }
  .case-register td.case-col-state { justify-self:end; max-width:100%; }
}
/* Runda 5 (QA): badges in the register history are compact, as in the other tables; the line under them stays small. */
.registers-history-table td .state-badge { display:inline-flex; width:auto; max-width:100%; }
.registers-history-table td > .state-badge + span { display:block; margin-top:.15rem; }
.workspace .row-actions .act-btn.danger, .workspace .row-actions button.danger.act-btn { color:hsl(0 72% 40%); border-color:hsl(0 72% 40% / .45); }

/* Runda 5 (QA): «Dosar nou» in its window: the heading of the section is the window's bar. */
dialog.wizard-window { padding:0; }
dialog.wizard-window > .wizard-start { margin:0; padding:1rem 1.25rem 1.25rem; border:0; box-shadow:none; overflow:auto; max-height:88vh; }
dialog.wizard-window > .wizard-start > .section-heading { position:sticky; top:-1rem; z-index:1; margin:-1rem -1.25rem 1rem; padding:.7rem 1rem .7rem 1.25rem; border-bottom:1px solid hsl(var(--border)); background:hsl(var(--card)); }
dialog.wizard-window > .wizard-start > .section-heading .eyebrow, dialog.wizard-window > .wizard-start > .section-heading .help { display:none; }
dialog.wizard-window #wizard-start-title { margin:0; font-size:1.05rem; }
/* Runda 9.11: the window keeps its top edge from the first step to the second (it was centred, so a shorter second step moved the title,
   «Închide» and the notice down); the title keeps room for two lines on a phone, so a long request name does not move the bar either. */
dialog.wizard-window[open] { margin-top:6vh; margin-bottom:auto; }
@media (max-width:760px) { dialog.wizard-window #wizard-start-title { display:flex; align-items:center; min-height:2.6em; } }
/* Runda 5 (QA): the register's filters share one width; the two dates are as wide as the other fields. */
@media (min-width:701px) { .cases-page .registry-filter-card .registry-filter-grid { grid-template-columns:repeat(auto-fill, minmax(11.5rem, 1fr)); } .cases-page .registry-filter-card .registry-filter-grid > .registry-main-filter:first-child { grid-column:span 2; } }
/* Runda 5 (QA): «Mențiuni pe actele emise» and «Recepția» are rows like those of «Informații dosar»: the arrow at the right. */
.cases-page .case-secondary-disclosure > summary::before { content:none !important; display:none !important; }
.cases-page .case-secondary-disclosure > summary { display:flex; align-items:center; gap:.3rem .9rem; }
.cases-page .case-secondary-disclosure > summary::after { content:''; order:99; margin-left:auto; margin-right:.25rem; width:.55rem; height:.55rem; flex:none;
  border-right:2px solid hsl(var(--muted-foreground)); border-bottom:2px solid hsl(var(--muted-foreground)); transform:rotate(-45deg); }
/* Runda 5 (QA): on a touch screen the small buttons and links of the rows are big enough for a finger. */
@media (max-width:1023px) {
  .workspace .row-actions :is(a, button), .workspace .act-btn, .wizard-review-link, .wizard-documents-link { min-height:40px; }
  .settings-start a { display:inline-flex; align-items:center; min-height:36px; }
}
/* Runda 5 (QA): «Cerere depusă în altă zi» is a small window; the day chosen is said under the link. */
dialog.request-date-window { width:min(30rem, 94vw); }
dialog.request-date-window .request-date-box { margin:0; }
.request-date-chosen { margin:.25rem 0 0; color:hsl(var(--foreground)); font-weight:500; }
/* Runda 5 (QA): the calendar button shows a calendar a finger and an eye can find. */
.date-ro-open { font-size:1.15rem; line-height:1; }
/* Runda 5 (QA): what is missing is said by the footer's buttons too, on a phone as well. */
:is(#urban-form, #ac-form) > .form-actions .pdf-status[data-has-problems="true"] { display:block !important; flex:1 1 100%; order:-1; margin:0; color:hsl(0 72% 38%); font-size:.8125rem; font-weight:500; }
/* Runda 5 (QA): the actions of a document row stay on one line on a desktop screen. */
@media (min-width:1100px) { #detail-documents-card li.doc-row .doc-actions { flex-wrap:nowrap; justify-content:flex-end; } }
/* Runda 6 (beneficiarii, 29.10): the parts of an address are short rubrics too, four on a row: the county, the locality, the
   village or sector, the street, the number, the postal code, the country, the block, staircase, floor and apartment and the CNP
   (they replace the wider rows of round 5). */
@media (min-width:900px) {
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field:not(.cu-wide):has(> :is(input,select):is([id$="county" i],[id$="locality" i],[id$="village" i],[id$="sector" i],[id$="street" i],[id$="streetnumber" i],[id$="country" i],[id$="postcode" i],[id$="postalcode" i],[id$="block" i],[id$="building" i],[id$="staircase" i],[id$="entrance" i],[id$="floor" i],[id$="apartment" i],[id$="cnp" i])) { grid-column:span 3; }
}
/* Runda 5 (QA): on a phone the title of the document window may take two lines instead of being cut. */
@media (max-width:700px) { .editor-panel-bar h3 { white-space:normal; display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; line-clamp:2; overflow:hidden; text-overflow:clip; font-size:.95rem; } }

/* Runda 5 (QA): the dossier's form in its window. */
dialog.case-form-window { padding:0; }
dialog.case-form-window > .case-form-panel, dialog.case-form-window > #case-form-panel { margin:0; padding:1rem 1.25rem 1.25rem; border:0; box-shadow:none; overflow:auto; max-height:88vh; }
/* Runda 5 (QA): «Termen notat: 26.11.2026 · 29 zile», with its space. */
.cases-page .case-quick-actions .case-due-left { margin-left:-.4rem; }
/* Runda 5 (QA): a row's window (annexes, handover, a step's form) has the look of every other window. */
dialog.row-dialog.section-modal { width:min(36rem, 94vw); }
dialog.row-dialog .row-dialog-body { max-height:none; }
dialog.row-dialog .row-dialog-body > .form-actions:last-child { margin-top:1rem; }
/* Runda 5 (QA): the opinion's form in its window: the window's title is the form's, not repeated as a legend. */
dialog.case-opinions-window .case-opinions-form > .field-group > legend { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
dialog.case-opinions-window .case-opinions-form > .field-group { margin:0; padding:0; border:0; }
/* Runda 5 (QA): on a phone the opened links of a person's rubric («Preia dintr-o cerere anterioară», «Caută la ANAF…») take their
   own row under the label, one under the other; beside it they covered the label's words. */
@media (max-width:700px) {
  .field > .person-directory-actions.open { grid-column:1 / -1; grid-row:2; justify-self:start; flex-direction:column; align-items:flex-start; margin:0; }
  .field > .person-directory-actions.open > button { justify-content:flex-start; text-align:left; width:auto; align-self:flex-start; }
}
/* Runda 5 (QA): the window's bar already sets its content apart: no line over the first form or the first term of a window. */
.section-modal-body > .inline-form { border-top:0; padding-top:0; }
.section-modal-body .deadline-card:first-of-type { border-top:0; padding-top:0; }
/* Runda 5 (QA): «De corectat / Verificați înainte de…» is a window as the others: bar, scrolling points, its two buttons at the bottom. */
dialog.section-modal.registration-review { width:min(46rem, 94vw); }
dialog.section-modal.registration-review .registration-review-body { flex:1 1 auto; min-height:0; padding:1rem 1.25rem 1.25rem; }
dialog.section-modal.registration-review > .form-actions { flex:none; margin:0; padding:.85rem 1.25rem 1rem; border-top:1px solid hsl(var(--border)); }
dialog.section-modal.registration-review .registration-problems:first-of-type { margin-top:.5rem; }
/* Runda 5 (QA): the bar of «Ce se solicită?» as the bar of the other windows: title and «Închide» on one line, the same shade. */
dialog.wizard-window > .wizard-start > .section-heading { display:flex; align-items:center; justify-content:space-between; gap:1rem; background:linear-gradient(hsl(var(--muted) / .45), hsl(var(--muted) / .45)), hsl(var(--card)); }
dialog.wizard-window > .wizard-start > .section-heading .detail-heading-actions { margin:0; }
/* Runda 7.11 (N1): on a phone too, the title and «Închide» stand on one line, as in the bar of every other window. */
@media (max-width:760px) {
  dialog.wizard-window > .wizard-start > .section-heading { flex-wrap:nowrap; }
  dialog.wizard-window > .wizard-start > .section-heading .detail-heading-actions { width:auto; flex:none; }
  dialog.wizard-window > .wizard-start > .section-heading .detail-heading-actions > button { flex:none; min-width:0; white-space:nowrap; }
}
/* Runda 5 (QA): in a request's window the row of the document's name is hidden; its separating line does not stay alone on top. */
body.embedded:is(.request-mode, .standalone) .form-heading { border-bottom:0; padding:0; margin:0; min-height:0; }
/* Runda 5 (QA): the arrow of a folded group stands on the first line of a title that takes two lines (phone). */
.ac-editor-page details:is(.ac-group, .ac-authority, .ac-rare) > summary { align-items:baseline; }
/* Runda 5 (QA): the dossiers' search is the main filter: two columns wide, so its hint is read whole. */
@media (min-width:701px) { .cases-page .case-filter-card .case-filter-grid > .field:first-child { grid-column:span 2; } }
/* Review (round 5b): «Modifică nota» shows only the transition note of the dossier's framing, with its buttons. */
#case-facts-form[data-only="transition"] > :not(.choice-inline:has(#case-facts-transition), #case-facts-transition-fields, .form-actions, #case-facts-message) { display:none !important; }
#case-facts-form[data-only="transition"] #case-facts-propose { display:none; }
/* Review (round 5b): «Consemnează ▾» of an opinion is a floating menu as «Alte acțiuni»: dark items, the row does not move. */
.case-opinion-menu { position:relative; }
.case-opinion-menu[open] { display:inline-block; }
.case-opinion-menu[open] > .case-opinion-actions { position:absolute; right:0; top:calc(100% + .25rem); z-index:20; display:flex; flex-direction:column; align-items:stretch; gap:0; min-width:15rem; padding:.35rem;
  border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); box-shadow:0 10px 28px hsl(222 47% 11% / .16); }
.case-opinion-menu[open] > .case-opinion-actions > button { justify-content:flex-start; width:100%; min-height:38px; padding:.4rem .65rem; border-radius:calc(var(--radius) - 2px); color:hsl(var(--foreground)); text-decoration:none; text-align:left; font-weight:500; }
.case-opinion-menu[open] > .case-opinion-actions > button:hover { background:hsl(var(--muted)); text-decoration:none; }
/* Review (round 5b): a part of a section («Act de identitate», «Domiciliu») reads under its section («Solicitant»): smaller than it. */
:is(.form-editor-page, .ac-editor-page) #fields .cu-subheading, :is(.form-editor-page, .ac-editor-page) #ac-fields .cu-subheading { font-size:.95rem; font-weight:600; color:hsl(var(--foreground) / .8); }
/* Review (round 5b): on a wide screen the six filters of the dossiers stand on one row (the search is the wider one).
   Runda 9 (reverificare): from 1200 px — a 1366 px laptop beside the menu gets one row too. */
@media (min-width:1200px) {
  .cases-page .case-filter-card .case-filter-grid { grid-template-columns:minmax(0,2fr) repeat(5, minmax(0,1fr)); }
  .cases-page .case-filter-card .case-filter-grid > .field:first-child { grid-column:auto; }
}
/* Review (round 5b): a small form of a section in its own window: the bar says its name, the fieldset adds no frame or legend. */
dialog.section-modal.form-window .section-modal-body > div > fieldset.field-group { margin:0; padding:0; border:0; box-shadow:none; background:transparent; }
dialog.section-modal.form-window .section-modal-body > div > fieldset.field-group > legend { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.module-stopped-note h2 { flex:1 1 100%; margin:0 0 .25rem; font-size:1.5rem; }
/* Review (round 5b): «Preia dintr-o cerere anterioară» with the bar of the other windows; its texts do not touch the table. */
.applicant-reuse-dialog > .section-modal-bar { flex:none; margin:-1.5rem -1.5rem 1rem; }
@media (max-width:480px) { .applicant-reuse-dialog > .section-modal-bar { margin:-1rem -1rem 1rem; } }
.applicant-reuse-dialog .applicant-reuse-preview > p.help { margin:.25rem 0 .75rem; }
/* Review (round 5b): a rubric of a dossier's small form with a problem is framed in red, as in the editors. */
.cases-page :is(input, select, textarea)[aria-invalid="true"] { border-color:hsl(var(--destructive, 0 72% 45%)); box-shadow:0 0 0 1px hsl(var(--destructive, 0 72% 45%) / .35); }
/* Review (round 5b): the small forms in their own window are one column, with no empty cells beside long rubrics. */
dialog.section-modal.form-window .uat-settings-grid { display:grid; grid-template-columns:minmax(0,1fr); gap:.75rem; }
dialog.section-modal.form-window .uat-settings-grid select { max-width:100%; }
/* Runda 11 (beneficiari, 30.10): the rows of a table alternate their colour, so a row is followed easily to its buttons; a hidden
   row does not count. On a phone the rows are cards and keep their own look. Runda 14 (review): a row's header cell (Module, the
   signatories) takes the colour of its row too. */
:root { --zebra: 214 32% 94.5%; }
@media (min-width:701px) {
  .workspace table.data-table > tbody > tr:nth-child(even of :not([hidden])) > :is(td, th) { background:hsl(var(--zebra)); }
  .workspace table.data-table > tbody > tr:hover > :is(td, th) { background:hsl(var(--primary) / .08); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row:nth-child(even of .doc-row:not([hidden])) { background:hsl(var(--zebra)); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row:nth-child(odd of .doc-row:not([hidden])) { background:hsl(var(--card)); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row:hover { background:hsl(var(--primary) / .08); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row:is([data-working], :has(details[open])) { background:hsl(var(--primary) / .1); }
}
/* Runda 11 (beneficiari, 30.10): what is done with the documents stands in one bar above their table; nothing follows the table.
   The sections («Avize și acorduri», «Mențiuni», «Recepția») are buttons of the bar, with their count, and open in a window. */
.cases-page .doc-toolbar { display:flex; flex-wrap:wrap; align-items:center; gap:.5rem; margin:0 0 .75rem; }
.cases-page .doc-toolbar-actions { display:flex; flex-wrap:wrap; align-items:center; gap:.5rem; margin-right:auto; }
.cases-page .doc-toolbar-sections { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:.5rem; margin-left:auto; }
.cases-page .doc-toolbar .action-disclosure { margin:0; padding:0; border:0; background:none; }
.cases-page .doc-toolbar .action-disclosure > summary { min-height:38px; padding:.4rem .9rem; font-size:.875rem; font-weight:550; }
/* Runda 7.11 (N4): one filled button on the page, the step's («Completează certificatul»); «Completează un formular» is outlined like «Atașează alt document scanat». */
.cases-page .doc-toolbar .toolbar-window:has(> section[hidden]) { display:none; }
.toolbar-count { display:inline-flex; align-items:center; min-height:1.3rem; padding:0 .45rem; border-radius:999px; background:hsl(var(--muted)); color:hsl(var(--muted-foreground)); font-size:.75rem; font-weight:600; }
.toolbar-count.toolbar-count-missing { background:hsl(38 92% 92%); color:hsl(30 80% 30%); }
.toolbar-window .section-modal-body > section > h4:first-child { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.toolbar-window .section-modal-body > section.detail-card, .toolbar-window .section-modal-body > section { margin:0; padding:0; border:0; box-shadow:none; background:none; }
.cases-page #detail-documents-card > #detail-forms > h5 { margin-top:.75rem; }
/* Runda 11 (beneficiari, 30.10): the certificate, the authorization and the extensions are the subdossiers of one dossier: tabs
   above it, the open one joined to the page; «+ Continuă cu…» adds the next one; «Toate documentele» lists them all. */
.cases-page .case-chain { display:flex; flex-wrap:wrap; align-items:flex-end; gap:.5rem .75rem; margin:.25rem 0 1rem; padding:0; border:0; border-bottom:2px solid hsl(var(--primary) / .55); border-radius:0; background:none; }
.cases-page .case-chain-label { align-self:center; margin:0; }
.cases-page .case-chain-tabs { display:flex; flex-wrap:wrap; align-items:flex-end; gap:.35rem; }
.cases-page .case-chain-item { min-height:46px; margin-bottom:-2px; padding:.35rem .9rem .4rem; border:1px solid hsl(var(--border)); border-bottom:2px solid hsl(var(--primary) / .55); border-radius:var(--radius) var(--radius) 0 0; background:hsl(var(--muted)); box-shadow:none; }
.cases-page .case-chain-item:hover { background:hsl(var(--primary) / .07); border-color:hsl(var(--primary) / .45); border-bottom-color:hsl(var(--primary) / .55); }
.cases-page .case-chain-item.current { border:2px solid hsl(var(--primary) / .55); border-top:3px solid hsl(var(--primary)); border-bottom:2px solid hsl(var(--card)); background:hsl(var(--card)); box-shadow:none; }
.cases-page .case-chain-item.current .case-chain-title { color:hsl(var(--primary)); }
.cases-page .case-chain-title { font-size:.875rem; }
.cases-page .case-chain-meta { font-size:.75rem; }
.cases-page .case-chain-add { position:relative; align-self:center; margin:0 0 .25rem; padding:0; border:0; background:none; }
.cases-page .case-chain-add > summary { list-style:none; display:inline-flex; align-items:center; min-height:38px; padding:.35rem .85rem; border:1px dashed hsl(var(--primary) / .6); border-radius:var(--radius); color:hsl(var(--primary)); font-size:.875rem; font-weight:600; cursor:pointer; }
.cases-page .case-chain-add > summary::-webkit-details-marker { display:none; }
.cases-page .case-chain-add > summary::before, .cases-page .case-chain-add > summary::after { content:none !important; display:none !important; }
.cases-page .case-chain-add > summary:hover, .cases-page .case-chain-add[open] > summary { background:hsl(var(--primary) / .07); border-style:solid; }
.cases-page .case-chain-add .case-add-options { left:0; right:auto; }
.cases-page .case-chain-add.opens-left .case-add-options { left:auto; right:0; }
.cases-page .case-chain-add .case-add-options { max-width:calc(100vw - 2rem); }
.cases-page .case-chain .chain-documents { align-self:center; margin:0 0 .25rem auto; }
@media (max-width:700px) {
  .cases-page .case-chain { align-items:stretch; border-bottom:0; }
  .cases-page .case-chain-tabs { flex-direction:column; align-items:stretch; width:100%; }
  .cases-page .case-chain-item { margin:0; border-radius:var(--radius); border-bottom:1px solid hsl(var(--border)); }
  .cases-page .case-chain-item.current { border:2px solid hsl(var(--primary)); }
  .cases-page .case-chain .chain-documents { margin:0; }
  .cases-page .case-chain-add { align-self:flex-start; margin:0; }
  .cases-page .doc-toolbar-sections { justify-content:flex-start; margin-left:0; width:100%; }
}
/* Runda 11 (beneficiari, 30.10): the files of a rubric of a request, uploaded from the request: under the rubric, small. */
.request-files { display:flex; flex-wrap:wrap; align-items:center; gap:.3rem .6rem; margin:.2rem 0 .45rem 1.9rem; }
.ac-list > .request-files { margin:.5rem 0 .25rem; }
.request-files-list { display:flex; flex-wrap:wrap; gap:.3rem .5rem; margin:0; padding:0; list-style:none; }
.request-files-list > li { display:inline-flex; align-items:center; gap:.3rem; min-height:28px; padding:.1rem .55rem; border:1px solid hsl(142 45% 78%); border-radius:999px; background:hsl(142 60% 96%); font-size:.8rem; }
.request-files-list > li::before { content:'✓'; color:hsl(142 55% 30%); font-weight:700; }
.request-files-list a { color:hsl(142 55% 22%); text-decoration:none; overflow-wrap:anywhere; }
.request-files-list a:hover { text-decoration:underline; }
.request-files-add.request-files-add { min-height:30px; padding:.15rem .7rem; font-size:.8rem; font-weight:550; }
.request-files-message:empty { display:none; }
.request-files-message { flex-basis:100%; margin:0; font-size:.8rem; }
/* Runda 11 (beneficiari, 30.10): the files of a checklist row, after its name. */
.wizard-check-files { display:inline-flex; flex-wrap:wrap; align-items:center; gap:.25rem .5rem; margin-left:auto; }
.wizard-check-file { display:inline-flex; align-items:center; gap:.25rem; max-width:16rem; min-height:24px; padding:0 .5rem; border:1px solid hsl(142 45% 78%); border-radius:999px; background:hsl(142 60% 96%); color:hsl(142 55% 22%); font-size:.75rem; text-decoration:none; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.wizard-check-file::before { content:'✓'; font-weight:700; }
.wizard-check-upload.link-button { min-height:28px; padding:0 .35rem; font-size:.8rem; }
/* Runda 12 (beneficiari, 31.10): no heading rows break a table. Where a row stands is a coloured label in «Stare» and the row
   takes its colour — a mark at its left edge and a light tint: blue in progress, amber waiting, green issued, grey ended, violet a
   request started. Runda 14 (beneficiari, 31.10: «nu știu de ce apar culori diferite»): the rows of one colour do not alternate
   two shades; a thin line parts them. A row in work is light blue, like its label. Tables without stages keep their zebra. */
:root { --stage-active: 221 83% 53%; --stage-waiting: 36 92% 50%; --stage-done: 145 60% 36%; --stage-ended: 220 9% 62%; --stage-draft: 262 60% 58%; }
.stage-row { --row-mark: var(--stage-active); --row-ink: 221 72% 36%; }
.stage-row.stage-active { --row-bg: 218 95% 97.4%; }
.stage-row.stage-waiting { --row-mark: var(--stage-waiting); --row-ink: 30 85% 28%; --row-bg: 45 100% 96.5%; }
.stage-row.stage-done { --row-mark: var(--stage-done); --row-ink: 145 60% 24%; --row-bg: 140 50% 96.5%; }
.stage-row.stage-ended { --row-mark: var(--stage-ended); --row-ink: 220 10% 32%; --row-bg: 220 14% 97.5%; }
.stage-row.stage-draft { --row-mark: var(--stage-draft); --row-ink: 262 50% 38%; --row-bg: 262 90% 97.5%; }
@media (min-width:701px) {
  .workspace table.data-table > tbody > tr.stage-row > td { background:hsl(var(--row-bg, var(--card))); }
  /* the even rows too: the zebra of the plain tables does not reach them */
  .workspace table.data-table > tbody > tr.stage-row:nth-child(even of :not([hidden])) > td { background:hsl(var(--row-bg, var(--card))); }
  .workspace table.data-table > tbody > tr.stage-row > td { border-bottom-color:hsl(var(--row-mark) / .22); }
  .workspace table.data-table > tbody > tr.stage-row:nth-child(n of :not([hidden])):hover > td { background:hsl(var(--row-mark) / .14); }
  .workspace table.data-table > tbody > tr.stage-row > td:first-child { box-shadow:inset 4px 0 0 hsl(var(--row-mark)); }
}
@media (max-width:900px) {
  .case-register tr.case-row.stage-row { background:hsl(var(--row-bg, var(--card))); box-shadow:inset 4px 0 0 hsl(var(--row-mark)); }
  .workspace .case-register tr.case-row.stage-row > td { background:transparent !important; box-shadow:none !important; }
}
.workspace .stage-badge { font-weight:650; }
.workspace .stage-badge.state-active { background:hsl(221 83% 95%); border-color:hsl(221 70% 80%); color:hsl(221 72% 36%); }
.workspace .state-badge.stage-badge.state-draft:not(.state-active):not(.state-waiting):not(.state-ended) { background:hsl(262 85% 95%); border-color:hsl(262 55% 80%); color:hsl(262 50% 38%); }
.workspace .stage-badge.state-ended { background:hsl(220 14% 93%); border-color:hsl(220 10% 80%); color:hsl(220 10% 32%); }
.case-register .case-stage-note { display:block; margin-top:.15rem; }
.case-register tr.stage-ended > td { color:hsl(var(--muted-foreground)); }
.case-register tr.stage-ended .case-name-line { font-weight:500; }
/* The documents of a dossier: one table — the request blue, the act green, a document in work amber, a file plain — with the
   request's and the act's names larger. The parts of the table follow without bands between them. */
.cases-page #detail-documents-card li.doc-row { --row-mark: transparent; }
.cases-page #detail-documents-card li.doc-row.doc-tone-request { --row-mark: var(--stage-active); --row-bg: 221 90% 97.5%; }
.cases-page #detail-documents-card li.doc-row.doc-tone-act { --row-mark: var(--stage-done); --row-bg: 140 50% 96.5%; }
.cases-page #detail-documents-card li.doc-row.doc-tone-draft { --row-mark: var(--stage-waiting); --row-bg: 45 100% 96.5%; }
.cases-page #detail-documents-card li.doc-row.doc-tone-support { --row-mark: 199 70% 45%; }
.cases-page #detail-documents-card li.doc-row.doc-tone-file { --row-mark: 220 12% 78%; }
.cases-page #detail-documents-card li.doc-row.doc-tone-ended { --row-mark: var(--stage-ended); }
.cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row[class*="doc-tone-"] { background:hsl(var(--row-bg, var(--card))); box-shadow:inset 4px 0 0 hsl(var(--row-mark)); }
@media (min-width:701px) {
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row[class*="doc-tone-"]:nth-child(n of .doc-row:not([hidden])) { background:hsl(var(--row-bg, var(--card))); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row[class*="doc-tone-"]:nth-child(even of .doc-row:not([hidden])) { background:hsl(var(--row-bg, var(--card))); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row[class*="doc-tone-"]:nth-child(n of .doc-row:not([hidden])):hover { background:hsl(var(--primary) / .09); }
  .cases-page #detail-documents-card :is(.doc-list, .form-list) > li.doc-row[class*="doc-tone-"]:nth-child(n of .doc-row:not([hidden])):is([data-working], :has(details[open])) { background:hsl(var(--primary) / .12); }
}
.cases-page #detail-documents-card li.doc-row:is(.doc-tone-request, .doc-tone-act, .doc-tone-draft) .doc-title { font-size:.97rem; font-weight:700; }
.cases-page #detail-documents-card li.doc-row.doc-tone-request .doc-title { color:hsl(221 72% 30%); }
.cases-page #detail-documents-card li.doc-row.doc-tone-act .doc-title { color:hsl(145 62% 21%); }
.cases-page #detail-documents-card li.doc-row:is(.doc-tone-file, .doc-tone-ended) .doc-title { font-weight:500; }
.cases-page #detail-documents-card :is(.doc-list, .form-list) { margin:0; }
.cases-page #detail-documents-card .act-versions, .cases-page #detail-documents-card .attachment-list-section { margin:0; padding:0; border:0; }
#detail-documents-card :is(#detail-forms, .attachment-list-section, .act-versions) > h5.visually-hidden { margin:0; padding:0; border:0; }
/* «Toate documentele»: the subdossier is the first column, a coloured label; its rows keep its colour at their edge. */
.chain-documents-table tr.chain-tone-1 { --row-mark: var(--stage-done); --row-ink: 145 60% 24%; }
.chain-documents-table tr.chain-tone-2 { --row-mark: var(--stage-draft); --row-ink: 262 50% 38%; }
.chain-documents-table tr.chain-tone-3 { --row-mark: var(--stage-waiting); --row-ink: 30 85% 28%; }
.chain-documents-table .chain-col-subdossier { white-space:nowrap; }
.chain-documents-table .chain-subdossier { display:inline-block; padding:.1rem .55rem; border-radius:999px; background:hsl(var(--row-mark) / .13); color:hsl(var(--row-ink)); font-size:.8rem; font-weight:650; text-decoration:none; }
.chain-documents-table .chain-subdossier:hover { text-decoration:underline; }
.chain-documents-table .chain-col-subdossier .cell-sub { display:block; margin-top:.1rem; }
.chain-documents-table tr:not(.chain-file) .chain-col-title { font-weight:650; }
/* The other tables (registers' history, documentations, texts, fees, accounts, numbering): the edge of a row takes the colour of
   its state label, so the tables of the whole application read alike. */
@media (min-width:701px) {
  .workspace table.data-table > tbody > tr:not(.stage-row):has(> td .state-badge.state-active) > td:first-child { box-shadow:inset 4px 0 0 hsl(var(--stage-active)); }
  .workspace table.data-table > tbody > tr:not(.stage-row):has(> td .state-badge.state-done) > td:first-child { box-shadow:inset 4px 0 0 hsl(var(--stage-done)); }
  .workspace table.data-table > tbody > tr:not(.stage-row):has(> td .state-badge.state-ended) > td:first-child { box-shadow:inset 4px 0 0 hsl(var(--stage-ended)); }
  .workspace table.data-table > tbody > tr:not(.stage-row):has(> td .state-badge.state-waiting) > td:first-child { box-shadow:inset 4px 0 0 hsl(var(--stage-waiting)); }
  .workspace table.data-table > tbody > tr:not(.stage-row):has(> td .state-badge.state-rejected) > td:first-child { box-shadow:inset 4px 0 0 hsl(0 72% 50%); }
}
/* Runda 12 (QA): a stage label stays on one line on a wide screen; between 761 and 1180 px it may take two, as a tag with small corners
   (the table must fit). A grey label keeps its pill on a grey row. */
.workspace .case-register td.case-col-state .stage-badge { white-space:nowrap; }
@media (min-width:761px) and (max-width:1180px) { .workspace .case-register td.case-col-state .stage-badge { white-space:normal; border-radius:.45rem; padding:.15rem .45rem; line-height:1.25; font-size:.74rem; text-align:left; } }
@media (min-width:701px) {
  .workspace table.data-table > tbody > tr:nth-child(even of :not([hidden])) > td .state-badge:not(.stage-badge):not(.state-waiting):not(.state-done):not(.state-rejected) { background:hsl(var(--card)); border-color:hsl(var(--border)); }
}
/* Runda 12 (QA): on a phone the short line of «Azi» stands for its chips only while they are folded. */
.case-today-toggle[aria-expanded="true"] .case-today-glance { display:none; }
/* Runda 13 (beneficiari, 31.10): the legal terms are a button of the bar «Azi» (their counts are its chips); their list opens in its
   window as before. On a phone, folding «Azi» folds the button too. */
.cases-page .case-today > .deadline-watch { margin-left:auto; }
.cases-page .case-today > .deadline-watch[hidden] { display:none; }
.cases-page .case-today > .deadline-watch:not([hidden]) + .case-today-print { margin-left:0; }
.case-today:has(> .case-today-toggle[aria-expanded="false"]) > .deadline-watch { display:none; }
.cases-page .case-today .deadline-watch-details { margin:0; border:0; border-radius:0; background:none; }
.cases-page .case-today .deadline-watch-details > summary { position:static; display:inline-flex; align-items:center; gap:.5rem; min-height:32px; padding:.25rem .75rem; border:1px solid hsl(var(--input)); border-radius:var(--radius); background:hsl(var(--card)); }
.cases-page .case-today .deadline-watch-details > summary:hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); }
.cases-page .case-today .deadline-watch-details > summary::after { content:none !important; display:none !important; }
.cases-page .case-today .deadline-watch-details h3#deadline-watch-title { margin:0; font-size:.84rem; font-weight:600; }
.cases-page .case-today :is(.deadline-watch-glance, .deadline-watch-term-counts, .deadline-watch-count-separator) { display:none !important; }
.cases-page .case-today .deadline-watch-note-counts { padding-left:0; border-left:0; font-size:.8rem; }
@media (max-width:600px) { .cases-page .case-today .deadline-watch-details > summary { min-height:44px; } }
/* The filters used rarely wait in «Mai multe filtre», a window; the button says how many are on. */
.cases-page .case-filter-grid > .case-more-filters { align-self:end; margin:0; padding:0; border:0; background:none; }
.cases-page .case-more-filters > summary { list-style:none; display:inline-flex; align-items:center; gap:.45rem; min-height:44px; padding:.4rem .9rem; border:1px solid hsl(var(--input)); border-radius:var(--radius); background:hsl(var(--card)); color:hsl(var(--foreground)); font-weight:550; white-space:nowrap; cursor:pointer; }
.cases-page .case-more-filters > summary::-webkit-details-marker { display:none; }
.cases-page .case-more-filters > summary::before, .cases-page .case-more-filters > summary::after { content:none !important; display:none !important; }
.cases-page .case-more-filters > summary:hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); }
.cases-page .case-more-filters .toolbar-count { background:hsl(var(--primary)); color:hsl(var(--primary-foreground, 0 0% 100%)); }
.cases-page .case-more-grid { display:grid; grid-template-columns:minmax(0,1fr); gap:.75rem; width:min(26rem, 80vw); margin:0; }
.cases-page .case-more-grid select, .cases-page .case-more-grid input { width:100%; }
@media (min-width:901px) { .cases-page .case-filter-card .case-filter-grid { grid-template-columns:minmax(0,2.2fr) minmax(0,1fr) minmax(0,1.2fr) auto; } }
/* An empty transition note has no row in «Informații dosar». */
.dossier-fold[hidden] { display:none !important; }
/* The step's term in one quiet line; «?» holds the rest of the rule. */
.wizard-term { display:flex; align-items:center; gap:.4rem; margin:.25rem 0 .5rem; color:hsl(var(--muted-foreground)); }
.workspace button.help-tip { display:inline-grid; place-items:center; flex:none; width:1.35rem; height:1.35rem; min-height:0; min-width:0; padding:0; border:1px solid hsl(var(--border)); border-radius:50%; background:hsl(var(--card)); color:hsl(var(--muted-foreground)); font-size:.75rem; font-weight:700; line-height:1; cursor:help; }
.workspace button.help-tip:hover, .workspace button.help-tip:focus-visible { border-color:hsl(var(--primary)); color:hsl(var(--primary)); }
/* Registre: the four ways of exporting in one menu «Exportă». */
.cases-page .registry-export-menu { position:relative; margin:0; padding:0; border:0; background:none; }
.cases-page .registry-export-menu > summary { list-style:none; display:inline-flex; align-items:center; gap:.4rem; min-height:40px; padding:.4rem .9rem; border:1px solid hsl(var(--input)); border-radius:var(--radius); background:hsl(var(--card)); font-weight:550; cursor:pointer; }
.cases-page .registry-export-menu > summary::-webkit-details-marker { display:none; }
.cases-page .registry-export-menu > summary::before { content:none !important; display:none !important; }
.cases-page .browse-summary > .registry-export-row { margin-left:auto; }
.cases-page .registry-export-menu > summary::after { content:''; width:.4rem; height:.4rem; border-right:2px solid currentColor; border-bottom:2px solid currentColor; transform:translateY(-.1rem) rotate(45deg); }
.cases-page .registry-export-menu .case-add-options { right:0; padding:.3rem; border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); box-shadow:0 8px 24px hsl(220 30% 20% / .14); }
.cases-page .registry-export-menu .case-add-options > :is(a, button) { display:flex; align-items:center; justify-content:flex-start; width:100%; min-height:38px; margin:0; padding:.4rem .7rem; border:0; border-radius:calc(var(--radius) - 2px); background:none; box-shadow:none; text-align:left; text-decoration:none; color:hsl(var(--foreground)); font-size:.875rem; font-weight:500; }
.cases-page .registry-export-menu .case-add-options > :is(a, button):hover { background:hsl(var(--muted)); }
.cases-page .registry-filter-grid > .case-more-filters { align-self:end; }
/* Runda 14 (beneficiari, 31.10): the two panels of a dossier are framed more clearly, each with its title in the frame —
   «Pași de urmat» (the steps, the current step's card) and «Documentele dosarului». */
:root { --panel-edge: 220 16% 76%; }
.cases-page .panel-framed { position:relative; margin:1.6rem 0 1rem; padding:1.4rem 1rem 1rem; border:2px solid hsl(var(--panel-edge)); border-radius:12px; background:hsl(var(--card)); }
.cases-page h4.panel-legend:is(#steps-legend, #documents-legend) { position:absolute; top:0; left:.9rem; z-index:1; max-width:calc(100% - 1.8rem); margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; letter-spacing:0; text-transform:none; }
.cases-page .case-current-step.panel-framed > .case-wizard { margin:0; }
.cases-page .case-current-step.panel-framed .wizard-body { padding:.35rem 0 0; border:0; border-radius:0; background:none; }
.cases-page .case-current-step.panel-framed > .case-next-step:not([hidden]) { margin:.75rem 0 0; }
/* With nothing to show (no step, no note), the frame of the steps is not drawn. */
.cases-page .case-current-step.panel-framed:not(:has(.wizard-steps, .wizard-body)):not(:has(> .case-next-step:not([hidden]))) { display:none; }
@media (max-width:600px) { .cases-page .panel-framed { padding:1.25rem .7rem .7rem; } .cases-page h4.panel-legend:is(#steps-legend, #documents-legend) { left:.6rem; font-size:.8rem; } }
/* The object of an investment's row: its subdossiers, numbered, in order. */
.workspace table.data-table ol.case-investment { margin:.3rem 0 0; padding-left:1.25rem; list-style:decimal; }
.workspace table.data-table ol.case-investment > li { margin:0; padding:0; line-height:1.35; }
/* Runda 15 (31.10, «Termene legale de urmărit e deplasat în sus»): what stands on one line is aligned — the bar «Azi» keeps no
   margins of its own inside it, the pager's four buttons look alike, the fields and the buttons of a table row are one height. */
/* The page line under the count is for the focus after a page change: it shows only while it holds the focus. */
/* Runda 18 (review in the browser): the line stays while the page is shown, not only while it holds the focus — on a click in the
   table head it would vanish under the mouse, the head would move up and the click would be lost. */
:is(#case-page-summary, #registry-page-summary).visually-hidden:is(:focus, .page-summary-shown) { position:static !important; width:auto; height:auto; overflow:visible; clip-path:none; white-space:normal; margin:.25rem 0; color:hsl(var(--muted-foreground)); font-size:.85rem; }
.cases-page .case-today > * { margin-block:0; }
.cases-page .case-today > .case-today-toggle { align-items:center; }
@media (min-width:701px) {
  body .workspace .browse-pagination > button { min-height:36px; min-width:36px; padding:.25rem .8rem; border:1px solid hsl(var(--input)); border-radius:var(--radius); background:hsl(var(--card)); box-shadow:none; color:hsl(var(--foreground)); font-weight:500; }
  body .workspace .browse-pagination > button:not(:disabled):hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); }
  body .workspace .browse-pagination > button:disabled { color:hsl(var(--muted-foreground)); background:hsl(var(--muted) / .5); }
  .workspace table.data-table td > :is(input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]), select) { min-height:36px; height:36px; padding-block:.25rem; }
  .workspace table.data-table tr:has(> td > :is(input:not([type="checkbox"]):not([type="radio"]), select)) td :is(button, .act-btn) { min-height:36px; }
}
/* On a phone a link drawn as a button is the 44px target its neighbouring buttons are. */
@media (max-width:600px) { .workspace :is(a.link-button, a.act-btn, a.secondary), .workspace #detail-documents-card li.doc-row > .doc-actions > a { min-height:44px; } }
/* The «+ Continuă cu…» after the subdossiers' tabs stands as one of them: their height, on their line. */
@media (min-width:701px) {
  .cases-page .case-chain .chain-documents { margin-bottom:0; }/* «Toate documentele», centred on the tabs' line */
  .cases-page .case-chain-tabs > .case-chain-add { align-self:stretch; display:flex; margin:0 0 -2px; }
  .cases-page .case-chain-tabs > .case-chain-add > summary { min-height:0; height:100%; border-radius:var(--radius) var(--radius) 0 0; }
}
/* On a narrow screen a document row reads alike: «Nr.» and «Data» above their values, «Editează documentul» a button as on a desktop. */
@media (max-width:760px) {
  #detail-documents-card li.doc-row :is(.doc-number, .doc-date)::before { display:block; }
  .cases-page #detail-documents-card li.doc-row > .doc-actions > a.doc-open { padding-inline:.75rem; border-color:hsl(var(--input)); }
}

/* Runda 17 (01.11, «acolo unde ai descărca un document e utilă și o vizualizare»): a PDF or an image in a window over the page,
   «Descarcă» by «Închide» in its bar. The window takes almost the whole screen; the file fills it (an image is fitted, a PDF scrolls itself). */
dialog.section-modal.file-view { width:min(72rem, 96vw); height:92vh; max-height:92vh; }
dialog.section-modal.file-view .file-view-body { flex:1 1 auto; min-height:0; display:flex; padding:0; overflow:auto; background:hsl(var(--muted) / .35); }
dialog.section-modal.file-view .file-view-body > p { margin:1rem 1.25rem; }
dialog.section-modal.file-view .file-view-body > p.inline-error { color:hsl(var(--danger)); }
/* Runda 22.11 (dosar, 8): a text window is as tall as its text («fit-content»: with «auto» the open dialog stretches up to its maximum height) */
dialog.section-modal.file-view.file-view-text-window { width:min(36rem, 94vw); height:fit-content; max-height:80vh; }
dialog.section-modal.file-view.file-view-text-window .file-view-body { flex:0 1 auto; }
dialog.section-modal.file-view .file-view-print-title { display:none; }
dialog.section-modal.file-view .file-view-text { flex:1 1 auto; margin:0; padding:1rem 1.25rem; background:hsl(var(--card)); overflow:auto; }
dialog.section-modal.file-view .file-view-text p { margin:.25rem 0 .6rem; }
dialog.section-modal.file-view .file-view-text ul { margin:.1rem 0 .6rem 1.2rem; padding:0; }
dialog.section-modal.file-view .file-view-frame { flex:1 1 auto; width:100%; min-height:100%; border:0; background:hsl(var(--card)); }
dialog.section-modal.file-view .file-view-image { display:block; max-width:100%; max-height:100%; margin:auto; object-fit:contain; background:hsl(var(--card)); }
dialog.section-modal.file-view .section-modal-bar h2 { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
dialog.section-modal.file-view .file-view-actions { display:flex; flex:none; align-items:center; gap:.5rem; }
dialog.section-modal.file-view .file-view-actions > [hidden] { display:none; }
/* Runda 16.11 (D-3): «Tipărește» in the window of an image prints the image alone. */
@media print {
  body.printing-file-view > *:not(dialog.file-view) { display:none !important; }
  body.printing-file-view dialog.file-view { position:static !important; display:block !important; width:auto !important; max-width:none !important; height:auto !important; max-height:none !important; margin:0 !important; padding:0 !important; border:0 !important; box-shadow:none !important; overflow:visible !important; background:none !important; }
  body.printing-file-view dialog.file-view .section-modal-bar { display:none !important; }
  body.printing-file-view dialog.file-view .file-view-print-title { display:block !important; margin:0 0 .6rem; }
  body.printing-file-view dialog.file-view .file-view-body { display:block !important; padding:0 !important; overflow:visible !important; background:none !important; }
  body.printing-file-view dialog.file-view .file-view-image { display:block !important; max-width:100% !important; max-height:100vh !important; margin:0 auto !important; }
}
@media (max-width:600px) {
  dialog.section-modal.file-view { width:100vw; max-width:100vw; height:100dvh; max-height:100dvh; border-radius:0; }
  dialog.section-modal.file-view.file-view-text-window { height:fit-content; max-height:100dvh; }
}

/* ===== Runda 18 (ședința din 02.11): the forms more compact — every form but the AC request (its own page, .ac-editor-page).
   Rules: documente/context-proiect/reguli-interfata.md. ===== */
/* Every section of a form is a frame with its title on the border, as «Pași de urmat» and «Documentele dosarului»; the title no
   longer takes a row of its own («tabelele cu un chenar bine definit și să aibă un titlu… uniformizează peste tot»). */
.form-editor-page #fields > .field-group { position:relative; margin:1.5rem 0 .9rem; padding:1.2rem .9rem .85rem; border:2px solid hsl(var(--panel-edge)); border-radius:12px; background:hsl(var(--card)); box-shadow:none; }
.form-editor-page #fields > .field-group > legend { float:none; position:absolute; top:0; left:.9rem; z-index:1; width:auto; max-width:calc(100% - 1.8rem); margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; }
.form-editor-page #fields > .field-group > legend ~ * { clear:none; }
.form-editor-page #fields .cu-subheading { margin:.9rem 0 .35rem; padding-top:.6rem; font-size:.85rem; }
.form-editor-page #fields legend + .cu-subheading, .form-editor-page #fields .cu-grid > .cu-subheading:first-child { margin-top:0; padding-top:0; border-top:0; }
/* A rubric as wide as what is written in it (cu-request-ui.js, rubricSpan): a quarter, half, three quarters or the whole row. */
@media (min-width:900px) {
  .form-editor-page .cu-grid { gap:.6rem .9rem; }
  .form-editor-page .cu-grid > .field.cu-span-1.cu-span-1 { grid-column:span 3; }
  .form-editor-page .cu-grid > .field.cu-span-2.cu-span-2 { grid-column:span 6; }
  .form-editor-page .cu-grid > .field.cu-span-3.cu-span-3 { grid-column:span 9; }
  /* Controls of 38 px on a wide screen (44 px on a phone), as in the AC request; the label sits close to its box. */
  .form-editor-page #fields :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]), select) { min-height:38px; height:38px; padding-block:.3rem; }
  .form-editor-page #fields .date-ro-open { min-height:38px; min-width:38px; height:38px; }
  .form-editor-page #fields .field > label { margin-bottom:.2rem; }
  .form-editor-page #fields textarea.text-entry { min-height:38px; }
}
/* A group of choices inside a section is not a second frame: its title reads as a field's label. A group named as its section does
   not repeat the title on screen (it stays the group's name for a screen reader). */
.form-editor-page #fields .cu-choice-group { padding:0; border:0; border-radius:0; background:none; }
.form-editor-page #fields .cu-choice-group > legend { margin:0 0 .25rem; padding:0; font-size:.9rem; font-weight:600; }
.form-editor-page #fields .cu-choice-group.cu-group-as-section > legend { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
/* A few short choices on one row («Teren» · «Construcții»). */
.form-editor-page #fields .cu-choice-group.cu-options-row { display:flex; flex-wrap:wrap; align-items:center; gap:.2rem 1.5rem; }
.form-editor-page #fields .cu-choice-group.cu-options-row > legend { flex:1 1 100%; }
.form-editor-page #fields .cu-choice-group.cu-options-row > :is(.cu-warning, .help, p) { flex:1 1 100%; }
.form-editor-page #fields .cu-choice-group.cu-options-row > .cu-option { margin:0; }
/* A provision («Prevederea 1») is a band of its section, not a frame inside the frame: a thin line above it, its tools on its title
   row, its two rubrics under it. */
.form-editor-page #fields .cu-rule-row { padding:.55rem 0 .2rem; border:0; border-top:1px solid hsl(var(--border)); border-radius:0; }
.form-editor-page #fields .cu-grid > .cu-rule-row:first-child, .form-editor-page #fields legend + .cu-rule-row { border-top:0; padding-top:0; }
.form-editor-page #fields .cu-rule-row > legend.rule-head { margin:0 0 .25rem; font-size:.9rem; }
.form-editor-page #fields .cu-rule-grid { gap:.5rem .9rem; }
/* A long list of short choices in columns. */
.form-editor-page #fields .cu-choice-group.cu-options-columns { display:grid; grid-template-columns:repeat(auto-fill, minmax(17rem, 1fr)); gap:.15rem 1.25rem; align-items:center; }
.form-editor-page #fields .cu-choice-group.cu-options-columns > :not(.cu-option) { grid-column:1 / -1; }
.form-editor-page #fields .cu-choice-group.cu-options-columns > .cu-option { margin:0; }
/* An annex and its «Încarcă fișierul» on one row, the button on the right. */
.form-editor-page #fields .annex-row { display:flex; flex-wrap:wrap; align-items:center; gap:.3rem .75rem; }
.form-editor-page #fields .annex-row > label { flex:1 1 20rem; min-width:0; margin:0; }
.form-editor-page #fields .annex-row > .request-files { flex:0 1 auto; justify-content:flex-end; margin:0; }
/* «Cerere depusă în altă zi?» on the row of the buttons, before «Șterge completările». */
#urban-form > .form-actions > .request-date-choice { order:3; flex:0 1 auto; align-self:center; }
#urban-form > .form-actions > .request-date-choice .request-date-link { min-height:38px; }

/* ===== Runda 18, toată aplicația (cererea de după ședința din 02.11: «design uniform; simplificarea și comprimarea coloanelor și
   a rândurilor la nivelul întregii aplicații, nu doar unde a arătat el»). Același chenar cu titlul pe margine ca «Pași de urmat»
   pe fiecare pagină — filtrele, secțiunile din Setări, panourile; ferestrele pe două coloane; rândurile tabelelor pe o linie;
   butoanele pe rândul lor. Cererea de AC (etapa următoare) rămâne cum este. ===== */
body:not(.ac-editor-page) :is(.filter-card, .settings-start, .deadlines-form, .overview-selection, .overview-picker, .explorer-content):not(dialog *),
body:not(.ac-editor-page) .settings-page fieldset.field-group:not(dialog *):not(#password-form *) {
  position:relative; margin-top:1.5rem; padding-top:1.15rem; border:2px solid hsl(var(--panel-edge)); border-radius:12px; background:hsl(var(--card)); box-shadow:none; }
body:not(.ac-editor-page) :is(.filter-card > .filter-card-title, .settings-start > h4:first-child, .deadlines-form > h4:first-child, .overview-selection-heading > h3, .explorer-placeholder > .explorer-placeholder-lead):not(dialog *),
body:not(.ac-editor-page) .settings-page fieldset.field-group:not(dialog *):not(#password-form *) > legend {
  float:none; position:absolute; top:0; left:.9rem; z-index:1; width:auto; max-width:calc(100% - 1.8rem); margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; letter-spacing:0; text-transform:none; }
body:not(.ac-editor-page) .overview-selection-heading > h3 > #overview-count { margin-left:.35rem; color:hsl(var(--muted-foreground)); font-weight:600; }
body:not(.ac-editor-page) .overview-selection-heading { justify-content:flex-end; }
/* A frame in a frame is not drawn: the filters of «Harta documentațiilor» stand in the frame of the choice, without their own. */
body:not(.ac-editor-page) .overview-picker .filter-card { margin:0 0 var(--space-3); padding:0; border:0; border-radius:0; }
body:not(.ac-editor-page) .overview-picker .filter-card > .filter-card-title { left:-.1rem; transform:translateY(calc(-100% - .55rem)); }
body:not(.ac-editor-page) .explorer-tree-pane { border:2px solid hsl(var(--panel-edge)); border-radius:12px; }
body:not(.ac-editor-page) .explorer-content:has(> #explorer-placeholder:not([hidden])) { padding-top:1.4rem; }
@media (max-width:600px) {
  body:not(.ac-editor-page) :is(.filter-card, .settings-start, .deadlines-form, .overview-selection, .overview-picker, .explorer-content):not(dialog *),
  body:not(.ac-editor-page) .settings-page fieldset.field-group:not(dialog *):not(#password-form *) { padding-left:.7rem; padding-right:.7rem; }
  body:not(.ac-editor-page) :is(.filter-card > .filter-card-title, .settings-start > h4:first-child, .deadlines-form > h4:first-child, .overview-selection-heading > h3, .explorer-placeholder > .explorer-placeholder-lead):not(dialog *),
  body:not(.ac-editor-page) .settings-page fieldset.field-group:not(dialog *):not(#password-form *) > legend { left:.6rem; font-size:.8rem; }
}
/* Windows: the fields two on a row when the window has room (a long text, a checkbox and a list of boxes keep the whole row). */
@media (min-width:701px) {
  dialog.section-modal .section-modal-body :is(.uat-settings-grid, .case-more-grid) { display:grid; grid-template-columns:repeat(auto-fit, minmax(14rem, 1fr)); gap:.75rem 1rem; width:auto; }
  dialog.section-modal .section-modal-body :is(.uat-settings-grid, .case-more-grid) > :is(.field:has(textarea), .checkbox-field, .field-full, fieldset, .help, p) { grid-column:1 / -1; }
}
/* Settings › Datele UAT: the phone, the e-mail and the seat on one row (the widths table: an address takes half, a phone a quarter). */
@media (min-width:701px) { body .settings-page .uat-form .uat-grid-compact > .field-full:has(#uat-address) { grid-column:auto; } }
/* «Atașează alt document scanat» (Runda 16.11, D-2): the title on a row of its own, the number and the day side by side, then the description; «Alegeți fișierul» and «Atașează» on one row. */
@media (min-width:701px) {
  .cases-page #attachment-form { display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); column-gap:1rem; align-items:end; }
  .cases-page #attachment-form > :is(#attachment-help, label[for="attachment-document"], #attachment-document, label[for="attachment-previous"], #attachment-previous, label[for="attachment-title"], #attachment-title, .attachment-number-date, label[for="attachment-description"], #attachment-description, #attachment-message, label[for="attachment-file"]) { grid-column:1 / -1; }
  .cases-page #attachment-form > .file-picker { grid-column:1; } .cases-page #attachment-form > button[type=submit] { grid-column:2; justify-self:end; }
}
#attachment-form > .attachment-number-date { display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:0 1rem; min-width:0; }
#attachment-form > .attachment-number-date > .field { min-width:0; margin:0; }
#attachment-form > .attachment-number-date[hidden] { display:none; }
@media (max-width:700px) { #attachment-form > .attachment-number-date { grid-template-columns:minmax(0,1fr); } }
.cases-page #attachment-form > #attachment-description { min-height:2.6rem; field-sizing:content; max-height:10rem; }
/* Tables: one line per row where the cell holds a short value. */
.settings-page .audit-when > span { display:inline; }
.settings-page .audit-when .audit-time { margin-left:.4rem; }
.cases-page table.registry-register td[data-label="Nr."] > .registry-number { display:inline; }
.cases-page table.registry-register td[data-label="Nr."] > .cell-sub { display:inline; margin-left:.35rem; }
@media (min-width:901px) { .cases-page table.registry-register .registry-entry-title { display:inline-block; min-width:13.5rem; } }
/* The journal's filters on one row with «Afișează luna» when the column has room; otherwise the checkbox and «Afișează luna» go together
   on a second row (Round 18, P9: the button is never alone). Runda 10.11: the month and the event are read whole at every width (7.11, N7). */
@media (min-width:761px) {
  body .settings-page .filter-card .audit-filters { display:flex; flex-wrap:wrap; align-items:flex-end; gap:var(--space-3); }
  body .settings-page .filter-card .audit-filters > .field:has(> #audit-month) { flex:0 0 11.5rem; min-width:0; }
  body .settings-page .filter-card .audit-filters > .field:has(> #audit-event) { flex:2 1 14rem; min-width:14rem; }
  body .settings-page .filter-card .audit-filters > .field:has(> #audit-account) { flex:1 1 10rem; min-width:10rem; }
  body .settings-page .filter-card .audit-filters .audit-filters-more { display:flex; flex:1 0 auto; flex-wrap:nowrap; align-items:center; justify-content:flex-end; gap:var(--space-3) var(--space-4); }
  body .settings-page .filter-card .audit-filters .audit-downloads { min-width:0; padding-bottom:0; }
  body .settings-page .filter-card .audit-filters .audit-downloads label { white-space:nowrap; }
  body .settings-page .filter-card .audit-filters :is(select, input:not([type=checkbox])) { width:100%; min-width:0; } }
.settings-page .audit-pagination.browse-pagination { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:.45rem; margin:.85rem 0 0; }
.settings-page .audit-pagination.browse-pagination > span { padding:.35rem .5rem; font-size:.85rem; }
/* «Harta imobilului»: the search beside the list of properties, not on a row of its own. */
@media (min-width:701px) { .property-map-picker { grid-template-columns:minmax(0,30rem) auto; align-items:end; column-gap:1rem; max-width:none; } }
/* «Pentru început»: the six steps on two columns. */
@media (min-width:901px) { body:not(.ac-editor-page) .settings-start .settings-start-list { grid-template-columns:repeat(2, minmax(0,1fr)); column-gap:1.5rem; } }
/* A window with headed parts: the thin line goes above each heading, not between a heading and its fields. */
dialog.section-modal .section-modal-body > h4 + :is(div, section) { margin-top:0 !important; padding-top:0 !important; border-top:0 !important; }
dialog.section-modal .section-modal-body > * ~ h4 { margin-top:1rem; padding-top:.75rem; border-top:1px solid hsl(var(--border)); }
/* («.workspace h3:not(#detail-title)» weighs an id: the legend of «Livrări GIS alese» is named by its own id.) */
body:not(.ac-editor-page) .workspace .overview-selection-heading > h3#overview-selection-title { font-size:.85rem; line-height:1.3; }
/* «Foldere»: the search pane is a frame too, «Căutare» on its border. */
body:not(.ac-editor-page) .explorer-tree-pane { padding-top:1.4rem; }
@media (max-width:1100px) { body:not(.ac-editor-page) .explorer-tree-pane { position:relative; } }
body:not(.ac-editor-page) .explorer-tree-pane > .explorer-search > label { position:absolute; top:0; left:.9rem; z-index:1; margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; }
/* A legal term on two rows: its title and state; then the date, its length and «Cum s-a calculat» (open, the steps take the row). */
.deadline-card { display:flex; flex-wrap:wrap; align-items:baseline; column-gap:.75rem; }
.deadline-card > :is(h4, h5, h6) { flex:1 1 100%; }
.deadline-card > :is(.deadline-due, p.help) { flex:0 1 auto; margin:0; }
.deadline-card > details.deadline-lines { flex:0 0 auto; margin:0 0 0 auto; }
.deadline-card > details.deadline-lines[open] { flex:1 1 100%; margin:.25rem 0 0; }
/* «Încadrarea lucrării»: the title, what it is and «Modifică încadrarea» on one row while the change is closed. */
.cases-page #case-facts:not(:has(> details[open])) { display:flex; flex-wrap:wrap; align-items:center; gap:.35rem 1rem; }
.cases-page #case-facts:not(:has(> details[open])) > h4 { margin:0; }
.cases-page #case-facts:not(:has(> details[open])) > .case-facts-summary { flex:1 1 auto; margin:0; }
.cases-page #case-facts:not(:has(> details[open])) > details { margin:0 0 0 auto; }
.cases-page #case-facts:not(:has(> details[open])) > :not(h4, .case-facts-summary, details) { flex:1 1 100%; }
/* On a phone, a card's button stands on a row it shares: «Deschide» by «Responsabil», «Detalii» by the date of the line. */
@media (max-width:900px) {
  .case-register td.case-col-responsible, .case-register.no-responsible td.case-col-due { grid-column:1 / 3 !important; }/* the card stays no wider: min-width:0 (Runda 5) */
  .case-register td.col-actions { grid-column:3; align-self:end; text-align:right; }
  .case-register td.col-actions .row-actions { justify-content:flex-end; }
}
@media (max-width:600px) {
  #audit-settings table.audit-table tr { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:.75rem; align-items:center; }
  #audit-settings table.audit-table tr > td { grid-column:1; }
  #audit-settings table.audit-table tr > td.audit-event-details { grid-column:2; grid-row:1; }
  #audit-settings table.audit-table tr > td.audit-event-details::before { content:none; }
  #audit-settings table.audit-table tr > td.audit-object-empty { display:none; }
}
@media (max-width:900px) {
  .registry-register td.col-actions { grid-column:3; align-self:center; text-align:right; }
  .registry-register td.col-actions .row-actions { justify-content:flex-end; }
}
/* «Documentație nouă»: the type a quarter of the row and the name the rest; the short data four on a row; the notes start on one row. */
@media (min-width:1101px) {
  .planning-page dialog .planning-form-grid, .planning-page .planning-form-grid { grid-template-columns:repeat(4, minmax(0,1fr)); }
  .planning-page .planning-form-main > .field:has(#planning-title-field) { grid-column:span 3; }
  .planning-page .planning-form-grid > .field:has(:is(#planning-location, #planning-planner)) { grid-column:span 2; }
}
.planning-page .planning-form-grid textarea#planning-notes { min-height:2.6rem; field-sizing:content; max-height:12rem; }
/* F_CU_07_0: «Elimină rândul» on the row of its provision, beside its two rubrics. */
@media (min-width:701px) {
  .form-editor-page #fields .cu-rule-row:has(> button.secondary) { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:.75rem; align-items:end; }
  .form-editor-page #fields .cu-rule-row:has(> button.secondary) > .cu-rule-grid { grid-column:1; min-width:0; }
  .form-editor-page #fields .cu-rule-row:has(> button.secondary) > button.secondary { grid-column:2; margin:0 0 .1rem; }
}
/* F_A_03, «Avizul N»: the classification and the name side by side; the request and the clarification half a row each (number and
   date a quarter); the term a quarter. */
@media (min-width:900px) {
  .form-editor-page [data-agreement-row] > .cu-grid > .field.cu-wide:has(> select[id^="agreement-classification-"]) { grid-column:span 6; }
  .form-editor-page [data-agreement-row] > .cu-grid > fieldset.cu-choice-group:has(> .cu-grid) { grid-column:span 6; }
  .form-editor-page [data-agreement-row] > .cu-grid > fieldset.cu-choice-group > .cu-grid { grid-template-columns:repeat(2, minmax(0,1fr)); }
  .form-editor-page [data-agreement-row] > .cu-grid > fieldset.cu-choice-group > .cu-grid > .field { grid-column:auto; }
}

/* ===== Runda 18, verificarea de uniformitate (03.11.2026): what the audit of every page and window found. ===== */
/* Two or more actions of a part, one after another, stand on one row while closed («Schimbă manual starea · Consemnează comunicarea»). */
body:not(.ac-editor-page) :has(> details.action-disclosure:not([open]) + details.action-disclosure:not([open])):not(:has(> details.action-disclosure[open])) {
  display:flex; flex-wrap:wrap; align-items:center; gap:.5rem .75rem; }
body:not(.ac-editor-page) :has(> details.action-disclosure:not([open]) + details.action-disclosure:not([open])):not(:has(> details.action-disclosure[open])) > :not(details.action-disclosure) { flex:1 1 100%; }
body:not(.ac-editor-page) :has(> details.action-disclosure:not([open]) + details.action-disclosure:not([open])):not(:has(> details.action-disclosure[open])) > details.action-disclosure { flex:0 0 auto; margin:0; padding:0; border:0; }
/* «Verificări»: «Verificări specifice» and «Adaugă o verificare» on one row while nothing is recorded or open. */
dialog.section-modal .section-modal-body:has(> #case-compliance):has(> #document-review-card) { display:flex; flex-wrap:wrap; align-items:flex-start; column-gap:.75rem; }
dialog.section-modal .section-modal-body:has(> #case-compliance):has(> #document-review-card) > * { flex:1 1 100%; }
dialog.section-modal .section-modal-body > #case-compliance:not(:has(details[open], li, table)):not([hidden]),
dialog.section-modal .section-modal-body > #document-review-card:not(:has(details[open], .document-review-list > *, #clarification-preparation:not([hidden]), #document-review-clarification-summary:not([hidden]))) {
  flex:0 0 auto; margin-top:0 !important; padding-top:0 !important; border-top:0 !important; }
/* Settings › Termene: «Nicio zi liberă adăugată.» and «Adaugă o zi liberă» on one row. */
.settings-page fieldset.deadlines-days > .deadlines-days-none:not([hidden]) { display:inline-block; margin:0 .75rem 0 0; vertical-align:middle; }
.settings-page fieldset.deadlines-days > .deadlines-days-none:not([hidden]) + details.deadlines-add-window:not([open]) { display:inline-block; vertical-align:middle; }
/* «Harta imobilului», the outline's window: «Desenează contur nou» and «Introducere prin coordonate / fișier» on one row. */
.property-map-toolbar:has(+ details.property-map-coordinates:not([open])) { display:inline-flex; vertical-align:middle; margin:0 .75rem .5rem 0; }
.property-map-toolbar + details.property-map-coordinates:not([open]) { display:inline-block; vertical-align:middle; }
/* «Foldere»: «Cum se deschide un dosar» on the row of «Listă · Foldere», not on a row of its own. */
@media (min-width:901px) { .explorer-workspace > details.explorer-rules:not([open]) { width:max-content; margin:-3.4rem 0 1.4rem auto; } }
/* The legends all bold alike; the register tables' heads all alike. */
body:not(.ac-editor-page) .workspace .overview-selection-heading > h3#overview-selection-title { font-weight:700; }
#numbering-settings table.numbering-table thead th { font-size:.7rem; font-weight:650; letter-spacing:.06em; text-transform:uppercase; }
/* One height for every control on a wide screen, as in the forms (rule 1.6): 38 px for fields, lists, the date button and the
   buttons beside them, on every page and window but the AC request; a phone and a tablet keep 44 px. */
@media (min-width:901px) {
  body:not(.ac-editor-page) { --control-height: 38px; }
  body:not(.ac-editor-page) :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]):not([type=range]):not([type=color]), select) { min-height:38px; height:38px; padding-block:.3rem; }
  body:not(.ac-editor-page) .date-ro-open { flex-basis:38px; width:38px; min-width:38px; min-height:38px; height:38px; }
  body:not(.ac-editor-page) :is(button, .button-link, a.secondary, summary.secondary):not(.act-btn):not(.link-button):not(.password-reveal):not(.page-edge):not(.date-ro-day):not(.th-sort) { min-height:38px; padding-block:.35rem; }
  body:not(.ac-editor-page) .cases-page .case-more-filters > summary, body.cases-page .case-more-filters > summary { min-height:38px; padding-block:.3rem; }
  body:not(.ac-editor-page) .password-field > .password-reveal { min-height:38px; }
}
@media (min-width:901px) { body:not(.ac-editor-page) .ol-zoom button { width:38px; height:38px; } }
/* The heads with an order button and those without stand on one line (the list, the register). */
.workspace table:is(.case-register, .registry-register) > thead > tr > th { vertical-align:middle; }
.workspace table:is(.case-register, .registry-register) th > button.th-sort { line-height:inherit; font:inherit; letter-spacing:inherit; text-transform:inherit; }

/* ===== Runda 19 (03.11): the form pages still above two screens. ===== */
/* Boxes of a sentence each: two columns, the text wrapping inside its column. */
.form-editor-page #fields .cu-choice-group.cu-options-columns.cu-options-wide { grid-template-columns:repeat(auto-fill, minmax(min(26rem, 100%), 1fr)); align-items:start; }
.form-editor-page #fields .cu-choice-group.cu-options-wide > .cu-option { align-items:flex-start; }
/* «Obiectivele de amplasare»: «Condiții din model» on the row of its box (rule 1.3); a box without conditions keeps its row. */
@media (min-width:701px) {
  .form-editor-page #fields .cu-choice-group:has(> details.model-condition) { display:flow-root; }
  .form-editor-page #fields .cu-choice-group > .cu-option:has(+ details.model-condition:not([open])) { float:left; clear:left; margin:0 1rem .15rem 0; }
  .form-editor-page #fields .cu-choice-group > .cu-option + details.model-condition:not([open]) { float:left; margin:0; }
  .form-editor-page #fields .cu-choice-group > .cu-option + details.model-condition:not([open]) > summary { min-height:38px; display:inline-flex; align-items:center; }
  .form-editor-page #fields .cu-choice-group:has(> details.model-condition) > :not(.cu-option):not(details.model-condition):not(legend), .form-editor-page #fields .cu-choice-group > .cu-option:not(:has(+ details.model-condition:not([open]))), .form-editor-page #fields .cu-choice-group > details.model-condition[open] { clear:both; }
}
/* A list of short answers is half a row on a wide screen. */
@media (min-width:900px) { .form-editor-page #fields .cu-grid > .cu-choice-group.cu-select-half { grid-column:span 6; } }
/* «Semnatari din Datele UAT» with no one saved: one line. */
.signatory-chooser.signatory-chooser-empty { padding:.45rem .9rem; margin:.5rem 0 .75rem; gap:0; }
.signatory-chooser.signatory-chooser-empty > p { margin:0; }

/* ===== Runda 20 (beneficiari, 03.11: «nu vrea să-mi micșoreze seria buletinului… are 2 litere», «numărul de stradă — cel mult
   3 cifre», «câmpurile dată pot fi reduse cu 50%», «i-ai zis să pună pe maxim 4 coloane?»): on a wide screen a rubric is as wide as
   the longest value it will hold and its label, on a row of 12 columns (shared-ui.js, RubricWidths). ===== */
@media (min-width:900px) {
  :is(.form-editor-page,.ac-editor-page) .cu-grid { column-gap:.75rem; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .library-pick { grid-column:span 3; }/* «Documentații din bibliotecă», a quarter as before */
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized:not(.cu-wide) { grid-column:span var(--cu-span, 6) !important; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized > :is(input, select) { min-width:0; }
  /* Beside the value: the check mark of a filled rubric in 1.5rem, a date's calendar button 38px wide and .25rem away. */
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized :is(input[type=text],input[type=email],input[type=tel],input:not([type])) { padding-right:1.5rem; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized input.entry-filled { background-position:right .35rem center; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized .date-ro-control { gap:.25rem; }
  :is(.form-editor-page,.ac-editor-page) .cu-grid > .field.cu-sized .date-ro-open { flex-basis:38px; width:38px; min-width:38px; }
}

/* ===== Runda 22 (testarea din 03.11 și aceleași probleme în restul aplicației) ===== */
/* «Continuă» stays at the right on every page of a form, also on the first one, where «Înapoi» is hidden. */
:is(.form-page-nav, .ac-page-nav) > :is(#form-page-next, #ac-page-next) { margin-left:auto; }
/* A line of text placed in a form's grid («Completați cel puțin un rând de aviz sau acord.») takes the whole row, not one column of 12. */
:is(.form-editor-page,.ac-editor-page) .cu-grid > p { grid-column:1 / -1; }
/* «(obligatoriu)» of the pages and windows (documentations, settings, dossier windows) is said as in the forms: a red «*» after the
   label, which no longer runs onto a second line beside its neighbour; the words stay for a screen reader. */
:is(label, legend) > .required-marker { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
:is(label, legend):has(> .required-marker)::after { content:'\00a0*'; color:hsl(0 72% 42%); font-weight:700; }
:is(label, legend):has(> .required-marker) { position:relative; }

/* Runda 7.11 (B5): an account that only reads is not given the helps of the rubrics (they tell how to fill in) nor the sentences about saving. */
body[data-role="READ"] :is(.cu-editor, #ac-fields, #fields) .field > .help, body[data-role="READ"] .cu-editor .help.save-hint { display:none; }
/* ===== Runda 9.11 (cererea de autorizație refăcută, 09.11.2026): the AC request looks and behaves as the requests for a certificate of urbanism.
   Used by ac-editor.html only. Rules: documente/context-proiect/reguli-interfata.md.
   Inside a section: groups are a sub-heading and a thin line (no frames, no folds); the tables are the application's tables (data-table, «Acțiuni», «⋯»);
   the property, its annex and a category of documents open in a window (section-modal). ===== */

/* The bar of steps stays where the form puts it (it does not follow the scroll), and the panel's margins are those of the other requests. */
#ac-pages { position:static; }
body.ac-editor-page.embedded main.layout { padding:1rem 1rem 0; }
/* A sub-heading and a thin line, as «Act de identitate», «Domiciliu» of F_CU_04. */
#ac-fields .ac-subgroup, .ac-window-body .ac-subgroup { grid-column:1 / -1; min-width:0; margin:0; }
#ac-fields .cu-subheading, .ac-window-body .cu-subheading { margin:.9rem 0 .35rem; padding-top:.6rem; border-top:1px solid hsl(var(--border)); font-size:1rem; font-weight:650; line-height:1.3; color:hsl(var(--foreground) / .8); }
#ac-fields > fieldset > legend + .cu-subheading, #ac-fields .ac-subgroup:first-child > .cu-subheading, .ac-window-body > .ac-subgroup:first-child > .cu-subheading,
.ac-window-step > .ac-subgroup:first-child > .cu-subheading, .ac-window-body .cu-section > .ac-subgroup:first-of-type > .cu-subheading { margin-top:0; padding-top:0; border-top:0; }
#ac-fields .ac-subgroup > .cu-grid, .ac-window-body .ac-subgroup > .cu-grid { padding:0; }
#ac-fields .ac-fields-grid, .ac-window-body .ac-fields-grid { padding:0; }
#ac-fields fieldset.cu-section > .ac-fields-grid + *, #ac-fields fieldset.cu-section > * + .ac-subgroup, .ac-window-body fieldset.cu-section > * + * { margin-top:.6rem; }

/* The frames of the sections, in the windows with steps too (the annex): the title on the border. */
.ac-window-body fieldset.field-group.cu-section { position:relative; margin:1.5rem 0 .9rem; padding:1.2rem .9rem .85rem; border:2px solid hsl(var(--panel-edge)); border-radius:12px; background:hsl(var(--card)); box-shadow:none; min-width:0; }
.ac-window-body fieldset.field-group.cu-section > legend { float:none; position:absolute; top:0; left:.9rem; z-index:1; width:auto; max-width:calc(100% - 1.8rem); margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; }
.ac-window-step[hidden] { display:none; }
.ac-window-step > fieldset.cu-section:first-child { margin-top:1.1rem; }

/* The widths of the rubrics on the row of 12 columns, where the value does not say it (RubricWidths narrows the ones it knows). */
@media (min-width:900px) {
  #ac-fields .cu-grid > .ac-col, .ac-window-body .cu-grid > .ac-col { grid-column:span var(--ac-span, 6); }
  #ac-fields .cu-grid > .field.cu-wide, .ac-window-body .cu-grid > .field.cu-wide { grid-column:1 / -1; }
  #ac-fields .cu-grid > .cu-choice-group:not(.ac-col), .ac-window-body .cu-grid > .cu-choice-group:not(.ac-col) { grid-column:1 / -1; }
  .ac-window-body .cu-grid { column-gap:.75rem; row-gap:.6rem; grid-template-columns:repeat(12,minmax(0,1fr)); }
  .ac-window-body .cu-grid > .field { grid-column:span 6; min-width:0; margin:0; }
  .ac-window-body :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]), select) { min-height:38px; height:38px; padding-block:.3rem; }
  .ac-window-body textarea.text-entry { min-height:38px; }
  .ac-window-body .field > label { margin-bottom:.2rem; }
}

/* A group of boxes is not a frame: its title reads as a label; a few short options on one row, a long list on columns. */
#ac-fields .ac-fields-grid > fieldset.ac-choices, .ac-window-body .ac-fields-grid > fieldset.ac-choices, .ac-window-body fieldset.ac-choices, #ac-fields fieldset.ac-choices { padding:0; border:0; border-radius:0; background:none; margin:0; min-width:0; }
#ac-fields .ac-choices > legend, .ac-window-body .ac-choices > legend:not(.visually-hidden) { margin:0 0 .25rem; padding:0; font-size:.9rem; font-weight:600; }
.ac-choices.cu-options-row { display:flex; flex-wrap:wrap; align-items:center; gap:.2rem 1.1rem; }
.ac-choices.cu-options-row > legend { flex:1 1 100%; }
.ac-choices.cu-options-row > .cu-option { margin:0; }
.ac-choices.cu-options-columns { display:grid; grid-template-columns:repeat(auto-fill, minmax(17rem, 1fr)); gap:.15rem 1.25rem; align-items:center; }
.ac-choices.cu-options-columns > :not(.cu-option) { grid-column:1 / -1; }
.ac-choices.cu-options-columns > .cu-option { margin:0; }
.ac-choices .cu-option { min-height:34px; margin:0; }
.ac-choices:disabled, .ac-choices[data-locked] { opacity:.6; }

/* The work categories, as the model has them: A, B, C and D, three columns, a parent with its sub-options together. */
.ac-categories { display:block !important; }
.ac-category-group + .ac-category-group { margin-top:.5rem; }
.ac-category-group > .cu-subheading { margin-top:.6rem; }
.ac-category-group:first-of-type > .cu-subheading { margin-top:0; padding-top:0; border-top:0; }
.ac-category-list { columns:3 15rem; column-gap:1.5rem; }
.ac-category-block { break-inside:avoid; margin:0 0 .35rem; }
.ac-category-block > .cu-option { margin:0; min-height:22px; align-items:flex-start; padding-block:.05rem; font-size:.9rem; line-height:1.25; }
.ac-category-block { margin:0 0 .25rem; }
.ac-category-block > .cu-option > input { margin-top:.15rem; }
.ac-editor-page .ac-category-block > .cu-option.ac-sub-option { margin-left:1.5rem; }
.ac-category-group { margin-top:.4rem; }

/* A rubric with the two toggles keeps half a row (they need room beside the label). */
.ac-window-body .cu-grid > .field.ac-value-field.cu-sized:not(.cu-wide) { --cu-span:6 !important; }
/* «Nu se aplică» and «Necunoscut» on the row of the label, at the right (the pattern of «Nu are» and «Nu se aplică» of the requests). */
.field:has(> .ac-state-toggles) { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:.75rem; align-content:start; }
.field:has(> .ac-state-toggles) > * { grid-column:1 / -1; }
.field:has(> .ac-state-toggles) > label:first-child { grid-column:1; grid-row:1; align-self:end; }
.field:has(> .ac-state-toggles) > .ac-state-toggles { grid-column:2; grid-row:1; align-self:end; justify-self:end; margin:0 0 .3rem; }
.ac-state-toggles { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:.15rem .85rem; }
.ac-state-toggles .cu-option { display:flex; align-items:center; gap:.35rem; min-height:0; margin:0; font-size:.82rem; font-weight:400; white-space:nowrap; cursor:pointer; }
.ac-state-toggles .cu-option input { width:1.1rem; min-width:1.1rem; height:1.1rem; min-height:1.1rem; margin:0; }
.ac-table .ac-state-toggles { flex-wrap:nowrap; }
.ac-window-body .cu-section > .ac-subgroup:first-of-type > .ac-subgroup-head > .cu-subheading, .ac-window-body .cu-section > .ac-subgroup:first-of-type > .cu-subheading { margin-top:0; padding-top:0; border-top:0; }
.ac-subgroup-head { display:flex; flex-wrap:wrap; align-items:flex-end; justify-content:space-between; gap:.25rem 1rem; }
.ac-subgroup-head > .cu-subheading { flex:1 1 auto; margin-bottom:.2rem; }
.ac-subgroup-head > .ac-state-toggles { margin-bottom:.3rem; }
.ac-state-selection > .ac-choices { margin-top:.2rem; }
.ac-editor-page .cu-not-applicable :is(input, textarea, select) { background:hsl(var(--muted) / .6); color:hsl(var(--muted-foreground)); }
.ac-editor-page .cu-not-applicable :is(input, textarea)::placeholder { color:hsl(var(--muted-foreground)); opacity:1; }

/* The tables of the request: the properties, the documents, the specialists, the checks, the rows of values. They are the application's tables
   (table.data-table); the same rules are written for the windows, which are outside .workspace. */
.ac-editor-page .table-wrap { max-width:100%; overflow-x:auto; border:1px solid hsl(var(--border)); border-radius:var(--radius); margin:.2rem 0 .7rem; }
@media (min-width:761px) { .ac-editor-page .table-wrap:has(details.row-more) { overflow:visible; } }
.ac-editor-page table.ac-table.data-table { width:100%; border-collapse:collapse; font-size:.875rem; table-layout:auto; }
.ac-editor-page table.ac-table.data-table thead th { padding:.5rem .75rem; border-bottom:1px solid hsl(var(--border)); background:hsl(var(--muted) / .7); color:hsl(var(--muted-foreground)); font-size:.7rem; font-weight:650; letter-spacing:.05em; text-transform:uppercase; text-align:left; white-space:nowrap; vertical-align:bottom; }
.ac-editor-page table.ac-table.data-table tbody td { padding:.2rem .75rem; border-bottom:1px solid hsl(var(--border)); vertical-align:middle; text-align:left; }
.ac-editor-page table.ac-table.data-table tbody tr:last-child > td { border-bottom:0; }
.ac-editor-page table.ac-table.data-table tbody tr:hover > td { background:hsl(var(--muted) / .4); }
.ac-editor-page table.ac-table.data-table :is(th, td).col-actions { text-align:right; white-space:nowrap; width:1%; }
.ac-editor-page table.ac-table.data-table :is(th, td).col-nowrap { white-space:nowrap; }
.ac-editor-page table.ac-table .cell-sub { display:block; margin-top:.1rem; color:hsl(var(--muted-foreground)); font-size:.78rem; }
.ac-row-name strong { font-weight:600; }
.ac-editor-page table.ac-table .cell-sub.ac-missing { color:hsl(var(--tone-attn-fg, 30 80% 30%)); }
.ac-row-holder { min-width:0; }
/* the property window is narrow: the directory actions go on a line of their own under the label, not beside it */
dialog.ac-window .field:has(> .property-directory-actions) > .property-directory-actions { grid-column:1 / -1; grid-row:2; justify-content:flex-start; justify-self:start; margin:0 0 .3rem; }
dialog.ac-window .field:has(> .property-directory-actions) > :is(input, textarea, select) { grid-row:3; justify-self:start; }
dialog.ac-window :is([data-pointer$="/property/cadastral"], [data-pointer$="/property/landBook"]) { width:12rem !important; max-width:100%; }
dialog.ac-window .cu-grid > .field:has(> [data-pointer$="/property/landBook"]) { grid-column:span 6 !important; }
/* a row marked at its holder (the annex, the data of a property, a category): the red frame of a rubric */
.ac-row-holder.field-invalid { padding:.2rem .35rem; border:1px solid hsl(var(--danger)); border-radius:6px; background:hsl(var(--danger) / .04); }
.ac-row-holder.field-invalid > .field-error { margin:.25rem 0 0; }
.ac-editor-page .ac-table .state-badge { white-space:nowrap; }
.ac-editor-page .ac-table .row-actions { display:inline-flex; flex-wrap:nowrap; justify-content:flex-end; align-items:center; gap:.35rem; }
.ac-editor-page .ac-table :is(.act-btn) { display:inline-flex; align-items:center; gap:.35rem; min-height:32px; padding:.25rem .65rem; border:1px solid hsl(var(--input)); border-radius:calc(var(--radius) - 2px); background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.8125rem; font-weight:500; line-height:1.2; white-space:nowrap; cursor:pointer; }
.ac-editor-page .ac-table .act-btn:hover { border-color:hsl(var(--primary) / .6); color:hsl(var(--primary)); background:hsl(var(--primary) / .06); }
/* A row filled where it stands: the cells hold the rubrics, their labels only for a screen reader. */
.ac-cell { margin:0; min-width:0; }
.ac-cell > label.visually-hidden { margin:0; }
.ac-editor-page .ac-table .ac-cell :is(input:not([type=checkbox]):not([type=radio]), select, textarea), .ac-editor-page .ac-table td > select, .ac-editor-page .ac-table td > .ac-row-holder > select { width:100%; min-width:0; min-height:34px !important; height:34px !important; padding-block:.2rem; }
.ac-editor-page .ac-table .ac-cell textarea.text-entry { height:auto !important; }
.ac-editor-page .ac-table .ac-cell .date-ro-control :is(input, button) { height:34px !important; min-height:34px !important; }
.ac-documents-table td > .ac-row-holder > select { width:11rem; }
.ac-editor-page table.ac-table.data-table.ac-documents-table tbody td { padding-block:.1rem; }
.ac-editor-page .ac-documents-table td > .ac-row-holder > select { height:30px !important; min-height:30px !important; padding-block:.1rem; }
.ac-reviews { min-width:50rem; }
.ac-reviews th:nth-child(1) { width:24%; }
.ac-reviews th:nth-child(2) { width:18%; }
.ac-editor-page .ac-reviews td:nth-child(2) select { min-width:9.5rem; padding-right:1.6rem; }
.ac-reviews th:nth-child(3) { width:16%; }
.ac-reviews th:nth-child(4) { width:11%; }
.ac-reviews th:nth-child(5) { width:10%; }
.ac-reviews .date-ro-control { gap:.25rem; }
.ac-editor-page .ac-table .ac-note-row > td { padding-top:0; border-top:0; background:hsl(var(--muted) / .25); }
.ac-editor-page .ac-table .ac-review-row > td { border-bottom:0; }
.ac-note-row .field { margin:.1rem 0; display:flex; align-items:center; gap:.75rem; }
.ac-note-row .field > label { flex:0 0 11rem; margin:0; }
.ac-note-row .field > :is(input, textarea) { flex:1 1 auto; min-width:0; }
.ac-value-table .ac-col-label { width:38%; font-weight:500; }
.ac-editor-page table.ac-table.data-table.ac-value-table tbody td { padding-block:.18rem; }
.ac-editor-page .ac-value-table .ac-cell :is(input:not([type=checkbox]):not([type=radio]), select) { min-height:32px !important; height:32px !important; }
.ac-value-table .ac-col-toggles { width:1%; white-space:nowrap; }
.ac-value-table .ac-col-unit { width:9rem; }
.ac-areas .ac-col-value { width:20%; }
.ac-specialists .ac-table td:first-child { width:38%; }
.ac-list > button, .ac-specialists > button { margin-top:.2rem; }

/* The sentence about what the request still lacks and its button, on one row. */
.wizard-annex-todo { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.5rem 1rem; }
.wizard-annex-todo > p { margin:0; }
/* A button beside a blocked rubric (the calendar of a date) is blocked like the rubric: grey, not clickable. */
.ac-editor-page :is(.cu-not-applicable, .ac-window-body) .date-ro-open:disabled, .ac-editor-page .cu-not-applicable .date-ro-open, .ac-editor-page .date-ro-open[data-locked] { background:hsl(var(--muted) / .6); border-color:hsl(var(--border)); color:hsl(var(--muted-foreground)); opacity:1; cursor:not-allowed; box-shadow:none; }
.ac-editor-page .cu-not-applicable :is(button:disabled) { background:hsl(var(--muted) / .6); color:hsl(var(--muted-foreground)); opacity:1; cursor:not-allowed; }
/* «⋯»: the rare actions of a row wait in a menu. */
.ac-editor-page details.row-more { position:relative; display:inline-block; margin:0; padding:0; border:0; background:none; }
.ac-editor-page details.row-more > summary { list-style:none; display:inline-flex; align-items:center; justify-content:center; min-width:2.1rem; min-height:32px; margin:0; padding:0 .5rem; border:1px solid hsl(var(--border)); border-radius:calc(var(--radius) - 2px); background:hsl(var(--card)); color:hsl(var(--foreground)); font-weight:700; letter-spacing:.06em; line-height:1; cursor:pointer; }
.ac-editor-page details.row-more > summary::-webkit-details-marker { display:none; }
.ac-editor-page details.row-more > summary::before, .ac-editor-page details.row-more > summary::after { content:none !important; display:none !important; }
.ac-editor-page details.row-more > summary:hover, .ac-editor-page details.row-more[open] > summary { border-color:hsl(var(--primary) / .55); background:hsl(var(--muted) / .5); }
.ac-editor-page .row-more-menu { position:absolute; right:0; top:calc(100% + .25rem); z-index:30; display:flex; flex-direction:column; align-items:stretch; min-width:12rem; padding:.35rem; border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); box-shadow:0 10px 28px hsl(222 47% 11% / .16); }
.ac-editor-page .row-more-menu > button { display:flex; justify-content:flex-start; width:100%; margin:0; min-height:36px; padding:.35rem .65rem; border:0; border-radius:calc(var(--radius) - 2px); background:none; box-shadow:none; color:hsl(var(--foreground)); text-align:left; font-size:.85rem; font-weight:500; white-space:nowrap; }
.ac-editor-page .row-more-menu > button:hover:not(:disabled) { background:hsl(var(--muted)); }
.ac-editor-page .row-more-menu > button.danger { color:hsl(var(--danger)); }

/* Reprezentare: the quality of the applicant, then the person represented. */
.ac-representation > .cu-grid + .cu-grid { margin-top:.6rem; }

/* The window: the bar with «Închide», the body that scrolls, the buttons below (the model of the application's windows). */
/* the two widths of the application's windows (a form narrow, anything wide wide) are kept; only the height may be taller */
dialog.section-modal.ac-window { max-height:92vh; }
/* Runda 23.11 (r2311): the window of the technical annex uses almost the whole screen from 761 px up, as the window «Vezi» does; on a phone it is the whole page (the rule at the end of the file). */
@media (min-width:761px) {
  dialog.section-modal.ac-annex-window, dialog.section-modal.ac-annex-window.section-modal-wide { width:min(97vw, 150rem); max-width:97vw; height:95vh; max-height:95vh; }
}
/* and the rubrics whose width the value does not say sit three on a row where the window is wide enough (the sized ones keep their own width) */
@media (min-width:1200px) {
  dialog.ac-annex-window .ac-window-body .cu-grid > .field:not(.cu-sized):not(.cu-wide):not(.ac-col) { grid-column:span 4; }
}
/* the button of a section of the annex: at the end of the section, on the right (and the same words for «Anulează marcarea») */
.ac-window-body .ac-section-rest { display:flex; justify-content:flex-end; margin-top:.7rem; }
.ac-window-body .ac-section-rest[hidden] { display:none; }
/* Runda 22.11: an empty rubric of a window shows no «entry» mark, so its hint (county → locality → village: «Întâi localitatea») may use the room that the mark keeps when the rubric is filled. */
dialog.ac-window .ac-window-body .cu-grid > .field input[type=text]:placeholder-shown { padding-right:.75rem; }
dialog.ac-window > .ac-window-body { flex:1 1 auto; min-height:0; padding:1rem 1.25rem 1rem; }
dialog.ac-window > .form-actions { flex:none; margin:0 1.25rem; padding:.85rem 0 1rem; border-top:1px solid hsl(var(--border)); position:static; box-shadow:none; background:hsl(var(--card)); }
.ac-window-body > :is(nav, article) { margin:0; }
.ac-window-body > .ac-window-pages { margin:0 0 .4rem; position:static; }
.ac-window-body > .form-page-nav { margin:.9rem 0 0; display:flex; justify-content:space-between; gap:.75rem; }
.ac-window-body > .form-page-nav > [data-step-next] { margin-left:auto; }
.ac-window-body > .form-page-nav > [data-step-back]:disabled { visibility:hidden; display:inline-flex; }
.ac-window-body > .ac-window-error { margin:0 0 .6rem; }
.ac-window-body > :is(div, section):not([hidden]) ~ :is(div, section):not([hidden]) { margin-top:.8rem !important; padding-top:0 !important; border-top:0 !important; }
.ac-window-pages ol { flex-wrap:wrap; }

/* The references of a category: identifier · description · properties · «Atașează un fișier» · «Elimină», on one row. */
.ac-references { display:flex; flex-direction:column; gap:.55rem; }
.ac-reference-row { display:grid; grid-template-columns:minmax(7rem, 2fr) minmax(12rem, 6fr) auto auto; align-items:end; gap:.5rem .75rem; padding-bottom:.55rem; border-bottom:1px solid hsl(var(--border)); }
.ac-reference-row > .field { margin:0; min-width:0; }
.ac-reference-row .ac-ref-properties { margin:0; padding:0; border:0; display:flex; gap:.2rem 1rem; align-items:center; align-self:end; min-height:38px; }
.ac-ref-tools { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:.4rem .6rem; align-self:end; }
.ac-ref-tools .request-files { display:flex; flex-wrap:wrap; align-items:center; gap:.3rem .6rem; margin:0; }
.ac-ref-tools .request-files-list { margin:0; padding:0; list-style:none; font-size:.85rem; }
.ac-ref-tools .request-files-message:empty { display:none; }
.ac-references > button { align-self:flex-start; }
.ac-references > .request-files { margin-top:.2rem; }

/* Narrow screens: the rows of the tables are cards; the bar of the window's steps scrolls; the references stack. */
@media (max-width:760px) {
  .ac-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
  .ac-editor-page .ac-table, .ac-editor-page .ac-table tbody, .ac-editor-page .ac-table tr, .ac-editor-page .ac-table td { display:block; width:100% !important; }
  .ac-editor-page .table-wrap, .ac-window-body .table-wrap { overflow:visible; border:0; }
  .ac-table tr { margin:.5rem 0; padding:.25rem 0; border:1px solid hsl(var(--border)); border-radius:var(--radius); background:hsl(var(--card)); }
  .ac-editor-page .ac-table td { display:grid; grid-template-columns:7.5rem minmax(0, 1fr); gap:.5rem; padding:.3rem .65rem !important; border:0 !important; white-space:normal !important; text-align:left !important; }
  .ac-table td::before { content:attr(data-label); color:hsl(var(--muted-foreground)); font-size:.7rem; font-weight:650; letter-spacing:.04em; text-transform:uppercase; align-self:center; }
  .ac-table td[data-label=""]::before, .ac-table td.col-actions::before { display:none; }
  .ac-table td[data-label=""], .ac-table td.col-actions { grid-template-columns:minmax(0, 1fr); }
  .ac-table td.col-actions .row-actions { justify-content:flex-start; }
  /* the lists of categories and of properties: the name on a line, then the state and the actions, no caption for what is plain */
  .ac-editor-page :is(.ac-documents-table, .ac-properties-table) tr { display:grid; grid-template-columns:minmax(0, 1fr) auto; align-items:center; padding:.35rem .65rem; }
  .ac-editor-page :is(.ac-documents-table, .ac-properties-table) td { display:block; padding:.15rem 0 !important; }
  .ac-editor-page :is(.ac-documents-table, .ac-properties-table) td::before { display:none; }
  .ac-editor-page :is(.ac-documents-table, .ac-properties-table) td:first-child { grid-column:1 / -1; }
  .ac-editor-page .ac-documents-table td:nth-child(3) { text-align:right !important; }
  .ac-editor-page :is(.ac-documents-table, .ac-properties-table) td.col-actions { grid-column:1 / -1; }
  .ac-editor-page .ac-documents-table td > .ac-row-holder > select { width:100%; }
  .ac-reviews { min-width:0; }
  .ac-reviews td:has(> .cu-not-applicable) { display:none !important; }
  .ac-note-row > td { padding-top:0 !important; }
  .ac-note-row .field { display:block; }
  .ac-note-row .field > label { display:block; margin:0 0 .25rem; }
  .ac-reference-row { grid-template-columns:minmax(0, 1fr); align-items:stretch; }
  .ac-ref-tools { justify-content:flex-start; }
  .ac-category-list { columns:1; }
  dialog.section-modal.ac-window, dialog.section-modal.ac-window.section-modal-wide { width:100vw; max-width:100vw; max-height:100dvh; height:100dvh; border-radius:0; }
  dialog.ac-window > .ac-window-body { padding:.75rem .9rem; }
  dialog.ac-window > .form-actions { margin:0 .9rem; padding:.6rem 0; flex-wrap:wrap; }
  dialog.ac-window > .form-actions > button { flex:1 1 0; }
  .ac-window-body .ac-section-rest > button { flex:1 1 100%; }
  .ac-window-body > .ac-window-pages ol { flex-wrap:nowrap; overflow-x:auto; }
  .field:has(> .ac-state-toggles) { grid-template-columns:minmax(0, 1fr); }
  .field:has(> .ac-state-toggles) > .ac-state-toggles { grid-column:1; grid-row:auto; justify-self:start; margin:.3rem 0 0; }
}

/* Runda 9.11 (verificare, consecvența între cereri): the sections of the AC request are framed like those of every other request
   (Runda 18): a frame with the title on its border. Only the frame and the title; the inside of the AC request keeps its own layout. */
.ac-editor-page #ac-fields fieldset.field-group.cu-section { position:relative; margin:1.5rem 0 .9rem; padding:1.2rem .9rem .85rem; border:2px solid hsl(var(--panel-edge)); border-radius:12px; background:hsl(var(--card)); box-shadow:none; }
.ac-editor-page #ac-fields fieldset.field-group.cu-section > legend { float:none; position:absolute; top:0; left:.9rem; z-index:1; width:auto; max-width:calc(100% - 1.8rem); margin:0; padding:.2rem .7rem; transform:translateY(-55%);
  border:2px solid hsl(var(--panel-edge)); border-radius:7px; background:hsl(var(--card)); color:hsl(var(--foreground)); font-size:.85rem; font-weight:700; line-height:1.3; }
@media (max-width:600px) { .ac-editor-page #ac-fields fieldset.field-group.cu-section { padding-left:.7rem; padding-right:.7rem; } .ac-editor-page #ac-fields fieldset.field-group.cu-section > legend { left:.6rem; } }
/* Runda 9.11 (verificare): «Cerere depusă în altă zi?» stands on the row of the buttons in the AC request too, as on the other requests. */
#ac-form > .form-actions:not(.ac-page-nav) > .request-date-choice { order:3; flex:0 1 auto; align-self:center; }
#ac-form > .form-actions:not(.ac-page-nav) > .request-date-choice .request-date-link { min-height:38px; }

/* Review 10.11: a value written under a state of absence (an old draft) stays open and is told apart; the declared registration of an old draft is a small block of the first step. */
.ac-editor-page .ac-conflict input { border-color:hsl(var(--danger)); }
.ac-editor-page .ac-registration > button { margin-top:.4rem; }

/* Runda 13.11 (cererea de AC): the lines that say what lacks lead there; the computed totals of the surfaces; the rule under the table. */
.ac-editor-page button.link-button.ac-todo { font:inherit; font-weight:600; padding:0; min-height:0; height:auto; text-align:left; white-space:normal; color:hsl(var(--tone-attn-fg)); }
.ac-editor-page button.link-button.ac-todo:hover { text-decoration:underline; }
.ac-editor-page .ac-row-holder.field-invalid > .ac-todo, .ac-editor-page .ac-row-holder.field-invalid .ac-row-name .ac-todo { display:none; }
.field-error .field-error-go { font:inherit; padding:0; min-height:0; height:auto; text-align:left; white-space:normal; color:inherit; text-decoration:underline; }
.ac-editor-page .ac-computed input { border-style:dashed; cursor:default; }
.ac-editor-page .ac-areas-rule { margin:.35rem 0 0; }
.ac-editor-page .ac-properties-table td.ac-col-todo { max-width:24rem; }
/* nc-formulare 15.11 (N-3): the request is drawn again whole at every choice; the browser's scroll anchoring kept anchoring on the sections it had removed and moved the page by thousands of pixels, so this page is not anchored (the page stays where the clerk is) */
html:has(> body.ac-editor-page) { overflow-anchor:none; }

/* Runda 16.11 (F-2): the number, the block, the surfaces and the land book stand on one row of their own (cu-request-ui.js); the surfaces are always on
   the screen, small, and grey while the choice that asks for them («Teren», «Construcții») is not ticked. */
.form-editor-page .cu-grid > .cu-property-row { grid-column:1 / -1; min-width:0; }
/* the boxes of the row stand on one line (at the bottom of the row), whatever the lines of their labels: no space is added above a label, so the page does not move when the form is drawn again */
.form-editor-page .cu-property-row.cu-grid { align-items:end; }
.form-editor-page .cu-surface-off > label { color:hsl(var(--muted-foreground)); }
@media (min-width:900px) {
  .form-editor-page .cu-property-row > .field.cu-prop-details.cu-prop-details.cu-prop-details, .form-editor-page .cu-property-row > .field.cu-prop-book.cu-prop-book.cu-prop-book { grid-column:span 3; }
  .form-editor-page .cu-property-row > .field.cu-prop-area.cu-prop-area.cu-prop-area { grid-column:span 2; }
}

/* Runda 16.11 (F-3): the rows of a regime stand as a table under one head («Prevedere», «Act de reglementare»), without «Prevederea N»: the certificate
   of construction (form-composites.js: «Adaugă rând», «Elimină rândul») and the certificates with fixed rows (cu-request-ui.js: «Nu se aplică» at the end of the row).
   The library's «…» stands at the right of the head (the certificate) or at the end of the first row (the others). */
.form-editor-page #fields .rules-head { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:.75rem; align-items:end; margin:0 0 .2rem; }
.form-editor-page #fields .rules-head-cell { font-size:.9rem; font-weight:600; }
.form-editor-page #fields .rules-head-tools { display:flex; justify-content:flex-end; min-width:8rem; }
.form-editor-page #fields .rules-head-tools > button, .form-editor-page #fields .cu-rule-row > .rule-tools > button { min-height:28px; min-width:2.4rem; padding:0 .55rem; line-height:1; font-weight:700; letter-spacing:.06em; }
.form-editor-page #fields .cu-rule-table-row, .form-editor-page #fields .cu-rule-fixed { border-top:0; padding:.15rem 0; }
.form-editor-page #fields .cu-rule-table-row > button.secondary { min-width:8rem; }
.form-editor-page #fields .cu-rule-table-row .rule-cell-label { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.form-editor-page #fields .cu-rule-fixed > .rule-tools { display:flex; align-items:center; justify-content:flex-end; gap:.75rem; }
.form-editor-page #fields .cu-rule-fixed > .rule-tools .cu-option { min-height:0; margin:0; gap:.4rem; font-size:.82rem; font-weight:400; white-space:nowrap; }
@media (min-width:701px) {
  .form-editor-page #fields .cu-rule-fixed { display:grid; grid-template-columns:minmax(0,1fr) 9.5rem; column-gap:.75rem; align-items:end; }
  .form-editor-page #fields .cu-rule-fixed > .cu-rule-grid { grid-column:1; min-width:0; }
  .form-editor-page #fields .cu-rule-fixed > .rule-tools { grid-column:2; margin:0 0 .1rem; }
  .form-editor-page #fields .cu-rule-fixed > :not(.cu-rule-grid):not(.rule-tools):not(legend) { grid-column:1 / -1; }
}
@media (max-width:700px) {
  .form-editor-page #fields .rules-head-grid { display:none; }
  .form-editor-page #fields .rules-head { grid-template-columns:minmax(0,1fr); justify-items:end; }
  .form-editor-page #fields .cu-rule-table-row { border-top:1px solid hsl(var(--border)); padding-top:.55rem; }
  .form-editor-page #fields .cu-rule-table-row .rule-cell-label { position:static; width:auto; height:auto; clip-path:none; white-space:normal; }
  .form-editor-page #fields .cu-rule-fixed > .rule-tools { justify-content:flex-start; margin:.3rem 0 0; }
  /* a phone has no table head: each row says what its boxes are, and the rows are told apart by a line */
  .form-editor-page #fields .cu-rule-fixed + .cu-rule-fixed { border-top:1px solid hsl(var(--border)); padding-top:.55rem; }
  .form-editor-page #fields .cu-rule-fixed .field > label.visually-hidden { position:static !important; width:auto; height:auto; overflow:visible; clip-path:none; white-space:normal; }
}

/* ===== Runda 16.11 (P-3, P-5): the header of a dossier is one line — applicant – request – procedure · day – property —, then «Stadiu:» with the state, then (a dossier closed or rejected)
   what it says about itself and, where allowed, «Redeschide dosarul»; «Solicitantul renunță la cerere» stands at the right of the bar of the documents. ===== */
.case-detail #detail-title.case-headline { margin:0; font-size:1.2rem; font-weight:600; line-height:1.4; overflow-wrap:anywhere; }
.case-headline .headline-request { font-weight:700; white-space:nowrap; }
.case-headline .headline-procedure, .case-headline .headline-property { font-weight:500; }
.case-headline .headline-dash { font-weight:400; color:hsl(var(--muted-foreground)); }
.case-detail #detail-meta.case-stage-line { display:flex; flex-wrap:wrap; align-items:center; gap:.35rem; margin:.4rem 0 0; }
.case-stage-line .case-stage-label { font-weight:600; }
.case-closure { margin:.35rem 0 0; }
.case-closure[hidden] { display:none; }
.case-closure .case-closure-text { margin:0; font-size:.9rem; color:hsl(var(--foreground)); overflow-wrap:anywhere; }
.case-closure .case-closure-actions { margin:.5rem 0 0; }
.case-closure .case-closure-actions > button { min-height:38px; padding:.4rem .9rem; font-size:.875rem; font-weight:550; }
.cases-page .doc-toolbar-withdraw { display:contents; }
.cases-page .doc-toolbar-withdraw > button { min-height:38px; padding:.4rem .9rem; font-size:.875rem; font-weight:550; }
.cases-page .doc-toolbar-withdraw > form { flex:0 0 100%; }
.case-workspace .detail-grid > .case-current-step.panel-framed { margin-top:.85rem; }

/* Runda 16.11 (C-4): the state of a request for completions («Comunicată la zz.ll.aaaa») may take two lines in «Toate documentele» instead of widening the table at 1024. */
.chain-documents-table .chain-col-state .state-badge { white-space:normal; }
/* ===== nc-prop2 (X-1, X-2): the window of the annex ===== */
/* it scrolls inside itself, so the browser must not anchor it (it is drawn again at every choice); with the whole form shown the bar of steps stays at the top, as a short road to each step */
.ac-window-body { overflow-anchor:none; }
.ac-window-body.ac-window-all > .ac-window-pages { position:sticky; top:0; z-index:5; }
/* a few short options (the access, the kinds of the sheet, the states of the building) are half a row, so two such groups, or a group and a short rubric, share a row */
@media (min-width:900px) {
  .ac-annex-window .ac-window-body .cu-grid > fieldset.cu-choice-group.cu-options-row:not(.ac-col) { grid-column:span 6; }
}
.ac-window-body.ac-window-all > .ac-window-pages { top:-1rem; }
@media (min-width:761px) {
  body.ac-editor-page nav.ac-window-pages.ac-pages ol { flex:1 1 100%; flex-wrap:wrap; overflow:visible; }
  body.ac-editor-page nav.ac-window-pages.ac-pages ol li { flex:none; width:auto; min-width:0; }
  body.ac-editor-page nav.ac-window-pages.ac-pages ol .ac-page { width:auto; }
}
nav.ac-window-pages > .ac-all-pages { flex:none; margin-left:auto; padding-block:0; min-height:0; white-space:nowrap; }
/* the numbers of the tables of the annex are a few digits: their boxes are as wide as that, not as the column */
.ac-areas .ac-cell, .ac-metrics .ac-col-value .ac-cell { max-width:9rem; }
@media (max-width:760px) { .ac-window-body.ac-window-all > .ac-window-pages { top:-.75rem; } }
/* the rows of the tables of values of the annex (characteristics, capacities, measures, surfaces) are a little lower: more rubrics in view */
@media (min-width:761px) {
  body.ac-editor-page .ac-annex-window table.ac-table.data-table.ac-value-table tbody td { padding-block:.08rem; }
  body.ac-editor-page .ac-annex-window .ac-value-table .ac-cell :is(input:not([type=checkbox]):not([type=radio]), select) { min-height:30px !important; height:30px !important; }
  body.ac-editor-page .ac-annex-window .ac-value-table .ac-cell .date-ro-control :is(input, button) { height:30px !important; min-height:30px !important; }
}
