:root {
  --surface: #f5ebd8;
  --surface-dim: #e6d7bf;
  --surface-bright: #fffdf8;
  --surface-low: #fbf5ec;
  --surface-mid: #efe1c8;
  --surface-high: #e0d4bc;
  --ink: #3b1f0e;
  --muted: #6b3a1f;
  --muted-2: #8a6a52;
  --outline: #e0d4bc;
  --outline-strong: #b98f68;
  --primary: #c94e22;
  --primary-hot: #d65e30;
  --primary-soft: #ffe5cc;
  --primary-dim: #fff3e6;
  --blue: #3b1f0e;
  --blue-soft: #f2dfc5;
  --teal: #2a8a4e;
  --teal-soft: #e1f2e7;
  --green: #2a8a4e;
  --green-soft: #e4f3e8;
  --amber: #d4860c;
  --amber-soft: #fff0cf;
  --red: #c92a2f;
  --red-soft: #ffe3dc;
  --purple: #7a3f1f;
  --purple-soft: #f5dcc9;
  --pink: #9e3a16;
  --pink-soft: #ffe2d4;
  --white: #fffdf8;
  --font-body: "Nunito", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-display: "Bebas Neue", "Nunito", sans-serif;
  --shadow: 0 10px 22px rgba(59, 31, 14, 0.07);
  --shadow-card: 0 4px 10px rgba(59, 31, 14, 0.055);
  --shadow-press: 0 2px 6px rgba(201, 78, 34, 0.12);
  --shadow-selected: inset 0 0 0 1px rgba(201, 78, 34, 0.16);
  --shadow-dropdown: 0 16px 34px rgba(59, 31, 14, 0.18);
  --radius: 14px;
  --touch: 48px;
  --desktop-canvas-width: 1366px;
  --desktop-scale: 1;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 700;
}

body {
  overflow-x: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
}

select {
  appearance: none;
  -webkit-appearance: none;
  min-height: 52px;
  padding: 0 42px 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background-color: var(--white);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--primary) 50%),
    linear-gradient(135deg, var(--primary) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-repeat: no-repeat;
  background-size: 6px 6px, 6px 6px;
  color: var(--ink);
  font-weight: 950;
  outline: 0;
}

select:hover,
select:focus {
  border-color: var(--outline-strong);
  box-shadow: var(--shadow-selected);
}

select option {
  color: var(--ink);
  background: var(--white);
  font-weight: 850;
}

button {
  min-height: var(--touch);
  border: 0;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

button:active {
  transform: scale(0.98);
}

.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 22px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
}

.app-shell {
  width: calc(100vw / var(--desktop-scale));
  min-width: var(--desktop-canvas-width);
  min-height: calc(100vh / var(--desktop-scale));
  zoom: var(--desktop-scale);
}

.layout {
  width: 100%;
  min-height: calc(100vh / var(--desktop-scale));
  min-width: var(--desktop-canvas-width);
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
  transition: grid-template-columns 0.52s cubic-bezier(0.16, 1, 0.3, 1);
}

.layout.nav-collapsed {
  grid-template-columns: 88px minmax(0, 1fr);
}

.side-nav {
  position: sticky;
  top: 0;
  height: calc(100vh / var(--desktop-scale));
  background: var(--ink);
  border-right: 1px solid rgba(255, 229, 204, 0.24);
  display: flex;
  flex-direction: column;
  padding: 24px 12px 16px;
  gap: 20px;
  z-index: 5;
  overflow: hidden;
  transition:
    padding 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    gap 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.34s ease;
}

.layout.nav-collapsed .side-nav {
  overflow: hidden;
}

.nav-collapse-btn {
  width: 30px;
  height: 30px;
  min-height: 30px;
  position: absolute;
  top: 33px;
  right: 16px;
  z-index: 2;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--surface-low);
  box-shadow: none;
  line-height: 1;
  transition:
    top 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    right 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    width 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    color 0.18s ease;
}

.nav-collapse-btn:hover {
  background: transparent;
  color: var(--white);
}

.nav-collapse-glyph {
  display: block;
  font-family: var(--font-body);
  font-size: 30px;
  font-weight: 900;
  line-height: 1;
  transform: translateY(-1px);
  transition:
    transform 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    font-size 0.52s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 48px 8px 10px;
  overflow: hidden;
  transition:
    gap 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    padding 0.52s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand > div:not(.brand-mark) {
  min-width: 0;
  max-width: 146px;
  opacity: 1;
  transform: translateX(0);
  transition:
    max-width 0.46s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.28s ease,
    transform 0.46s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--primary), var(--primary-hot));
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 26px;
  letter-spacing: 1px;
  box-shadow: 0 4px 10px rgba(201, 78, 34, 0.2);
  transition:
    width 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    border-radius 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.52s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand h1 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 23px;
  line-height: 26px;
  color: var(--surface-low);
  font-weight: 900;
}

.brand p {
  margin: 2px 0 0;
  color: #e6d7bf;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.nav-group,
.panel-actions,
.chip-row,
.status-row,
.keypad,
.quick-actions {
  display: flex;
}

.nav-group {
  flex-direction: column;
  gap: 8px;
}

.nav-item-wrap {
  position: relative;
  display: grid;
  gap: 0;
}

.nav-btn {
  width: 100%;
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  color: #f5ebd8;
  background: transparent;
  font-weight: 800;
  text-align: left;
  box-shadow: none;
  will-change: padding, gap;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    color 0.18s ease,
    padding 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    gap 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.52s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-btn:active,
.nav-sub-btn:active,
.nav-collapse-btn:active,
.nav-language-menu .language-trigger:active {
  transform: none;
}

.nav-btn > .material-symbols-outlined,
.nav-sub-btn > .material-symbols-outlined {
  flex: 0 0 24px;
  width: 24px;
  min-width: 24px;
}

.nav-menu-chevron {
  margin-left: auto;
  font-size: 20px;
  opacity: 0.8;
  transition:
    transform 0.28s ease,
    opacity 0.2s ease;
}

.nav-item-wrap.open .nav-menu-chevron {
  transform: rotate(180deg);
}

.nav-submenu {
  display: grid;
  gap: 6px;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0 0 0 18px;
  transform: translateY(-4px);
  transition:
    max-height 0.36s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.22s ease,
    transform 0.36s cubic-bezier(0.16, 1, 0.3, 1),
    padding-top 0.36s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-submenu.open {
  max-height: 98px;
  opacity: 1;
  padding-top: 6px;
  transform: translateY(0);
}

.nav-sub-btn {
  min-height: 36px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: #f5ebd8;
  box-shadow: none;
  font-size: 13px;
  font-weight: 900;
  text-align: left;
}

.nav-sub-btn .material-symbols-outlined {
  font-size: 18px;
}

.nav-sub-btn.active {
  border-color: rgba(255, 229, 204, 0.34);
  background: rgba(255, 247, 237, 0.13);
  color: var(--white);
}

.nav-btn span:not(.material-symbols-outlined),
.nav-sub-btn span:not(.material-symbols-outlined),
.nav-language-text,
.nav-footer .btn span:not(.material-symbols-outlined) {
  display: inline-block;
  max-width: 140px;
  opacity: 1;
  overflow: hidden;
  white-space: nowrap;
  transform: translateX(0);
  transition:
    max-width 0.46s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.28s ease,
    transform 0.46s cubic-bezier(0.16, 1, 0.3, 1);
}

.layout.nav-collapsed .side-nav {
  padding: 16px 10px;
}

.layout.nav-collapsed .brand {
  justify-content: center;
  padding: 0;
  gap: 0;
}

.layout.nav-collapsed .brand > div:not(.brand-mark),
.layout.nav-collapsed .nav-btn span:not(.material-symbols-outlined),
.layout.nav-collapsed .nav-sub-btn span:not(.material-symbols-outlined),
.layout.nav-collapsed .nav-language-text,
.layout.nav-collapsed .nav-footer .btn span:not(.material-symbols-outlined) {
  max-width: 0;
  opacity: 0;
  transform: translateX(-18px);
}

.layout.nav-collapsed .nav-collapse-btn {
  top: 32px;
  right: 4px;
  width: 24px;
  height: 24px;
  min-height: 24px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.layout.nav-collapsed .nav-collapse-glyph {
  font-size: 27px;
  transform: translateY(-2px);
}

.layout.nav-collapsed .nav-btn {
  justify-content: center;
  gap: 0;
  padding: 0;
  transform: none;
}

.layout.nav-collapsed .nav-menu-chevron {
  display: none;
}

.layout.nav-collapsed .nav-submenu {
  width: 100%;
  max-height: 0;
  position: static;
  padding: 0 0 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
}

.layout.nav-collapsed .nav-submenu.open {
  max-height: 92px;
  opacity: 1;
  padding: 6px 0 0;
  transform: translateY(0);
  pointer-events: auto;
}

.layout.nav-collapsed .nav-sub-btn {
  width: 100%;
  min-height: 38px;
  justify-content: center;
  gap: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.06);
}

.layout.nav-collapsed .nav-footer .btn {
  width: 100%;
  gap: 0;
  padding: 0;
}

.nav-btn:hover {
  background: rgba(255, 229, 204, 0.09);
  border-color: rgba(255, 229, 204, 0.1);
  color: var(--white);
}

.nav-btn.active {
  background: linear-gradient(180deg, rgba(255, 247, 237, 0.96), rgba(255, 228, 204, 0.9));
  border-color: rgba(255, 229, 204, 0.9);
  color: var(--ink);
  box-shadow: 0 3px 8px rgba(201, 78, 34, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.nav-footer {
  margin-top: auto;
  border-top: 1px solid rgba(255, 229, 204, 0.22);
  padding-top: 14px;
  display: grid;
  gap: 10px;
  transition:
    gap 0.34s cubic-bezier(0.2, 0.8, 0.2, 1),
    padding-top 0.34s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.nav-keyboard-toggle {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 0 13px;
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  color: var(--surface-low);
  box-shadow: none;
  font-weight: 950;
  transition:
    width 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    padding 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    gap 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease;
}

.nav-keyboard-toggle:hover,
.nav-keyboard-toggle.active {
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 229, 204, 0.26);
  color: var(--white);
}

.nav-keyboard-toggle.active {
  background: rgba(201, 78, 34, 0.24);
  border-color: rgba(255, 229, 204, 0.34);
}

.nav-keyboard-toggle:active {
  transform: none;
}

.nav-keyboard-label {
  max-width: 92px;
  overflow: hidden;
  white-space: nowrap;
  transition:
    max-width 0.46s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.28s ease,
    transform 0.46s cubic-bezier(0.16, 1, 0.3, 1);
}

.layout.nav-collapsed .nav-keyboard-toggle {
  width: 48px;
  min-width: 48px;
  margin: 0 auto;
  justify-content: center;
  gap: 0;
  padding: 0;
}

.layout.nav-collapsed .nav-keyboard-label {
  max-width: 0;
  opacity: 0;
  transform: translateX(-10px);
}

.nav-language-slot {
  width: 100%;
}

.nav-language-menu {
  width: 100%;
}

.nav-language-menu .language-trigger {
  width: 100%;
  min-width: 0;
  justify-content: flex-start;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: var(--surface-low);
  box-shadow: none;
  transition:
    width 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    min-width 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    padding 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    justify-content 0.52s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.18s ease,
    border-color 0.18s ease;
}

.nav-language-menu .language-trigger:hover,
.nav-language-menu.open .language-trigger {
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 229, 204, 0.26);
  color: var(--white);
}

.nav-language-flag {
  width: 24px;
  min-width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  place-items: center;
  font-size: 18px;
  line-height: 1;
  transform-origin: center;
  text-align: center;
}

.nav-language-text {
  max-width: 92px;
  color: inherit;
  font-size: 13px;
  line-height: 1;
  font-weight: 950;
}

.nav-language-menu .language-trigger .material-symbols-outlined {
  margin-left: auto;
  color: var(--surface-low);
  font-size: 18px;
}

.nav-language-menu .language-options {
  top: auto;
  right: auto;
  bottom: calc(100% + 8px);
  left: 0;
}

.layout.nav-collapsed .nav-language-menu .language-trigger {
  width: 48px;
  min-width: 48px;
  margin: 0 auto;
  padding: 0;
  gap: 0;
  justify-content: center;
}

.layout.nav-collapsed .nav-language-menu .nav-language-flag {
  margin: 0;
}

.layout.nav-collapsed .nav-language-menu .nav-language-text {
  max-width: 0;
  opacity: 0;
  transform: translateX(-10px);
}

.layout.nav-collapsed .nav-language-slot,
.layout.nav-collapsed .nav-language-menu {
  display: grid;
  justify-items: center;
}

.layout.nav-collapsed .nav-language-menu .language-trigger .material-symbols-outlined {
  width: 0;
  margin-left: 0;
  opacity: 0;
  overflow: hidden;
}

.layout.nav-collapsed .nav-language-menu .language-options {
  width: 56px;
  min-width: 56px;
  left: 50%;
  right: auto;
  justify-items: center;
  padding: 6px;
  transform: translateX(-50%);
}

.layout.nav-collapsed .nav-language-menu .language-option {
  width: 44px;
  min-width: 44px;
  min-height: 44px;
  justify-content: center;
  gap: 0;
  padding: 0;
}

.layout.nav-collapsed .nav-language-menu .language-option > span:not(.nav-language-flag),
.layout.nav-collapsed .nav-language-menu .language-option .material-symbols-outlined {
  display: none;
}

.store-card {
  border: 1px solid rgba(255, 229, 204, 0.2);
  border-radius: var(--radius);
  padding: 14px;
  max-height: 86px;
  background: rgba(255, 253, 248, 0.08);
  color: var(--surface-low);
  opacity: 1;
  overflow: hidden;
  transform: translateY(0);
  transition:
    max-height 0.3s cubic-bezier(0.2, 0.8, 0.2, 1),
    padding 0.3s cubic-bezier(0.2, 0.8, 0.2, 1),
    border-color 0.3s ease,
    opacity 0.2s ease,
    transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.layout.nav-collapsed .store-card {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-color: transparent;
  opacity: 0;
  transform: translateY(8px);
}

.store-card strong,
.store-card span {
  display: block;
}

.store-card strong {
  font-size: 15px;
}

.store-card span {
  margin-top: 3px;
  color: #e6d7bf;
  font-size: 13px;
}

.main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  min-height: 72px;
  padding: 14px 24px;
  background: rgba(251, 245, 236, 0.96);
  border-bottom: 1.5px solid var(--outline);
  position: sticky;
  top: 0;
  z-index: 4;
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar.compact {
  min-height: 64px;
  padding-block: 12px;
}

.top-title {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.top-title > div {
  display: grid;
  align-content: center;
}

.top-title h2 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 28px;
  line-height: 34px;
  font-weight: 900;
  letter-spacing: 0;
}

.top-title p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.profile-menu {
  position: relative;
  display: inline-flex;
}

.profile-trigger {
  color: var(--ink);
}

.profile-popover {
  width: 280px;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 40;
  display: none;
  padding: 10px;
  border: 1.5px solid var(--outline-strong);
  border-radius: 8px;
  background: var(--white);
  box-shadow: var(--shadow-dropdown);
}

.profile-menu.open .profile-popover {
  display: grid;
  gap: 8px;
}

.profile-identity {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 8px;
  border-bottom: 1px solid var(--outline);
}

.profile-avatar {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--primary);
  color: var(--white);
  font-size: 20px;
  font-weight: 900;
}

.profile-identity strong,
.profile-identity span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-identity strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 900;
}

.profile-identity span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.profile-row {
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.profile-row:hover {
  background: rgba(214, 83, 44, 0.1);
  color: var(--primary);
}

.profile-row.danger {
  color: #b42318;
}

.content {
  padding: 24px;
  display: grid;
  gap: 20px;
  align-content: start;
}

.main[data-module="menu"] {
  height: calc(100dvh / var(--desktop-scale));
  max-height: calc(100dvh / var(--desktop-scale));
  overflow: hidden;
}

.main[data-module="menu"] .content {
  flex: 1 1 0;
  min-height: 0;
  grid-template-rows: minmax(0, 1fr);
  align-content: stretch;
  overflow: hidden;
}

.main[data-module="menu"] .menu-management-layout {
  align-self: stretch;
}

.btn,
.icon-btn,
.segment-btn,
.pill,
.table-card,
.menu-card,
.bill-tab,
.payment-chip,
.scenario-btn,
.action-tile,
.ticket-card,
.reservation-card,
.inventory-row,
.order-row {
  transition:
    background-color 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease,
    transform 0.16s ease,
    opacity 0.16s ease;
}

.btn {
  min-height: var(--touch);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border-radius: var(--radius);
  background: var(--surface-mid);
  color: var(--ink);
  font-weight: 800;
  border: 1.5px solid transparent;
}

.btn.primary {
  background: linear-gradient(180deg, var(--primary-hot), var(--primary));
  color: var(--white);
  box-shadow: var(--shadow-press);
}

.btn.primary:hover {
  background: var(--primary-hot);
}

.btn.order-submit-btn {
  background: linear-gradient(180deg, #f0b53f, var(--amber));
  color: var(--ink);
  box-shadow: var(--shadow-press);
}

.btn.secondary {
  background: var(--white);
  border-color: var(--outline-strong);
  color: var(--ink);
}

.btn.danger {
  background: var(--red);
  color: var(--white);
}

.btn.warning {
  background: var(--amber-soft);
  color: var(--amber);
  border-color: #d4860c;
}

.btn.ghost {
  background: transparent;
  color: var(--muted);
}

.icon-btn {
  width: var(--touch);
  height: var(--touch);
  padding: 0;
  border-radius: var(--radius);
  background: var(--white);
  border: 1.5px solid var(--outline);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--blue);
}

.icon-btn:hover,
.btn.secondary:hover,
.pill:hover {
  background: var(--surface-low);
}

.language-switcher {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: var(--radius);
  background: var(--surface-mid);
  border: 1.5px solid var(--outline);
}

.language-btn {
  min-width: 46px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  font-weight: 900;
}

.language-btn.active {
  background: var(--white);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.language-menu {
  position: relative;
  z-index: 12;
}

.settings-language-control {
  display: flex;
  justify-content: flex-end;
}

.settings-language-control .language-menu {
  z-index: 20;
}

.language-trigger {
  min-width: 82px;
  height: var(--touch);
  min-height: var(--touch);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 10px;
  border-radius: var(--radius);
  background: var(--surface-mid);
  border: 1.5px solid var(--outline);
  color: var(--ink);
  font-weight: 900;
}

.language-trigger .material-symbols-outlined {
  color: var(--muted);
  font-size: 20px;
}

.language-code {
  font-size: 13px;
  line-height: 1;
}

.language-emoji-flag {
  width: 24px;
  min-width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
  text-align: center;
}

.language-trigger .language-emoji-flag {
  flex: 0 0 24px;
}

.language-menu.open .language-trigger,
.language-trigger:hover {
  background: var(--white);
  border-color: var(--outline-strong);
  box-shadow: var(--shadow-selected);
}

.language-options {
  width: 220px;
  max-height: 280px;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  display: none;
  gap: 6px;
  padding: 8px;
  overflow-y: auto;
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-dropdown);
}

.language-menu.open .language-options {
  display: grid;
}

.language-option {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 9px 10px;
  border: 1.5px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  font-weight: 900;
  text-align: left;
}

.language-option:hover,
.language-option.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.language-option .material-symbols-outlined {
  margin-left: auto;
  font-size: 20px;
}

.flag-icon {
  width: 28px;
  height: 20px;
  display: inline-block;
  position: relative;
  overflow: hidden;
  border-radius: 5px;
  border: 1px solid rgba(59, 31, 14, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.flag-cn {
  background: #de2910;
}

.flag-cn::before {
  content: "★";
  position: absolute;
  left: 4px;
  top: 1px;
  color: #ffde00;
  font-size: 10px;
  line-height: 1;
}

.flag-cn::after {
  content: "★";
  position: absolute;
  left: 14px;
  top: 2px;
  color: #ffde00;
  font-size: 4px;
  line-height: 1;
  text-shadow:
    4px 3px 0 #ffde00,
    4px 8px 0 #ffde00,
    0 11px 0 #ffde00;
  transform: rotate(18deg);
}

.flag-it {
  background: linear-gradient(90deg, #008c45 0 33.33%, #f4f5f0 33.33% 66.66%, #cd212a 66.66% 100%);
}

.sr-only {
  width: 1px;
  height: 1px;
  position: absolute;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.segment-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  font-weight: 800;
  white-space: nowrap;
}

.segment-btn.active {
  background: var(--white);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.panel {
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  min-width: 0;
  box-shadow: var(--shadow-card);
}

.panel-pad {
  padding: 18px;
}

.panel-head {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--outline);
}

.panel-head h3,
.panel-pad h3 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 21px;
  line-height: 26px;
}

.panel-head p,
.panel-pad p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.panel-title-inline {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.top-title .panel-title-inline {
  display: inline-flex;
}

.tiny-info-btn {
  width: 20px;
  height: 20px;
  min-height: 20px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.tiny-info-btn .material-symbols-outlined {
  font-size: 18px;
  line-height: 1;
}

.tiny-info-btn:hover,
.tiny-info-btn.active {
  background: transparent;
  color: var(--primary);
}

.mini-popover {
  width: 260px;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 30;
  padding: 10px 12px;
  border: 1.5px solid var(--outline-strong);
  border-radius: 12px;
  background: var(--white);
  color: var(--muted);
  box-shadow: var(--shadow);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.45;
}

.dish-catalog-popover {
  left: calc(100% - 30px);
}

.title-note-popover {
  display: none;
}

.title-note-inline.open .title-note-popover {
  display: block;
}

.metric {
  min-height: 150px;
  padding: 18px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.metric.no-note {
  min-height: 96px;
  justify-content: center;
}

.table-metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.table-metric-strip .metric,
.table-metric-strip .metric.no-note {
  min-height: 66px;
  padding: 10px 14px;
  border-radius: 14px;
  justify-content: center;
}

.table-metric-strip .metric .metric-label {
  font-size: 11px;
  line-height: 14px;
}

.table-metric-strip .metric .metric-value {
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 24px;
  line-height: 28px;
}

.metric .metric-label {
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
  text-transform: uppercase;
}

.metric .metric-value {
  margin-top: 12px;
  font-family: var(--font-body);
  font-size: 34px;
  line-height: 40px;
  font-weight: 800;
}

.metric .metric-note {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.metric.hot {
  border-color: #d4860c;
  background: linear-gradient(180deg, var(--amber-soft), var(--white));
}

.metric.good {
  border-color: #2a8a4e;
  background: linear-gradient(180deg, var(--green-soft), var(--white));
}

.metric.risk {
  border-color: #c92a2f;
  background: linear-gradient(180deg, var(--red-soft), var(--white));
}

.floor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  position: relative;
  align-items: start;
}

.floor-layout.drawer-open {
  grid-template-columns: minmax(0, 1fr) 480px;
}

.table-board-panel {
  min-height: calc(100vh - 128px);
  min-width: 0;
  overflow: hidden;
}

@media (min-width: 821px) {
  .floor-layout.drawer-open .table-board-panel {
    width: auto;
  }
}

.desktop-module-strip {
  display: block;
  gap: 12px;
  padding: 14px 14px 0;
}

.desktop-module-tabs {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.floor-layout.drawer-open .desktop-module-strip {
  display: block;
}

.floor-layout.drawer-open .desktop-module-tabs {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.desktop-module-btn {
  min-height: 68px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.desktop-module-btn .material-symbols-outlined {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--surface-low);
  color: var(--primary);
}

.desktop-module-btn strong,
.desktop-module-btn small {
  display: block;
}

.desktop-module-btn strong {
  font-size: 15px;
  line-height: 18px;
}

.desktop-module-btn small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 13px;
  font-weight: 850;
}

.desktop-module-btn.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  box-shadow: var(--shadow-selected);
}

.desktop-module-btn.active .material-symbols-outlined {
  background: var(--white);
}

.table-toolbar,
.bill-toolbar,
.table-summary,
.receipt-summary,
.split-grid,
.lane-head,
.calendar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.table-toolbar {
  padding: 14px;
  border-bottom: 1px solid var(--outline);
}

.floor-space-tabs {
  width: 100%;
  flex: 1 1 auto;
}

.floor-space-tab {
  flex: 0 1 134px;
  min-width: 112px;
}

.floor-space-tab.all {
  flex: 0 1 134px;
  min-width: 112px;
}

.floor-source-tabs {
  padding-right: 0;
}

.table-status-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(88px, 1fr));
  gap: 8px;
  padding: 12px 14px 0;
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-gutter: stable;
}

.status-filter {
  min-height: 54px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  text-align: left;
}

.status-filter span {
  min-width: 0;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}

.status-filter strong {
  min-width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 12px;
}

.status-filter.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.status-filter.active strong {
  background: var(--white);
  color: var(--primary);
}

.floor-layout.drawer-open .status-filter {
  min-height: 62px;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto;
  justify-items: center;
  align-content: center;
  gap: 4px;
  padding: 8px 10px;
  text-align: center;
}

.floor-layout.drawer-open .status-filter span {
  max-width: 100%;
  line-height: 17px;
  white-space: normal;
}

.floor-layout.drawer-open .status-filter strong {
  min-width: 30px;
  height: 26px;
}

.service-scope-note {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.table-count {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.pill-row,
.chip-row,
.bill-tabs,
.payment-chips,
.scenario-grid,
.doc-toggle,
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  min-height: 42px;
  padding: 0 14px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1.5px solid var(--outline);
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.pill.active {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--primary-dim);
  box-shadow: var(--shadow-selected);
}

.order-filter-row {
  align-items: center;
  padding: 0 2px;
}

.order-filter-pill {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.order-filter-pill em {
  min-width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 7px;
  border-radius: 999px;
  background: rgba(94, 55, 35, 0.08);
  color: var(--text);
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

.order-filter-pill.active em {
  background: var(--primary);
  color: var(--white);
}

.table-grid {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  align-items: flex-start;
  gap: 12px;
  padding: 18px;
}

.takeaway-create-card {
  flex: 0 0 96px;
  width: 96px;
  min-width: 96px;
  height: 112px;
  min-height: 112px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  padding: 12px;
  border: 1.5px dashed var(--primary);
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--primary);
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(201, 78, 34, 0.08);
}

.takeaway-create-card:hover {
  background: var(--primary-soft);
  transform: translateY(-1px);
}

.takeaway-create-card > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--primary);
  color: var(--white);
}

.takeaway-create-card strong,
.takeaway-create-card small {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.takeaway-create-card strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 950;
}

.takeaway-create-card small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.floor-bottom-controls {
  display: grid;
  gap: 12px;
  padding-bottom: 14px;
}

.table-operation-dock {
  margin: 0 14px;
  padding: 12px;
  display: grid;
  grid-template-columns: minmax(230px, 0.82fr) minmax(0, 1.8fr);
  gap: 12px;
  align-items: center;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.table-operation-dock strong,
.table-operation-dock span {
  display: block;
}

.table-operation-dock span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.table-op-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(78px, 1fr));
  gap: 8px;
}

.table-op-btn {
  min-height: 58px;
  display: grid;
  place-items: center;
  gap: 4px;
  padding: 8px 6px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  text-align: center;
}

.table-op-btn:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  background: var(--surface-low);
}

.table-op-btn:hover:not(:disabled) {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.table-op-btn .material-symbols-outlined {
  color: var(--primary);
}

.table-card {
  min-height: 112px;
  overflow: hidden;
  border: 2px solid var(--outline);
  background: var(--white);
  border-radius: var(--radius);
  padding: 12px;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.table-card:hover,
.table-card.active {
  border-color: var(--primary);
}

.table-card h4 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 26px;
  line-height: 30px;
}

.table-card small {
  color: var(--muted);
  font-weight: 800;
}

.table-card-status {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
}

.table-card-status .status-badge {
  flex: 0 1 auto;
  min-width: 0;
  padding-inline: 7px;
}

.table-due-amount {
  min-width: 0;
  max-width: 58px;
  min-height: 26px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1px;
  padding: 0 7px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--white);
  color: var(--primary);
  font-family: var(--font-body);
  font-size: 0;
  font-weight: 900;
  box-shadow: var(--shadow-selected);
  white-space: nowrap;
}

.table-due-amount .money-major {
  font-size: 12px;
  line-height: 1;
}

.table-due-amount .money-minor,
.table-due-amount .money-currency {
  font-size: 9px;
  line-height: 1;
}

.table-due-amount .money-currency {
  margin-left: 2px;
}

.table-card.free {
  background: #eaf7ee;
  border-color: #8fd0a2;
  color: #174c2f;
}

.table-card.dining {
  background: #fff0df;
  border-color: #de7436;
  color: #87330f;
}

.table-card.reserved {
  background: #fff7d8;
  border-color: #e3bd4b;
  color: #70480a;
}

.table-card.free small {
  color: #2d7548;
}

.table-card.dining small {
  color: #b24c1d;
}

.table-card.reserved small {
  color: #8d6813;
}

.table-card.cleaning {
  background: var(--red-soft);
  border-color: #c92a2f;
}

.table-card.offline {
  opacity: 0.55;
}

.table-admin-layout {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.table-admin-layout > .table-layout-panel {
  grid-column: 1 / -1;
}

.table-space-list {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.table-space-card {
  min-height: 70px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.table-space-card.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.table-space-card strong,
.table-space-card small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.table-space-card small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.table-space-editor {
  display: grid;
  gap: 12px;
  padding: 0 14px 14px;
}

.table-admin-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.table-admin-actions .btn {
  min-height: 42px;
  padding: 0 10px;
  font-size: 12px;
}

.managed-table-grid {
  display: grid;
  gap: 8px;
  padding: 14px;
  min-width: 0;
}

.managed-table-row {
  display: grid;
  grid-template-columns: minmax(110px, 1fr) minmax(120px, 1fr) 78px 112px 132px;
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.managed-table-row.header {
  min-height: 34px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.managed-table-row input,
.managed-table-row select,
.table-space-editor input {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background-color: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.managed-table-row select {
  padding-right: 42px;
}

.table-position-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.table-row-actions {
  display: grid;
  grid-template-columns: repeat(3, 40px);
  justify-content: end;
  gap: 6px;
}

.table-row-actions .icon-btn {
  width: 40px;
  height: 40px;
  min-height: 40px;
  border-radius: 12px;
}

.danger-icon {
  color: var(--red);
  border-color: rgba(201, 42, 47, 0.28);
  background: var(--red-soft);
}

.table-layout-preview {
  min-height: 360px;
  display: grid;
  grid-template-columns: repeat(8, minmax(90px, 1fr));
  grid-auto-rows: 82px;
  gap: 10px;
  padding: 14px;
  overflow: auto;
  background: linear-gradient(90deg, rgba(224, 212, 188, 0.26) 1px, transparent 1px),
    linear-gradient(rgba(224, 212, 188, 0.26) 1px, transparent 1px);
  background-size: 92px 82px;
}

.layout-table-chip {
  min-width: 86px;
  min-height: 72px;
  display: grid;
  place-items: center;
  gap: 2px;
  padding: 8px;
  border: 2px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
}

.layout-table-chip strong {
  font-family: var(--font-body);
  font-size: 19px;
  line-height: 22px;
}

.layout-table-chip span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
}

.layout-table-chip.free {
  background: #eaf7ee;
  border-color: #8fd0a2;
}

.layout-table-chip.dining {
  background: #fff0df;
  border-color: #de7436;
}

.layout-table-chip.reserved {
  background: #fff7d8;
  border-color: #e3bd4b;
}

.layout-table-chip.cleaning {
  background: var(--red-soft);
  border-color: var(--red);
}

.table-admin-workbench {
  display: grid;
  gap: 0;
}

.table-admin-summary {
  min-height: 74px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  margin-bottom: 12px;
  border: 1.5px solid var(--outline);
  border-radius: 16px;
  background: rgba(255, 252, 247, 0.88);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

.table-admin-summary > div {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 12px 16px;
}

.table-admin-summary > div + div {
  border-left: 1px solid rgba(116, 88, 60, 0.14);
}

.table-admin-summary span,
.table-admin-summary small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
}

.table-admin-summary strong {
  color: var(--ink);
  font-size: 24px;
  line-height: 1;
  font-weight: 950;
}

.table-admin-summary small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.table-space-tabs-head {
  flex: 0 0 auto;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 12px 14px;
  background: transparent;
}

.table-space-tabs {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 0;
  overflow: visible;
}

.table-space-tab {
  position: relative;
  flex: 0 1 134px;
  min-width: 112px;
  min-height: 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1.5px solid var(--space-border, var(--outline));
  border-radius: 14px;
  background: linear-gradient(180deg, var(--space-bg-strong, var(--space-bg, var(--white))) 0%, var(--space-bg, rgba(255, 255, 255, 0.94)) 100%);
  color: var(--space-color-dark, var(--ink));
  text-align: left;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.table-space-tab.active {
  border-color: var(--space-color, var(--primary));
  background: linear-gradient(180deg, var(--space-color, #dd5a2b) 0%, var(--space-color-dark, var(--primary)) 100%);
  color: var(--white);
  box-shadow: 0 10px 20px var(--space-shadow, rgba(201, 78, 34, 0.22));
}

.table-space-tab strong,
.table-space-tab span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.table-space-tab strong {
  font-size: 15px;
  line-height: 18px;
  font-weight: 950;
}

.table-space-tab span {
  color: var(--space-color-dark, var(--muted));
  font-size: 11px;
  font-weight: 900;
  text-align: right;
  opacity: 0.72;
}

.table-space-tab.active span {
  color: rgba(255, 255, 255, 0.86);
  opacity: 1;
}

.table-space-tool {
  width: 48px;
  height: 48px;
  min-width: 48px;
  display: inline-grid;
  place-items: center;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--white);
  color: var(--ink);
}

.table-space-tool:hover,
.table-space-tool.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.table-space-summary-card {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid var(--outline);
  border-radius: 14px;
  background: rgba(255, 250, 242, 0.78);
}

.table-space-summary-card span,
.table-space-summary-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.table-space-summary-card strong {
  color: var(--ink);
  font-size: 22px;
  line-height: 1.1;
}

.table-edit-toggle {
  flex: 0 0 auto;
}

.table-edit-toggle.active {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-dim);
}

.table-edit-controls {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  max-width: min(100%, 560px);
}

.table-edit-controls .btn {
  white-space: nowrap;
}

.btn.compact {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 14px;
}

.table-layout-editor {
  --table-editor-top: 94px;
  --table-editor-height: calc(100dvh - var(--table-editor-top) - 18px);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  transition:
    grid-template-columns 220ms cubic-bezier(0.2, 0.8, 0.2, 1),
    gap 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.table-layout-panel {
  height: var(--table-editor-height);
  max-height: var(--table-editor-height);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius);
}

.table-layout-editor.inspector-open {
  grid-template-columns: minmax(0, 1fr) 360px;
}

.table-layout-editor.inspector-open.inspector-closing {
  grid-template-columns: minmax(0, 1fr) 0;
  gap: 0;
}

.table-layout-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.table-layout-actions .btn {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  white-space: nowrap;
}

.table-layout-preview.visual-editor {
  --layout-pad: 20px;
  --layout-origin-x: max(0px, calc((100% - var(--layout-width, 832px)) / 2 - var(--layout-pad)));
  --layout-origin-y: max(0px, calc((100% - var(--layout-height, 416px)) / 2 - var(--layout-pad)));
  --layout-scale: 1;
  --layout-scaled-width: var(--layout-width, 832px);
  --layout-scaled-height: var(--layout-height, 416px);
  --layout-scaled-step: var(--layout-step, 208px);
  flex: 1 1 auto;
  min-height: 0;
  position: relative;
  display: block;
  padding: var(--layout-pad);
  overflow: auto;
  scroll-behavior: smooth;
  border-top: 1px solid rgba(116, 88, 60, 0.12);
  border-radius: 0 0 calc(var(--radius) - 1px) calc(var(--radius) - 1px);
  background-position:
    calc(var(--layout-pad) + var(--layout-origin-x))
    calc(var(--layout-pad) + var(--layout-origin-y));
  background-size: var(--layout-scaled-step, var(--layout-step, 208px)) var(--layout-scaled-step, var(--layout-step, 208px));
}

.table-layout-editor.edit-mode .table-layout-preview.visual-editor {
  --layout-origin-x: 0px;
}

.table-layout-preview.visual-editor::after {
  content: "";
  display: block;
  width: max(100%, calc(var(--layout-origin-x) + var(--layout-scaled-width, var(--layout-width, 832px))));
  height: max(320px, calc(var(--layout-origin-y) + var(--layout-scaled-height, var(--layout-height, 416px))));
  pointer-events: none;
}

.table-layout-stage {
  position: absolute;
  left: calc(var(--layout-pad) + var(--layout-origin-x));
  top: calc(var(--layout-pad) + var(--layout-origin-y));
  width: var(--layout-width, 832px);
  height: var(--layout-height, 416px);
  transform: scale(var(--layout-scale, 1));
  transform-origin: top left;
  transition:
    left 240ms cubic-bezier(0.2, 0.8, 0.2, 1),
    top 240ms cubic-bezier(0.2, 0.8, 0.2, 1),
    transform 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.table-layout-preview.visual-editor .table-empty-note {
  grid-column: 1 / -1;
  align-self: start;
}

.layout-table-chip.table-visual {
  display: grid;
  place-items: center;
  position: absolute;
  left: calc(var(--layout-pad) + var(--layout-origin-x) + var(--table-x, 0px));
  top: calc(var(--layout-pad) + var(--layout-origin-y) + var(--table-y, 0px));
  width: var(--table-width, 112px);
  min-width: var(--table-width, 112px);
  height: 104px;
  min-height: 104px;
  padding: 12px 14px;
  border: 1.5px solid rgba(116, 88, 60, 0.28);
  border-radius: 16px;
  background: rgba(255, 252, 247, 0.92);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.72);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
  touch-action: none;
}

.layout-table-chip.table-visual.editable {
  cursor: grab;
}

.table-layout-preview.visual-editor.drag-active,
.layout-table-chip.table-visual.editable.drag-armed,
.layout-table-chip.table-visual.editable.is-dragging {
  cursor: grabbing;
}

.layout-table-chip.table-visual.is-dragging {
  z-index: 20;
  opacity: 0.92;
  pointer-events: none;
  box-shadow: 0 18px 38px rgba(78, 37, 16, 0.22), 0 0 0 2px var(--space-soft, rgba(201, 78, 34, 0.18));
  transition: none;
}

.layout-table-chip.table-visual.shape-2,
.layout-table-chip.table-visual.shape-4,
.layout-table-chip.table-visual.shape-6,
.layout-table-chip.table-visual.shape-dynamic {
  width: var(--table-width, 112px);
  min-width: var(--table-width, 112px);
  height: 104px;
  min-height: 104px;
}

.layout-table-chip.table-visual:hover,
.layout-table-chip.table-visual.active {
  border-color: var(--primary);
  box-shadow: 0 10px 22px rgba(105, 51, 24, 0.14), inset 0 0 0 1px rgba(255, 255, 255, 0.82);
  transform: translateY(-1px);
}

.layout-table-chip.table-visual.active {
  border-width: calc(3px / var(--desktop-scale));
  box-shadow: 0 12px 26px rgba(105, 51, 24, 0.16), 0 0 0 2px rgba(201, 78, 34, 0.22);
}

.table-add-slot {
  position: absolute;
  left: calc(var(--layout-pad) + var(--layout-origin-x) + var(--slot-x, 0px));
  top: calc(var(--layout-pad) + var(--layout-origin-y) + var(--slot-y, 0px));
  width: 36px;
  height: 36px;
  min-height: 36px;
  display: inline-grid;
  place-items: center;
  border: 1.5px solid rgba(201, 78, 34, 0.62);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.94);
  color: var(--primary);
  box-shadow: none;
  transition:
    background 140ms ease,
    color 140ms ease,
    border-color 140ms ease,
    transform 140ms ease;
}

.table-add-slot:hover,
.table-add-slot:active,
.table-add-slot.drop-target {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
  transform: scale(1.04);
}

.table-add-slot.drop-target {
  box-shadow: 0 0 0 7px rgba(201, 78, 34, 0.12);
}

.table-add-slot .material-symbols-outlined {
  font-size: 20px;
}

.table-layout-stage .layout-table-chip.table-visual {
  left: var(--table-x, 0px);
  top: var(--table-y, 0px);
}

.table-layout-stage .table-add-slot {
  left: var(--slot-x, 0px);
  top: var(--slot-y, 0px);
}

.table-guest-dot {
  position: absolute;
  z-index: 1;
  border-radius: 999px;
  background: rgba(116, 88, 60, 0.46);
  box-shadow: none;
}

.dot-top-1 {
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
}

.dot-bottom-1 {
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
}

.dot-left-1 {
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.dot-right-1 {
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.dot-top-a {
  top: 8px;
  left: calc(50% - 18px);
}

.dot-top-b {
  top: 8px;
  left: calc(50% + 8px);
}

.dot-bottom-a {
  bottom: 8px;
  left: calc(50% - 18px);
}

.dot-bottom-b {
  bottom: 8px;
  left: calc(50% + 8px);
}

.table-visual-body {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 1px;
  width: calc(var(--table-width, 112px) - 28px);
  min-width: 52px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.shape-2 .table-visual-body,
.shape-4 .table-visual-body,
.shape-6 .table-visual-body {
  height: auto;
  aspect-ratio: auto;
}

.layout-table-chip.table-visual.free .table-visual-body {
  color: #174c2f;
}

.layout-table-chip.table-visual.dining .table-visual-body {
  color: #87330f;
}

.layout-table-chip.table-visual.reserved .table-visual-body {
  color: #70480a;
}

.layout-table-chip.table-visual.cleaning .table-visual-body {
  color: var(--red);
}

.layout-table-chip.table-visual.free {
  background: #eaf7ee;
  border-color: #8fd0a2;
}

.layout-table-chip.table-visual.dining {
  background: #fff0df;
  border-color: #de7436;
}

.layout-table-chip.table-visual.reserved {
  background: #fff7d8;
  border-color: #e3bd4b;
}

.layout-table-chip.table-visual.cleaning {
  background: var(--red-soft);
  border-color: rgba(201, 42, 47, 0.52);
}

.layout-table-chip.table-visual.free .table-guest-dot {
  background: rgba(31, 122, 67, 0.42);
}

.layout-table-chip.table-visual.dining .table-guest-dot {
  background: rgba(163, 61, 18, 0.42);
}

.layout-table-chip.table-visual.reserved .table-guest-dot {
  background: rgba(138, 92, 0, 0.42);
}

.layout-table-chip.table-visual.cleaning .table-guest-dot {
  background: rgba(201, 42, 47, 0.42);
}

.table-status-dot {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  border: 2px solid rgba(255, 252, 247, 0.95);
  background: #9ca3af;
  box-shadow: 0 0 0 1px rgba(78, 37, 16, 0.12), 0 3px 8px rgba(78, 37, 16, 0.16);
  pointer-events: none;
}

.table-status-dot.status-free {
  background: #22c55e;
}

.table-status-dot.status-dining {
  background: #f97316;
}

.table-status-dot.status-reserved {
  background: #facc15;
}

.table-status-dot.status-cleaning {
  background: #ef4444;
}

.table-status-dot.status-offline,
.table-status-dot.status-unknown {
  background: #9ca3af;
}

.layout-table-chip.table-visual.space-colored {
  border-color: var(--space-border, rgba(116, 88, 60, 0.28));
  background:
    linear-gradient(180deg, var(--space-bg-strong, rgba(255, 252, 247, 0.92)) 0%, var(--space-bg, rgba(255, 255, 255, 0.82)) 100%);
  color: var(--space-color-dark, var(--ink));
}

.layout-table-chip.table-visual.space-colored:hover,
.layout-table-chip.table-visual.space-colored.active {
  border-color: var(--space-color, var(--primary));
  box-shadow: 0 12px 26px var(--space-shadow, rgba(105, 51, 24, 0.16)), 0 0 0 2px var(--space-soft, rgba(201, 78, 34, 0.16));
}

.layout-table-chip.table-visual.space-colored .table-guest-dot {
  background: var(--space-color, rgba(116, 88, 60, 0.46));
  opacity: 0.72;
}

.layout-table-chip.table-visual.space-colored .table-visual-body,
.layout-table-chip.table-visual.space-colored.free .table-visual-body,
.layout-table-chip.table-visual.space-colored.dining .table-visual-body,
.layout-table-chip.table-visual.space-colored.reserved .table-visual-body,
.layout-table-chip.table-visual.space-colored.cleaning .table-visual-body {
  color: var(--space-color-dark, var(--ink));
}

.layout-table-chip.table-visual strong {
  max-width: 100%;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 17px;
  font-weight: 950;
}

.layout-table-chip.table-visual small {
  color: var(--muted);
  font-size: 10px;
  line-height: 11px;
  font-weight: 950;
  white-space: nowrap;
}

.layout-table-chip.table-visual .seat-count.hot {
  color: var(--red);
  font-weight: 950;
}

.table-grid .layout-table-chip.table-visual.floor-table-visual {
  position: relative;
  left: auto;
  top: auto;
  flex: 0 0 var(--table-width, 112px);
  width: var(--table-width, 112px);
  min-width: var(--table-width, 112px);
  height: 112px;
  min-height: 112px;
  padding: 14px;
  overflow: hidden;
  cursor: pointer;
  touch-action: manipulation;
}

.table-grid .layout-table-chip.table-visual.floor-table-visual:hover,
.table-grid .layout-table-chip.table-visual.floor-table-visual.active {
  transform: translateY(-1px);
}

.floor-table-meta {
  position: absolute;
  top: 12px;
  left: 14px;
  right: 30px;
  z-index: 3;
  overflow: hidden;
  color: var(--space-color-dark, var(--muted));
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.floor-table-status-band {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 4;
  min-height: 24px;
  display: grid;
  place-items: center;
  padding: 0 10px;
  overflow: hidden;
  border-radius: calc(var(--radius) - 2px) calc(var(--radius) - 2px) 0 0;
  background: rgba(255, 253, 248, 0.74);
  color: var(--ink);
  font-size: 11px;
  font-weight: 950;
  line-height: 24px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  box-shadow: inset 0 -1px 0 rgba(116, 88, 60, 0.1);
}

.floor-table-status-band.free {
  background: rgba(228, 243, 232, 0.92);
  color: #174c2f;
}

.floor-table-status-band.dining {
  background: rgba(255, 229, 204, 0.94);
  color: #87330f;
}

.floor-table-status-band.reserved {
  background: rgba(255, 240, 207, 0.95);
  color: #70480a;
}

.floor-table-status-band.cleaning,
.floor-table-status-band.offline {
  background: rgba(255, 227, 220, 0.95);
  color: var(--red);
}

.floor-table-visual-body {
  margin-top: 16px;
  gap: 3px;
}

.layout-table-chip.table-visual .floor-table-occupancy {
  min-width: 34px;
  display: inline-grid;
  place-items: center;
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.72);
  color: var(--space-color-dark, var(--ink));
  font-size: 12px;
  font-weight: 950;
  line-height: 17px;
  box-shadow: inset 0 0 0 1px rgba(116, 88, 60, 0.14);
}

.floor-table-badges {
  position: absolute;
  right: 12px;
  bottom: 11px;
  left: 12px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 0;
}

.floor-table-badges .status-badge {
  flex: 0 1 auto;
  min-width: 0;
  min-height: 24px;
  padding: 0 7px;
  overflow: hidden;
  font-size: 11px;
  line-height: 24px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.floor-table-badges .table-due-amount {
  max-width: 58px;
  min-height: 24px;
  padding-inline: 7px;
  box-shadow: 0 2px 8px rgba(78, 37, 16, 0.08);
}

.floor-table-badges .table-due-amount .money-major {
  font-size: 11px;
}

.floor-table-badges .table-due-amount .money-minor,
.floor-table-badges .table-due-amount .money-currency {
  font-size: 8px;
}

.table-space-dialog-scrim {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(59, 31, 14, 0.22);
  backdrop-filter: blur(7px);
}

.table-space-dialog {
  width: min(560px, 100%);
  display: grid;
  gap: 14px;
  padding: 20px;
  border: 1.5px solid var(--outline);
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow-dropdown);
}

.table-space-dialog .dialog-head {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 2px 0 6px;
}

.table-space-dialog h3 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
  line-height: 28px;
}

.table-space-dialog p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.table-space-dialog-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.table-space-dialog .field {
  gap: 7px;
}

.table-space-dialog .table-count-field {
  grid-column: 1 / -1;
}

.table-space-dialog .field small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.table-space-dialog input {
  width: 100%;
  min-height: 52px;
  padding: 0 14px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 950;
}

.color-field {
  grid-column: 1 / -1;
}

.space-color-control {
  min-height: 52px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border: 1.5px solid var(--space-border, var(--outline));
  border-radius: 14px;
  background: linear-gradient(180deg, var(--space-bg-strong, var(--paper)) 0%, var(--space-bg, var(--paper)) 100%);
}

.space-color-preview {
  width: 28px;
  height: 28px;
  border-radius: 10px;
  background: var(--space-color, var(--primary));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.58);
}

.space-color-control input[type="color"] {
  min-width: 0;
  width: 100%;
  min-height: 36px;
  height: 36px;
  padding: 2px;
  border: 1px solid var(--space-border, var(--outline));
  border-radius: 10px;
  background: var(--white);
}

.space-color-control strong {
  color: var(--space-color-dark, var(--ink));
  font-size: 13px;
  font-weight: 950;
  white-space: nowrap;
}

.space-color-palette {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.space-color-dot {
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  border: 1.5px solid rgba(116, 88, 60, 0.18);
  border-radius: 999px;
  background: var(--swatch);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42);
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.space-color-dot:hover:not(:disabled),
.space-color-dot.active {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(59, 31, 14, 0.12);
  transform: translateY(-1px);
}

.space-color-dot.unavailable {
  cursor: not-allowed;
  opacity: 0.28;
  filter: grayscale(0.4);
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.table-transfer-options {
  display: grid;
  gap: 8px;
}

.table-transfer-choice {
  min-height: 58px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  text-align: left;
}

.table-transfer-choice strong,
.table-transfer-choice span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.table-transfer-choice strong {
  font-size: 14px;
  font-weight: 950;
}

.table-transfer-choice span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.table-transfer-choice.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.table-inspector-panel {
  --table-inspector-top: var(--table-editor-top, 94px);
  position: sticky;
  top: var(--table-inspector-top);
  width: 360px;
  max-width: 360px;
  height: var(--table-editor-height, calc(100dvh - var(--table-inspector-top) - 18px));
  max-height: var(--table-editor-height, calc(100dvh - var(--table-inspector-top) - 18px));
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.table-inspector-panel.entering {
  animation: table-inspector-slide-in 220ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.table-inspector-panel.closing {
  pointer-events: none;
  animation: table-inspector-slide-out 220ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes table-inspector-slide-in {
  from {
    opacity: 0;
    transform: translateX(28px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes table-inspector-slide-out {
  from {
    opacity: 1;
    transform: translateX(0);
  }

  to {
    opacity: 0;
    transform: translateX(28px);
  }
}

.table-inspector-grid {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-top: 1px solid var(--outline);
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.table-order-inspector {
  display: grid;
  align-content: start;
  align-items: start;
  grid-auto-rows: max-content;
  gap: 12px;
  padding: 14px;
  border-top: 1px solid var(--outline);
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.table-inspector-panel > .table-inspector-grid,
.table-inspector-panel > .table-order-inspector {
  flex: 1;
}

.table-inspector-panel > .panel-head {
  flex: 0 0 auto;
}

.table-order-status-card {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  padding: 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.table-order-status-card strong,
.table-order-status-card span {
  display: block;
}

.table-order-status-card strong {
  font-size: 30px;
  line-height: 1;
}

.table-order-status-card div > span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.table-order-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.table-order-summary div {
  min-width: 0;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.table-order-summary strong,
.table-order-summary span {
  display: block;
}

.table-order-summary strong {
  font-size: 18px;
  line-height: 22px;
}

.table-order-summary span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.table-order-section {
  display: grid;
  align-content: start;
  align-items: start;
  gap: 8px;
}

.table-order-section h4 {
  margin: 4px 0 0;
  font-size: 16px;
  line-height: 20px;
}

.table-order-card,
.table-order-record {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.table-order-card {
  padding: 12px;
}

.table-order-card-head,
.table-order-record,
.table-order-line,
.table-order-money {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.table-order-card-head strong,
.table-order-record strong {
  display: block;
}

.table-order-card-head span:not(.order-status),
.table-order-record small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.table-order-money {
  margin-top: 10px;
  padding: 9px 0;
  border-top: 1px solid var(--outline);
  border-bottom: 1px solid var(--outline);
}

.table-order-money span {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.table-order-money strong {
  color: var(--ink);
  font-size: 14px;
}

.table-order-lines {
  display: grid;
  gap: 7px;
  margin-top: 10px;
}

.table-order-line span:first-child {
  min-width: 0;
  font-weight: 900;
}

.table-order-line em {
  color: var(--muted);
  font-style: normal;
  font-weight: 850;
}

.table-order-record {
  padding: 10px 12px;
}

.table-order-record > span:last-child {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.empty-note.compact {
  padding: 12px;
  min-height: 0;
}

.table-inspector-grid input,
.table-inspector-grid select {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background-color: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.table-inspector-grid select {
  padding-right: 42px;
}

.seat-stepper {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 48px;
  gap: 8px;
  align-items: center;
}

.seat-stepper input {
  min-height: 48px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--white);
  text-align: center;
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 900;
}

.stepper-btn {
  width: 48px;
  height: 48px;
  min-height: 48px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--surface-low);
  color: var(--ink);
  display: grid;
  place-items: center;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.82) inset;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.stepper-btn:hover {
  background: var(--primary-dim);
  border-color: var(--primary);
  color: var(--primary);
}

.stepper-btn:active {
  transform: translateY(1px);
}

.stepper-btn .material-symbols-outlined {
  font-size: 20px;
  line-height: 1;
}

.compact-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.compact-actions.single-action {
  grid-template-columns: minmax(0, 1fr);
}

.compact-actions .btn {
  min-width: 0;
}

.btn:disabled,
.icon-btn:disabled {
  opacity: 0.46;
  pointer-events: none;
}

.status-badge,
.doc-badge,
.line-status,
.severity {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 8px;
  border-radius: var(--radius);
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.status-badge.free {
  background: var(--teal-soft);
  color: var(--teal);
}

.status-badge.dining {
  background: var(--primary-soft);
  color: var(--primary);
}

.status-badge.reserved {
  background: #fff0bf;
  color: #8a5c00;
}

.status-badge.cleaning,
.status-badge.error {
  background: var(--red-soft);
  color: var(--red);
}

.status-badge.offline {
  background: var(--surface-high);
  color: var(--muted);
}

.table-detail {
  display: grid;
  gap: 14px;
}

.table-drawer {
  width: auto;
  min-width: 0;
  height: calc((100vh / var(--desktop-scale)) - 120px);
  max-height: calc((100vh / var(--desktop-scale)) - 120px);
  position: sticky;
  top: 96px;
  z-index: 3;
  display: flex;
  flex-direction: column;
  background: var(--surface-low);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  opacity: 1;
  animation: drawer-in 0.2s ease-out both;
  overflow: hidden;
}

.table-drawer-stable {
  animation: none;
}

.drawer-head {
  min-height: 102px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  align-items: start;
  gap: 16px;
  padding: 16px 18px 14px;
  border-bottom: 1.5px solid var(--outline);
  background: var(--white);
}

.drawer-title {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.drawer-title-row {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.drawer-head h2 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 32px;
  line-height: 1;
  letter-spacing: 0;
}

.drawer-head p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
  line-height: 1.38;
}

.drawer-head .icon-btn {
  align-self: start;
  justify-self: end;
}

.drawer-kicker {
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1;
}

.table-drawer-scroll {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-auto-rows: max-content;
  align-content: start;
  gap: 12px;
  overflow-y: auto;
  padding: 0 14px 16px;
}

.drawer-tab-strip {
  display: flex;
  gap: 8px;
  padding-top: 12px;
}

.drawer-tab {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.drawer-tab.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.drawer-tab.add {
  margin-left: auto;
}

.drawer-status-panel {
  padding: 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.drawer-status-main {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.drawer-status-main > strong {
  font-family: var(--font-body);
  font-size: 28px;
  line-height: 1;
}

.drawer-status-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.drawer-status-grid div {
  min-height: 68px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 3px;
  padding: 8px 4px;
  border-radius: var(--radius);
  background: var(--surface-low);
  text-align: center;
}

.drawer-status-grid .material-symbols-outlined {
  color: var(--primary);
  font-size: 21px;
}

.drawer-status-grid strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.drawer-status-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.drawer-money-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.drawer-money-summary div {
  min-height: 66px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.drawer-money-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.drawer-money-summary strong {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
}

.drawer-money-summary .due {
  border-color: rgba(201, 78, 34, 0.45);
  background: var(--primary-dim);
}

.drawer-money-summary .due strong {
  color: var(--primary);
}

@keyframes drawer-in {
  from {
    transform: translateX(32px);
  }
  to {
    transform: translateX(0);
  }
}

.table-summary {
  padding: 18px;
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.table-summary h3 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 30px;
  line-height: 36px;
}

.table-summary p {
  margin: 4px 0 0;
  color: var(--muted);
  font-weight: 700;
}

.bill-tabs {
  padding: 14px;
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.bill-tab {
  min-height: 58px;
  padding: 8px 12px;
  border-radius: var(--radius);
  background: var(--surface-low);
  border: 2px solid transparent;
  text-align: left;
  flex: 1 1 155px;
}

.bill-tab.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.bill-tab strong,
.bill-tab small {
  display: block;
}

.bill-tab small {
  color: var(--muted);
  margin-top: 4px;
  font-weight: 800;
}

.bill-body {
  display: grid;
  align-content: start;
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.bill-toolbar {
  padding: 14px 16px;
  border-bottom: 1px solid var(--outline);
}

.bill-toolbar h3 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 22px;
}

.bill-lines {
  display: grid;
}

.bill-line {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) 52px 86px 88px 136px;
  gap: 10px;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--outline);
  min-height: 64px;
}

.bill-line.header {
  min-height: 42px;
  background: var(--surface-low);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.bill-line:last-child {
  border-bottom: 0;
}

.line-name strong,
.line-name span {
  display: block;
}

.line-name span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.money,
.mono {
  font-family: var(--font-body);
  font-weight: 800;
}

.line-status.ready,
.doc-badge.ok {
  background: var(--green-soft);
  color: var(--green);
}

.line-status.kitchen {
  background: var(--amber-soft);
  color: var(--amber);
}

.line-status.void,
.doc-badge.block {
  background: var(--red-soft);
  color: var(--red);
}

.line-status.comp,
.doc-badge.hold {
  background: var(--purple-soft);
  color: var(--purple);
}

.line-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.line-menu-btn {
  width: 44px;
  height: 44px;
  min-height: 44px;
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--muted);
}

.line-menu-btn:hover {
  color: var(--primary);
  background: var(--primary-dim);
}

.line-menu-btn:disabled,
.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.scenario-btn,
.action-tile,
.payment-chip {
  min-height: 58px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1.5px solid var(--outline);
  color: var(--ink);
  font-weight: 900;
}

.scenario-btn {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 0 12px;
  text-align: left;
}

.scenario-btn.active,
.payment-chip.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.receipt-panel {
  display: grid;
  gap: 14px;
}

.receipt-summary {
  align-items: stretch;
  padding: 16px;
  background: var(--white);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.total-stack {
  display: grid;
  gap: 8px;
  width: 100%;
}

.total-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-weight: 800;
}

.total-row.strong {
  color: var(--primary);
  font-size: 24px;
}

.total-row.due {
  color: var(--red);
}

.total-row.paid {
  color: var(--green);
}

.payment-chips {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.payment-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 10px;
}

.compact-head {
  min-height: 54px;
  padding: 12px 14px;
}

.order-menu-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 12px 14px 0;
}

.order-menu-card {
  min-height: 58px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.order-menu-card strong,
.order-menu-card span {
  display: block;
}

.order-menu-card strong {
  font-size: 14px;
}

.order-menu-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
}

.order-menu-card.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.order-find-bar {
  display: grid;
  gap: 10px;
  padding: 12px 14px 0;
}

.order-search {
  min-height: 46px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.order-search .material-symbols-outlined {
  color: var(--muted);
}

.order-search input {
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  outline: 0;
}

.compact-clear {
  width: 34px;
  height: 34px;
  min-height: 34px;
}

.order-category-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.order-category-row .pill {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.order-category-row .pill span {
  min-width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--muted);
  font-size: 11px;
}

.order-category-row .pill.active span {
  background: var(--white);
  color: var(--primary);
}

.order-entry-modes {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 12px 14px 0;
}

.order-entry-modes button {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.order-entry-modes button:last-child {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.order-dish-list {
  display: grid;
  gap: 8px;
  padding: 12px 14px 14px;
}

.order-dish {
  min-height: 92px;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) minmax(86px, auto) 28px;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.order-dish:hover {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.order-dish:disabled {
  cursor: not-allowed;
  opacity: 0.56;
}

.order-dish.sold-out {
  background: var(--surface-low);
}

.order-dish img {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--surface-mid);
}

.order-dish strong,
.order-dish small {
  display: block;
}

.order-dish-main {
  min-width: 0;
}

.order-dish small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.order-price-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}

.dish-type-badge {
  display: inline-flex;
  min-height: 22px;
  margin-left: 6px;
  padding: 0 7px;
  align-items: center;
  border-radius: 999px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  vertical-align: middle;
}

.dish-type-badge.ingredient {
  background: var(--teal-soft);
  color: var(--teal);
}

.dish-type-badge.combo {
  background: var(--amber-soft);
  color: #8a5c00;
}

.order-rule-line {
  display: block;
  margin-top: 6px;
  color: var(--primary);
  font-size: 11px;
  font-weight: 900;
  line-height: 1.35;
}

.order-price-strip span {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.order-price-strip span.active {
  background: var(--primary-dim);
  color: var(--primary);
}

.order-dish-side {
  justify-self: end;
  text-align: right;
}

.order-dish-side strong {
  font-family: var(--font-body);
  font-size: 17px;
}

.order-dish-side em {
  display: inline-flex;
  margin-top: 6px;
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.order-dish > .material-symbols-outlined {
  color: var(--primary);
}

.order-workbench-backdrop {
  position: fixed;
  inset: 0;
  z-index: 45;
  display: grid;
  padding: 20px;
  background: rgba(59, 31, 14, 0.2);
  backdrop-filter: blur(5px);
}

.order-workbench {
  position: relative;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  box-shadow: 0 18px 44px rgba(59, 31, 14, 0.22);
  overflow: hidden;
}

.order-workbench-head {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1.5px solid var(--outline);
  background: var(--white);
}

.order-workbench-title {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 5px;
}

.order-workbench-title > span,
.order-workbench-head p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.order-workbench-head h3 {
  margin: 2px 0 0;
  font-size: 24px;
  line-height: 30px;
}

.order-workbench-head p {
  margin: 2px 0 0;
}

.order-flow-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.order-flow-strip span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.order-flow-strip strong {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--white);
  color: currentColor;
  font-family: var(--font-body);
  font-size: 11px;
}

.order-flow-strip span.done {
  border-color: rgba(31, 143, 92, 0.28);
  background: var(--green-soft);
  color: var(--green);
}

.order-flow-strip span.active {
  border-color: rgba(216, 78, 31, 0.34);
  background: var(--primary-dim);
  color: var(--primary);
}

.order-workbench-body {
  min-height: 0;
  display: grid;
  grid-template-columns: 520px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
}

.order-cart-panel,
.order-menu-panel {
  min-height: 0;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  overflow: hidden;
}

.order-cart-panel {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto auto;
}

.order-cart-meta {
  min-height: 58px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--outline);
}

.order-cart-meta span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.order-cart-head,
.order-cart-line {
  display: grid;
  grid-template-columns: 72px minmax(108px, 1fr) 68px 88px 126px;
  gap: 8px;
  align-items: center;
}

.order-cart-head {
  min-height: 38px;
  padding: 0 12px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.order-cart-list {
  min-height: 0;
  overflow: auto;
  padding: 8px;
  display: grid;
  align-content: start;
  gap: 8px;
}

.order-cart-line {
  min-height: 62px;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.order-cart-line.submitted {
  opacity: 0.72;
  background: var(--white);
}

.order-cart-line strong,
.order-cart-line small {
  display: block;
}

.order-cart-line small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
  font-weight: 850;
}

.order-line-stepper,
.order-line-options {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.order-line-options {
  justify-content: flex-end;
}

.order-line-stepper button {
  width: 30px;
  min-height: 30px;
  border-radius: 999px;
  background: var(--primary-dim);
  color: var(--primary);
}

.order-line-options .line-menu-btn {
  width: 36px;
  height: 36px;
  min-height: 36px;
  flex: 0 0 36px;
  border-radius: 12px;
}

.order-line-stepper button:disabled,
.order-line-options button:disabled {
  opacity: 0.38;
}

.order-bill-note {
  padding: 10px 12px 0;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.order-bill-note textarea {
  min-height: 70px;
  resize: none;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  padding: 10px;
  outline: 0;
}

.order-cart-total {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding: 0 14px;
  color: var(--muted);
  font-weight: 900;
}

.order-cart-total strong {
  color: var(--primary);
  font-family: var(--font-body);
  font-size: 20px;
}

.order-cart-actions,
.order-workbench-bottom {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--outline);
}

.order-cart-actions {
  grid-template-columns: 1fr 1.2fr 1.4fr 1.2fr;
}

.order-menu-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.order-menu-tabs.compact {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.order-dish-board {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  gap: 12px;
  padding: 12px;
}

.order-dish-grid {
  min-height: 0;
  overflow: auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-content: start;
  gap: 10px;
}

.pdf-dish-tile {
  min-height: 136px;
  padding: 10px;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  align-items: start;
  gap: 7px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  text-align: left;
}

.pdf-dish-image {
  grid-row: 1 / span 3;
  align-self: start;
  width: 64px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--surface-high);
  box-shadow: inset 0 0 0 1px rgba(116, 88, 60, 0.12);
}

.pdf-dish-tile:hover {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.pdf-dish-tile.needs-config {
  border-color: rgba(205, 140, 22, 0.44);
}

.pdf-dish-tile.sold-out {
  opacity: 0.5;
}

.pdf-dish-tile > strong,
.pdf-dish-tile > span {
  display: block;
}

.pdf-dish-tile > .pdf-dish-title {
  grid-column: 2;
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 3px;
}

.pdf-dish-code {
  display: block;
  color: var(--primary);
  font-size: 11px;
  line-height: 1;
  font-weight: 950;
}

.pdf-dish-name {
  display: block;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.16;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.pdf-dish-tile > span,
.pdf-dish-tile small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.pdf-dish-tile > .pdf-dish-meta {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  line-height: 1.25;
}

.pdf-dish-meta > span {
  display: inline;
  min-width: 0;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 850;
}

.pdf-dish-tile .dish-type-badge {
  min-height: 18px;
  margin: 0 5px 0 0;
  padding: 0 6px;
  font-family: var(--font-body);
  font-size: 10.5px;
  line-height: 18px;
  font-weight: 900;
}

.pdf-dish-tile > em {
  grid-column: 2;
  justify-self: end;
  align-self: end;
  color: var(--primary);
  font-family: var(--font-body);
  font-size: 18px;
  font-style: normal;
  font-weight: 900;
}

.pdf-dish-tile > .order-rule-line,
.pdf-dish-tile > small {
  grid-column: 1 / -1;
  margin-top: 0;
}

.order-category-rail {
  min-height: 0;
  overflow: auto;
  display: grid;
  align-content: start;
  gap: 8px;
}

.order-category-rail button {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  font-weight: 900;
}

.order-category-rail button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.order-category-rail strong {
  min-width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 12px;
}

.order-workbench-bottom {
  grid-template-columns: minmax(0, 1fr) auto auto auto auto;
  align-items: center;
}

.order-dialog-scrim {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(59, 31, 14, 0.24);
}

.dish-builder-dialog {
  width: min(860px, calc(100% - 80px));
  max-height: calc(100% - 70px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 16px 36px rgba(59, 31, 14, 0.2);
  overflow: hidden;
}

.dish-builder-head {
  min-height: 76px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--outline);
}

.dish-builder-head h3 {
  margin: 0;
  font-size: 22px;
}

.dish-builder-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.builder-head-note {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.builder-group-list {
  min-height: 0;
  overflow: auto;
  padding: 12px;
  display: grid;
  align-content: start;
  gap: 12px;
}

.builder-group {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  overflow: hidden;
}

.builder-group.incomplete {
  border-color: var(--amber);
}

.builder-group-head {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--white);
}

.builder-group-head span {
  color: var(--muted);
  font-size: 13px;
}

.builder-group-head .material-symbols-outlined {
  margin-left: auto;
  color: var(--teal);
}

.builder-select-all {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--primary-dim);
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
}

.builder-option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 12px;
}

.builder-option {
  min-height: 86px;
  padding: 12px;
  display: grid;
  align-content: space-between;
  border: 1.5px solid transparent;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.builder-option.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.builder-option span {
  color: var(--primary);
  font-family: var(--font-body);
  font-weight: 900;
}

.builder-option em {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--white);
  color: var(--primary);
  font-style: normal;
}

.builder-code-entry {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 0 12px 12px;
}

.builder-code-entry .material-symbols-outlined {
  color: var(--primary);
}

.builder-code-entry input {
  min-height: 44px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  padding: 0 12px;
  outline: 0;
  font-weight: 900;
}

.dish-builder-actions {
  min-height: 72px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-top: 1px solid var(--outline);
}

.dish-builder-actions .btn {
  min-width: 130px;
}

.code-order-dialog {
  width: min(420px, calc(100% - 80px));
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 16px 36px rgba(59, 31, 14, 0.2);
}

.code-order-dialog h3 {
  margin: 0;
}

.code-order-dialog label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.code-order-dialog input,
.code-order-dialog textarea {
  min-height: 48px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  padding: 10px;
  color: var(--ink);
  outline: 0;
}

.code-order-dialog textarea {
  min-height: 100px;
  resize: none;
}

.code-order-dialog.note-dialog.line-option-dialog {
  width: min(760px, calc(100% - 80px));
  max-height: calc(100% - 72px);
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.line-option-head {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--outline);
}

.line-option-head h3,
.line-option-head p {
  margin: 0;
}

.line-option-head p {
  margin-top: 5px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.line-option-head p strong {
  color: var(--ink);
  font-size: 16px;
}

.line-option-head p span {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
}

.line-option-body {
  min-height: 0;
  overflow: auto;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 14px;
}

.line-option-section {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  overflow: hidden;
}

.line-option-section-head {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--outline);
  background: var(--white);
}

.line-option-section-head strong {
  font-size: 14px;
}

.line-option-section-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.line-option-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px;
}

.line-option-chip {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border: 1.5px solid var(--outline);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
}

.line-option-chip span {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
}

.line-option-chip strong {
  font-size: 13px;
  font-weight: 950;
}

.line-option-chip:hover {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.line-option-chip.add.active {
  border-color: rgba(31, 143, 92, 0.42);
  background: var(--green-soft);
}

.line-option-chip.remove.active {
  border-color: rgba(216, 78, 31, 0.48);
  background: var(--primary-dim);
}

.line-option-chip.active span {
  background: var(--white);
  color: var(--primary);
}

.line-option-empty {
  margin: 0;
  padding: 6px 2px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.line-spice-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
}

.line-spice-row button {
  min-height: 44px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.line-spice-row button:hover,
.line-spice-row button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.line-free-note {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.line-free-note textarea {
  min-height: 86px;
  resize: none;
}

.code-qty-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.code-qty-row button {
  width: 38px;
  min-height: 38px;
  border-radius: 999px;
  background: var(--primary-dim);
  color: var(--primary);
}

.payment-list {
  display: grid;
  gap: 8px;
}

.payment-row {
  min-height: 46px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border-radius: var(--radius);
  background: var(--surface-low);
  font-weight: 800;
}

.payment-row.removable {
  grid-template-columns: minmax(0, 1fr) auto 34px;
}

.checkout-cash-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.cash-cell {
  min-height: 62px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.cash-cell span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.cash-cell strong {
  font-family: var(--font-body);
  font-size: 20px;
}

.cash-cell.change strong {
  color: var(--green);
}

.doc-toggle {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.doc-btn {
  min-height: 62px;
  border-radius: var(--radius);
  border: 1.5px solid var(--outline);
  background: var(--white);
  font-weight: 900;
}

.doc-btn.active {
  background: var(--ink);
  color: var(--white);
  border-color: var(--ink);
}

.keypad {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.keypad button {
  min-height: 60px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1.5px solid var(--outline);
  font-family: var(--font-body);
  font-size: 23px;
  font-weight: 800;
}

.amount-display {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 26px;
  font-weight: 800;
}

.touch-number-pad {
  position: fixed;
  z-index: 160;
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1.5px solid rgba(185, 143, 104, 0.62);
  border-radius: 20px;
  background: rgba(255, 253, 248, 0.98);
  box-shadow: 0 20px 46px rgba(59, 31, 14, 0.18);
  color: var(--ink);
  backdrop-filter: blur(12px);
  animation: number-pad-in 0.18s ease-out;
}

.touch-number-pad-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px;
  align-items: center;
  gap: 10px;
}

.touch-number-pad-head div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.touch-number-pad-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.touch-number-pad-head strong {
  min-height: 48px;
  display: flex;
  align-items: center;
  padding: 0 14px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--surface-low);
  color: var(--ink);
  font-size: 24px;
  font-weight: 950;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.touch-number-pad-close {
  width: 44px;
  height: 44px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--white);
  color: var(--ink);
}

.touch-number-pad-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.touch-number-pad-grid button {
  min-height: 54px;
  border: 1.5px solid var(--outline);
  border-radius: 14px;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 21px;
  font-weight: 950;
  box-shadow: none;
  transition:
    background 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease,
    transform 0.12s ease;
}

.touch-number-pad-grid button:hover {
  border-color: rgba(201, 78, 34, 0.52);
  background: var(--primary-dim);
  color: var(--primary);
}

.touch-number-pad-grid button:active {
  transform: translateY(1px);
}

.touch-number-pad-grid .operator,
.touch-number-pad-grid .decimal {
  background: var(--primary-dim);
  color: var(--primary);
}

.touch-number-pad-grid .utility {
  background: var(--surface-low);
  color: var(--muted);
  font-size: 16px;
}

.touch-number-pad-grid button.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-size: 22px;
  font-weight: 500;
}

.touch-number-pad-grid .equals,
.touch-number-pad-grid .done {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
}

.system-keyboard {
  position: fixed;
  z-index: 155;
  width: min(720px, calc(100vw - 24px));
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1.5px solid rgba(185, 143, 104, 0.62);
  border-radius: 20px;
  background: rgba(255, 253, 248, 0.98);
  box-shadow: 0 20px 46px rgba(59, 31, 14, 0.18);
  color: var(--ink);
  backdrop-filter: blur(12px);
  animation: number-pad-in 0.18s ease-out;
}

.system-keyboard.dragging {
  box-shadow: 0 24px 58px rgba(59, 31, 14, 0.24);
}

.system-keyboard-head {
  min-height: 50px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  align-items: center;
  gap: 10px;
  padding: 4px 4px 4px 10px;
  border-radius: 15px;
  background: var(--surface-low);
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.system-keyboard.dragging .system-keyboard-head {
  cursor: grabbing;
}

.system-keyboard-head div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.system-keyboard-head strong {
  font-size: 18px;
  line-height: 1.1;
  font-weight: 950;
}

.system-keyboard-head span {
  max-width: 100%;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.system-keyboard-close {
  width: 42px;
  min-height: 42px;
  border: 1.5px solid var(--outline);
  border-radius: 13px;
  background: var(--white);
  color: var(--ink);
}

.system-keyboard-rows {
  display: grid;
  gap: 7px;
}

.system-keyboard-row {
  display: flex;
  gap: 7px;
}

.system-keyboard-key {
  min-width: 0;
  min-height: 48px;
  flex: 1 1 0;
  border: 1.5px solid var(--outline);
  border-radius: 13px;
  background: var(--white);
  color: var(--ink);
  font-size: 16px;
  font-weight: 950;
  box-shadow: none;
  transition:
    background 0.14s ease,
    border-color 0.14s ease,
    color 0.14s ease,
    transform 0.1s ease;
}

.system-keyboard-key.wide {
  flex: 1.45 1 0;
}

.system-keyboard-key.grow {
  flex: 6 1 0;
}

.system-keyboard-key:hover {
  border-color: rgba(201, 78, 34, 0.52);
  background: var(--primary-dim);
  color: var(--primary);
}

.system-keyboard-key:active {
  transform: translateY(1px);
}

.system-keyboard-key.active {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
}

.system-keyboard-key .material-symbols-outlined {
  font-size: 20px;
}

@keyframes number-pad-in {
  from {
    opacity: 0;
    transform: translateY(6px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.pdf-operation-panel {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.drawer-action-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.drawer-action {
  min-height: 76px;
  display: grid;
  place-items: center;
  gap: 5px;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.drawer-action:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  background: var(--surface-low);
}

.drawer-action .material-symbols-outlined {
  color: var(--primary);
}

.floor-overlay-backdrop {
  position: fixed;
  inset: 0;
  z-index: 42;
  display: grid;
  place-items: center;
  padding: 32px;
  background: rgba(59, 31, 14, 0.22);
  backdrop-filter: blur(5px);
}

.floor-modal {
  width: min(760px, calc(var(--desktop-canvas-width) - 320px));
  max-height: calc((100vh / var(--desktop-scale)) - 64px);
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  box-shadow: 0 18px 40px rgba(59, 31, 14, 0.22);
}

.floor-modal.wide {
  width: min(980px, calc(var(--desktop-canvas-width) - 300px));
}

.floor-modal.open-table-modal {
  width: min(620px, calc(var(--desktop-canvas-width) - 420px));
  grid-template-rows: auto auto auto;
}

.floor-modal.table-detail-modal {
  width: min(1180px, calc(var(--desktop-canvas-width) - 72px));
  max-height: calc((100vh / var(--desktop-scale)) - 44px);
}

.table-detail-modal-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(380px, 0.98fr);
  gap: 14px;
  overflow: auto;
  padding: 14px;
}

.table-detail-modal-primary,
.table-detail-modal-secondary {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 12px;
}

.table-detail-hero {
  min-height: 132px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px;
  border: 2px solid var(--space-color);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--space-bg), var(--white));
  box-shadow: 0 14px 28px var(--space-shadow);
}

.table-detail-hero div {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.table-detail-hero span:first-child {
  color: var(--space-color-dark);
  font-size: 13px;
  font-weight: 950;
}

.table-detail-hero strong {
  color: var(--space-color-dark);
  font-family: var(--font-body);
  font-size: 56px;
  line-height: 1;
}

.table-detail-modal .drawer-tab-strip {
  padding-top: 0;
}

.table-detail-modal .drawer-status-panel,
.table-detail-modal .pdf-operation-panel,
.table-detail-modal .drawer-bill-preview,
.table-detail-modal .no-bill-compact {
  box-shadow: none;
}

.floor-modal-head {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1.5px solid var(--outline);
  background: var(--white);
}

.floor-modal-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.floor-modal-title > span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--primary);
}

.floor-modal-title h3 {
  margin: 0;
  font-size: 22px;
  line-height: 27px;
}

.floor-modal-title p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
  font-weight: 800;
}

.floor-data-table {
  overflow: auto;
  padding: 14px;
  display: grid;
  gap: 8px;
}

.floor-data-row {
  min-height: 58px;
  display: grid;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.floor-data-row.header {
  min-height: 42px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.message-table .floor-data-row {
  grid-template-columns: 1fr 1.2fr 0.9fr 0.7fr 58px;
}

.pending-invoice-table .floor-data-row {
  grid-template-columns: 1fr 0.65fr 1fr 1.6fr;
}

.row-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.row-actions .btn {
  min-height: 42px;
  padding: 0 12px;
}

.floor-modal-foot {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  padding: 0 14px 14px;
  color: var(--muted);
  font-weight: 900;
}

.open-table-form {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.open-table-summary {
  min-height: 92px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.open-table-summary span,
.open-table-summary small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.open-table-summary strong {
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 32px;
  line-height: 1;
}

.open-table-field {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 950;
}

.open-table-field select,
.open-table-field input {
  min-height: 52px;
  width: 100%;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background-color: var(--white);
  color: var(--ink);
  padding: 0 12px;
  outline: 0;
  font-size: 16px;
  font-weight: 950;
}

.open-table-field select {
  padding-right: 42px;
}

.open-table-field.has-error {
  color: var(--red);
}

.open-table-field.has-error select,
.open-table-field.has-error input {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(209, 41, 46, 0.08);
}

.open-table-field.has-error .open-table-menu-trigger {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(209, 41, 46, 0.08);
}

.open-table-field em {
  color: var(--red);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.25;
}

.open-table-menu-picker {
  position: relative;
  z-index: 2;
}

.open-table-menu-picker.open {
  z-index: 12;
}

.open-table-menu-trigger {
  min-height: 52px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
  font-weight: 950;
}

.open-table-menu-trigger:hover,
.open-table-menu-picker.open .open-table-menu-trigger {
  border-color: var(--outline-strong);
  box-shadow: var(--shadow-selected);
}

.open-table-menu-trigger.placeholder {
  color: var(--muted);
}

.open-table-menu-trigger > span,
.open-table-menu-option > span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.open-table-menu-trigger strong,
.open-table-menu-option strong {
  overflow: hidden;
  color: inherit;
  font-size: 15px;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.open-table-menu-trigger small,
.open-table-menu-option small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.open-table-menu-trigger .material-symbols-outlined {
  width: 24px;
  min-width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  color: var(--primary);
  font-size: 22px;
}

.open-table-menu-options {
  width: 100%;
  max-height: 260px;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  display: none;
  gap: 6px;
  padding: 8px;
  overflow: auto;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-dropdown);
}

.open-table-menu-picker.open .open-table-menu-options {
  display: grid;
}

.open-table-menu-option {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 10px;
  border: 1.5px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.open-table-menu-option:hover,
.open-table-menu-option.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.open-table-menu-option .material-symbols-outlined {
  color: var(--primary);
  font-size: 20px;
}

.open-table-covers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.open-counter {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) 50px;
  gap: 8px;
}

.open-counter button {
  min-height: 52px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--primary);
}

.open-counter input {
  background: var(--white);
  color: var(--ink);
  caret-color: var(--primary);
  text-align: center;
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 900;
}

.open-counter input::placeholder {
  color: var(--ink);
  opacity: 1;
}

.open-counter input:focus {
  background: var(--white);
  color: var(--ink);
}

.open-table-actions {
  padding: 0 16px 16px;
}

.quick-receipt-workbench {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) 310px;
  gap: 14px;
  padding: 14px;
  overflow: auto;
}

.quick-receipt-left,
.quick-payment-stack {
  display: grid;
  align-content: start;
  gap: 12px;
}

.quick-sale-card,
.quick-sale-amount,
.payment-row,
.transfer-summary > div,
.transfer-confirm {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.quick-sale-card {
  min-height: 150px;
  padding: 16px;
  display: grid;
  align-content: center;
  gap: 8px;
}

.quick-vat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.quick-vat-grid button {
  min-height: 44px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  font-weight: 950;
}

.quick-vat-grid button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.quick-sale-card span,
.quick-sale-card small,
.quick-sale-amount span,
.payment-row span,
.transfer-summary span,
.transfer-summary small,
.transfer-confirm span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.quick-sale-card strong {
  font-size: 25px;
}

.quick-sale-amount {
  min-height: 86px;
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.quick-sale-amount strong {
  font-family: var(--font-body);
  font-size: 36px;
}

.quick-sale-amount input {
  width: 150px;
  min-height: 52px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  text-align: right;
  font-family: var(--font-body);
  font-size: 28px;
  font-weight: 900;
  padding: 0 12px;
}

.payment-row {
  min-height: 54px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink);
}

.payment-row.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.payment-row.muted {
  background: var(--surface-mid);
}

.quick-receipt-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.transfer-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px 14px 0;
}

.transfer-summary > div {
  min-height: 94px;
  padding: 14px;
  display: grid;
  align-content: center;
  gap: 5px;
}

.transfer-summary strong {
  font-family: var(--font-body);
  font-size: 26px;
}

.transfer-table-grid {
  padding: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  overflow: auto;
}

.transfer-target {
  min-height: 112px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.transfer-target.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  box-shadow: var(--shadow-selected);
}

.transfer-target strong {
  font-family: var(--font-body);
  font-size: 26px;
}

.transfer-target small {
  color: var(--muted);
  font-weight: 850;
}

.transfer-target em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.transfer-table-grid.compact {
  padding: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-height: 286px;
}

.transfer-confirm {
  margin: 0 14px 14px;
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
}

.transfer-confirm strong,
.transfer-confirm span {
  grid-column: 1 / 2;
}

.operation-section-title {
  padding: 14px 14px 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 950;
}

.table-operation-split {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  gap: 14px;
  padding: 0 14px 14px;
  overflow: auto;
}

.table-operation-split .operation-section-title {
  padding: 0 0 8px;
}

.operation-choice-list,
.operation-choice-grid {
  display: grid;
  gap: 10px;
  padding: 14px;
  overflow: auto;
}

.operation-choice-list {
  padding: 0;
}

.operation-choice-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.menu-choice-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.operation-choice {
  min-height: 76px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.operation-choice strong,
.operation-choice span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.operation-choice strong {
  font-size: 16px;
  font-weight: 950;
}

.operation-choice span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.operation-choice.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.table-temp-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.table-temp-form .wide-field {
  grid-column: 1 / -1;
}

.invoice-form {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.invoice-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.invoice-form-grid .wide {
  grid-column: 1 / -1;
}

.invoice-management {
  display: grid;
  gap: 14px;
}

.invoice-view-tabs,
.invoice-time-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 14px 14px;
}

.invoice-view-tabs button,
.invoice-time-filters button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.invoice-view-tabs button.active,
.invoice-time-filters button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.invoice-archive-table .invoice-row {
  grid-template-columns: 1fr 0.9fr 1.4fr 0.8fr 0.8fr 0.9fr;
}

.checkout-workbench-backdrop {
  position: fixed;
  inset: 0;
  z-index: 48;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(59, 31, 14, 0.2);
  backdrop-filter: blur(5px);
}

.checkout-workbench {
  width: min(1120px, calc(var(--desktop-canvas-width) - 44px));
  height: calc((100vh / var(--desktop-scale)) - 44px);
  max-height: 880px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  box-shadow: 0 20px 48px rgba(59, 31, 14, 0.24);
}

.checkout-workbench-head {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1.5px solid var(--outline);
  background: var(--white);
}

.checkout-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.checkout-title > span {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--primary);
}

.checkout-title small,
.checkout-title p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.checkout-title h3 {
  margin: 2px 0 1px;
  font-size: 26px;
  line-height: 1.1;
}

.checkout-title p {
  margin: 0;
  line-height: 1.35;
}

.checkout-workbench-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 365px;
  gap: 14px;
  padding: 14px;
  overflow: hidden;
}

.checkout-bill-panel,
.checkout-pay-panel {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 12px;
  overflow: auto;
}

.checkout-bill-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.checkout-bill-tab {
  min-width: 124px;
  min-height: 56px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 8px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.checkout-bill-tab.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.checkout-bill-tab.add {
  min-width: 118px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.checkout-bill-tab span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.checkout-merge-strip {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border: 1.5px dashed var(--outline-strong);
  border-radius: var(--radius);
  background: var(--surface-low);
  overflow-x: auto;
}

.checkout-merge-strip > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
  white-space: nowrap;
}

.checkout-merge-strip button {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 950;
  white-space: nowrap;
}

.checkout-merge-strip button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.checkout-table-card,
.checkout-member-strip,
.checkout-line-table,
.checkout-summary-card,
.checkout-doc-card,
.checkout-payment-line,
.checkout-dialog,
.checkout-even-preview {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.checkout-table-card {
  min-height: 110px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
}

.checkout-table-card h4 {
  margin: 4px 0;
  font-family: var(--font-body);
  font-size: 34px;
  line-height: 1;
}

.checkout-table-card p,
.checkout-member-strip small,
.checkout-doc-card small {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.checkout-table-badges {
  display: flex;
  align-items: center;
  gap: 8px;
}

.checkout-member-strip {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
}

.checkout-member-strip.bound {
  background: linear-gradient(180deg, var(--green-soft), var(--white));
  border-color: rgba(42, 138, 78, 0.35);
}

.checkout-member-strip > div,
.checkout-doc-card > div:first-child {
  display: grid;
  gap: 4px;
}

.checkout-member-strip span,
.checkout-doc-card span,
.checkout-summary-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.checkout-member-strip strong,
.checkout-doc-card strong {
  font-size: 20px;
}

.checkout-line-table {
  overflow: hidden;
}

.checkout-line {
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 60px 96px 105px;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-top: 1px solid var(--outline);
}

.checkout-line:first-child {
  border-top: 0;
}

.checkout-line.header {
  min-height: 42px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.checkout-line strong,
.checkout-line small {
  display: block;
}

.checkout-line.selected {
  background: var(--primary-dim);
}

.checkout-line.rush {
  border-left: 4px solid var(--primary);
}

.checkout-line-name {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}

.checkout-line small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.checkout-tool-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.checkout-tool-strip .btn {
  min-height: 54px;
  padding: 0 10px;
}

.checkout-summary-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 12px;
}

.checkout-summary-card div {
  min-height: 64px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--surface-low);
}

.checkout-summary-card button {
  min-height: 64px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px;
  border: 0;
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  text-align: left;
}

.checkout-summary-card strong {
  font-family: var(--font-body);
  font-size: 17px;
}

.checkout-summary-card .due {
  border: 1.5px solid rgba(201, 78, 34, 0.36);
  background: var(--primary-dim);
}

.checkout-summary-card .due strong {
  color: var(--primary);
}

.checkout-summary-card .change strong {
  color: var(--green);
}

.checkout-payment-stack {
  display: grid;
  gap: 8px;
}

.checkout-payment-line {
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  align-items: center;
  gap: 8px;
  padding: 6px;
}

.checkout-payment-line.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.checkout-payment-line > button:first-child {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 8px;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
}

.checkout-payment-line > button:first-child span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.checkout-payment-line .material-symbols-outlined {
  color: var(--primary);
}

.checkout-payment-line em {
  font-family: var(--font-body);
  font-style: normal;
  font-weight: 900;
}

.checkout-doc-card {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.checkout-actions-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.checkout-action {
  min-height: 58px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 4px;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.checkout-action .material-symbols-outlined {
  color: var(--primary);
}

.checkout-action.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

.checkout-action.primary .material-symbols-outlined {
  color: var(--white);
}

.checkout-action.primary.alt {
  background: var(--ink);
  border-color: var(--ink);
}

.checkout-action:disabled,
.checkout-payment-line button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.checkout-rule-note {
  margin: 0;
}

.checkout-dialog-scrim {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  background: rgba(59, 31, 14, 0.3);
}

.checkout-dialog {
  width: min(420px, 90%);
  max-height: calc((100vh / var(--desktop-scale)) - 120px);
  display: grid;
  gap: 12px;
  padding: 18px;
  overflow: auto;
  box-shadow: 0 16px 36px rgba(59, 31, 14, 0.22);
}

.checkout-dialog h3 {
  margin: 0;
  font-size: 24px;
}

.checkout-dialog p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
  font-weight: 850;
}

.checkout-amount-field {
  display: grid;
  gap: 6px;
}

.checkout-amount-field span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.checkout-amount-field input {
  min-height: 56px;
  width: 100%;
  padding: 0 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 900;
}

.checkout-quick-amounts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.checkout-quick-amounts button,
.checkout-keypad button {
  min-height: 48px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-weight: 900;
}

.checkout-keypad {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.checkout-mode-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.checkout-mode-tabs button {
  min-height: 44px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.checkout-mode-tabs button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.checkout-keypad button {
  font-family: var(--font-body);
  font-size: 20px;
}

.checkout-dialog-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.checkout-customer-list {
  display: grid;
  gap: 8px;
}

.checkout-customer-card {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  text-align: left;
}

.checkout-customer-card span,
.checkout-customer-card small {
  display: grid;
  gap: 3px;
}

.checkout-customer-card small {
  color: var(--muted);
  font-size: 12px;
}

.checkout-customer-card em {
  font-style: normal;
  color: var(--primary);
  font-weight: 900;
}

.checkout-even-preview {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
}

.checkout-even-preview strong {
  font-family: var(--font-body);
  font-size: 24px;
}

.drawer-bill-preview {
  overflow: hidden;
}

.drawer-bill-lines {
  display: grid;
  gap: 8px;
  padding: 0 12px 12px;
}

.drawer-bill-line {
  min-height: 54px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px 82px 34px;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  border-top: 1px solid var(--outline);
}

.drawer-bill-line:first-child {
  border-top: 0;
}

.drawer-bill-line strong,
.drawer-bill-line span {
  display: block;
}

.drawer-bill-line span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.3;
}

.drawer-bill-line em {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-low);
  color: var(--ink);
  font-style: normal;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 900;
}

.drawer-bill-line > strong {
  justify-self: end;
  font-family: var(--font-body);
  font-size: 13px;
}

.compact-empty {
  min-height: 80px;
}

.no-bill-compact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.no-bill-compact h3 {
  margin: 0;
}

.no-bill-compact p {
  margin: 4px 0 0;
}

.operation-rule-note {
  min-height: 46px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
}

.operation-rule-note .material-symbols-outlined {
  color: var(--primary);
}

.action-tile {
  display: grid;
  place-items: center;
  gap: 2px;
  padding: 10px;
  color: var(--blue);
}

.action-tile span {
  font-size: 24px;
}

.dashboard-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 18px;
}

.timeline {
  display: grid;
}

.event-row {
  min-height: 66px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--outline);
}

.event-row:last-child {
  border-bottom: 0;
}

.event-dot {
  width: 34px;
  height: 34px;
  border-radius: var(--radius);
  display: grid;
  place-items: center;
  background: var(--surface-low);
  color: var(--ink);
}

.event-row strong,
.event-row span {
  display: block;
}

.event-row span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.compact-table-map {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  padding: 18px;
}

.tiny-table {
  min-height: 64px;
  border-radius: var(--radius);
  border: 1.5px solid var(--outline);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 800;
  color: var(--ink);
}

.tiny-table.dining {
  background: #fff0df;
  border-color: #de7436;
  color: #a33d12;
}

.tiny-table.free {
  background: #eaf7ee;
  border-color: #8fd0a2;
  color: #1f7a43;
}

.tiny-table.reserved {
  background: #fff7d8;
  border-color: #e3bd4b;
  color: #8a5c00;
}

.tiny-table.cleaning {
  background: var(--red-soft);
  color: var(--red);
}

.orders-layout {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(480px, 1fr) minmax(360px, 0.8fr);
  gap: 18px;
}

.main[data-module="orders"] {
  height: calc(100dvh / var(--desktop-scale));
  max-height: calc(100dvh / var(--desktop-scale));
  overflow: hidden;
}

.main[data-module="orders"] .content {
  flex: 1 1 0;
  min-height: 0;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  overflow: hidden;
}

.orders-list-panel,
.orders-detail-panel,
.checkout-record-panel {
  min-height: 0;
  overflow: hidden;
}

.orders-list-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.orders-detail-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.checkout-record-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-height: 180px;
}

.order-list,
.kds-lanes,
.reservation-list,
.menu-grid,
.inventory-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.orders-list-panel .order-list,
.orders-detail-panel > .detail-stack,
.checkout-record-panel .checkout-record-list {
  min-height: 0;
  align-content: start;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.order-empty-state {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  border: 1.5px dashed var(--outline);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  text-align: center;
}

.order-row {
  min-height: 76px;
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) minmax(160px, 1fr) minmax(82px, auto) minmax(94px, auto);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.order-row.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.order-row strong,
.order-row span {
  display: block;
}

.order-row span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  margin-top: 3px;
}

.order-status {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: start;
  margin-top: 0;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.order-row .order-status {
  display: inline-flex;
  margin-top: 0;
  font-size: 12px;
}

.order-status.partial {
  background: #f0e7df;
  color: #6b4c39;
}

.order-status.paid {
  background: var(--green-soft);
  color: var(--green);
}

.order-status.kitchen {
  background: var(--amber-soft);
  color: var(--amber);
}

.order-status.deposit {
  background: #f1e4d9;
  color: var(--purple);
}

.order-status.void {
  background: var(--red-soft);
  color: var(--red);
}

.checkout-stamp {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1.5px solid rgba(42, 138, 78, 0.28);
  border-radius: var(--radius);
  background: var(--green-soft);
}

.checkout-stamp strong,
.checkout-stamp span,
.checkout-stamp code {
  display: block;
}

.checkout-stamp span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.checkout-stamp code {
  color: var(--green);
  font-family: var(--font-body);
  font-weight: 900;
}

.checkout-record-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.checkout-record {
  min-height: 66px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.checkout-record:hover {
  border-color: var(--primary);
}

.checkout-record strong,
.checkout-record small {
  display: block;
}

.checkout-record small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.detail-stack {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.split-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
}

.split-box {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--surface-low);
}

.split-box strong,
.split-box span {
  display: block;
}

.split-box span {
  margin-top: 5px;
  color: var(--muted);
  font-weight: 700;
}

.order-data-panel {
  display: grid;
  gap: 12px;
}

.order-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.order-meta-grid div,
.order-detail-section {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.order-meta-grid div {
  min-height: 66px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 12px;
}

.order-meta-grid span,
.order-detail-head span,
.order-detail-line span,
.order-mini-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.order-meta-grid strong {
  font-size: 14px;
}

.order-detail-section {
  overflow: hidden;
}

.order-detail-section.compact {
  display: grid;
  gap: 0;
}

.order-detail-head {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--outline);
}

.order-detail-lines {
  display: grid;
}

.order-detail-line,
.order-mini-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid var(--outline);
}

.order-mini-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.order-detail-line:last-child,
.order-mini-row:last-child {
  border-bottom: 0;
}

.order-detail-line strong,
.order-detail-line span {
  display: block;
}

.order-detail-line > div {
  min-width: 0;
}

.order-detail-line > div strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-detail-line .line-status {
  justify-self: start;
}

.order-mini-row.muted strong,
.order-mini-row.muted span {
  color: var(--muted);
}

.order-detail-empty {
  min-height: 54px;
  display: flex;
  align-items: center;
  padding: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.kds-lanes {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
}

.kds-lane {
  min-width: 0;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  overflow: hidden;
}

.lane-head {
  min-height: 60px;
  padding: 14px;
  border-bottom: 1px solid var(--outline);
  background: var(--surface-low);
}

.lane-head h3 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 20px;
}

.ticket-card {
  margin: 12px;
  padding: 12px;
  border: 2px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  display: grid;
  gap: 10px;
}

.ticket-card.aging {
  border-color: var(--amber);
  background: var(--amber-soft);
}

.ticket-card.late {
  border-color: var(--red);
  background: var(--red-soft);
}

.ticket-card.hold {
  border-color: var(--purple);
  background: var(--purple-soft);
}

.ticket-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ticket-title strong {
  font-family: var(--font-body);
}

.ticket-items {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.ticket-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ticket-actions button {
  min-height: 44px;
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  font-weight: 900;
}

.kds-mode-switch {
  min-width: 128px;
}

.kds-mode-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.kds-table-grid,
.kds-dish-grid {
  display: grid;
  gap: 14px;
  align-items: start;
}

.kds-table-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kds-dish-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kds-table-card,
.kds-dish-card {
  min-width: 0;
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.kds-card-head,
.kds-dish-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding-bottom: 10px;
  border-bottom: 1.5px solid var(--outline);
}

.kds-card-head strong,
.kds-dish-head strong {
  display: block;
  color: var(--ink);
  font-size: 25px;
  font-weight: 950;
}

.kds-card-head span,
.kds-dish-head span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.kds-card-head em {
  min-width: 58px;
  min-height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--green-soft);
  color: var(--green);
  font-style: normal;
  font-family: var(--font-body);
  font-weight: 900;
}

.kds-card-head em.aging {
  background: var(--amber-soft);
  color: var(--amber);
}

.kds-card-head em.late {
  background: var(--red-soft);
  color: var(--red);
}

.kds-table-total {
  min-height: 64px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 12px;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--surface-low);
}

.kds-table-total span,
.kds-table-total small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.kds-table-total small {
  grid-column: 1 / -1;
}

.kds-table-total strong {
  color: var(--primary);
  font-family: var(--font-body);
  font-size: 28px;
  font-weight: 900;
}

.kds-dish-head b {
  min-width: 72px;
  min-height: 64px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--primary);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 34px;
  font-weight: 900;
}

.kds-line-list {
  display: grid;
  gap: 8px;
}

.kds-line {
  width: 100%;
  min-height: 62px;
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) 46px 56px 76px;
  gap: 8px;
  align-items: center;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  color: var(--ink);
  text-align: left;
}

.kds-line.open:hover {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.kds-line.ready {
  opacity: 0.72;
  background: var(--green-soft);
  border-color: rgba(42, 138, 78, 0.35);
}

.kds-line-table,
.kds-line-qty,
.kds-line-age,
.kds-line-status {
  display: grid;
  place-items: center;
  min-height: 40px;
  border-radius: 10px;
  background: var(--white);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 900;
}

.kds-line-qty {
  color: var(--primary);
  font-size: 20px;
}

.kds-line-age.late {
  background: var(--red-soft);
  color: var(--red);
}

.kds-line-status {
  color: var(--amber);
  font-family: var(--font-body);
  font-size: 12px;
}

.kds-line-status.ready {
  color: var(--green);
}

.kds-line-dish {
  min-width: 0;
}

.kds-line-dish strong,
.kds-line-dish small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kds-line-dish strong {
  font-size: 14px;
  font-weight: 950;
}

.kds-line-dish small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.reservations-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 18px;
}

.reservation-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.reservation-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 18px;
  margin-bottom: 18px;
  align-items: stretch;
}

.reservation-calendar-panel {
  overflow: hidden;
}

.reservation-calendar-head {
  min-height: 76px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--outline);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.reservation-calendar-head h3 {
  margin: 0;
  font-size: 22px;
  line-height: 26px;
}

.reservation-calendar-head p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.reservation-calendar-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.reservation-calendar-nav .btn,
.reservation-calendar-nav .icon-btn {
  height: 40px;
  min-height: 40px;
  border-radius: 12px;
}

.reservation-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  padding: 12px 14px 6px;
}

.reservation-weekdays span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
  text-align: center;
}

.reservation-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  padding: 0 14px 14px;
}

.reservation-day {
  min-width: 0;
  min-height: 58px;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: 12px;
  background: var(--white);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: left;
  font: inherit;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    color 0.18s ease,
    transform 0.18s ease;
}

.reservation-day:hover {
  border-color: rgba(217, 77, 31, 0.55);
  background: #fff7ef;
}

.reservation-day span {
  font-size: 15px;
  line-height: 18px;
  font-weight: 950;
}

.reservation-day small {
  min-height: 14px;
  color: var(--muted);
  font-size: 10px;
  line-height: 12px;
  font-weight: 900;
}

.reservation-day.outside {
  color: rgba(74, 47, 33, 0.42);
  background: rgba(255, 255, 255, 0.52);
}

.reservation-day.today {
  border-color: rgba(28, 136, 74, 0.42);
  background: #eff9f1;
}

.reservation-day.selected {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
  transform: translateY(-1px);
}

.reservation-day.selected small {
  color: rgba(255, 255, 255, 0.82);
}

.reservation-day-panel {
  display: grid;
  grid-template-rows: auto min-content;
  align-content: start;
}

.reservation-day-panel .panel-head {
  min-height: 76px;
}

.reservation-day-panel .reservation-summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  padding: 14px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  padding: 16px;
}

.calendar-day {
  min-height: 94px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  padding: 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-weight: 800;
}

.calendar-day.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.calendar-day small {
  color: var(--muted);
}

.reservation-workbench {
  min-height: 620px;
}

.reservation-board {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.reservation-side {
  display: grid;
  align-content: start;
  gap: 18px;
}

.reservation-card {
  min-height: 118px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--white);
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(0, 330px);
  gap: 16px;
  align-items: stretch;
}

.reservation-card.confirmed,
.reservation-card.deposit {
  border-color: #e3bd4b;
  background: #fffaf0;
}

.reservation-card.arriving,
.reservation-card.queued {
  border-color: #de7436;
  background: #fff3e8;
}

.reservation-card.seated {
  border-color: #8fd0a2;
  background: #edf8f0;
}

.reservation-card.late,
.reservation-card.no-show,
.reservation-card.cancelled {
  border-color: rgba(201, 42, 47, 0.32);
  background: #fff5f2;
}

.reservation-main {
  min-width: 0;
  display: grid;
  gap: 7px;
  align-content: start;
}

.reservation-title-row {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.reservation-title-row strong {
  min-width: 0;
  flex: 0 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reservation-card strong,
.reservation-card span,
.reservation-card small {
  display: block;
}

.reservation-card span {
  color: var(--muted);
  font-weight: 700;
}

.reservation-card small {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--muted-2);
  font-size: 12px;
  font-weight: 900;
}

.reservation-status {
  height: 28px;
  min-height: 28px;
  min-width: 56px;
  flex: 0 0 auto;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  overflow: hidden;
  text-overflow: clip;
  white-space: nowrap;
}

.reservation-status.confirmed,
.reservation-status.deposit {
  background: #fff0bf;
  color: #8a5c00;
}

.reservation-status.arriving,
.reservation-status.queued {
  background: #ffe1c4;
  color: #a33d12;
}

.reservation-status.seated {
  background: #dff4e6;
  color: #1f7a43;
}

.reservation-status.late,
.reservation-status.no-show,
.reservation-status.cancelled {
  background: var(--red-soft);
  color: var(--red);
}

.reservation-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-content: center;
  justify-self: end;
  max-width: 330px;
  gap: 8px;
}

.reservation-actions .btn {
  flex: 0 0 92px;
  min-height: 40px;
  padding: 0 9px;
  border-radius: 12px;
  white-space: nowrap;
}

.queue-form {
  padding: 14px;
  display: grid;
  gap: 12px;
}

.reservation-create {
  padding: 14px;
  display: grid;
  gap: 12px;
  border-bottom: 1px solid var(--outline);
}

.reservation-date-context {
  min-height: 58px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: 12px;
  background: var(--surface-low);
  display: flex;
  align-items: center;
  gap: 10px;
}

.reservation-date-context > .material-symbols-outlined {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: var(--white);
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.reservation-date-context span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.reservation-date-context strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
  line-height: 18px;
}

.reservation-date-context small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.reservation-inline-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  gap: 10px;
}

.reservation-table-pick {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1.5px dashed var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.reservation-table-pick > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.reservation-table-pick span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--white);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.reservation-table-pick .muted {
  background: transparent;
  padding: 0;
}

.queue-block {
  padding-top: 0;
}

.inline-head {
  min-height: 50px;
  padding: 12px 0 6px;
  border-bottom: 0;
}

.inline-head h3 {
  font-size: 18px;
  line-height: 22px;
}

.compact-counter {
  min-height: 54px;
  grid-template-columns: 50px 1fr 50px;
}

.compact-counter button {
  min-height: 52px;
}

.compact-counter strong {
  font-size: 24px;
}

.counter {
  min-height: 64px;
  display: grid;
  grid-template-columns: 58px 1fr 58px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
}

.counter button {
  min-height: 62px;
  background: var(--surface-low);
  color: var(--ink);
  font-size: 26px;
  font-weight: 800;
}

.counter strong {
  display: grid;
  place-items: center;
  font-family: var(--font-body);
  font-size: 28px;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.field input,
.field select {
  min-height: 54px;
  width: 100%;
  padding: 0 14px;
  border-radius: var(--radius);
  border: 1.5px solid var(--outline);
  background-color: var(--white);
  color: var(--ink);
  font-weight: 950;
}

.field select {
  min-height: 52px;
  padding-right: 42px;
}

.menu-management-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.menu-management-layout.menu-section-dishes {
  grid-template-columns: minmax(0, 1fr);
  height: 100%;
  max-height: 100%;
  min-height: 0;
  align-items: stretch;
  overflow: hidden;
}

.menu-management-layout.menu-section-menus {
  grid-template-columns: 300px minmax(0, 1fr);
}

.menu-section-dishes .menu-set-panel,
.menu-section-dishes .shared-menu-panel,
.menu-section-menus .dish-catalog-panel,
.menu-section-menus .dish-editor {
  display: none;
}

.menu-section-menus .shared-menu-panel {
  grid-column: 2;
}

.menu-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.menu-set {
  min-height: 74px;
  border: 2px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  padding: 12px;
  text-align: left;
  display: grid;
  gap: 4px;
  color: var(--ink);
}

.menu-set.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.menu-set strong,
.menu-set span {
  display: block;
}

.menu-set span {
  color: var(--muted);
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
}

.menu-set small {
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
}

.menu-side-note {
  margin: 0 14px 14px;
  padding: 12px;
  border: 1.5px dashed var(--outline-strong);
  border-radius: var(--radius);
  background: var(--surface-low);
  display: grid;
  gap: 6px;
}

.menu-side-note strong {
  color: var(--ink);
}

.menu-side-note span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
}

.menu-admin-layout {
  height: 100%;
  max-height: 100%;
  min-height: 0;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 340px;
  gap: 14px;
  align-items: stretch;
  overflow: hidden;
}

.menu-admin-layout .panel {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.menu-admin-sidebar .panel-head,
.menu-editor-panel .panel-head,
.menu-dishes-panel .panel-head,
.menu-library-panel .panel-head {
  flex: 0 0 auto;
}

.menu-admin-list,
.menu-dish-list,
.menu-library-list {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
}

.menu-admin-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.menu-admin-card {
  min-height: 94px;
}

.menu-admin-main {
  min-width: 0;
  min-height: 0;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
}

.menu-editor-panel {
  flex: 0 1 auto;
  min-height: 0;
  max-height: min(460px, 52%);
}

.menu-editor-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.menu-editor-body {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  gap: 14px;
  padding: 14px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.menu-summary-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.menu-summary-strip > div {
  min-width: 0;
  min-height: 58px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: 12px;
  background: var(--surface-low);
}

.menu-summary-strip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.menu-summary-strip strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
  font-size: 16px;
  font-weight: 950;
}

.menu-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.menu-field-grid .span-2 {
  grid-column: span 2;
}

.field textarea {
  width: 100%;
  min-height: 82px;
  padding: 12px 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background-color: var(--white);
  color: var(--ink);
  font: inherit;
  font-weight: 850;
  line-height: 1.4;
  resize: vertical;
}

.menu-channel-section {
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.menu-channel-section > strong {
  color: var(--ink);
  font-size: 14px;
}

.menu-channel-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.menu-dishes-panel {
  flex: 1 1 320px;
  min-height: 260px;
  max-height: 100%;
}

.menu-dish-list {
  display: grid;
  gap: 8px;
  padding: 14px;
  grid-auto-rows: max-content;
}

.menu-dish-row {
  min-width: 0;
  min-height: 72px;
  display: grid;
  grid-template-columns: minmax(180px, 1.5fr) minmax(118px, 0.9fr) minmax(112px, 0.62fr) 42px;
  gap: 10px;
  align-items: center;
  padding: 9px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.menu-dish-row.header {
  min-height: 36px;
  padding-block: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.menu-dish-main {
  min-width: 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.menu-dish-main img {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--surface-mid);
}

.menu-dish-main strong,
.menu-dish-main small,
.menu-dish-meta strong,
.menu-dish-meta small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu-dish-main strong {
  white-space: nowrap;
  font-size: 14px;
}

.menu-dish-main small,
.menu-dish-meta small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.menu-dish-meta {
  min-width: 0;
}

.menu-dish-meta strong {
  white-space: nowrap;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.menu-price-cell {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
}

.menu-price-cell input {
  min-width: 0;
  min-height: 42px;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: 11px;
  background: var(--surface-low);
  color: var(--ink);
  font-weight: 950;
}

.menu-price-cell small {
  color: var(--muted);
  font-weight: 950;
}

.danger-soft {
  color: var(--red);
}

.danger-soft:hover {
  border-color: rgba(201, 42, 47, 0.34);
  background: var(--red-soft);
}

.menu-library-toolbar {
  flex: 0 0 auto;
}

.menu-library-list {
  display: grid;
  gap: 8px;
  padding: 14px;
  grid-auto-rows: max-content;
}

.menu-candidate-row {
  min-width: 0;
  min-height: 74px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 9px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.menu-candidate-row:hover {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.menu-candidate-price {
  display: grid;
  grid-template-columns: auto 42px;
  gap: 8px;
  align-items: center;
}

.menu-candidate-price strong {
  color: var(--ink);
  font-size: 13px;
  white-space: nowrap;
}

.dish-catalog-panel {
  min-width: 0;
  overflow: hidden;
}

.menu-section-dishes .dish-catalog-panel,
.menu-section-dishes .dish-editor {
  align-self: stretch;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.menu-section-dishes .dish-editor {
  position: static;
  top: auto;
}

.menu-section-dishes .dish-catalog-panel > .panel-head,
.menu-section-dishes .dish-stat-grid,
.menu-section-dishes .dish-toolbar,
.menu-section-dishes .dish-editor > .panel-head {
  flex: 0 0 auto;
}

.dish-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 12px 14px 0;
}

.dish-stat {
  min-height: 66px;
  min-width: 0;
  padding: 11px 12px;
  border: 1.5px solid var(--outline);
  border-radius: 12px;
  background: var(--surface-low);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto;
  grid-template-areas:
    "value"
    "label";
  row-gap: 5px;
  align-content: center;
  align-items: center;
  justify-items: center;
  text-align: center;
}

.dish-stat strong {
  grid-area: value;
  min-width: 0;
  max-width: 100%;
  justify-self: center;
  font-family: var(--font-body);
  font-size: 24px;
  line-height: 1;
  color: var(--ink);
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reservation-summary-grid .dish-stat {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto auto;
  grid-template-areas:
    "value"
    "label"
    "note";
  justify-items: center;
  row-gap: 4px;
  column-gap: 0;
  padding: 9px 12px;
  text-align: center;
}

.reservation-summary-grid .dish-stat strong {
  min-width: 0;
  max-width: 100%;
  font-size: 26px;
}

.reservation-summary-grid .dish-stat-label,
.reservation-summary-grid .dish-stat-note-control {
  max-width: 100%;
  text-align: center;
}

.dish-stat-label {
  grid-area: label;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
  font-size: 13px;
  line-height: 18px;
  font-weight: 900;
}

.dish-stat-note-control {
  display: none !important;
}

.stat-note-btn {
  width: 20px;
  height: 20px;
  min-height: 20px;
  color: var(--muted);
}

.stat-note-btn .material-symbols-outlined {
  font-size: 17px;
}

.stat-note-popover {
  width: 220px;
  top: calc(100% + 8px);
  right: auto;
  bottom: auto;
  left: 0;
  z-index: 35;
  text-align: left;
}

.reservation-summary-grid .dish-stat-label {
  font-size: 15px;
  line-height: 18px;
}

.reservation-summary-grid .dish-stat-note-control {
  justify-self: center;
}

.reservation-summary-grid .stat-note-popover {
  left: 50%;
  transform: translateX(-50%);
}

.dish-toolbar {
  display: grid;
  gap: 12px;
  padding: 14px 14px 0;
}

.dish-search {
  min-height: 54px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.dish-search .material-symbols-outlined {
  color: var(--muted);
}

.dish-search input {
  border: 0;
  outline: 0;
  min-width: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 800;
}

.dish-category-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dish-db-list {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  overflow: hidden;
}

.menu-section-dishes .dish-db-list {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  grid-auto-rows: max-content;
}

.dish-db-header,
.dish-db-row {
  display: grid;
  grid-template-columns: minmax(150px, 1.35fr) minmax(118px, 1fr) minmax(82px, 0.62fr) minmax(86px, 0.68fr);
  gap: 8px;
  align-items: center;
}

.dish-db-header {
  min-height: 38px;
  padding: 0 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.dish-db-row {
  min-width: 0;
  min-height: 88px;
  padding: 8px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
  align-items: start;
}

.dish-db-row:hover,
.dish-db-row.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.dish-db-row.inactive {
  background: var(--surface-low);
}

.dish-db-main {
  min-width: 0;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.dish-db-main img {
  width: 46px;
  height: 46px;
  border-radius: 9px;
  object-fit: cover;
  background: var(--surface-mid);
}

.dish-db-main strong,
.dish-db-main small,
.dish-db-stack strong,
.dish-db-stack small,
.dish-db-state small {
  display: block;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dish-db-main strong {
  white-space: nowrap;
  font-size: 14px;
}

.dish-db-main small,
.dish-db-stack small,
.dish-db-state small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.35;
  white-space: nowrap;
}

.dish-db-stack small.dish-db-ingredients {
  display: -webkit-box;
  overflow: hidden;
  text-overflow: clip;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow-wrap: anywhere;
  line-height: 1.32;
}

.dish-db-stack {
  min-width: 0;
}

.dish-db-stack strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.dish-db-stack em {
  margin-left: 6px;
  color: var(--green);
  font-style: normal;
  font-size: 12px;
}

.dish-db-state {
  min-width: 0;
  display: grid;
  justify-items: start;
  gap: 1px;
}

.dish-status-inline {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 11px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dish-status-inline.out {
  background: var(--red-soft);
  color: var(--red);
}

.dish-status-inline.hidden {
  background: var(--surface-mid);
  color: var(--muted);
}

.stock-risk {
  color: var(--red) !important;
}

.menu-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.menu-grid.managed {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.menu-card {
  min-height: 292px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  overflow: hidden;
  display: grid;
  grid-template-rows: 138px 1fr;
  text-align: left;
  color: var(--ink);
  box-shadow: none;
  transition: border-color 0.16s ease, transform 0.16s ease, background 0.16s ease;
}

.menu-card:hover {
  border-color: var(--primary);
  transform: translateY(-1px);
}

.menu-card.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.menu-card.inactive,
.menu-card.sold-out {
  background: var(--surface-low);
}

.dish-image-wrap {
  position: relative;
  min-width: 0;
}

.dish-image {
  width: 100%;
  height: 138px;
  object-fit: cover;
  background: var(--surface-mid);
}

.dish-status {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(68, 34, 18, 0.1);
}

.dish-status.live {
  color: var(--green);
}

.dish-status.out {
  color: var(--red);
}

.dish-status.hidden {
  color: var(--muted);
}

.dish-body {
  padding: 12px;
  display: grid;
  gap: 8px;
}

.dish-body h4 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 20px;
  line-height: 24px;
}

.dish-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

.allergen-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dish-channel-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dish-channel-row span,
.muted-mini {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-mid);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.dish-editor {
  grid-column: 2;
  min-width: 0;
  overflow: hidden;
  position: sticky;
  top: 16px;
}

.dish-editor-scrim {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(44, 25, 15, 0.28);
  backdrop-filter: blur(12px);
}

.dish-editor-modal {
  width: min(980px, calc(100vw - 48px));
  height: min(880px, calc(100vh - 48px));
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
  border-radius: 18px;
  background: var(--white);
  box-shadow: 0 18px 50px rgba(54, 31, 18, 0.16);
}

.dish-editor-modal-head {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px 16px;
  border-bottom: 1.5px solid var(--outline);
}

.dish-editor-modal-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: 26px;
  line-height: 1.1;
}

.dish-editor-modal-head p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
  line-height: 1.35;
}

.dish-editor-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dish-editor-modal-body {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  grid-auto-rows: max-content;
  padding: 18px 22px 22px;
}

.dish-editor-modal .dish-editor-hero {
  min-height: 112px;
  grid-template-columns: 112px minmax(0, 1fr);
  padding: 14px;
  background: linear-gradient(135deg, rgba(255, 246, 233, 0.9), rgba(255, 255, 255, 0.96));
}

.dish-editor-modal .dish-editor-hero img {
  width: 112px;
  height: 84px;
}

.dish-editor-modal .dish-editor-hero strong {
  font-size: 22px;
  line-height: 1.15;
}

.dish-editor-section-card {
  padding: 14px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.dish-editor-modal .dish-editor-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dish-editor-modal .dish-editor-grid .span-2 {
  grid-column: 1 / -1;
}

.dish-editor-modal .field textarea {
  min-height: 96px;
  resize: vertical;
}

.dish-menu-price-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.dish-menu-price-card {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.dish-menu-price-card span {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dish-menu-price-card input {
  min-width: 0;
  min-height: 48px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: 12px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-weight: 900;
}

.dish-editor-modal-footer {
  min-height: 76px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 22px;
  border-top: 1.5px solid var(--outline);
  background: rgba(255, 252, 247, 0.96);
}

@media (max-width: 760px) {
  .dish-editor-scrim {
    padding: 12px;
  }

  .dish-editor-modal {
    width: calc(100vw - 24px);
    height: calc(100vh - 24px);
    border-radius: 16px;
  }

  .dish-editor-modal-head,
  .dish-editor-modal-body,
  .dish-editor-modal-footer {
    padding-inline: 14px;
  }

  .dish-editor-modal-head {
    align-items: flex-start;
  }

  .dish-editor-modal .dish-editor-grid,
  .dish-menu-price-grid {
    grid-template-columns: 1fr;
  }

  .dish-editor-modal .dish-editor-hero {
    grid-template-columns: 82px minmax(0, 1fr);
  }

  .dish-editor-modal .dish-editor-hero img {
    width: 82px;
    height: 66px;
  }

  .dish-editor-modal-footer {
    justify-content: stretch;
  }

  .dish-editor-modal-footer .btn {
    flex: 1 1 0;
  }
}

.dish-editor-body {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.menu-section-dishes .dish-editor-body {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  grid-auto-rows: max-content;
}

.dish-editor-preview {
  min-height: 92px;
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.dish-editor-preview img {
  width: 86px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--surface-mid);
}

.dish-editor-preview strong,
.dish-editor-preview span {
  display: block;
}

.dish-editor-preview strong {
  font-size: 17px;
  line-height: 22px;
}

.dish-editor-preview span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.dish-editor-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.dish-editor-grid .span-2 {
  grid-column: 1 / -1;
}

.dish-image-field small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.dish-image-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: stretch;
}

.dish-upload-btn {
  min-height: 54px;
  white-space: nowrap;
  cursor: pointer;
}

.stock-stepper {
  min-height: 54px;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
}

.stock-stepper button {
  display: grid;
  place-items: center;
  background: var(--surface-low);
  color: var(--ink);
}

.stock-stepper input {
  min-width: 0;
  border: 0;
  border-left: 1.5px solid var(--outline);
  border-right: 1.5px solid var(--outline);
  border-radius: 0;
  text-align: center;
}

.editor-section {
  display: grid;
  gap: 8px;
}

.editor-section > strong {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.dish-pdf-rule {
  padding: 12px;
  border: 1.5px dashed var(--outline-strong);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.dish-rule-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.dish-rule-card {
  min-height: 86px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1.5px solid var(--outline);
}

.dish-rule-card span,
.dish-rule-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
}

.dish-rule-card strong {
  color: var(--primary);
  font-size: 14px;
}

.toggle-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.toggle-chip {
  min-height: 38px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-weight: 900;
}

.toggle-chip.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.menu-assignment-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.menu-price-grid {
  grid-template-columns: 1fr;
}

.menu-price-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 126px;
  gap: 8px;
  align-items: stretch;
  padding: 8px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.menu-price-row.active {
  border-color: rgba(201, 78, 34, 0.42);
  background: var(--primary-dim);
}

.menu-assignment {
  min-height: 54px;
  padding: 8px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.menu-assignment.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
  box-shadow: var(--shadow-selected);
}

.menu-assignment strong,
.menu-assignment span {
  display: block;
}

.menu-assignment span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.shared-menu-panel {
  grid-column: 1 / -1;
}

.shared-menu-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 14px 0;
}

.shared-menu-flow div {
  min-height: 82px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.shared-menu-flow strong {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--primary);
  color: var(--white);
  font-family: var(--font-body);
}

.shared-menu-flow span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.35;
}

.shared-policy-table,
.invoice-table {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.shared-policy-row,
.invoice-row {
  display: grid;
  gap: 10px;
  align-items: center;
  min-height: 54px;
  padding: 10px 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  font-size: 12px;
  font-weight: 850;
}

.shared-policy-row {
  grid-template-columns: minmax(150px, 0.8fr) minmax(140px, 0.8fr) 100px minmax(0, 1.5fr);
}

.shared-policy-row.header,
.invoice-row.header {
  min-height: 36px;
  color: var(--muted);
  background: transparent;
  border-color: transparent;
  text-transform: uppercase;
  font-size: 11px;
}

.shared-policy-row em,
.invoice-row em {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--amber-soft);
  color: #8a5c00;
  font-style: normal;
  font-weight: 900;
}

.shared-policy-row em.ok {
  background: var(--green-soft);
  color: var(--green);
}

.shared-control-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
  gap: 14px;
  padding: 14px;
}

.shared-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 34px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 950;
}

.shared-section-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.shared-section-head.sub {
  margin-top: 12px;
}

.shared-policy-cards,
.shared-permission-panel,
.shared-store-preview,
.shared-local-card {
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  padding: 12px;
}

.shared-policy-cards {
  display: grid;
  align-content: start;
  gap: 9px;
}

.shared-policy-card {
  min-height: 98px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
  box-shadow: none;
}

.shared-policy-card.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  box-shadow: var(--shadow-selected);
}

.shared-policy-card strong,
.shared-policy-card small {
  display: block;
}

.shared-policy-card small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.35;
}

.shared-policy-card em {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--amber-soft);
  color: #8a5c00;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
}

.shared-policy-card em.ok {
  background: var(--green-soft);
  color: var(--green);
}

.shared-permission-panel {
  min-width: 0;
}

.shared-permission-grid {
  display: grid;
  gap: 8px;
}

.shared-permission-grid.hub {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.shared-permission-grid.operation {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 10px;
}

.shared-permission-toggle {
  min-height: 52px;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-start;
  padding: 8px 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
  text-align: left;
}

.shared-permission-toggle .material-symbols-outlined {
  color: var(--muted);
  font-size: 20px;
}

.shared-permission-toggle.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.shared-permission-toggle.active .material-symbols-outlined {
  color: var(--primary);
}

.shared-permission-toggle.inherited-lock {
  border-color: var(--amber);
  background: var(--amber-soft);
  color: #8a5c00;
}

.shared-operation-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.shared-operation-tabs button {
  min-height: 38px;
  white-space: nowrap;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: 999px;
  background: var(--white);
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.shared-operation-tabs button.active {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--white);
}

.shared-warning-line {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding: 9px 10px;
  border-radius: var(--radius);
  background: var(--primary-dim);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
}

.shared-store-preview {
  margin: 0 14px 14px;
}

.shared-preview-layout {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 12px;
}

.shared-category-rail {
  display: grid;
  align-content: start;
  gap: 8px;
}

.shared-category-rail button {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 950;
}

.shared-category-rail button.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.shared-table-wrap {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.shared-store-table {
  display: grid;
  grid-template-columns: minmax(170px, 1.3fr) repeat(7, minmax(74px, 0.72fr)) minmax(82px, 0.7fr);
  gap: 7px;
  align-items: stretch;
}

.shared-store-table.header {
  min-height: 32px;
  align-items: center;
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
}

.shared-store-table.row {
  width: 100%;
  min-height: 66px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.shared-store-table.row.selected .shared-cell,
.shared-store-table.row.selected > span:first-child,
.shared-store-table.row.selected > span:last-child {
  border-color: var(--primary);
}

.shared-store-table.row > span,
.shared-cell {
  min-width: 0;
  display: grid;
  align-content: center;
  min-height: 60px;
  padding: 8px 9px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  font-size: 12px;
  font-weight: 950;
}

.shared-store-table.row strong,
.shared-store-table.row small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shared-store-table.row small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.shared-cell.editable {
  border-color: var(--green);
  background: var(--green-soft);
  color: var(--green);
}

.shared-cell.locked {
  background: #f0ebe3;
  color: #8b8074;
}

.shared-cell.inherited-lock {
  border-color: var(--amber);
  background: var(--amber-soft);
  color: #8a5c00;
}

.shared-batch-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1.5px dashed var(--outline);
}

.shared-batch-bar span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.shared-local-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 14px;
  padding: 0 14px 14px;
}

.shared-local-card {
  display: grid;
  gap: 9px;
}

.shared-local-dish {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.shared-local-dish strong,
.shared-local-dish small {
  display: block;
}

.shared-local-dish small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.shared-local-dish em {
  color: var(--primary);
  font-style: normal;
  font-weight: 950;
}

.shared-local-card.rules ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.shared-local-card.rules li {
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.4;
}

.shared-dialog-scrim {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(38, 23, 13, 0.32);
}

.shared-dialog {
  width: min(760px, calc(100vw - 44px));
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 14px;
}

.shared-dialog-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.shared-dialog-grid > div {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.shared-dialog-grid > div > strong {
  font-size: 13px;
  font-weight: 950;
}

.shared-store-pick {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 12px;
  font-weight: 950;
}

.shared-store-pick small {
  color: var(--muted);
  font-weight: 850;
}

.shared-store-pick.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.shared-dialog-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1.5px solid var(--outline);
}

.shared-dialog-footer span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.fiscal-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.4fr);
  gap: 18px;
}

.quick-ticket-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 14px 0;
}

.quick-ticket-chip {
  min-height: 42px;
  padding: 0 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.quick-ticket-chip.active {
  border-color: var(--primary);
  background: var(--primary-dim);
  color: var(--primary);
}

.quick-ticket-sale {
  margin: 14px;
  padding: 14px;
  display: grid;
  gap: 4px;
  border: 1.5px dashed var(--outline-strong);
  border-radius: var(--radius);
  background: var(--surface-low);
}

.quick-ticket-sale span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.invoice-row {
  grid-template-columns: minmax(180px, 1.15fr) minmax(120px, 0.8fr) minmax(180px, 1.1fr) 110px 100px 86px;
}

.invoice-archive-table .invoice-row {
  grid-template-columns: 1fr 0.9fr 1.4fr 0.8fr 0.8fr 0.9fr;
}

.invoice-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
}

.invoice-actions {
  display: flex;
  gap: 6px;
}

.invoice-actions .btn {
  min-height: 38px;
  padding: 0 10px;
}

.invoice-actions .locked {
  border-color: var(--outline);
  background: var(--surface-mid);
  color: var(--muted);
}

.menu-price-row label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.menu-price-row input {
  width: 100%;
  min-width: 0;
  height: 36px;
  min-height: 36px;
  padding: 0 9px;
  border: 1.5px solid var(--outline);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font-weight: 900;
}

.menu-price-row input:disabled {
  opacity: 0.45;
  background: var(--surface-mid);
}

.editor-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.editor-actions .btn {
  min-width: 0;
}

.allergen {
  min-height: 24px;
  padding: 4px 7px;
  border-radius: var(--radius);
  background: var(--blue-soft);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.report-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
}

.chart {
  min-height: 290px;
  padding: 18px;
  display: flex;
  align-items: end;
  gap: 12px;
  border-top: 1px solid var(--outline);
}

.bar {
  flex: 1;
  min-width: 26px;
  border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(180deg, var(--primary-hot), var(--primary));
  display: flex;
  align-items: start;
  justify-content: center;
  color: var(--white);
  font-size: 12px;
  font-weight: 900;
  padding-top: 8px;
}

.donut {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background:
    conic-gradient(var(--primary) 0 46%, var(--green) 46% 69%, var(--blue) 69% 85%, var(--amber) 85% 100%);
  margin: 18px auto;
  position: relative;
}

.donut::after {
  content: "";
  position: absolute;
  inset: 44px;
  border-radius: 50%;
  background: var(--white);
}

.inventory-row {
  min-height: 66px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--white);
}

.inventory-row strong,
.inventory-row span {
  display: block;
}

.inventory-row span {
  margin-top: 3px;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.settings-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.handoff-panel {
  grid-column: 1 / -1;
}

.handoff-list {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.contract-row {
  min-height: 76px;
  padding: 12px;
  border: 1.5px solid var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
  display: grid;
  align-content: space-between;
  gap: 8px;
}

.contract-row span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.contract-row strong,
.contract-row code {
  min-width: 0;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.toggle-row {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--outline);
}

.toggle-row:last-child {
  border-bottom: 0;
}

.toggle-row strong,
.toggle-row span {
  display: block;
}

.toggle-row span {
  color: var(--muted);
  margin-top: 3px;
  font-size: 13px;
  font-weight: 700;
}

.toggle-row .rule-badge {
  min-width: 94px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 0;
  padding: 0 10px;
  border: 1.5px solid var(--outline);
  border-radius: 11px;
  background: var(--surface-low);
  color: var(--muted);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62);
  white-space: nowrap;
}

.rule-badge .material-symbols-outlined {
  font-size: 18px;
}

.rule-badge em {
  font-style: normal;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.toggle-row .rule-badge.warn {
  background: #fff5dd;
  border-color: rgba(212, 134, 12, 0.28);
  color: #9b5d04;
}

.toggle-row .rule-badge.block {
  background: #ffeae5;
  border-color: rgba(201, 42, 47, 0.26);
  color: #9b292d;
}

.toggle-row .rule-badge.ok {
  background: #e9f6ed;
  border-color: rgba(42, 138, 78, 0.26);
  color: #246f43;
}

.toggle-row .rule-badge.neutral {
  background: #f4ece0;
  border-color: rgba(59, 31, 14, 0.14);
  color: var(--ink);
}

.switch {
  --switch-width: 52px;
  --switch-height: 30px;
  --switch-padding: 3px;
  --switch-thumb: 24px;
  width: var(--switch-width);
  height: var(--switch-height);
  min-height: var(--switch-height);
  flex: 0 0 var(--switch-width);
  border-radius: calc(var(--switch-height) / 2);
  padding: 0;
  background: #ded6ca;
  border: 0;
  position: relative;
  box-shadow: none;
  transition: background 0.18s ease, box-shadow 0.18s ease;
}

.switch.on {
  background: var(--primary);
  box-shadow: none;
}

.switch:hover {
  box-shadow: inset 0 0 0 1.5px rgba(59, 31, 14, 0.14);
}

.switch:active {
  transform: none;
}

.switch:focus-visible {
  outline: 3px solid rgba(201, 78, 34, 0.22);
  outline-offset: 2px;
}

.switch::after {
  content: "";
  width: var(--switch-thumb);
  height: var(--switch-thumb);
  border-radius: 50%;
  background: var(--white);
  border: 1px solid rgba(59, 31, 14, 0.12);
  position: absolute;
  left: var(--switch-padding);
  top: var(--switch-padding);
  box-shadow: none;
  transform: translateX(0);
  transition: transform 0.18s ease, border-color 0.18s ease;
}

.switch.on::after {
  transform: translateX(calc(var(--switch-width) - var(--switch-thumb) - var(--switch-padding) * 2));
}

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  min-width: 280px;
  max-width: 380px;
  min-height: 54px;
  display: none;
  align-items: center;
  gap: 10px;
  padding: 13px 16px;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--white);
  box-shadow: var(--shadow);
  font-weight: 800;
}

.toast.show {
  display: flex;
}

.empty-note {
  min-height: 180px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
  text-align: center;
  border: 1.5px dashed var(--outline);
  border-radius: var(--radius);
  background: var(--surface-low);
}

@media (max-width: 0px) {
  .layout {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .nav-collapse-btn {
    display: none;
  }

  .side-nav {
    padding: 16px 10px;
  }

  .brand {
    justify-content: center;
    padding: 0;
  }

  .brand h1,
  .brand p,
  .nav-btn span:not(.material-symbols-outlined),
  .store-card,
  .nav-footer .btn span:not(.material-symbols-outlined) {
    display: none;
  }

  .nav-btn {
    justify-content: center;
    padding: 0;
  }

  .floor-layout,
  .orders-layout,
  .reservations-layout,
  .menu-management-layout,
  .report-layout,
  .dashboard-layout,
  .settings-layout {
    grid-template-columns: 1fr;
  }

  .reservation-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reservation-card {
    grid-template-columns: 1fr;
  }

  .reservation-actions {
    justify-content: flex-start;
  }

  .dish-db-header,
  .dish-db-row {
    grid-template-columns: 1fr;
  }

  .receipt-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .menu-grid.managed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dish-editor {
    grid-column: auto;
    position: static;
  }

  .metric .metric-value {
    font-size: 30px;
    line-height: 36px;
  }
}

@media (max-width: 0px) {
  .receipt-panel {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  .reservation-day-panel .reservation-summary-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .reservation-card {
    grid-template-columns: 1fr;
  }

  .reservation-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 980px) {
  .reservation-overview-grid,
  .reservations-layout {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1500px) {
  .menu-management-layout {
    grid-template-columns: 280px minmax(0, 1fr) 420px;
  }

  .menu-admin-layout {
    grid-template-columns: 320px minmax(0, 1fr) 390px;
  }

  .menu-summary-strip,
  .menu-field-grid,
  .menu-channel-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .menu-management-layout.menu-section-dishes {
    grid-template-columns: minmax(0, 1fr);
  }

  .menu-management-layout.menu-section-menus {
    grid-template-columns: 320px minmax(0, 1fr);
  }

  .dish-editor {
    grid-column: auto;
    position: sticky;
    top: 16px;
  }

  .dish-stat-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .menu-grid.managed {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dish-editor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 0px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .side-nav {
    position: fixed;
    bottom: 0;
    top: auto;
    left: 0;
    right: 0;
    width: 100%;
    height: 116px;
    padding: 8px;
    border-right: 0;
    border-top: 1px solid var(--outline);
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    z-index: 10;
  }

  .brand,
  .nav-footer {
    display: none;
  }

  .nav-group {
    width: 100%;
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
  }

  .nav-btn {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    min-height: 48px;
    font-size: 11px;
    gap: 2px;
    flex-direction: column;
    padding: 4px;
  }

  .nav-btn span:not(.material-symbols-outlined) {
    display: none;
  }

  .main {
    padding-bottom: 124px;
  }

  .topbar {
    min-height: 156px;
    padding: 12px;
    align-items: stretch;
    flex-direction: column;
    overflow: visible;
  }

  .top-actions {
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .top-actions .language-menu {
    grid-column: auto;
  }

  .top-actions .icon-btn,
  .top-actions .profile-menu {
    width: 100%;
  }

  .profile-trigger {
    width: 100%;
  }

  .profile-popover {
    width: min(320px, calc(100vw - 24px));
    right: 0;
  }

  .top-actions .language-trigger,
  .top-actions .btn {
    width: 100%;
    min-width: 0;
  }

  .top-title h2 {
    font-size: 23px;
    line-height: 28px;
  }

  .top-title p {
    display: none;
  }

  .content {
    padding: 12px;
  }

  .grid-4,
  .grid-3,
  .grid-2,
  .reservation-summary-grid,
  .order-menu-tabs,
  .dish-stat-grid,
  .receipt-panel,
  .payment-chips,
  .quick-actions,
  .scenario-grid,
  .kds-lanes,
  .handoff-list,
  .menu-grid,
  .menu-grid.managed,
  .dish-editor-grid,
  .editor-actions {
    grid-template-columns: 1fr;
  }

  .reservation-inline-fields,
  .menu-price-row {
    grid-template-columns: 1fr;
  }

  .table-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .order-dish {
    grid-template-columns: 52px minmax(0, 1fr) 28px;
  }

  .order-dish-side {
    grid-column: 2 / 3;
    justify-self: start;
    text-align: left;
  }

  .order-dish > .material-symbols-outlined {
    grid-column: 3 / 4;
    grid-row: 1 / 3;
  }

  .table-board-panel {
    min-height: calc(100vh - 180px);
  }

  .table-drawer {
    top: 8px;
    left: 8px;
    right: 8px;
    bottom: 124px;
    width: auto;
    border: 1.5px solid var(--outline);
    border-radius: var(--radius);
    box-shadow: 0 10px 28px rgba(59, 31, 14, 0.16);
  }

  .drawer-head {
    min-height: 108px;
    padding: 14px;
    grid-template-columns: minmax(0, 1fr) 44px;
    gap: 10px;
  }

  .drawer-head h2 {
    font-size: 28px;
  }

  .drawer-head p {
    font-size: 13px;
  }

  .table-drawer-scroll {
    padding: 12px;
  }

  .compact-table-map {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .bill-line {
    grid-template-columns: minmax(0, 1fr) 44px 74px;
  }

  .bill-line.header {
    display: none;
  }

  .bill-line .hide-sm {
    display: none;
  }

  .doc-toggle,
  .calendar-grid {
    grid-template-columns: 1fr;
  }

  .order-row {
    grid-template-columns: 1fr auto;
  }

  .order-row .hide-sm {
    display: none;
  }

  .top-actions {
    width: 100%;
    min-width: 0;
    overflow: visible;
  }

  .top-actions .btn {
    display: inline-flex;
    padding: 0 8px;
    font-size: 15px;
  }

  .top-actions .language-menu,
  .top-actions .language-switcher {
    width: 100%;
  }

  .language-options {
    left: 0;
    right: auto;
  }
}

@media (max-width: 980px) {
  .floor-overlay-backdrop {
    padding: 10px;
  }

  .floor-modal.table-detail-modal {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
  }

  .table-detail-modal-body {
    grid-template-columns: 1fr;
    padding: 10px;
  }

  .table-detail-hero {
    min-height: 112px;
    padding: 16px;
  }

  .table-detail-hero strong {
    font-size: 42px;
  }

  .table-detail-modal .drawer-status-grid,
  .table-detail-modal .drawer-money-summary,
  .table-detail-modal .drawer-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .reservation-calendar-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .reservation-day-panel .reservation-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reservation-calendar-grid {
    gap: 4px;
    padding: 0 10px 10px;
  }

  .reservation-day {
    min-height: 48px;
    padding: 6px;
  }

  .touch-number-pad {
    left: 12px !important;
    right: 12px;
    top: auto !important;
    bottom: 12px;
    width: auto !important;
  }
}
