/* ============================================
   Near 2 You - Mobile-First E-Commerce Styles
   ============================================ */

/* --- CSS Variables --- */
:root {
  --bg: #f8f9fa;
  --bg-white: #ffffff;
  --text-primary: #1a1a2e;
  --text-secondary: #6c757d;
  --text-muted: #adb5bd;
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --accent-light: #eef2ff;
  --danger: #ef4444;
  --danger-hover: #dc2626;
  --success: #22c55e;
  --warning: #f59e0b;
  --border: #e5e7eb;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.05);
  --radius: 1rem;
  --radius-sm: 0.5rem;
  --radius-full: 9999px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --bottom-nav-height: 64px;
  --top-bar-height: 56px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.5;
  overflow-x: hidden;
  min-height: 100vh;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: var(--font);
  cursor: pointer;
  border: none;
  background: none;
  font-size: inherit;
  color: inherit;
}

a {
  color: var(--accent);
  text-decoration: none;
}

input, select, textarea {
  font-family: var(--font);
  font-size: 1rem;
}

/* --- App Layout --- */
#app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

/* --- Top Bar --- */
#top-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-white);
  border-bottom: 1px solid var(--border);
  height: var(--top-bar-height);
  padding-top: env(safe-area-inset-top, 0);
}

.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--top-bar-height);
  padding: 0 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.brand-logo {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  object-fit: contain;
}

.brand-text {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.top-bar-actions {
  display: flex;
  gap: 0.25rem;
}

.icon-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  transition: background 0.15s;
}

.icon-btn:hover,
.icon-btn:active {
  background: var(--accent-light);
}

.cart-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  background: var(--danger);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
}

/* --- Main Content --- */
#page-content {
  flex: 1;
  padding: 1rem;
  padding-bottom: calc(var(--bottom-nav-height) + 1rem + env(safe-area-inset-bottom, 0));
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

/* --- Bottom Navigation --- */
#bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg-white);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: var(--bottom-nav-height);
  padding-bottom: env(safe-area-inset-bottom, 0);
  box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

.nav-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 44px;
  min-height: 44px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.7rem;
  font-weight: 500;
  transition: color 0.15s;
}

.nav-item svg {
  transition: transform 0.15s;
}

.nav-item.active {
  color: var(--accent);
}

.nav-item.active svg {
  transform: scale(1.1);
}

.nav-item:active {
  transform: scale(0.95);
}

/* --- Category Grid --- */
.category-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

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

.category-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-white);
  box-shadow: var(--shadow-md);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  min-height: 160px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 1rem;
  text-align: center;
}

.category-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.category-card:active {
  transform: scale(0.98);
}

.category-card .cat-icon {
  width: 48px;
  height: 48px;
  margin-bottom: 0.75rem;
  color: white;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15));
}

.category-card .cat-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: white;
  line-height: 1.3;
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.category-card .cat-subtitle {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.85);
  margin-top: 0.25rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.08);
}

/* Category card vibrant backgrounds — Blinkit/Swiggy/Zepto style */
.category-card.women {
  background: linear-gradient(135deg, #e91e63, #f06292);
  box-shadow: 0 4px 15px rgba(233,30,99,0.3);
}
.category-card.women:hover {
  box-shadow: 0 8px 25px rgba(233,30,99,0.4);
}

.category-card.gifts {
  background: linear-gradient(135deg, #7c3aed, #a78bfa);
  box-shadow: 0 4px 15px rgba(124,58,237,0.3);
}
.category-card.gifts:hover {
  box-shadow: 0 8px 25px rgba(124,58,237,0.4);
}

.category-card.college {
  background: linear-gradient(135deg, #0ea5e9, #38bdf8);
  box-shadow: 0 4px 15px rgba(14,165,233,0.3);
}
.category-card.college:hover {
  box-shadow: 0 8px 25px rgba(14,165,233,0.4);
}

.category-card.services {
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  box-shadow: 0 4px 15px rgba(245,158,11,0.3);
}
.category-card.services:hover {
  box-shadow: 0 8px 25px rgba(245,158,11,0.4);
}
.category-card.services .cat-title,
.category-card.services .cat-subtitle {
  color: #422006;
  text-shadow: none;
}
.category-card.services .cat-icon {
  color: #422006;
  filter: none;
}

.category-card.others {
  background: linear-gradient(135deg, #10b981, #34d399);
  box-shadow: 0 4px 15px rgba(16,185,129,0.3);
}
.category-card.others:hover {
  box-shadow: 0 8px 25px rgba(16,185,129,0.4);
}

.category-card.add-store {
  background: linear-gradient(135deg, #6366f1, #818cf8);
  border: 2px dashed rgba(255,255,255,0.5);
  box-shadow: 0 4px 15px rgba(99,102,241,0.3);
}
.category-card.add-store:hover {
  box-shadow: 0 8px 25px rgba(99,102,241,0.4);
  border-color: rgba(255,255,255,0.8);
}

/* --- Product Grid --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }
}

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

/* --- Product Card --- */
.product-card {
  background: var(--bg-white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
}

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

.product-card .product-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: #f0f0f0;
}

.product-card .product-img-fallback {
  width: 100%;
  aspect-ratio: 1;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.product-card .product-body {
  padding: 0.75rem;
}

.product-card .product-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card .product-price {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent);
  margin-top: 0.25rem;
}

.product-card .product-club {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

.product-card .product-desc {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.35rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card .product-actions {
  padding: 0 0.75rem 0.75rem;
  display: flex;
  gap: 0.5rem;
}

/* --- Variant Select --- */
.variant-select {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-white);
  font-size: 0.85rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  min-width: 44px;
  padding: 0.625rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  transition: background 0.15s, transform 0.1s, opacity 0.15s;
  white-space: nowrap;
}

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

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover);
}

.btn-secondary {
  background: var(--accent-light);
  color: var(--accent);
}

.btn-secondary:hover:not(:disabled) {
  background: #ddd6fe;
}

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

.btn-danger:hover:not(:disabled) {
  background: var(--danger-hover);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.btn-outline:hover:not(:disabled) {
  background: var(--bg);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  min-height: 36px;
  padding: 0.375rem 0.75rem;
  font-size: 0.8rem;
}

.btn-cart-icon {
  background: var(--accent);
  color: white;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, transform 0.1s;
  box-shadow: var(--shadow-sm);
}

.btn-cart-icon:hover:not(:disabled) {
  background: var(--accent-hover);
  box-shadow: var(--shadow-md);
}

.btn-cart-icon:active {
  transform: scale(0.92);
}

/* --- Add to Cart Bounce Animation --- */
@keyframes cartBounce {
  0% { transform: scale(1); }
  30% { transform: scale(1.15); }
  50% { transform: scale(0.95); }
  70% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.bounce {
  animation: cartBounce 0.4s ease;
}

/* --- Cart Page --- */
.cart-item {
  display: flex;
  gap: 0.75rem;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 0.75rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 0.75rem;
  transition: opacity 0.3s, transform 0.3s;
}

.cart-item.removing {
  opacity: 0;
  transform: translateX(100px);
}

.cart-item .cart-item-img {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #f0f0f0;
  flex-shrink: 0;
}

.cart-item .cart-item-img-fallback {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-sm);
  background: #f0f0f0;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.cart-item .cart-item-details {
  flex: 1;
  min-width: 0;
}

.cart-item .cart-item-name {
  font-size: 0.9rem;
  font-weight: 600;
}

.cart-item .cart-item-price {
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 600;
  margin-top: 0.15rem;
}

.cart-item .cart-item-custom {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

.cart-item .cart-item-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.qty-control {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.qty-control button {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg);
  transition: background 0.15s;
}

.qty-control button:hover {
  background: var(--accent-light);
}

.qty-control .qty-value {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 600;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
}

.cart-item .remove-btn {
  color: var(--danger);
  padding: 0.25rem;
  min-width: 36px;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: background 0.15s;
}

.cart-item .remove-btn:hover {
  background: #fef2f2;
}

/* --- Order Summary --- */
.order-summary {
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
  margin-top: 1rem;
}

.order-summary h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  font-size: 0.9rem;
}

.summary-row.total {
  border-top: 2px solid var(--border);
  margin-top: 0.5rem;
  padding-top: 0.75rem;
  font-weight: 700;
  font-size: 1.05rem;
}

/* --- Auth Form --- */
.auth-container {
  max-width: 400px;
  margin: 2rem auto;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  box-shadow: var(--shadow-md);
}

.auth-container h2 {
  font-size: 1.25rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 1.5rem;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--text-primary);
}

.form-input {
  width: 100%;
  padding: 0.625rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  transition: border-color 0.15s, box-shadow 0.15s;
  background: var(--bg-white);
  color: var(--text-primary);
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.form-input.error {
  border-color: var(--danger);
}

.form-error {
  font-size: 0.8rem;
  color: var(--danger);
  margin-top: 0.25rem;
}

.auth-toggle {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.auth-toggle a {
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
}

/* --- Profile Page --- */
.profile-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1rem;
}

.profile-avatar {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.5rem;
  font-weight: 700;
  flex-shrink: 0;
}

.profile-info {
  flex: 1;
  min-width: 0;
}

.profile-info .email {
  font-size: 0.95rem;
  font-weight: 600;
  word-break: break-all;
}

.profile-info .member-since {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

/* --- Orders List --- */
.order-card {
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 0.75rem;
}

.order-card .order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.order-card .order-id {
  font-size: 0.85rem;
  font-weight: 600;
}

.order-card .order-status {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  text-transform: capitalize;
}

.order-status.pending { background: #fef3c7; color: #92400e; }
.order-status.confirmed { background: #dbeafe; color: #1e40af; }
.order-status.delivered { background: #d1fae5; color: #065f46; }

.order-card .order-total {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent);
}

.order-card .order-date {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* --- Customize Form --- */
.customize-form {
  max-width: 500px;
  margin: 0 auto;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

.customize-form h2 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.color-input-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.color-input-wrapper input[type="color"] {
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 2px;
}

.char-count {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: right;
  margin-top: 0.15rem;
}

/* --- Service Card --- */
.service-card {
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.service-card .service-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.service-card .service-info {
  flex: 1;
  min-width: 0;
}

.service-card .service-name {
  font-size: 0.9rem;
  font-weight: 600;
}

.service-card .service-type {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.service-card .service-contact {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

/* --- Toast --- */
#toast-container {
  position: fixed;
  top: calc(var(--top-bar-height) + env(safe-area-inset-top, 0) + 0.5rem);
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
  max-width: calc(100vw - 2rem);
}

.toast {
  background: var(--bg-white);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  box-shadow: var(--shadow-lg);
  font-size: 0.85rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  pointer-events: auto;
  animation: toastIn 0.3s ease;
  border-left: 4px solid var(--accent);
}

.toast.success { border-left-color: var(--success); }
.toast.error { border-left-color: var(--danger); }
.toast.warning { border-left-color: var(--warning); }

.toast.removing {
  animation: toastOut 0.3s ease forwards;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(100px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(100px); }
}

/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--bg-white);
  border-radius: var(--radius) var(--radius) 0 0;
  padding: 1.5rem;
  width: 100%;
  max-width: 500px;
  max-height: 80vh;
  overflow-y: auto;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

@media (min-width: 768px) {
  .modal-overlay {
    align-items: center;
  }
  .modal-content {
    border-radius: var(--radius);
    transform: scale(0.95) translateY(0);
  }
  .modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
  }
}

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

.modal-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
}

.modal-close {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  transition: background 0.15s;
}

.modal-close:hover {
  background: var(--bg);
}

/* --- Skeleton Loader --- */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}

.skeleton-card {
  border-radius: var(--radius);
  overflow: hidden;
}

.skeleton-card .skeleton-img {
  width: 100%;
  aspect-ratio: 1;
}

.skeleton-card .skeleton-text {
  height: 14px;
  margin: 0.5rem 0.75rem;
  width: 80%;
}

.skeleton-card .skeleton-text.short {
  width: 50%;
}

.skeleton-card .skeleton-btn {
  height: 36px;
  margin: 0.5rem 0.75rem 0.75rem;
  width: 60%;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* --- Empty State --- */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
}

.empty-state .empty-icon {
  margin-bottom: 1rem;
  opacity: 0.5;
  color: var(--text-muted);
}

.empty-state .empty-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.empty-state .empty-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
}

/* --- Page Title --- */
.page-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  padding-top: 0.25rem;
}

.page-subtitle {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: -0.75rem;
  margin-bottom: 1rem;
}

/* --- Error State --- */
.error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
}

.error-state .error-icon {
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.error-state .error-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.error-state .error-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

/* --- Tabs --- */
.tabs {
  display: flex;
  border-bottom: 2px solid var(--border);
  margin-bottom: 1rem;
  gap: 0;
}

.tab {
  padding: 0.625rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color 0.15s, border-color 0.15s;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.tab:hover {
  color: var(--text-primary);
}

/* --- Back Button --- */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  min-height: 44px;
  padding: 0.25rem 0;
}

.back-btn:hover {
  color: var(--accent);
}

/* --- Section Header --- */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.section-header h2 {
  font-size: 1.1rem;
  font-weight: 700;
}

/* --- Utility --- */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.hidden { display: none !important; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* --- Scrollbar --- */
::-webkit-scrollbar {
  width: 4px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

/* --- Loading Overlay --- */
.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* --- Contact Modal Items --- */
.category-modal-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.category-modal-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--bg);
  cursor: pointer;
  transition: background 0.15s;
  min-height: 44px;
}

.category-modal-item:hover {
  background: var(--accent-light);
}

.category-modal-item .item-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.category-modal-item .item-icon.women { background: linear-gradient(135deg, #e91e63, #f06292); color: white; }
.category-modal-item .item-icon.gifts { background: linear-gradient(135deg, #7c3aed, #a78bfa); color: white; }
.category-modal-item .item-icon.college { background: linear-gradient(135deg, #0ea5e9, #38bdf8); color: white; }
.category-modal-item .item-icon.services { background: linear-gradient(135deg, #f59e0b, #fbbf24); color: #422006; }
.category-modal-item .item-icon.others { background: linear-gradient(135deg, #10b981, #34d399); color: white; }
.category-modal-item .item-icon.add-store { background: linear-gradient(135deg, #6366f1, #818cf8); color: white; }

.category-modal-item .item-text {
  font-size: 0.9rem;
  font-weight: 600;
}

/* --- Add Store Page --- */
.add-store-form {
  max-width: 500px;
  margin: 0 auto;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

.store-benefits {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--accent-light);
  border-radius: var(--radius-sm);
}

.benefit-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.benefit-icon {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}
