/* 
   Gujarat Anganwadi E-Commerce Portal - CSS Design System
   Aesthetics: Rich, Modern, vibrant Saffron & Teal highlights, Soft Gradients, Glassmorphism, and Premium Micro-animations.
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
  --primary-gradient: linear-gradient(135deg, #ff8c42 0%, #ff5c00 100%);
  --secondary-gradient: linear-gradient(135deg, #0d9488 0%, #0f766e 100%);
  --primary-color: #ff5c00;
  --secondary-color: #0d9488;
  --dark-bg: #0f172a;
  --dark-surface: #1e293b;
  --light-bg: #f8fafc;
  --light-surface: #ffffff;
  --text-dark: #0f172a;
  --text-light: #f8fafc;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --border-dark: #334155;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--light-bg);
  color: var(--text-dark);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Header & Navigation */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.logo-icon {
  width: 42px;
  height: 42px;
  background: var(--primary-gradient);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 800;
  font-size: 1.4rem;
  font-family: var(--font-heading);
  box-shadow: var(--shadow-md);
}

.logo-text h1 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  color: var(--text-dark);
  font-weight: 700;
  line-height: 1.2;
}

.logo-text span {
  font-size: 0.75rem;
  color: var(--secondary-color);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* Role & Location Selectors */
.user-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-grow: 1;
  max-width: 800px;
  justify-content: flex-end;
}

.role-selector {
  display: flex;
  background: #f1f5f9;
  padding: 0.25rem;
  border-radius: 9999px;
  border: 1px solid var(--border-color);
}

.role-btn {
  border: none;
  background: none;
  padding: 0.5rem 1.25rem;
  border-radius: 9999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  color: var(--text-muted);
}

.role-btn.active {
  background: var(--text-dark);
  color: white;
  box-shadow: var(--shadow-sm);
}

.role-btn.worker.active {
  background: var(--secondary-gradient);
}

.location-dropdowns-container {
  display: flex;
  gap: 0.5rem;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.location-select {
  padding: 0.5rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  background-color: white;
  cursor: pointer;
  outline: none;
  min-width: 110px;
  transition: var(--transition-smooth);
}

.location-select:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 2px rgba(13, 148, 136, 0.15);
}

/* Cart Badge & Search */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.search-bar {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input {
  padding: 0.5rem 1rem 0.5rem 2.25rem;
  border-radius: 9999px;
  border: 1px solid var(--border-color);
  font-family: var(--font-body);
  font-size: 0.85rem;
  width: 200px;
  transition: var(--transition-smooth);
  outline: none;
}

.search-input:focus {
  width: 280px;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(255, 92, 0, 0.15);
}

.search-icon {
  position: absolute;
  left: 0.85rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.cart-icon-btn {
  background: none;
  border: none;
  position: relative;
  cursor: pointer;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dark);
  font-size: 1.25rem;
  transition: var(--transition-smooth);
  background: #f1f5f9;
}

.cart-icon-btn:hover {
  background: #e2e8f0;
  transform: scale(1.05);
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--primary-gradient);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
  box-shadow: var(--shadow-sm);
}

/* Page Spacing */
main {
  margin-top: 80px; /* offset for fixed header */
}

/* Hero Carousel Slider */
.hero-slider {
  position: relative;
  height: 520px;
  overflow: hidden;
  background: #0f172a;
}

.slides-container {
  height: 100%;
  position: relative;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  z-index: 1;
  transition: opacity 0.8s ease-in-out;
  display: flex;
  align-items: center;
}

.slide.active {
  opacity: 1;
  z-index: 2;
}

.slide-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.4) contrast(1.1);
}

.slide-content {
  position: relative;
  z-index: 3;
  max-width: 800px;
  margin-left: 10%;
  color: white;
  padding: 2rem;
  transform: translateY(30px);
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.slide-badge {
  display: inline-block;
  background: rgba(255, 92, 0, 0.2);
  border: 1px solid var(--primary-color);
  color: #ff9d66;
  padding: 0.35rem 1rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.slide-title {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1rem;
  text-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.slide-description {
  font-size: 1.1rem;
  margin-bottom: 1.75rem;
  color: #cbd5e1;
  max-width: 600px;
  text-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.slide-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--primary-gradient);
  color: white;
  text-decoration: none;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: 0 4px 14px rgba(255, 92, 0, 0.4);
  transition: var(--transition-smooth);
  border: none;
  cursor: pointer;
}

.slide-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 92, 0, 0.6);
}

/* Slider Controls */
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.2);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  font-size: 1.2rem;
  transition: var(--transition-smooth);
}

.slider-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: white;
  color: var(--primary-color);
}

.slider-btn.prev { left: 2rem; }
.slider-btn.next { right: 2rem; }

.slider-dots {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.75rem;
  z-index: 10;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.dot.active {
  background: var(--primary-color);
  width: 24px;
  border-radius: 5px;
}

/* Section Common Styles */
.section {
  padding: 5rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: var(--primary-gradient);
  border-radius: 999px;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* Product Showcase Filters */
.product-showcase {
  background: white;
}

.filter-tabs {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: #f1f5f9;
  border: 1px solid var(--border-color);
  padding: 0.6rem 1.5rem;
  border-radius: 9999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.filter-btn:hover {
  background: #e2e8f0;
  color: var(--text-dark);
}

.filter-btn.active {
  background: var(--primary-gradient);
  border-color: transparent;
  color: white;
  box-shadow: 0 4px 12px rgba(255, 92, 0, 0.25);
}

/* Product Grid & Cards */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  transition: opacity 0.3s ease;
}

.product-card {
  background: white;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
  border-color: rgba(255, 92, 0, 0.2);
}

.product-image-container {
  position: relative;
  padding-top: 80%; /* 4:3 aspect ratio */
  background: #f8fafc;
  overflow: hidden;
  cursor: pointer;
}

.product-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 1rem;
  transition: transform 0.5s ease;
}

.product-card:hover .product-image {
  transform: scale(1.06);
}

.product-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: rgba(13, 148, 136, 0.9);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 4px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.subsidized-badge {
  background: var(--secondary-gradient);
}

.product-info {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-category {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.product-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  line-height: 1.3;
  cursor: pointer;
}

.product-title:hover {
  color: var(--primary-color);
}

.product-rating {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.8rem;
  color: #fbbf24;
  margin-bottom: 1rem;
}

.product-rating span {
  color: var(--text-muted);
  font-weight: 500;
  margin-left: 0.25rem;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.price-box {
  display: flex;
  flex-direction: column;
}

.commercial-price {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-dark);
}

.subsidized-price {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--secondary-color);
}

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

.add-to-cart-btn {
  background: var(--primary-gradient);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 10px rgba(255, 92, 0, 0.25);
}

.add-to-cart-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 14px rgba(255, 92, 0, 0.4);
}

/* Happy Customer Feedback Section */
.testimonials-section {
  background: var(--light-bg);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.testimonial-card {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  position: relative;
  transition: var(--transition-smooth);
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(13, 148, 136, 0.2);
}

.testimonial-stars {
  color: #fbbf24;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.testimonial-text {
  font-style: italic;
  font-size: 0.95rem;
  color: #334155;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 2;
}

.testimonial-quote-icon {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  font-size: 4rem;
  color: #f1f5f9;
  z-index: 1;
  font-family: serif;
  line-height: 0;
  user-select: none;
}

.testimonial-user {
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 2;
}

.user-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--secondary-color);
}

.user-details h4 {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-dark);
}

.user-details span {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Product Detail Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  padding: 1rem;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: white;
  width: 100%;
  max-width: 960px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  transform: scale(0.9) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-height: 90vh;
}

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

.close-modal-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(15, 23, 42, 0.05);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: var(--transition-smooth);
  font-size: 1.1rem;
}

.close-modal-btn:hover {
  background: var(--primary-color);
  color: white;
}

/* Modal Media Gallery */
.modal-media-section {
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border-color);
  padding: 2rem;
  overflow-y: auto;
}

.viewer-container {
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  height: 300px;
}

.viewer-media {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 1rem;
}

.viewer-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}

.gallery-thumbs {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
  justify-content: center;
}

.thumb-item {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  overflow: hidden;
  background: white;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
}

.thumb-item.active {
  border-color: var(--primary-color);
  transform: scale(1.05);
}

.thumb-item img, .thumb-item .thumb-video-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumb-video-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0f172a;
  color: white;
  font-size: 1.2rem;
}

/* Modal Details */
.modal-details-section {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.modal-details-section h2 {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.modal-details-section .product-category {
  margin-bottom: 0.5rem;
}

.modal-price-box {
  background: #f1f5f9;
  padding: 1rem;
  border-radius: 12px;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-price-label {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.modal-details-section .description-heading {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

.modal-product-description {
  font-size: 0.9rem;
  color: #475569;
  margin-bottom: 2rem;
  line-height: 1.6;
}

.modal-purchase-row {
  display: flex;
  gap: 1rem;
  margin-top: auto;
  align-items: center;
}

.quantity-picker {
  display: flex;
  align-items: center;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: white;
}

.qty-btn {
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  color: var(--text-dark);
}

.qty-btn:hover {
  background: #f1f5f9;
}

.qty-input {
  width: 40px;
  text-align: center;
  border: none;
  outline: none;
  font-weight: 700;
  font-size: 0.95rem;
  font-family: var(--font-body);
}

.modal-add-btn {
  flex-grow: 1;
  background: var(--primary-gradient);
  color: white;
  border: none;
  padding: 0.85rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 12px rgba(255, 92, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.modal-add-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(255, 92, 0, 0.45);
}

/* Cart & Checkout Sidebar */
.cart-sidebar {
  position: fixed;
  top: 0;
  right: -420px;
  width: 420px;
  height: 100%;
  background: white;
  box-shadow: var(--shadow-xl);
  z-index: 2100;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.cart-sidebar.active {
  right: 0;
}

.cart-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-header h2 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-dark);
}

.close-cart-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition-smooth);
}

.close-cart-btn:hover {
  color: var(--text-dark);
  transform: rotate(90deg);
}

.cart-items-container {
  flex-grow: 1;
  padding: 1.5rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.cart-item {
  display: flex;
  gap: 1rem;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
}

.cart-item-image {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: contain;
  background: #f8fafc;
  padding: 0.25rem;
  border: 1px solid var(--border-color);
}

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

.cart-item-title {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.25rem;
}

.cart-item-price {
  font-size: 0.85rem;
  color: var(--primary-color);
  font-weight: 600;
}

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

.cart-qty-input {
  width: 30px;
  text-align: center;
  border: none;
  font-weight: 700;
  font-size: 0.85rem;
}

.remove-item-btn {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 1rem;
  transition: var(--transition-smooth);
  padding: 0.25rem;
}

.remove-item-btn:hover {
  transform: scale(1.1);
}

.empty-cart-message {
  text-align: center;
  color: var(--text-muted);
  margin-top: 3rem;
  font-size: 0.95rem;
}

.cart-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border-color);
  background: #f8fafc;
}

.cart-subtotal-row {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

.checkout-btn {
  width: 100%;
  background: var(--primary-gradient);
  color: white;
  border: none;
  padding: 0.9rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(255, 92, 0, 0.3);
  transition: var(--transition-smooth);
  font-size: 0.95rem;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
}

.checkout-btn:hover {
  box-shadow: 0 6px 18px rgba(255, 92, 0, 0.45);
  transform: translateY(-1px);
}

/* Sidebar Backdrop overlay */
.sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(4px);
  z-index: 2050;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* Checkout Panel (Reuses Cart Sidebar layout style) */
.checkout-panel {
  position: fixed;
  top: 0;
  right: -500px;
  width: 500px;
  height: 100%;
  background: white;
  box-shadow: var(--shadow-xl);
  z-index: 2200;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.checkout-panel.active {
  right: 0;
}

.checkout-body {
  flex-grow: 1;
  padding: 2rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.checkout-section-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
  margin-bottom: 0.75rem;
  color: var(--text-dark);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.form-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.form-group input, .form-group textarea, .form-group select {
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  font-family: var(--font-body);
  font-size: 0.85rem;
  outline: none;
  background: #f8fafc;
  transition: var(--transition-smooth);
}

.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
  border-color: var(--secondary-color);
  background: white;
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.1);
}

/* Payment Gateway Selector */
.payment-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 0.5rem;
}

.payment-option-card {
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  background: white;
}

.payment-option-card:hover {
  border-color: var(--secondary-color);
  background: rgba(13, 148, 136, 0.02);
}

.payment-option-card.active {
  border-color: var(--secondary-color);
  background: rgba(13, 148, 136, 0.05);
}

.payment-icon {
  font-size: 1.5rem;
  color: var(--secondary-color);
}

.payment-title {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-dark);
}

/* UPI Gateway Form Container */
.upi-gateway-container {
  background: #0f172a;
  border-radius: 12px;
  padding: 1.5rem;
  display: none;
  flex-direction: column;
  align-items: center;
  color: white;
  text-align: center;
  margin-top: 1rem;
}

.upi-gateway-container.active {
  display: flex;
}

.qr-code-box {
  width: 150px;
  height: 150px;
  background: white;
  border-radius: 8px;
  margin: 1rem 0;
  padding: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(0,0,0,0.5);
  position: relative;
}

.qr-code-box svg {
  width: 100%;
  height: 100%;
}

.payment-loading {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255,255,255,0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  color: var(--text-dark);
}

.payment-loading.active {
  opacity: 1;
  pointer-events: auto;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(13, 148, 136, 0.2);
  border-top-color: var(--secondary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 0.5rem;
}

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

.order-success-screen {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: white;
  z-index: 2500;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
}

.order-success-screen.active {
  display: flex;
}

.success-icon-box {
  width: 80px;
  height: 80px;
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  margin-bottom: 1.5rem;
  animation: popScale 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes popScale {
  0% { transform: scale(0.5); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.invoice-preview {
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  width: 100%;
  max-width: 420px;
  background: #f8fafc;
  margin: 1.5rem 0;
  text-align: left;
  font-size: 0.85rem;
}

.invoice-header {
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 0.75rem;
  margin-bottom: 0.75rem;
  display: flex;
  justify-content: space-between;
}

.invoice-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.invoice-total-row {
  border-top: 1px dashed var(--border-color);
  padding-top: 0.75rem;
  margin-top: 0.75rem;
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  justify-content: space-between;
}

.action-btn-row {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.success-btn {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

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

.success-btn.secondary {
  background: #e2e8f0;
  color: var(--text-dark);
}

/* Footer Section */
footer {
  background: var(--dark-bg);
  color: #cbd5e1;
  padding: 4rem 2rem 2rem 2rem;
  border-top: 4px solid var(--primary-color);
}

.footer-container {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.footer-logo-icon {
  width: 38px;
  height: 38px;
  background: var(--primary-gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 800;
  font-size: 1.2rem;
}

.footer-logo-text h3 {
  font-family: var(--font-heading);
  color: white;
  font-size: 1.15rem;
}

.footer-desc {
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 1rem;
  max-width: 320px;
}

.footer-links h4 {
  font-family: var(--font-heading);
  color: white;
  font-size: 1rem;
  margin-bottom: 1.25rem;
  font-weight: 600;
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: #94a3b8;
  text-decoration: none;
  font-size: 0.85rem;
  transition: var(--transition-smooth);
}

.footer-links a:hover {
  color: var(--primary-color);
  padding-left: 4px;
}

.footer-newsletter h4 {
  font-family: var(--font-heading);
  color: white;
  font-size: 1rem;
  margin-bottom: 1.25rem;
  font-weight: 600;
}

.newsletter-form {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.newsletter-input {
  background: #1e293b;
  border: 1px solid var(--border-dark);
  padding: 0.6rem 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  color: white;
  flex-grow: 1;
  outline: none;
}

.newsletter-btn {
  background: var(--secondary-gradient);
  color: white;
  border: none;
  padding: 0.6rem 1.25rem;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.newsletter-btn:hover {
  opacity: 0.9;
}

.footer-bottom {
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid #1e293b;
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: #64748b;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Responsiveness */
@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: 1fr 1fr;
  }
  .modal-content {
    grid-template-columns: 1fr;
    max-height: 95vh;
  }
  .modal-media-section {
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem;
  }
  .viewer-container {
    height: 240px;
  }
}

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
  }
  .user-controls {
    width: 100%;
    justify-content: space-between;
  }
  .hero-slider {
    height: 400px;
  }
  .slide-title {
    font-size: 2rem;
  }
  .slide-description {
    font-size: 0.95rem;
  }
  .cart-sidebar, .checkout-panel {
    width: 100%;
    right: -100%;
  }
  .footer-container {
    grid-template-columns: 1fr;
  }
  .payment-selector {
    grid-template-columns: 1fr;
  }
}
