/* Additional theme styles - loaded after style.css */

/* Smooth image loading */
img {
  transition: opacity 0.3s ease;
}

/* Elementor full-width sections look better */
.elementor-section.elementor-section-stretched {
  left: 0 !important;
}

/* Better product card hover */
.woocommerce ul.products li.product .button {
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
}

.woocommerce ul.products li.product:hover .button {
  opacity: 1;
  transform: translateY(0);
}

/* Ensure Elementor widgets inherit theme fonts */
.elementor-widget-heading .elementor-heading-title {
  font-family: var(--font-heading);
}

.elementor-widget-text-editor {
  font-family: var(--font-body);
}

/* Cart count badge always visible when > 0 */
.cart-count:empty {
  display: none;
}
/* ========== DEMO PRODUCT CARDS ========== */
.demo-products-grid,
.product-carousel {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 28px;
}

.demo-product-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  padding-bottom: 16px;
}

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

.demo-product-card img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
}

.demo-product-card h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  padding: 14px 16px 4px;
  margin: 0;
  color: var(--dark);
}

.demo-product-card .price {
  padding: 0 16px 12px;
  font-weight: 600;
  color: var(--primary);
  font-size: 1.05rem;
  margin: 0;
}

.demo-product-card .price del {
  color: #999;
  font-weight: 400;
  font-size: 0.9rem;
  margin-right: 6px;
}

.demo-product-card .price ins {
  text-decoration: none;
  color: var(--primary);
}

.demo-product-card .btn {
  margin: 0 16px;
  width: calc(100% - 32px);
}

.new-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--primary);
  color: var(--secondary);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  z-index: 5;
  letter-spacing: 0.06em;
}

/* ========== PRODUCT CAROUSEL ========== */
.product-carousel-wrap {
  position: relative;
  padding: 0 48px;
}

.product-carousel {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  padding-bottom: 12px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.product-carousel::-webkit-scrollbar {
  display: none;
}

.product-carousel .demo-product-card,
.product-carousel .product,
.product-carousel ul.products li.product {
  flex: 0 0 280px;
  scroll-snap-align: start;
  max-width: 280px;
}

.product-carousel ul.products {
  display: flex !important;
  gap: 24px;
  margin: 0;
  padding: 0;
  width: max-content;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--secondary);
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.carousel-btn:hover {
  background: var(--secondary);
  color: var(--primary);
}

.carousel-prev { left: 0; }
.carousel-next { right: 0; }

/* ========== STORY GRID ========== */
.story-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.story-visual {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 12px;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
  padding: 40px;
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--secondary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: var(--primary);
}

/* Category cards with images */
.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

.category-card {
  background: var(--primary);
}

@media (max-width: 768px) {
  .story-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .product-carousel-wrap {
    padding: 0 36px;
  }
  .product-carousel .demo-product-card,
  .product-carousel .product {
    flex: 0 0 240px;
    max-width: 240px;
  }
}

/* ========== CRITICAL: Fix WooCommerce float columns (thin cards bug) ========== */
.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product,
.woocommerce.columns-1 ul.products li.product,
.woocommerce.columns-2 ul.products li.product,
.woocommerce.columns-3 ul.products li.product,
.woocommerce.columns-4 ul.products li.product,
.woocommerce.columns-5 ul.products li.product,
.woocommerce.columns-6 ul.products li.product,
.woocommerce ul.products[class*=columns-] li.product,
.woocommerce-page ul.products[class*=columns-] li.product {
  width: 100% !important;
  max-width: 100% !important;
  float: none !important;
  clear: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.woocommerce ul.products li.product.first,
.woocommerce ul.products li.product.last {
  clear: none !important;
}

/* Ensure product link doesn't break layout */
.woocommerce ul.products li.product a {
  display: block;
  text-decoration: none;
}

.woocommerce ul.products li.product .woocommerce-LoopProduct-link {
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* Bigger logo on desktop */
@media (min-width: 769px) {
  .custom-logo-link img,
  .custom-logo {
    max-height: 100px !important;
  }
}

/* Mobile header polish */
@media (max-width: 768px) {
  .header-inner {
    flex-wrap: nowrap;
    gap: 12px;
  }

  .site-branding {
    order: 1;
    flex: 1;
  }

  .header-actions {
    order: 2;
  }

  .menu-toggle {
    order: 3;
  }

  .main-navigation.active {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    padding: 20px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    z-index: 999;
  }

  .hero-title {
    font-size: 2.2rem !important;
  }

  .section {
    padding: 40px 0 !important;
  }

  .section-title {
    font-size: 1.6rem !important;
  }

  .category-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px !important;
  }

  .category-card {
    aspect-ratio: 3/4;
  }

  .category-overlay h3 {
    font-size: 1rem !important;
  }

  .story-grid {
    grid-template-columns: 1fr !important;
  }

  .testimonial-slider {
    grid-template-columns: 1fr !important;
  }

  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }

  .features-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }
}

@media (max-width: 480px) {
  .features-grid {
    grid-template-columns: 1fr 1fr !important;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-buttons .btn {
    width: 100%;
    text-align: center;
  }
}

/* Hide all sale badges */
.onsale,
span.onsale,
.woocommerce span.onsale,
.woocommerce ul.products li.product .onsale,
.woocommerce div.product span.onsale,
.new-badge {
  display: none !important;
}

/* ========== BANNER CAROUSEL ========== */
.banner-carousel-section {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.banner-carousel {
  position: relative;
  height: 420px;
  background: var(--primary);
}

.banner-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.7s ease;
  display: flex;
  align-items: center;
}

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

.banner-content {
  position: relative;
  z-index: 2;
  max-width: 560px;
  padding: 40px 60px;
  color: #fff;
}

.banner-label {
  display: inline-block;
  background: rgba(236, 188, 96, 0.2);
  border: 1px solid var(--secondary);
  color: var(--secondary);
  padding: 5px 16px;
  border-radius: 30px;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.banner-content h2 {
  color: #fff;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  margin-bottom: 12px;
}

.banner-content p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 24px;
}

.banner-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(1, 17, 47, 0.7);
  color: var(--secondary);
  border: 1px solid var(--secondary);
  font-size: 1.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.banner-nav:hover {
  background: var(--secondary);
  color: var(--primary);
}

.banner-prev { left: 20px; }
.banner-next { right: 20px; }

.banner-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  gap: 10px;
}

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

.banner-dots .dot.active {
  background: var(--secondary);
  transform: scale(1.2);
}

/* ========== DUAL IMAGE SIDE SECTION ========== */
.dual-image-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.dual-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 7/5;
  display: block;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

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

.dual-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.dual-card:hover img {
  transform: scale(1.06);
}

.dual-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(1,17,47,0.85) 0%, transparent 55%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
  color: #fff;
}

.dual-overlay h3 {
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 4px;
}

.dual-overlay span {
  color: var(--secondary);
  font-size: 0.95rem;
  font-weight: 500;
}

@media (max-width: 768px) {
  .banner-carousel {
    height: 320px;
  }
  .banner-content {
    padding: 24px 50px 24px 24px;
  }
  .banner-content h2 {
    font-size: 1.6rem;
  }
  .banner-nav {
    width: 36px;
    height: 36px;
    font-size: 1.4rem;
  }
  .banner-prev { left: 8px; }
  .banner-next { right: 8px; }

  .dual-image-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}
