/* Month shell and month pages (task 025). Shared components come from components.css; these rules only place the
   month header above the flow bar and the sections of the month page. Roles and steps only, no colour literals. */
/* Task 331 (Silvia D3): the month's progress is a plain band under the page's head, not a resting card: it is not the
   page's job, so it takes no padding and no shadow, only the line that closes it. */
.month-shell { display: grid; gap: var(--space-2); margin: 0 0 var(--space-3); padding: 0 0 var(--space-2); border-bottom: var(--border-w) solid var(--line); }
.month-shell-name { margin: 0; color: var(--ink-2); font-size: var(--ph-text-sm); font-weight: 400; }
.month-shell-facts { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1); margin: 0; font-size: var(--ph-text-sm); }
.month-shell-current, .month-shell-closed { color: var(--ink-2); }
.month-shell .flow-bar { margin: 0; }
/* Task 122: what the current step waits for, inside the progress card under the steps. */
.month-shell-note { display: grid; gap: var(--ph-space-05); padding-top: var(--space-2); border-top: var(--border-w) solid var(--line); font-size: var(--ph-text-md); }
.month-shell-note > p { margin: 0; }
.month-shell-note .field-help { color: var(--ink-2); }
.flow-link[aria-disabled="true"] .flow-name { color: var(--ink-2); }
.month-window { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1); margin: 0 0 var(--space-3); font-size: var(--ph-text-md); }
.month-overview h3 { margin: 0 0 var(--space-1); font-size: var(--ph-text-lg); }
.month-section-note, .month-history-hidden { color: var(--ink-2); }
/* Task 373 (rompi-ui 372 #6): the consultant's name and address in «Accesso del consulente» wrap; a 72 letter PEC address widened the page to 535px at 390. */
.month-section-contact { overflow-wrap: anywhere; }
.month-section-counts { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-3); margin: 0; padding: 0; list-style: none; }
.month-archive, .month-history { margin-top: var(--space-3); }
.month-history-list { margin: 0; padding-left: var(--space-3); }
.month-history-list li + li { margin-top: var(--space-1); }
.months-list + .months-list { margin-top: var(--space-4); }
/* Task 051a round 2: the month to close leads the list, which from the 1st is no longer the current month. */
.months-to-close { margin-block: 0 var(--space-2); font-weight: 600; }
/* Task 052d: who does what on the month page, in the ink of the text (F31); the close window reads as a company
   setting under the date line; the line that Payroll Hub does not record the payment of wages is normal text (F8). */
.month-window { margin-bottom: var(--space-3); }
.month-window-setting { margin: 0 0 var(--space-3); color: var(--ink); font-size: var(--ph-text-md); }
.month-section-who, .month-section-note.month-pay { color: var(--ink); }
/* Task 054a (theme 1, I7 and I21): the shell follows the page header, so it sits close under it; what no longer takes
   changes is a fact beside the month's one pill, in words. */
.month-shell-lock { color: var(--ink-2); }
/* Task 054a (item 6, I6 and N42): the folded sections read as a control, a button with a chevron that turns. */
.month-rest-toggle { gap: var(--space-1); cursor: pointer; }
.month-rest-toggle::before { content: ""; flex: none; width: 0.45em; height: 0.45em; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); }
.month-rest[open] > .month-rest-toggle::before { transform: rotate(45deg); }
/* Task 056b (Rosa F11 R35): the actions agreed with the consultant to apply in the month, read before what the close waits
   for, in normal text; each line keeps its person, its words and its state together. */
.month-agreements-lead { margin: 0 0 var(--space-2); color: var(--ink); font-size: var(--ph-text-md); }
.month-agreements-list .checklist-label { flex-basis: 24rem; font-weight: 400; }
/* Task 054a (theme 3, F37): what happens if the window passes without a close, in normal text. */
.close-window-passes { margin: 0 0 var(--space-2); color: var(--ink); font-size: var(--ph-text-md); }
@media (max-width: 40rem) {
  /* The count chips of a month's list keep one row and scroll sideways rather than stacking three rows high. */
  .month-page .segments { flex-wrap: nowrap; max-width: 100%; overflow-x: auto; }
  .month-page .segments > * { flex: none; white-space: nowrap; }
}
/* Design «Segnale»: the close's rows that ask something, then the quiet ones folded under them. A person's name stays on
   one line, an anomaly reads its state, its name and its link on one line, with its one line of warning under it. */
.close-people-table th[scope="row"] { min-width: 12rem; }
.close-anomalies { padding: 0; list-style: none; }
.close-anomaly-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--ph-space-05) var(--space-1); }
.close-quiet { margin: var(--space-2) 0 0; }
.close-nothing-asks { margin: 0; color: var(--ink-2); }
/* Design «Segnale»: the month's timesheets as one progress, delivered over the people of the month, with the counts of
   delivered and approved beside it in words. */
.month-progress { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); margin: 0 0 var(--space-1); }
.month-progress > progress { flex: 0 1 16rem; height: 0.5rem; border: 0; border-radius: var(--radius); background: var(--surface-2); appearance: none; overflow: hidden; }
.month-progress > progress::-webkit-progress-bar { background: var(--surface-2); }
.month-progress > progress::-webkit-progress-value { background: var(--accent); }
.month-progress > progress::-moz-progress-bar { background: var(--accent); }
/* Design «Segnale»: the recent months and the archive read as one list, their columns at the same widths. */
@media (min-width: 40rem) {
  .months-table { table-layout: fixed; }
  .months-table th:nth-child(1) { width: 22%; }
  .months-table th:nth-child(2) { width: 24%; }
  .months-table th:nth-child(3) { width: 30%; }
  .months-table th:nth-child(4) { width: 16%; }
}
/* Design «Segnale»: the submissions' «i» on what «Conferma» does sits over the column of the buttons; who is told stays
   under them. */
.data-table th.row-actions { text-align: right; }
.submissions-notice { display: block; margin: var(--ph-space-05) 0 0; }
.months-next { margin: var(--space-2) 0 0; color: var(--ink-2); font-size: var(--ph-text-md); }
