/* ============================================
   VILCHES - Product Listing customizations
   Minimal changes, scoped selectors
   ============================================ */

/* --- Hide sidebar (moved into drawer via JS) --- */
#category #left-column,
#search #left-column {
  display: none;
}

/* --- Full width: container, row, content --- */
#category #wrapper > .container,
#search #wrapper > .container {
  width: 100% !important;
  max-width: 100% !important;
  padding-left: 15px;
  padding-right: 15px;
}

/* --- Hide grid/list toggle --- */
#category .display,
#search .display {
  display: none !important;
}

#category #wrapper > .container > .row,
#search #wrapper > .container > .row {
  margin-left: 0;
  margin-right: 0;
}

#category #content-wrapper,
#search #content-wrapper {
  width: 100% !important;
  max-width: 100% !important;
  flex: 0 0 100% !important;
  padding-left: 0;
  padding-right: 0;
}

/* --- Sidebar visible inside drawer --- */
.vilches-drawer-body #left-column {
  display: block !important;
  width: 100% !important;
  padding: 0 !important;
  position: static !important;
  float: none !important;
}

.vilches-drawer-body #search_filters > p.text-uppercase {
  display: none !important;
}

.vilches-drawer-body .hidden-sm-down,
.vilches-drawer-body .facet .hidden-sm-down {
  display: block !important;
}

.vilches-drawer-body .hidden-md-up,
.vilches-drawer-body .facet .hidden-md-up {
  display: none !important;
}

.vilches-drawer-body .collapse,
.vilches-drawer-body .facet .collapse {
  display: block !important;
  height: auto !important;
}

/* --- Filter button --- */
.vilches-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 14px;
  border: 1px solid #ccc;
  border-radius: 20px;
  background: #fff;
  font-size: 13px;
  color: #333;
  cursor: pointer;
  transition: all 0.2s;
  margin-right: 10px;
}

.vilches-filter-btn:hover { border-color: #333; }
.vilches-filter-btn .material-icons { font-size: 16px; }

/* ===========================================
   FILTER DRAWER
   =========================================== */
.vilches-drawer-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
  z-index: 9998;
}

.vilches-drawer-overlay.open { display: block; }

.vilches-drawer {
  position: fixed;
  top: 0;
  left: -360px;
  width: 340px;
  height: 100%;
  background: #fff;
  z-index: 9999;
  box-shadow: 2px 0 12px rgba(0,0,0,0.15);
  transition: left 0.3s ease;
  display: flex;
  flex-direction: column;
}

.vilches-drawer.open { left: 0; }

.vilches-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #e5e5e5;
  flex-shrink: 0;
}

.vilches-drawer-title {
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.vilches-drawer-close {
  width: 32px; height: 32px;
  border: none; background: none;
  cursor: pointer; color: #666;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

.vilches-drawer-close:hover { background: #f0f0f0; }

.vilches-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 15px 20px;
}

/* --- Product grid: tighter gutters --- */
#category #js-product-list .product_list .row,
#search #js-product-list .product_list .row,
.parfois-related .products .row,
.featured-products .products .row,
.product-accessories .products .row {
  margin-left: 0;
  margin-right: 0;
}

#category #js-product-list .product_list .ajax_block_product[class*="col-"],
#search #js-product-list .product_list .ajax_block_product[class*="col-"],
.parfois-related .products [class*="col-"],
.featured-products .products [class*="col-"],
.product-accessories .products [class*="col-"] {
  padding-left: 1px;
  padding-right: 1px;
  margin-bottom: 2px;
}

/* ===========================================
   PRODUCT CARD - .vilches-product-card only
   =========================================== */
.vilches-product-card .product-image {
  position: relative;
  overflow: hidden;
  background: #f5f5f5;
  aspect-ratio: 3 / 4;
}

.vilches-product-card .product-image .product-thumbnail {
  display: block;
  width: 100%;
  height: 100%;
}

.vilches-product-card .product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.vilches-product-card:hover .product-image img {
  transform: scale(1.03);
}

.vilches-product-card .product-flags { display: none !important; }
.vilches-product-card .product-description-short { display: none !important; }

/* Hide action buttons (quickview, cart, compare, wishlist) */
.vilches-product-card .pro3-btn {
  display: none !important;
}

/* Product meta */
.vilches-product-meta {
  padding: 3px 4px 4px;
  text-align: left !important;
}

.vilches-flag {
  display: inline-block;
  font-size: 10px;
  color: #666;
  text-transform: capitalize;
}

.vilches-flag-new { color: #333; }
.vilches-flag-discount { color: #c00; }

.vilches-product-meta .product-title {
  font-size: 11px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  text-align: left !important;
}

.vilches-product-meta .product-title a {
  color: #333;
  text-decoration: none;
}

.vilches-product-meta .product-price-and-shipping {
  font-size: 12px;
  text-align: left !important;
}

.vilches-product-meta .regular-price {
  font-size: 11px;
  color: #999;
}

.vilches-product-meta .discount-percentage {
  font-size: 10px;
  color: #c00;
}

/* ===========================================
   OWL-CAROUSEL product sections — clean look
   =========================================== */
.category-products .products-section-title,
.product-accessories .products-section-title,
.parfois-related__title {
  font-size: 16px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-align: center;
  color: #1a1a1a;
  margin-bottom: 24px;
  padding-bottom: 12px;
}

.category-products .products-section-title span,
.product-accessories .products-section-title span {
  display: none;
}

/* Owl navigation arrows — minimal */
.category-products .owl-controls,
.product-accessories .owl-controls,
.parfois-related .owl-controls {
  margin-top: 12px;
  text-align: center;
}

.category-products .owl-buttons .owl-prev,
.category-products .owl-buttons .owl-next,
.product-accessories .owl-buttons .owl-prev,
.product-accessories .owl-buttons .owl-next,
.parfois-related .owl-buttons .owl-prev,
.parfois-related .owl-buttons .owl-next {
  background: none !important;
  color: #999;
  font-size: 24px;
  padding: 4px 10px;
  border: 1px solid #ddd;
  border-radius: 0;
  transition: all 0.2s;
}

.category-products .owl-buttons .owl-prev:hover,
.category-products .owl-buttons .owl-next:hover,
.product-accessories .owl-buttons .owl-prev:hover,
.product-accessories .owl-buttons .owl-next:hover,
.parfois-related .owl-buttons .owl-prev:hover,
.parfois-related .owl-buttons .owl-next:hover {
  border-color: #1a1a1a;
  color: #1a1a1a;
}

/* Owl item spacing */
.category-products .owl-carousel .owl-item,
.product-accessories .owl-carousel .owl-item,
.parfois-related .owl-carousel .owl-item {
  padding: 0 1px;
}

/* ===========================================
   RESPONSIVE
   =========================================== */
@media (max-width: 767px) {
  .vilches-drawer {
    width: 85vw;
    left: -85vw;
  }
}
