:root {
  --bg: #f5f5f8;
  --white: #ffffff;
  --text: #1a1a2e;
  --muted: #6b6b80;
  --primary: #1a2b48;
  --primary-dark: #0f1a2e;
  --primary-light: #2d4080;
  --secondary: #2874f0;
  --accent: #ff6f00;
  --gold: #c5a059;
  --success: #388e3c;
  --border: #e8e8ef;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 40px rgba(26, 43, 72, 0.15);
  --radius: 12px;
  --font: 'Poppins', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.hidden { display: none !important; }
.container { width: min(1280px, 94vw); margin: 0 auto; padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

.top-strip {
  background: linear-gradient(90deg, var(--secondary), var(--primary));
  color: #fff;
  font-size: 0.8rem;
  text-align: center;
  padding: 0.45rem 0.5rem;
  line-height: 1.35;
}
.top-strip a { color: #fff; font-weight: 600; text-decoration: underline; }

/* Header — Meesho + Flipkart mix */
.header {
  background: var(--white);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 200;
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.45rem 0;
  flex-wrap: wrap;
}
.logo-link {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  height: 92px;
  min-width: 100px;
  padding: 0;
  line-height: 0;
}
.logo-img {
  height: 98px;
  width: auto;
  max-width: 118px;
  min-width: 88px;
  object-fit: contain;
  object-position: center;
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.06));
}
.logo-img-admin { height: 72px; max-width: 180px; }
.footer-logo {
  height: 120px;
  width: auto;
  max-width: 200px;
  object-fit: contain;
  display: block;
  margin-bottom: 0.25rem;
}
.logo {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--primary);
}
.logo span { color: var(--secondary); }
.search-bar {
  flex: 1;
  min-width: 200px;
  display: flex;
  max-width: 520px;
  margin: 0 auto;
}
.search-bar input {
  flex: 1;
  padding: 0.7rem 1.1rem;
  border: none;
  border-radius: 999px 0 0 999px;
  font-family: inherit;
  font-size: 0.92rem;
  outline: none;
  background: #f0f0f5;
  color: var(--text);
}
.search-bar input::placeholder { color: #878787; }
.search-bar button {
  padding: 0 1.35rem;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 0 999px 999px 0;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.88rem;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.header-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  padding: 0.35rem 0.5rem;
}
.header-link:hover { color: var(--primary); }
.header-link.active { color: var(--primary); font-weight: 700; }
.header-desktop-only { display: inline-flex; }
.header-icon {
  position: relative;
  font-size: 1.15rem;
  padding: 0.4rem 0.55rem !important;
  line-height: 1;
}
.header-auth { display: inline-flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }
.header-user-name {
  max-width: 72px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted) !important;
  font-size: 0.78rem !important;
}
.cart-btn {
  position: relative;
  background: var(--primary);
  color: #fff !important;
  padding: 0.5rem 1rem !important;
  border-radius: 8px;
  font-weight: 600;
}
.cart-btn.header-icon { padding: 0.45rem 0.65rem !important; font-size: 1.1rem; }
.cart-badge {
  position: absolute;
  top: -8px; right: -8px;
  min-width: 18px; height: 18px;
  background: var(--accent);
  border-radius: 50%;
  font-size: 0.65rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

/* Category nav */
.cat-nav {
  background: var(--white);
  border-top: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.cat-nav-inner {
  display: flex;
  gap: 0.25rem;
  padding: 0.5rem 0;
  min-width: max-content;
}
.cat-pill {
  padding: 0.45rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  transition: all 0.2s;
}
.cat-pill:hover, .cat-pill.active {
  background: rgba(26, 43, 72, 0.1);
  color: var(--primary);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  box-shadow: 0 4px 14px rgba(26, 43, 72, 0.35);
}
.btn-secondary {
  background: linear-gradient(135deg, var(--secondary), #1a5fd4);
  color: #fff;
}
.btn-gold {
  background: var(--secondary);
  color: #fff;
  font-weight: 600;
}
.btn-ghost {
  background: var(--white);
  border: 1px solid var(--border);
  color: var(--text);
}
.btn-sm { padding: 0.45rem 0.9rem; font-size: 0.8rem; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* Hero — 3D carousel */
.hero-section {
  background: linear-gradient(135deg, #eef1f8 0%, #f0f4ff 50%, #fff8f0 100%);
  padding: 2rem 0 2.5rem;
  overflow: hidden;
  position: relative;
  z-index: 1;
}
.hero-text h1 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--text);
}
.hero-text h1 em {
  font-style: normal;
  color: var(--primary);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 2rem;
  align-items: center;
  min-height: 0;
}
.hero-text p {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 1.25rem;
  max-width: 420px;
}
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}
.hero-badge {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--success);
}
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* 3D Carousel */
.hero-carousel-wrap {
  position: relative;
  height: min(420px, 52vw);
  min-height: 360px;
  max-height: 420px;
  padding: 1.25rem 2.5rem 0.5rem;
  overflow: hidden;
  isolation: isolate;
}
.hero-carousel-wrap::before {
  content: '';
  position: absolute;
  inset: 12% 8% 8%;
  background: radial-gradient(ellipse, rgba(26, 43, 72, 0.1), transparent 70%);
  pointer-events: none;
}
.carousel-controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0;
  z-index: 10;
  pointer-events: none;
}
.carousel-btn {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: none;
  background: var(--white);
  box-shadow: var(--shadow);
  cursor: pointer;
  font-size: 1.2rem;
  color: var(--primary);
  font-weight: 700;
  pointer-events: auto;
  flex-shrink: 0;
}
.carousel-btn:hover { background: var(--primary); color: #fff; }
[data-hero-carousel] {
  perspective: 1200px;
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}
.carousel-card {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(250px, 40vw);
  max-height: calc(100% - 8px);
  background: var(--white);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: translate(-50%, -50%);
  transition: all 0.85s cubic-bezier(0.34, 1.2, 0.64, 1);
  transform-style: preserve-3d;
  backface-visibility: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.carousel-card.front {
  transform: translate(-50%, -50%) translateZ(60px) scale(0.98);
  z-index: 5;
  opacity: 1;
  box-shadow: 0 16px 40px rgba(26, 43, 72, 0.2);
  animation: cardFloat 2.5s ease-in-out infinite;
  cursor: default;
}
@keyframes cardFloat {
  0%, 100% { transform: translate(-50%, -50%) translateZ(60px) scale(0.98) translateY(0); }
  50% { transform: translate(-50%, -50%) translateZ(68px) scale(0.99) translateY(-4px); }
}
.carousel-card.left,
.carousel-card.right {
  animation: cardSway 2.5s ease-in-out infinite;
}
@keyframes cardSway {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 0.85; }
}
.carousel-card.left {
  transform: translate(-50%, -50%) translateX(-52%) translateZ(-30px) rotateY(24deg) scale(0.8);
  z-index: 3;
  opacity: 0.85;
  filter: none;
  pointer-events: auto;
}
.carousel-card.right {
  transform: translate(-50%, -50%) translateX(52%) translateZ(-30px) rotateY(-24deg) scale(0.8);
  z-index: 3;
  opacity: 0.85;
  filter: none;
  pointer-events: auto;
}
.carousel-price-tag {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  font-size: 0.82rem;
  padding: 0.3rem 0.55rem;
  border-radius: 8px;
  z-index: 4;
  box-shadow: 0 4px 12px rgba(26,43,72,0.3);
  line-height: 1.2;
}
.carousel-wish {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: #fff;
  box-shadow: var(--shadow);
  cursor: pointer;
  z-index: 5;
  font-size: 1rem;
}
.carousel-wish.active { color: #e91e8c; background: #fff0f5; }
.carousel-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.65rem;
}
.carousel-actions .btn { flex: 1; padding: 0.5rem 0.4rem; font-size: 0.78rem; }
.carousel-card.hidden {
  transform: translate(-50%, -50%) translateZ(-200px) scale(0.5);
  z-index: 0;
  opacity: 0;
  pointer-events: none;
}
.carousel-tag {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  z-index: 2;
}
.carousel-img {
  aspect-ratio: 4 / 3.2;
  max-height: 210px;
  overflow: hidden;
  background: #f8f0f5;
  flex-shrink: 0;
}
.carousel-card.front .carousel-img {
  aspect-ratio: 4 / 3.2;
  max-height: 200px;
}
.carousel-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.carousel-info {
  padding: 0.85rem 1rem 1rem;
  flex-shrink: 0;
}
.carousel-info h3 {
  font-size: 0.92rem;
  font-weight: 600;
  margin-bottom: 0.45rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
}
.carousel-price {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}
.carousel-price strong { color: var(--text); font-size: 1.05rem; }
.carousel-price .mrp {
  font-size: 0.78rem;
  color: var(--muted);
  text-decoration: line-through;
}
.carousel-price .off {
  font-size: 0.72rem;
  color: var(--success);
  font-weight: 700;
  background: #e8f5e9;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}

/* Promo banners */
.promo-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.promo-card {
  border-radius: var(--radius);
  padding: 1.25rem;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  min-height: 90px;
  display: flex;
  align-items: flex-end;
  transition: transform 0.2s, box-shadow 0.2s;
}
a.promo-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.promo-card:nth-child(1) { background: linear-gradient(135deg, var(--primary), #2d4080); }
.promo-card:nth-child(2) { background: linear-gradient(135deg, var(--secondary), #5b9fff); }
.promo-card:nth-child(3) { background: linear-gradient(135deg, var(--accent), #ffb74d); }

/* Sections */
.section { padding: 2rem 0 3rem; }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.section-title {
  font-size: 1.35rem;
  font-weight: 700;
}
.section-sub { color: var(--muted); font-size: 0.9rem; }

/* Product grid — clean 4-column layout */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.35rem 1.15rem;
}
.product-grid-shop {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.35rem 1.15rem;
}
.product-card {
  background: var(--white);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e8e8ee;
  transition: box-shadow 0.2s, transform 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.product-card:hover {
  box-shadow: 0 4px 16px rgba(26, 43, 72, 0.12);
  transform: translateY(-2px);
  border-color: rgba(26, 43, 72, 0.15);
}
.product-card-img {
  aspect-ratio: 4/5;
  overflow: hidden;
  background: #fafafa;
  position: relative;
}
.product-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
  background: #f5f0f8;
}
.admin-thumb {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #fafafa;
}
.admin-actions-cell {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-width: 140px;
}
.product-card .off-badge {
  position: absolute;
  top: 8px; left: 8px;
  background: var(--success);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
}
.product-card-body { padding: 0.75rem 0.85rem 0.85rem; flex: 1; display: flex; flex-direction: column; }
.product-card-body h3 {
  font-size: 0.86rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
  color: #353543;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.5em;
  line-height: 1.4;
}
.product-card-actions { display: flex; gap: 0.4rem; margin-top: auto; padding-top: 0.35rem; }
.product-card-body .cat {
  font-size: 0.7rem;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
  letter-spacing: 0.03em;
}
.price-row {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}
.price-row .price { font-size: 1rem; font-weight: 700; color: var(--text); }
.price-row .mrp { font-size: 0.75rem; color: var(--muted); text-decoration: line-through; }
.product-card-actions .btn { flex: 1; padding: 0.52rem 0.4rem; font-size: 0.78rem; }

/* Category grid — desktop */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
}
.cat-grid .cat-circle { width: auto; }
.cat-grid .cat-circle img { width: 72px; height: 72px; }

/* Review cards */
.review-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.review-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.review-card .stars { color: #f5a623; font-size: 0.9rem; margin-bottom: 0.5rem; }
.review-card p { font-size: 0.88rem; color: var(--muted); line-height: 1.55; margin-bottom: 0.75rem; }
.review-card strong { font-size: 0.82rem; color: var(--text); }

.spotlight-banner {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.5rem;
  align-items: center;
  background: linear-gradient(135deg, #fff5f8 0%, #f0f4ff 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  overflow: hidden;
}
.spotlight-banner img {
  width: 100%;
  max-height: 280px;
  object-fit: cover;
  border-radius: 10px;
}
.spotlight-banner h2 { font-size: 1.4rem; margin-bottom: 0.5rem; }
.spotlight-banner p { color: var(--muted); margin-bottom: 1rem; line-height: 1.6; }

/* Trust row */
.trust-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.25rem;
  border: 1px solid var(--border);
}
.trust-item {
  text-align: center;
  font-size: 0.85rem;
}
.trust-item strong { display: block; font-size: 1.5rem; margin-bottom: 0.25rem; }

/* Page layouts (inner pages) */
.page { padding: 1.5rem 0 3rem; min-height: 60vh; }
.page-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 1.25rem; }
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
}
.filters { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.filter-chip, .search-input {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--white);
  font-family: inherit;
  font-size: 0.85rem;
}
.filter-chip { cursor: pointer; font-weight: 600; color: var(--muted); }
.filter-chip.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.search-input { min-width: 180px; }

.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  padding: 1rem 0 2rem;
  align-items: start;
}
.product-detail-img {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 4/5;
  background: #fff;
}
.product-detail-img img { width: 100%; height: 100%; object-fit: cover; }
.product-detail-info h1 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.price-lg { font-size: 1.75rem; font-weight: 800; color: var(--primary); }
.contact-card h2 { color: var(--primary); margin-bottom: 0.75rem; }
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 1rem;
}
@media (max-width: 768px) {
  .contact-grid { grid-template-columns: 1fr; }
}
.qty-control { display: flex; align-items: center; gap: 0.5rem; margin: 1rem 0; }
.qty-control button {
  width: 36px; height: 36px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--white);
  cursor: pointer;
  font-size: 1.1rem;
}
.cart-layout { display: grid; grid-template-columns: 1fr min(320px, 100%); gap: 1.5rem; align-items: start; }
.checkout-layout { display: grid; grid-template-columns: 1fr min(320px, 100%); gap: 1.5rem; align-items: start; }
.cart-item {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  gap: 1rem;
  align-items: center;
}
.cart-item img { width: 90px; height: 110px; object-fit: cover; border-radius: 8px; }
.summary-box {
  position: sticky;
  top: 5rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.summary-row { display: flex; justify-content: space-between; margin-bottom: 0.5rem; font-size: 0.9rem; color: var(--muted); }
.summary-row.total { font-size: 1.1rem; font-weight: 700; color: var(--text); border-top: 1px dashed var(--border); padding-top: 0.75rem; margin-top: 0.75rem; }

.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.35rem; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
}
.form-group input:focus { outline: 2px solid rgba(26, 43, 72, 0.25); border-color: var(--primary); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.tabs { display: flex; gap: 0.5rem; margin-bottom: 1rem; }
.tab {
  padding: 0.5rem 1.25rem;
  border: none;
  background: var(--bg);
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.tab.active { background: var(--primary); color: #fff; }

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: capitalize;
}
.badge-paid { background: #e8f5e9; color: var(--success); }
.badge-pending { background: #fff3e0; color: var(--accent); }
.badge-shipped { background: #e3f2fd; color: var(--secondary); }
.badge-cancelled { background: #ffebee; color: #c62828; }

.alert { padding: 0.85rem 1rem; border-radius: 8px; margin-bottom: 1rem; font-size: 0.9rem; }
.alert-error { background: #ffebee; color: #c62828; border: 1px solid #ffcdd2; }
.alert-success { background: #e8f5e9; color: var(--success); }
.alert-info { background: #e3f2fd; color: var(--secondary); }

/* Features row */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.feature-card {
  padding: 2rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--border);
  text-align: center;
}
.feature-card .icon { font-size: 2rem; margin-bottom: 1rem; }
.feature-card h3 { margin-bottom: 0.5rem; }
.feature-card p { color: var(--muted); font-size: 0.9rem; }

.footer {
  background: #1a1a2e;
  color: #aaa;
  padding: 2.5rem 0 0;
  margin-top: 2rem;
  font-size: 0.85rem;
}
.footer a { color: #ccc; }
.footer a:hover { color: #fff; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr;
  gap: 2rem;
  padding-bottom: 2rem;
}
.footer-brand p { margin-top: 0.75rem; line-height: 1.6; }
.footer-brand .footer-logo { filter: drop-shadow(0 2px 8px rgba(0,0,0,0.25)); }
.footer-seo { font-size: 0.8rem; opacity: 0.85; }
.footer-col h4 { color: #fff; margin-bottom: 0.75rem; font-size: 0.95rem; }
.footer-col { display: flex; flex-direction: column; gap: 0.4rem; }
.footer-bottom {
  background: var(--primary-dark);
  text-align: center;
  padding: 1rem;
  font-size: 0.8rem;
  color: #8a95a8;
}
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr; } }

/* Admin panel */
body.admin-page { background: var(--bg); }
.admin-layout {
  display: flex;
  min-height: 100vh;
  align-items: stretch;
}
.admin-sidebar {
  flex: 0 0 240px;
  background: var(--white);
  border-right: 1px solid var(--border);
  padding: 1.5rem 1.25rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.admin-nav { display: flex; flex-direction: column; gap: 0.4rem; }
.admin-nav .tab {
  text-align: left;
  width: 100%;
  padding: 0.65rem 1rem;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
}
.admin-nav .tab:hover { background: rgba(26, 43, 72, 0.06); color: var(--primary); }
.admin-nav .tab.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.admin-main {
  flex: 1;
  padding: 1.5rem 2rem 2rem;
  min-width: 0;
  width: 100%;
}
.admin-panel { display: none; }
.admin-panel.active { display: block; }
.admin-form {
  max-width: 640px;
  width: 100%;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}
.admin-form .form-group input,
.admin-form .form-group textarea,
.admin-form .form-group select {
  width: 100%;
  display: block;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  background: #fff;
  box-sizing: border-box;
}
.admin-form .form-group textarea { min-height: 80px; resize: vertical; }
.admin-form .btn-primary { width: 100%; margin-top: 0.5rem; padding: 0.85rem; }
.admin-hint {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.35rem;
}
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.btn-danger-text { color: #c62828 !important; border-color: #ffcdd2 !important; }
.btn-danger-text:hover { background: #ffebee !important; }
.stat-card .lbl { font-size: 0.8rem; color: var(--muted); }
.table-wrap { overflow-x: auto; background: var(--white); border-radius: var(--radius); border: 1px solid var(--border); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 0.75rem 1rem; text-align: left; border-bottom: 1px solid var(--border); font-size: 0.88rem; }
th { background: var(--bg); color: var(--muted); font-weight: 600; }
select.status-select {
  padding: 0.35rem;
  border-radius: 6px;
  border: 1px solid var(--border);
  font-family: inherit;
}

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.empty-state h2 { color: var(--text); margin-bottom: 0.5rem; }

/* Meesho / Flipkart extras */
.flash-banner {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  color: #fff;
  text-align: center;
  padding: 0.5rem 0.65rem;
  font-size: 0.85rem;
  font-weight: 600;
  position: relative;
  z-index: 5;
  line-height: 1.35;
}
@media (min-width: 1025px) {
  .cat-scroll { display: none; }
  .cat-grid { display: grid; }
}
@media (max-width: 1024px) {
  .cat-grid { display: none; }
}
.cat-scroll {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: 0.5rem 0 0.25rem;
  -webkit-overflow-scrolling: touch;
}
@media (max-width: 1024px) {
  .cat-scroll { display: flex; }
}
.cat-circle {
  flex: 0 0 auto;
  text-align: center;
  width: 72px;
}
.cat-circle img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
  margin: 0 auto 0.35rem;
}
.cat-circle span { font-size: 0.75rem; font-weight: 600; color: var(--text); }
.product-card-img-wrap { position: relative; }
.wishlist-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  cursor: pointer;
  z-index: 2;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.wishlist-btn.active, .wishlist-btn-lg.active { color: #e91e8c; background: #fff0f5; }
.free-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: #e8f5e9;
  color: var(--success);
  font-size: 0.62rem;
  font-weight: 700;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
}
.rating-row {
  font-size: 0.78rem;
  color: var(--text);
  margin-bottom: 0.25rem;
}
.rating-row span { color: var(--muted); }
.off-text { font-size: 0.72rem; color: var(--success); font-weight: 700; }
.price-row .price { color: var(--primary); }
.shop-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.sort-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  white-space: nowrap;
}
.sort-bar select {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
}
.bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--white);
  border-top: 1px solid var(--border);
  z-index: 300;
  padding: 0.35rem 0;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.08);
}
.bottom-nav a,
.bottom-nav-item {
  flex: 1;
  text-align: center;
  font-size: 0.65rem;
  color: var(--muted);
  padding: 0.35rem;
  text-decoration: none;
}
.bottom-nav a span,
.bottom-nav-ico { display: block; font-size: 1.2rem; }
.bottom-nav a.active,
.bottom-nav-item.active { color: var(--primary); font-weight: 700; }
body { padding-bottom: 0; }

/* Legacy nav compat for subpages */
.nav { display: none; }
.nav-links, .nav-link, .nav-user { /* use header instead */ }

/* Header icon buttons — Meesho style circle + badge */
.header-icon-btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  color: var(--text);
  padding: 0.1rem 0.3rem;
  text-decoration: none;
}
.header-icon-label {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--muted);
}
.header-icon-circle {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid #e0e0e8;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.wishlist-header-btn .header-heart {
  font-size: 1.4rem;
  color: #e91e8c;
  line-height: 1;
  font-weight: 400;
}
.wishlist-header-btn:hover .header-heart { color: #c2185b; }
.cart-header-btn .cart-circle {
  background: var(--primary);
  border-color: var(--primary);
}
.header-cart-ico { font-size: 1.15rem; line-height: 1; }
.nav-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--white);
  line-height: 1;
}

/* Homepage sections */
.home-section { padding: 1.75rem 0; }
.home-section-alt { background: var(--white); }
.cat-section { padding-top: 1.25rem; }
.page-lead { color: var(--muted); margin-bottom: 1.5rem; font-size: 0.95rem; }
.home-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  padding: 1.5rem 1.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}
.home-cta h2 { font-size: 1.25rem; margin-bottom: 0.35rem; }
.home-cta p { opacity: 0.9; font-size: 0.9rem; }

/* Contact page */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}
.contact-form-card { padding: 1.5rem; }
.contact-phone { font-size: 1.25rem; font-weight: 700; color: var(--primary); }
.contact-link { font-weight: 600; color: var(--primary); }
.contact-muted { color: var(--muted); font-size: 0.88rem; }
.contact-form .form-group textarea { min-height: 100px; resize: vertical; }

/* Admin image upload */
.image-upload-box {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  background: #fafbfc;
}
.image-upload-preview {
  width: 100%;
  max-width: 220px;
  aspect-ratio: 4/5;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 0.75rem;
  border: 1px solid var(--border);
}
.image-upload-box input[type="file"] {
  width: 100%;
  font-size: 0.85rem;
  margin-bottom: 0.35rem;
}

/* Bottom nav badges */
.bottom-nav-item { position: relative; }
.bottom-nav-ico { position: relative; display: inline-block; }
.bottom-badge {
  position: absolute;
  top: -6px;
  right: -10px;
  min-width: 16px;
  height: 16px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-size: 0.55rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--white);
  line-height: 1;
}

.stat-card .val { font-size: 1.5rem; font-weight: 800; color: var(--primary); margin-bottom: 0.25rem; }

@media (max-width: 900px) {
  .features { grid-template-columns: 1fr; }
  .hero-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .hero-text { text-align: center; }
  .hero-text p { margin-left: auto; margin-right: auto; }
  .hero-badges { justify-content: center; }
  .hero-actions { justify-content: center; }
  .hero-section { padding: 1.25rem 0 1.75rem; }
  .hero-carousel-wrap { order: -1; height: auto; min-height: 400px; max-height: none; padding: 0.75rem 0.5rem 2.75rem; overflow: hidden; }
  [data-hero-carousel] { min-height: 340px; overflow: hidden; }
  .carousel-controls { top: auto; bottom: 0; transform: none; justify-content: center; gap: 1rem; }
  .carousel-card { top: 48%; width: min(240px, 82vw); max-height: none; }
  .carousel-card.front .carousel-img { aspect-ratio: 4 / 3.2; max-height: 175px; }
  .product-grid, .product-grid-shop { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
  .cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .review-row { grid-template-columns: 1fr; }
  .spotlight-banner { grid-template-columns: 1fr; }
  .trust-row { grid-template-columns: repeat(2, 1fr); }
  .product-detail, .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
  .summary-box { position: static; }
  .form-row { grid-template-columns: 1fr; }
  .admin-layout { flex-direction: column; }
  .admin-sidebar { flex: none; width: 100%; height: auto; position: relative; }
  .admin-main { padding: 1rem; }
  .admin-form { max-width: 100%; }
  .bottom-nav { display: flex; padding-bottom: env(safe-area-inset-bottom); }
  body.has-bottom-nav { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
  .section-head { flex-direction: column; align-items: flex-start; }
  .shop-toolbar { flex-direction: column; align-items: stretch; }
  .filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 0.25rem; -webkit-overflow-scrolling: touch; }
  .filter-chip, .search-input { flex-shrink: 0; }
  .sort-bar { width: 100%; justify-content: space-between; }
  .contact-layout { grid-template-columns: 1fr; }
  .home-cta { flex-direction: column; text-align: center; }
  .home-cta .btn { width: 100%; }
}

@media (max-width: 768px) {
  .container { width: min(1280px, 96vw); }
  .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas:
      "logo actions actions"
      "search search search";
    gap: 0.45rem 0.5rem;
    align-items: center;
    padding: 0.4rem 0;
  }
  .logo-link { grid-area: logo; height: 68px; min-width: 76px; }
  .logo-img { height: 68px; max-width: 88px; min-width: 72px; }
  .search-bar { grid-area: search; max-width: none; width: 100%; min-width: 0; margin: 0; }
  .header-actions { grid-area: actions; justify-content: flex-end; gap: 0.25rem; flex-wrap: nowrap; }
  .header-desktop-only { display: none !important; }
  .header-auth .btn { padding: 0.35rem 0.65rem; font-size: 0.75rem; }
  .header-user-name { display: none !important; }
  .top-strip { font-size: 0.72rem; padding: 0.35rem 0.5rem; }
  .flash-banner { font-size: 0.75rem; padding: 0.45rem 0.5rem; }
  .cat-pill { font-size: 0.8rem; padding: 0.4rem 0.85rem; }
  .product-grid, .product-grid-shop { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }
  .product-card-body { padding: 0.55rem 0.6rem 0.65rem; }
  .product-card-body h3 { font-size: 0.78rem; min-height: 2.2em; }
  .product-card-actions .btn { font-size: 0.72rem; padding: 0.42rem 0.35rem; }
  .page { padding: 1rem 0 2rem; }
  .page-title { font-size: 1.25rem; }
  .cart-item {
    grid-template-columns: 72px 1fr;
    grid-template-rows: auto auto;
    gap: 0.65rem;
  }
  .cart-item img { width: 72px; height: 88px; }
  .cart-item > div:last-child {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px dashed var(--border);
    padding-top: 0.65rem;
  }
  .footer-logo { height: 90px; max-width: 150px; }
  .carousel-card.left { transform: translate(-50%, -50%) translateX(-62%) translateZ(-40px) rotateY(18deg) scale(0.72); opacity: 0.55; }
  .carousel-card.right { transform: translate(-50%, -50%) translateX(62%) translateZ(-40px) rotateY(-18deg) scale(0.72); opacity: 0.55; }
  .carousel-card.left .carousel-price-tag,
  .carousel-card.right .carousel-price-tag { display: none; }
  .carousel-info { padding: 0.7rem 0.85rem 0.85rem; }
  .carousel-info h3 { font-size: 0.84rem; -webkit-line-clamp: 1; margin-bottom: 0.35rem; }
  .carousel-price strong { font-size: 0.95rem; }
  .carousel-actions { margin-top: 0.5rem; }
  .feature-card { padding: 1.25rem; }
  .promo-card { min-height: 72px; font-size: 0.92rem; }
}

@media (max-width: 480px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
  .hero-carousel-wrap { min-height: 360px; padding-bottom: 2.5rem; }
  [data-hero-carousel] { min-height: 300px; }
  .carousel-card { width: min(220px, 88vw); }
  .trust-row { grid-template-columns: 1fr 1fr; gap: 0.65rem; padding: 1rem; }
  .trust-item { font-size: 0.78rem; }
  .trust-item strong { font-size: 1.15rem; }
  .bottom-nav a { font-size: 0.6rem; padding: 0.3rem 0.15rem; }
  .bottom-nav a span { font-size: 1.05rem; }
  .product-detail-info h1 { font-size: 1.2rem; }
  .price-lg { font-size: 1.4rem; }
  .tabs { flex-wrap: wrap; }
  .tab { flex: 1; text-align: center; min-width: 0; }
}

/* Multi-image admin upload */
.admin-images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}
.admin-image-slot {
  position: relative;
  aspect-ratio: 4/5;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #f8f8fb;
}
.admin-image-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.admin-image-slot .cover-tag {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26, 43, 72, 0.85);
  color: #fff;
  font-size: 0.62rem;
  text-align: center;
  padding: 0.2rem;
  font-weight: 600;
}
.admin-image-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: rgba(0,0,0,0.65);
  color: #fff;
  cursor: pointer;
  font-size: 0.85rem;
  line-height: 1;
}
.admin-hint-inline { font-weight: 400; color: var(--muted); font-size: 0.82rem; }
.category-edit-row { display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.category-edit-row input { max-width: 180px; padding: 0.35rem 0.5rem; font-size: 0.85rem; }

/* Product detail gallery */
.product-gallery-main {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #fff;
  margin-bottom: 0.75rem;
}
.product-gallery-main img {
  width: 100%;
  display: block;
  aspect-ratio: 4/5;
  object-fit: cover;
}
.product-gallery-thumbs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.product-gallery-thumb {
  width: 64px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  background: none;
}
.product-gallery-thumb.active { border-color: var(--primary); }
.product-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
