/* Hidden bars: wheel / finger always scroll. Thumb shows while scrolling or when the right edge is hovered. */
:root {
  --sb-size: 14px;
  --sb-thumb: transparent;
  --sb-thumb-on: rgba(91, 33, 182, 0.5);
}
html[data-theme="dark"] {
  --sb-thumb-on: rgba(196, 181, 253, 0.55);
}
html, body,
html:not(.is-plus),
html:not(.is-plus) body {
  height: auto !important;
  max-height: none !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch;
}
html:not(.is-plus) #app,
#app {
  height: auto !important;
  max-height: none !important;
  min-height: 100% !important;
  overflow: visible !important;
  -webkit-overflow-scrolling: touch;
}
@media (min-width: 900px) {
  html.has-side:not(.is-plus) .tabbar:not(.hidden) {
    position: fixed !important;
    left: 0 !important;
    top: 0 !important;
    bottom: 0 !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }
}

html, body, #app,
.pos-scroll, .floor-side, .menu, .bill-ticket, .g-nav, .g-main, .cart,
.nav-scroll, .nav-groups, .mod-g, .zones, .mcats, .seat-bar, .type-bar, .pos-top-r {
  scrollbar-width: thin;
  scrollbar-color: var(--sb-thumb) transparent;
}
html.is-scrolling,
html.is-scrolling *,
html.is-sb-on,
html.is-sb-on * {
  scrollbar-color: var(--sb-thumb-on) transparent;
}

*::-webkit-scrollbar {
  width: var(--sb-size);
  height: var(--sb-size);
}
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb {
  background: var(--sb-thumb);
  border-radius: 999px;
  border: 3px solid transparent;
  background-clip: padding-box;
  min-height: 48px;
}
html.is-scrolling *::-webkit-scrollbar-thumb,
html.is-sb-on *::-webkit-scrollbar-thumb {
  background-color: var(--sb-thumb-on);
  background-clip: padding-box;
}

html.gate-on #app,
html.gate-on .wrap { visibility: hidden; }
html.gate-on .gate-mask { visibility: visible; }

.theme-chip {
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.16);
  color: inherit;
  font-weight: 600;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
}

.gate-mask {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--brand, #5B21B6);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
html[data-theme="dark"] .gate-mask { background: #160b24; }
.gate-box {
  width: min(400px, 100%);
  background: #fff;
  color: #1a1228;
  border-radius: 20px;
  padding: 28px 24px;
  box-shadow: 0 18px 50px rgba(0,0,0,.28);
}
html[data-theme="dark"] .gate-box { background: #1c142c; color: #f4f0ff; }
.gate-box h1 { margin: 0 0 6px; font-size: 26px; color: var(--brand, #5B21B6); }
html[data-theme="dark"] .gate-box h1 { color: #c4b5fd; }
.gate-box p { margin: 0 0 16px; color: #6b5b8c; line-height: 1.5; }
html[data-theme="dark"] .gate-box p { color: #b4a8c9; }
.gate-box label { display: block; font-size: 13px; margin: 10px 0 4px; }
.gate-box input {
  width: 100%;
  border: 1px solid #d4c8ec;
  border-radius: 12px;
  padding: 12px 14px;
  font: inherit;
  min-height: 46px;
  box-sizing: border-box;
}
html[data-theme="dark"] .gate-box input { background: #12081f; color: #f4f0ff; border-color: #3f3358; }
.gate-box button {
  width: 100%;
  margin-top: 16px;
  border: 0;
  border-radius: 12px;
  padding: 14px;
  min-height: 48px;
  background: var(--brand, #5B21B6);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.gate-err { color: #b91c1c; font-size: 13px; min-height: 18px; margin-top: 8px; }

html { --type-scale: 1; }
.type-tools { display:inline-flex; align-items:center; gap:4px; margin-left:6px; }
.type-btn {
  border:0; border-radius:8px; min-width:32px; min-height:32px; padding:4px 8px;
  background:rgba(255,255,255,.18); color:inherit; font-weight:700; cursor:pointer; font-size:13px;
}
.type-lab { font-size:11px; min-width:36px; text-align:center; font-style:normal; opacity:.9; }
.back-chip {
  display:inline-flex; align-items:center; gap:4px; padding:6px 12px; min-height:36px;
  border-radius:999px; background:rgba(255,255,255,.16); color:inherit; font-weight:700;
  cursor:pointer; border:0; text-decoration:none; font-size:14px;
}
.ico-btn {
  display:inline-flex; flex-direction:column; align-items:center; justify-content:center;
  gap:2px; border:0; border-radius:12px; min-width:52px; min-height:44px; padding:4px 8px;
  background:#2a2040; color:#fff; cursor:pointer; font-size:11px; font-weight:600; line-height:1.15;
}
html[data-theme="light"] .ico-btn { background:#fff; color:#4c1d95; box-shadow:0 0 0 1px #d4c8ec; }
.ico-btn.on, .ico-btn.primary { background: var(--brand, #5B21B6); color:#fff; box-shadow:none; }
.ico-btn svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.ico-btn[disabled] { opacity:.35; cursor:default; }
.ico-btn:active { transform:scale(.96); }

body { font-size: calc(14px * var(--type-scale, 1)); }
.btn, .mini, .pkey, .dish, .more-tile { font-size: calc(14px * var(--type-scale, 1)); }
