/* App Sala: tavoli, comande, conto, ordini al telefono. */
.home, .conto { padding: 12px max(12px, env(safe-area-inset-right, 0px)) 110px max(12px, env(safe-area-inset-left, 0px)); max-width: 1100px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.schede { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.schede::-webkit-scrollbar { display: none; }
.home-barra { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.home-barra .riassunto { flex: 1; min-width: 140px; font-size: 0.9rem; }
.seg-vista { flex: none; }
.seg-vista button { padding: 0 14px; }
.vuoto { color: var(--muted); padding: 30px 10px; text-align: center; }
.piccolo { font-size: 0.82rem; }

/* tavoli in elenco */
.lista-tav { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.tav { position: relative; min-height: 96px; border-radius: 16px; border: 2px solid var(--line); background: var(--libero); color: var(--ink); cursor: pointer; padding: 10px; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; text-align: left; font: inherit; }
.tav b { font-size: 1.45rem; font-weight: 800; line-height: 1; }
.tav small { font-size: 0.78rem; font-weight: 700; color: var(--muted); }
.tav .info { display: flex; flex-direction: column; gap: 1px; width: 100%; }
.tav.occ { background: var(--occupato); color: var(--occupato-ink); border-color: var(--occupato); }
.tav.occ small { color: inherit; opacity: 0.75; }
.tav.pre { background: var(--warn-soft); border-color: var(--warn); color: var(--ink); }
.tav.pre small { color: var(--warn); opacity: 1; }
.tav .badge { align-self: stretch; text-align: center; margin-top: 6px; font-size: 0.75rem; font-weight: 800; padding: 3px 7px; border-radius: 8px; background: var(--ok); color: #FFFFFF; }
.tav .badge.attesa { background: var(--info); }
.tav.tondo { border-radius: 999px; align-items: center; justify-content: center; text-align: center; }
.tav.tondo .info { align-items: center; }

/* piantina */
.pianta-wrap { overflow-x: auto; border-radius: 16px; border: 1px solid var(--line); background: var(--surface-2) repeating-linear-gradient(0deg, transparent 0 23px, color-mix(in srgb, var(--line) 50%, transparent) 23px 24px), var(--surface-2); }
.pianta { position: relative; width: 100%; min-width: 640px; aspect-ratio: 48 / 30; }
.pianta .tav { position: absolute; min-height: 0; padding: 6px; }
.pianta .tav b { font-size: 1.15rem; }
.pianta .tav .info small:nth-child(n+2) { display: none; }
.pianta .tav .badge { position: absolute; top: -6px; right: -6px; width: 16px; height: 16px; margin: 0; padding: 0; font-size: 0; border-radius: 50%; border: 2px solid var(--surface); }
.pianta .tav { overflow: visible; justify-content: center; }
.pianta .tav b { font-size: clamp(0.9rem, 2.4vw, 1.3rem); }
.pianta .tav small { font-size: 0.7rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }

/* ordini da asporto e domicilio */
.ordini { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.ord { background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.ord-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ord-top b { font-size: 1.1rem; }
.ord-ora { font: 700 1.4rem var(--mono); }
.ord ul { margin: 0; padding-left: 18px; font-size: 0.95rem; }
.ord .stato { font-size: 0.78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; padding: 3px 8px; border-radius: 6px; background: var(--surface-2); align-self: flex-start; }
.ord .stato.in_preparazione { background: var(--info-soft); color: var(--info); }
.ord .stato.pronto { background: var(--ok-soft); color: var(--ok); }
.ord .stato.nuovo { background: var(--warn-soft); color: var(--warn); }
.ord .azioni { display: flex; gap: 8px; flex-wrap: wrap; }
.ord .azioni .b { min-height: 42px; flex: 1; }
.stima, #stimaTesto { font-weight: 700; }
.stima.alto, #stimaTesto.alto { color: var(--bad); }

/* conto */
.conto-testa { display: flex; gap: 8px; align-items: center; position: sticky; top: 61px; z-index: 10; background: var(--bg); padding: 4px 0; }
.conto-testa .seg { flex: 1; }
.conto-testa .seg b { font-family: var(--mono); font-weight: 700; margin-left: 4px; }
.inviati { display: flex; flex-direction: column; gap: 8px; }
.inviati:empty { display: none; }
.uscita-blocco { background: var(--surface); border: 1.5px solid var(--line); border-radius: 14px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.uscita-blocco h3 { font-size: 0.85rem; font-weight: 800; color: var(--muted); display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.uscita-blocco .b { min-height: 40px; }
.inv { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 0.95rem; }
.inv span:first-child { min-width: 0; }
.st { font-size: 0.72rem; font-weight: 800; padding: 2px 7px; border-radius: 6px; white-space: nowrap; background: var(--surface-2); color: var(--muted); }
.st.da_fare { background: var(--info-soft); color: var(--info); }
.st.pronto { background: var(--ok-soft); color: var(--ok); }
.st.attesa { background: var(--surface-2); color: var(--muted); }
.st.servito { background: transparent; color: var(--muted); }
.uscita-barra { display: flex; align-items: center; gap: 10px; }
.uscita-barra .lbl { font-weight: 800; font-size: 0.85rem; color: var(--muted); }
.uscita-barra .seg { flex: 1; max-width: 300px; }
.cerca input { width: 100%; min-height: 46px; font: 600 1rem var(--font); color: var(--ink); background: var(--surface); border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 14px; }
.cerca input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.cats { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; position: sticky; top: 117px; z-index: 9; background: var(--bg); padding: 4px 0; }
.cats::-webkit-scrollbar { display: none; }
.piatti { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.pz { position: relative; min-height: 78px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); text-align: left; padding: 10px 12px; cursor: pointer; display: flex; flex-direction: column; justify-content: space-between; gap: 6px; font: inherit; color: var(--ink); }
.pz b { font-size: 0.98rem; font-weight: 800; line-height: 1.2; }
.pz span { font: 600 0.9rem var(--mono); color: var(--muted); }
.pz.off { opacity: 0.4; cursor: not-allowed; }
.pz .n { position: absolute; top: -7px; right: -7px; min-width: 26px; height: 26px; border-radius: 13px; background: var(--accent); color: var(--accent-ink); font: 800 0.85rem var(--font); display: grid; place-items: center; padding: 0 6px; }
.pz .opz { font: 700 0.7rem var(--font); color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.pz:active { transform: scale(0.98); }
.bozza-barra { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px max(12px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)); background: linear-gradient(to top, var(--bg) 70%, transparent); }
.bozza-barra .b { max-width: 640px; margin: 0 auto; display: flex; box-shadow: 0 10px 26px rgba(0, 0, 0, .25); }

.righe-conto { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; overflow: hidden; }
.righe-conto li button { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; cursor: pointer; font: inherit; color: var(--ink); }
.righe-conto li:last-child button { border-bottom: 0; }
.righe-conto .nome { font-weight: 700; }
.righe-conto .prezzo { font: 600 0.95rem var(--mono); text-align: right; }
.righe-conto .sotto { grid-column: 1 / -1; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 0.82rem; color: var(--muted); }
.righe-conto .vuoto { padding: 20px; }
.totali { display: flex; flex-direction: column; gap: 4px; font: 600 1rem var(--mono); background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px 14px; }
.totali div { display: flex; justify-content: space-between; gap: 10px; }
.totali .tot { font-size: 1.3rem; font-weight: 700; border-top: 2px solid var(--ink); padding-top: 6px; margin-top: 4px; }
.totali .res { color: var(--accent); font-weight: 700; }
.azioni-conto { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.azioni-conto .b { min-height: 56px; font-size: 1.05rem; }

/* fogli */
.gruppi { display: flex; flex-direction: column; gap: 12px; }
.gruppo { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.gruppo legend { width: 100%; display: flex; justify-content: space-between; font-weight: 800; padding: 0 0 4px; }
.gruppo legend small { color: var(--muted); font-weight: 600; }
.gruppo .opz-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 6px; }
.gruppo input { position: absolute; opacity: 0; pointer-events: none; }
.gruppo label { min-height: 48px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface-2); padding: 8px 10px; display: flex; flex-direction: column; justify-content: center; cursor: pointer; font-weight: 700; }
.gruppo label small { color: var(--muted); font: 600 0.8rem var(--mono); }
.gruppo input:checked + label { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.gruppo input:focus-visible + label { outline: 2px solid var(--accent); outline-offset: 2px; }
.gruppo input:disabled + label { opacity: 0.4; }
.passo { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; flex: none; }
.passo button { width: 52px; min-height: 50px; border: 0; background: var(--surface-2); font-size: 1.4rem; font-weight: 800; cursor: pointer; }
.passo output { min-width: 44px; text-align: center; font: 800 1.2rem var(--font); }
.passo.largo { align-self: center; }
.passo.largo output { min-width: 70px; font-size: 1.6rem; }
.bozza { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; max-height: 46vh; overflow-y: auto; }
.bozza li { border: 1.5px solid var(--line); border-radius: 14px; padding: 10px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.bozza .nome { font-weight: 800; }
.bozza .nome small { display: block; font-weight: 600; color: var(--muted); font-size: 0.82rem; }
.bozza .ctrl { grid-column: 1 / -1; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.bozza .ctrl input { flex: 1; min-width: 140px; min-height: 42px; font: 600 0.95rem var(--font); color: var(--ink); background: var(--surface-2); border: 1.5px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.bozza .passo button { width: 42px; min-height: 42px; font-size: 1.2rem; }
.bozza .usc { display: flex; gap: 4px; }
.bozza .usc button { min-width: 42px; min-height: 42px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface-2); font-weight: 800; cursor: pointer; }
.bozza .usc button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.storno { border: 1.5px solid var(--line); border-radius: 14px; padding: 12px; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.storno legend { font-weight: 800; padding: 0 6px; }
.motivi { display: flex; gap: 6px; flex-wrap: wrap; }
.numeri { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.numeri button { min-height: 58px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface-2); font: 800 1.3rem var(--font); cursor: pointer; }
.numeri button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.scegli-righe { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; max-height: 34vh; overflow-y: auto; }
.scegli-righe label { display: flex; gap: 10px; align-items: center; min-height: 46px; border: 1.5px solid var(--line); border-radius: 12px; padding: 6px 10px; cursor: pointer; }
.scegli-righe input { width: 20px; height: 20px; accent-color: var(--accent); }
.scegli-righe span { flex: 1; }
.scegli-righe b { font-family: var(--mono); }
.quote { display: flex; gap: 8px; flex-wrap: wrap; }
.quote button, .quote span { min-height: 44px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface-2); font: 700 1rem var(--mono); cursor: pointer; color: var(--ink); }
.grande-num { font: 700 2.2rem var(--mono); text-align: center; }
.resto { font: 700 1.3rem var(--mono); text-align: center; color: var(--ok); min-height: 1.6em; }
@media (min-width: 900px) {
  .piatti { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
}
.ord.fatto { opacity: 0.6; }
.pz, .tav, .key { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: manipulation; }
.chip small { font-weight: 800; opacity: 0.7; }
#bozzaStima.alto { color: var(--bad); font-weight: 700; }
.bozza li > b { font: 600 0.95rem var(--mono); }
@media (max-width: 480px) {
  .top { gap: 8px; }
  .op span { display: none; }
  .op { padding: 0 6px; }
  .home-barra .riassunto { order: 3; flex-basis: 100%; }
}
.quote .quota-testo { flex-basis: 100%; margin: 0; font-weight: 700; }
.quote button.incassa { background: var(--ok); border-color: var(--ok); color: #FFFFFF; font-family: var(--font); font-weight: 800; }
.storno .passo { align-self: flex-start; }
#telModifica { flex: 1; }

/* ingredienti tolti ("senza"): sempre in evidenza */
.senza { display: inline-block; padding: 1px 7px; border-radius: 6px; background: var(--bad); color: var(--surface); font-weight: 800; font-size: 0.78rem; letter-spacing: 0.02em; }
small.senza { display: inline-block; margin-top: 3px; }
.ord li .senza { margin-left: 6px; }
.ingr-chips { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }
.ingr-chip { min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface-2); font: 700 0.85rem var(--font); color: var(--ink); cursor: pointer; }
.ingr-chip.tolto { background: var(--bad-soft); border-color: var(--bad); color: var(--bad); text-decoration: line-through; }
.gruppo.ingr input:not(:checked) + label { text-decoration: line-through; color: var(--bad); border-style: dashed; border-color: var(--bad); background: var(--bad-soft); }
.bozza .nome small.senza { display: inline-block; color: var(--surface); font-weight: 800; font-size: 0.78rem; }

/* ---------------------------------------------------------------- v4.2: conto, cassa, prenotazioni */
.centro { text-align: center; }
.tav.prenotato { border-style: dashed; border-color: var(--info); }
.tav .badge.prenb { background: var(--info); }
.tav .badge.prenb.conflitto { background: var(--warn); color: #FFFFFF; }
.tav.suggerito { border-color: var(--ok); box-shadow: 0 0 0 2px var(--ok); }

.righe-testa { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.righe-testa .lbl { font-weight: 800; color: var(--muted); font-size: 0.85rem; }
.righe-conto .prezzo s { color: var(--muted); font-weight: 500; }
.righe-conto .omaggio { color: var(--ok); text-transform: uppercase; font: 800 0.78rem var(--font); letter-spacing: 0.04em; }
.righe-conto .pagato { font-weight: 800; color: var(--ok); }
.righe-conto li.tutto-pagato .nome, .righe-conto li.tutto-pagato .prezzo { opacity: 0.55; }
.totali .info { color: var(--muted); font-size: 0.9rem; }

.quote-romana { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.quote-romana .lbl { font-weight: 800; color: var(--muted); font-size: 0.85rem; width: 100%; }
.quota { min-height: 44px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font: 700 1rem var(--mono); color: var(--ink); cursor: pointer; }
button.quota { border-color: var(--accent); }
.quota.pagata { background: var(--ok-soft); border-color: var(--ok-soft); color: var(--ok); cursor: default; }

.pagamenti { background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 10px 14px; display: flex; flex-direction: column; gap: 6px; }
.pagamenti h3 { font-size: 0.85rem; font-weight: 800; color: var(--muted); }
.pag { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 4px 10px; align-items: center; font-size: 0.92rem; padding: 6px 0; border-top: 1px solid var(--line); }
.pag:first-of-type { border-top: 0; }
.pag > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pag b { font-family: var(--mono); }
.pag.annullato > span, .pag.annullato b { text-decoration: line-through; color: var(--muted); }
.pag.annullato small { text-decoration: none; }
.mini { min-height: 34px; padding: 0 10px; border-radius: 9px; border: 1.5px solid var(--line); background: var(--surface-2); font-weight: 800; font-size: 0.82rem; cursor: pointer; color: var(--ink); }
small.sc { font-weight: 700; color: var(--muted); }
small.sc.emesso, span.sc.emesso { color: var(--ok); }
small.sc.errore, small.sc.incerto, span.sc.errore, span.sc.incerto { color: var(--bad); }

.avviso-sc { display: flex; flex-direction: column; gap: 8px; }
.sc-avviso { background: var(--bad-soft); border: 1.5px solid var(--bad); border-radius: 14px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.sc-avviso .azioni { display: flex; gap: 8px; flex-wrap: wrap; }
.sc-avviso .b { min-height: 40px; flex: 1; }

.inc-cosa { text-align: center; font-weight: 700; color: var(--muted); margin-top: -8px; }
.mancia { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.mancia input { flex: 0 1 120px; }
.mancia .quote button { min-height: 40px; font-size: 0.9rem; }
.spunta { display: flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 700; cursor: pointer; }
.spunta input { width: 22px; height: 22px; accent-color: var(--accent); }
#incForm { display: flex; flex-direction: column; gap: 12px; }
.pos-attesa { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 14px 6px; border-radius: 16px; background: var(--info-soft); }
.pos-attesa p { font-weight: 800; font-size: 1.05rem; }
.pos-attesa .giro { width: 38px; height: 38px; border-radius: 50%; border: 4px solid color-mix(in srgb, var(--info) 25%, transparent); border-top-color: var(--info); }
@media (prefers-reduced-motion: no-preference) { .pos-attesa .giro { animation: gira 0.9s linear infinite; } }
@keyframes gira { to { transform: rotate(360deg); } }
.pos-attesa.fine .giro { display: none; }
.pos-attesa.fine.ok { background: var(--ok-soft); }
.pos-attesa.fine.ko, .pos-attesa.fine.annullato { background: var(--bad-soft); }
.pos-attesa.fine.incerto { background: var(--warn-soft); }
.pos-az { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; width: 100%; }
.pos-az .b { flex: 1; min-width: 140px; }
.pos-az p { width: 100%; }

.riga-qta { display: flex; align-items: center; gap: 10px; }
.riga-qta .lbl { font-weight: 800; color: var(--muted); font-size: 0.85rem; }
.prezzo-riga { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; align-items: end; }
.prezzo-riga .b { min-height: 46px; }
.passo.mini button { width: 36px; min-height: 36px; font-size: 1.1rem; }
.passo.mini output { min-width: 30px; font-size: 1rem; }
.scegli-righe li { display: flex; gap: 8px; align-items: center; }
.scegli-righe li label { flex: 1; min-width: 0; }

/* lista d'attesa degli ordini (asporto) */
.att-ordini { background: var(--warn-soft); border: 1.5px solid var(--warn); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.att-ordini h3 { font-size: 1rem; font-weight: 800; }
.att-o { background: var(--surface); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.att-o .azioni { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.att-o .azioni input { min-height: 42px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--ink); font: 700 1rem var(--mono); padding: 0 8px; }
.att-o .azioni .b { min-height: 42px; }

/* prenotazioni */
.giorno-nav { display: inline-flex; align-items: center; gap: 6px; }
.giorno-nav b { min-width: 92px; text-align: center; font-size: 1.05rem; cursor: pointer; }
.pren-corpo, .cassa-corpo { display: flex; flex-direction: column; gap: 14px; }
.pren-sez { display: flex; flex-direction: column; gap: 8px; }
.pren-sez > h3, .pren-sez > summary { font-size: 0.9rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.pren-sez > summary { cursor: pointer; min-height: 36px; display: flex; align-items: center; }
.pren, .chiuso { background: var(--surface); border: 1.5px solid var(--line); border-left: 6px solid var(--info); border-radius: 14px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.pren.st-richiesta { border-left-color: var(--warn); }
.pren.st-arrivata { border-left-color: var(--ok); }
.pren.st-offerta { border-left-color: var(--accent); }
.pren.st-completata, .pren.st-annullata, .pren.st-noshow, .pren.st-scaduta { border-left-color: var(--line); opacity: 0.7; }
.pren.walk, .pren.attesa { border-left-color: var(--warn); }
.chiuso { border-left-color: var(--line); }
.pren-top { display: flex; align-items: baseline; gap: 10px; }
.pren-top b { flex: 1; min-width: 0; font-size: 1.08rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pren-ora { font: 700 1.2rem var(--mono); }
.pren-pers { font-weight: 800; white-space: nowrap; }
.pren-info { display: flex; flex-wrap: wrap; gap: 6px 10px; font-size: 0.85rem; color: var(--muted); align-items: center; }
.stato-p { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; padding: 3px 8px; border-radius: 6px; background: var(--info-soft); color: var(--info); }
.stato-p.richiesta, .stato-p.attesa { background: var(--warn-soft); color: var(--warn); }
.stato-p.arrivata, .stato-p.completata { background: var(--ok-soft); color: var(--ok); }
.stato-p.offerta { background: color-mix(in srgb, var(--accent) 15%, var(--surface)); color: var(--accent); }
.stato-p.annullata, .stato-p.noshow, .stato-p.scaduta { background: var(--surface-2); color: var(--muted); }
.pren-info .manca, .pren-info .ritardo { color: var(--bad); font-weight: 800; }
.pren-note { font-size: 0.9rem; background: var(--surface-2); border-radius: 8px; padding: 6px 8px; }
.pren .azioni, .chiuso .azioni { display: flex; gap: 8px; flex-wrap: wrap; }
.pren .azioni .b, .chiuso .azioni .b { min-height: 42px; flex: 1 1 auto; }
.orari-pren { display: grid; grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 6px; max-height: 190px; overflow-y: auto; padding: 2px; }
.orari-pren .ora { min-height: 40px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface); font: 700 0.95rem var(--mono); cursor: pointer; color: var(--ink); }
.orari-pren .ora.pieno { background: var(--surface-2); color: var(--muted); text-decoration: line-through; }
.orari-pren .ora[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); text-decoration: none; }
.tavoli-pren { display: flex; flex-wrap: wrap; gap: 6px; }
#fPren, #fWalk { display: flex; flex-direction: column; gap: 12px; }
#fPren .riga2 input[type="time"] { min-height: 42px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--ink); font: 700 1rem var(--mono); padding: 0 8px; }
#fPren .riga2 { align-items: center; }
.qr-grande { width: min(280px, 80vw); margin: 0 auto; background: #FFFFFF; padding: 10px; border-radius: 12px; }
.qr-grande svg { display: block; width: 100%; height: auto; }
#siediTavoli { max-height: 60vh; overflow-y: auto; padding: 4px; }

/* cassa */
.cassa-griglia { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.cassa-box { background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; font: 600 0.95rem var(--mono); }
.cassa-box h3 { font: 800 0.9rem var(--font); color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px; }
.cassa-box > div { display: flex; justify-content: space-between; gap: 10px; }
.cassa-box .tot { font-weight: 800; border-top: 2px solid var(--ink); padding-top: 4px; margin-top: 2px; }
.cassa-box .info { color: var(--muted); font-size: 0.88rem; }
.cassa-box p { font-family: var(--font); }
@media (max-width: 560px) {
  .prezzo-riga { grid-template-columns: 1fr 1fr; }
  .prezzo-riga .campo { grid-column: 1 / -1; grid-row: 1; }
  .home-barra .b { flex: 1 1 auto; }
}
#tConto { display: flex; flex-direction: column; gap: 12px; }
#tConto .righe-testa { margin-bottom: -4px; }
#vistaPren:not([hidden]), #vistaCassa:not([hidden]), #vistaAsporto:not([hidden]) { display: flex; flex-direction: column; gap: 12px; }
