/* =========================================================
   Bijoux Hélène Riu — UX / Conversion — custom-bijoux.css
   ========================================================= */

/* ── A. HEADER STICKY ───────────────────────────────────── */
/* Fix: theme.css applique body{overflow:hidden} qui casse position:sticky */
html, body {
  overflow-x: clip !important;
}
body {
  overflow-y: visible !important;
}
#header, .header-top {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.header-top {
  transition: padding .2s ease;
}
.header-scrolled #header {
  box-shadow: 0 2px 12px rgba(0,0,0,0.1);
}

/* ── B. WISHLIST 44x44 (WCAG tactile) ───────────────────── */
.btn-product-wishlist,
.product-add-to-wishlist,
button[data-action="favorites"] {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ── C. STICKY CART MOBILE ──────────────────────────────── */
.product-sticky-cart {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1050;
  background: #fff;
  border-top: 1px solid #e8e0d4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  min-height: 56px;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.08);
}
.product-sticky-cart .sticky-price {
  font-size: 1.1rem;
  font-weight: 700;
  color: #2c1a0e;
  white-space: nowrap;
}
.product-sticky-cart .btn-sticky-cart {
  flex: 1;
  min-height: 44px;
  background: #c9a96e;
  color: #2c1a0e;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.product-sticky-cart .btn-sticky-cart:hover {
  background: #b8924d;
}

/* ── A11Y — WCAG 2.1 AA ─────────────────────────────────── */

/* Skip link */
.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  background: #2c1a0e;
  color: #f5f0e8;
  padding: 0.75rem 1.25rem;
  font-weight: 600;
  font-size: 1rem;
  z-index: 99999;
  border-radius: 0 0 6px 0;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 0;
}

/* Focus visible global — outline 2px sur tous les éléments interactifs */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid #c9a96e;
  outline-offset: 3px;
}

/* Boutons unstyled pour icons de navigation */
.btn-unstyled {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ── E. GALERIE PRODUIT ─────────────────────────────────── */

/* Aspect-ratio 1:1 anti-CLS + fond neutre */
.product__images .carousel-item {
  aspect-ratio: 1 / 1;
  background: #f5f0e8;
  overflow: hidden;
}
.product__images .carousel-item picture,
.product__images .carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Zoom hover CSS sur l'image principale */
.product__images .carousel-item img {
  transition: transform 0.35s ease;
}
.product__images .carousel-item:hover img {
  transform: scale(1.08);
}

/* Mobile: thumbnails scroll-snap horizontal */
@media (max-width: 767.98px) {
  .thumbnails__container .thumbnails__list {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 0.5rem;
    padding-bottom: 0.25rem;
  }
  .thumbnails__container .thumbnail {
    flex: 0 0 72px;
    scroll-snap-align: start;
    width: 72px !important;
    min-width: 72px;
  }
}

/* ── D. UX MOBILE ────────────────────────────────────────── */

/* Swatches pierres 44x44px min (WCAG tactile) */
.product-variants .color,
.product-variants .input-radio,
.product-variants .input-color {
  min-width: 44px !important;
  min-height: 44px !important;
}

/* CTA hero: colonne sur mobile */
@media (max-width: 575.98px) {
  .slider__content .slider__actions,
  .banner__actions,
  #content .hero-cta-group {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0.75rem;
  }
  .slider__content .slider__actions .btn,
  .banner__actions .btn {
    width: 100%;
    text-align: center;
  }
}

/* Menu burger items min 48px */
@media (max-width: 991.98px) {
  #mobile_top_menu_wrapper .top-menu a,
  .mobile-menu .top-menu a,
  #top-menu a {
    min-height: 48px;
    display: flex;
    align-items: center;
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
  }
}


/* ── F. STICKY NEWSLETTER BANNER ────────────────────────── */
#bijoux-newsletter-sticky {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: #2c1a0e;
  color: #f5f0e8;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.25);
  transform: translateY(100%);
  transition: transform 0.4s ease;
}
#bijoux-newsletter-sticky.is-visible {
  transform: translateY(0);
}
#bijoux-newsletter-sticky .bijoux-nl-text {
  flex: 1;
  min-width: 0;
}
#bijoux-newsletter-sticky .bijoux-nl-text strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}
#bijoux-newsletter-sticky .bijoux-nl-text span {
  font-size: 0.8rem;
  opacity: 0.85;
}
#bijoux-newsletter-sticky .bijoux-nl-cta {
  white-space: nowrap;
  background: #c9a96e;
  color: #2c1a0e;
  border: none;
  border-radius: 6px;
  padding: 0.55rem 1rem;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: none;
}
#bijoux-newsletter-sticky .bijoux-nl-close {
  background: none;
  border: none;
  color: #f5f0e8;
  font-size: 1.4rem;
  cursor: pointer;
  padding: 0 0.25rem;
  line-height: 1;
  opacity: 0.75;
  flex-shrink: 0;
}
#bijoux-newsletter-sticky .bijoux-nl-close:hover {
  opacity: 1;
}
@media (max-width: 575.98px) {
  #bijoux-newsletter-sticky {
    flex-wrap: wrap;
    padding: 0.875rem 1rem;
  }
  #bijoux-newsletter-sticky .bijoux-nl-text {
    flex: 1 1 calc(100% - 2.5rem);
    order: 1;
  }
  #bijoux-newsletter-sticky .bijoux-nl-close {
    order: 2;
  }
  #bijoux-newsletter-sticky .bijoux-nl-cta {
    order: 3;
    flex: 1 1 100%;
    text-align: center;
  }
}
