/* ===== HERO CAROUSEL SECTION ===== */
.hero-section {
  position: relative;
  width: 100%;
  background: #000;
  margin-top: -1px; /* Remove any gap with navbar */
}

/* Carousel Container */
.hero-carousel {
  position: relative;
  width: 100%;
  height: 500px; /* Reduced from 600px for better proportion */
  max-height: 70vh; /* Responsive to viewport height */
  overflow: hidden;
}

.carousel-container {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Carousel Slides */
.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  z-index: 0;
}

.carousel-slide.active {
  opacity: 1;
  z-index: 1;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* Carousel Overlay */
.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.5) 50%,
    rgba(0, 0, 0, 0.3) 100%
  );
  display: flex;
  align-items: center;
  z-index: 2;
}

/* Carousel Content */
.carousel-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
  color: white;
  animation: fadeInUp 0.8s ease-out;
}

.carousel-title {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.carousel-description {
  font-size: 1.3rem;
  line-height: 1.6;
  margin-bottom: 28px;
  max-width: 650px;
  text-shadow: 1px 1px 6px rgba(0, 0, 0, 0.7);
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

.carousel-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease-out 0.6s both;
  justify-content: flex-start;
}

/* Hero Buttons */
.btn-primary-hero,
.btn-secondary-hero {
  padding: 14px 36px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-primary-hero {
  background: linear-gradient(135deg, #007bff, #0056b3);
  color: white;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
}

.btn-primary-hero:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 123, 255, 0.6);
  background: linear-gradient(135deg, #0056b3, #003d82);
}

.btn-secondary-hero {
  background: transparent;
  color: white;
  border: 2px solid white;
}

.btn-secondary-hero:hover {
  background: white;
  color: #007bff;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

/* Navigation Arrows */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.carousel-btn:hover {
  background: rgba(255, 255, 255, 0.4);
  transform: translateY(-50%) scale(1.1);
  border-color: rgba(255, 255, 255, 0.5);
}

.carousel-btn-prev {
  left: 30px;
}

.carousel-btn-next {
  right: 30px;
}

.carousel-btn i {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Carousel Indicators */
.carousel-indicators {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 12px;
  z-index: 10;
}

.indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.indicator:hover {
  background: rgba(255, 255, 255, 0.8);
  transform: scale(1.2);
}

.indicator.active {
  background: white;
  width: 40px;
  border-radius: 6px;
  border-color: white;
}

/* Hero Features Bar */
.hero-features-bar {
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  padding: 40px 0;
  border-bottom: 1px solid #dee2e6;
}

.hero-features-bar .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.feature-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.feature-item i {
  font-size: 2.5rem;
  color: #007bff;
  flex-shrink: 0;
}

.feature-text h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #212529;
  margin-bottom: 4px;
}

.feature-text p {
  font-size: 0.9rem;
  color: #6c757d;
  margin: 0;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideIn {
  from {
    transform: translateX(-100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* ===== RESPONSIVE DESIGN ===== */

/* Tablet (768px - 1024px) */
@media (max-width: 1024px) {
  .hero-carousel {
    height: 450px;
    max-height: 65vh;
  }

  .carousel-title {
    font-size: 2.8rem;
  }

  .carousel-description {
    font-size: 1.15rem;
  }

  .carousel-content {
    padding: 0 32px;
  }

  .carousel-btn {
    width: 45px;
    height: 45px;
    font-size: 1.3rem;
  }

  .carousel-btn-prev {
    left: 20px;
  }

  .carousel-btn-next {
    right: 20px;
  }

  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile (max-width: 767px) */
@media (max-width: 767px) {
  .hero-carousel {
    height: 400px;
    max-height: 60vh;
  }

  .carousel-title {
    font-size: 2rem;
  }

  .carousel-description {
    font-size: 1rem;
    margin-bottom: 20px;
  }

  .carousel-content {
    padding: 0 20px;
  }

  .carousel-buttons {
    flex-direction: column;
  }

  .btn-primary-hero,
  .btn-secondary-hero {
    width: 100%;
    max-width: 280px;
    padding: 12px 28px;
    font-size: 0.95rem;
  }

  .carousel-btn {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }

  .carousel-btn-prev {
    left: 10px;
  }

  .carousel-btn-next {
    right: 10px;
  }

  .carousel-indicators {
    bottom: 20px;
    gap: 8px;
  }

  .indicator {
    width: 10px;
    height: 10px;
  }

  .indicator.active {
    width: 30px;
  }

  .hero-features-bar {
    padding: 30px 0;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .feature-item {
    padding: 16px;
  }

  .feature-item i {
    font-size: 2rem;
  }

  .feature-text h3 {
    font-size: 1rem;
  }

  .feature-text p {
    font-size: 0.85rem;
  }
}

/* Small Mobile (max-width: 480px) */
@media (max-width: 480px) {
  .hero-carousel {
    height: 350px;
    max-height: 55vh;
  }

  .carousel-title {
    font-size: 1.6rem;
    margin-bottom: 12px;
  }

  .carousel-description {
    font-size: 0.9rem;
    margin-bottom: 16px;
  }

  .carousel-overlay {
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.6) 0%,
      rgba(0, 0, 0, 0.8) 100%
    );
  }

  .btn-primary-hero,
  .btn-secondary-hero {
    padding: 11px 24px;
    font-size: 0.85rem;
    max-width: 260px;
  }
}


/* ===== CTA SECTION ===== */
.cta-section {
  padding: 60px 0;
  background: #f8f9fa;
  width: 100%;
  margin: 0;
  box-sizing: border-box;
}

.cta-section .container {
  max-width: 100%;
  margin: 0;
  padding: 0 24px;
  width: 100%;
  box-sizing: border-box;
}

.cta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  max-width: 900px;
  margin: 0 auto;
}

.cta-card {
  background: white;
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: box-shadow 0.3s ease;
}

.cta-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.cta-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #0b74de;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.cta-icon i {
  font-size: 1.75rem;
  color: white;
}

.cta-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 12px 0;
}

.cta-content p {
  font-size: 0.95rem;
  color: #6b7280;
  margin: 0 0 24px 0;
  line-height: 1.5;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: #0b74de;
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.2s ease;
}

.cta-btn:hover {
  background: #095bb8;
}

/* Responsive */
@media (max-width: 768px) {
  .cta-section {
    padding: 40px 0;
  }
  
  .cta-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .cta-card {
    padding: 28px 24px;
  }
}

@media (max-width: 480px) {
  .cta-card {
    padding: 24px 20px;
  }
  
  .cta-icon {
    width: 56px;
    height: 56px;
  }
  
  .cta-icon i {
    font-size: 1.5rem;
  }
  
  .cta-content h3 {
    font-size: 1.25rem;
  }
  
  .cta-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ===== TESTIMONIALS SECTION ===== */
.testimonials-section {
  padding: 60px 0;
  background: white;
  width: 100%;
  margin: 0;
  box-sizing: border-box;
}

.testimonials-section .container {
  max-width: 100%;
  margin: 0;
  padding: 0 24px;
  width: 100%;
  box-sizing: border-box;
}

.testimonials-header {
  text-align: center;
  margin-bottom: 32px;
}

.testimonials-header h2 {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin: 0 0 12px 0;
}

.testimonials-header p {
  font-size: 1rem;
  color: #6b7280;
  margin: 0;
}

.testimonials-wrapper {
  position: relative;
}

.testimonials-grid {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  gap: 24px;
  padding-bottom: 10px;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 #f1f5f9;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

/* Webkit scrollbar styling for testimonials */
.testimonials-grid::-webkit-scrollbar {
  height: 8px;
}

.testimonials-grid::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 4px;
}

.testimonials-grid::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.testimonials-grid::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.testimonial-card {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  min-width: 350px;
  max-width: 350px;
  flex-shrink: 0;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.testimonial-rating {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
}

.testimonial-rating i {
  color: #fbbf24;
  font-size: 1rem;
}

.testimonial-text {
  font-size: 0.95rem;
  color: #374151;
  line-height: 1.6;
  margin: 0 0 20px 0;
  flex: 1;
  text-align: justify;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #0b74de;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.author-avatar i {
  color: white;
  font-size: 1.25rem;
}

.author-info h4 {
  font-size: 1rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 4px 0;
}

.author-info span {
  font-size: 0.875rem;
  color: #6b7280;
}

/* Responsive */
@media (max-width: 768px) {
  .testimonials-section {
    padding: 40px 0;
  }
  
  .testimonials-header h2 {
    font-size: 1.75rem;
  }
  
  .testimonial-card {
    min-width: 300px;
    max-width: 300px;
    padding: 24px;
  }
  
  .scroll-btn {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }
  
  .scroll-btn.scroll-left {
    left: 5px;
  }
  
  .scroll-btn.scroll-right {
    right: 5px;
  }
}

@media (max-width: 480px) {
  .testimonials-header h2 {
    font-size: 1.5rem;
  }
  
  .testimonials-header p {
    font-size: 0.9rem;
  }
  
  .testimonial-card {
    min-width: 280px;
    max-width: 280px;
    padding: 20px;
  }
  
  .testimonial-text {
    font-size: 0.9rem;
  }
  
  .author-avatar {
    width: 40px;
    height: 40px;
  }
  
  .author-avatar i {
    font-size: 1rem;
  }
  
  .scroll-btn {
    width: 36px;
    height: 36px;
    font-size: 16px;
  }
}
/* ===== CATEGORY SHOWCASE SECTION ===== */
.categories-section {
  padding: 60px 0;
  background: #ffffff;
  width: 100%;
  margin: 0;
  box-sizing: border-box;
}

.categories-section .container {
  max-width: 100%;
  margin: 0;
  padding: 0 24px;
  width: 100%;
  box-sizing: border-box;
}

/* Category Showcase */
.category-showcase {
  margin-bottom: 60px;
}

.category-showcase:last-child {
  margin-bottom: 0;
}

/* Category Header with Title and View All Button */
.category-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  gap: 16px;
}

/* Category Title */
.category-title {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
  font-family: 'Inter', sans-serif;
}

/* View All Button */
.category-view-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  background-color: #ffffff;
  color: #0b74de;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  border: 2px solid #0b74de;
  border-radius: 6px;
  transition: all 0.3s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.category-view-all:hover {
  background-color: #0b74de;
  color: #ffffff;
}

.category-view-all i {
  font-size: 0.85rem;
}


/* Products Wrapper for Horizontal Scroll */
.category-products-wrapper {
  position: relative;
  width: 100%;
}

/* Scroll Buttons - Positioned on top of content */
.scroll-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #0b74de;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 4px 12px rgba(11, 116, 222, 0.4);
  z-index: 10;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.scroll-btn.scroll-left {
  left: 10px;
}

.scroll-btn.scroll-right {
  right: 10px;
}

.scroll-btn.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Horizontal Scroll Grid - Override similar-products grid for horizontal layout */
.similar-products-grid.horizontal-scroll {
  display: flex !important;
  flex-direction: row !important;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  gap: 20px;
  padding-bottom: 10px;
  padding-right: 24px; /* Match container padding to prevent cutoff */
  padding-left: 0;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 #f1f5f9;
  grid-template-columns: none !important;
  /* Snap to prevent half cards */
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  /* Ensure proper width calculation */
  width: 100%;
  box-sizing: border-box;
}

/* Add spacer after last card to prevent cutoff */
.similar-products-grid.horizontal-scroll::after {
  content: '';
  flex-shrink: 0;
  width: 1px; /* Minimal width */
}

/* Webkit scrollbar styling */
.similar-products-grid.horizontal-scroll::-webkit-scrollbar {
  height: 8px;
}

.similar-products-grid.horizontal-scroll::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 4px;
}

.similar-products-grid.horizontal-scroll::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.similar-products-grid.horizontal-scroll::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Product Card in Horizontal Layout */
.similar-products-grid.horizontal-scroll .product-card {
  min-width: 260px;
  max-width: 260px;
  flex-shrink: 0;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

/* Fix image sizing and remove zoom effect */
.similar-products-grid.horizontal-scroll .product-card img {
  width: 100%;
  height: 220px;
  object-fit: contain !important;
  object-position: center;
  background: #ffffff;
  padding: 10px;
  transition: none !important;
  transform: none !important;
}

/* Remove hover effects from images */
.similar-products-grid.horizontal-scroll .product-card:hover img {
  transform: none !important;
  scale: 1 !important;
}

/* Fix clearance/sale badge width - prevent full width */
.similar-products-grid.horizontal-scroll .clearance-badge {
  position: absolute !important;
  top: 10px !important;
  left: 10px !important;
  width: auto !important;
  max-width: fit-content !important;
  display: inline-block !important;
  white-space: nowrap !important;
  z-index: 10 !important;
}

/* Loading State */
.category-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 16px;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e5e7eb;
  border-top-color: #007bff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.category-loading p {
  color: #6b7280;
  font-size: 0.95rem;
  margin: 0;
}

/* Error State */
.category-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 12px;
}

.category-error i {
  font-size: 3rem;
  color: #dc3545;
}

.category-error p {
  color: #6b7280;
  font-size: 1rem;
  margin: 0;
}

/* ===== RESPONSIVE DESIGN ===== */

/* Tablet (768px - 1024px) */
@media (max-width: 1024px) {
  .categories-section {
    padding: 48px 0;
  }
  
  .categories-section .container {
    max-width: 100%;
    padding: 0 20px;
  }

  .similar-products-grid.horizontal-scroll {
    padding-right: 20px; /* Match container padding */
  }

  .category-showcase {
    margin-bottom: 48px;
  }

  .category-title {
    font-size: 1.75rem;
  }
  
  .category-view-all {
    padding: 8px 16px;
    font-size: 0.9rem;
  }

  .similar-products-grid.horizontal-scroll .product-card {
    min-width: 240px;
    max-width: 240px;
  }
}

/* Mobile (max-width: 767px) */
@media (max-width: 767px) {
  .categories-section {
    padding: 40px 0;
  }

  .categories-section .container {
    max-width: 100%;
    padding: 0 16px;
  }

  .similar-products-grid.horizontal-scroll {
    padding-right: 16px; /* Match container padding */
  }

  .category-showcase {
    margin-bottom: 40px;
  }

  .category-header {
    flex-wrap: wrap;
    gap: 12px;
  }

  .category-header-with-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .category-title {
    font-size: 1.5rem;
  }
  
  .category-view-all {
    padding: 8px 14px;
    font-size: 0.85rem;
  }

  .scroll-buttons {
    align-self: flex-end;
  }

  .scroll-btn {
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
  }

  .similar-products-grid.horizontal-scroll .product-card {
    min-width: 200px;
    max-width: 200px;
  }

  .category-loading,
  .category-error {
    padding: 40px 16px;
  }

  .loading-spinner {
    width: 32px;
    height: 32px;
    border-width: 3px;
  }

  .category-error i {
    font-size: 2.5rem;
  }
}

/* Empty State */
.category-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}

.category-empty p {
  color: #6b7280;
  font-size: 1rem;
  margin: 0;
}

/* Small Mobile (max-width: 480px) */
@media (max-width: 480px) {
  .categories-section .container {
    padding: 0 12px;
  }
  
  .category-title {
    font-size: 1.25rem;
  }
  
  .category-view-all {
    padding: 6px 12px;
    font-size: 0.8rem;
    gap: 4px;
  }
  
  .category-view-all i {
    font-size: 0.75rem;
  }

  .similar-products-grid.horizontal-scroll {
    padding-right: 12px; /* Match container padding */
  }

  .similar-products-grid.horizontal-scroll .product-card {
    min-width: 180px;
    max-width: 180px;
  }

  .category-empty {
    padding: 40px 16px;
  }
}
