/* MORNING TABLE Restaurant POS — standalone responsive design system */
:root {
  color-scheme: light;
  --ink: #142a24;
  --ink-soft: #536660;
  --brand: #164a3c;
  --brand-deep: #0c3027;
  --brand-tint: #e7f0eb;
  --accent: #ed6530;
  --accent-deep: #c84a1b;
  --canvas: #f5f3ed;
  --surface: #ffffff;
  --surface-muted: #f8f8f5;
  --line: #d7e0da;
  --line-strong: #bdcbc3;
  --warning: #ab6c08;
  --warning-tint: #fff3d9;
  --danger: #b52f2d;
  --danger-tint: #fce9e7;
  --success: #187550;
  --success-tint: #e4f4eb;
  --radius-xl: 26px;
  --radius-lg: 18px;
  --radius-md: 13px;
  --shadow: 0 15px 38px rgba(15, 51, 41, .09);
  --shadow-soft: 0 8px 22px rgba(15, 51, 41, .07);
  --font: "Microsoft JhengHei", "PingFang TC", "Noto Sans TC", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--canvas); }
body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
button, input, select, textarea { font: inherit; }
button, [role="button"], a.button, .nav-item, .compact-table, .order-select, .text-button, .round-button, .dialog-close { cursor: pointer; }
button:disabled, [disabled] { cursor: not-allowed; opacity: .5; }
button, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible {
  outline: 3px solid rgba(237, 101, 48, .38);
  outline-offset: 2px;
}
button { border: 0; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p { margin: 0; }
small { line-height: 1.45; }

/* Shared primitives */
.eyebrow {
  margin: 0 0 7px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .13em;
  line-height: 1.2;
}
.muted { color: var(--ink-soft); }
.small { font-size: 13px; }
.full { width: 100%; justify-content: center; }
.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 17px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
}
.button:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(13, 55, 44, .15); }
.button.primary { color: #fff; background: var(--brand); }
.button.primary:hover:not(:disabled) { background: var(--brand-deep); }
.button.secondary { color: var(--brand); border-color: var(--line-strong); background: #fff; }
.button.secondary:hover:not(:disabled) { border-color: var(--brand); background: var(--brand-tint); }
.button.light { color: var(--brand-deep); background: #fff; }
.button.subtle { color: var(--brand); border-color: var(--line); background: transparent; }
.button.mini { min-height: 36px; padding: 8px 11px; font-size: 13px; color: var(--brand); background: var(--brand-tint); }
.text-button { padding: 6px 0; color: var(--brand); background: transparent; font-weight: 800; }
.text-button:hover { color: var(--accent-deep); text-decoration: underline; }
.round-button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  flex: 0 0 38px;
  border: 1px solid var(--brand);
  border-radius: 50%;
  color: var(--brand);
  background: #fff;
  font-size: 23px;
  line-height: 1;
}
.round-button:hover:not(:disabled) { color: #fff; background: var(--brand); }

label { display: grid; gap: 7px; color: var(--ink); font-weight: 700; font-size: 14px; }
input, select, textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  color: var(--ink);
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(0,0,0,.015);
}
textarea { min-height: 88px; resize: vertical; }
select { cursor: pointer; }
.stack-form { display: grid; gap: 15px; }
.inline-form { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.inline-form label { min-width: 160px; flex: 1 1 160px; }
.inline-form .button { flex: 0 0 auto; }

.panel {
  min-width: 0;
  padding: clamp(18px, 2vw, 27px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}
.panel.wide { grid-column: 1 / -1; }
.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.panel-heading h3 { font-size: clamp(20px, 1.7vw, 27px); line-height: 1.22; }
.pill {
  display: inline-flex;
  min-height: 29px;
  align-items: center;
  justify-content: center;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--brand);
  background: var(--brand-tint);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}
.pill.warning, .pill.status-pending, .pill.status-new { color: var(--warning); background: var(--warning-tint); }
.pill.ok, .pill.status-paid, .pill.status-served, .pill.status-ready, .pill.status-sent { color: var(--success); background: var(--success-tint); }
.pill.status-cancelled, .pill.status-failed, .pill.status-void { color: var(--danger); background: var(--danger-tint); }
.pill.status-accepted, .pill.status-preparing, .pill.status-open, .pill.status-occupied { color: #325d92; background: #e9f1ff; }
.notice {
  margin-bottom: 22px;
  padding: 15px 17px;
  border: 1px solid #cce0d5;
  border-radius: var(--radius-md);
  color: #305a4c;
  background: #eef7f1;
}
.empty-state { padding: 30px 15px; color: var(--ink-soft); text-align: center; }

/* Staff sign in */
.login-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 28px 18px;
  background:
    radial-gradient(circle at 13% 12%, rgba(237,101,48,.2), transparent 24rem),
    linear-gradient(135deg, #0a2b23, #154b3d 60%, #12342d);
}
.login-card {
  width: min(100%, 460px);
  padding: clamp(28px, 6vw, 48px);
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 28px;
  background: rgba(255,255,255,.96);
  box-shadow: 0 25px 70px rgba(0,0,0,.22);
}
.login-card h1 { margin: 2px 0 8px; font-size: 33px; letter-spacing: .02em; }
.login-card > .muted { margin-bottom: 26px; }
.brand-mark {
  display: grid;
  width: 43px;
  height: 43px;
  place-items: center;
  border-radius: 13px 13px 13px 2px;
  color: #fff;
  background: var(--accent);
  font-family: Georgia, serif;
  font-size: 25px;
  font-weight: 700;
}
.login-card > .brand-mark { width: 56px; height: 56px; margin-bottom: 26px; font-size: 31px; }

/* Staff application shell */
.pos-shell { display: grid; min-height: 100vh; grid-template-columns: 250px minmax(0, 1fr); }
.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  height: 100vh;
  flex-direction: column;
  padding: 25px 15px 16px;
  color: #eff9f4;
  background: var(--brand-deep);
}
.brand, .public-brand { display: flex; align-items: center; gap: 11px; }
.brand b, .public-brand b { display: block; color: #fff; font-size: 19px; letter-spacing: .05em; line-height: 1.05; }
.brand small, .public-brand small { display: block; margin-top: 4px; color: #a9cfc0; font-size: 11px; letter-spacing: .06em; }
.sidebar-caption { margin: 22px 10px 13px; color: #9bbbad; font-size: 13px; }
.sidebar nav { display: grid; gap: 5px; }
.nav-item {
  display: flex;
  min-height: 48px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 11px 13px;
  border-radius: 11px;
  color: #c1d8cc;
  background: transparent;
  font-size: 15px;
  font-weight: 700;
  text-align: left;
  transition: background .15s ease, color .15s ease;
}
.nav-item span { display: inline-grid; width: 22px; place-items: center; color: #79c5a6; }
.nav-item:hover { color: #fff; background: rgba(255,255,255,.09); }
.nav-item.active { color: #fff; background: rgba(237,101,48,.96); box-shadow: 0 8px 20px rgba(0,0,0,.15); }
.nav-item.active span { color: #fff; }
.sidebar-foot { margin-top: auto; padding: 16px 10px 0; border-top: 1px solid rgba(255,255,255,.15); color: #cae5d7; font-weight: 700; font-size: 13px; }
.sidebar-foot small { color: #9bbbad; font-weight: 500; }
.status-dot { display: inline-block; width: 9px; height: 9px; margin-right: 6px; border-radius: 50%; background: #5bda9d; box-shadow: 0 0 0 4px rgba(91,218,157,.12); }

.pos-main { min-width: 0; background: var(--canvas); }
.topbar {
  display: flex;
  min-height: 134px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 23px clamp(22px, 4vw, 58px);
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.62);
}
.topbar h1 { font-size: clamp(28px, 3vw, 44px); line-height: 1.1; }
.topbar-actions { display: flex; align-items: center; justify-content: end; gap: 12px; }
.branch-picker { grid-template-columns: auto; gap: 2px; min-width: 178px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 13px; background: #fff; font-size: 11px; color: var(--ink-soft); }
.branch-picker select { min-height: 26px; padding: 0; border: 0; color: var(--ink); background: transparent; font-size: 15px; font-weight: 800; }
.user-chip { min-width: 92px; padding-left: 12px; border-left: 1px solid var(--line); }
.user-chip b, .user-chip small { display: block; }
.user-chip b { font-size: 14px; }
.user-chip small { color: var(--ink-soft); font-size: 12px; }
.content { max-width: 1720px; margin: 0 auto; padding: clamp(22px, 3.2vw, 46px) clamp(18px, 4vw, 58px) 52px; }

/* Dashboard */
.hero-card {
  display: flex;
  min-height: 180px;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  margin-bottom: 23px;
  padding: clamp(24px, 4vw, 42px);
  overflow: hidden;
  border-radius: var(--radius-xl);
  color: #fff;
  background:
    radial-gradient(circle at 83% 15%, rgba(237,101,48,.75), transparent 15rem),
    linear-gradient(120deg, #103d31, #174d3e 55%, #0b2d24);
  box-shadow: var(--shadow);
}
.hero-card h2 { max-width: 720px; font-size: clamp(24px, 3vw, 39px); line-height: 1.2; }
.hero-card p:not(.eyebrow) { max-width: 710px; margin-top: 12px; color: #d4e9df; }
.hero-card .eyebrow { color: #ffc19e; }
.hero-card.compact { min-height: 145px; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(150px, 1fr)); gap: 16px; margin-bottom: 23px; }
.metric { display: grid; min-height: 142px; align-content: space-between; gap: 7px; padding: 21px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-soft); }
.metric span, .metric small { color: var(--ink-soft); font-size: 13px; }
.metric b { font-size: clamp(28px, 3vw, 42px); line-height: 1; }
.two-column { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-bottom: 22px; }
.shift-detail { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.shift-detail span { color: var(--ink-soft); font-size: 14px; }
.shift-detail .button { margin-left: auto; }
.source-list { display: grid; gap: 10px; }
.source-list > div, .mini-menu > div { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.source-list > div:last-child, .mini-menu > div:last-child { border-bottom: 0; }

/* Tables and QR */
.qr-workflow { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 0 0 22px; padding: 24px 27px; overflow: hidden; border: 1px solid rgba(22,74,60,.16); border-radius: var(--radius-lg); background: linear-gradient(118deg, #edf6f0, #fffaf5); box-shadow: var(--shadow-soft); }
.qr-workflow h2 { margin-bottom: 8px; font-size: 25px; }
.qr-workflow p:not(.eyebrow) { max-width: 690px; color: var(--ink-soft); font-size: 14px; }
.qr-workflow ol { display: grid; grid-template-columns: repeat(3, minmax(106px, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.qr-workflow li { display: grid; justify-items: center; gap: 7px; padding: 13px 9px; border: 1px solid #cbdcd2; border-radius: 11px; color: var(--brand); background: rgba(255,255,255,.76); font-size: 12px; font-weight: 800; text-align: center; }
.qr-workflow li b { display: grid; width: 26px; height: 26px; place-items: center; border-radius: 50%; color: #fff; background: var(--brand); font-size: 12px; }
.table-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(204px, 1fr)); gap: 14px; }
.table-card { display: grid; gap: 9px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius-md); background: linear-gradient(135deg, #fff, #fbfcfb); }
.table-card.occupied { border-color: #b9cce5; background: #f4f8ff; }
.table-card h3 { font-size: 24px; }
.table-card p { color: var(--ink-soft); font-size: 14px; }
.table-card small { color: var(--ink-soft); }
.table-top { display: flex; align-items: start; justify-content: space-between; gap: 10px; }
.table-icon { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 10px; color: var(--brand); background: var(--brand-tint); font-size: 13px; font-weight: 800; }
.table-card .button { margin-top: 6px; }

/* Counter ordering */
.counter-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(290px, 370px); align-items: start; gap: 22px; }
.counter-left { min-width: 0; }
.compact-tables { display: grid; grid-template-columns: repeat(auto-fill, minmax(91px, 1fr)); gap: 9px; }
.compact-table { display: grid; min-height: 72px; align-content: center; gap: 3px; padding: 10px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #fff; text-align: left; }
.compact-table:hover { border-color: var(--brand); background: var(--brand-tint); }
.compact-table.selected { border-color: var(--brand); color: #fff; background: var(--brand); box-shadow: 0 5px 12px rgba(22,74,60,.18); }
.compact-table.occupied:not(.selected) { border-color: #b9cce5; background: #f3f7fe; }
.compact-table small { color: inherit; opacity: .73; font-size: 11px; }
.menu-heading { margin-top: 29px; }
.menu-category + .menu-category { margin-top: 27px; }
.menu-category > h4 { margin-bottom: 11px; font-size: 17px; }
.menu-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 12px; }
.menu-card { display: grid; min-height: 202px; align-content: space-between; gap: 15px; padding: 17px; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease; }
.menu-card:hover:not(.sold-out) { transform: translateY(-2px); border-color: #9ab8aa; box-shadow: var(--shadow-soft); }
.menu-card small, .public-menu-card small { color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.menu-card h4 { margin: 4px 0 6px; font-size: 18px; line-height: 1.3; }
.menu-card p { color: var(--ink-soft); font-size: 13px; }
.menu-card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.menu-card-bottom > b { color: var(--brand); }
.menu-card.sold-out { color: #8a9791; background: #f3f5f3; }
.tag { display: inline-block; margin-top: 9px; padding: 3px 7px; border-radius: 5px; color: var(--brand); background: var(--brand-tint); font-size: 11px; }
.order-cart {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 17px;
  padding: 23px;
  border-radius: var(--radius-lg);
  color: #fff;
  background: var(--brand-deep);
  box-shadow: var(--shadow);
}
.order-cart .eyebrow { color: #ffc19e; }
.order-cart h2 { font-size: 25px; }
.cart-lines { display: grid; max-height: 48vh; gap: 1px; overflow: auto; border-top: 1px solid rgba(255,255,255,.16); border-bottom: 1px solid rgba(255,255,255,.16); }
.cart-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 9px 12px; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.11); }
.cart-line:last-child { border-bottom: 0; }
.cart-line b, .cart-line strong { font-size: 14px; }
.cart-line small { display: block; margin-top: 3px; color: #a8cdbd; font-size: 11px; }
.cart-line-controls { display: flex; grid-column: 1 / -1; align-items: center; justify-content: end; gap: 11px; }
.cart-line-controls button, .public-cart-lines button { display: grid; width: 27px; height: 27px; place-items: center; border: 1px solid rgba(255,255,255,.45); border-radius: 50%; color: #fff; background: transparent; }
.cart-guests { color: #d2e8dc; }
.cart-guests select { min-height: 42px; color: var(--ink); }
.cart-total { display: flex; align-items: end; justify-content: space-between; gap: 12px; }
.cart-total span { color: #c8dfd4; font-size: 13px; }
.cart-total b { font-size: 27px; }
.order-cart .button.primary { color: var(--brand-deep); background: #fff; }
.order-cart .button.primary:hover:not(:disabled) { background: #f5eee9; }

/* Kitchen display */
.kitchen-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 20px; }
.tickets { display: grid; gap: 11px; }
.ticket { display: grid; gap: 12px; padding: 16px; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 11px; background: #fffdfa; }
.ticket p { color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.ticket h4 { margin-top: 3px; font-size: 17px; }
.ticket small { color: var(--ink-soft); }
.ticket-actions { display: flex; flex-wrap: wrap; gap: 7px; }

/* Checkout */
.checkout-layout { display: grid; grid-template-columns: minmax(280px, .76fr) minmax(0, 1.24fr); align-items: start; gap: 22px; }
.checkout-orders { display: grid; gap: 9px; }
.order-select { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px; padding: 15px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); background: #fff; text-align: left; }
.order-select:hover, .order-select.selected { border-color: var(--brand); background: var(--brand-tint); }
.order-select small { display: block; margin-top: 5px; color: var(--ink-soft); }
.checkout-detail { min-height: 450px; }
.checkout-lines, .payment-history { display: grid; gap: 10px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.checkout-lines > div, .payment-history > div { display: flex; align-items: start; justify-content: space-between; gap: 20px; }
.checkout-lines span small { display: block; margin-top: 3px; color: var(--ink-soft); }
.totals { display: grid; gap: 9px; padding: 17px 0; }
.totals > div { display: flex; justify-content: space-between; gap: 16px; color: var(--ink-soft); }
.totals .grand { padding-top: 13px; border-top: 1px solid var(--line); color: var(--ink); font-size: 18px; font-weight: 800; }
.totals .due { color: var(--accent-deep); font-weight: 800; }
.payment-history { margin-bottom: 18px; }
.payment-history h4 { margin: 0; font-size: 14px; }
.payment-history span { color: var(--ink-soft); font-size: 13px; }
.payment-form { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.payment-form label:nth-of-type(3), .payment-form .demo-note, .payment-form .button { grid-column: 1 / -1; }
.demo-note { margin: 2px 0 0; padding: 12px; border-radius: 10px; color: #5f521e; background: #fff8e5; font-size: 13px; }
.payment-complete { margin-top: 20px; padding: 16px; border-radius: 12px; color: var(--success); background: var(--success-tint); font-weight: 800; text-align: center; }

/* Invoices / menu master */
.check-list { display: grid; gap: 11px; margin: 16px 0 0; padding: 0 0 0 19px; }
.check-list li::marker { color: var(--accent); }
.mini-menu { display: grid; gap: 0; }
.mini-menu span { display: grid; gap: 2px; }
.mini-menu small { color: var(--ink-soft); }

/* Tables used in dashboard/invoices */
.order-table { overflow-x: auto; }
.order-row { display: grid; grid-template-columns: minmax(124px, 1.2fr) minmax(70px, .8fr) minmax(86px, .8fr) minmax(85px, .75fr) auto; align-items: center; gap: 15px; min-width: 640px; padding: 14px 4px; border-bottom: 1px solid var(--line); }
.order-row.headings { padding-top: 0; color: var(--ink-soft); font-size: 12px; font-weight: 800; }
.order-row:last-child { border-bottom: 0; }

/* Dialog / feedback */
.qr-dialog { width: min(92vw, 440px); max-width: 440px; padding: 31px; border: 1px solid var(--line); border-radius: 20px; color: var(--ink); background: #fff; box-shadow: 0 25px 80px rgba(0,0,0,.28); }
.qr-dialog::backdrop { background: rgba(8,39,31,.64); backdrop-filter: blur(3px); }
.qr-dialog h2 { margin-bottom: 13px; font-size: 26px; }
.qr-dialog img { display: block; width: min(100%, 280px); margin: 19px auto; border-radius: 8px; image-rendering: crisp-edges; }
.qr-dialog p { color: var(--ink-soft); }
.qr-dialog-lead { max-width: 350px; margin: 0 auto; text-align: center; }
.qr-preview { margin: 18px 0; padding: 13px; border: 1px solid var(--line); border-radius: 14px; background: #fff; text-align: center; }
.qr-preview figcaption { color: var(--ink-soft); font-size: 12px; }
.qr-dialog code { display: block; max-height: 75px; margin: 15px 0; padding: 10px; overflow: auto; border-radius: 8px; color: var(--brand); background: var(--surface-muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; overflow-wrap: anywhere; }
.qr-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 14px; }
.qr-actions .button:first-child { grid-column: 1 / -1; }
.qr-actions .button { min-height: 43px; padding-inline: 10px; font-size: 13px; }
.qr-scan-note { margin: 16px 0 0; padding: 11px 13px; border-radius: 10px; color: #3d6557 !important; background: var(--brand-tint); font-size: 12px; }
.dialog-close { position: absolute; top: 12px; right: 12px; display: grid; width: 35px; height: 35px; place-items: center; border-radius: 50%; color: var(--ink); background: var(--surface-muted); font-size: 25px; line-height: 1; }
.dialog-close:hover { color: #fff; background: var(--brand); }
.toast { position: fixed; z-index: 30; right: max(18px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom)); max-width: min(430px, calc(100vw - 36px)); padding: 14px 18px; border-radius: 12px; color: #fff; background: var(--success); box-shadow: 0 12px 33px rgba(0,0,0,.23); font-weight: 800; animation: toast-in .2s ease-out; }
.toast.error { background: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* Public table QR ordering */
.order-app { min-height: 100vh; background: #f5f2eb; }
.public-top { display: flex; min-height: 78px; align-items: center; justify-content: space-between; gap: 16px; padding: 15px clamp(18px, 5vw, 72px); color: #fff; background: var(--brand-deep); }
.public-top-landing { min-height: 88px; }
.public-top > div { display: grid; gap: 2px; text-align: right; }
.public-top > div b { font-size: 14px; }
.public-top > div small { color: #afd1c1; font-size: 12px; }
.public-shell { width: min(100% - 36px, 1280px); margin: 0 auto; padding: clamp(26px, 5vw, 60px) 0 90px; }
.public-intro { max-width: 720px; margin-bottom: 40px; }
.public-intro h1 { font-size: clamp(30px, 5vw, 50px); line-height: 1.18; letter-spacing: .01em; }
.public-intro p:not(.eyebrow) { margin-top: 12px; color: var(--ink-soft); font-size: 17px; }
.public-menu { display: grid; gap: 43px; padding-right: min(29vw, 370px); }
.public-category { scroll-margin-top: 25px; }
.public-category > h2 { font-size: clamp(23px, 3vw, 31px); }
.public-category > p { margin-top: 6px; color: var(--ink-soft); }
.public-item-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(245px, 1fr)); gap: 15px; margin-top: 18px; }
.public-menu-card { display: grid; align-content: space-between; gap: 16px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #fff; box-shadow: 0 7px 19px rgba(15,51,41,.04); }
.public-menu-card h3 { margin: 4px 0 7px; font-size: 20px; }
.public-menu-card p { min-height: 42px; color: var(--ink-soft); font-size: 14px; }
.public-menu-card b { display: block; margin-top: 14px; color: var(--brand); font-size: 19px; }
.public-modifiers { display: grid; gap: 8px; margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.public-modifiers legend { padding: 0 4px; color: var(--ink-soft); font-size: 12px; font-weight: 800; }
.public-modifiers label { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 13px; font-weight: 600; }
.public-modifiers input { width: 17px; min-height: 17px; padding: 0; accent-color: var(--brand); }
.public-cart {
  position: fixed;
  z-index: 2;
  top: 102px;
  right: max(18px, calc((100vw - 1280px) / 2));
  display: grid;
  width: min(335px, calc(100vw - 36px));
  max-height: calc(100vh - 122px);
  gap: 15px;
  padding: 22px;
  overflow: auto;
  border-radius: var(--radius-lg);
  color: #fff;
  background: var(--brand-deep);
  box-shadow: var(--shadow);
}
.public-cart .eyebrow { color: #ffc19e; }
.public-cart h3 { font-size: 25px; }
.public-cart-lines { display: grid; gap: 8px; padding: 13px 0; border-top: 1px solid rgba(255,255,255,.15); border-bottom: 1px solid rgba(255,255,255,.15); }
.public-cart-lines > div { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px; }
.public-cart-lines span { font-size: 13px; }
.public-cart-lines small { display: block; margin-top: 2px; color: #add0c0; font-size: 11px; }
.public-cart-lines b { font-size: 13px; white-space: nowrap; }
.public-cart-total { display: flex; align-items: end; justify-content: space-between; gap: 10px; }
.public-cart-total span, .public-cart > small { color: #b7d6c8; font-size: 12px; }
.public-cart-total b { font-size: 25px; }
.public-cart .button.primary { color: var(--brand-deep); background: #fff; }
.public-message, .public-loading { width: min(100% - 36px, 670px); margin: 9vh auto; padding: clamp(26px, 7vw, 55px); border: 1px solid var(--line); border-radius: var(--radius-xl); background: #fff; box-shadow: var(--shadow); text-align: center; }
.public-message h1, .public-loading { font-size: clamp(25px, 4vw, 39px); }
.public-message p { margin: 15px auto; color: var(--ink-soft); }
.public-message.success { border-color: #a9d7bd; }
.public-message .button { margin-top: 9px; }
.public-landing-shell { min-height: calc(100vh - 88px); padding: clamp(26px, 7vw, 86px) 18px; background: radial-gradient(circle at 85% 17%, rgba(237,101,48,.18), transparent 20rem), linear-gradient(135deg, #f7f3eb, #fcfdfb 56%, #ecf3ed); }
.public-landing { width: min(100%, 720px); margin: 0 auto; padding: clamp(28px, 6vw, 64px); border: 1px solid rgba(22,74,60,.16); border-radius: 28px; background: rgba(255,255,255,.94); box-shadow: var(--shadow); text-align: center; }
.landing-status { padding: 8px 12px; border: 1px solid rgba(255,255,255,.24); border-radius: 999px; color: #d9e9e1; font-size: 13px; font-weight: 800; }
.scan-illustration { position: relative; display: grid; width: 116px; height: 116px; place-items: center; margin: 0 auto 25px; border-radius: 24px; background: #edf5f0; }
.scan-corner { position: absolute; width: 34px; height: 34px; border-color: var(--accent); border-style: solid; }
.scan-corner.one { top: 13px; left: 13px; border-width: 4px 0 0 4px; border-radius: 7px 0 0 0; }
.scan-corner.two { top: 13px; right: 13px; border-width: 4px 4px 0 0; border-radius: 0 7px 0 0; }
.scan-corner.three { bottom: 13px; left: 13px; border-width: 0 0 4px 4px; border-radius: 0 0 0 7px; }
.scan-corner.four { right: 13px; bottom: 13px; border-width: 0 4px 4px 0; border-radius: 0 0 7px 0; }
.scan-grid { width: 48px; height: 48px; border-radius: 6px; background: repeating-linear-gradient(90deg, var(--brand) 0 8px, transparent 8px 12px), repeating-linear-gradient(0deg, var(--brand) 0 8px, transparent 8px 12px); }
.public-landing h1 { font-size: clamp(31px, 6vw, 52px); line-height: 1.18; letter-spacing: .02em; }
.landing-copy { max-width: 520px; margin: 17px auto 26px; color: var(--ink-soft); font-size: 17px; line-height: 1.8; }
.scan-steps { display: grid; gap: 9px; max-width: 460px; margin: 0 auto 24px; padding: 0; text-align: left; list-style: none; }
.scan-steps li { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; font-size: 14px; font-weight: 700; }
.scan-steps b { display: grid; width: 27px; height: 27px; flex: 0 0 auto; place-items: center; border-radius: 50%; color: #fff; background: var(--brand); font-size: 13px; }
.manual-order-link { max-width: 520px; margin: 0 auto; border: 1px dashed #afc5b9; border-radius: 13px; color: var(--brand); background: #fbfdfb; text-align: left; }
.manual-order-link summary { padding: 14px 16px; cursor: pointer; font-size: 14px; font-weight: 800; }
.manual-order-link form { display: grid; gap: 11px; padding: 0 16px 16px; }
.manual-order-link label { display: grid; gap: 6px; color: var(--ink-soft); font-size: 12px; font-weight: 800; }
.manual-order-link input { min-width: 0; min-height: 45px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 9px; color: var(--ink); background: #fff; }
.landing-help { margin: 17px 0 0; color: var(--ink-soft); font-size: 12px; }

/* iPad and smaller landscape */
@media (max-width: 1180px) {
  .pos-shell { grid-template-columns: 216px minmax(0, 1fr); }
  .sidebar { padding-inline: 12px; }
  .sidebar .brand b { font-size: 17px; }
  .nav-item { padding-inline: 11px; font-size: 14px; }
  .topbar { min-height: 116px; }
  .metric-grid { grid-template-columns: repeat(2, minmax(150px, 1fr)); }
  .counter-layout { grid-template-columns: minmax(0, 1fr) 315px; }
  .qr-workflow { align-items: flex-start; flex-direction: column; }
  .qr-workflow ol { width: 100%; max-width: 520px; }
  .public-menu { padding-right: 340px; }
  .public-cart { right: 18px; width: 310px; }
}

@media (max-width: 900px) {
  .pos-shell { display: block; }
  .sidebar { position: static; height: auto; min-height: 0; padding: 12px 14px; }
  .sidebar > .brand, .sidebar-caption, .sidebar-foot { display: none; }
  .sidebar nav { display: flex; gap: 7px; max-width: none; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .nav-item { width: auto; min-width: max-content; min-height: 42px; padding: 8px 11px; }
  .topbar { min-height: 105px; padding: 18px 22px; }
  .topbar-actions { gap: 9px; }
  .branch-picker { min-width: 153px; }
  .content { padding: 24px 22px 45px; }
  .counter-layout, .checkout-layout { grid-template-columns: 1fr; }
  .order-cart { position: static; max-height: none; }
  .checkout-detail { min-height: 0; }
  .public-menu { padding-right: 0; padding-bottom: 255px; }
  .public-cart { position: fixed; top: auto; right: 0; bottom: 0; width: 100%; max-width: none; max-height: 224px; grid-template-columns: 1fr auto; gap: 8px 20px; padding: 15px 20px max(15px, env(safe-area-inset-bottom)); border-radius: 21px 21px 0 0; }
  .public-cart > div:first-child { grid-column: 1; }
  .public-cart-lines { grid-column: 1 / -1; max-height: 74px; padding: 7px 0; overflow: auto; }
  .public-cart-total { grid-column: 1; }
  .public-cart .button { grid-column: 2; grid-row: 3; min-width: 155px; }
  .public-cart > small { display: none; }
}

@media (max-width: 650px) {
  body { font-size: 15px; }
  .login-shell { padding: 16px; }
  .login-card { border-radius: 22px; }
  .topbar { display: grid; min-height: 0; gap: 15px; }
  .topbar-actions { width: 100%; justify-content: stretch; flex-wrap: wrap; }
  .branch-picker { flex: 1 1 170px; }
  .user-chip { flex: 1 1 100px; }
  .topbar-actions .button { min-height: 42px; }
  .content { padding: 19px 14px 35px; }
  .hero-card { align-items: flex-start; flex-direction: column; min-height: 0; padding: 25px; border-radius: 20px; }
  .metric-grid { gap: 10px; }
  .metric { min-height: 120px; padding: 16px; }
  .two-column { grid-template-columns: 1fr; gap: 13px; }
  .panel { padding: 17px; border-radius: 15px; }
  .panel-heading { margin-bottom: 15px; }
  .inline-form { display: grid; }
  .inline-form .button { width: 100%; }
  .table-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .qr-workflow { padding: 20px; }
  .qr-workflow ol { grid-template-columns: 1fr; }
  .qr-workflow li { grid-template-columns: auto 1fr; align-items: center; justify-items: start; text-align: left; }
  .table-card { padding: 13px; }
  .table-card h3 { font-size: 20px; }
  .compact-tables { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .menu-grid, .public-item-grid { grid-template-columns: 1fr; }
  .menu-card { min-height: 0; }
  .ticket-actions .button { flex: 1; }
  .payment-form { grid-template-columns: 1fr; }
  .payment-form label, .payment-form label:nth-of-type(3), .payment-form .demo-note, .payment-form .button { grid-column: auto; }
  .order-select { padding: 13px; }
  .order-row { gap: 11px; }
  .qr-dialog { padding: 28px 20px 20px; }
  .qr-actions { grid-template-columns: 1fr; }
  .qr-actions .button:first-child { grid-column: auto; }
  .public-top { min-height: 69px; padding: 11px 17px; }
  .public-top-landing { min-height: 72px; }
  .public-brand .brand-mark { width: 35px; height: 35px; font-size: 21px; }
  .public-brand b { font-size: 15px; }
  .public-top > div b { font-size: 12px; }
  .public-shell { width: min(100% - 28px, 1280px); padding-top: 31px; }
  .public-landing-shell { min-height: calc(100vh - 72px); padding: 31px 14px; }
  .public-landing { padding: 34px 20px; border-radius: 21px; }
  .landing-status { padding: 6px 9px; font-size: 11px; }
  .landing-copy { font-size: 15px; }
  .public-intro { margin-bottom: 29px; }
  .public-intro p:not(.eyebrow) { font-size: 15px; }
  .public-menu { gap: 31px; padding-bottom: 230px; }
  .public-cart { max-height: 222px; padding-inline: 16px; }
  .public-cart h3 { font-size: 20px; }
  .public-cart .button { min-width: 138px; font-size: 13px; }
}

@media (max-width: 410px) {
  .topbar-actions .user-chip { display: none; }
  .metric-grid { grid-template-columns: 1fr 1fr; }
  .metric b { font-size: 29px; }
  .compact-tables { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .table-grid { grid-template-columns: 1fr; }
  .public-cart { grid-template-columns: 1fr; max-height: 256px; }
  .public-cart .button { grid-column: 1; grid-row: auto; }
  .public-menu { padding-bottom: 270px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Food-forward public ordering refinement.  Uses the locally hosted hero image only. */
.order-app {
  background:
    radial-gradient(circle at 5% 1%, rgba(232, 116, 52, .12), transparent 26rem),
    linear-gradient(180deg, #f7f3ea 0, #f3eee4 100%);
}
.public-top {
  position: relative;
  z-index: 4;
  min-height: 84px;
  overflow: hidden;
  background: linear-gradient(100deg, #102f27 0%, #153e31 100%);
  box-shadow: 0 4px 18px rgba(16, 47, 39, .14);
}
.public-top::after {
  position: absolute;
  right: -7%;
  bottom: 0;
  width: 39%;
  height: 1px;
  content: '';
  background: linear-gradient(90deg, transparent, rgba(239, 171, 108, .72), transparent);
}
.public-top > * { position: relative; z-index: 1; }
.public-brand { min-width: max-content; }
.public-brand .brand-mark {
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 224, 194, .28);
  border-radius: 15px 15px 15px 3px;
  color: #f5c692;
  background: rgba(255, 255, 255, .06);
}
.public-brand b { letter-spacing: .1em; }
.public-brand small { color: #c6d9cf; }
.public-table-status {
  display: flex !important;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background: rgba(255,255,255,.06);
  text-align: left !important;
}
.public-table-status > span:last-child { display: grid; gap: 2px; }
.public-table-status b, .public-table-status small { display: block; }
.public-table-status b { font-size: 13px; }
.public-table-status small { margin-top: 1px; color: #bcd8ca; font-size: 11px; }
.scan-status-dot { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: #f7a75c; box-shadow: 0 0 0 5px rgba(247,167,92,.13); }
.public-shell { width: min(100% - 36px, 1340px); padding: clamp(22px, 4vw, 52px) 0 108px; }
.public-hero {
  position: relative;
  display: flex;
  min-height: min(31vw, 405px);
  align-items: center;
  padding: clamp(30px, 5vw, 67px);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 25px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(12, 43, 35, .98) 0%, rgba(12, 43, 35, .91) 36%, rgba(12, 43, 35, .27) 73%, rgba(12, 43, 35, .11) 100%),
    url("./images/morning-table-hero-food-v1.png") center / cover no-repeat;
  box-shadow: 0 19px 43px rgba(44, 41, 24, .16);
}
.public-hero::after {
  position: absolute;
  right: 3%;
  bottom: -21%;
  width: min(27vw, 340px);
  aspect-ratio: 1;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 50%;
  content: '';
}
.public-hero-content { position: relative; z-index: 1; width: min(100%, 565px); }
.public-hero .eyebrow { color: #f6bb86; }
.public-hero h1 { max-width: 490px; font-size: clamp(34px, 4.3vw, 61px); line-height: 1.13; letter-spacing: .025em; }
.public-hero p:not(.eyebrow) { max-width: 500px; margin-top: 17px; color: #d9e8df; font-size: clamp(15px, 1.25vw, 18px); line-height: 1.75; }
.public-service-points { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 23px; }
.public-service-points span { padding: 7px 10px; border: 1px solid rgba(255,255,255,.19); border-radius: 999px; color: #f6f1df; background: rgba(0,0,0,.12); font-size: 12px; font-weight: 700; }
.public-category-nav { display: flex; gap: 10px; margin: 20px 0 28px; padding: 4px; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.public-category-nav::-webkit-scrollbar { display: none; }
.category-link { display: inline-flex; min-height: 45px; align-items: center; gap: 7px; padding: 10px 14px; border: 1px solid #e0d8cb; border-radius: 999px; color: #3f554c; background: rgba(255,255,255,.82); font-size: 14px; font-weight: 800; white-space: nowrap; box-shadow: 0 5px 12px rgba(48, 44, 31, .04); transition: transform .16s ease, color .16s ease, background .16s ease, border-color .16s ease; }
.category-link:hover { transform: translateY(-1px); border-color: #2d6a56; color: #fff; background: #1e5848; }
.category-link span { display: grid; width: 21px; height: 21px; place-items: center; border-radius: 50%; color: #fff; background: #bf5d35; font-size: 13px; }
.category-link-drink span { background: #4d8693; }
.category-link-dessert span { background: #b46c7c; }
.category-link-share span { background: #c58334; }
.public-menu { gap: 28px; padding-right: min(30vw, 386px); }
.public-category {
  scroll-margin-top: 18px;
  padding: clamp(19px, 2.7vw, 33px);
  border: 1px solid #e4ddd2;
  border-radius: 22px;
  background: rgba(255,255,255,.83);
  box-shadow: 0 10px 28px rgba(73, 58, 38, .055);
}
.public-category.category-main { --category-accent: #b55332; --category-tint: #f8ede3; }
.public-category.category-share { --category-accent: #ad7427; --category-tint: #fcf1dc; }
.public-category.category-drink { --category-accent: #28747b; --category-tint: #e4f0ee; }
.public-category.category-dessert { --category-accent: #a65068; --category-tint: #f8eaf0; }
.public-category-heading { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.public-category-heading .eyebrow { margin-bottom: 4px; color: var(--category-accent); }
.public-category-heading h2 { font-size: clamp(24px, 3vw, 33px); line-height: 1.2; }
.public-category-heading p:not(.eyebrow) { margin-top: 4px; color: var(--ink-soft); font-size: 14px; }
.category-emblem { display: grid; width: 54px; height: 54px; place-items: center; flex: 0 0 54px; border-radius: 18px 18px 18px 5px; color: var(--category-accent); background: var(--category-tint); font-size: 27px; font-weight: 800; }
.category-count { min-width: 47px; margin-left: auto; padding: 7px 9px; border-radius: 999px; color: var(--category-accent); background: var(--category-tint); font-size: 12px; font-weight: 800; text-align: center; white-space: nowrap; }
.public-item-grid { grid-template-columns: repeat(auto-fill, minmax(238px, 1fr)); gap: 16px; }
.public-empty-category { grid-column: 1 / -1; padding: 28px; border-radius: 14px; color: var(--ink-soft); background: var(--surface-muted); text-align: center; }
.public-menu-card { display: grid; align-content: start; gap: 0; overflow: hidden; padding: 0; border: 1px solid #e2ddd3; border-radius: 18px; background: #fff; box-shadow: 0 9px 21px rgba(35, 43, 32, .055); transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.public-menu-card:hover { transform: translateY(-3px); border-color: #c5b59f; box-shadow: 0 14px 27px rgba(35, 43, 32, .11); }
.public-menu-card.sold-out { opacity: .66; filter: grayscale(.28); }
.menu-food-art { position: relative; display: grid; height: 132px; place-items: center; overflow: hidden; background: radial-gradient(circle at 53% 40%, #f7d3a1 0 18%, #b85631 18.5% 21%, #f6e8ca 21.5% 40%, #d3b179 40.5% 41%, #f7f2e8 42% 100%); }
.menu-food-art::before, .menu-food-art::after { position: absolute; border-radius: 50%; content: ''; opacity: .8; }
.menu-food-art::before { top: 17px; left: 18%; width: 24px; height: 24px; background: #5d9a50; box-shadow: 74px 28px 0 #e8a52f, 145px 5px 0 #c55a36, 172px 68px 0 #7cb968; }
.menu-food-art::after { right: -18px; bottom: -31px; width: 127px; height: 127px; border: 13px solid rgba(255,255,255,.36); }
.menu-food-art span { position: relative; z-index: 2; display: grid; width: 64px; height: 64px; place-items: center; border: 1px solid rgba(75, 51, 33, .1); border-radius: 50%; color: #fff; background: rgba(79, 52, 33, .68); box-shadow: 0 7px 17px rgba(60, 42, 27, .18); font-size: 32px; font-style: normal; }
.menu-food-art i { position: absolute; z-index: 1; width: 54px; height: 7px; border-radius: 999px; background: rgba(76, 135, 61, .8); transform: rotate(-35deg); }
.menu-food-art i:first-of-type { top: 29px; right: 30px; }
.menu-food-art i:last-of-type { bottom: 31px; left: 25px; background: rgba(222, 106, 48, .75); transform: rotate(28deg); }
.food-noodle .menu-food-art { background: radial-gradient(circle at 52% 42%, #f5cf79 0 20%, #bd7736 20.5% 23%, #f4ecdc 23.5% 41%, #d8b97b 41.5% 42.5%, #f8f2e7 43% 100%); }
.food-share .menu-food-art { background: radial-gradient(circle at 53% 42%, #d88b43 0 20%, #925834 20.5% 23%, #f9e6bd 23.5% 40%, #d9b17d 40.5% 42%, #fbf1dc 42.5% 100%); }
.food-drink .menu-food-art { background: radial-gradient(circle at 52% 36%, rgba(244, 211, 118, .95) 0 22%, rgba(220, 157, 65, .82) 22.5% 31%, rgba(239, 246, 238, .9) 31.5% 52%, #e0f0ec 52.5% 100%); }
.food-drink .menu-food-art::before { background: #559763; box-shadow: 86px 21px 0 #f0bd43, 150px 8px 0 #69a9ae, 172px 64px 0 #559763; }
.food-dessert .menu-food-art { background: radial-gradient(circle at 52% 39%, #f7d3b8 0 18%, #b4544f 18.5% 26%, #f7efe3 26.5% 41%, #b68d74 41.5% 42.5%, #fbf3ed 43% 100%); }
.food-dessert .menu-food-art::before { background: #f3edc4; box-shadow: 77px 23px 0 #bc5c6e, 153px 4px 0 #f2c267, 176px 66px 0 #8ab06c; }
.public-menu-card-main { padding: 18px 18px 10px; }
.public-menu-card-main small { color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .1em; }
.public-menu-card h3 { margin: 5px 0 7px; font-size: 20px; line-height: 1.3; }
.public-menu-card p { min-height: 40px; color: var(--ink-soft); font-size: 14px; line-height: 1.55; }
.public-menu-card b { display: block; margin-top: 14px; color: #1c5847; font-size: 20px; }
.public-menu-card-options { display: grid; gap: 9px; padding: 4px 18px 11px; }
.public-modifiers { display: grid; gap: 7px; margin: 0; padding: 10px 11px; border: 1px solid #e2ddd3; border-radius: 11px; background: #fbfaf7; }
.public-modifiers legend { padding: 0 4px; color: var(--ink-soft); font-size: 12px; font-weight: 800; }
.public-modifiers label { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 13px; font-weight: 600; }
.public-modifiers input { width: 17px; min-height: 17px; padding: 0; accent-color: var(--brand); }
.public-menu-card-action { padding: 6px 18px 18px; }
.public-menu-card .button.secondary { border-color: #b7c7bd; color: #1b5a48; background: #fbfdfb; }
.public-menu-card .button.secondary:hover:not(:disabled) { border-color: #1b5a48; color: #fff; background: #1b5a48; }
.public-cart {
  z-index: 3;
  top: 104px;
  right: max(18px, calc((100vw - 1340px) / 2));
  width: min(352px, calc(100vw - 36px));
  max-height: calc(100vh - 124px);
  gap: 14px;
  overflow: auto;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 20px;
  background: linear-gradient(160deg, #12382e, #0e2d25);
  box-shadow: 0 18px 35px rgba(17, 44, 36, .26);
}
.public-cart::before { position: absolute; top: -83px; right: -47px; width: 176px; height: 176px; border: 1px solid rgba(245, 191, 132, .25); border-radius: 50%; content: ''; pointer-events: none; }
.public-cart > * { position: relative; z-index: 1; }
.public-cart .eyebrow { margin-bottom: 4px; color: #f5bd87; }
.public-cart h3 { font-size: 25px; }
.public-cart-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.cart-count { display: grid; width: 35px; height: 35px; place-items: center; border-radius: 50%; color: #12382e; background: #f4c18d; font-weight: 900; }
.public-cart-lines { min-height: 68px; }
.public-cart-lines button { display: grid; width: 25px; height: 25px; place-items: center; border: 1px solid rgba(255,255,255,.46); border-radius: 50%; color: #fff; background: transparent; font-size: 18px; line-height: 1; }
.public-guest-count { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #d8ebdf; font-size: 13px; }
.public-guest-count select { width: 96px; min-height: 36px; padding: 6px 9px; border-color: rgba(255,255,255,.26); border-radius: 9px; color: #183a30; font-size: 13px; }
.public-cart-total b { font-size: 27px; }
.public-cart .button.primary { color: #fff; background: #e86a32; box-shadow: none; }
.public-cart .button.primary:hover:not(:disabled) { background: #f17b42; }
.public-cart .button.primary:disabled { color: rgba(255,255,255,.67); background: rgba(255,255,255,.13); }

@media (max-width: 1180px) {
  .public-menu { padding-right: 350px; }
  .public-cart { right: 18px; width: 326px; }
}

@media (max-width: 900px) {
  .public-menu { padding-right: 0; padding-bottom: 273px; }
  .public-cart { top: auto; right: 0; bottom: 0; width: 100%; max-width: none; max-height: 244px; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 20px; padding: 15px 20px max(15px, env(safe-area-inset-bottom)); border-radius: 21px 21px 0 0; }
  .public-cart-head { grid-column: 1; }
  .public-cart-lines { grid-column: 1 / -1; max-height: 74px; padding: 7px 0; overflow: auto; }
  .public-guest-count { grid-column: 1; }
  .public-cart-total { grid-column: 1; }
  .public-cart .button { grid-column: 2; grid-row: 3 / span 2; min-width: 155px; }
  .public-cart > small { display: none; }
}

@media (max-width: 650px) {
  .public-top { min-height: 70px; padding: 11px 16px; }
  .public-top-landing { min-height: 72px; }
  .public-brand .brand-mark { width: 35px; height: 35px; font-size: 21px; }
  .public-brand b { font-size: 15px; }
  .public-brand small { font-size: 9px; }
  .public-table-status { padding: 7px 9px; }
  .public-table-status b { font-size: 11px; }
  .public-table-status small { display: none; }
  .public-shell { width: min(100% - 28px, 1340px); padding-top: 22px; }
  .public-hero { min-height: 356px; padding: 31px 24px; border-radius: 20px; background-position: 61% center; }
  .public-hero h1 { max-width: 315px; font-size: clamp(32px, 10vw, 44px); }
  .public-hero p:not(.eyebrow) { max-width: 300px; margin-top: 13px; font-size: 14px; }
  .public-service-points { margin-top: 18px; }
  .public-service-points span { padding: 6px 8px; font-size: 10px; }
  .public-category-nav { margin: 14px 0 20px; }
  .category-link { min-height: 40px; padding: 8px 12px; font-size: 13px; }
  .public-menu { gap: 19px; padding-bottom: 278px; }
  .public-category { padding: 18px 15px; border-radius: 17px; }
  .public-category-heading { gap: 11px; margin-bottom: 16px; }
  .category-emblem { width: 45px; height: 45px; flex-basis: 45px; border-radius: 15px 15px 15px 4px; font-size: 23px; }
  .public-category-heading h2 { font-size: 25px; }
  .public-category-heading p:not(.eyebrow) { font-size: 12px; }
  .public-item-grid { grid-template-columns: 1fr; gap: 13px; }
  .menu-food-art { height: 119px; }
  .public-cart { max-height: 258px; padding-inline: 16px; }
  .public-cart h3 { font-size: 20px; }
  .public-cart .button { min-width: 135px; font-size: 13px; }
}

@media (max-width: 410px) {
  .public-table-status b { display: none; }
  .public-table-status { padding: 9px; }
  .public-cart { grid-template-columns: 1fr; max-height: 283px; }
  .public-cart-head, .public-guest-count, .public-cart-total, .public-cart .button { grid-column: 1; grid-row: auto; }
  .public-cart .button { min-width: 0; }
  .public-menu { padding-bottom: 302px; }
}

/* Demonstration polish: make the back-office feel like a finished restaurant product. */
body.staff-app {
  background:
    radial-gradient(circle at 92% 4%, rgba(234, 139, 66, .12), transparent 23rem),
    radial-gradient(circle at 48% 98%, rgba(47, 109, 88, .09), transparent 28rem),
    var(--canvas);
}
.sidebar {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(5, 36, 29, .97), rgba(8, 44, 35, .98)),
    url("./images/morning-table-hero-food-v1.png") center / cover no-repeat;
}
.sidebar::before,
.sidebar::after {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(239, 177, 113, .18);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}
.sidebar::before { top: -115px; right: -125px; width: 305px; height: 305px; }
.sidebar::after { bottom: -145px; left: -145px; width: 310px; height: 310px; }
.brand { padding: 8px 9px 18px; border-bottom: 1px solid rgba(255,255,255,.12); }
.brand .brand-mark { box-shadow: 0 8px 18px rgba(0,0,0,.22); }
.sidebar-caption { color: #b7dacb; font-weight: 700; letter-spacing: .04em; }
.nav-item { position: relative; overflow: hidden; }
.nav-item::after { position: absolute; top: 0; bottom: 0; left: 0; width: 3px; border-radius: 0 4px 4px 0; content: ''; background: transparent; }
.nav-item.active { background: linear-gradient(105deg, #e86a32, #d85625); }
.nav-item.active::after { background: #ffd0a9; }
.pos-main { background: transparent; }
.topbar {
  position: relative;
  overflow: hidden;
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(15px);
}
.topbar::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  content: '';
  background: linear-gradient(90deg, transparent, rgba(237,101,48,.42), transparent);
}
.topbar h1 { letter-spacing: .01em; }
.branch-picker { box-shadow: 0 5px 13px rgba(34, 62, 50, .04); }
.user-chip { position: relative; }
.user-chip::before { position: absolute; top: 4px; left: -1px; width: 2px; height: 28px; border-radius: 999px; content: ''; background: var(--accent); }
.content { position: relative; }
.hero-card {
  position: relative;
  min-height: 226px;
  isolation: isolate;
  border: 1px solid rgba(255,255,255,.18);
  background:
    linear-gradient(90deg, rgba(8, 46, 37, .98), rgba(11, 51, 41, .91) 45%, rgba(7, 43, 35, .35)),
    url("./images/morning-table-hero-food-v1.png") center / cover no-repeat;
  box-shadow: 0 22px 46px rgba(13, 55, 44, .19);
}
.hero-card::before,
.hero-card::after {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}
.hero-card::before { right: 6%; bottom: -120px; width: 310px; height: 310px; }
.hero-card::after { top: -155px; right: 24%; width: 235px; height: 235px; }
.hero-card .button.light {
  min-height: 50px;
  border: 1px solid rgba(255,255,255,.78);
  color: var(--brand-deep);
  box-shadow: 0 10px 24px rgba(0,0,0,.14);
}
.hero-card .button.light:hover:not(:disabled) { color: #fff; border-color: #f18a57; background: var(--accent); }
.metric {
  position: relative;
  overflow: hidden;
  border-color: rgba(189,203,195,.8);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.metric::before { position: absolute; top: 0; right: 18px; left: 18px; height: 3px; border-radius: 0 0 4px 4px; content: ''; background: linear-gradient(90deg, var(--brand), #7fb49d); }
.metric:nth-child(2)::before { background: linear-gradient(90deg, var(--accent), #f4b377); }
.metric:nth-child(3)::before { background: linear-gradient(90deg, #28747b, #86c1c3); }
.metric:nth-child(4)::before { background: linear-gradient(90deg, #9d6570, #e6b9be); }
.metric:hover { transform: translateY(-3px); border-color: #a5bdaf; box-shadow: 0 16px 28px rgba(15,51,41,.1); }
.panel { border-color: rgba(189,203,195,.85); }
.panel-heading h3 { letter-spacing: .01em; }
.qr-workflow {
  position: relative;
  overflow: hidden;
  border-color: rgba(173, 129, 78, .24);
  background:
    radial-gradient(circle at 93% 18%, rgba(237,101,48,.16), transparent 12rem),
    linear-gradient(118deg, #f1f6f1, #fffaf5 68%, #f9eee4);
}
.qr-workflow::after { position: absolute; top: -78px; right: -58px; width: 185px; height: 185px; border: 1px solid rgba(237,101,48,.2); border-radius: 50%; content: ''; pointer-events: none; }
.qr-workflow > * { position: relative; z-index: 1; }
.table-card { position: relative; overflow: hidden; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.table-card::before { position: absolute; top: 0; right: 0; left: 0; height: 4px; content: ''; background: linear-gradient(90deg, #4c8a72, #a3cfb9); }
.table-card.occupied::before { background: linear-gradient(90deg, #5b80b3, #b9d0ee); }
.table-card:hover { transform: translateY(-3px); border-color: #aac1b3; box-shadow: var(--shadow-soft); }
.order-cart { border: 1px solid rgba(255,255,255,.08); }
.order-cart::before { position: absolute; top: -100px; right: -86px; width: 208px; height: 208px; border: 1px solid rgba(249, 194, 138, .21); border-radius: 50%; content: ''; pointer-events: none; }
.order-cart > * { position: relative; z-index: 1; }
.checkout-orders .order-select { transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease; }
.checkout-orders .order-select:hover { transform: translateX(3px); box-shadow: 0 8px 17px rgba(15,51,41,.06); }

@media (max-width: 820px) {
  .hero-card { min-height: 205px; background-position: 63% center; }
  .hero-card::after { display: none; }
}

/* Demonstration entry: the first screen should sell the restaurant flow before staff sign-in. */
.login-shell {
  grid-template-columns: minmax(0, 1.22fr) minmax(360px, .78fr);
  gap: clamp(26px, 5vw, 78px);
  place-items: unset;
  align-items: center;
  justify-items: center;
  padding: clamp(24px, 5vw, 76px);
}
.login-showcase {
  position: relative;
  isolation: isolate;
  width: min(100%, 824px);
  min-height: 614px;
  overflow: hidden;
  padding: clamp(35px, 5.4vw, 74px);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 34px;
  color: #fff;
  background:
    linear-gradient(98deg, rgba(6, 39, 31, .98) 0%, rgba(9, 48, 38, .91) 49%, rgba(9, 48, 38, .36) 100%),
    url("./images/morning-table-hero-food-v1.png") center / cover no-repeat;
  box-shadow: 0 30px 74px rgba(0,0,0,.27);
}
.login-showcase::before,
.login-showcase::after {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(248, 195, 139, .25);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}
.login-showcase::before { top: -150px; right: -125px; width: 374px; height: 374px; }
.login-showcase::after { bottom: -164px; right: 19%; width: 292px; height: 292px; }
.login-showcase .eyebrow { color: #f5bd87; }
.login-showcase h1 {
  max-width: 690px;
  margin: 15px 0 20px;
  color: #fff;
  font-size: clamp(40px, 4vw, 56px);
  line-height: 1.12;
  letter-spacing: -.035em;
}
.login-showcase h1 span { display: inline-block; letter-spacing: -.055em; white-space: nowrap; }
.login-showcase-copy {
  max-width: 580px;
  color: rgba(239,248,243,.83);
  font-size: clamp(16px, 1.45vw, 19px);
  line-height: 1.75;
}
.demo-flow-cards {
  display: grid;
  gap: 10px;
  max-width: 590px;
  margin-top: 34px;
}
.demo-flow-cards article {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  gap: 13px;
  padding: 12px 15px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 16px;
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(7px);
}
.demo-flow-cards span {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 13px 13px 13px 4px;
  color: #0f3d31;
  background: #f5bd87;
  font-size: 12px;
  font-weight: 900;
}
.demo-flow-cards b { display: block; color: #fff; font-size: 15px; }
.demo-flow-cards small { display: block; margin-top: 3px; color: rgba(240,249,245,.72); font-size: 12px; }
.login-showcase-actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 32px; }
.login-showcase .button.light {
  min-height: 51px;
  border: 1px solid rgba(255,255,255,.7);
  color: #143a30;
  box-shadow: 0 10px 25px rgba(0,0,0,.16);
}
.login-showcase .button.light:hover { border-color: #f39760; color: #fff; background: var(--accent); }
.light-link { color: rgba(255,255,255,.92); }
.light-link:hover { color: #f7c99e; }
.login-showcase-note { margin-top: 28px; color: rgba(239,248,243,.6); font-size: 12px; }
.login-card {
  position: relative;
  justify-self: start;
  width: min(100%, 470px);
  overflow: hidden;
}
.login-card::before {
  position: absolute;
  top: -74px;
  right: -69px;
  width: 182px;
  height: 182px;
  border: 1px solid rgba(237,101,48,.17);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}
.login-card > * { position: relative; z-index: 1; }
.login-card .brand-mark { box-shadow: 0 12px 22px rgba(237,101,48,.22); }

@media (max-width: 980px) {
  .login-shell { grid-template-columns: minmax(0, 1fr); min-height: 100vh; max-width: 860px; margin: 0 auto; }
  .login-showcase { min-height: 0; }
  .login-card { justify-self: center; }
}

@media (max-width: 650px) {
  .login-shell { gap: 17px; padding: 14px; }
  .login-showcase { min-height: 0; padding: 31px 22px; border-radius: 24px; background-position: 62% center; }
  .login-showcase h1 { margin: 11px 0 14px; font-size: clamp(31px, 9vw, 38px); }
  .login-showcase-copy { font-size: 14px; line-height: 1.65; }
  .demo-flow-cards { gap: 8px; margin-top: 23px; }
  .demo-flow-cards article { grid-template-columns: 36px 1fr; gap: 10px; padding: 10px; }
  .demo-flow-cards span { width: 35px; height: 35px; border-radius: 11px 11px 11px 3px; font-size: 11px; }
  .demo-flow-cards b { font-size: 13px; }
  .demo-flow-cards small { font-size: 11px; }
  .login-showcase-actions { gap: 13px; margin-top: 24px; }
  .login-showcase-note { margin-top: 20px; }
  .login-card { width: 100%; }
}
