:root {
  color-scheme: light;
  --ink: #1d2329;
  --muted: #69727c;
  --line: #d7dde4;
  --panel: #ffffff;
  --app: #f5f7fb;
  --brand: #136f63;
  --brand-strong: #0f574e;
  --brand-soft: #e3f4ef;
  --amber: #c77800;
  --red: #b42318;
  --blue: #285ea8;
  --blue-soft: #eaf1fb;
  --shadow: 0 18px 42px rgba(26, 37, 52, 0.08);
}


* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  background: var(--app);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.modal-open {
  overflow: hidden;
}

body.app-busy {
  cursor: progress;
  user-select: none;
}

.app-loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(33, 22, 13, 0.36);
  backdrop-filter: blur(3px);
}

.app-loading-overlay[hidden] {
  display: none;
}

.app-loading-panel {
  width: min(320px, 100%);
  display: grid;
  justify-items: center;
  gap: 10px;
  border: 1px solid rgba(126, 78, 35, 0.18);
  border-radius: 8px;
  background: #fffaf3;
  box-shadow: 0 24px 70px rgba(35, 22, 12, 0.28);
  padding: 22px 20px;
  color: #2d2118;
  text-align: center;
}

.app-loading-panel strong {
  font-size: 15px;
}

.app-loading-panel small {
  color: #7d7066;
}

.app-loading-spinner {
  width: 34px;
  height: 34px;
  border: 3px solid #ead8c7;
  border-top-color: var(--brand, #6e3a16);
  border-radius: 999px;
  animation: app-spin 0.8s linear infinite;
}

button.is-loading,
input.is-loading {
  cursor: progress;
  opacity: 0.78;
}

@keyframes app-spin {
  to {
    transform: rotate(360deg);
  }
}

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

.form-grid [hidden] {
  display: none !important;
}

textarea {
  min-height: 76px;
  resize: vertical;
  padding: 10px;
  font: inherit;
  line-height: 1.45;
}

button,
a {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100vh;
  background: #161d1b;
  color: #f8fbfa;
  padding: 24px 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 8px;
  background: #f0b94c;
  color: #18211f;
  font-weight: 800;
}

.brand h1 {
  margin: 0;
  font-size: 18px;
}

.brand p,
.panel-heading p,
.metric small,
.form-note {
  margin: 4px 0 0;
  color: var(--muted);
}

.sidebar .brand p {
  color: #bfc9c5;
  font-size: 13px;
}

.nav-tabs {
  display: grid;
  gap: 18px;
}

.nav-group {
  display: grid;
  gap: 6px;
}

.nav-group-title {
  color: #8fa19c;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.nav-tab {
  position: relative;
  display: block;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #dce5e2;
  padding: 12px 14px;
  text-align: left;
  text-decoration: none;
  transition: background 150ms ease, color 150ms ease, transform 150ms ease;
}

.nav-tab.active,
.nav-tab:hover {
  background: #263632;
  color: #ffffff;
}

.nav-tab.active::before {
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: 6px;
  width: 3px;
  border-radius: 999px;
  background: #f0b94c;
  content: "";
}

.mapping-tabs {
  align-items: center;
  background: #fbf4ed;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: inline-flex;
  gap: 6px;
  padding: 6px;
  width: fit-content;
}

.mapping-tabs button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  padding: 9px 13px;
}

.mapping-tabs button.active {
  background: #6e3a16;
  color: #fffaf4;
}

.main {
  min-width: 0;
  padding: 28px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.topbar h2 {
  margin: 0;
  font-size: 28px;
}

.top-actions {
  display: flex;
  gap: 10px;
}

.primary-button,
.ghost-button,
.qty-button,
.icon-button {
  border: 1px solid transparent;
  border-radius: 8px;
  min-height: 42px;
  padding: 0 16px;
  font-weight: 700;
  transition: background 150ms ease, border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--brand);
  color: #ffffff;
  text-decoration: none;
}

.primary-button:hover {
  background: var(--brand-strong);
  box-shadow: 0 10px 18px rgba(19, 111, 99, 0.18);
}

.primary-button:disabled {
  cursor: not-allowed;
  background: #9aa5ad;
}

.ghost-button:disabled {
  cursor: not-allowed;
  border-color: #e5ddd5;
  background: #f5f1ed;
  color: #b1a399;
  box-shadow: none;
}

.ghost-button,
.qty-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.92);
  border-color: var(--line);
  color: var(--ink);
  text-decoration: none;
}

.ghost-button:hover,
.qty-button:hover {
  border-color: #aeb8c4;
  box-shadow: 0 8px 18px rgba(26, 37, 52, 0.08);
}

.full {
  width: 100%;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.executive-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 18px;
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
  margin-bottom: 18px;
  padding: 22px;
}

.inventory-command {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
  padding: 22px;
}

.inventory-command h3 {
  max-width: 760px;
  margin: 0;
  font-size: 26px;
  line-height: 1.2;
}

.inventory-command p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.inventory-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.hero-kicker {
  display: inline-flex;
  margin-bottom: 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.executive-hero h3 {
  max-width: 760px;
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
}

.executive-hero p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.hero-score {
  display: grid;
  align-content: center;
  border-radius: 8px;
  background: #18211f;
  color: #ffffff;
  padding: 18px;
}

.hero-score span,
.hero-score small {
  color: #bfc9c5;
}

.hero-score strong {
  display: block;
  margin: 8px 0;
  color: #f0b94c;
  font-size: 42px;
  line-height: 1;
}

.metric,
.workspace-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.metric {
  position: relative;
  overflow: hidden;
  padding: 18px;
}

.metric::after {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 72px;
  height: 4px;
  background: var(--brand);
  content: "";
}

.metric span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.metric strong {
  display: block;
  margin-top: 10px;
  font-size: 26px;
}

.metric.alert strong {
  color: var(--red);
}

.content-grid,
.pos-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 18px;
}

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

.wide {
  grid-column: 1 / -1;
}

.workspace-panel {
  min-width: 0;
  padding: 20px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.panel-heading h3 {
  margin: 0;
  font-size: 18px;
}

.panel-heading p {
  font-size: 13px;
}

.table-wrap {
  overflow-x: auto;
}

.filter-toolbar {
  display: grid;
  grid-template-columns: repeat(6, minmax(120px, 1fr));
  gap: 10px;
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf4;
}

.filter-toolbar label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.filter-toolbar input,
.filter-toolbar select {
  min-width: 0;
}

.filter-toolbar .compact-button {
  align-self: end;
  min-height: 38px;
}

.compact-filter {
  grid-template-columns: minmax(180px, 1.5fr) repeat(4, minmax(110px, 1fr)) auto;
}

.order-history-toolbar {
  align-items: start;
  gap: 14px;
}

.order-history-filter {
  width: min(760px, 100%);
  grid-template-columns: minmax(120px, .8fr) minmax(140px, .9fr) minmax(150px, 1fr) minmax(220px, 1.4fr);
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.order-history-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}

.order-history-card {
  position: relative;
  display: grid;
  min-height: 96px;
  align-content: space-between;
  gap: 8px;
  overflow: hidden;
  border: 1px solid #eadfd5;
  border-radius: 8px;
  background: linear-gradient(180deg, #fff 0%, #fffaf5 100%);
  padding: 14px 15px;
  box-shadow: 0 10px 24px rgba(73, 42, 22, 0.06);
}

.order-history-card::after {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(var(--brand-rgb, 110, 58, 22), 0.11);
  content: "";
}

.order-history-card span {
  color: #7a695d;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.order-history-card strong {
  display: block;
  max-width: calc(100% - 32px);
  color: #2f2118;
  font-size: 21px;
  line-height: 1.15;
}

.order-history-card strong em {
  color: #a18e7f;
  font-style: normal;
  font-weight: 700;
}

.order-history-card small {
  color: #8d7c70;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.35;
}

.order-history-card.warning-card strong {
  color: #9a5522;
}

.order-history-card.revenue-card strong {
  color: var(--brand);
}

.order-history-card.date-card strong {
  font-size: 17px;
}

.order-history-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px;
  border: 1px solid #eadfd5;
  border-radius: 8px;
  background: #fffaf5;
}

.order-history-tabs button {
  min-height: 34px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: #6d5c4f;
  padding: 0 12px;
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
}

.order-history-tabs button.active {
  border-color: rgba(var(--brand-rgb, 110, 58, 22), 0.18);
  background: var(--brand);
  color: #fff;
  box-shadow: 0 8px 16px rgba(75, 38, 15, 0.12);
}

.order-history-table {
  min-width: 1080px;
}

.order-history-table .status-pill {
  white-space: nowrap;
}

.order-history-open-row td:first-child {
  border-left: 3px solid var(--brand);
}

.order-history-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.order-history-followup-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 12px 0;
  border: 1px solid #eadfd5;
  border-radius: 8px;
  background: #fffaf5;
  padding: 13px 14px;
}

.order-history-followup-panel.needs-action {
  border-color: rgba(var(--brand-rgb, 110, 58, 22), 0.24);
  background: linear-gradient(135deg, rgba(var(--brand-rgb, 110, 58, 22), 0.08), #fffaf5 62%);
}

.order-history-followup-panel span {
  display: block;
  color: #7d6b5d;
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.order-history-followup-panel strong {
  display: block;
  margin-top: 4px;
  color: #2f2118;
  font-size: 15px;
}

.order-history-followup-panel p {
  max-width: 640px;
  margin: 5px 0 0;
  color: #75675d;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.45;
}

.datatable-shell {
  display: grid;
  gap: 12px;
}

.datatable-toolbar,
.datatable-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.datatable-toolbar label {
  width: min(320px, 100%);
}

.datatable-actions,
.datatable-pagination {
  display: flex;
  align-items: center;
  gap: 8px;
}

.datatable-pagination span,
.datatable-info {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 14px 12px;
  text-align: left;
  vertical-align: top;
}

th {
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

tbody tr:hover {
  background: #fbfcff;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
}

.status-pill small {
  font-size: 10px;
  font-weight: 900;
  opacity: 0.72;
}

.status-ok {
  background: #dff3ee;
  color: var(--brand-strong);
}

.status-low {
  background: #fff1d6;
  color: var(--amber);
}

.status-warning {
  color: #8a4b08;
  background: #fff2cf;
  border-color: #e7c56c;
}

.status-pending_cashier,
.status-waiting,
.status-00,
.status-10 {
  background: #fff1d6;
  color: #8a4b08;
}

.status-preparing,
.status-20 {
  background: #e8f0ff;
  color: #1d4f91;
}

.status-ready,
.status-completed,
.status-30,
.status-90 {
  background: #dff3ee;
  color: #116149;
}

.status-cancelled,
.status-99 {
  background: #fee2e2;
  color: #991b1b;
}

.onboarding-progress-row {
  display: grid;
  gap: 8px;
}

.onboarding-progress-copy {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.onboarding-progress-track {
  height: 10px;
  overflow: hidden;
  background: #ece6df;
  border-radius: 5px;
}

.onboarding-progress-track span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--brand);
  transition: width 220ms ease;
}

.onboarding-step-list {
  display: grid;
  gap: 0;
}

.onboarding-guide-panel {
  padding: 0;
  overflow: hidden;
}

.onboarding-guide-panel > .form-feedback {
  margin: 0;
  padding: 0 20px 14px;
}

.onboarding-step-section {
  padding: 18px 20px 6px;
}

.onboarding-step-section.optional {
  border-top: 8px solid #f4eee8;
  background: #fcfaf8;
}

.onboarding-step-section .panel-heading {
  align-items: center;
  margin-bottom: 4px;
}

.onboarding-step.next-required {
  margin-inline: -10px;
  padding-inline: 10px;
  border-left: 3px solid var(--brand);
  background: #fffaf4;
}

.onboarding-step {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.onboarding-step:last-child {
  border-bottom: 0;
}

.onboarding-step-index {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #d8c9bb;
  border-radius: 6px;
  color: var(--brand);
  font-size: 11px;
  font-weight: 800;
}

.onboarding-step.completed .onboarding-step-index {
  color: #17633a;
  background: #e5f5eb;
  border-color: #a7d4b6;
}

.onboarding-step-copy {
  min-width: 0;
}

.onboarding-step-copy > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.onboarding-step-copy p,
.onboarding-step-copy small {
  margin: 3px 0 0;
  color: var(--muted);
}

@media (max-width: 720px) {
  .onboarding-step-section {
    padding-inline: 14px;
  }

  .onboarding-step {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .onboarding-step > a,
  .onboarding-step > button {
    grid-column: 2;
    justify-self: start;
  }
}

.status-empty {
  background: #ffe4e0;
  color: var(--red);
}

.flow-list {
  margin: 0;
  padding-left: 20px;
  color: #40464d;
  line-height: 1.65;
}

.recommendation-list {
  display: grid;
  gap: 10px;
}

.recommendation-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
  padding: 12px;
}

.recommendation-item strong,
.recommendation-item span {
  display: block;
}

.recommendation-item span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.module-value-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.module-value-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
  padding: 14px;
}

.module-value-grid span {
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.module-value-grid strong {
  display: block;
  margin-top: 8px;
}

.module-value-grid p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.coverage-bar {
  width: 100%;
  max-width: 170px;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e7ecf2;
  margin-bottom: 6px;
}

.coverage-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 12px;
}

.product-card {
  display: grid;
  gap: 10px;
  min-height: 152px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
  padding: 14px;
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.product-card:hover {
  border-color: #b9c4cf;
  box-shadow: 0 12px 24px rgba(26, 37, 52, 0.08);
  transform: translateY(-1px);
}

.product-card h4 {
  margin: 0;
  font-size: 16px;
}

.product-card .price {
  color: var(--blue);
  font-weight: 800;
}

.product-card small,
.recipe-line,
.empty-state {
  color: var(--muted);
}

.cart-list {
  display: grid;
  gap: 10px;
  min-height: 120px;
}

.cart-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.cart-row strong,
.cart-row span {
  display: block;
}

.qty-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty-button {
  width: 34px;
  min-height: 34px;
  padding: 0;
}

.icon-button {
  display: grid;
  width: 40px;
  min-height: 40px;
  place-items: center;
  background: #ffffff;
  border-color: var(--line);
  color: var(--ink);
  padding: 0;
}

.icon-button:hover {
  border-color: #aeb8c4;
  box-shadow: 0 8px 18px rgba(26, 37, 52, 0.08);
}

.cart-summary {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.cart-summary div {
  display: flex;
  justify-content: space-between;
}

.cart-summary .total {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  font-size: 18px;
}

.form-grid {
  display: grid;
  gap: 14px;
}

.form-panel {
  max-width: 860px;
}

.split-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  align-items: end;
}

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

.input-workflow {
  border-radius: 8px;
  background: #f9fbfd;
  border: 1px solid #e4e9ef;
  padding: 16px;
}

.full-row {
  grid-column: 1 / -1;
}

.inline-input-action {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

label {
  display: grid;
  gap: 7px;
  color: #333940;
  font-size: 13px;
  font-weight: 700;
}

input,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  min-height: 46px;
  padding: 0 13px;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

input:focus,
select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(19, 111, 99, 0.13);
}

input::placeholder {
  color: #98a2ad;
}

.form-preview,
.form-feedback {
  margin: 0;
  border-radius: 8px;
  padding: 11px 12px;
  font-size: 13px;
  line-height: 1.45;
}

.form-preview {
  background: var(--blue-soft);
  color: #264b76;
}

.form-feedback {
  display: none;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-weight: 700;
}

.form-feedback.show {
  display: block;
}

.logo-upload-field {
  gap: 8px;
}

.logo-upload-control {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fffaf4;
  padding: 8px;
}

.logo-preview {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  overflow: hidden;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-weight: 800;
}

.logo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.logo-upload-control input[type="file"] {
  min-width: 0;
  padding: 9px;
  background: #fff;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  background: rgba(18, 27, 25, 0.58);
  padding: 24px;
}

.modal-backdrop[hidden],
.modal-dialog[hidden] {
  display: none;
}

.modal-dialog {
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 28px 80px rgba(12, 18, 22, 0.28);
  padding: 20px;
}

.modal-dialog-wide {
  width: min(980px, 100%);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.modal-header h3 {
  margin: 0;
  font-size: 22px;
}

.modal-header p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

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

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

.compact-button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.quick-action {
  display: grid;
  gap: 5px;
  min-height: 86px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  padding: 14px;
  text-align: left;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.quick-action:hover {
  border-color: #b9c4cf;
  box-shadow: 0 14px 28px rgba(26, 37, 52, 0.1);
  transform: translateY(-1px);
}

.quick-action span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.quick-action strong {
  font-size: 15px;
}

.product-list {
  display: grid;
  gap: 12px;
}

.recipe-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 16px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.recipe-card:hover {
  border-color: #b9c4cf;
  box-shadow: 0 12px 24px rgba(26, 37, 52, 0.08);
}

.recipe-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.recipe-card h4 {
  margin: 0 0 4px;
}

.recipe-card strong {
  color: var(--brand);
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 5;
    padding: 14px;
  }

  .brand {
    margin-bottom: 14px;
  }

  .nav-tabs {
    display: flex;
    overflow-x: auto;
  }

  .nav-group {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .nav-group-title {
    flex: 0 0 auto;
    padding: 0 4px;
  }

  .nav-tab {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .metric-grid,
  .executive-hero,
  .inventory-command,
  .module-value-grid,
  .quick-actions,
  .content-grid,
  .pos-layout,
  .two-column-form,
  .split-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .main {
    padding: 16px;
  }

  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .top-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .datatable-toolbar,
  .datatable-footer,
  .datatable-actions,
  .datatable-pagination {
    align-items: stretch;
    display: grid;
  }

  .inventory-actions {
    display: grid;
  }

  .metric strong {
    font-size: 22px;
  }

  .panel-heading,
  .recipe-card header,
  .modal-header {
    display: block;
  }

  .modal-actions {
    display: grid;
  }

  .row-actions {
    display: grid;
  }
}

/* POS counter experience */
body[data-page="pos"] .main {
  background: #fbfaf8;
}

body[data-page="pos"] .topbar {
  margin-bottom: 12px;
}

body[data-page="pos"] .pos-command-bar {
  width: 100%;
  grid-template-columns: 145px 130px 150px minmax(170px, 1fr) 86px 106px 104px 78px;
  gap: 8px;
  border-color: #e7ddd4;
  padding: 8px;
}

body[data-page="pos"] .service-modes {
  grid-column: 1;
  min-width: 0;
}

body[data-page="pos"] .pos-table-select {
  grid-column: 2;
  min-width: 0;
}

body[data-page="pos"] .pos-pickup-name {
  grid-column: 3;
  min-width: 0;
}

body[data-page="pos"] .pos-search {
  grid-column: 4;
  min-width: 0;
}

body[data-page="pos"] #open-pos-queue {
  grid-column: 5;
}

body[data-page="pos"] #open-pos-approvals {
  grid-column: 6;
}

body[data-page="pos"] #open-pos-tables {
  grid-column: 7;
}

body[data-page="pos"] .order-reference {
  grid-column: 8;
  min-width: 0;
}

body[data-page="pos"] .pos-command-bar input,
body[data-page="pos"] .pos-command-bar select,
body[data-page="pos"] .pos-command-bar button {
  width: 100%;
  min-width: 0;
}

body[data-page="pos"] .pos-command-bar [hidden] {
  display: none;
}

.pos-table-select,
.pos-search {
  font-size: 0;
}

.pos-table-select select,
.pos-search input {
  min-height: 34px;
  border-color: #e9e0d8;
  background: #fcfbfa;
}

body[data-page="pos"] .pos-layout {
  grid-template-columns: minmax(0, 1fr) minmax(350px, 400px);
  align-items: start;
  gap: 12px;
}

body[data-page="pos"] .product-browser {
  min-height: calc(100vh - 160px);
  padding: 14px;
}

body[data-page="pos"] .pos-category-tabs {
  gap: 6px;
  border-bottom: 0;
  margin: -4px -4px 10px;
  background: transparent;
  padding: 0;
}

body[data-page="pos"] .pos-category-tabs button {
  min-height: 30px;
  border: 1px solid transparent;
  border-radius: 5px;
  padding: 0 11px;
}

body[data-page="pos"] .pos-category-tabs button.active {
  border-color: #744017;
  background: #744017;
  color: #ffffff;
}

body[data-page="pos"] .pos-category-tabs button.active::after {
  display: none;
}

.pos-browser-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid #eee7e1;
  padding: 12px 0;
}

.pos-browser-heading strong,
.pos-browser-heading span {
  display: block;
}

.pos-browser-heading strong {
  font-size: 12px;
}

.pos-browser-heading div span {
  margin-top: 3px;
  color: #887a70;
  font-size: 9px;
}

body[data-page="pos"] .product-grid {
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 10px;
}

body[data-page="pos"] .product-card {
  display: grid;
  grid-template-rows: 104px 1fr auto;
  gap: 0;
  min-height: 208px;
  overflow: hidden;
  border-color: #e8dfd7;
  border-radius: 6px;
  padding: 0;
}

body[data-page="pos"] .product-card:hover {
  border-color: #c89f7f;
  box-shadow: 0 12px 26px rgba(91, 51, 21, 0.12);
  transform: translateY(-2px);
}

body[data-page="pos"] .product-card-soldout {
  border-color: #eadfd5;
  background: #f6f0eb;
  opacity: 0.72;
}

body[data-page="pos"] .product-card-soldout:hover {
  border-color: #eadfd5;
  box-shadow: none;
  transform: none;
}

body[data-page="pos"] .product-card-soldout .product-visual img,
body[data-page="pos"] .product-card-soldout .product-visual > span:first-child {
  filter: grayscale(0.85);
  opacity: 0.62;
}

body[data-page="pos"] .product-visual {
  position: relative;
  height: 104px;
  border-radius: 0;
  background: linear-gradient(145deg, #b97d48, #48240e);
}

body[data-page="pos"] .product-tone-1 {
  background: linear-gradient(145deg, #d3a16d, #6d3818);
}

body[data-page="pos"] .product-tone-2 {
  background: linear-gradient(145deg, #9d653b, #2e1b11);
}

body[data-page="pos"] .product-tone-3 {
  background: linear-gradient(145deg, #d9b58e, #79451e);
}

body[data-page="pos"] .product-visual > span:first-child {
  width: 70px;
  height: 70px;
  border-width: 7px;
}

.product-stock-badge {
  position: absolute;
  top: 7px;
  right: 7px;
  width: auto !important;
  height: auto !important;
  border: 0 !important;
  border-radius: 4px !important;
  background: rgba(255, 255, 255, 0.88) !important;
  box-shadow: none !important;
  color: #5b3418;
  padding: 3px 5px;
  font-size: 8px;
  font-weight: 800;
}

.product-stock-badge-soldout {
  background: #fff1f0 !important;
  color: #b42318 !important;
  text-transform: uppercase;
}

.product-card-copy {
  padding: 10px 10px 7px;
}

.product-category-label {
  color: #a06d44;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

body[data-page="pos"] .product-card h4 {
  min-height: 30px;
  margin: 4px 0 2px;
  font-size: 11px;
  line-height: 1.35;
}

body[data-page="pos"] .product-card .price {
  font-size: 11px;
  font-weight: 850;
}

.product-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #eee7e1;
  padding: 7px 9px;
}

body[data-page="pos"] .product-detail-button {
  text-decoration: none;
}

body[data-page="pos"] .product-card .product-add-button {
  position: static;
  width: 26px;
  height: 26px;
  background: #754016;
  color: #ffffff;
}

body[data-page="pos"] .product-card-soldout .product-add-button,
body[data-page="pos"] .product-card-soldout .product-add-button:disabled {
  cursor: not-allowed;
  background: #d9cfc6;
  color: #8d8177;
  opacity: 1;
}

body[data-page="pos"] .cart-panel {
  position: sticky;
  top: 12px;
  display: flex;
  min-height: calc(100vh - 160px);
  flex-direction: column;
}

.active-open-table-context[hidden] {
  display: none;
}

.active-open-table-context span,
.active-open-table-context small {
  display: block;
  color: #7b5d43;
  font-size: 8px;
  font-weight: 800;
}

.active-open-table-context strong {
  display: block;
  margin: 2px 0;
  color: #54290d;
  font-size: 11px;
}

.active-open-table-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.danger-button {
  border-color: #e4b5aa;
  background: #fff3ef;
  color: #9b321d;
}

.cart-count-badge {
  border-radius: 4px;
  background: #f4ebe3;
  color: #754016;
  padding: 4px 7px;
  font-size: 9px;
  font-weight: 800;
}

body[data-page="pos"] .cart-list {
  flex: 1;
  align-content: start;
  gap: 0;
  min-height: 150px;
  max-height: 350px;
  overflow-y: auto;
}

body[data-page="pos"] .cart-list > .empty-state {
  display: grid;
  min-height: 180px;
  place-items: center;
  border: 1px dashed #e5d9cf;
  border-radius: 6px;
  background: #fdfbf9;
  text-align: center;
}

body[data-page="pos"] .cart-row {
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
}

.cart-product-thumb {
  display: block;
  width: 30px;
  height: 30px;
  border: 3px solid #f5eee8;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, #ecd0aa 0 26%, #96501e 28% 60%, #53280d 62%);
}

body[data-page="pos"] .cart-row > div:nth-child(2) strong {
  font-size: 10px;
}

body[data-page="pos"] .cart-row > div:nth-child(2) span {
  margin-top: 3px;
  color: #8a7c71;
  font-size: 8px;
}

body[data-page="pos"] .qty-controls {
  gap: 5px;
}

body[data-page="pos"] .qty-button {
  width: 24px;
  min-height: 24px;
  padding: 0;
}

.cart-line-total {
  grid-column: 2 / -1;
  justify-self: end;
  color: #5d2d0c;
  font-size: 10px;
}

body[data-page="pos"] .cart-summary {
  border: 1px solid #eadfd6;
  border-radius: 6px;
  background: #fffaf6;
  margin-top: 10px;
  padding: 9px 11px;
}

body[data-page="pos"] .cart-summary > div {
  padding: 5px 0;
  font-size: 10px;
}

body[data-page="pos"] .cart-summary > div[hidden] {
  display: none;
}

.cashier-internal-metric {
  display: none !important;
}

body[data-page="pos"] .cart-summary .total {
  border-top: 1px solid #e0d3c7;
  margin-top: 7px;
  padding-top: 11px;
}

body[data-page="pos"] .cart-summary .total span,
body[data-page="pos"] .cart-summary .total strong {
  font-size: 15px;
}

body[data-page="pos"] #checkout {
  min-height: 40px;
  font-weight: 850;
}

@media (max-width: 1100px) {
  body[data-page="pos"] .pos-layout {
    grid-template-columns: 1fr;
  }

  body[data-page="pos"] .pos-command-bar {
    grid-template-columns: 140px 120px 140px minmax(150px, 1fr) 76px 96px 96px 70px;
  }

  body[data-page="pos"] .product-browser {
    min-height: auto;
  }

  body[data-page="pos"] .cart-panel {
    position: static;
    min-height: auto;
  }
}

@media (max-width: 980px) {
  .order-history-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: block;
    width: 100%;
    height: auto;
    min-height: 0;
    padding: 8px 12px;
  }

  .sidebar .brand,
  .sidebar-footer {
    display: none;
  }

  .nav-tabs,
  .nav-group {
    display: flex;
    width: 100%;
    gap: 5px;
    overflow-x: auto;
  }

  .nav-tab {
    flex: 0 0 auto;
    width: auto;
    min-height: 32px;
    padding: 6px 8px;
  }

  .main {
    min-width: 0;
  }
}

@media (max-width: 620px) {
  body[data-page="pos"] .main {
    padding: 10px;
  }

  body[data-page="pos"] .topbar {
    flex-direction: row;
  }

  body[data-page="pos"] .pos-command-bar {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  body[data-page="pos"] .service-modes,
  body[data-page="pos"] .pos-table-select,
  body[data-page="pos"] .pos-pickup-name,
  body[data-page="pos"] .pos-search,
  body[data-page="pos"] #open-pos-queue,
  body[data-page="pos"] #open-pos-approvals,
  body[data-page="pos"] #open-pos-tables,
  body[data-page="pos"] .order-reference {
    grid-column: 1;
  }

  body[data-page="pos"] .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="pos"] .product-card {
    min-width: 0;
  }
}

/* Orders page uses the same compact three-column queue as POS. */
body[data-page="orders"] .main {
  background: #fbf8f5;
}

body[data-page="orders"] .order-queue-toolbar {
  align-items: center;
  border: 1px solid #e5dbd2;
  background: #ffffff;
  color: #251b14;
  padding: 10px 12px;
}

.queue-page-heading {
  display: grid;
  min-width: 175px;
  gap: 3px;
}

.queue-page-heading span {
  color: #966039;
  font-size: 8px;
  font-weight: 850;
  text-transform: uppercase;
}

.queue-page-heading strong {
  font-size: 11px;
}

body[data-page="orders"] .queue-summary {
  display: grid;
  flex: 1;
  grid-template-columns: repeat(3, minmax(90px, 1fr));
  gap: 6px;
}

body[data-page="orders"] .queue-summary article {
  justify-content: space-between;
  min-width: 0;
  border: 0;
  border-left: 3px solid #d3a44d;
  border-radius: 4px;
  background: #f8f3ee;
  padding: 7px 8px;
}

body[data-page="orders"] .queue-summary .pos-queue-summary-preparing,
body[data-page="orders"] .queue-summary .pos-queue-summary-20 {
  border-left-color: #9a5522;
}

body[data-page="orders"] .queue-summary .pos-queue-summary-ready,
body[data-page="orders"] .queue-summary .pos-queue-summary-30 {
  border-left-color: #44945a;
}

body[data-page="orders"] .queue-summary strong {
  color: #2e2118;
  font-size: 14px;
}

body[data-page="orders"] .queue-summary span {
  color: #75675d;
  font-size: 7px;
}

body[data-page="orders"] .service-mode {
  border-color: #dfd2c7;
  background: #ffffff;
  color: #6f5c4e;
}

body[data-page="orders"] .service-mode.active {
  border-color: #754018;
  background: #754018;
  color: #ffffff;
}

body[data-page="orders"] .order-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  gap: 10px;
  min-height: 560px;
  overflow-x: auto;
}

body[data-page="orders"] .pos-queue-column {
  min-height: 560px;
}

body[data-page="orders"] .pos-queue-card {
  cursor: default;
}

.queue-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid #eee6df;
  padding-top: 8px;
}

.queue-card-footer span {
  color: #806e61;
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.selected-order-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 12px;
}

.selected-order-meta article {
  display: grid;
  gap: 4px;
  border: 1px solid #e9dfd7;
  border-radius: 5px;
  background: #faf6f2;
  padding: 9px;
}

.selected-order-meta span {
  color: #8a796c;
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.selected-order-meta strong {
  font-size: 10px;
}

.order-detail-actions {
  border-top: 1px solid #e9dfd7;
  margin-top: 12px;
  padding-top: 12px;
}

.pos-queue-card-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid #eee6df;
  padding-top: 8px;
}

.pos-queue-card-count strong {
  color: #5b3921;
  font-size: 9px;
}

.pos-queue-card-count span {
  color: #918176;
  font-size: 7px;
  text-align: right;
}

.preparation-note {
  border-left: 3px solid #9a5522;
  border-radius: 4px;
  background: #fff7ef;
  color: #75431e;
  margin-bottom: 10px;
  padding: 8px 10px;
  font-size: 8px;
  font-weight: 750;
}

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

.order-edit-form {
  display: grid;
  gap: 9px;
  border: 1px solid #e5d8cc;
  border-radius: 7px;
  background: #fffaf5;
  margin: 12px 0;
  padding: 10px;
}

.order-edit-note {
  color: #6f543e;
  font-size: 9px;
  line-height: 1.45;
}

.order-edit-list {
  display: grid;
  gap: 7px;
}

.order-edit-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 72px;
  align-items: center;
  gap: 10px;
  border: 1px solid #eee4dc;
  border-radius: 6px;
  background: #ffffff;
  padding: 8px;
}

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

.order-edit-row strong {
  color: #442711;
  font-size: 10px;
}

.order-edit-row small {
  margin-top: 3px;
  color: #88776a;
  font-size: 8px;
}

.order-edit-row input {
  min-height: 32px;
  text-align: right;
}

.preparation-item {
  overflow: hidden;
  border: 1px solid #e7ddd5;
  border-radius: 6px;
  background: #ffffff;
}

.preparation-item.ready {
  border-color: #acd5b5;
  background: #f7fcf8;
}

.preparation-item-heading {
  display: flex;
  align-items: center;
  gap: 9px;
  border-bottom: 1px solid #eee6df;
  padding: 10px;
}

.preparation-item-heading input {
  width: 18px;
  height: 18px;
  min-height: 0;
  accent-color: #438d56;
}

.preparation-item-heading span,
.preparation-item-heading strong,
.preparation-item-heading small {
  display: block;
}

.preparation-item-heading strong {
  font-size: 10px;
}

.preparation-item-heading small {
  margin-top: 3px;
  color: #89786c;
  font-size: 8px;
}

.preparation-ingredients {
  display: grid;
  gap: 0;
  padding: 5px 10px 8px;
}

.preparation-ingredients div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px dashed #eee5de;
  padding: 5px 0;
}

.preparation-ingredients div:last-child {
  border-bottom: 0;
}

.preparation-ingredients span {
  color: #75665b;
  font-size: 8px;
}

.preparation-ingredients strong {
  color: #4e3020;
  font-size: 8px;
}

.preparation-ingredients p {
  color: #9a8a7e;
  font-size: 8px;
}

@media (max-width: 760px) {
  body[data-page="orders"] .order-queue-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  body[data-page="orders"] .queue-summary {
    overflow-x: auto;
  }

  body[data-page="orders"] .queue-summary article {
    min-width: 115px;
  }

  body[data-page="orders"] .order-board {
    min-height: 500px;
  }
}

/* Airport-style order operations display */
body[data-page="orders"] .main {
  background: #f4f0eb;
}

body[data-page="orders"] .content-grid.single {
  gap: 12px;
}

body[data-page="orders"] .order-queue-toolbar {
  background: #17130f;
  border-color: #17130f;
  color: #fff9ee;
  padding: 10px 14px;
}

.queue-display-title {
  display: grid;
  gap: 3px;
  min-width: 130px;
}

.queue-display-title span {
  color: #c9b8a7;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.queue-display-title strong {
  color: #ffc45f;
  font-size: 18px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}

body[data-page="orders"] .queue-summary {
  flex: 1;
  justify-content: center;
}

body[data-page="orders"] .queue-summary article {
  min-width: 78px;
  border-right-color: #41372e;
  padding-right: 10px;
}

body[data-page="orders"] .queue-summary strong {
  color: #ffffff;
  font-size: 18px;
}

body[data-page="orders"] .queue-summary span {
  color: #b9aa9e;
  font-size: 8px;
  text-transform: uppercase;
}

body[data-page="orders"] .service-mode {
  border-color: #51463c;
  background: #272019;
  color: #d8ccc1;
}

body[data-page="orders"] .service-mode.active {
  border-color: #ffc45f;
  background: #ffc45f;
  color: #25170d;
}

body[data-page="orders"] .order-board {
  display: block;
  overflow: visible;
}

/* Embedded POS queue */
.pos-queue-trigger {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  border: 1px solid #d9c8ba;
  border-radius: 5px;
  background: #fffaf5;
  color: #54290d;
  padding: 0 9px;
  font-size: 9px;
  font-weight: 850;
  cursor: pointer;
}

.pos-queue-trigger[hidden] {
  display: none;
}

.pos-pickup-name {
  min-width: 150px;
}

.pos-pickup-name[hidden] {
  display: none;
}

.packaging-cart-row {
  background: #faf6f1;
}

.packaging-cart-row .cart-product-thumb {
  background: #d8b98f;
}

.packaging-control {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid #e5d8cc;
  border-radius: 5px;
  background: #faf4ee;
  margin-bottom: 8px;
  padding: 7px 9px;
}

.packaging-control[hidden] {
  display: none;
}

.packaging-control span {
  color: #735239;
  font-size: 8px;
  font-weight: 750;
}

.pos-queue-trigger strong {
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: #6f3610;
  color: #ffffff;
  font-size: 9px;
}

.approval-trigger {
  border-color: #d9b98b;
  background: #fff7ec;
}

.approval-trigger strong {
  background: #9b5520;
}

.pos-queue-backdrop {
  position: fixed;
  z-index: 80;
  inset: 0;
  background: rgba(48, 31, 18, 0.38);
}

.pos-queue-drawer[hidden],
.pos-queue-backdrop[hidden] {
  display: none;
}

.pos-queue-drawer {
  position: fixed;
  z-index: 81;
  top: 18px;
  right: 18px;
  bottom: 18px;
  display: grid;
  width: min(1120px, calc(100vw - 36px));
  grid-template-rows: auto auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid #dfd3c9;
  border-radius: 7px;
  background: #fbf8f5;
  box-shadow: 0 24px 80px rgba(51, 30, 15, 0.28);
}

.pos-table-drawer {
  width: min(940px, calc(100vw - 36px));
  grid-template-rows: auto minmax(0, 1fr);
}

.pos-approval-drawer {
  width: min(720px, calc(100vw - 36px));
  grid-template-rows: auto minmax(0, 1fr);
}

.pos-approval-list {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 0;
  overflow-y: auto;
  padding: 12px;
}

.pos-queue-drawer-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #e9dfd7;
  background: #ffffff;
  padding: 16px 18px;
}

.pos-queue-drawer-header h3,
.pos-queue-drawer-header p {
  margin: 0;
}

.pos-queue-drawer-header h3 {
  margin-top: 3px;
  font-size: 17px;
}

.pos-queue-drawer-header p {
  margin-top: 4px;
  color: #807166;
  font-size: 9px;
}

.pos-queue-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  border-bottom: 1px solid #e7ddd5;
  background: #f6f0ea;
  padding: 9px 18px;
}

.pos-queue-summary article {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-left: 3px solid #d3a44d;
  border-radius: 4px;
  background: #ffffff;
  padding: 8px 10px;
}

.pos-queue-summary-preparing,
.pos-queue-summary-20 {
  border-left-color: #9a5522 !important;
}

.pos-queue-summary-ready,
.pos-queue-summary-30 {
  border-left-color: #44945a !important;
}

.pos-queue-summary span {
  color: #75675d;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.pos-queue-summary strong {
  font-size: 16px;
}

.pos-queue-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  gap: 10px;
  min-height: 0;
  overflow-x: auto;
  padding: 12px;
}

.pos-queue-column {
  display: grid;
  min-width: 240px;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid #e5dbd2;
  border-radius: 6px;
  background: #f5f0eb;
}

.pos-queue-column > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid #d3a44d;
  background: #ffffff;
  padding: 10px 11px;
}

.pos-queue-column.column-preparing > header,
.pos-queue-column.column-20 > header {
  border-bottom-color: #9a5522;
}

.pos-queue-column.column-ready > header,
.pos-queue-column.column-30 > header {
  border-bottom-color: #44945a;
}

.pos-queue-column header span,
.pos-queue-column header h4 {
  display: block;
  margin: 0;
}

.pos-queue-column header span {
  color: #8b7d72;
  font-size: 7px;
  font-weight: 850;
  text-transform: uppercase;
}

.pos-queue-column header h4 {
  margin-top: 3px;
  font-size: 11px;
}

.pos-queue-column > header > strong {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 50%;
  background: #f4ece5;
  color: #673310;
  font-size: 10px;
}

.pos-queue-column-list {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 0;
  overflow-y: auto;
  padding: 8px;
}

.pos-queue-card {
  display: grid;
  gap: 9px;
  border: 1px solid #e2d8cf;
  border-top: 3px solid #d3a44d;
  border-radius: 6px;
  background: #ffffff;
  padding: 10px;
  box-shadow: 0 4px 14px rgba(72, 45, 25, 0.06);
}

.pos-queue-card.status-preparing,
.pos-queue-card.status-20 {
  border-top-color: #9a5522;
}

.pos-queue-card.status-ready,
.pos-queue-card.status-30 {
  border-top-color: #44945a;
}

.pos-queue-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.pos-queue-card-heading strong,
.pos-queue-card-heading span {
  display: block;
}

.pos-queue-card-heading strong {
  font-size: 11px;
}

.pos-queue-card-heading div span,
.pos-queue-age {
  margin-top: 3px;
  color: #88796e;
  font-size: 8px;
}

.pos-queue-age {
  border-radius: 3px;
  background: #fff1db;
  color: #9b641d;
  padding: 3px 5px;
  font-weight: 800;
  white-space: nowrap;
}

.pos-queue-card-items {
  display: grid;
  gap: 5px;
  border-top: 1px solid #eee6df;
  padding-top: 8px;
}

.pos-queue-card-items div,
.pos-queue-card-items strong,
.pos-queue-card-items span {
  display: block;
}

.pos-queue-card-items strong {
  font-size: 9px;
}

.pos-queue-card-items span {
  margin-top: 2px;
  color: #8a7a6f;
  font-size: 7px;
}

.pos-queue-card-actions {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 7px;
}

.pos-queue-card-actions .pos-queue-action:only-child {
  grid-column: 1 / -1;
}

.pos-queue-card-detail {
  display: grid;
  gap: 10px;
  border-top: 1px solid #eee6df;
  padding-top: 10px;
}

.pos-queue-card-detail .selected-order-meta {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 0;
}

.pos-queue-card-detail .preparation-list {
  max-height: 320px;
  overflow-y: auto;
}

.pos-queue-card-detail .order-detail-actions {
  margin-top: 0;
  padding-top: 10px;
}

.payment-proof-panel,
.order-status-timeline {
  display: grid;
  gap: 10px;
  border: 1px solid #eadfd5;
  border-radius: 6px;
  background: #fffaf5;
  padding: 12px;
}

.payment-proof-panel span,
.order-status-timeline > strong {
  color: #7b6658;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.payment-proof-panel strong {
  display: block;
  margin-top: 4px;
  color: #2f2017;
  font-size: 12px;
}

.payment-proof-panel img {
  width: min(260px, 100%);
  max-height: 180px;
  object-fit: contain;
  border: 1px solid #eadfd5;
  border-radius: 6px;
  background: #ffffff;
}

.order-status-timeline > div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 4px 10px;
  border-top: 1px dashed #eadfd5;
  padding-top: 8px;
}

.order-status-timeline > div:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.order-status-timeline span {
  color: #7b6658;
  font-size: 11px;
}

.order-status-timeline p,
.order-status-timeline small {
  margin: 0;
}

.order-status-timeline p {
  color: #2f2017;
  font-size: 12px;
  font-weight: 800;
}

.order-status-timeline small {
  grid-column: 2;
  color: #7b6658;
  font-size: 11px;
}

.pos-queue-action {
  display: grid;
  place-items: center;
  min-height: 29px;
  border: 0;
  border-radius: 4px;
  background: #6c3510;
  color: #ffffff;
  font-size: 8px;
  font-weight: 850;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
}

.column-ready .pos-queue-action {
  background: #438d56;
}

.pos-queue-action-link {
  background: #8b4d20;
}

.pos-queue-empty {
  display: grid;
  min-height: 130px;
  place-items: center;
  border: 1px dashed #ddd1c7;
  border-radius: 5px;
  color: #998a7f;
  font-size: 9px;
}

@media (max-width: 700px) {
  .pos-queue-drawer {
    top: 8px;
    right: 8px;
    bottom: 8px;
    width: calc(100vw - 16px);
  }

  .pos-queue-summary {
    overflow-x: auto;
  }

  .pos-queue-summary article {
    min-width: 120px;
  }
}

.flight-board-panel {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #2d2722;
  border-radius: 7px;
  background: #17130f;
  box-shadow: 0 12px 32px rgba(44, 27, 15, 0.16);
}

.flight-board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #4a3d32;
  background: #241c16;
  padding: 12px 14px;
}

.flight-board-header span,
.flight-board-header h3 {
  display: block;
  margin: 0;
}

.flight-board-header span {
  color: #c0a993;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.flight-board-header h3 {
  margin-top: 3px;
  color: #fff6e9;
  font-size: 15px;
}

.flight-board-header > strong {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  border: 1px solid #69523d;
  border-radius: 4px;
  color: #ffc45f;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.flight-board-labels,
.flight-order-row {
  display: grid;
  grid-template-columns: 72px minmax(90px, 0.75fr) minmax(180px, 2fr) 78px 70px 104px 112px;
  gap: 8px;
  align-items: center;
}

.flight-board-labels {
  border-bottom: 1px solid #3a3028;
  color: #9f8d7d;
  padding: 8px 12px;
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.flight-board-rows {
  display: grid;
}
.flight-order-destination span,
.flight-order-items span,
.flight-order-time span {
  color: #a99788;
  font-size: 8px;
}

.flight-order-time strong {
  font-variant-numeric: tabular-nums;
}

.flight-order-status {
  width: fit-content;
  border: 1px solid currentColor;
  border-radius: 3px;
  padding: 4px 6px;
  font-size: 7px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.flight-order-owner {
  width: fit-content;
  border-radius: 3px;
  padding: 4px 6px;
  font-size: 7px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.flight-order-owner.owner-kitchen {
  background: #5f371d;
  color: #ffc98a;
}

.flight-order-owner.owner-kasir {
  background: #234c32;
  color: #8de7a6;
}

.flight-order-status.status-waiting {
  color: #ffc45f;
}

.flight-order-status.status-preparing {
  color: #f08a45;
}

.flight-order-status.status-ready {
  color: #62d882;
}

.flight-order-status.status-completed {
  color: #9c948d;
}

.flight-action-button {
  width: 100%;
  min-height: 27px;
  border: 1px solid #ffc45f;
  border-radius: 4px;
  background: #ffc45f;
  color: #25170d;
  padding: 0 6px;
  font-size: 8px;
  font-weight: 850;
  cursor: pointer;
}

.flight-action-button.muted {
  border-color: #66574b;
  background: #2f2720;
  color: #d3c5ba;
}

.flight-board-empty {
  display: grid;
  min-height: 180px;
  place-items: center;
  color: #8e7e70;
  font-size: 10px;
}

@media (max-width: 700px) {
  body[data-page="orders"] .order-queue-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  body[data-page="orders"] .queue-summary {
    justify-content: flex-start;
    overflow-x: auto;
  }

  .flight-board-header,
  .flight-board-labels,
  .flight-board-rows {
    min-width: 0;
  }

  .flight-board-labels,
  .flight-order-row {
    grid-template-columns: 54px 54px minmax(88px, 1fr) 44px 43px 64px 72px;
    gap: 5px;
    padding-right: 8px;
    padding-left: 8px;
  }

  .flight-order-code {
    font-size: 13px;
  }

  .flight-order-destination strong,
  .flight-order-items strong,
  .flight-order-time strong {
    font-size: 8px;
  }

  .flight-order-destination span,
  .flight-order-items span,
  .flight-order-time span {
    font-size: 7px;
  }

  .flight-order-status {
    padding: 3px 4px;
    font-size: 6px;
    white-space: normal;
  }

  .flight-order-owner {
    padding: 3px;
    font-size: 6px;
    white-space: normal;
  }

  .flight-action-button {
    padding: 0 3px;
    font-size: 7px;
  }
}

.order-queue-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #e8dfd7;
  border-radius: 7px;
  background: #ffffff;
  padding: 10px 12px;
}

.queue-summary {
  display: flex;
  gap: 8px;
}

.queue-summary article {
  display: flex;
  align-items: center;
  gap: 8px;
  border-right: 1px solid #eee6df;
  padding-right: 12px;
}

.queue-summary span {
  color: #76695f;
  font-size: 9px;
  font-weight: 700;
}

.queue-summary strong {
  font-size: 17px;
}

.order-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(245px, 1fr));
  gap: 12px;
  align-items: start;
  overflow-x: auto;
}

.queue-column {
  min-width: 245px;
  border: 1px solid #e7ded6;
  border-radius: 7px;
  background: #f8f5f2;
  padding: 8px;
}

.queue-column-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 2px solid #d7a349;
  padding: 5px 4px 10px;
}

.column-preparing .queue-column-header {
  border-bottom-color: #8a4b1c;
}

.column-ready .queue-column-header {
  border-bottom-color: #4c9a5d;
}

.column-completed .queue-column-header {
  border-bottom-color: #a89f98;
}

.queue-column-header span,
.queue-column-header h3 {
  display: block;
  margin: 0;
}

.queue-column-header span {
  color: #8d7e72;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.queue-column-header h3 {
  margin-top: 3px;
  font-size: 11px;
}

.queue-column-header > strong {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  border-radius: 50%;
  background: #ffffff;
  color: #62300e;
  font-size: 11px;
}

.queue-column-list {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.order-queue-card {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 220px;
  border: 1px solid #e7ded6;
  border-top: 3px solid #d7a349;
  border-radius: 7px;
  background: #ffffff;
  box-shadow: var(--shadow);
  padding: 12px;
}

.queue-column-empty {
  display: grid;
  min-height: 130px;
  place-items: center;
  border: 1px dashed #ddd2c9;
  border-radius: 6px;
  color: #9a8d82;
  font-size: 9px;
  text-align: center;
}

.order-queue-card.status-preparing {
  border-top-color: #8a4b1c;
}

.order-queue-card.status-ready {
  border-top-color: #4c9a5d;
}

.order-queue-card.status-completed {
  border-top-color: #a89f98;
  opacity: 0.76;
}

.order-queue-card header,
.queue-status-row,
.order-queue-card footer,
.order-detail-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

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

.order-queue-card header strong {
  font-size: 12px;
}

.order-queue-card header div span,
.queue-time {
  margin-top: 3px;
  color: #8b7d72;
  font-size: 9px;
}

.queue-time {
  border-radius: 4px;
  background: #fff3dc;
  color: #9c6418;
  padding: 4px 6px;
  font-weight: 800;
  white-space: nowrap;
}

.queue-status {
  border-radius: 4px;
  padding: 4px 6px;
  font-size: 8px;
  font-weight: 850;
  text-transform: uppercase;
}

.queue-status.status-waiting {
  background: #fff3dc;
  color: #a16b1f;
}

.queue-status.status-preparing {
  background: #f4e8df;
  color: #7c3f13;
}

.queue-status.status-ready {
  background: #e4f5e7;
  color: #3d814b;
}

.queue-status.status-completed {
  background: #eeeae7;
  color: #77706a;
}

.queue-status-row b {
  color: #76695f;
  font-size: 9px;
}

.queue-items,
.order-detail-list {
  display: grid;
  gap: 0;
}

.queue-items {
  min-height: 100px;
  max-height: 125px;
  overflow-y: auto;
  border-top: 1px solid #eee6df;
}

.queue-item-line {
  position: relative;
  display: grid;
  gap: 3px;
  border-bottom: 1px solid #eee6df;
  padding: 8px 0;
}

.queue-item-line strong {
  font-size: 10px;
}

.queue-item-line span {
  color: #9a6740;
  font-size: 9px;
}

.queue-item-line b {
  position: absolute;
  top: 8px;
  right: 0;
  font-size: 10px;
}

.order-queue-card footer {
  margin-top: auto;
}

.empty-queue {
  grid-column: 1 / -1;
  display: grid;
  min-height: 220px;
  place-items: center;
  align-content: center;
  gap: 5px;
  color: #7b6e64;
  text-align: center;
}

.empty-queue span {
  font-size: 10px;
}

.order-detail-list {
  margin-bottom: 14px;
}

.order-detail-total {
  border-radius: 6px;
  background: #f7eee5;
  padding: 12px;
}

.order-detail-total span {
  color: #786b61;
  font-size: 10px;
}

.order-detail-total strong {
  color: #6d340e;
  font-size: 16px;
}

@media (max-width: 700px) {
  .order-queue-toolbar,
  .queue-summary {
    align-items: stretch;
    flex-direction: column;
  }

  .queue-summary article {
    justify-content: space-between;
    border-right: 0;
    border-bottom: 1px solid #eee6df;
    padding: 6px 0;
  }

  .order-board {
    grid-template-columns: repeat(3, minmax(250px, 1fr));
  }
}

.module-tabs,
.pos-category-tabs {
  display: flex;
  align-items: center;
  gap: 18px;
  overflow-x: auto;
  border-bottom: 1px solid #e9e1da;
  background: #ffffff;
  padding: 0 12px;
}

.module-tabs a,
.module-tabs button,
.pos-category-tabs button {
  position: relative;
  min-height: 38px;
  border: 0;
  background: transparent;
  color: #796d63;
  cursor: pointer;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.module-tabs a.active,
.module-tabs a:hover,
.module-tabs button.active,
.module-tabs button:hover,
.pos-category-tabs button.active,
.pos-category-tabs button:hover {
  color: #65300c;
}

.module-tabs a.active::after,
.module-tabs button.active::after,
.pos-category-tabs button.active::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: #7a3e12;
  content: "";
}

.pos-category-tabs {
  margin: -16px -16px 14px;
}

.product-visual img,
.pos-product-detail-visual img,
.product-photo-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-card {
  position: relative;
  min-height: 158px;
}

.product-card .product-add-button {
  position: absolute;
  right: 8px;
  bottom: 8px;
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 1px solid #ddc8b7;
  border-radius: 50%;
  background: #fff8f0;
  color: #71370e;
  font-weight: 800;
}

.product-card .product-add-button:disabled {
  opacity: 0.4;
}

.product-detail-button {
  width: max-content;
  border: 0;
  background: transparent;
  color: #71370e;
  padding: 0;
  font-size: 9px;
  font-weight: 800;
  text-decoration: underline;
}

.payment-methods {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 6px;
  margin: 12px 0 8px;
}

.payment-methods[hidden] {
  display: none;
}

.payment-methods button {
  min-height: 32px;
  border: 1px solid #dfd3c8;
  border-radius: 5px;
  background: #ffffff;
  color: #61544a;
  font-size: 9px;
  font-weight: 750;
}

.payment-methods button.active {
  border-color: #7a3e12;
  background: #7a3e12;
  color: #ffffff;
}

.pos-payment-panel {
  display: grid;
  gap: 8px;
  margin: 0 0 10px;
}

.pos-payment-panel[hidden],
.cash-payment-fields[hidden],
.third-party-payment[hidden] {
  display: none;
}

.cash-payment-fields,
.third-party-payment {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #eadbcf;
  border-radius: 7px;
  background: #fffaf4;
}

.cash-payment-fields {
  grid-template-columns: 1.2fr 0.8fr;
  align-items: end;
}

.cash-payment-fields label {
  display: grid;
  gap: 5px;
  color: #7b6a5c;
  font-size: 11px;
  font-weight: 800;
}

.cash-payment-fields div,
.third-party-payment {
  color: #7b6a5c;
  font-size: 11px;
  font-weight: 800;
}

.cash-payment-fields strong,
.third-party-payment strong {
  display: block;
  margin-top: 3px;
  color: #2f2017;
  font-size: 15px;
}

.third-party-payment small {
  color: #8f7c6f;
  line-height: 1.4;
}

.qris-payment-modal {
  width: min(460px, 100%);
}

.qris-payment-card {
  display: grid;
  gap: 14px;
  justify-items: center;
  padding: 18px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: linear-gradient(180deg, #fffaf4 0%, #ffffff 100%);
}

.qris-payment-brand {
  display: grid;
  gap: 4px;
  justify-items: center;
  text-align: center;
}

.qris-payment-brand strong {
  color: #2f2017;
  font-size: 18px;
}

.qris-payment-brand span,
.qris-payment-info small,
.qris-payment-note {
  color: #8f7c6f;
  font-size: 12px;
  font-weight: 800;
}

.qris-code-frame {
  display: grid;
  place-items: center;
  width: min(280px, 100%);
  aspect-ratio: 1;
  padding: 12px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: #ffffff;
}

.qris-code-frame[hidden],
.card-payment-icon[hidden] {
  display: none;
}

.qris-code-frame.invalid {
  border-style: dashed;
  background: #fff7ed;
}

.qris-code-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: crisp-edges;
}

.qris-code-frame.invalid img {
  display: none;
}

.qris-code-placeholder {
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 16px;
  text-align: center;
}

.qris-code-placeholder[hidden] {
  display: none;
}

.qris-code-placeholder strong {
  color: #9a3412;
  font-size: 18px;
}

.qris-code-placeholder span {
  color: #7c2d12;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.qris-payment-info {
  display: grid;
  gap: 4px;
  justify-items: center;
  text-align: center;
}

.qris-payment-info span {
  color: #7b6a5c;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.qris-payment-info strong {
  color: #5b2b0e;
  font-size: 26px;
}

.qris-payment-note {
  margin: 0;
  text-align: center;
  line-height: 1.45;
}

.card-payment-card {
  background: linear-gradient(180deg, #fffaf4 0%, #fff 72%);
}

.card-payment-icon {
  display: grid;
  gap: 6px;
  place-items: center;
  width: min(280px, 100%);
  min-height: 150px;
  padding: 20px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: #2f2017;
  color: #fffaf4;
  text-align: center;
}

.card-payment-icon strong {
  font-size: 30px;
  letter-spacing: 0;
}

.card-payment-icon span {
  color: #f5dcc5;
  font-size: 12px;
  font-weight: 800;
}

.customer-payment-page {
  min-height: 100vh;
  margin: 0;
  background: #fff7ed;
  color: #2f2017;
}

.customer-payment-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 20px;
}

.customer-payment-card {
  display: grid;
  gap: 14px;
  width: min(520px, 100%);
  padding: 24px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: #fffdf9;
  box-shadow: 0 18px 45px rgba(47, 32, 23, 0.12);
}

.customer-payment-card .brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 8px;
  background: #4b2a15;
  color: #fffaf4;
  font-weight: 900;
}

.customer-payment-card h1 {
  margin: 0;
  font-size: 26px;
  letter-spacing: 0;
}

.customer-payment-card p {
  margin: 0;
  color: #7b6a5c;
  line-height: 1.5;
}

.customer-payment-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.customer-payment-summary article,
.customer-payment-secure-box {
  display: grid;
  gap: 5px;
  padding: 12px;
  border: 1px solid #eadbcf;
  border-radius: 7px;
  background: #fffaf4;
}

.customer-payment-summary span {
  color: #8f7c6f;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.customer-payment-summary strong {
  overflow-wrap: anywhere;
}

.customer-card-actions {
  display: grid;
  gap: 8px;
}

.customer-card-actions .form-feedback {
  margin: 0;
}

@media (max-width: 560px) {
  .customer-payment-summary {
    grid-template-columns: 1fr;
  }
}

.table-layout-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 8px;
  margin: 8px 0 14px;
}

.table-layout-preview article {
  display: grid;
  gap: 5px;
  min-height: 72px;
  align-content: center;
  border: 1px solid #e4d7ca;
  border-radius: 7px;
  background: #fffaf6;
  padding: 10px;
}

.table-layout-preview article strong {
  color: #4c2810;
  font-size: 13px;
}

.table-layout-preview article span {
  color: #806f62;
  font-size: 10px;
}

.table-layout-preview article.inactive {
  background: #f7f3ee;
  opacity: 0.55;
}

.table-flow-form {
  margin-bottom: 14px;
}

.open-table-list {
  display: grid;
  gap: 8px;
  align-content: start;
  min-height: 0;
  overflow-y: auto;
  padding: 12px;
}

.open-table-card {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) auto minmax(112px, 140px) auto auto auto minmax(112px, 140px) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid #e4d7ca;
  border-radius: 7px;
  background: #ffffff;
  padding: 10px;
}

.open-table-card .compact-button {
  white-space: nowrap;
}

.open-table-card strong,
.open-table-total strong {
  color: #4c2810;
}

.open-table-card span,
.open-table-total span {
  display: block;
  color: #806f62;
  font-size: 10px;
}

.open-table-total {
  text-align: right;
}

[data-bill-detail-backdrop] {
  z-index: 110;
}

#bill-detail-modal {
  z-index: 111;
}

.bill-detail-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.bill-detail-summary article {
  border: 1px solid #eadfd5;
  border-radius: 6px;
  background: #fffaf5;
  padding: 10px;
}

.bill-detail-summary span,
.bill-total-panel span,
.bill-settlement-row label {
  display: block;
  color: #7f7166;
  font-size: 9px;
  font-weight: 800;
}

.bill-detail-summary strong,
.bill-total-panel strong {
  display: block;
  margin-top: 4px;
  color: #4c2810;
  font-size: 13px;
}

.bill-detail-table-wrap {
  overflow-x: auto;
  border: 1px solid #eadfd5;
  border-radius: 7px;
  margin-bottom: 12px;
}

.bill-detail-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

.bill-detail-table th,
.bill-detail-table td {
  border-bottom: 1px solid #eee6df;
  padding: 10px;
  text-align: left;
  font-size: 10px;
}

.bill-detail-table th {
  background: #f8f1ea;
  color: #6b4c34;
  font-size: 8px;
  text-transform: uppercase;
}

.bill-detail-table td:nth-child(n+2),
.bill-detail-table th:nth-child(n+2) {
  text-align: right;
}

.bill-detail-table small {
  display: block;
  margin-top: 3px;
  color: #87786d;
  font-size: 8px;
}

.bill-total-panel {
  display: grid;
  gap: 7px;
  border: 1px solid #eadfd5;
  border-radius: 7px;
  background: #fffdfb;
  margin-bottom: 12px;
  padding: 10px;
}

.bill-total-panel div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.bill-total-panel .total {
  border-top: 1px solid #eadfd5;
  margin-top: 3px;
  padding-top: 8px;
}

.bill-total-panel .total strong {
  color: #7a3e12;
  font-size: 16px;
}

.bill-settlement-row {
  margin-bottom: 12px;
}

.bill-settlement-row[hidden] {
  display: none;
}

.bill-settlement-row select {
  margin-top: 6px;
}

.bill-cash-fields,
.bill-gateway-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(130px, auto);
  gap: 10px;
  align-items: end;
  margin-top: 10px;
}

.bill-cash-fields[hidden],
.bill-gateway-panel[hidden] {
  display: none;
}

.bill-cash-fields div,
.bill-gateway-panel {
  border: 1px solid #eadfd5;
  border-radius: 6px;
  background: #fffaf5;
  padding: 9px 10px;
}

.bill-cash-fields span,
.bill-gateway-panel span,
.bill-gateway-panel small {
  display: block;
  color: #7d6c60;
  font-size: 9px;
  font-weight: 750;
}

.bill-cash-fields strong,
.bill-gateway-panel strong {
  display: block;
  margin-top: 3px;
  color: #4b260f;
  font-size: 13px;
}

.bill-gateway-panel {
  grid-template-columns: minmax(0, 1fr);
}

@media (max-width: 760px) {
  .active-open-table-context,
  .bill-total-panel div {
    align-items: stretch;
    flex-direction: column;
  }

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

  .open-table-card {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .open-table-total {
    text-align: left;
  }
}

.table-product-photo {
  display: block;
  width: 28px;
  height: 28px;
  border: 3px solid #f4ede6;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, #efd3ae 0 26%, #98501d 28% 60%, #53280d 62%);
}

.product-photo-image {
  object-fit: cover;
}

.qris-upload-preview {
  display: grid;
  width: 120px;
  aspect-ratio: 1;
  place-items: center;
  overflow: hidden;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fffaf4;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.qris-upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}

.pos-product-detail-layout {
  display: grid;
  grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1.28fr);
  gap: 18px;
}

.pos-product-detail-visual {
  display: grid;
  min-height: 290px;
  place-items: center;
  overflow: hidden;
  border-radius: 6px;
  background: linear-gradient(145deg, #c68a51, #4b260e);
}

.pos-product-detail-visual span {
  width: 150px;
  height: 150px;
  border: 12px solid #f7f0e8;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, #f2d9b7 0 25%, #a6541c 27% 52%, #4d260e 54%);
}

.pos-product-story {
  display: grid;
  align-content: start;
  gap: 12px;
}

.product-detail-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.product-detail-heading strong {
  font-size: 18px;
}

.pos-product-story > p {
  margin: 0;
  color: #6d6157;
  font-size: 11px;
  line-height: 1.6;
}

.product-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin: 0;
}

.product-facts div {
  border: 1px solid #ebe3dc;
  border-radius: 5px;
  background: #fdfbf9;
  padding: 9px;
}

.product-facts dt,
.product-facts dd {
  margin: 0;
}

.product-facts dt {
  color: #887a6e;
  font-size: 9px;
}

.product-facts dd {
  margin-top: 4px;
  font-size: 10px;
  font-weight: 800;
}

.cashier-recommendation {
  border-left: 3px solid #8a4819;
  background: #f8eee4;
  padding: 10px 12px;
}

.cashier-recommendation span,
.cashier-recommendation strong {
  display: block;
}

.pos-modifier-group {
  border: 1px solid #eadfd5;
  border-radius: 7px;
  background: #fffaf5;
  display: grid;
  gap: 8px;
  padding: 12px;
}

.pos-modifier-group legend {
  color: #2f2018;
  font-size: 11px;
  font-weight: 850;
  padding: 0 5px;
}

.pos-modifier-group legend small {
  color: #8a796d;
  font-size: 9px;
  font-weight: 800;
  margin-left: 6px;
}

.modifier-option {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #e8dfd7;
  border-radius: 6px;
  background: #fffdfb;
  padding: 10px;
  cursor: pointer;
}

.modifier-option input {
  width: 17px;
  min-height: 17px;
}

.modifier-option span,
.modifier-option strong,
.modifier-option small,
.cart-row small {
  display: block;
}

.modifier-option strong {
  font-size: 11px;
}

.modifier-option small,
.cart-row small {
  margin-top: 3px;
  color: #8a6b54;
  font-size: 9px;
}

.cashier-recommendation span {
  color: #8a4819;
  font-size: 9px;
  font-weight: 800;
}

.cashier-recommendation strong {
  margin-top: 4px;
  font-size: 10px;
  line-height: 1.5;
}

@media (max-width: 760px) {
  .pos-product-detail-layout,
  .product-facts {
    grid-template-columns: 1fr;
  }
}

.table-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.recipe-product-picker {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #7a6d63;
  font-size: 10px;
  font-weight: 700;
}

.recipe-product-picker a {
  color: #6e3510;
  font-weight: 800;
}

.recipe-product-picker select {
  min-width: 190px;
}

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

.dashboard-operational-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(210px, 0.65fr) minmax(210px, 0.72fr);
  gap: 12px;
  margin-top: 12px;
}

.esb-control-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, .7fr);
  gap: 12px;
  margin-top: 12px;
}

.esb-control-grid.single-panel {
  grid-template-columns: minmax(0, 1fr);
}

.dashboard-operational-grid[data-panels="1"] {
  grid-template-columns: minmax(0, 1fr);
}

.dashboard-operational-grid[data-panels="2"] {
  grid-template-columns: minmax(0, 1.7fr) minmax(230px, 0.7fr);
}

.esb-module-grid,
.esb-integration-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.esb-module-card,
.esb-integration-card {
  display: grid;
  gap: 5px;
  min-height: 92px;
  padding: 12px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: #fffaf4;
}

.esb-module-card.warning {
  border-color: #efc28d;
  background: #fff7ed;
}

.esb-module-card span,
.esb-integration-card span {
  color: #8a7665;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.esb-module-card strong,
.esb-integration-card strong {
  color: #2f2017;
  font-size: 18px;
  overflow-wrap: anywhere;
}

.esb-module-card small,
.esb-integration-card small {
  color: #7d6b5e;
  font-size: 11px;
  line-height: 1.35;
}

.esb-risk-list {
  display: grid;
  gap: 9px;
}

.esb-risk-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid #eadbcf;
  border-radius: 8px;
  background: #fffaf4;
}

.esb-risk-item strong,
.esb-risk-item b {
  color: #2f2017;
}

.esb-risk-item small {
  display: block;
  color: #8a7665;
  font-size: 11px;
  margin-top: 2px;
}

.esb-integration-panel {
  margin-top: 12px;
}

.sales-chart-panel canvas {
  display: block;
  width: 100%;
  height: 220px;
}

.compact-dashboard-panel {
  min-width: 0;
}

.ranking-list,
.low-stock-list {
  display: grid;
  gap: 2px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  border-bottom: 1px solid #eee8e2;
}

.ranking-item:last-child,
.low-stock-item:last-child {
  border-bottom: 0;
}

.ranking-item strong,
.low-stock-item strong {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-item b,
.low-stock-item b {
  color: #796b60;
  font-size: 9px;
  font-weight: 600;
}

.menu-thumbnail,
.ingredient-thumbnail {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid #e3d5c9;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 44%, #f4d3a6 0 25%, #9d511d 27% 48%, #fff 50% 63%, #c9b5a4 65%);
  color: transparent;
  font-size: 0;
}

.ingredient-thumbnail {
  width: 23px;
  height: 23px;
  border-radius: 5px;
  background: linear-gradient(135deg, #e9d4bb, #8e4d20);
}

.low-stock-item {
  display: grid;
  gap: 6px;
  min-height: 47px;
  border-bottom: 1px solid #eee8e2;
  padding: 7px 0;
}

.low-stock-item > div {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
}

.stock-progress {
  display: block;
  height: 3px;
  margin-left: 32px;
  overflow: hidden;
  border-radius: 8px;
  background: #eee9e4;
}

.stock-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #e3a33e;
}

.stock-progress i.danger {
  background: #d85a49;
}

@media (max-width: 1180px) {
  .esb-control-grid,
  .dashboard-operational-grid {
    grid-template-columns: minmax(0, 1.5fr) minmax(220px, 0.75fr);
  }

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

  .dashboard-operational-grid .compact-dashboard-panel:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .dashboard-kpis,
  .esb-control-grid,
  .esb-module-grid,
  .esb-integration-grid,
  .dashboard-operational-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-operational-grid .compact-dashboard-panel:last-child {
    grid-column: auto;
  }
}

.page-command-bar,
.pos-command-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid #ebe4dd;
  border-radius: 7px;
  background: #ffffff;
  box-shadow: var(--shadow);
  padding: 14px 16px;
}

.page-command-bar h3 {
  margin: 0;
  font-size: 16px;
}

.page-command-bar .hero-kicker {
  margin-bottom: 5px;
}

.pos-command-bar {
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) auto;
  margin-bottom: 12px;
  padding: 10px 12px;
}

.service-modes {
  display: flex;
  gap: 5px;
  min-width: 0;
}

.service-mode {
  flex: 1 1 0;
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #ffffff;
  color: var(--muted);
  padding: 0 11px;
  font-size: 10px;
  font-weight: 800;
}

.service-mode.active {
  border-color: #8a4b1c;
  background: var(--brand-soft);
  color: var(--brand-strong);
}

.pos-search {
  display: block;
  font-size: 0;
}

.pos-search input {
  min-height: 32px;
}

.order-reference {
  min-width: 0;
  text-align: right;
}

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

.order-reference span {
  color: var(--muted);
  font-size: 9px;
}

.order-reference strong {
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.recipe-workspace {
  grid-template-columns: minmax(300px, 0.75fr) minmax(420px, 1.25fr);
}

.recipe-workspace .split-form {
  grid-template-columns: 1fr;
}

.recipe-workspace .full-row {
  grid-column: auto;
}

.recipe-card footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line);
  margin-top: 10px;
  padding-top: 9px;
  color: var(--muted);
  font-size: 10px;
}

.recipe-card footer strong {
  color: var(--ink);
}

.recipe-lines {
  display: grid;
  gap: 5px;
}

.recipe-line {
  border-radius: 4px;
  background: #f8f5f2;
  padding: 6px 8px;
  font-size: 10px;
}

.recipe-margin {
  border-radius: 4px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  padding: 4px 7px;
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.form-workspace {
  grid-template-columns: minmax(420px, 1fr) minmax(260px, 0.55fr);
  align-items: start;
}

.form-workspace .form-panel {
  max-width: none;
}

@media (max-width: 980px) {
  .recipe-workspace,
  .form-workspace,
  .pos-command-bar {
    grid-template-columns: 1fr;
  }
}

/* CoffeeSuite premium operating theme */
:root {
  --ink: #251c16;
  --muted: #7c7067;
  --line: #e7dfd7;
  --panel: #ffffff;
  --app: #fbfaf8;
  --brand: #7a3e12;
  --brand-strong: #552708;
  --brand-soft: #f7ede3;
  --amber: #d28a25;
  --red: #d65349;
  --blue: #7a3e12;
  --blue-soft: #f7f1ea;
  --shadow: 0 4px 16px rgba(73, 42, 20, 0.045);
}

body {
  background: #fbfaf8;
  font-size: 13px;
}

.app-shell {
  grid-template-columns: 220px minmax(0, 1fr);
}

.sidebar {
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-height: 100vh;
  overflow-y: auto;
  background:
    radial-gradient(circle at 50% 0%, rgba(142, 76, 25, 0.22), transparent 32%),
    #21160e;
  padding: 20px 14px 14px;
}

.brand {
  display: grid;
  justify-items: center;
  gap: 7px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  margin-bottom: 14px;
  padding: 0 4px 18px;
}

.brand-mark {
  width: 72px;
  height: 72px;
  border: 2px solid #c87a32;
  border-radius: 50%;
  background: #f6eadc;
  box-shadow: inset 0 0 0 4px #382012;
  color: #4b250e;
  font-family: Georgia, serif;
  font-size: 19px;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}

.app-brand-logo {
  background: #fff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.app-brand-logo img {
  object-fit: contain;
  padding: 5px;
}

.app-brand-mark {
  align-content: center;
  display: grid;
  gap: 0;
  line-height: 1;
  text-align: center;
}

.app-brand-mark strong {
  display: block;
  color: #4b250e;
  font-family: Georgia, serif;
  font-size: 20px;
  line-height: 1;
}

.app-brand-mark small {
  display: block;
  color: #6e3a16;
  font-family: Inter, system-ui, sans-serif;
  font-size: 8px;
  font-weight: 900;
  line-height: 1;
  margin-top: 3px;
  text-transform: uppercase;
}

.brand > div {
  text-align: center;
}

.brand h1 {
  font-family: Georgia, serif;
  font-size: 18px;
}

.sidebar .brand p {
  color: #aa9d91;
  font-size: 10px;
}

.nav-tabs {
  gap: 8px;
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-group-title {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 32px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.045);
  color: #d8c1ab;
  padding: 8px 10px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  list-style: none;
  text-transform: uppercase;
  user-select: none;
}

.nav-group-title:hover,
.nav-group-title:focus {
  border-color: rgba(200, 122, 50, 0.42);
  background: rgba(114, 56, 15, 0.35);
  color: #ffffff;
  outline: none;
}

.nav-group-title::-webkit-details-marker {
  display: none;
}

.nav-group-title::after {
  content: "›";
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.18);
  color: #f2d3b4;
  font-size: 14px;
  transform: rotate(90deg);
  transition: transform 0.16s ease;
}

.nav-group:not([open]) .nav-group-title::after {
  transform: rotate(0deg);
}

.nav-tab {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  border-radius: 5px;
  color: #ddd3ca;
  padding: 8px 10px 8px 14px;
  font-size: 11px;
}

.nav-tab.active,
.nav-tab:hover {
  background: linear-gradient(90deg, #72380f, #4b250d);
  color: #ffffff;
}

.nav-tab.active::before {
  display: none;
}

.nav-icon {
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  color: #d8c1ab;
  font-size: 9px;
  font-weight: 800;
}

.nav-tab.active .nav-icon {
  border-color: rgba(255, 255, 255, 0.32);
  color: #ffffff;
}

.sidebar-footer {
  display: grid;
  gap: 8px;
  margin-top: auto;
  padding-top: 18px;
}

.outlet-card,
.user-card {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.035);
  color: #ffffff;
  padding: 9px;
}

.outlet-card span,
.outlet-card strong,
.user-card strong,
.user-card small {
  display: block;
}

.outlet-card span,
.user-card small {
  color: #9f9185;
  font-size: 9px;
}

.outlet-card strong,
.user-card strong {
  margin-top: 2px;
  font-size: 10px;
}

.outlet-card-select {
  display: grid;
  gap: 5px;
}

.outlet-card-select select {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.18);
  color: #ffffff;
  font-size: 10px;
  font-weight: 850;
  outline: none;
  padding: 7px 8px;
}

.outlet-card-select select:focus {
  border-color: #c87a32;
}

.user-card {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 0;
  background: transparent;
}

.user-avatar {
  display: grid;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #f0c39c;
  color: #4b250e;
  font-weight: 800;
}

.main {
  padding: 20px 24px 28px;
}

.topbar {
  min-height: 48px;
  margin-bottom: 18px;
}

.eyebrow {
  display: none;
}

.topbar h2 {
  color: #19130f;
  font-size: 20px;
  font-weight: 750;
}

.top-actions {
  align-items: center;
}

.onboarding-topbar-button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 10px;
  width: 190px;
  min-height: 42px;
  padding: 7px 10px;
  border: 1px solid #dfd1c4;
  border-radius: 6px;
  background: #fffaf5;
  color: #3f2819;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(61, 35, 18, 0.06);
}

.onboarding-topbar-button:hover {
  border-color: var(--brand);
  box-shadow: 0 5px 14px rgba(61, 35, 18, 0.1);
}

.onboarding-topbar-copy {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.onboarding-topbar-copy small {
  overflow: hidden;
  font-size: 10px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.onboarding-topbar-copy strong,
.onboarding-topbar-percent {
  font-size: 10px;
  font-weight: 800;
}

.onboarding-topbar-progress {
  align-self: center;
  height: 5px;
  overflow: hidden;
  border-radius: 3px;
  background: #eadfd5;
}

.onboarding-topbar-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.onboarding-topbar-percent {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
}

.date-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #ffffff;
  color: #50463f;
  padding: 0 11px;
  font-size: 11px;
  font-weight: 700;
}

.primary-button,
.ghost-button,
.qty-button,
.icon-button {
  min-height: 34px;
  border-radius: 5px;
  padding: 0 12px;
  font-size: 11px;
}

.primary-button {
  background: linear-gradient(180deg, #814313, #642e08);
}

.primary-button:hover {
  background: #552708;
  box-shadow: 0 7px 14px rgba(101, 46, 8, 0.18);
}

.ghost-button,
.qty-button,
.icon-button {
  background: #ffffff;
}

.icon-button {
  width: 34px;
  min-height: 34px;
}

.executive-hero,
.quick-actions {
  display: none;
}

.metric-grid {
  gap: 12px;
  margin-bottom: 14px;
}

.metric,
.workspace-panel,
.inventory-command {
  border-color: #ebe4dd;
  border-radius: 7px;
  box-shadow: var(--shadow);
}

.metric {
  min-height: 104px;
  padding: 15px;
}

.metric::after {
  top: 14px;
  right: 14px;
  bottom: auto;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: var(--brand-soft);
}

.metric span {
  color: #685d54;
  font-size: 10px;
}

.metric strong {
  margin-top: 12px;
  font-size: 20px;
  line-height: 1.1;
}

.metric small {
  font-size: 9px;
}

.content-grid,
.pos-layout {
  gap: 14px;
}

.workspace-panel {
  padding: 16px;
}

.panel-heading {
  margin-bottom: 12px;
}

.panel-heading h3 {
  font-size: 13px;
}

.panel-heading p {
  font-size: 10px;
}

.inventory-command {
  padding: 16px;
}

.inventory-command h3 {
  font-size: 18px;
}

.inventory-command p {
  margin-top: 6px;
  font-size: 11px;
  line-height: 1.45;
}

.hero-kicker {
  margin-bottom: 7px;
  border-radius: 4px;
  padding: 4px 7px;
  font-size: 9px;
}

.datatable-shell {
  gap: 9px;
}

.datatable-toolbar,
.datatable-footer {
  gap: 8px;
}

.datatable-toolbar label {
  width: min(280px, 100%);
  font-size: 10px;
}

.datatable-pagination span,
.datatable-info {
  font-size: 10px;
}

table {
  min-width: 640px;
  font-size: 10px;
}

th,
td {
  padding: 10px 9px;
}

th {
  background: #f8f5f2;
  color: #6f6258;
  font-size: 9px;
  letter-spacing: 0;
  text-transform: none;
}

tbody tr:hover {
  background: #fdf9f5;
}

.status-pill {
  border-radius: 4px;
  padding: 3px 6px;
  font-size: 9px;
}

.status-ok {
  background: #e4f5e6;
  color: #39834b;
}

.status-low {
  background: #fff1d6;
  color: #b56b10;
}

.status-empty {
  background: #ffe8e4;
  color: #cc4d42;
}

.form-grid {
  gap: 10px;
}

.input-workflow {
  border-color: #ede6df;
  border-radius: 6px;
  background: #fcfaf8;
  padding: 12px;
}

label {
  gap: 5px;
  color: #5b5048;
  font-size: 10px;
}

input,
select {
  min-height: 36px;
  border-radius: 5px;
  padding: 0 10px;
  font-size: 11px;
}

input:focus,

.modal-header h3 {
  font-size: 16px;
}

.modal-header p,
.form-preview,
.form-feedback {
  font-size: 10px;
}

.compact-subform {
  border: 1px solid rgba(109, 67, 35, 0.14);
  border-radius: 7px;
  background: #fffaf5;
  padding: 10px;
}

.compact-button {
  min-height: 27px;
  padding: 0 8px;
  font-size: 9px;
}

.ghost-button:disabled,
.ghost-button:disabled:hover,
.ghost-button.compact-button:disabled,
.ghost-button.compact-button:disabled:hover {
  cursor: not-allowed;
  border-color: #e2d8cf;
  background: #f3eee9;
  color: #b5a79d;
  box-shadow: none;
  opacity: 0.72;
}

@media (max-width: 980px) {
  .sidebar {
    height: auto;
    min-height: auto;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .sidebar-footer {
    display: none;
  }

  .nav-tabs {
    width: 100%;
    max-width: 100%;
  }

  .nav-group {
    width: max-content;
  }

  .nav-tab {
    width: auto;
  }
}

@media (max-width: 620px) {
  .main {
    padding: 14px;
  }

  .date-chip {
    display: none;
  }
}

/* Final responsive overrides must remain after the premium theme declarations. */
@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: block;
    width: 100%;
    height: auto;
    min-height: 0;
    padding: 8px 12px;
  }

  .sidebar .brand,
  .sidebar-footer {
    display: none;
  }

  .nav-tabs,
  .nav-group {
    display: flex;
    width: 100%;
    gap: 5px;
    overflow-x: auto;
  }

  .nav-tab {
    flex: 0 0 auto;
    width: auto;
    min-height: 32px;
    padding: 6px 8px;
  }

  body[data-page="pos"] .product-browser,
  body[data-page="pos"] .cart-panel {
    min-height: auto;
  }
}

@media (max-width: 620px) {
  body[data-page="pos"] .main {
    padding: 10px;
  }

  body[data-page="pos"] .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Final orders-page overrides: match the light embedded POS queue. */
body[data-page="orders"] .order-queue-toolbar {
  border-color: #e5dbd2;
  background: #ffffff;
  color: #251b14;
}

body[data-page="orders"] .queue-summary article {
  border-right: 0;
  border-left: 3px solid #d3a44d;
  background: #f8f3ee;
}

body[data-page="orders"] .queue-summary .pos-queue-summary-preparing,
body[data-page="orders"] .queue-summary .pos-queue-summary-20 {
  border-left-color: #9a5522;
}

body[data-page="orders"] .queue-summary .pos-queue-summary-ready,
body[data-page="orders"] .queue-summary .pos-queue-summary-30 {
  border-left-color: #44945a;
}

body[data-page="orders"] .queue-summary strong {
  color: #2e2118;
}

body[data-page="orders"] .queue-summary span {
  color: #75675d;
}

body[data-page="orders"] .service-mode {
  border-color: #dfd2c7;
  background: #ffffff;
  color: #6f5c4e;
}

body[data-page="orders"] .service-mode.active {
  border-color: #754018;
  background: #754018;
  color: #ffffff;
}

body[data-page="orders"] .order-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  gap: 10px;
  overflow-x: auto;
}

body[data-page="orders"] .order-board.completed-only {
  display: block;
}

.completed-orders-table-panel {
  overflow: hidden;
  border: 1px solid #e4d9d0;
  border-radius: 6px;
  background: #ffffff;
}

.completed-orders-table-scroll {
  overflow-x: auto;
}

.completed-orders-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
}

.completed-orders-table th {
  background: #f5eee8;
  color: #746458;
  padding: 9px 10px;
  font-size: 7px;
  font-weight: 850;
  text-align: left;
  text-transform: uppercase;
}

.completed-orders-table td {
  border-bottom: 1px solid #eee5de;
  color: #514238;
  padding: 10px;
  font-size: 9px;
  vertical-align: top;
}

.completed-orders-table tr:last-child td {
  border-bottom: 0;
}

.completed-orders-table td > span {
  display: block;
  margin-top: 3px;
  color: #8b7b6f;
  font-size: 7px;
}

.completed-order-items {
  display: grid;
  gap: 4px;
}

.completed-order-items > span,
.completed-order-items small {
  display: block;
}

.completed-order-items small {
  margin-top: 2px;
  color: #917f71;
  font-size: 7px;
}

.completed-orders-empty {
  height: 160px;
  color: #998a7e !important;
  text-align: center;
  vertical-align: middle !important;
}

@media (max-width: 980px) {
  body[data-page="orders"] .order-board {
    grid-template-columns: repeat(3, minmax(240px, 1fr));
  }

  body[data-page="orders"] .order-board.completed-only {
    grid-template-columns: minmax(240px, 1fr);
    padding-bottom: 8px;
  }

  .nav-group {
    width: 100%;
  }

  .nav-group[open] {
    grid-column: 1 / -1;
  }

  .nav-group-title {
    width: 100%;
    min-width: 118px;
    min-height: 40px;
    padding: 0 10px;
  }

  .nav-group-menu {
    position: static;
    margin-top: 6px;
    min-width: 0;
    width: 100%;
    max-height: 48vh;
    overflow-y: auto;
  }

  .nav-group-menu .nav-tab {
    min-height: 42px;
    font-size: 11px;
  }
}

@media (max-width: 520px) {
  .nav-tabs {
    grid-template-columns: minmax(0, 1fr);
  }

  .nav-group-title {
    display: flex;
    min-width: 0;
  }
}

/* Final responsive sidebar: desktop vertical, mobile dropdown header. */
.mobile-menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.08);
  padding: 0;
}

.mobile-menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: #ffffff;
}

.app-shell {
  grid-template-columns: 236px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  width: 236px;
  height: 100vh;
  min-height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 18px 12px 14px;
}

.sidebar .brand {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  justify-items: start;
  min-width: 0;
  gap: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  margin: 0 0 14px;
  padding: 0 2px 16px;
}

.sidebar .brand > div {
  min-width: 0;
  text-align: left;
}

.sidebar .brand h1,
.sidebar .brand p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar .brand h1 {
  font-size: 15px;
}

.sidebar .brand p {
  font-size: 9px;
}

.brand-mark {
  width: 44px;
  height: 44px;
}

.nav-tabs {
  display: grid;
  align-items: stretch;
  gap: 7px;
  overflow: visible;
  padding: 0;
}

.nav-group {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 0;
  border: 0;
  background: transparent;
  padding: 0;
}

.nav-group-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-width: 0;
  min-height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.045);
  color: #d8c1ab;
  cursor: pointer;
  padding: 0 10px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  list-style: none;
  text-transform: uppercase;
  user-select: none;
}

.nav-group-title::-webkit-details-marker {
  display: none;
}

.nav-group-title::after {
  content: ">";
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.2);
  color: #f2d3b4;
  font-size: 12px;
  line-height: 1;
  transform: rotate(90deg);
  transition: transform 0.16s ease;
}

.nav-group:not([open]) .nav-group-title::after {
  transform: rotate(0deg);
}

.nav-group.active > .nav-group-title,
.nav-group-title:hover,
.nav-group[open] > .nav-group-title {
  border-color: rgba(200, 122, 50, 0.45);
  background: linear-gradient(90deg, rgba(114, 56, 15, 0.82), rgba(75, 37, 13, 0.72));
  color: #ffffff;
}

.nav-group-menu {
  position: static;
  z-index: auto;
  display: none;
  width: 100%;
  min-width: 0;
  max-height: none;
  overflow: visible;
  border: 0;
  border-left: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  margin: 6px 0 2px 14px;
  padding: 0 0 0 9px;
}

.nav-group[open] .nav-group-menu {
  display: grid;
  gap: 4px;
}

.nav-group-menu .nav-tab {
  width: 100%;
  min-height: 35px;
  justify-content: flex-start;
  white-space: normal;
  padding: 7px 9px;
  font-size: 10px;
}

.nav-icon {
  flex: 0 0 auto;
}

.sidebar-footer {
  display: grid;
  gap: 8px;
  min-width: 0;
  margin-top: auto;
  padding-top: 16px;
}

.sidebar-footer .full {
  width: 100%;
}

.outlet-card,
.user-card {
  min-height: 0;
  padding: 8px;
}

.user-card {
  max-width: none;
}

.main {
  min-width: 0;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .sidebar {
    position: sticky;
    top: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    width: 100%;
    height: auto;
    min-height: 0;
    overflow: visible;
    padding: 10px 12px;
  }

  .sidebar .brand {
    border-bottom: 0;
    margin: 0;
    padding: 0;
  }

  .mobile-menu-toggle {
    display: grid;
  }

  .nav-tabs {
    display: none;
    grid-column: 1 / -1;
    gap: 8px;
    max-height: calc(100vh - 92px);
    overflow-y: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
    margin-top: 10px;
    padding-top: 10px;
  }

  .sidebar.mobile-nav-open .nav-tabs {
    display: grid;
  }

  .nav-group-title {
    min-height: 44px;
    font-size: 11px;
  }

  .nav-group-menu {
    max-height: none;
    margin: 6px 0 2px 12px;
    overflow: visible;
    padding-left: 10px;
  }

  .nav-group-menu .nav-tab {
    min-height: 42px;
    font-size: 11px;
  }

  .sidebar-footer {
    display: none;
    grid-column: 1 / -1;
    margin-top: 10px;
    padding-top: 10px;
  }

  .sidebar.mobile-nav-open .sidebar-footer {
    display: grid;
  }

  .user-card {
    display: flex;
  }
}

@media (max-width: 620px) {
  .main {
    padding: 14px;
  }

  .topbar {
    align-items: flex-start;
  }

  .top-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .onboarding-topbar-button {
    width: 152px;
  }

  .filter-toolbar,
  .onboarding-topbar-copy small {
    max-width: 75px;
  }
}

@media (max-width: 420px) {
  .topbar .date-chip {
    display: none;
  }
}
