/* Gestionale ristoranti: stile dei mockup di questo prodotto (partials/*.html).
   Si carica dopo style.css del motore (site.css in content.mjs). Colori dei
   locali inventati: rosso vino (Osteria Fil di Ferro) e blu notte (Bistrot Ventidue). */

:root {
  --rs-wine: #7a2430;
  --rs-wine-deep: #2a1216;
  --rs-in: #cfe5d4;      /* tavolo: arrivati */
  --rs-bk: #f7d3c2;      /* tavolo: prenotato */
  --rs-no: #f3c4c4;      /* tavolo: no-show */
  --rs-warn: #a33a1d;
}

/* Il motore usa il verde acqua per tessere e iniziali: qui rosso vino. */
.ui-pass { background: var(--rs-wine-deep); }
.ui-pass .mark { color: var(--rs-wine-deep); }
.mark { background: var(--rs-wine); }
.ref-avatar { background: var(--rs-wine); }
.ui-status .dot { background: var(--rs-wine); }

/* Allergeni: icona (sigla nel cerchio) + testo */
.rs-algs { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 6px; font-size: 10.5px; color: #6b6b70; }
.rs-algs i { display: inline-grid; place-items: center; min-width: 17px; height: 17px; padding: 0 3px; border-radius: 999px; font-style: normal; font-size: 8.5px; font-weight: 600; color: #202020; margin-inline-end: -2px; }
.a-g { background: #f2d9a6; }
.a-l { background: #dde7f3; }
.a-u { background: #f6e7a8; }
.a-se { background: #d5ead0; }
.a-so { background: #ecd6e6; }

/* Hero: carta del menu (scura), colonna della sala, tavolo libero, gift card */
.rs-menu-card { display: grid; gap: 0; }
.rs-mc-dish { margin-top: 12px; display: grid; gap: 5px; }
.rs-mc-dish > div { display: flex; justify-content: space-between; gap: 8px; }
.rs-mc-dish strong { font-weight: 500; font-size: 13px; }
.rs-mc-dish b { font-weight: 500; font-size: 12px; color: var(--accent); }
.rs-menu-card .rs-algs { color: rgba(255,255,255,.7); }
.stage .rs-menu-card .qr { width: 58px; margin-top: 10px; }
.rs-sala-col { display: grid; gap: 6px; }
.rs-si { display: grid; grid-template-columns: 40px 1fr; gap: 8px; align-items: start; padding: 7px 8px; border-radius: 8px; background: #f5f5f5; }
.rs-si b { font-family: var(--font-mono); font-weight: 500; font-size: 11px; color: #6b6b70; padding-top: 1px; }
.rs-si strong { display: block; font-weight: 500; font-size: 12.5px; line-height: 1.25; }
.rs-si span { font-size: 11px; color: #6b6b70; }
.rs-si-hl { background: var(--rs-bk); box-shadow: inset 3px 0 0 var(--rs-wine); }
.rs-si-hl b, .rs-si-hl span { color: #5a2a1c; }
.rs-gift { background: linear-gradient(140deg, #3b151b, #7a2430); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.1), var(--shadow-float); }
.rs-gift .cap, .rs-gift .ui-meta { color: rgba(255,255,255,.75); }
.rs-gift .mark { background: var(--accent); color: var(--rs-wine-deep); }
.rs-gift .ui-big { margin: 10px 0 4px; }
.rs-free { background: #1c1c1c; color: #fff; box-shadow: inset 0 0 0 1px #292929, var(--shadow-float); }
.rs-free .cap, .rs-free .ui-meta { color: #a8a8aa; }
.rs-free .ui-title { color: var(--accent); }

/* Pannello dei mockup nelle sezioni split (chiare o scure) */
.rs-panel { position: relative; display: flex; justify-content: center; padding: 40px clamp(16px, 3vw, 40px); background: var(--surface-raised); border-radius: var(--radius-lg); box-shadow: var(--stroke-hairline); }
.rs-chips, .rs-slots { display: flex; flex-wrap: wrap; gap: 5px; }
.rs-chips span, .rs-slots span { padding: 5px 9px; border-radius: 999px; background: #f0f0f1; font-size: 11px; }
.rs-slots span { font-family: var(--font-mono); border-radius: 7px; }
.rs-chips .on, .rs-slots .on { background: var(--brand, var(--rs-wine)); color: var(--brand-ink, #fff); }
.rs-covers span { min-width: 26px; text-align: center; }
.rs-second { position: relative; box-shadow: inset 0 0 0 1px #d9d9dc; background: #fff !important; }
.rs-second em { display: block; font-family: var(--font-sans, inherit); font-style: normal; font-size: 8.5px; color: #6b6b70; }
.rs-toggle { display: inline-flex; padding: 3px; border-radius: 8px; background: #f0f0f1; font-size: 11px; justify-self: start; }
.rs-toggle span { padding: 4px 10px; border-radius: 6px; color: #6b6b70; }
.rs-toggle .on { background: #fff; color: #202020; box-shadow: 0 1px 2px rgba(0,0,0,.08); }

/* Prenotazione dal telefono + promemoria */
.rs-booking { padding-bottom: 150px; }
.rs-booking .phone { width: 250px; }
.rs-bubble { position: absolute; inset-inline-end: clamp(12px, 3vw, 32px); bottom: 24px; width: min(280px, 72%); }
.rs-bubble p { font-size: 12.5px; color: #3a3a3f; margin: 6px 0 10px; }
.rs-bubble-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.rs-bubble-tags span { padding: 5px 8px; border-radius: 8px; font-size: 11px; font-weight: 500; background: #f0f0f1; }
.rs-bubble-tags span:last-child { background: #dcf3e2; color: #135c2b; }

/* Sala del turno */
.rs-sala-panel { flex-direction: column; align-items: center; gap: 12px; }
.rs-sala { width: 100%; max-width: 440px; display: grid; gap: 12px; box-shadow: inset 0 0 0 1px #e9e9eb, var(--shadow-float); }
.rs-sala-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.rs-sala-top strong { font-weight: 500; font-size: 15px; }
.rs-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rs-kpis div { background: #f5f5f5; border-radius: 10px; padding: 8px 10px; display: grid; gap: 2px; }
.rs-kpis strong { font-size: 17px; font-weight: 500; }
.rs-kpis .ok { background: #e3f1e6; }
.rs-floor { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 14px; border-radius: 12px; background: repeating-linear-gradient(90deg, #fafafa 0 22px, #f4f4f5 22px 23px); box-shadow: inset 0 0 0 1px #ececee; }
.rs-floor .t { display: grid; place-items: center; align-content: center; height: 54px; border-radius: 10px; font-family: var(--font-mono); font-size: 11px; font-weight: 500; color: #202020; }
.rs-floor .t small { font-size: 9px; color: #4a4a4f; font-weight: 400; }
.rs-floor .r2 { border-radius: 50%; width: 54px; justify-self: center; }
.rs-floor .r8 { grid-column: span 1; }
.t-in { background: var(--rs-in); }
.t-bk { background: var(--rs-bk); }
.t-free { background: #fff; box-shadow: inset 0 0 0 1.5px #c9c9cc; }
.t-no { background: repeating-linear-gradient(135deg, var(--rs-no) 0 6px, #fbe3e3 6px 12px); }
.t-pulse { box-shadow: inset 0 0 0 2px var(--accent), 0 0 0 4px color-mix(in srgb, var(--accent) 25%, transparent); }
.rs-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 11px; color: #6b6b70; }
.rs-legend span { display: inline-flex; align-items: center; gap: 5px; }
.rs-legend i { width: 10px; height: 10px; border-radius: 3px; }
.rs-notice { display: flex; align-items: center; gap: 12px; width: 100%; max-width: 440px; box-shadow: inset 0 0 0 1px #e9e9eb, var(--shadow-float); }

/* Menu QR + registro allergeni */
.rs-menu-panel { padding-bottom: 170px; }
.rs-menu-panel .phone { width: 262px; }
.rs-lang { margin-inline-start: auto; font-family: var(--font-mono); font-size: 9px; opacity: .8; white-space: nowrap; }
.rs-filters span { font-size: 10.5px; padding: 4px 8px; }
.rs-dish { display: grid; gap: 5px; padding: 9px 10px; border-radius: 10px; background: #f5f5f5; }
.rs-dish > div { display: flex; justify-content: space-between; gap: 8px; }
.rs-dish strong { font-weight: 500; font-size: 12.5px; }
.rs-dish b { font-weight: 500; font-size: 12px; }
.rs-dish-off { opacity: .45; }
.rs-veg { font-style: normal; font-size: 10px; padding: 1px 6px; border-radius: 999px; background: #dcefd8; color: #23552a; }
.rs-traces { font-size: 10px; color: #6b6b70; font-style: italic; }
.rs-register { position: absolute; inset-inline-end: clamp(12px, 3vw, 32px); bottom: 24px; width: min(300px, 78%); }
.rs-register table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 11px; }
.rs-register th { font-family: var(--font-mono); font-weight: 500; font-size: 9.5px; color: #6b6b70; text-align: center; padding: 4px 2px; }
.rs-register th:first-child, .rs-register td:first-child { text-align: start; }
.rs-register td { padding: 5px 2px; text-align: center; box-shadow: inset 0 1px 0 #ececec; color: var(--rs-wine); }
.rs-register td:first-child { color: #202020; }

/* Food cost */
.rs-fc-panel { flex-direction: column; align-items: center; gap: 12px; }
.rs-fc { width: 100%; max-width: 440px; display: grid; gap: 12px; box-shadow: inset 0 0 0 1px #e9e9eb, var(--shadow-float); }
.rs-fc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.rs-fc-top strong { font-weight: 500; font-size: 15px; }
.rs-fc-top > span { font-family: var(--font-mono); font-size: 13px; }
.rs-fc-table { display: grid; }
.rs-fc-table div { display: grid; grid-template-columns: 1fr 64px 64px; gap: 8px; padding: 6px 2px; box-shadow: inset 0 -1px 0 #ececec; font-size: 12px; }
.rs-fc-table div span:nth-child(n+2) { font-family: var(--font-mono); text-align: end; font-size: 11.5px; }
.rs-fc-table .h span { font-family: var(--font-mono) !important; text-transform: uppercase; letter-spacing: var(--tracking-mono); font-size: 9.5px !important; color: #89898a; }
.rs-fc-chg { background: color-mix(in srgb, var(--accent) 14%, #fff); border-radius: 6px; }
.rs-fc-low { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 10px; background: #fdf0ec; box-shadow: inset 3px 0 0 var(--rs-warn); }
.rs-fc-low strong { display: block; font-weight: 500; font-size: 13px; }
.rs-fc-low span { font-size: 11.5px; color: #6b4a40; }
.ui .rs-pill-warn, .rs-pill-warn { background: #f9d9cf; color: #7a2410; white-space: nowrap; }
.rs-notice-fc { max-width: 440px; }

/* Menu del giorno + messaggio WhatsApp */
.rs-mdg-panel { padding-bottom: 150px; }
.rs-mdg-panel .phone { width: 250px; }
.rs-mdg-item { display: flex; justify-content: space-between; gap: 8px; padding: 9px 10px; border-radius: 10px; background: #f5f5f5; font-size: 12.5px; }
.rs-mdg-item b { font-weight: 500; }
.rs-typing { box-shadow: inset 0 0 0 1.5px var(--brand); background: #fbf3f4; }
.rs-mdg-add { font-size: 11.5px; color: #6b6b70; padding: 2px 4px; }
.rs-mdg-done { font-size: 11px; color: #135c2b; text-align: center; }
.rs-wa { position: absolute; inset-inline-end: clamp(12px, 3vw, 32px); bottom: 24px; width: min(290px, 74%); }
.rs-wa-bubble { margin: 8px 0 10px; padding: 9px 11px; border-radius: 10px 10px 10px 3px; background: #dcf3e2; }
.rs-wa-bubble p { font-size: 12px; color: #1f3a26; }
.rs-wa-bubble u { text-decoration-color: rgba(31,58,38,.4); word-break: break-all; }
.rs-wa-btn { text-align: center; padding: 7px; border-radius: 8px; font-size: 12px; font-weight: 500; background: #1f8f4e; color: #fff; }

/* Asporto e consegna */
.rs-orders { width: 100%; max-width: 460px; display: grid; gap: 4px; box-shadow: inset 0 0 0 1px #e9e9eb, var(--shadow-float); }
.rs-orders .rs-sala-top { margin-bottom: 6px; }
.rs-order { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: start; padding: 10px 2px; box-shadow: inset 0 -1px 0 #ececec; }
.rs-order > b { font-family: var(--font-mono); font-weight: 500; font-size: 12px; padding-top: 1px; }
.rs-order strong { display: block; font-weight: 500; font-size: 13px; }
.rs-order span { display: block; font-size: 11.5px; color: #6b6b70; }
.rs-order em { display: inline-block; margin-top: 4px; font-style: normal; font-size: 10px; padding: 1px 6px; border-radius: 999px; background: var(--accent-wash-strong); color: #202020; }
.rs-order .pill { white-space: nowrap; font-size: 10.5px; }
.ui .rs-st-ok { background: #dcf3e2; color: #135c2b; }
.ui .rs-st-wip { background: #fbeccd; color: #6b4a0f; }
.rs-orders-foot { margin-top: 8px; font-family: var(--font-mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: var(--tracking-mono); color: #6b6b70; }

/* Lati: gift card e turni */
.rs-gift-lg { width: 280px; padding: 20px; }
.rs-gift-place { margin-top: 14px; font-size: 15px; }
.rs-gift-code { margin-top: 14px; display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 8px; background: rgba(255,255,255,.1); }
.rs-gift-code code { font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; }
.rs-shifts { width: 100%; max-width: 440px; box-shadow: inset 0 0 0 1px #e9e9eb !important; }
.rs-sh-grid { display: grid; grid-template-columns: 58px repeat(6, minmax(0, 1fr)) 34px; gap: 4px; align-items: center; }
.rs-sh-grid .h { font-family: var(--font-mono); font-size: 9.5px; text-transform: uppercase; color: #89898a; text-align: center; }
.rs-sh-grid .n { font-size: 12px; font-weight: 500; }
.rs-sh-grid i { height: 24px; display: grid; place-items: center; border-radius: 6px; font-style: normal; font-family: var(--font-mono); font-size: 9.5px; color: #202020; }
.rs-sh-grid .p { background: #e6eef8; }
.rs-sh-grid .c { background: var(--rs-bk); }
.rs-sh-grid .pc { background: linear-gradient(90deg, #e6eef8 50%, var(--rs-bk) 50%); }
.rs-sh-grid .d { background: repeating-linear-gradient(135deg, #f0f0f1 0 5px, #e6e6e8 5px 10px); }
.rs-sh-grid b { font-family: var(--font-mono); font-weight: 500; font-size: 12px; text-align: end; }
.rs-sh-grid b.warn { color: var(--rs-warn); }
.rs-sh-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin-top: 12px; }
.rs-sh-send { font-size: 11.5px; font-weight: 500; padding: 6px 10px; border-radius: 8px; background: #dcf3e2; color: #135c2b; }

/* Demo (mockup di riserva) */
.rs-demo { margin-top: 8px; }
.rs-demo-app { display: grid; grid-template-columns: 180px 1fr; min-height: 340px; background: #fff; color: #202020; }
.rs-demo-side { display: grid; align-content: start; gap: 2px; padding: 16px 12px; background: #fafafa; box-shadow: inset -1px 0 0 #ececec; font-size: 13px; }
.rs-demo-side span { padding: 7px 10px; border-radius: 8px; color: #4a4a4f; }
.rs-demo-side .on { background: var(--accent-wash-strong); color: #202020; font-weight: 500; }
.rs-demo-brand { display: flex; align-items: center; gap: 8px; font-weight: 500; padding: 0 6px 14px; }
.rs-demo-main { padding: 18px 20px 22px; display: grid; gap: 14px; align-content: start; min-width: 0; }
.rs-floor-wide { grid-template-columns: repeat(6, 1fr); }

@media (max-width: 720px) {
  .rs-panel { padding: 24px 12px; }
  .rs-booking, .rs-mdg-panel { padding-bottom: 170px; }
  .rs-menu-panel { padding-bottom: 190px; }
  .rs-booking .phone, .rs-mdg-panel .phone, .rs-menu-panel .phone { width: min(86%, 262px); }
  .rs-bubble, .rs-wa, .rs-register { inset-inline-end: 12px; bottom: 16px; width: min(270px, 84%); }
  .rs-floor { gap: 8px; padding: 10px; }
  .rs-floor .t { height: 46px; }
  .rs-floor .r2 { width: 46px; }
  .rs-fc-table div { grid-template-columns: 1fr 52px 56px; gap: 6px; }
  .rs-sh-grid { grid-template-columns: 48px repeat(6, minmax(0, 1fr)) 26px; gap: 3px; }
  .rs-sh-grid i { font-size: 8px; }
  .rs-demo-app { grid-template-columns: 1fr; min-height: 0; }
  .rs-demo-side { display: none; }
  .rs-floor-wide { grid-template-columns: repeat(4, 1fr); }
}

/* Hero su telefono: la colonna della sala è più alta della carta del motore,
   la abbasso così non copre i bottoni. */
@media (max-width: 720px) {
  .c4 { --x: 27vw; --y: 38vh; --sc: .5; }
  .c3 { --y: 35vh; }
}
