:root {
  --bg-color: #fafafa;
  --card-bg: #ffffff;
  --text-main: #1a1a1a;
  --text-muted: #757575;
  --accent: #f44293;
  --whatsapp: #25d366;
  --morado: #f44293;
  --font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-focus-ring-color: transparent;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-color);
  color: var(--text-main);
  padding-bottom: 80px;
  overflow-x: hidden;
}

span.bold {
  color: var(--morado);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.container-nav {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.container-hero {
  padding: 0;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.floating-buttons {
  position: fixed;
  bottom: 25px;
  left: 25px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 1;
}

/* Estilo base para los botones */
.btn-float {
  width: 55px;
  height: 55px;
  background: #25d366; /* color por defecto (WhatsApp) */
  color: white;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 28px;
  text-decoration: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.btn-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35);
}

/* WhatsApp */
.whatsapp {
  background: #25d366;
}

.whatsapp img {
  width: 45px;
}

/* Facebook */
.facebook {
  background: #1877f2;
}

.facebook img {
  width: 35px;
}

.instagram {
  background: #e1306c;
}

.instagram img {
  width: 45px;
}

/* --- Header & Search (Igual que antes) --- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(250, 250, 250, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}
.logo {
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -1px;
}
/* --- Modificación Header Icons --- */
.header-icons {
  display: flex;
  gap: 16px;
  align-items: center;
}

/* El contenedor del icono de lupa */
#search-toggle {
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  /* Por defecto oculto al inicio (lo manejaremos con JS) */
  opacity: 0;
  pointer-events: none;
  transform: scale(0.8);
}

/* Clase para mostrar el icono cuando hacemos scroll */
#search-toggle.visible {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

/* --- Estilos Base (Input Gris por defecto) --- */
.search-wrapper {
  display: flex;
  align-items: center;
  background: #f5f5f5; /* Gris claro por defecto (para cuando la barra es blanca) */
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 1.2rem;
  transition:
    background 0.3s ease,
    box-shadow 0.3s ease;
}

.search-wrapper input {
  font-size: 1.4rem;
  border: none;
  background: transparent;
  width: 100%;
}

/* --- Barra de Búsqueda (Contenedor) --- */
.search-bar {
  position: fixed;
  top: 60px;
  left: 0;
  width: 100%;
  z-index: 90;

  /* Estado Scrolled/Popup (Barra Blanca) */
  background: #ffffff;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  padding: 12px 16px;

  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-15px);
}

.search-bar.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* --- ESTADO ESTÁTICO (Top de la página) --- */
.search-bar.is-static {
  background: transparent; /* Contenedor transparente */
  box-shadow: none;
  transform: translateY(0);
}

#campo {
  border: none;
  background: transparent;
  width: 100%;
  outline: none;
  margin-left: 8px;
}

/* --- EL CAMBIO CLAVE: Input Blanco en modo Estático --- */
.search-bar.is-static .search-wrapper {
  background: #ffffff; /* ¡El input se vuelve blanco! */
  border: 1px solid #e0e0e0; /* Borde sutil para definirlo */
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05); /* Sombra suave para que flote un poco */
  font-size: 1.2rem;
}

.search-bar .close-btn {
  border: none;
  font-size: 1.5rem;
}
/* Ocultar botón cerrar 'X' en estático */
.search-bar.is-static .close-btn {
  display: none;
}
.icon-btn,
.cart-icon {
  font-size: 2rem;
  cursor: pointer;
  position: relative;
}
#cart-count {
  position: absolute;
  top: -5px;
  right: -8px;
  background: var(--accent);
  color: white;
  font-size: 0.7rem;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Search Bar */
.search-bar {
  position: fixed;
  top: 75px;
  left: 0;
  width: 100%;
  background: white;
  padding: 12px;
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s;
}
.search-bar.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.search-wrapper {
  display: flex;
  align-items: center;
  background: #f5f5f5;
  border-radius: 8px;
  font-size: 1.2rem;
  padding: 8px 12px;
}
#search-input {
  border: none;
  background: transparent;
  width: 100%;
  outline: none;
  margin-left: 8px;
}

/* --- Carousel --- */
.carousel {
  position: relative;
  width: 100%;
  height: 350px;
  overflow: hidden;
  margin-bottom: 10px;
}
.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
}
.slide.active {
  opacity: 1;
}
.slide::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 80%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
}
.slide-content {
  position: relative;
  z-index: 2;
  padding: 24px;
  color: white;
}
.slide h2 {
  font-size: 2rem;
  line-height: 1.1;
  margin: 8px 0;
}

/* --- Filters --- */
.category-filter {
  display: flex;
  gap: 12px;
  padding: 16px;
  overflow-x: auto;
  scrollbar-width: none;
}
.filter-btn {
  text-decoration: none;
  color: var(--dark-color);
  background: none;
  border: 1px solid #e0e0e0;
  padding: 8px 16px;
  border-radius: 20px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.3s;
}
.filter-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.title_categorias {
  font-size: 1.8rem;
  font-weight: bold;
  margin-top: 26px;
  margin-bottom: 16px;
}

@media (max-width: 768px) {
  .title_categorias {
    font-size: 1.5rem;
  }
}

.products-title {
  font-size: 1.4rem;
  font-weight: bold;
  margin-left: 16px;
  margin-bottom: 16px;
}

/* --- Grid & Product Card --- */
.container {
  padding: 0 16px;
}
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.product-info {
  padding: 5px;
}

.product-card {
  background: var(--card-bg);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid #f0f0f0;
}
.image-container {
  position: relative;
  aspect-ratio: 3/4;
}
.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Category Tag (Floating) */
.category-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(244, 66, 147, 0.65);
  color: white;
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  font-weight: 600;
  text-transform: capitalize;
  letter-spacing: 0.3px;
}

/* Product Title */
.product-title {
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--text-main);
  line-height: 1.3;

  display: -webkit-box; /* comportamiento de caja flexible */
  -webkit-box-orient: vertical; /* orientación vertical */
  -webkit-line-clamp: 3; /* máximo de líneas */
  line-clamp: 3;
  overflow: hidden; /* oculta el excedente */
  text-overflow: ellipsis; /* agrega los ... */
}

/* Product Description - Limited to 2 lines */
.product-description {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 12px;

  /* Limit to 2 lines with ellipsis */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;

  /* Fallback for non-webkit browsers */
  max-height: 2.8em; /* 2 lines * 1.4 line-height */
}

.product-bottom-row {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start; /* Alinea el botón con la base del precio */
  margin-top: 8px;
}

/* Contenedor de precios */
/* Contenedor del precio tachado */
.price-wrapper {
  margin-bottom: 2px; /* Pequeña separación con el precio real */
  line-height: 1;
}

/* Estilo del texto del precio original */
.price-original {
  text-decoration: line-through; /* Esto crea la línea tachada */
  color: #999999; /* Color gris */
  font-size: 0.9rem; /* Tamaño ligeramente más pequeño */
  font-weight: 500;
}

/* --- PRECIO PRINCIPAL (Naranja estilo Imagen 1) --- */
.price-current {
  width: 100%;
  color: #333; /* Naranja vibrante */
  display: flex;
  justify-content: space-between;
  line-height: 0.9; /* Compacto */
  font-family: var(--font-family);
}

.currency-symbol {
  font-size: 18px;
  margin-top: 4px; /* Ajuste óptico */
  font-weight: 500;
}

.price-integer {
  font-size: 1.8rem; /* El número más grande */
  font-weight: 500; /* No tan grueso, más limpio */
  letter-spacing: -1px;
}

.price-decimals {
  font-size: 0.9rem;
  margin-top: 2px;
  font-weight: 500;
}

/* --- INFORMACIÓN SECUNDARIA (Precio tachado + Badge Negro) --- */
.price-secondary-info {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: #999; /* Gris suave */
  margin-top: 4px;
}

.price-old {
  text-decoration: line-through;
  font-weight: 400;
  font-size: 18px;
}

/* --- BOTÓN AGREGAR (Manteniendo tu estilo anterior) --- */
.btn-add {
  background: var(--accent);
  padding: 2px 12px;
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* --- CART SIDEBAR --- */
.cart-sidebar {
  position: fixed;
  top: 0;
  right: -100%;
  width: 85%;
  max-width: 400px;
  height: 100%;
  background: white;
  z-index: 200;
  transition: right 0.3s ease;
  display: flex;
  flex-direction: column;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
}
.cart-sidebar.open {
  right: 0;
}
.cart-header {
  padding: 20px;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.cart-items {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
}

.cart-header .close-btn {
  background: none;
  background-color: transparent;
  border: none;
  font-size: 2rem;
  cursor: pointer;
}

/* Cart Item Style */
.cart-item {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: center;
}
.cart-item img {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  object-fit: cover;
}
.cart-item-info {
  flex-grow: 1;
}
.cart-item-info h4 {
  font-size: 0.9rem;
  margin-bottom: 4px;
  display: -webkit-box; /* comportamiento de caja flexible */
  -webkit-box-orient: vertical; /* orientación vertical */
  -webkit-line-clamp: 3; /* máximo de líneas */
  line-clamp: 3;
  overflow: hidden; /* oculta el excedente */
  text-overflow: ellipsis; /* agrega los ... */
}
.cart-remove {
  color: red;
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
}

.cart-footer {
  padding: 20px;
  border-top: 1px solid #eee;
  background: #fafafa;
}

#cart-total-price {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.cart-total-container {
  width: 100%;
  display: flex;
  justify-content: space-between;
}
.cart-label-container {
  width: 100%;
  display: flex;
  justify-content: space-between;
  font-size: 1.4rem;
  color: var(--text-main);
}

/* Cart Total Breakdown */
.cart-total-details {
  width: 100%;
  margin-top: 10px;
}

.cart-row {
  display: flex;
  justify-content: space-between;
  font-size: 1.2rem;
  color: #666;
  font-weight: 500;
}

.cart-row.discount {
  color: var(--accent);
}

.cart-row.final-total {
  font-weight: bold;
  font-size: 1.2em;
  color: var(--text-main);
  margin-top: 10px;
  border-top: 1px solid #ddd;
  padding-top: 10px;
}

.cart-coupon-section {
  padding: 15px;
  border-top: 1px solid #eee;
}

#coupon-code {
  text-transform: uppercase;
}

.checkout-total-breakdown .final-total {
  font-weight: bold;
  font-size: 1.4em;
  color: var(--text-main);
  margin-top: 10px;
  border-top: 1px solid #ddd;
  padding-top: 10px;
  margin-bottom: 1.2rem;
}
.whatsapp-checkout-btn {
  width: 100%;
  background: var(--accent);
  color: white;
  border: none;
  padding: 14px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 150;
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
}
.overlay.active {
  opacity: 1;
  visibility: visible;
}
.empty-msg {
  text-align: center;
  color: #aaa;
  margin-top: 40px;
}

/* Toast */
.toast {
  position: fixed;
  text-align: center;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--accent);
  color: white;
  padding: 10px 24px;
  border-radius: 30px;
  opacity: 0;
  transition: 0.4s;
  z-index: 300;
}
.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
.toast.error {
  background: #ef4444;
}

@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --- CHECKOUT MODAL --- */
.checkout-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 250;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.checkout-modal.active {
  opacity: 1;
  visibility: visible;
}

.checkout-modal-content {
  background: white;
  border-radius: 16px;
  width: 90%;
  max-width: 450px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.checkout-modal.active .checkout-modal-content {
  transform: scale(1);
}

.checkout-modal-header {
  padding: 24px;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.checkout-modal-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
}

.checkout-modal-header .close-btn {
  background: none;
  background-color: transparent;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #999;
  transition: color 0.2s;
}

.checkout-modal-header .close-btn:hover {
  color: #333;
}

.checkout-form {
  padding: 24px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-main);
  font-size: 0.95rem;
}

.form-group input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  font-family: var(--font-family);
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}

.form-group input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

.checkout-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: #f8f8f8;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 1.2rem;
  font-weight: 700;
}

.checkout-total span:last-child {
  color: var(--accent);
}

.btn-submit-checkout {
  width: 100%;
  background: var(--accent);
  color: white;
  border: none;
  padding: 16px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.btn-submit-checkout:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.btn-submit-checkout:active {
  transform: translateY(0);
}

/* Improved cart remove button styling */
.cart-remove {
  color: #ff4444;
  background: rgba(255, 68, 68, 0.1);
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.2s;
}

.cart-remove:hover {
  background: rgba(255, 68, 68, 0.2);
  transform: scale(1.1);
}

@media (max-width: 480px) {
  .checkout-modal-content {
    width: 95%;
    max-height: 95vh;
  }

  .checkout-modal-header {
    padding: 20px;
  }

  .checkout-form {
    padding: 20px;
  }
}

/* --- PAGINATION STYLES --- */

.pagination li {
  list-style: none;
}
.pagination_container {
  margin-top: 40px;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

#lbl-total {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

#nav-paginacion {
  display: flex;
  justify-content: center;
}

.pagination {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
}

.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-main);
  text-decoration: none;
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.pagination a:hover {
  background: var(--bg-color);
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.pagination .active,
.pagination .active a {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  font-weight: 600;
  cursor: default;
}

.pagination .active:hover {
  transform: none;
  box-shadow: none;
}

.pagination .disabled,
.pagination .disabled a {
  color: #ccc;
  cursor: not-allowed;
  pointer-events: none;
  background: #f5f5f5;
  border-color: #e0e0e0;
}

/* Pagination arrows */
.pagination a[aria-label="Previous"],
.pagination a[aria-label="Next"],
.pagination span[aria-label="Previous"],
.pagination span[aria-label="Next"] {
  font-weight: 600;
}

@media (max-width: 640px) {
  .pagination a,
  .pagination span {
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    font-size: 0.85rem;
  }

  .pagination {
    gap: 6px;
  }

  .pagination_container {
    margin-top: 30px;
    margin-bottom: 30px;
  }
}

/* --- CATEGORY CAROUSEL STYLES --- */
.category-carousel-container {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px;
  overflow: hidden;
  margin-bottom: 15px;
}

.category-swiper {
  flex: 1;
  overflow: visible;
}

.category-swiper .swiper-wrapper {
  display: flex;
  align-items: center;
}

.category-swiper .swiper-slide {
  width: auto;
  flex-shrink: 0;
}

.category-swiper .filter-btn {
  text-decoration: none;
  color: var(--text-main);
  background: white;
  border: 1px solid #e0e0e0;
  padding: 8px 16px;
  border-radius: 20px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 500;
}

.category-swiper .filter-btn:hover {
  background: var(--bg-color);
  border-color: var(--accent);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.category-swiper .filter-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.category-nav-btn {
  background: white;
  border: 1px solid #e0e0e0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
  font-size: 1.2rem;
  color: var(--text-main);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.category-nav-btn:hover {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.category-nav-btn:active {
  transform: scale(0.95);
}

.category-nav-btn.swiper-button-disabled {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

/* Mobile adjustments */
@media (max-width: 640px) {
  .category-carousel-container {
    padding: 12px;
    gap: 6px;
  }

  .category-nav-btn {
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }

  .category-swiper .filter-btn {
    padding: 6px 14px;
    font-size: 0.85rem;
  }
}

/* --- FILTER BUTTON & SIDEBAR --- */

/* Button trigger */
.filter-trigger-btn {
  position: fixed;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  background-color: var(--accent);
  color: white;
  border: none;
  padding: 12px 16px 12px 12px; /* Extra padding right for visual balance */
  border-radius: 0 10px 10px 0;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
  z-index: 95; /* Below header/cart but above content */
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  transition: transform 0.7s ease-in-out;
  display: none; /* Hidden by default, shown via JS */
}

.filter-trigger-btn:hover {
  transform: translateY(-50%) translateX(5px);
}

.filter-trigger-btn i {
  font-size: 1.2rem;
}

.filter-header .close-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 2rem;
}

/* Sidebar */
.filter-sidebar {
  position: fixed;
  top: 0;
  left: -100%; /* Hidden to the left */
  width: 80%;
  max-width: 300px;
  height: 100%;
  background: white;
  z-index: 200; /* Same as cart sidebar */
  transition: left 0.7s ease-in-out;
  display: flex;
  flex-direction: column;
  box-shadow: 5px 0 15px rgba(0, 0, 0, 0.1);
}

.filter-sidebar.open {
  left: 0;
}

.filter-header {
  padding: 20px;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-color);
}

.filter-header h2 {
  font-size: 1.2rem;
  margin: 0;
}

.filter-content {
  flex-grow: 1;
  padding: 20px;
  overflow-y: auto;
}

.size-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.size-option-btn {
  padding: 10px 16px;
  border: 1px solid #ddd;
  background: white;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 1rem;
  color: var(--text-main);
  min-width: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.size-option-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.size-option-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  box-shadow: 0 4px 8px rgba(106, 81, 174, 0.3);
}

.active-filters-summary {
  padding: 10px 20px;
  background: #f0f0f0;
  font-size: 0.9rem;
  color: var(--text-muted);
}
