:root {
  --adm-bg: #F6F7F9;
  --adm-surface: #FFFFFF;
  --adm-surface-2: #F8FAFC;
  --adm-border: #E6E8EE;
  --adm-text: #475569;
  --adm-heading: #0F172A;
  --adm-accent: #C49A45;
  --adm-accent-hover: #AD8432;
  --adm-espresso: #382212;
  --adm-success: #16A34A;
  --adm-warning: #D97706;
  --adm-danger: #DC2626;
  --adm-shadow-sm: 0 2px 10px rgba(15, 23, 42, 0.04);
  --adm-shadow-md: 0 10px 28px rgba(15, 23, 42, 0.08);
  --adm-sidebar-w: 256px;
  --adm-sidebar-collapsed: 74px;
}

body.admin-body, body.admin-login-split-body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--adm-bg);
  color: var(--adm-text);
  margin: 0;
  min-height: 100vh;
}

.admin-body .text-white,
.login-form-pane .text-white {
  color: var(--adm-heading) !important;
}
.admin-body .text-light,
.login-form-pane .text-light {
  color: var(--adm-text) !important;
}
.admin-body .text-secondary,
.login-form-pane .text-secondary {
  color: #64748B !important;
}
.admin-body .border-dark-subtle,
.login-form-pane .border-dark-subtle {
  border-color: var(--adm-border) !important;
}
.admin-body .bg-dark {
  background-color: #F1F5F9 !important;
  color: #334155 !important;
}
.admin-body .badge.bg-dark {
  background-color: #F1F5F9 !important;
  color: #334155 !important;
  border-color: #E2E8F0 !important;
}
.admin-body .btn.btn-indigo,
.admin-body .btn.btn-primary,
.admin-body .btn.btn-success,
.admin-body .btn.btn-danger {
  color: #FFFFFF !important;
}
.admin-body .badge.bg-success,
.admin-body .badge.bg-primary,
.admin-body .badge.bg-danger,
.admin-body .badge.bg-info,
.admin-body .badge.bg-warning {
  color: #FFFFFF;
}
.admin-body .badge.bg-opacity-25 {
  color: inherit;
}

.login-split-shell {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 100vh;
}
@media (min-width: 992px) {
  .login-split-shell {
    grid-template-columns: 1.05fr 0.95fr;
  }
}

.login-visual-pane {
  position: relative;
  overflow: hidden;
  padding: 44px 52px;
  flex-direction: column;
  background-color: #24140B;
}

.login-visual-bg {
  position: absolute;
  inset: 0;
  background-image: url('https://images.unsplash.com/photo-1501339847302-ac426a4a7cbb?w=1400&q=80');
  background-size: cover;
  background-position: center;
  transform: scale(1.03);
}

.login-visual-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(155deg, rgba(36, 20, 11, 0.88) 0%, rgba(56, 34, 18, 0.8) 55%, rgba(28, 15, 8, 0.92) 100%);
}

.login-visual-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  height: 100%;
  color: #FAF6EE;
}

.login-brand-pill {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(196, 154, 69, 0.22);
  border: 1px solid rgba(243, 213, 141, 0.35);
  color: #F3D58D;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.login-eyebrow {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #F3D58D;
  background: rgba(196, 154, 69, 0.2);
  border: 1px solid rgba(243, 213, 141, 0.3);
  padding: 5px 12px;
  border-radius: 999px;
}

.login-hero-heading {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 34px;
  line-height: 1.24;
  color: #FFFFFF;
  max-width: 480px;
}

.login-feature-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 440px;
}

.login-feature-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.lf-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(243, 213, 141, 0.2);
  color: #F3D58D;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.login-visual-footer {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.status-dot-live {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22C55E;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.25);
}

.login-form-pane {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 36px 24px;
  background: #FFFFFF;
}

.login-form-box {
  width: 100%;
  max-width: 410px;
}

.quick-login-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--adm-heading);
}

.quick-login-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #FAF8F4;
  border: 1.5px solid #EAE2D3;
  cursor: pointer;
  transition: all 180ms ease;
}

.quick-login-card:hover {
  border-color: var(--adm-accent);
  background: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: var(--adm-shadow-md);
}

.ql-badge {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.ql-badge.kasir { background: rgba(196, 154, 69, 0.16); color: #A67B28; }
.ql-badge.owner { background: rgba(22, 163, 74, 0.14); color: #16A34A; }

.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #94A3B8;
  font-size: 12px;
}
.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--adm-border);
}

.input-icon-wrap { position: relative; }
.input-left-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94A3B8;
  pointer-events: none;
}
.admin-input.has-left-icon {
  padding-left: 40px !important;
  height: 46px;
}
.admin-input-addon {
  background-color: #FFFFFF !important;
  border: 1px solid #CBD5E1 !important;
  border-right: none !important;
  color: #94A3B8 !important;
}

.btn-indigo-glow {
  background: linear-gradient(135deg, #CFA44C 0%, #B4872E 100%);
  color: #FFFFFF !important;
  border: none;
  height: 46px;
  border-radius: 11px;
  box-shadow: 0 8px 20px rgba(196, 154, 69, 0.28);
  transition: transform 160ms ease, filter 160ms ease;
}
.btn-indigo-glow:hover {
  filter: brightness(0.96);
  color: #FFFFFF !important;
  transform: translateY(-1px);
}

.login-back-link:hover { color: var(--adm-heading) !important; }

.admin-wrapper {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: var(--adm-sidebar-w);
  flex-shrink: 0;
  background: #FFFFFF;
  border-right: 1px solid var(--adm-border);
  position: sticky;
  top: 0;
  height: 100vh;
  transition: width 200ms ease;
  z-index: 1020;
}

.admin-wrapper.sidebar-collapsed .admin-sidebar {
  width: var(--adm-sidebar-collapsed);
}
.admin-wrapper.sidebar-collapsed .sidebar-brand-text,
.admin-wrapper.sidebar-collapsed .nav-label,
.admin-wrapper.sidebar-collapsed .nav-badge {
  display: none !important;
}
.admin-wrapper.sidebar-collapsed .admin-nav-link {
  justify-content: center;
  padding: 11px;
}

.sidebar-brand {
  height: 64px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--adm-border);
}

.sidebar-brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: rgba(196, 154, 69, 0.14);
  color: var(--adm-accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sidebar-scroll {
  overflow-y: auto;
  padding: 14px 12px;
  scrollbar-width: thin;
  scrollbar-color: #E2E8F0 transparent;
}
.sidebar-scroll::-webkit-scrollbar { width: 5px; }
.sidebar-scroll::-webkit-scrollbar-thumb { background: #E2E8F0; border-radius: 999px; }

.sidebar-footer {
  padding: 12px;
  border-top: 1px solid var(--adm-border);
}

.admin-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 11px;
  color: #475569;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 600;
  transition: all 160ms ease;
}

.admin-nav-link:hover {
  background: #F8FAFC;
  color: var(--adm-heading);
}

.admin-nav-link.active {
  background: rgba(196, 154, 69, 0.14);
  color: #9A7021;
  font-weight: 700;
}

.admin-nav-link .nav-icon {
  font-size: 1.08rem;
  flex-shrink: 0;
}

.nav-badge {
  margin-left: auto;
  background: var(--adm-accent);
  color: #FFFFFF;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 8px;
  border-radius: 999px;
}

.admin-offcanvas {
  background: #FFFFFF !important;
  border-right: 1px solid var(--adm-border) !important;
  width: 268px !important;
}

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

.admin-topbar {
  height: 64px;
  padding: 0 24px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--adm-border);
  position: sticky;
  top: 0;
  z-index: 1010;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.admin-content {
  flex: 1;
  padding: 24px;
}

.admin-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--adm-border);
  background: #FFFFFF;
  font-size: 12.5px;
  color: #64748B;
}

.admin-card {
  background: #FFFFFF;
  border: 1px solid var(--adm-border);
  border-radius: 16px;
  padding: 20px;
  box-shadow: var(--adm-shadow-sm);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--adm-shadow-md);
}

.stat-label {
  font-size: 12.5px;
  font-weight: 600;
  color: #64748B;
  margin-bottom: 6px;
}

.stat-value {
  font-size: 23px;
  font-weight: 800;
  color: var(--adm-heading);
}

.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.bg-indigo-soft  { background: rgba(196, 154, 69, 0.14); }
.bg-success-soft { background: rgba(22, 163, 74, 0.12); }
.bg-warning-soft { background: rgba(217, 119, 6, 0.12); }
.bg-info-soft    { background: rgba(2, 132, 199, 0.12); }
.text-indigo     { color: #A67B28 !important; }

.btn-indigo {
  background: linear-gradient(135deg, #CFA44C 0%, #B4872E 100%);
  color: #FFFFFF !important;
  border: none;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(196, 154, 69, 0.25);
  transition: filter 150ms ease, transform 150ms ease;
}
.btn-indigo:hover {
  filter: brightness(0.95);
  color: #FFFFFF !important;
}

.btn-espresso {
  background: #2C1A0E;
  color: #FFFFFF !important;
  border: none;
  border-radius: 10px;
}
.btn-espresso:hover {
  background: #3F2717;
  color: #FFFFFF !important;
}

.btn-soft-success {
  background: #ECFDF5;
  color: #15803D !important;
  border: 1px solid #BBF7D0;
  border-radius: 10px;
}
.btn-soft-success:hover { background: #DCFCE7; }

.btn-soft-danger {
  background: #FEF2F2;
  color: #DC2626 !important;
  border: 1px solid #FECACA;
  border-radius: 10px;
}
.btn-soft-danger:hover { background: #FEE2E2; }

.order-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.order-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  background: #F8FAFC;
  border: 1px solid var(--adm-border);
  color: #475569;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 150ms ease;
}
.order-filter-pill:hover {
  border-color: #CBD5E1;
  color: #0F172A;
}
.order-filter-pill.active {
  background: #2C1A0E;
  border-color: #2C1A0E;
  color: #FFFFFF;
}
.order-filter-pill .pill-count {
  background: rgba(15, 23, 42, 0.08);
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.order-filter-pill.active .pill-count {
  background: rgba(255, 255, 255, 0.2);
  color: #FFFFFF;
}

.live-sync-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #15803D;
  background: #F0FDF4;
  border: 1px solid #DCFCE7;
  padding: 5px 12px;
  border-radius: 999px;
}
.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22C55E;
}

.order-card-modern {
  transition: transform 180ms ease, box-shadow 180ms ease;
}
.order-card-modern:hover {
  transform: translateY(-2px);
  box-shadow: var(--adm-shadow-md);
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
}
.status-menunggu { background: #FEF3C7; color: #B45309; }
.status-diproses { background: #EEF2FF; color: #4338CA; }
.status-siap     { background: #E0F2FE; color: #0369A1; }
.status-selesai  { background: #DCFCE7; color: #15803D; }
.status-batal    { background: #FEE2E2; color: #B91C1C; }

.meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 8px;
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  color: #475569;
  font-size: 11.5px;
  font-weight: 600;
}
.meta-chip.pay-paid    { background: #F0FDF4; border-color: #DCFCE7; color: #15803D; }
.meta-chip.pay-pending { background: #FFFBEB; border-color: #FEF3C7; color: #B45309; }
.meta-chip.pay-failed  { background: #FEF2F2; border-color: #FEE2E2; color: #B91C1C; }

.order-items-surface {
  background: #F8FAFC;
  border: 1px solid #EEF0F4;
  border-radius: 12px;
  padding: 10px 12px;
  max-height: 195px;
  overflow-y: auto;
}
.order-item-line {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 6px 0;
  border-bottom: 1px dashed #E2E8F0;
}
.order-item-line:last-child { border-bottom: none; padding-bottom: 0; }
.order-item-line:first-child { padding-top: 0; }

.btn-dark-outline {
  background: #FFFFFF;
  color: #334155;
  border: 1px solid #CBD5E1;
  border-radius: 10px;
}
.btn-dark-outline:hover {
  background: #F8FAFC;
  color: #0F172A;
  border-color: #94A3B8;
}

.btn-icon {
  color: #475569;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 6px 9px;
}
.btn-icon:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.admin-input {
  background-color: #FFFFFF !important;
  border: 1px solid #CBD5E1 !important;
  color: #0F172A !important;
  border-radius: 10px !important;
}
.admin-input::placeholder {
  color: #94A3B8 !important;
}
.admin-input:focus {
  border-color: var(--adm-accent) !important;
  box-shadow: 0 0 0 3px rgba(196, 154, 69, 0.18) !important;
}

.user-avatar-chip {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #CFA44C 0%, #B4872E 100%);
  color: #FFFFFF;
  font-weight: 700;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.admin-table {
  --bs-table-bg: #FFFFFF;
  --bs-table-color: #334155;
  --bs-table-border-color: #EEF0F4;
  --bs-table-striped-bg: #FAFBFD;
  --bs-table-hover-bg: #F8FAFC;
}
.admin-table thead th {
  position: sticky;
  top: 0;
  background: #F8FAFC !important;
  color: #64748B !important;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--adm-border) !important;
  padding: 13px 16px;
}
.admin-table tbody td {
  padding: 13px 16px;
  font-size: 13.5px;
  background: #FFFFFF !important;
  color: #334155 !important;
  border-color: #F1F5F9 !important;
}
.admin-table tbody tr:hover td {
  background: #FAFBFD !important;
}

.admin-subitem-row {
  background: #F8FAFC;
  border: 1px solid var(--adm-border);
  border-radius: 10px;
}

.recent-order-item {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  background: #F8FAFC;
  border: 1px solid var(--adm-border);
  transition: all 150ms ease;
}
.recent-order-item:hover {
  border-color: var(--adm-accent);
  background: #FFFFFF;
  box-shadow: var(--adm-shadow-sm);
}

.order-items-box {
  max-height: 190px;
  overflow-y: auto;
  padding-right: 4px;
}

.drag-handle { cursor: grab; color: #94A3B8; }
.drag-handle:active { cursor: grabbing; }

.cat-icon-box {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(196, 154, 69, 0.14);
  color: #A67B28;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.subcat-row {
  background: #F8FAFC;
  padding: 9px 14px;
  border-radius: 10px;
  border: 1px solid var(--adm-border);
}

.check-tile {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #F8FAFC;
  border: 1px solid var(--adm-border);
  cursor: pointer;
  transition: all 150ms ease;
}
.check-tile input { accent-color: var(--adm-accent); }
.check-tile:has(input:checked) {
  border-color: var(--adm-accent);
  background: rgba(196, 154, 69, 0.1);
}

.qr-preview-box {
  background: #FFFFFF;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--adm-border);
  display: inline-block;
  margin: 0 auto;
}

.brand-preview-box {
  min-width: 72px;
  height: 60px;
  padding: 6px;
  border-radius: 12px;
  background: #F8FAFC;
  border: 1px dashed #CBD5E1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.admin-tabs .nav-link {
  color: #64748B;
  background: #FFFFFF;
  border: 1px solid var(--adm-border);
  border-radius: 11px;
  font-size: 13.5px;
  font-weight: 600;
  padding: 9px 16px;
}
.admin-tabs .nav-link:hover {
  color: var(--adm-heading);
  border-color: #CBD5E1;
}
.admin-tabs .nav-link.active {
  background: linear-gradient(135deg, #CFA44C 0%, #B4872E 100%);
  border-color: transparent;
  color: #FFFFFF;
  box-shadow: 0 4px 12px rgba(196, 154, 69, 0.25);
}

.modal-backdrop.show {
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.admin-modal {
  background: #FFFFFF;
  border: 1px solid var(--adm-border);
  border-radius: 18px;
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.18);
}

.admin-toast-container {
  position: fixed;
  top: 76px;
  right: 22px;
  z-index: 1090;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 350px;
}
.admin-toast {
  background: #FFFFFF;
  color: #0F172A;
  border: 1px solid var(--adm-border);
  border-left: 4px solid var(--adm-accent);
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
  display: flex;
  align-items: center;
  gap: 10px;
}
.admin-toast.success { border-left-color: var(--adm-success); }
.admin-toast.danger  { border-left-color: var(--adm-danger); }
.admin-toast.warning { border-left-color: var(--adm-warning); }

@media (max-width: 991.98px) {
  .admin-content { padding: 14px; }
  .admin-topbar { padding: 0 14px; }
}
