/* dashboard/css/60-refinements.css — estratto da app.css (2026-07, split senza build). */
/* ===== Chip / filter-pill: nessuna sottolineatura (anche se sono <a>) ===== */
.chip, .filter-pill, .sub-chip { text-decoration: none; color: inherit; }
.chip:hover, .filter-pill:hover, .sub-chip:hover { text-decoration: none; }

/* Lavatrici/Asciugatrici usano la regola globale .section-title (stessa di Andamento/Impostazioni/Domotica) */

/* ===== Modal Macchina · field-row e modal-pane attivo (compl. al toggle JS) ===== */
.field-row { display: flex; gap: 12px; margin-bottom: 12px; }
.field-row .field { flex: 1; }
.modal-pane.active { display: block; }

/* ===== Macchina card: cliente row + hopper info + program info ===== */
.machine-card .meta-line { display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: var(--ink-3); margin-top: 8px; padding: 0 16px 12px; }
.machine-card .meta-line .meta-left { font-weight: 600; }
.machine-card .meta-line .meta-right { color: var(--ink-3); }

/* Background/padding/radius utility per row interne ai modal (mockup pattern) */
.u-bg-pad-radius { background: var(--bg); padding: 12px 14px; border-radius: 10px; margin-bottom: 8px; }

/* ===== Goal card e mkt-cta-free ora <a>: rimuovi underline ===== */
a.goal-card, a.mkt-cta-free { color: inherit; text-decoration: none; }
a.goal-card:hover, a.mkt-cta-free:hover { text-decoration: none; }

/* ===== DOB widget dentro modal cliente (cust-pane) =====
   1. Trigger compatto (lukew: proporzionato al contenuto "12 Giugno 1982").
   2. Telefono prende lo spazio rimanente, DOB resta auto-width.
   3. Popover ancorato a destra: cust-pane ha overflow-y:auto che implica
      overflow-x:clip, quindi un popover left:0 esce e viene tagliato. */
.cust-pane .dt-field { width: auto; }
.cust-pane .dt-trigger {
  width: auto;
  min-width: 200px;
  background: var(--surface);
  text-align: left;
}
.cust-pane .dt-trigger .dt-display { text-align: left; }
.cust-pane .dt-popover { left: auto; right: 0; }

/* Link inline brand (no underline) dentro note descrittive del modal cliente */
.cust-pane .u-meta-note-sm a { color: var(--brand); text-decoration: none; font-weight: 600; }
.cust-pane .u-meta-note-sm a:hover { text-decoration: underline; }
/* Link azione dentro una dom-channel-row del modal cliente (es. "Cambia" gruppo) */
.cust-pane .dom-channel-row a { color: var(--brand); text-decoration: none; font-weight: 600; font-size: 13px; }
.cust-pane .dom-channel-row a:hover { text-decoration: underline; }

/* Re-invio magic-link: link di testo brand sotto l'email (stile .oggi-azioni-all
   "Vedi tutte le azioni"), niente riga bordata né icona. */
.resend-magiclink-link {
  display: inline-block;
  margin-top: 8px;
  padding: 0;
  border: 0;
  background: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--brand);
  cursor: pointer;
}
.resend-magiclink-link:hover { color: var(--brand-hover); text-decoration: underline; }

/* ===== Profilo cliente (modal): field-system allineato 1:1 al form "Dati
   personali" dell'app cliente (.form-screen). Scoped al pane Profilo per non
   toccare gli altri tab/modali che usano .field-row flex + .field--w-* a pixel
   della dashboard. Larghezze percentuali su campi standalone, righe a colonne. */
.cust-pane [data-cpane="profile"] .field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
.cust-pane [data-cpane="profile"] .field-row .field { margin-bottom: 18px; min-width: 0; }
/* min-width:0 anche sugli input: in grid hanno min-width intrinseca (~20 char) che
   i track fr non comprimono → la riga CAP/Città/Prov deborderebbe (Prov tagliata). */
.cust-pane [data-cpane="profile"] .field input, .cust-pane [data-cpane="profile"] .field select { min-width: 0; }
.cust-pane [data-cpane="profile"] .field-row--phone-dob { grid-template-columns: 1fr 50%; }  /* Data nascita 50% (col mese corto ci sta); Telefono prende il resto */
.cust-pane [data-cpane="profile"] .field-row--loc { grid-template-columns: 3fr 5fr 2fr; }    /* CAP 30 · Città 50 · Prov 20 */
.cust-pane [data-cpane="profile"] .field-row--loc:has([data-b2b-province].u-hidden) { grid-template-columns: 3fr 7fr; }
.cust-pane [data-cpane="profile"] .field-row--loc label { white-space: nowrap; }
.cust-pane [data-cpane="profile"] .field--w-30 { width: 30%; min-width: 110px; }
.cust-pane [data-cpane="profile"] .field--w-40 { width: 40%; min-width: 140px; }
.cust-pane [data-cpane="profile"] .field--w-50 { width: 50%; min-width: 170px; }  /* vero 50% dove c'è spazio; 170px = minimo per non tagliare "Scegli il Paese" */
.cust-pane [data-cpane="profile"] .field--w-60 { width: 60%; min-width: 170px; }
.cust-pane [data-cpane="profile"] .field--w-80 { width: 80%; min-width: 200px; }
/* DOB nella colonna 50% della riga: lascia riempire la cella (no min-width 200px). */
.cust-pane [data-cpane="profile"] .dt-trigger { min-width: 0; }

/* Sezioni Gruppi di sistema / manuali: la classe .section-title fa già tutto,
   bastano un paio di tweak per strong inline + bottone allineato. */
.section-title strong { color: var(--ink); font-weight: 800; }

/* ===== Modal "Aggiungi a campagna" · righe campagna selezionabili (radio) ===== */
.promo-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px; cursor: pointer; transition: border-color 120ms ease, background 120ms ease; }
.promo-row:hover { border-color: var(--brand); background: var(--brand-soft); }
.promo-row:has(input[type="radio"]:checked) { border-color: var(--brand); background: var(--brand-soft); }
.promo-row input[type="radio"] { margin: 0; flex-shrink: 0; accent-color: var(--brand); }
/* Variante multi-selezione (sheet "Aggiungi clienti" al gruppo): checkbox nativo. */
.promo-row input[type="checkbox"] { margin: 0; flex-shrink: 0; accent-color: var(--brand); }
.promo-row:has(input[type="checkbox"]:checked) { border-color: var(--brand); background: var(--brand-soft); }
/* `hidden` (ricerca gaddFilter) deve vincere sul display:flex della riga. */
.promo-row[hidden] { display: none; }
[data-modal="gruppo-add-clienti"] [data-gadd-list] { max-height: 45vh; overflow-y: auto; }
.promo-row-ico { width: 40px; height: 40px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.promo-row-body { flex: 1; min-width: 0; }
.promo-row-name { font-size: 15px; font-weight: 700; color: var(--ink); }
.promo-row-meta { font-size: 12px; color: var(--ink-3); margin-top: 2px; line-height: 1.3; }
.promo-row--in { opacity: 0.55; cursor: not-allowed; }
.promo-row--in:hover { border-color: var(--line); background: transparent; }
.cat-list-wrap { margin-bottom: 12px; }

/* ===== Blocco DESIDERATA (modal macchina · funzioni cassa POS non ancora API) ===== */
.desiderata-block { margin-top: 18px; padding: 14px; border: 1px dashed var(--ink-3); border-radius: 12px; background: var(--bg); opacity: 0.85; }
.desiderata-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.desiderata-badge { font-size: 10px; font-weight: 800; letter-spacing: 0.1em; color: var(--brand); background: var(--brand-soft); padding: 3px 8px; border-radius: 4px; }
.desiderata-title { font-size: 12px; color: var(--ink-3); font-weight: 600; flex: 1; min-width: 0; }
.desiderata-block .field input:disabled { opacity: 0.6; cursor: not-allowed; background: var(--bg); }
.desiderata-block .toggle-ios[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; pointer-events: none; }
.prices-group-body--2col { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ===== Tabella prezzi per-slot (asciugatrice) · stile gestionale Bloomest web ===== */
.slot-prices-table { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 13px; }
.slot-prices-table thead tr.slot-th-group th { background: var(--brand); color: #fff; padding: 10px 6px; font-weight: 800; text-align: center; font-size: 13px; vertical-align: top; }
.slot-prices-table thead tr.slot-th-sub th { background: transparent; color: var(--ink); padding: 10px 6px 8px; font-weight: 700; text-align: center; font-size: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.slot-prices-table tbody td { padding: 10px 6px; text-align: center; vertical-align: middle; border-bottom: 1px solid var(--line); }
/* Palette unica azzurrina per gruppi colonne (richiesta Andrea 2026-05-14):
   bandone = #C7DBED carico (ink navy), sub+tbody = #EEF4FA tenue. */
.slot-prices-table thead tr.slot-th-group th.col-time,
.slot-prices-table thead tr.slot-th-group th.col-cash,
.slot-prices-table thead tr.slot-th-group th.col-card { background: #C7DBED; color: #1F4977; }
.slot-prices-table thead tr.slot-th-group th.col-time .macro-alias,
.slot-prices-table thead tr.slot-th-group th.col-cash .macro-alias,
.slot-prices-table thead tr.slot-th-group th.col-card .macro-alias { color: rgba(0,0,0,0.55); }
.slot-prices-table thead tr.slot-th-sub th.col-time,
.slot-prices-table thead tr.slot-th-sub th.col-cash,
.slot-prices-table thead tr.slot-th-sub th.col-card,
.slot-prices-table tbody td.col-time,
.slot-prices-table tbody td.col-cash,
.slot-prices-table tbody td.col-card { background: #EEF4FA; }
.slot-prices-table tbody td:first-child { font-weight: 700; color: var(--ink); }
.slot-prices-table .slot-cell-n { font-weight: 700; color: var(--ink); }
.slot-prices-table .slot-cell-readonly { color: var(--ink); font-weight: 600; }
.slot-prices-table input { width: 70px; max-width: 70px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font-size: 16px; font-weight: 600; font-family: inherit; text-align: right; box-sizing: border-box; }
.slot-prices-table input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand-soft); }
.slot-prices-table .pct-wrap,
.listini-table .pct-wrap { display: inline-flex; align-items: center; gap: 4px; justify-content: flex-end; width: 100%; }
.slot-prices-table .pct-wrap input,
.listini-table .pct-wrap input { width: 70px; max-width: 70px; }
.slot-prices-table .pct-wrap .pct-suffix,
.listini-table .pct-wrap .pct-suffix { color: var(--ink-3); font-weight: 700; font-size: 13px; }
.slot-prices-table .pct-derived { display: block; margin-top: 3px; text-align: right; font-size: 11px; color: var(--ink-3); font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* Allineamento a destra per colonne valori (Andrea 2026-05-14) */
.slot-prices-table tbody td.col-cash,
.slot-prices-table tbody td.col-card,
.listini-table tbody td.col-cash,
.listini-table tbody td.col-card { text-align: right; }
/* Vertical-align top sui cell valori in modo che gli input box siano allineati
   alla stessa altezza in tutte e 4 le colonne (slot 1 ha derived sotto Tipo 1/2,
   senza top alignment gli input apparirebbero sfalsati verticalmente). */
.slot-prices-table tbody td.col-cash,
.slot-prices-table tbody td.col-card { vertical-align: top; }
.slot-prices-table tbody td.col-cash .slot-cell-readonly,
.slot-prices-table tbody td.col-card .slot-cell-readonly,
.listini-table tbody td.col-cash .slot-cell-readonly,
.listini-table tbody td.col-card .slot-cell-readonly { display: inline-block; text-align: right; }
/* Anti-orfano "Tipo 0" su sub-alias multi-riga */
.sub-alias .nowrap { white-space: nowrap; }

/* ===== Chip status per Ticket (3 stati: aperto/in_lavorazione/chiuso) ===== */
.chip-status { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: 0.02em; }
.chip-status.chip-aperto { background: rgba(220, 53, 69, 0.12); color: var(--danger); }
.chip-status.chip-in_lavorazione { background: rgba(245, 158, 11, 0.16); color: #B45309; }
.chip-status.chip-chiuso { background: rgba(120, 120, 120, 0.15); color: var(--ink-3); }

/* ===== Collapsible details (registra nuovo ticket nel pane) ===== */
.cust-collapsible { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin: 8px 0 14px; background: var(--surface); }
.cust-collapsible summary { display: flex; align-items: center; justify-content: space-between; cursor: pointer; list-style: none; margin: 0; padding: 0; }
.cust-collapsible summary::-webkit-details-marker { display: none; }
.cust-collapsible summary svg { transition: transform 0.2s ease; }
.cust-collapsible[open] summary svg { transform: rotate(180deg); }
.cust-collapsible[open] summary { margin-bottom: 12px; }

/* ===== Menu group/row · liste compatte clickabili (lista ticket, ecc.) ===== */
.menu-group { display: flex; flex-direction: column; gap: 6px; padding: 0 var(--page-pad-x); margin: 8px 0 16px; }
.menu-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); flex-wrap: nowrap; min-width: 0; }
.menu-row:hover { border-color: var(--brand); }
.menu-row:active { background: var(--bg); }
.menu-row .ico { width: 36px; height: 36px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; background: var(--bg); color: var(--ink-3); }
.menu-row .ico.problem { background: rgba(245, 158, 11, 0.16); color: #B45309; }
.menu-row .ico.brand { background: var(--brand-soft); color: var(--brand); }
.menu-row .ico.wa { background: rgba(120, 120, 120, 0.15); color: var(--ink-3); }
.menu-row .ttl { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; color: var(--ink); overflow: hidden; }
.menu-row .ttl small { display: block; color: var(--ink-3); font-size: 12px; font-weight: 500; margin-top: 2px; line-height: 1.3; }
.menu-row .arr { width: 14px; height: 14px; color: var(--ink-3); flex-shrink: 0; margin-left: auto; }

/* ===== Empty state lista (cface-empty) ===== */
.cface-empty { padding: 32px 16px; text-align: center; }
.cface-empty .ttl { font-size: 15px; font-weight: 700; color: var(--ink); margin-bottom: 6px; }
.cface-empty .sub { font-size: 13px; color: var(--ink-3); line-height: 1.4; max-width: 320px; margin: 0 auto; }

/* ===== Sub-tab Ticket: filter-row chip wrap su mobile ===== */
[data-cli-view="ticket"] .filter-row { padding: 12px var(--page-pad-x) 8px; flex-wrap: wrap; overflow-x: visible; }
/* l'eyebrow Ticket usa il padding standard di .section-title (20px/8px), come Gruppi/Lista — niente override */

/* ===== Promo · card bonus (Bonus reg. + Compleanno): metric-rows bianca con
   riga toggle-ios in testa e sezioni form sotto (bordo top al posto del
   border-bottom della row, cosi' la card chiusa non ha bordi appesi). ===== */
.bonus-card .metric-row { border-bottom: none; }
.bonus-card .bonus-card-body { border-top: 1px solid var(--line); padding: 14px 16px; }
.bonus-card .bonus-card-body .field { margin-bottom: 0; }
/* importo € stretto (form-design regola 1, min-width per il font 16px mobile anti-zoom) */
.bonus-card .fld-mid { max-width: 9rem; min-width: 7rem; }
.bonus-card-note { padding: 0 16px 14px; margin: 0; font-size: 12px; color: var(--ink-3); line-height: 1.4; }
/* Pool QR compleanno · righe statistiche nude dentro la bonus-card (niente
   .metric-rows annidata: card-in-card raddoppiava shadow e margini). */
.qr-pool-stats { margin: 4px 0 12px; }
.qr-pool-stats .row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.qr-pool-stats .row:last-child { border-bottom: none; }
.qr-pool-stats .lbl { color: var(--ink-2); }
.qr-pool-stats .val { font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
/* File-picker custom (il control nativo del browser e' in inglese e non
   stilizzabile). position:relative: ancora l'input nascosto (abspos,
   dimensioni 0) al wrapper — mai un abspos nascosto senza ancestor
   posizionato (bug zoom iOS 2026-07-05). */
.qr-pool-steps { margin: 4px 0 12px; padding-left: 20px; font-size: 13px; color: var(--ink-2); line-height: 1.55; }
.qr-pool-steps li { margin-bottom: 6px; }
.qr-pool-steps li::marker { font-weight: 700; color: var(--ink); }
.field-hint { margin: 4px 0 0; font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.file-pick { position: relative; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.file-pick-count { font-size: 13px; color: var(--ink-3); }
.file-pick-input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
/* Il popover del datepicker vive dentro la .bonus-card (overflow:hidden per
   il border-radius): a calendario aperto la card lo lascia uscire, altrimenti
   esce tagliato. */
.bonus-card:has(.dt-field.open) { overflow: visible; }
/* nota descrittiva sotto un .section-title (pane paddato, niente padding-x proprio) */
.sec-note { margin: -2px 0 10px; font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.metric-row > .pill-btn { flex-shrink: 0; }
/* disclosure dentro una card metric-rows (anteprima compleanni): si fonde come riga */
.metric-rows .reservations-disclosure { margin: 0; box-shadow: none; border-radius: 0; border-bottom: 1px solid var(--line); }
.metric-rows .reservations-disclosure summary { font-size: 14px; color: var(--ink-2); font-weight: 400; }

/* Messaggio in cassa */
/* Il pane vive dentro la gm-card (28px di padding suo): il padding di pagina
   della .mkt-intro qui è solo indent spurio rispetto a campi e storico. */
#cassa-msg-pane .mkt-intro { padding-left: 0; padding-right: 0; }
.cash-msg-range { display:flex; align-items:flex-end; gap:10px; flex-wrap:wrap; }
/* Coppia date su UNA riga da 480px in su: col .dt-display a 16px (anti-zoom iOS,
   2026-07-20) la larghezza intrinseca dei trigger supera i 220px di min-width e
   la coppia non entra più nei ~484px utili della card 540 → i campi si
   spartiscono la riga elasticamente (pattern .hh-dates). La freccia è centrata
   sull'altezza del trigger (42px). Sotto i 480px la colonna mobile è invariata. */
.cash-msg-range .dt-field { flex: 1 1 100%; min-width: 0; }
.cash-msg-range .dt-field .dt-trigger { min-width: 0; width: 100%; }
/* In colonna la freccia occuperebbe una riga propria senza dire nulla:
   spenta come fa .mov-range su mobile. */
.cash-msg-range .range-arrow { display: none; }
@media (min-width: 480px) {
  .cash-msg-range .dt-field { flex: 1 1 0; }
  .cash-msg-range .range-arrow { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 42px; align-self: flex-end; color: var(--ink-3); font-size: 18px; line-height: 1; }
}
.cash-msg-counter { font-size:12px; color:var(--ink-3,#9ca3af); text-align:right; }
.cash-msg-history-title { font-size:14px; font-weight:700; margin:18px 0 8px; color:var(--ink); }
.cash-msg-list { margin-top:8px; }
/* Riga su due livelli (2026-07-20): testata periodo+badge/azioni, testo sotto
   full-width — il vecchio layout orizzontale su mobile strizzava il testo in
   una colonnina illeggibile (period nowrap + URL non spezzabili). */
.cash-msg-row { display:flex; flex-direction:column; gap:4px; padding:10px 0; border-bottom:1px solid var(--line,#e5e7eb); }
.cash-msg-head { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.cash-msg-period { font-size:12px; color:var(--ink-2,#6b7280); white-space:nowrap; }
/* min-width:0 + overflow-wrap: le URL (www.bloomestfilottrano.it) sono parole
   lunghe non spezzabili — senza, il min-content della row allarga la gm-card
   oltre il viewport mobile (taglio a sinistra, 2026-07-20). */
.cash-msg-text { min-width:0; overflow-wrap:anywhere; font-size:13px; color:var(--ink); }
.cash-msg-actions { display:flex; align-items:center; gap:2px; }
.cash-msg-del { background:none; border:none; cursor:pointer; color:var(--ink-3); padding:4px; line-height:1; }
.cash-msg-del:hover { color:var(--danger,#ef4444); }
.cash-msg-reuse { background:none; border:none; cursor:pointer; color:var(--ink-3); padding:4px; line-height:1; }
.cash-msg-reuse:hover { color:var(--brand); }
.cash-msg-history-hint { font-size:13px; color:var(--ink-3); margin:8px 0; }
.badge-ok { background:#dcfce7; color:#166534; border-radius:6px; padding:1px 6px; font-size:11px; }
.badge-external { background:#e0e7ff; color:#3730a3; border-radius:6px; padding:1px 6px; font-size:11px; }

