:root {
  --primary: #ff5d8f;
  --primary-dark: #e04375;
  --primary-soft: #fff0f5;
  --secondary: #4ea8de;
  --accent: #ffd166;
  --bg: #fdfaf9;
  --surface: #ffffff;
  --text: #2b2329;
  --text-muted: #6e626a;
  --border: #f0e1e7;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(255, 93, 143, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Nunito', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.hidden {
  display: none !important;
}

.container {
  max-width: 1260px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Announcement Bar */
.announcement-bar {
  background: linear-gradient(90deg, var(--primary), #ff85a8);
  color: #fff;
  text-align: center;
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 700;
}

/* Header */
.site-header {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  gap: 16px;
  flex-wrap: wrap;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
}

.store-logo {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
  border: 2px solid var(--primary-soft);
  background: #fff;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.store-name {
  font-size: 1.45rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1.1;
}

.store-tagline {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
}

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

.guest-mobile-bar {
  display: flex;
  align-items: center;
  background: var(--primary-soft);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 6px 4px 12px;
  gap: 6px;
}

.guest-mobile-bar input {
  border: none;
  background: transparent;
  outline: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
}

.btn-tiny {
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
}

.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  border: 1px solid var(--border);
  padding: 8px 14px;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 800;
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
}

.nav-btn:hover {
  border-color: var(--primary);
  transform: translateY(-1px);
}

.cart-btn {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.cart-btn .badge {
  background: #fff;
  color: var(--primary);
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 900;
}

.admin-btn {
  background: #f3f4f6;
}

/* Hero Section */
.hero-section {
  background: linear-gradient(135deg, #fff3f7 0%, #eef8ff 100%);
  padding: 34px 0;
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 32px;
  align-items: center;
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
}

.hero-pill {
  display: inline-block;
  background: #fff;
  color: var(--primary);
  padding: 5px 14px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.82rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
  margin-bottom: 10px;
}

.hero-content h1 {
  font-size: 2.2rem;
  font-weight: 900;
  margin-bottom: 10px;
  color: var(--text);
}

.hero-content p {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 18px;
}

.hero-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

@media (max-width: 600px) {
  .hero-steps {
    grid-template-columns: 1fr;
  }
}

.step-chip {
  background: rgba(255,255,255,0.88);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
}

.step-chip strong {
  color: var(--primary);
  font-size: 0.9rem;
}

.step-chip span {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.hero-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.hero-badge-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.trust-pill {
  background: var(--primary-soft);
  color: var(--primary-dark);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
}

.hero-quick-lookup {
  display: flex;
  gap: 8px;
  margin: 12px 0;
}

.hero-quick-lookup input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: inherit;
}

.hero-contact-note {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Catalog Section & Toolbar */
.catalog-section {
  padding: 28px 20px 60px;
}

.catalog-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
  background: #fff;
  padding: 14px 18px;
  border-radius: 14px;
  border: 1px solid var(--border);
}

.filter-controls-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.filter-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-item label {
  font-weight: 800;
  font-size: 0.88rem;
  color: var(--text);
}

.toolbar-select {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.88rem;
  background: #fdf8fa;
  color: var(--text);
  cursor: pointer;
}

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

.mb-16 { margin-bottom: 16px; }
.mt-12 { margin-top: 12px; }
.mt-6 { margin-top: 6px; }
.mb-12 { margin-bottom: 12px; }

.cat-tab {
  background: #fff;
  border: 1px solid var(--border);
  padding: 7px 15px;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.86rem;
  cursor: pointer;
  color: var(--text-muted);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cat-tab.active,
.cat-tab:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.search-box input {
  padding: 9px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  width: 240px;
  font-family: inherit;
}

/* Storefront 2-Column Main Layout (Products + Live Order Summary) */
.storefront-main-grid {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 24px;
  align-items: start;
}

@media (max-width: 1024px) {
  .storefront-main-grid {
    grid-template-columns: 1fr;
  }
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.product-card {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.product-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--primary);
  color: #fff;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
  z-index: 2;
}

.product-img-wrap {
  height: 195px;
  background: #fff6f9;
  overflow: hidden;
}

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

.product-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-cat {
  font-size: 0.74rem;
  color: var(--primary);
  font-weight: 800;
  text-transform: uppercase;
}

.product-title {
  font-size: 1rem;
  font-weight: 800;
  margin: 4px 0 6px;
}

.product-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  flex: 1;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid #f7edf1;
  gap: 8px;
  flex-wrap: wrap;
}

.price-wrap {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.price-current {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text);
}

.price-mrp {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-decoration: line-through;
}

/* Live Order Summary Sidebar Card */
.live-order-summary-card {
  background: #fff;
  border-radius: var(--radius);
  border: 2px solid var(--primary);
  padding: 20px;
  position: sticky;
  top: 86px;
  box-shadow: var(--shadow);
}

.summary-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 12px;
}

.live-summary-items {
  max-height: 260px;
  overflow-y: auto;
  margin-bottom: 12px;
}

.summary-item-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 0.86rem;
}

.summary-item-top {
  display: flex;
  justify-content: space-between;
  font-weight: 800;
}

.summary-item-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.remove-btn-tiny {
  background: #fee2e2;
  color: #b91c1c;
  border: none;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 0.74rem;
  font-weight: 800;
  cursor: pointer;
}

.live-summary-totals {
  background: #fff5f8;
  padding: 12px;
  border-radius: 10px;
  margin-bottom: 14px;
}

.summary-total-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
}

.summary-total-line.grand-total {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--primary);
  margin-top: 4px;
  padding-top: 6px;
  border-top: 1px solid var(--border);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-family: inherit;
  font-weight: 800;
  font-size: 0.92rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

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

.btn-outline {
  background: #fff;
  border-color: var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.btn-success {
  background: var(--success);
  color: #fff;
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-danger-soft {
  background: #fee2e2;
  color: #b91c1c;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.82rem;
}

.btn-lg {
  padding: 14px 22px;
  font-size: 1.02rem;
}

.btn-block {
  width: 100%;
}

.btn-icon {
  background: #f3f4f6;
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  font-weight: 900;
}

/* Admin View */
.admin-view {
  padding: 28px 0 80px;
}

.admin-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 16px;
  flex-wrap: wrap;
}

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

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: #fff;
  padding: 16px 18px;
  border-radius: 14px;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

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

.stat-value {
  font-size: 1.65rem;
  font-weight: 900;
  margin-top: 4px;
}

.text-warning { color: var(--warning); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-muted { color: var(--text-muted); }

.admin-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.admin-tab {
  background: #fff;
  border: 1px solid var(--border);
  padding: 9px 16px;
  border-radius: 10px;
  font-family: inherit;
  font-weight: 800;
  font-size: 0.88rem;
  cursor: pointer;
  color: var(--text-muted);
}

.admin-tab.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.badge-inline {
  background: rgba(0,0,0,0.12);
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
}

.admin-two-col {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 24px;
  align-items: start;
}

@media (max-width: 920px) {
  .admin-two-col {
    grid-template-columns: 1fr;
  }
}

.admin-card {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 22px;
}

.admin-card h3 {
  margin-bottom: 12px;
}

.category-create-bar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.category-create-bar input {
  flex: 1;
  min-width: 240px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: inherit;
}

/* Report Table & Controls */
.report-controls-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

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

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

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

.report-table th {
  background: #fff5f8;
  font-weight: 800;
}

.multi-mail-box {
  background: #fdf8fa;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  margin-top: 12px;
}

.form-group {
  margin-bottom: 12px;
}

.form-group label {
  display: block;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 4px;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="tel"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.9rem;
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.logo-editor-box {
  display: flex;
  gap: 16px;
  align-items: center;
  background: #fdf6f8;
  padding: 12px;
  border-radius: 12px;
  border: 1px dashed var(--primary);
}

.store-logo-large {
  width: 72px;
  height: 72px;
  border-radius: 16px;
  object-fit: cover;
  background: #fff;
  border: 2px solid #fff;
}

.image-preview-wrap img {
  margin-top: 8px;
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
}

/* Order Cards in Admin */
.panel-header-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}

.status-filters {
  display: flex;
  gap: 6px;
}

.chip {
  background: #fff;
  border: 1px solid var(--border);
  padding: 6px 14px;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
}

.chip.active {
  background: var(--text);
  color: #fff;
}

.order-card {
  background: #fff;
  border-radius: 14px;
  border: 1px solid var(--border);
  padding: 16px 18px;
  margin-bottom: 14px;
}

.order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #f5ebf0;
  padding-bottom: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
  gap: 10px;
}

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.status-pending { background: #fef3c7; color: #b45309; }
.status-accepted { background: #d1fae5; color: #065f46; }
.status-rejected { background: #fee2e2; color: #991b1b; }

.order-customer-strip {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 0.88rem;
  margin-bottom: 10px;
  background: #fcf8fa;
  padding: 10px 14px;
  border-radius: 10px;
}

.order-items-mini {
  margin-bottom: 10px;
  font-size: 0.88rem;
}

.order-admin-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid #f5ebf0;
  flex-wrap: wrap;
}

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

/* Cart Drawer */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 200;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 430px;
  height: 100vh;
  background: #fff;
  z-index: 210;
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 30px rgba(0, 0, 0, 0.15);
}

.drawer-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-items-container {
  flex: 1;
  overflow-y: auto;
  padding: 14px 20px;
}

.cart-item-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #f5ebf0;
}

.cart-item-row img {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  object-fit: cover;
}

.cart-item-info {
  flex: 1;
}

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

.qty-btn {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  cursor: pointer;
  font-weight: 800;
}

.cart-checkout-section {
  padding: 14px 20px 20px;
  border-top: 2px solid var(--border);
  background: #fffbfd;
  max-height: 62vh;
  overflow-y: auto;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 1.15rem;
  margin-bottom: 10px;
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  background: #fff;
  border-radius: var(--radius);
  max-width: 500px;
  width: 100%;
  padding: 26px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 50px rgba(0,0,0,0.2);
}

.modal-lg {
  max-width: 740px;
}

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

.success-modal-card {
  text-align: center;
}

.success-icon-circle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #d1fae5;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
}

.success-exact-msg {
  background: #ecfdf5;
  color: #065f46;
  border: 2px solid #6ee7b7;
  padding: 14px 16px;
  border-radius: 12px;
  font-size: 1.15rem;
  margin-bottom: 12px;
  line-height: 1.35;
}

.success-order-summary {
  text-align: left;
  background: #fdf8fa;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  margin: 14px 0;
  font-size: 0.9rem;
}

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

.lookup-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.lookup-bar input {
  flex: 1;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
}

/* Modules Grid */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}

.module-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  background: #fdfafa;
}

/* Toast */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: #1f2937;
  color: #fff;
  padding: 12px 18px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

/* Full-Screen Image Lightbox Popup & Carousel */
.product-img-wrap {
  position: relative;
  cursor: pointer;
}

.img-count-pill {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.68);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  pointer-events: none;
}

.lightbox-modal-card {
  max-width: 780px;
  padding: 20px 24px;
}

.lightbox-stage {
  position: relative;
  background: #111827;
  border-radius: 14px;
  height: 410px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 12px;
}

.lightbox-main-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #111827;
  border: none;
  font-size: 1.2rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: transform 0.15s, background 0.15s;
}

.lightbox-arrow:hover {
  background: var(--primary);
  color: #fff;
}

.lightbox-arrow.left {
  left: 14px;
}

.lightbox-arrow.right {
  right: 14px;
}

.lightbox-counter {
  position: absolute;
  bottom: 12px;
  right: 14px;
  background: rgba(0, 0, 0, 0.72);
  color: #fff;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 800;
}

.lightbox-thumbnails {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 14px;
  justify-content: center;
}

.lightbox-thumb {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  object-fit: cover;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.65;
  transition: all 0.2s;
}

.lightbox-thumb.active,
.lightbox-thumb:hover {
  border-color: var(--primary);
  opacity: 1;
  transform: scale(1.04);
}

.lightbox-footer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

/* Admin Multi-Image Preview Grid */
.multi-images-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(115px, 1fr));
  gap: 10px;
}

.multi-img-card {
  border: 2px solid var(--border);
  border-radius: 10px;
  padding: 6px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.multi-img-card.is-default {
  border-color: var(--primary);
  background: var(--primary-soft);
}

.multi-img-card img {
  width: 100%;
  height: 76px;
  object-fit: cover;
  border-radius: 6px;
}

.portal-login-screen {
  min-height: calc(100vh - 90px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* ==================== MOBILE-FIRST STOREFRONT & RESPONSIVE UX ==================== */

/* Sticky Mobile Bottom Cart Bar (Hidden on Desktop, Active on Mobile/Tablet <= 920px) */
.mobile-bottom-cart-bar {
  display: none;
}

@media (max-width: 920px) {
  .storefront-main-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    padding-bottom: 84px; /* Space for sticky mobile bottom bar */
  }

  .live-order-summary-card {
    position: static;
    margin-bottom: 24px;
  }

  .mobile-bottom-cart-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 260;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    border-top: 2px solid var(--primary-soft);
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.12);
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  }

  .mobile-bottom-cart-info {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
  }

  .mobile-cart-pill {
    background: var(--primary-soft);
    color: var(--primary-dark);
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 800;
    white-space: nowrap;
  }

  .mobile-bottom-cart-actions {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  /* Admin & Developer Portal Responsive Fallback when accessed on Mobile */
  .admin-two-col {
    grid-template-columns: 1fr;
  }

  .admin-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 6px;
  }

  .admin-tabs::-webkit-scrollbar {
    display: none;
  }

  .admin-tab {
    white-space: nowrap;
    flex-shrink: 0;
  }
}

@media (max-width: 768px) {
  /* Prevent iOS Safari & Android Chrome auto-zoom on input focus */
  input[type="text"],
  input[type="tel"],
  input[type="email"],
  input[type="number"],
  input[type="password"],
  select,
  textarea {
    font-size: 16px !important;
  }

  .container {
    padding: 0 12px;
  }

  /* Compact Mobile Header */
  .header-inner {
    flex-direction: column;
    align-items: stretch;
    padding: 10px 12px;
    gap: 8px;
  }

  .brand-link {
    justify-content: flex-start;
  }

  .store-logo {
    width: 42px;
    height: 42px;
  }

  .store-title {
    font-size: 1.22rem;
  }

  .store-tagline {
    font-size: 0.72rem;
  }

  .header-actions {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 6px;
  }

  .quick-mobile-pill {
    width: 100%;
    order: 2;
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 6px;
    padding: 6px;
    border-radius: 10px;
  }

  .quick-mobile-pill input {
    width: 100% !important;
    min-width: 0;
    padding: 7px 8px;
  }

  .quick-divider {
    display: none;
  }

  /* Compact Hero Banner for Mobile Shoppers */
  .hero-banner {
    padding: 16px 0 12px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .hero-text h2 {
    font-size: 1.35rem;
    line-height: 1.25;
  }

  .hero-text p {
    font-size: 0.86rem;
    margin-bottom: 10px;
  }

  .hero-badges {
    gap: 6px;
  }

  .badge-pill {
    font-size: 0.74rem;
    padding: 4px 10px;
  }

  /* Swipeable Single-Line Category Pill Bar */
  .category-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 8px;
    padding-bottom: 4px;
  }

  .category-tabs::-webkit-scrollbar {
    display: none;
  }

  .cat-tab {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 8px 14px;
    font-size: 0.84rem;
  }

  /* Compact Filter & Sort Toolbar */
  .catalog-toolbar {
    flex-direction: column;
    align-items: stretch;
    padding: 10px 12px;
    gap: 8px;
  }

  .toolbar-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
  }

  .toolbar-group {
    flex-direction: column;
    align-items: stretch;
    gap: 3px;
  }

  .toolbar-group label {
    font-size: 0.74rem;
  }

  .toolbar-select {
    width: 100%;
    padding: 7px 8px;
  }

  .search-box {
    width: 100%;
    max-width: none;
  }

  /* 2-Column Mobile Product Grid (Like FirstCry / Amazon / Flipkart Mobile App) */
  .products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .product-card {
    border-radius: 12px;
  }

  .product-img-wrap img {
    height: 148px;
  }

  .product-badge {
    top: 8px;
    left: 8px;
    font-size: 0.68rem;
    padding: 2px 8px;
  }

  .img-count-pill {
    bottom: 6px;
    right: 6px;
    font-size: 0.68rem;
    padding: 2px 7px;
  }

  .product-body {
    padding: 10px;
  }

  .product-cat {
    font-size: 0.68rem;
  }

  .product-title {
    font-size: 0.88rem;
    line-height: 1.25;
    margin: 2px 0 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .product-desc {
    font-size: 0.74rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 8px;
  }

  .product-footer {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .price-current {
    font-size: 1rem;
  }

  .price-mrp {
    font-size: 0.76rem;
  }

  .product-footer .btn {
    width: 100%;
    padding: 9px 10px;
    font-size: 0.82rem;
  }

  .cart-qty-controls {
    width: 100%;
    justify-content: space-between;
  }

  /* Full-Screen Image Lightbox Popup Mobile Sheet */
  .lightbox-modal-card {
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 18px 18px 0 0;
    padding: 14px;
    max-height: 92vh;
    overflow-y: auto;
  }

  .lightbox-stage {
    height: 270px;
  }

  .lightbox-arrow {
    width: 38px;
    height: 38px;
  }

  .lightbox-footer-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  #lightbox-cart-action-box .btn {
    width: 100%;
  }

  /* Slide-Over Cart Drawer Full-Width on Mobile */
  .cart-drawer {
    width: 100%;
    max-width: 100%;
  }

  .toast-container {
    bottom: 76px;
    left: 12px;
    right: 12px;
  }
}

@media (max-width: 360px) {
  .products-grid {
    grid-template-columns: 1fr;
  }
}
