/* ===== SEZIONE BOLOGNA (Alsos) — usa le variabili del tema di app.css ===== */
.bo-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.bo-nav, .bo-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bo-week-label { display: flex; flex-direction: column; margin-left: 6px; line-height: 1.25; }
.bo-week-label strong { font-size: var(--text-md, 18px); }
.bo-week-label span { font-size: 12px; color: var(--text2); }
.bo-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 10px 14px; margin-bottom: 14px;
  border: 1px dashed var(--amber); border-radius: var(--radius); background: var(--amber2); font-size: 14px; }
.bo-empty { padding: 40px; text-align: center; color: var(--text2); }

.bo-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; align-items: start; }
.bo-days { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.bo-day { display: flex; flex-direction: column; gap: 8px; padding: 12px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface); min-width: 0; }
.bo-day.bo-today { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.bo-day.bo-st-anteprima { border-style: dashed; background: transparent; }
.bo-day.bo-st-anteprima .bo-rows, .bo-day.bo-st-anteprima .bo-bar { opacity: .6; }
.bo-day header { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.bo-dname { font-weight: 700; }
.bo-ddate { color: var(--text2); font-variant-numeric: tabular-nums; }
.bo-badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; border: 1px solid currentColor; white-space: nowrap; }
.bo-badge-anteprima { color: var(--amber); }
.bo-badge-master { color: var(--text2); }
.bo-badge-manuale { color: var(--blue); }
.bo-badge-emesso { color: var(--green); }

.bo-bar { position: relative; background: var(--surface2); border-radius: 4px; overflow: hidden; }
.bo-bar i { position: absolute; height: 6px; border-radius: 3px; }
.bo-ticks { display: flex; justify-content: space-between; font-size: 10px; color: var(--text3); margin-top: -4px; }

.bo-rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.bo-row { width: 100%; display: flex; align-items: center; gap: 6px; padding: 6px 4px; border: 0; border-radius: 6px; background: none;
  color: var(--text); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.bo-row:hover:not(:disabled) { background: var(--surface2); }
.bo-row:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.bo-row:disabled { cursor: default; }
.bo-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex: 0 0 10px; }
.bo-rname { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bo-rtime { font-variant-numeric: tabular-nums; color: var(--text2); font-size: 12px; letter-spacing: -.2px; white-space: nowrap; }
.bo-clock { color: var(--green); font-size: 10px; }
.bo-note { font-size: 12px; color: var(--text2); padding: 0 6px 4px 24px; font-style: italic; }
.bo-norows { color: var(--text3); font-size: 13px; padding: 6px; }
.bo-dchecks { list-style: none; margin: 0; padding: 0; font-size: 12px; display: flex; flex-direction: column; gap: 2px; }
.bo-edit { margin-top: auto; }

.bo-err { color: var(--red); }
.bo-warn { color: var(--amber); }
.bo-ok { color: var(--text2); font-size: 13px; margin: 0; }
.bo-dchecks .bo-err::before, .bo-checks .bo-err::before { content: "● "; }
.bo-dchecks .bo-warn::before, .bo-checks .bo-warn::before { content: "▲ "; }

.bo-side { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 12px; }
.bo-panel { padding: 14px; }
.bo-panel h3 { font-size: 14px; margin: 0 0 10px; }
.bo-sum { margin: 0 0 8px; font-size: 13px; font-weight: 600; }
.bo-checks { list-style: none; margin: 0; padding: 0; font-size: 13px; display: flex; flex-direction: column; gap: 4px; max-height: 260px; overflow: auto; }
.bo-checks span { color: var(--text2); font-variant-numeric: tabular-nums; margin-right: 4px; }
.bo-hours { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.bo-hours li { display: grid; grid-template-columns: 80px 1fr 48px; align-items: center; gap: 8px; }
.bo-track { height: 8px; background: var(--surface2); border-radius: 4px; overflow: hidden; }
.bo-track i { display: block; height: 100%; border-radius: 4px; }
.bo-v { text-align: right; font-variant-numeric: tabular-nums; }
.bo-abs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.bo-abs li { position: relative; padding-right: 26px; }
.bo-abs-sub { color: var(--text2); font-size: 12px; }
.bo-abs-del { position: absolute; top: 0; right: 0; }
.bo-legend { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12px; color: var(--text2); margin: 0; }
.bo-legend span { display: inline-flex; align-items: center; gap: 5px; }

/* dialog */
.bo-modal { max-width: 560px; width: 94vw; }
.bo-modal.bo-modal-wide { max-width: 980px; }
.bo-modal-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 20px 18px; border-top: 1px solid var(--border); }
.bo-hint { font-size: 13px; color: var(--text2); margin: 0 0 12px; line-height: 1.45; }
.bo-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.bo-edit-head, .bo-edit-row { display: grid; grid-template-columns: minmax(140px, 1.4fr) 110px 110px minmax(100px, 1.4fr) 32px; gap: 6px; align-items: center; }
.bo-edit-head { font-size: 12px; color: var(--text2); margin-bottom: 4px; }
.bo-edit-row { margin-bottom: 6px; }
.bo-edit-row[data-locked] { opacity: .7; }
.bo-fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.bo-fieldset label, .bo-check { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.bo-wtabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; }
.bo-wtab { min-width: 34px; padding: 6px 8px; border: 1px solid var(--border2); border-radius: 6px; background: var(--surface); color: var(--text); cursor: pointer; font: inherit; }
.bo-wtab.active { background: var(--accent); border-color: var(--accent); color: #041014; font-weight: 700; }
.bo-mwrap { overflow-x: auto; }
.bo-mtable { width: 100%; border-collapse: collapse; font-size: 13px; }
.bo-mtable th { text-align: left; font-weight: 600; color: var(--text2); padding: 4px; }
.bo-mtable td { padding: 3px; }
.bo-mtable select { min-width: 106px; padding: 6px; }
.bo-mslot { display: flex; gap: 4px; }
.bo-mslot input { width: 92px; padding: 6px; }

/* tabelle presenze / report / storico */
.bo-table-wrap { max-height: 55vh; overflow: auto; }
.bo-rt { width: 100%; border-collapse: collapse; font-size: 13px; margin-bottom: 14px; }
.bo-rt caption { text-align: left; font-weight: 700; padding: 4px 0 8px; }
.bo-rt th, .bo-rt td { padding: 6px 8px; border-bottom: 1px solid var(--border); text-align: left; white-space: nowrap; }
.bo-rt th { color: var(--text2); font-weight: 600; position: sticky; top: 0; background: var(--bg2); }
.bo-rt .n { text-align: right; font-variant-numeric: tabular-nums; }
.bo-rt tfoot td { font-weight: 700; border-bottom: 0; }
.bo-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.bo-grid3 { display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: 0 12px; }

@media (max-width: 1100px) {
  .bo-layout { grid-template-columns: 1fr; }
  .bo-side { position: static; }
}
@media (max-width: 640px) {
  .bo-days { grid-template-columns: 1fr; }
  .bo-grid2, .bo-grid3 { grid-template-columns: 1fr; }
  .bo-rt th, .bo-rt td { white-space: normal; }
  .bo-edit-head { display: none; }
  .bo-edit-row { grid-template-columns: 1fr 1fr 40px; grid-template-areas: "op op op" "from to to" "note note rm";
    padding: 8px; border: 1px solid var(--border); border-radius: 8px; }
  .bo-edit-row [data-f=employee_id] { grid-area: op; }
  .bo-edit-row [data-f=from] { grid-area: from; }
  .bo-edit-row [data-f=to] { grid-area: to; }
  .bo-edit-row [data-f=note] { grid-area: note; }
  .bo-edit-row [data-rm] { grid-area: rm; }
  .bo-week-label { margin-left: 0; }
}

/* Etichetta solo per lettori di schermo (usata anche dal filtro città in Dipendenti). */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
