/* ═══════════════════════════════════════════════════════════════════════════
   App styles — shell, views, components. Logical properties keep RTL free.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── App shell ─────────────────────────────────────────────────────────────── */

#app-root {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.appbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px var(--pad-page);
  background: color-mix(in srgb, var(--ink) 82%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.appbar-store {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  text-align: start;
}

.appbar-logo {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--surface-2);
  flex-shrink: 0;
}

.appbar-name {
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text);
}

.appbar-actions { display: flex; align-items: center; gap: 6px; }

.iconbtn {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  font-size: 16px;
  transition: transform 0.15s var(--ease-spring), border-color 0.15s;
}
.iconbtn:active { transform: scale(0.92); }
.iconbtn.lang { font-size: 12px; font-weight: 700; letter-spacing: 0.04em; }

.appbar-avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  object-fit: cover;
  border: 2px solid var(--glow);
  cursor: pointer;
  background: var(--surface-2);
}

/* ── Main + bottom nav ─────────────────────────────────────────────────────── */

.view {
  flex: 1;
  width: 100%;
  max-width: var(--content-max);
  margin-inline: auto;
  padding: 0 var(--pad-page) calc(86px + env(safe-area-inset-bottom, 0px));
  animation: view-in 0.28s ease both;
}

@keyframes view-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.bottomnav {
  position: fixed;
  bottom: 0;
  inset-inline: 0;
  z-index: 40;
  display: flex;
  justify-content: center;
  gap: 4px;
  padding: 8px max(10px, env(safe-area-inset-left)) calc(8px + env(safe-area-inset-bottom, 0px));
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}

.bottomnav-item {
  flex: 1;
  max-width: 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 6px 4px;
  border: none;
  background: none;
  border-radius: var(--r-md);
  cursor: pointer;
  color: var(--text-2);
  font-size: 11px;
  font-weight: 600;
  transition: color 0.15s;
}

.bottomnav-item .nav-ic { font-size: 20px; line-height: 1; transition: transform 0.2s var(--ease-spring); }

.bottomnav-item.active { color: var(--glow); }
.bottomnav-item.active .nav-ic { transform: translateY(-2px) scale(1.12); }

/* ── Hero (home) ───────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  margin: 0 calc(-1 * var(--pad-page));
  height: clamp(210px, 44vw, 300px);
  overflow: hidden;
  border-radius: 0 0 var(--r-lg) var(--r-lg);
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
  transform: scale(1.02);
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16, 20, 24, 0.35) 0%, rgba(16, 20, 24, 0) 35%, rgba(16, 20, 24, 0.82) 100%);
}

/* identity overlays the hero's lower edge — cover, name and slogan read as one object */
.identity {
  position: absolute;
  inset-inline: clamp(16px, 3vw, 26px);
  bottom: clamp(14px, 2.6vw, 22px);
  z-index: 2;
  display: flex;
  align-items: flex-end;
  gap: 14px;
  animation: rise 0.5s 0.08s var(--ease-spring) both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}

.identity-logo {
  width: clamp(56px, 8vw, 76px);
  height: clamp(56px, 8vw, 76px);
  border-radius: var(--r-md);
  object-fit: cover;
  background: var(--surface);
  border: 2.5px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  flex-shrink: 0;
}

.identity-text { min-width: 0; padding-bottom: 2px; }

.identity-name {
  margin: 0;
  font-size: clamp(21px, 5.6vw, 30px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: #f6f7f8;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.55);
}

.identity-slogan {
  margin: 2px 0 0;
  color: rgba(246, 247, 248, 0.82);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
  font-size: 13.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* live status pill */
.status-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* live status chip pinned inside the hero's top corner */
.hero-status {
  position: absolute;
  top: 14px;
  inset-inline-end: 14px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: var(--r-pill);
  background: rgba(12, 15, 19, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.hero-status .pill { background: none; padding: 0; }
.hero-status .status-hint { color: rgba(246, 247, 248, 0.85); }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 13px;
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 700;
}

.pill-open { background: var(--mint-soft); color: var(--mint); }
.pill-closed { background: var(--rose-soft); color: var(--rose); }

.pill .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}
.pill-open .dot { animation: pulse 1.6s ease infinite; }

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(62, 207, 142, 0.45); }
  55% { box-shadow: 0 0 0 6px rgba(62, 207, 142, 0); }
}

.status-hint { color: var(--text-2); font-size: 12.5px; }

/* ── Cards ─────────────────────────────────────────────────────────────────── */

.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 18px;
  margin-top: 16px;
  box-shadow: var(--shadow-card);
}

.card-title {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 800;
}

.card-sub { margin: 0 0 12px; color: var(--text-2); font-size: 13px; }

.card-head-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* ── Buttons ───────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 18px;
  border-radius: var(--r-md);
  border: none;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: transform 0.15s var(--ease-spring), filter 0.15s, opacity 0.15s;
}
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.btn-glow {
  background: linear-gradient(135deg, var(--glow), var(--glow-deep));
  color: var(--glow-ink);
  box-shadow: var(--shadow-glow);
}
.btn-glow:hover { filter: brightness(1.05); }

.btn-quiet {
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--text);
}

.btn-danger { background: var(--rose-soft); color: var(--rose); }

.btn-whatsapp { background: var(--whatsapp); color: #06301b; }

.btn-inline { width: auto; padding: 9px 16px; font-size: 13.5px; border-radius: var(--r-pill); }

/* ── The Queue Ticket (signature) ─────────────────────────────────────────── */

.ticket-wrap { margin-top: 18px; perspective: 700px; }

.ticket {
  position: relative;
  background: linear-gradient(150deg, var(--glow) 0%, var(--glow-deep) 100%);
  color: var(--glow-ink);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-glow), var(--shadow-card);
  overflow: hidden;
  animation: ticket-print 0.6s var(--ease-spring) both;
}

@keyframes ticket-print {
  from { opacity: 0; transform: translateY(26px) rotateX(18deg); }
  to { opacity: 1; transform: none; }
}

.ticket-main { padding: 20px 20px 14px; text-align: center; }

.ticket-label {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.75;
}

.ticket-number {
  font-family: var(--font-ticket);
  font-weight: 800;
  font-size: clamp(64px, 21vw, 96px);
  line-height: 1;
  letter-spacing: -0.03em;
  margin: 2px 0 4px;
}

.ticket-number.is-turn { font-size: clamp(34px, 10vw, 44px); line-height: 1.15; padding: 14px 0; }

.ticket-msg { font-size: 13.5px; font-weight: 600; opacity: 0.9; margin: 0; }

/* perforated tear line */
.ticket-tear {
  position: relative;
  height: 0;
  border-top: 2px dashed rgba(42, 28, 8, 0.35);
  margin: 8px 14px 0;
}
.ticket-tear::before, .ticket-tear::after {
  content: '';
  position: absolute;
  top: -9px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--ink);
}
.ticket-tear::before { inset-inline-start: -24px; }
.ticket-tear::after { inset-inline-end: -24px; }

.ticket-stub {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 20px 16px;
  font-size: 12.5px;
  font-weight: 600;
}

.ticket-stub .stub-cell { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.ticket-stub .stub-k { font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.65; }
.ticket-stub .stub-v { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.ticket-actions { display: flex; gap: 10px; margin-top: 12px; }
.ticket-actions .btn { padding: 11px 14px; font-size: 13.5px; }

/* waiting count strip under the ticket / join card */
.queue-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
  color: var(--text-2);
  font-size: 13px;
}
.queue-meta b { color: var(--text); }

/* ── Loyalty strip ─────────────────────────────────────────────────────────── */

.loyalty-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.loyalty-cell {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 12px 10px;
  text-align: center;
}

.loyalty-cell .l-v {
  font-family: var(--font-ticket);
  font-weight: 800;
  font-size: 22px;
  line-height: 1.15;
}

.loyalty-cell .l-k { font-size: 11px; color: var(--text-2); font-weight: 600; margin-top: 2px; }

/* ── Menu ──────────────────────────────────────────────────────────────────── */

.menu-toolbar {
  position: sticky;
  top: 58px;
  z-index: 30;
  margin: 10px calc(-1 * var(--pad-page)) 4px;
  padding: 10px var(--pad-page) 4px;
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.menu-toolbar-row { display: flex; gap: 10px; align-items: center; }

.menu-search {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
}
.menu-search .ms-ic {
  position: absolute;
  inset-inline-start: 13px;
  font-size: 14px;
  opacity: 0.65;
  pointer-events: none;
}
.menu-search input {
  width: 100%;
  padding: 12px 40px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font-size: 14.5px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.menu-search input:focus {
  outline: none;
  border-color: var(--glow);
  box-shadow: 0 0 0 3px rgba(255, 180, 84, 0.18);
}
.menu-search input::placeholder { color: var(--text-2); }
.menu-search input::-webkit-search-cancel-button { display: none; }
.menu-search .ms-clear {
  position: absolute;
  inset-inline-end: 8px;
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 12px;
  cursor: pointer;
}

.menu-branch { width: auto; max-width: 190px; border-radius: var(--r-pill); padding: 11px 14px; font-size: 13.5px; }

.chip-count {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: var(--r-pill);
  background: rgba(127, 127, 127, 0.18);
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}
.cat-chip.active .chip-count { background: rgba(42, 28, 8, 0.22); }

.cat-count {
  margin-inline-start: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-2);
  background: var(--surface-2);
  border-radius: var(--r-pill);
  padding: 2px 9px;
  vertical-align: 3px;
}

.result-count { margin: 10px 2px 10px; font-size: 12.5px; font-weight: 700; color: var(--text-2); }

.cat-rail {
  margin-top: 8px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px 10px;
  scrollbar-width: none;
  position: sticky;
  top: 59px;
  z-index: 10;
  background: var(--ink);
}
.cat-rail::-webkit-scrollbar { display: none; }

.cat-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text-2);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s;
}
.cat-chip img { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; }
.cat-chip.active { background: var(--glow); border-color: var(--glow); color: var(--glow-ink); }

.menu-cat-title {
  font-family: var(--font-ticket);
  font-size: 17px;
  font-weight: 800;
  margin: 22px 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.menu-cat-title img { width: 24px; height: 24px; border-radius: 8px; object-fit: cover; }

.menu-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
@media (min-width: 640px) { .menu-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .menu-grid { grid-template-columns: repeat(4, 1fr); gap: 14px; } }

/* (the row-card menu treatment retired — product cards own .menu-item now, later in this file) */
.price-now { font-weight: 800; color: var(--glow); font-size: 15px; white-space: nowrap; }
.price-old { color: var(--text-2); font-size: 12px; text-decoration: line-through; }

.branch-select-row { display: flex; align-items: center; gap: 8px; margin: 6px 0 4px; }
.branch-select-row select {
  flex: 1;
  padding: 10px 12px;
  border-radius: var(--r-md);
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
}

/* ── Account view ──────────────────────────────────────────────────────────── */

.account-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
}

.account-avatar {
  width: 74px;
  height: 74px;
  border-radius: var(--r-lg);
  object-fit: cover;
  border: 3px solid var(--glow);
  background: var(--surface-2);
}

.account-name { margin: 0; font-size: 19px; font-weight: 800; }
.account-mobile { margin: 2px 0 0; color: var(--text-2); font-size: 13px; direction: ltr; unicode-bidi: embed; }

.list-group { margin-top: 16px; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }

.list-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  background: var(--surface);
  border: none;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text);
  text-align: start;
}
.list-row:last-child { border-bottom: none; }
.list-row .row-ic { width: 24px; text-align: center; font-size: 17px; }
.list-row .row-arrow { margin-inline-start: auto; color: var(--text-2); }
.list-row.danger { color: var(--rose); }

/* ── Sheet (bottom sheet / modal) ─────────────────────────────────────────── */

.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(6, 8, 10, 0.62);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fade 0.2s ease both;
}

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.sheet {
  width: 100%;
  max-width: 560px;
  max-height: 88dvh;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  border: 1px solid var(--line);
  animation: sheet-up 0.32s var(--ease-spring) both;
}

@keyframes sheet-up {
  from { transform: translateY(48px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@media (min-width: 640px) {
  .sheet-backdrop { align-items: center; padding: 24px; }
  .sheet { border-radius: var(--r-lg); }
}

.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 20px 10px;
}

.sheet-grip {
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: var(--line);
  margin: 8px auto 0;
}

.sheet-title { margin: 0; font-size: 17px; font-weight: 800; }

.sheet-x {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: none;
  background: var(--surface-2);
  cursor: pointer;
  font-size: 15px;
  color: var(--text-2);
}

.sheet-body { padding: 6px 20px 20px; overflow-y: auto; }
.sheet-foot { display: flex; gap: 10px; padding: 12px 20px calc(16px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); }

/* ── Forms ─────────────────────────────────────────────────────────────────── */

.f-group { margin-bottom: 14px; }
.f-label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--text-2); }
.f-input {
  width: 100%;
  padding: 13px 14px;
  border-radius: var(--r-md);
  background: var(--surface-2);
  border: 1.5px solid var(--line);
  color: var(--text);
  font-size: 15px;
  transition: border-color 0.15s;
}
.f-input:focus { outline: none; border-color: var(--glow); }
.f-hint { font-size: 12px; color: var(--text-2); margin-top: 5px; }
.f-error { font-size: 12.5px; color: var(--rose); margin-top: 5px; }

/* ── Toasts ────────────────────────────────────────────────────────────────── */

#toasts {
  position: fixed;
  top: calc(12px + env(safe-area-inset-top, 0px));
  inset-inline: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
  padding: 0 var(--pad-page);
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 480px;
  padding: 11px 18px;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-pop);
  font-size: 13.5px;
  font-weight: 600;
  animation: toast-in 0.3s var(--ease-spring) both;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-14px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

.toast.success { border-color: var(--mint); color: var(--mint); }
.toast.error { border-color: var(--rose); color: var(--rose); }
.toast.warning { border-color: var(--glow); color: var(--glow); }

/* ── Skeletons ─────────────────────────────────────────────────────────────── */

.skel {
  background: linear-gradient(100deg, var(--surface) 40%, var(--surface-2) 50%, var(--surface) 60%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: var(--r-md);
}

@keyframes shimmer { to { background-position: -200% 0; } }

/* ── Error page ────────────────────────────────────────────────────────────── */

.error-page {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  padding: 40px var(--pad-page);
}
.error-page .err-ic { font-size: 52px; }
.error-page h2 { margin: 0; font-size: 20px; font-weight: 800; }
.error-page p { margin: 0; color: var(--text-2); max-width: 380px; }

/* ── Empty state ───────────────────────────────────────────────────────────── */

.empty {
  text-align: center;
  padding: 34px 16px;
  color: var(--text-2);
}
.empty .empty-ic {
  display: inline-grid; place-items: center;
  width: 52px; height: 52px; margin-bottom: 10px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--glow) 9%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--glow) 22%, var(--line));
  color: var(--glow);
}
.empty p { margin: 0; font-size: 14px; }

/* ── Survey ────────────────────────────────────────────────────────────────── */

.survey-progress {
  height: 5px;
  border-radius: 3px;
  background: var(--surface-2);
  margin-bottom: 16px;
  overflow: hidden;
}
.survey-progress > div {
  height: 100%;
  background: linear-gradient(90deg, var(--glow), var(--glow-deep));
  border-radius: 3px;
  transition: width 0.3s ease;
}

.survey-q { font-size: 17px; font-weight: 700; margin: 0 0 16px; line-height: 1.45; }

.survey-opt {
  display: block;
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 9px;
  border-radius: var(--r-md);
  border: 1.5px solid var(--line);
  background: var(--surface-2);
  text-align: start;
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.survey-opt:hover { border-color: var(--glow); }

/* ── Footer ────────────────────────────────────────────────────────────────── */

.site-footer {
  text-align: center;
  padding: 22px var(--pad-page) 8px;
  color: var(--text-2);
  font-size: 12px;
}
.site-footer a { color: var(--glow); font-weight: 700; text-decoration: none; }

/* ── Home two-pane grid (mobile: single column, rail first) ────────────────── */

.home-grid { display: flex; flex-direction: column; }
.home-side, .home-main { min-width: 0; }

/* ── Desktop refinements ───────────────────────────────────────────────────── */

@media (min-width: 760px) {
  .bottomnav { display: none; }
  .view { padding-bottom: 48px; }

  /* 3-zone appbar: brand | centered tabs | actions — no more stranded clusters */
  .appbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    padding-block: 12px;
  }
  .appbar-store { justify-self: start; flex: initial; }
  .appbar-actions { justify-self: end; }
  .appbar-tabs {
    display: flex;
    gap: 4px;
    padding: 4px;
    border-radius: var(--r-pill);
    background: var(--surface);
    border: 1px solid var(--line);
  }
  .appbar-tab {
    padding: 7px 16px;
    border-radius: var(--r-pill);
    border: none;
    background: none;
    color: var(--text-2);
    font-weight: 700;
    font-size: 13.5px;
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
  }
  .appbar-tab:hover { color: var(--text); }
  .appbar-tab.active { background: var(--glow); color: var(--glow-ink); }
}
@media (max-width: 759px) {
  .appbar-tabs { display: none; }
}

/* wide desktop: the lounge desk — framed hero, main feed + sticky ticket rail */
@media (min-width: 1000px) {
  .view { max-width: 1160px; }
  .appbar { padding-inline: max(var(--pad-page), calc((100% - 1160px) / 2 + var(--pad-page))); }

  .hero {
    margin: 22px 0 0;
    border-radius: var(--r-lg);
    height: 320px;
    box-shadow: var(--shadow-card);
  }

  .status-row { margin-top: 16px; }

  .home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 400px;
    gap: 26px;
    align-items: start;
    margin-top: 8px;
  }
  .home-main { grid-column: 1; grid-row: 1; }
  .home-side { grid-column: 2; grid-row: 1; position: sticky; top: 86px; }
  .home-side .ticket-wrap { margin-top: 16px; }
  .home-side .card { margin-top: 16px; }
  .home-main .card:first-child { margin-top: 16px; }

  /* menu items flow in columns on wide screens */
  .menu-view .menu-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .menu-toolbar { top: 63px; border-radius: 0 0 var(--r-md) var(--r-md); }

  /* narrow, centered single-purpose views */
  .turn-view, .account-view { max-width: 560px; margin-inline: auto; }
  .turn-view .view-title { text-align: center; }

  .site-footer { margin-top: 40px; }

  .menu-view { max-width: 900px; margin-inline: auto; }
}

/* ── Late additions (view helpers) ─────────────────────────────────────────── */

.view-title { margin: 18px 0 4px; font-size: 22px; font-weight: 800; font-family: var(--font-ticket); letter-spacing: 0.01em; }

.menu-section { margin-top: 6px; }

.join-ic { font-size: 38px; text-align: center; margin-bottom: 4px; }

.ghost-ticket {
  position: relative;
  margin-top: 18px;
  padding: 20px;
  text-align: center;
  border-radius: var(--r-lg);
  border: 2px dashed color-mix(in srgb, var(--glow) 40%, var(--line));
  background: color-mix(in srgb, var(--glow) 4%, var(--surface));
}
.ghost-ticket::before, .ghost-ticket::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--ink);
  border: 2px dashed color-mix(in srgb, var(--glow) 40%, var(--line));
  transform: translateY(-50%);
}
.ghost-ticket::before { inset-inline-start: -11px; }
.ghost-ticket::after { inset-inline-end: -11px; }

/* footer strip of the ticket that holds its action buttons */
.ticket-foot { padding: 0 20px 18px; }

/* decorative barcode stub — bars + a mono serial, pure CSS */
.ticket-barcode { padding: 2px 24px 10px; text-align: center; }
.ticket-barcode .tb-bars {
  height: 26px;
  border-radius: 3px;
  background: repeating-linear-gradient(
    90deg,
    color-mix(in srgb, var(--glow-ink) 80%, transparent) 0 2px, transparent 2px 5px,
    color-mix(in srgb, var(--glow-ink) 80%, transparent) 5px 6px, transparent 6px 8px,
    color-mix(in srgb, var(--glow-ink) 80%, transparent) 8px 12px, transparent 12px 14px
  );
  opacity: 0.75;
}
.ticket-barcode .tb-serial {
  margin-top: 4px;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.35em;
  opacity: 0.6;
}
.ticket-foot .ticket-actions { margin-top: 0; }

.stub-wa {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 20px 10px;
  font-size: 13px;
  font-weight: 600;
}

.btn-link {
  border: none;
  background: none;
  padding: 2px 4px;
  font-weight: 700;
  font-size: 12.5px;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}

/* iOS-style switch (notifications toggle) */
.switch { position: relative; display: inline-flex; margin-inline-start: auto; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.switch-track {
  width: 46px;
  height: 27px;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  border: 1px solid var(--line);
  transition: background 0.2s;
  display: block;
}
.switch-thumb {
  position: absolute;
  top: 3.5px;
  inset-inline-start: 4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--text-2);
  transition: transform 0.2s var(--ease-spring), background 0.2s;
  display: block;
}
.switch input:checked + .switch-track { background: var(--mint-soft); border-color: var(--mint); }
.switch input:checked + .switch-track .switch-thumb { transform: translateX(19px); background: var(--mint); }
[dir='rtl'] .switch input:checked + .switch-track .switch-thumb { transform: translateX(-19px); }
.switch input:disabled + .switch-track { opacity: 0.5; }

/* ambient background — the store's logo as a soft blurred wash behind everything */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.8s ease;
}
.ambient-bg.on { opacity: 1; }
.ambient-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(70px) saturate(1.15);
  transform: scale(1.2);
  opacity: 0.16;
}
.ambient-veil { position: absolute; inset: 0; background: linear-gradient(180deg, transparent, var(--ink) 78%); }

/* list group section label */
.list-title {
  padding: 12px 16px 6px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-2);
  background: var(--surface);
}

/* on-ticket button variants — the amber ground needs darker, opaque ink */
.ticket .btn-danger { background: rgba(42, 28, 8, 0.16); color: #7e1626; }
.ticket .btn-quiet { background: rgba(23, 29, 36, 0.88); color: #f2f4f6; }


/* the turn view's own title already says "waiting list" — the ghost card doesn't repeat it */
.turn-view .ghost-ticket .card-title { display: none; }

/* ── Online services (bot web forms) ───────────────────────────────────────── */

.services-list { margin-top: 14px; }

.service-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  margin-bottom: 10px;
  border-radius: var(--r-md);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  transition: transform 0.15s var(--ease-spring), border-color 0.15s;
}
@media (hover: hover) {
  .service-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--glow) 45%, var(--line)); }
}
.service-card .service-ic { font-size: 24px; }
.service-card .service-name { flex: 1; min-width: 0; }

@media (min-width: 1000px) {
  .services-view { max-width: 640px; margin-inline: auto; }
}

/* the forms sub-app embedded in the shell (#/forms) — a framed panel that fills the
   viewport under the appbar; scrolling happens INSIDE the iframe . */
.forms-view { display: flex; flex-direction: column; }
.forms-embed {
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #101418; /* matches the panel's night ground — no flash while it boots */
  min-height: 60vh;
}
.forms-embed.light { background: #F4F5F7; }
.forms-frame {
  display: block;
  width: 100%;
  border: 0;
  height: calc(100dvh - 190px);
  min-height: 480px;
  opacity: 0;
  transition: opacity 0.25s;
}
.forms-embed.ready .forms-frame { opacity: 1; }
@media (min-width: 1000px) {
  .forms-view { max-width: 980px; margin-inline: auto; width: 100%; }
  .forms-frame { height: calc(100dvh - 150px); }
}

/* WhatsApp login steps */
.wa-login-steps {
  margin: 6px 0 0;
  padding-inline-start: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  color: var(--text-2);
}
.wa-login-steps li::marker { color: var(--glow); font-weight: 800; }


/* ── Shop cart (SHOP service) ─────────────────────────────────────────────── */

/* ── Product cards — merchandise-first: photo, name, price, one action ─────── */
.menu-item {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: transform 0.18s var(--ease-spring), border-color 0.18s;
}
.menu-item.clickable { cursor: pointer; }
@media (hover: hover) {
  .menu-item.clickable:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--glow) 45%, var(--line)); }
}
/* the photo is taken out of flow, so a tall or square upload can't stretch the 4:3 box
   (an aspect-ratio box otherwise grows to fit its content) – every card's photo is the same size */
.menu-item-visual { position: relative; aspect-ratio: 4 / 3; overflow: hidden; flex-shrink: 0; background: var(--surface-2); }
.menu-item-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  max-width: 100%;
  object-fit: cover;
  display: block;
}
.menu-item-mono {
  display: grid; place-items: center;
  font-size: clamp(34px, 6vw, 52px); font-weight: 800;
  color: color-mix(in srgb, var(--glow) 75%, var(--text));
  background:
    radial-gradient(120% 90% at 20% 0%, color-mix(in srgb, var(--glow) 22%, transparent), transparent 60%),
    var(--surface-2);
}
.menu-item.soldout { opacity: 0.55; filter: saturate(0.4); }
.menu-item.soldout .menu-item-photo { filter: grayscale(0.7); }
.menu-item-soldout {
  position: absolute; top: 8px; inset-inline-start: 8px;
  background: color-mix(in srgb, var(--text) 18%, transparent);
  color: var(--text);
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
  border-radius: 999px; padding: 3px 8px;
  backdrop-filter: blur(4px);
}
.menu-item-sale {
  position: absolute; top: 8px; inset-inline-start: 8px;
  background: var(--glow); color: var(--glow-ink);
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
  border-radius: 999px; padding: 3px 8px;
}
.menu-item-body { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px 12px; flex: 1; }
.menu-item-name { margin: 0; font-size: 14px; font-weight: 700; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.menu-item-desc {
  margin: 0;
  color: var(--text-2);
  font-size: 12px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.menu-item-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.menu-item-price { display: flex; align-items: baseline; gap: 6px; font-variant-numeric: tabular-nums; }
.menu-item-price .price-from { font-size: 11px; color: var(--text-2); }
.menu-item-price .price-now { font-weight: 800; font-size: 14.5px; }
.menu-item-price .price-old { font-size: 11.5px; color: var(--text-2); text-decoration: line-through; }
.menu-pick { font-size: 12px; font-weight: 700; color: var(--glow); white-space: nowrap; }
.menu-add {
  width: 32px; height: 32px; flex: none;
  border-radius: 50%; border: none;
  background: var(--glow); color: var(--glow-ink);
  font-size: 18px; line-height: 1; font-weight: 800; cursor: pointer;
  box-shadow: var(--shadow-glow);
  transition: transform 0.15s var(--ease-spring);
}
.menu-add:active { transform: scale(0.88); }
.menu-add:disabled { opacity: 0.6; }

/* ── Item page — the decide-and-add surface ─────────────────────────────────── */
.item-view { padding-bottom: 96px; /* room for the docked buy bar */ }
.item-back {
  border: none; background: none; color: var(--text-2);
  font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer;
  padding: 10px 0 4px;
}
.item-back:hover { color: var(--glow); }
.item-layout { display: flex; flex-direction: column; gap: 16px; }
.item-media { margin: 0 calc(-1 * var(--pad-page)); }
.item-hero {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block;
  animation: hero-in 0.4s var(--ease-spring) both;
}
.item-hero-mono {
  display: grid; place-items: center;
  font-size: 72px; font-weight: 800;
  color: color-mix(in srgb, var(--glow) 75%, var(--text));
  background:
    radial-gradient(130% 100% at 15% 0%, color-mix(in srgb, var(--glow) 24%, transparent), transparent 65%),
    var(--surface-2);
}
@keyframes hero-in {
  from { opacity: 0; transform: scale(1.02); }
  to { opacity: 1; transform: scale(1); }
}
.item-eyebrow {
  font-size: 11px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--glow);
}
.item-name { margin: 4px 0 0; font-size: clamp(22px, 5.4vw, 30px); font-weight: 800; line-height: 1.2; }
.item-price-row { display: flex; align-items: baseline; gap: 10px; margin-top: 8px; font-variant-numeric: tabular-nums; }
.item-price { font-size: 21px; font-weight: 800; }
.item-price-old { font-size: 14px; color: var(--text-2); text-decoration: line-through; }
.item-price-hint { font-size: 13.5px; color: var(--text-2); }
.item-attr { margin-top: 16px; }
.item-attr-name {
  font-size: 11px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-2); margin-bottom: 8px;
}
.item-attr-values { display: flex; flex-wrap: wrap; gap: 8px; }
.attr-chip {
  border: 1.5px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--text);
  font: inherit; font-size: 13.5px; font-weight: 600;
  padding: 8px 16px; cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.attr-chip.on {
  border-color: var(--glow);
  background: color-mix(in srgb, var(--glow) 14%, var(--surface));
  color: var(--glow);
}
.item-desc { margin: 16px 0 0; color: var(--text-2); font-size: 14px; line-height: 1.65; }
.item-note { display: block; margin-top: 18px; }

/* the buy bar — quantity, live total and the action fused into one capsule .
   docked to the thumb on phones; sits inline under the panel on wide screens . */
.buy-bar {
  position: fixed;
  bottom: calc(64px + env(safe-area-inset-bottom, 0px) + 10px);
  inset-inline: var(--pad-page);
  z-index: 30;
  display: flex; align-items: center; gap: 10px;
  background: color-mix(in srgb, var(--ink) 92%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  animation: bar-up 0.35s 0.1s var(--ease-spring) both;
}
@keyframes bar-up {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.buy-bar.disabled .buy-add { opacity: 0.6; }
.buy-qty {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 0 6px; flex: none;
}
.buy-qty button {
  width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 50%;
  background: var(--surface); color: var(--text);
  font-size: 17px; cursor: pointer;
}
.buy-qty span { min-width: 20px; text-align: center; font-weight: 800; font-size: 15px; }
.buy-add {
  flex: 1;
  border: none; border-radius: 999px;
  background: linear-gradient(135deg, var(--glow), var(--glow-deep));
  color: var(--glow-ink);
  font: inherit; font-size: 15px; font-weight: 800;
  padding: 13px 18px; cursor: pointer;
  box-shadow: var(--shadow-glow);
  font-variant-numeric: tabular-nums;
}
.buy-add:disabled { cursor: default; }

@media (min-width: 1000px) {
  .item-view { max-width: 980px; margin-inline: auto; padding-bottom: 24px; }
  .item-layout { flex-direction: row; align-items: flex-start; gap: 32px; }
  .item-media { flex: 1; margin: 0; position: sticky; top: 76px; }
  .item-hero { border-radius: var(--r-lg); }
  .item-panel { flex: 1; min-width: 0; }
  .buy-bar { position: sticky; bottom: 16px; margin-top: 22px; inset-inline: 0; }
}

/* per-line note inside the cart — a quiet full-width row under the line */
.cart-line { flex-wrap: wrap; }
.cart-line-note { flex-basis: 100%; margin-top: 6px; }
.cart-line-note input {
  width: 100%;
  border: none; border-bottom: 1px dashed var(--line);
  background: none; color: var(--text);
  font: inherit; font-size: 12.5px;
  padding: 4px 2px;
}
.cart-line-note input::placeholder { color: var(--text-2); opacity: 0.7; }
.cart-line-note input:focus { outline: none; border-bottom-color: var(--glow); }

@media (prefers-reduced-motion: reduce) {
  .item-hero, .buy-bar { animation: none; }
}

.nav-badge {
  display: inline-grid; place-items: center;
  min-width: 16px; height: 16px;
  padding: 0 4px;
  margin-inline-start: 4px;
  border-radius: 999px;
  background: var(--glow);
  color: var(--glow-ink);
  font-size: 10px; font-weight: 800;
  vertical-align: top;
}
.bottomnav-item .nav-ic { position: relative; }
.bottomnav-item .nav-badge { position: absolute; top: -4px; inset-inline-end: -10px; }

.cart-card { padding: 8px 14px; }
.cart-line {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
}
.cart-line:last-child { border-bottom: none; }
.cart-line.problem { opacity: 0.75; }
.cart-line-img {
  width: 44px; height: 44px; border-radius: var(--r-sm); object-fit: cover; background: var(--surface-2);
  flex-shrink: 0;
}
.cart-line-img.mono { display: grid; place-items: center; font-weight: 800; color: var(--text-2); }
.cart-line-body { flex: 1; min-width: 0; }
.cart-line-name { font-weight: 700; font-size: 14px; }
.cart-line-price { font-size: 12.5px; color: var(--text-2); }
.cart-line-total { font-weight: 700; font-size: 13.5px; min-width: 64px; text-align: end; }
.cart-stepper {
  display: inline-flex; align-items: center; gap: 8px;
  border: 1px solid var(--line); border-radius: 999px; padding: 3px 6px;
}
.cart-stepper button {
  width: 26px; height: 26px; border: none; border-radius: 50%;
  background: var(--surface-2); color: var(--text); font-size: 16px; cursor: pointer;
}
.cart-stepper span { min-width: 18px; text-align: center; font-weight: 700; font-size: 13.5px; }

.cart-flag { display: inline-block; font-size: 11.5px; font-weight: 700; border-radius: 999px; padding: 2px 8px; }
.cart-flag.warn { background: var(--amber-soft, rgba(255,180,84,0.15)); color: var(--glow); }
.cart-flag.danger { background: var(--rose-soft); color: var(--rose); }

.cart-types { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; }
.cart-type {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  border: 1.5px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); color: var(--text);
  padding: 12px 8px; cursor: pointer; font-weight: 700; font-size: 13px;
  transition: border-color 0.15s, background 0.15s;
}
.cart-type.active { border-color: var(--glow); background: color-mix(in srgb, var(--glow) 10%, var(--surface)); }
.cart-type .ct-ic { font-size: 20px; }
.cart-type .ct-fee { font-size: 11px; color: var(--text-2); font-weight: 600; }

.cart-summary {
  margin-top: 14px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 12px 16px; font-size: 13.5px;
}
.cart-summary > div { display: flex; justify-content: space-between; padding: 3px 0; color: var(--text-2); }
.cart-summary .grand { color: var(--text); font-weight: 800; font-size: 15px; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 8px; }

/* ── My orders (tracking) ── */
.order-ticket {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 14px 16px; margin-top: 12px; box-shadow: var(--shadow-card);
}
.order-ticket.cancelled { opacity: 0.65; }
.order-ticket-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.order-code { font-weight: 800; font-variant-numeric: tabular-nums; }
.order-type { font-size: 12.5px; color: var(--text-2); }
.order-status {
  margin-inline-start: auto; display: inline-flex; align-items: center; gap: 5px;
  font-size: 12px; font-weight: 700; border-radius: 999px; padding: 3px 10px;
  background: color-mix(in srgb, var(--glow) 14%, transparent); color: var(--glow);
}
.order-status.s-cancelled { background: var(--rose-soft); color: var(--rose); }
.order-status.s-done { background: var(--mint-soft); color: var(--mint); }
.order-ticket-lines { margin-top: 10px; font-size: 13px; }
.ot-line { display: flex; justify-content: space-between; padding: 2.5px 0; }
.ot-line.soft { color: var(--text-2); font-size: 12.5px; }
.ot-line.grand { font-weight: 800; border-top: 1px dashed var(--line); margin-top: 4px; padding-top: 6px; }
.order-dest { margin-top: 8px; font-size: 12.5px; color: var(--text-2); }
.order-timeline { margin-top: 12px; border-inline-start: 2px solid var(--line); padding-inline-start: 14px; display: flex; flex-direction: column; gap: 8px; }
.tl-step { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-2); position: relative; }
.tl-step.current { color: var(--text); font-weight: 700; }
.tl-step .tl-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); flex: none; }
.tl-step.current .tl-dot { background: var(--glow); }
.tl-ic { font-size: 15px; }
.tl-img { width: 18px; height: 18px; border-radius: 4px; object-fit: cover; }
.tl-time { margin-inline-start: auto; font-size: 11px; opacity: 0.7; }

@media (min-width: 1000px) {
  .cart-view, .orders-view { max-width: 640px; margin-inline: auto; }
}


/* ── Item sheet (the options popup) ────────────────────────────────────────── */
.item-sheet { display: flex; flex-direction: column; gap: 14px; }
.carousel { position: relative; margin: -4px -18px 0; }
.carousel-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-slide {
  flex: 0 0 100%;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  scroll-snap-align: center;
}
.carousel-mono {
  display: grid; place-items: center;
  aspect-ratio: 4 / 3;
  font-size: 64px; font-weight: 800;
  color: color-mix(in srgb, var(--glow) 75%, var(--text));
  background:
    radial-gradient(130% 100% at 15% 0%, color-mix(in srgb, var(--glow) 22%, transparent), transparent 65%),
    var(--surface-2);
}
.carousel-dots {
  position: absolute; bottom: 10px; inset-inline: 0;
  display: flex; justify-content: center; gap: 6px;
}
.carousel-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  transition: transform 0.2s, background 0.2s;
}
.carousel-dot.on { background: var(--glow); transform: scale(1.25); }

.item-sheet-price { display: flex; align-items: baseline; gap: 10px; font-variant-numeric: tabular-nums; }
.item-sheet-price .isp-now { font-size: 20px; font-weight: 800; }
.item-sheet-price .isp-old { font-size: 13.5px; color: var(--text-2); text-decoration: line-through; }
.item-sheet-price .isp-hint { font-size: 13px; color: var(--text-2); }
.soldout-flag {
  font-size: 11px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--rose); background: var(--rose-soft);
  border-radius: 999px; padding: 3px 9px;
}
.item-sheet-desc { margin: 0; color: var(--text-2); font-size: 13.5px; line-height: 1.6; }
.item-sheet .item-attr { margin-top: 2px; }
.attr-chip.off { opacity: 0.4; text-decoration: line-through; cursor: default; }
.item-sheet .item-note { margin-top: 2px; }

.item-sheet-bar {
  display: flex; align-items: center; gap: 10px;
  margin-top: 4px;
  position: sticky; bottom: 0;
  background: inherit;
  padding-top: 4px;
}
.item-attr.shake { animation: attr-shake 0.35s; }
@keyframes attr-shake {
  20% { transform: translateX(-4px); }
  45% { transform: translateX(4px); }
  70% { transform: translateX(-3px); }
  90% { transform: translateX(2px); }
}
@media (prefers-reduced-motion: reduce) { .item-attr.shake { animation: none; } }


/* ═══ Voice pass — the ticket face carries the commerce, icons are one hand ═══ */

/* the icon system (inline SVG, currentColor) */
.ic { display: inline-block; vertical-align: -0.18em; flex: none; }
.nav-ic .ic { vertical-align: middle; }
.bottomnav-item .nav-ic { display: inline-grid; place-items: center; height: 22px; }
.bottomnav-item.active .ic { stroke-width: 2.2; }
.row-ic .ic { vertical-align: middle; opacity: 0.9; }
.service-ic .ic, .ct-ic .ic { color: var(--glow); }
.join-ic { display: grid; place-items: center; color: var(--glow); }
.ms-ic .ic { opacity: 0.6; }
.order-type .ic, .order-dest .ic { vertical-align: -0.22em; opacity: 0.8; }

/* display voice: Bricolage carries titles, prices and everything money . */
.view-title,
.card-title,
.sheet-title {
  font-family: var(--font-ticket);
  letter-spacing: -0.015em;
}
.view-title { font-size: 26px; font-weight: 800; }

.price-now,
.menu-item-price,
.item-sheet-price,
.item-price-row,
.cart-line-price,
.cart-line-total,
.cart-summary,
.order-ticket-lines,
.order-code,
.buy-add,
.ct-fee {
  font-family: var(--font-ticket);
  font-variant-numeric: tabular-nums;
}

/* section headers in the menu read as aisle labels, not card titles */
.menu-cat-title {
  font-family: var(--font-ticket);
  letter-spacing: 0.01em;
}

/* ── the receipt: the storefront's signature object ─────────────────────────
   totals and orders share one physical language — perforated top edge, dashed
   rules, tabular figures — like the slip the store would actually hand you . */
.cart-summary.receipt,
.order-ticket {
  position: relative;
  border-radius: 4px 4px var(--r-lg) var(--r-lg);
  border-top: none;
  --perf: color-mix(in srgb, var(--ink) 100%, transparent);
}
.cart-summary.receipt::before,
.order-ticket::before {
  content: '';
  position: absolute;
  top: -5px; inset-inline: 0;
  height: 10px;
  background-image: radial-gradient(circle at 5px 5px, var(--ink) 4.5px, transparent 5px);
  background-size: 18px 10px;
  background-position: 0 0;
  background-repeat: repeat-x;
  filter: drop-shadow(0 1px 0 var(--line));
}
.cart-summary.receipt { padding-top: 18px; }
.cart-summary.receipt .grand,
.ot-line.grand {
  font-family: var(--font-ticket);
  font-weight: 800;
  font-size: 16px;
  border-top: 1.5px dashed var(--line);
}
.order-ticket { padding-top: 18px; }
.order-code { font-weight: 800; letter-spacing: 0.02em; }

/* buttons that sell speak the display voice */
.btn-glow, .buy-add, .menu-pick {
  font-family: var(--font-ticket);
  letter-spacing: 0.01em;
}

/* badges tighten up */
.menu-item-sale, .menu-item-soldout, .soldout-flag {
  font-family: var(--font-ticket);
  letter-spacing: 0.08em;
}


/* picked options on cart lines */
.cart-line-attrs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.line-attr {
  font-size: 11px; color: var(--text-2);
  border: 1px solid var(--line); border-radius: 999px; padding: 1.5px 8px;
}
.line-attr b { color: var(--text); font-weight: 700; }
.ot-attrs { color: var(--text-2); font-size: 11.5px; margin-inline-start: 4px; }
.ot-note { display: block; color: var(--text-2); font-size: 11.5px; font-style: italic; }

/* the floating basket */
.cart-fab {
  position: fixed;
  inset-inline-end: 16px;
  bottom: calc(76px + env(safe-area-inset-bottom, 0px));
  z-index: 45;
  width: 54px; height: 54px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, var(--glow), var(--glow-deep));
  color: var(--glow-ink);
  display: grid; place-items: center;
  box-shadow: var(--shadow-glow), 0 10px 26px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  animation: fab-in 0.3s var(--ease-spring) both;
}
@keyframes fab-in { from { opacity: 0; transform: scale(0.6); } to { opacity: 1; transform: scale(1); } }
.cart-fab:active { transform: scale(0.92); }
.cart-fab-count {
  position: absolute; top: -4px; inset-inline-end: -4px;
  min-width: 21px; height: 21px; padding: 0 5px;
  border-radius: 999px;
  background: var(--ink); color: var(--text);
  border: 1.5px solid var(--glow);
  font-family: var(--font-ticket); font-size: 11.5px; font-weight: 800;
  display: grid; place-items: center;
}
@media (min-width: 1000px) { .cart-fab { bottom: 24px; } }
@media (prefers-reduced-motion: reduce) { .cart-fab { animation: none; } }

/* ── cart: schedule / tip / table additions ─────────────────────────────────────────────── */
.cart-hint { font-size: 12px; opacity: .7; margin-top: 6px; }
.tip-row { align-items: center; }
.tip-row .tip-input { width: 120px; flex: 0 0 auto; }
.table-flag { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.link-btn { background: none; border: 0; color: inherit; text-decoration: underline; cursor: pointer; font: inherit; opacity: .8; }
.cart-type[disabled] { opacity: .45; cursor: not-allowed; }
