@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800&display=swap');

:root {
  --primary: #059669;
  --primary-dark: #047857;
  --primary-deep: #065f46;
  --primary-light: #d1fae5;
  --primary-soft: #ecfdf5;
  --accent: #f59e0b;
  --bg-page: #eef2f6;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --border-color: #e2e8f0;
  --input-bg: #f8fafc;
  --danger: #e11d48;
  --danger-bg: #fff1f2;
  --info: #2563eb;
  --info-bg: #eff6ff;
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 26px;
  --shadow-card: 0 8px 24px -4px rgba(15, 23, 42, 0.06), 0 2px 6px -1px rgba(15, 23, 42, 0.03);
  --shadow-float: 0 16px 36px -6px rgba(15, 23, 42, 0.14);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  font-family: 'Hind Siliguri', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ==================== COMPACT MOBILE-FIRST TOP BAR ==================== */
.top-nav-bar {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.85);
  padding: 8px 12px;
}

.top-nav-inner {
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

body.admin-mode .top-nav-inner {
  max-width: 960px;
}

.brand-mini {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-main);
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-mini-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-deep));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.nav-mode-Readouts {
  display: flex;
  align-items: center;
  background: #f1f5f9;
  padding: 3px;
  border-radius: 999px;
  gap: 2px;
  flex-shrink: 0;
}

.btn-mode-switch {
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  font-family: inherit;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.btn-mode-switch.active {
  background: #ffffff;
  color: var(--primary-deep);
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

/* ==================== MOBILE APP SHELL CONTAINER (SINGLE UNIFIED BOX) ==================== */
.mobile-app-shell {
  max-width: 460px;
  margin: 0 auto;
  padding: 14px 12px 40px;
}

.unified-order-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: 0 12px 32px -6px rgba(15, 23, 42, 0.08), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.9);
}

/* ==================== NATIVE APP STOREFRONT HEADER SECTION ==================== */
.app-store-card {
  background: transparent;
}

.store-cover-banner {
  height: 76px;
  background: linear-gradient(125deg, #064e3b 0%, var(--primary) 55%, #0d9488 100%);
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 10px 14px;
}

.store-cover-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1px, transparent 1px);
  background-size: 14px 14px;
  opacity: 0.6;
}

.verified-badge-top {
  position: relative;
  z-index: 2;
  background: rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(6px);
  color: #ecfdf5;
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.store-profile-body {
  padding: 0 16px 16px;
  position: relative;
}

.store-avatar-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-top: -36px;
  margin-bottom: 10px;
  position: relative;
  z-index: 3;
}

.shop-logo-wrap {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  background: #14110f;
  border: 3.5px solid #ffffff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

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

.default-logo-svg {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 30% 30%, #2e2418, #0c0a08);
  color: #fbbf24;
}

.store-quick-btns {
  display: flex;
  gap: 6px;
}

.btn-store-action {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 12px;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid var(--border-color);
  background: #f8fafc;
  color: #334155;
  transition: all 0.15s ease;
}

.btn-store-action.wa {
  background: #ecfdf5;
  color: #059669;
  border-color: #a7f3d0;
}

.btn-store-action:active {
  transform: scale(0.96);
}

.shop-title {
  font-size: 1.32rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.shop-subtitle {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 2px;
  margin-bottom: 12px;
}

/* Side-by-Side 2-Column Delivery Charge Cards on Mobile */
.delivery-grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.delivery-mini-card {
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  padding: 10px 11px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
}

.delivery-mini-card.active-zone {
  background: var(--primary-soft);
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.12);
}

.dmc-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  margin-bottom: 3px;
}

.dmc-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #1e293b;
}

.dmc-price {
  background: var(--primary-light);
  color: var(--primary-deep);
  font-size: 0.82rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 8px;
}

.dmc-time {
  font-size: 0.71rem;
  color: #64748b;
}

.sub-dhaka-strip {
  margin-top: 8px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ==================== DRAFT ORDER PRODUCT SECTION (INSIDE UNIFIED BOX) ==================== */
.draft-order-banner {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdfa 100%);
  border-top: 1.5px dashed #a7f3d0;
  border-bottom: 1.5px dashed #a7f3d0;
  padding: 14px 18px;
}

.draft-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.draft-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--primary);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 999px;
}

.draft-product-title {
  font-size: 1.02rem;
  font-weight: 800;
  color: #064e3b;
  margin-bottom: 10px;
}

.draft-controls-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #ffffff;
  border: 1px solid #a7f3d0;
  border-radius: 12px;
  padding: 8px 12px;
}

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

.btn-qty {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-qty:active {
  background: var(--primary);
  color: #ffffff;
}

/* ==================== MOBILE FORM SECTION (INSIDE UNIFIED BOX) ==================== */
.mobile-form-card {
  background: transparent;
  padding: 18px 18px 16px;
  border-top: 1px solid #f1f5f9;
}

.m-form-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.m-form-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
}

.m-form-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.m-step-dots {
  display: flex;
  align-items: center;
  gap: 5px;
}

.m-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #64748b;
  font-size: 0.7rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.m-dot.done {
  background: var(--primary);
  color: #ffffff;
}

/* Form Fields Optimized for Mobile Touch (16px font prevents iOS auto-zoom) */
.form-group {
  margin-bottom: 14px;
}

.form-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.86rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 6px;
}

.req-star {
  color: var(--danger);
  margin-left: 2px;
}

.validation-hint {
  font-size: 0.73rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}

.validation-hint.ok {
  background: #d1fae5;
  color: #065f46;
}

.validation-hint.err {
  background: #ffe4e6;
  color: #e11d48;
}

.input-icon-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  color: #64748b;
  display: flex;
  align-items: center;
  pointer-events: none;
  transition: color 0.18s;
}

.input-icon-wrap:focus-within .input-icon {
  color: var(--primary);
}

.form-control {
  width: 100%;
  min-height: 48px;
  padding: 11px 14px 11px 42px;
  font-size: 16px; /* Prevents mobile browser zoom on focus */
  font-family: inherit;
  color: var(--text-main);
  background: var(--input-bg);
  border: 1.5px solid var(--border-color);
  border-radius: 14px;
  transition: all 0.18s ease;
  outline: none;
}

.form-control.no-icon {
  padding-left: 14px;
}

.form-control::placeholder {
  color: #94a3b8;
  font-size: 0.92rem;
}

.form-control:focus {
  background: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 0 0 3.5px rgba(5, 150, 105, 0.12);
}

textarea.form-control {
  min-height: 82px;
  resize: vertical;
  padding: 12px 14px;
  line-height: 1.45;
}

/* Horizontal Scrollable Quick Chips (Single clean row on mobile!) */
.h-scroll-chips {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: 8px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.h-scroll-chips::-webkit-scrollbar {
  display: none;
}

.quick-chip-tag {
  font-size: 0.74rem;
  font-weight: 700;
  color: #64748b;
  white-space: nowrap;
  flex-shrink: 0;
}

.quick-chip {
  padding: 5px 12px;
  border-radius: 999px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-size: 0.78rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.quick-chip.active,
.quick-chip:active {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
}

/* Touch Picker Trigger Button (Opens Smooth Bottom Sheet) */
.touch-picker-btn {
  width: 100%;
  min-height: 50px;
  padding: 11px 14px;
  background: var(--input-bg);
  border: 1.5px solid var(--border-color);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text-main);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.18s ease;
}

.touch-picker-btn.placeholder {
  color: #94a3b8;
  font-weight: 400;
}

.touch-picker-btn.disabled {
  background: #f1f5f9;
  color: #94a3b8;
  opacity: 0.75;
  cursor: not-allowed;
}

.touch-picker-btn.selected {
  background: var(--primary-soft);
  border-color: var(--primary);
  color: var(--primary-deep);
}

.picker-left {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
}

.picker-left span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Optional Product Collapsible Pill */
.optional-product-box {
  background: #f8fafc;
  border: 1.5px dashed #cbd5e1;
  border-radius: 14px;
  padding: 11px 13px;
  margin-bottom: 14px;
}

.optional-product-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.83rem;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
}

/* ==================== COMPACT DIGITAL RECEIPT SECTION (INSIDE UNIFIED BOX) ==================== */
.mobile-receipt-card {
  background: #f8fafc;
  border-top: 2px dashed #e2e8f0;
  padding: 16px 18px 20px;
  position: relative;
}

.m-receipt-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.92rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 10px;
}

.m-receipt-cod-badge {
  font-size: 0.72rem;
  background: var(--primary-light);
  color: var(--primary-deep);
  padding: 2px 9px;
  border-radius: 99px;
  font-weight: 700;
}

.m-receipt-body {
  padding: 0;
}

.bill-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.86rem;
  color: var(--text-secondary);
  padding: 4px 0;
}

.bill-row.total {
  border-top: 1.5px dashed #cbd5e1;
  margin-top: 8px;
  padding-top: 10px;
  font-size: 0.96rem;
  font-weight: 800;
  color: #0f172a;
}

.bill-row.total .amount {
  color: var(--primary);
  font-size: 1.15rem;
}

.btn-confirm-order {
  width: 100%;
  min-height: 52px;
  padding: 14px 20px;
  border: none;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #ffffff;
  font-size: 1.02rem;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 8px 20px -4px rgba(5, 150, 105, 0.4);
  transition: transform 0.15s ease;
  margin-top: 12px;
}

.btn-confirm-order:active {
  transform: scale(0.98);
}

/* ==================== STICKY BOTTOM MOBILE CHECKOUT BAR ==================== */
.sticky-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 88;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid #e2e8f0;
  box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.08);
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
}

.sticky-bottom-inner {
  max-width: 460px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.sticky-bill-info {
  display: flex;
  flex-direction: column;
}

.sticky-bill-label {
  font-size: 0.72rem;
  color: #64748b;
  font-weight: 600;
}

.sticky-bill-amount {
  font-size: 1.12rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

.btn-sticky-submit {
  flex: 1;
  max-width: 240px;
  min-height: 46px;
  padding: 10px 18px;
  border: none;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #ffffff;
  font-size: 0.94rem;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 6px 16px -3px rgba(5, 150, 105, 0.4);
}

.btn-sticky-submit:active {
  transform: scale(0.97);
}

/* ==================== MOBILE BOTTOM-SHEET LOCATION PICKER ==================== */
.bottom-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(3px);
  z-index: 220;
  display: none;
  align-items: flex-end;
  justify-content: center;
}

.bottom-sheet-backdrop.show {
  display: flex;
}

.bottom-sheet-card {
  width: 100%;
  max-width: 480px;
  height: 82vh;
  max-height: 640px;
  background: #ffffff;
  border-radius: 24px 24px 0 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 -12px 36px rgba(15, 23, 42, 0.2);
  animation: slideUpSheet 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUpSheet {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.sheet-handle-bar {
  width: 42px;
  height: 5px;
  background: #cbd5e1;
  border-radius: 999px;
  margin: 10px auto 4px;
  flex-shrink: 0;
}

.sheet-header {
  padding: 8px 16px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #f1f5f9;
  flex-shrink: 0;
}

.sheet-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
}

.btn-sheet-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: #f1f5f9;
  color: #475569;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.sheet-search-wrap {
  padding: 10px 16px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  flex-shrink: 0;
}

.sheet-search-input {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border: 1.5px solid #cbd5e1;
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  outline: none;
  background: #ffffff;
}

.sheet-search-input:focus {
  border-color: var(--primary);
}

.sheet-list {
  flex: 1;
  overflow-y: auto;
  list-style: none;
  padding: 6px 10px 24px;
}

.sheet-list-item {
  padding: 13px 14px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1e293b;
  cursor: pointer;
  border-bottom: 1px solid #f8fafc;
}

.sheet-list-item:active,
.sheet-list-item.selected {
  background: var(--primary-soft);
  color: var(--primary-deep);
  font-weight: 700;
}

.option-zone-badge {
  font-size: 0.74rem;
  padding: 3px 9px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-weight: 700;
}

.sheet-list-item.selected .option-zone-badge {
  background: var(--primary-light);
  color: var(--primary-deep);
}

/* ==================== UPGRADED MODERN SaaS ADMIN DASHBOARD ==================== */
.admin-container {
  max-width: 1020px;
  margin: 14px auto 70px;
  padding: 0 12px;
}

/* Admin Hero Command Banner */
.admin-hero-card {
  background: linear-gradient(130deg, #0f172a 0%, #113c35 55%, #065f46 100%);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 22px 22px 20px;
  margin-bottom: 16px;
  box-shadow: 0 16px 36px -8px rgba(15, 23, 42, 0.22);
  position: relative;
  overflow: hidden;
}

.admin-hero-card::before {
  content: "";
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(52, 211, 153, 0.22) 0%, transparent 70%);
  top: -100px;
  right: -60px;
  pointer-events: none;
}

.admin-hero-top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}

.admin-brand-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-avatar-badge {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.12);
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  backdrop-filter: blur(8px);
  flex-shrink: 0;
}

.admin-hero-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-admin-glass {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 15px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: all 0.18s ease;
}

.btn-admin-glass:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.btn-admin-glass.primary-glow {
  background: #10b981;
  border-color: #34d399;
  color: #022c22;
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.35);
}

/* Segmented Admin Navigation Bar */
.admin-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  background: #ffffff;
  padding: 6px;
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
  margin-bottom: 18px;
}

@media (max-width: 680px) {
  .admin-tabs {
    grid-template-columns: repeat(2, 1fr);
  }
}

.admin-tab-btn {
  padding: 11px 12px;
  border-radius: 13px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 0.84rem;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: all 0.18s ease;
  text-align: center;
}

.admin-tab-btn:hover {
  background: #f8fafc;
  color: var(--primary-deep);
}

.admin-tab-btn.active {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #ffffff;
  box-shadow: 0 6px 16px -3px rgba(5, 150, 105, 0.35);
}

.tab-count-pill {
  background: rgba(15, 23, 42, 0.12);
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 0.74rem;
}

.admin-tab-btn.active .tab-count-pill {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* Admin Section Cards */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(226, 232, 240, 0.9);
  padding: 20px 18px;
}

.admin-card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.06rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 4px;
}

.admin-card-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

/* Colorful KPI Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

@media (min-width: 740px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  gap: 13px;
  position: relative;
  overflow: hidden;
}

.stat-icon-box {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.stat-icon-box.slate { background: #f1f5f9; color: #0f172a; }
.stat-icon-box.amber { background: #fef3c7; color: #d97706; }
.stat-icon-box.emerald { background: #d1fae5; color: #059669; }
.stat-icon-box.blue { background: #dbeafe; color: #2563eb; }

.stat-label {
  font-size: 0.77rem;
  color: var(--text-secondary);
  font-weight: 700;
}

.stat-value {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
  margin-top: 2px;
}

.grid-2col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 820px) {
  .grid-2col {
    grid-template-columns: 1.08fr 0.92fr;
  }
}

/* Chat Bubble Preview in Draft Link Studio */
.chat-preview-phone {
  background: #e5ddd5;
  background-image: radial-gradient(rgba(0,0,0,0.04) 1px, transparent 0);
  background-size: 16px 16px;
  border-radius: 18px;
  padding: 16px 14px;
  border: 1.5px solid #cbd5e1;
  margin-bottom: 14px;
}

.chat-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 700;
  color: #475569;
  margin-bottom: 8px;
}

.chat-bubble-box {
  background: #dcf8c6;
  border-radius: 14px 14px 2px 14px;
  padding: 12px 14px;
  font-size: 0.83rem;
  color: #111827;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.5;
  position: relative;
}

.generated-link-box {
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px;
}

.code-preview-area {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.81rem;
  word-break: break-all;
  color: var(--primary-deep);
  font-weight: 600;
  margin: 8px 0;
  white-space: pre-wrap;
}

/* Courier Export Bar & Status Filter Pills */
.courier-export-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.btn-courier-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 13px;
  font-size: 0.83rem;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: all 0.16s ease;
}

.btn-courier-card.steadfast {
  background: #ecfdf5;
  color: #047857;
  border-color: #a7f3d0;
}

.btn-courier-card.pathao {
  background: #fff1f2;
  color: #be123c;
  border-color: #fecdd3;
}

.btn-courier-card.redx {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.btn-courier-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

.status-filter-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin: 14px 0 12px;
  scrollbar-width: none;
}

.status-filter-pills::-webkit-scrollbar {
  display: none;
}

.status-pill-btn {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #475569;
  font-size: 0.79rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s;
}

.status-pill-btn.active {
  background: #0f172a;
  color: #ffffff;
  border-color: #0f172a;
}

/* Modern Order Cards Grid (Works great on both Mobile & Desktop!) */
.orders-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 820px) {
  .orders-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.merchant-order-card {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.merchant-order-card:hover {
  border-color: #94a3b8;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.moc-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f1f5f9;
}

.moc-inv-badge {
  font-weight: 800;
  font-size: 0.92rem;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 6px;
}

.moc-time {
  font-size: 0.74rem;
  color: #64748b;
  font-weight: 500;
}

.moc-customer-box {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.moc-cust-name {
  font-size: 1rem;
  font-weight: 800;
  color: #0f172a;
}

.moc-cust-phone {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-top: 1px;
}

.moc-address-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 0.82rem;
}

.moc-loc-tag {
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.moc-product-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--primary-soft);
  border: 1px solid #a7f3d0;
  border-radius: 12px;
  padding: 10px 12px;
}

.moc-cod-amount {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--primary-deep);
  white-space: nowrap;
}

.moc-footer-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 8px;
  border-top: 1px dashed #e2e8f0;
}

.btn-group-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 11px;
  font-size: 0.82rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
  transition: all 0.15s ease;
}

.btn-primary { background: var(--primary); color: #ffffff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: #ffffff; border-color: #cbd5e1; color: #334155; }
.btn-outline:hover { background: #f8fafc; border-color: #94a3b8; }
.btn-danger { background: var(--danger-bg); color: var(--danger); border-color: #fecdd3; }
.btn-info { background: var(--info-bg); color: var(--info); border-color: #bfdbfe; }

.preset-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}

.preset-chip {
  font-size: 0.78rem;
  padding: 6px 11px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #334155;
  cursor: pointer;
  font-family: inherit;
  font-weight: 700;
  transition: all 0.15s;
}

.preset-chip:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
  color: var(--primary-deep);
}

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

.orders-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.orders-table th,
.orders-table td {
  padding: 12px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  vertical-align: top;
}

.orders-table th {
  background: #f8fafc;
  color: #475569;
  font-weight: 700;
  white-space: nowrap;
}

.status-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.73rem;
  font-weight: 800;
}

.status-Pending { background: #fef3c7; color: #b45309; }
.status-Confirmed { background: #dbeafe; color: #1d4ed8; }
.status-Shipped { background: #ede9fe; color: #6d28d9; }
.status-Delivered { background: #d1fae5; color: #065f46; }
.status-Cancelled { background: #ffe4e6; color: #be123c; }

.ratio-progress-wrap {
  height: 13px;
  background: #ffe4e6;
  border-radius: 999px;
  overflow: hidden;
  margin: 10px 0;
}

.ratio-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #059669, #10b981);
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  z-index: 230;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 12px;
}

.modal-backdrop.show {
  display: flex;
}

.modal-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  max-width: 480px;
  width: 100%;
  padding: 20px 18px;
  box-shadow: var(--shadow-float);
  max-height: 92vh;
  overflow-y: auto;
}

.invoice-box {
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  padding: 14px;
  background: #ffffff;
  margin: 12px 0;
}

.invoice-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 2px solid #0f172a;
  padding-bottom: 10px;
  margin-bottom: 10px;
}

.invoice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  font-size: 0.82rem;
  margin-bottom: 12px;
}

.invoice-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin-bottom: 10px;
}

.invoice-table th,
.invoice-table td {
  border: 1px solid #cbd5e1;
  padding: 6px 8px;
}

.invoice-table th {
  background: #f1f5f9;
}

.toast-container {
  position: fixed;
  top: 64px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 320;
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 92%;
  max-width: 400px;
  pointer-events: none;
}

.toast {
  background: #0f172a;
  color: #ffffff;
  padding: 11px 16px;
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 600;
  box-shadow: var(--shadow-float);
  display: flex;
  align-items: center;
  gap: 8px;
}

.hidden {
  display: none !important;
}

@media print {
  body * {
    visibility: hidden;
  }
  #printableInvoiceArea,
  #printableInvoiceArea * {
    visibility: visible;
  }
  #printableInvoiceArea {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    border: none;
    box-shadow: none;
  }
  .no-print {
    display: none !important;
  }
}
