/* Page catalogue Produits — hero moderne, filtres, grille cartes */

.page-produits {
  --p-primary: #1c486f;
  --p-primary-mid: #2a5a85;
  --p-accent: #ef8121;
  --p-accent-light: #ff9a4d;
  --p-ease: cubic-bezier(0.22, 1, 0.36, 1);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(960px 640px at 100% 0%, rgba(28, 72, 111, 0.055), transparent 50%),
    radial-gradient(640px 480px at 0% 100%, rgba(239, 129, 33, 0.04), transparent 48%),
    #f1f5f9;
}

.prod-display {
  font-family: "Outfit", "Sora", "Plus Jakarta Sans", system-ui, sans-serif;
  letter-spacing: -0.025em;
}

/* Hero */
.prod-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(ellipse 80% 60% at 20% 100%, rgba(251, 191, 36, 0.12), transparent 52%),
    radial-gradient(ellipse 55% 45% at 100% 0%, rgba(56, 189, 248, 0.09), transparent 48%),
    linear-gradient(152deg, #040a14 0%, #0f2844 36%, #1c486f 58%, #0a1628 100%);
}

.prod-hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(72px);
  pointer-events: none;
  opacity: 0.5;
}

.prod-hero-orb--a {
  width: min(340px, 46vw);
  height: min(340px, 46vw);
  background: rgba(28, 72, 111, 0.65);
  top: -12%;
  right: -8%;
  animation: prodOrb 20s ease-in-out infinite;
}

.prod-hero-orb--b {
  width: min(240px, 38vw);
  height: min(240px, 38vw);
  background: rgba(239, 129, 33, 0.22);
  bottom: 0;
  left: -10%;
  animation: prodOrb 16s ease-in-out infinite reverse;
}

@keyframes prodOrb {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(-10px, 14px) scale(1.05);
  }
}

.prod-hero-grid {
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.5) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 75% 65% at 45% 35%, black, transparent);
  pointer-events: none;
}

.prod-hero-noise {
  position: absolute;
  inset: 0;
  opacity: 0.32;
  pointer-events: none;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

/* Ligne lumineuse — transition vers le contenu catalogue */
.prod-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  z-index: 4;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 154, 77, 0.45) 22%,
    rgba(56, 189, 248, 0.3) 50%,
    rgba(255, 154, 77, 0.45) 78%,
    transparent 100%
  );
  opacity: 0.9;
  pointer-events: none;
}

.prod-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1440px;
  margin: 0 auto;
  padding: 2.75rem 1rem 3rem;
  display: grid;
  gap: 1.75rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .prod-hero-inner {
    grid-template-columns: 1fr min(300px, 30%);
    padding: 3.25rem 1.5rem 3.5rem;
    gap: 2.5rem;
  }
}

.prod-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.95rem 0.35rem 0.45rem;
  border-radius: 9999px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 247, 237, 0.95);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  margin-bottom: 0.85rem;
}

.prod-kicker-ic {
  width: 28px;
  height: 28px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--p-accent-light), var(--p-accent));
  color: #0f172a;
}

.prod-hero-title {
  font-size: clamp(1.85rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.prod-hero-title [data-ecom-text-rotator] {
  display: block;
  margin-top: 0.2rem;
}

.prod-hero-rotator-line {
  display: flex;
  align-items: center;
  background: linear-gradient(102deg, #ff9a4d, #fff4e6 35%, #ef8121 70%, #ffb366);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: prodTitle 8s ease-in-out infinite;
}

@keyframes prodTitle {
  0%,
  100% {
    background-position: 0% center;
  }
  50% {
    background-position: 100% center;
  }
}

.prod-hero-lead {
  margin-top: 1rem;
  max-width: 34rem;
  font-size: 1.02rem;
  line-height: 1.65;
  color: rgba(226, 232, 240, 0.9);
}

.prod-stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1rem;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
}

.prod-stat-pill #produits-total-stat {
  font-variant-numeric: tabular-nums;
  color: #ffedd5;
  font-weight: 800;
}

.prod-hero-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.prod-btn-gold {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.85rem 1.3rem;
  border-radius: 9999px;
  font-weight: 800;
  font-size: 0.88rem;
  color: #0f172a;
  background: linear-gradient(135deg, #ff9a4d, #ef8121);
  box-shadow:
    0 12px 32px rgba(239, 129, 33, 0.32),
    0 0 0 1px rgba(255, 255, 255, 0.2) inset;
  transition: transform 0.28s var(--p-ease), filter 0.2s ease;
}

.prod-btn-gold::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, 0.35) 50%, transparent 62%);
  transform: translateX(-100%);
  transition: transform 0.65s var(--p-ease);
  pointer-events: none;
}

.prod-btn-gold:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
}

.prod-btn-gold:hover::after {
  transform: translateX(100%);
}

.prod-btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.85rem 1.2rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.86rem;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(10px);
  transition: background 0.22s ease, transform 0.22s var(--p-ease);
}

.prod-btn-ghost:hover {
  background: rgba(255, 255, 255, 0.13);
  transform: translateY(-2px);
}

.prod-lottie-ring {
  position: relative;
  border-radius: 1.65rem;
  padding: 3px;
  background: linear-gradient(
    135deg,
    rgba(239, 129, 33, 0.5),
    rgba(255, 154, 77, 0.35),
    rgba(28, 72, 111, 0.48),
    rgba(56, 189, 248, 0.22)
  );
  box-shadow: 0 24px 52px -20px rgba(0, 0, 0, 0.45);
}

.prod-lottie-inner {
  border-radius: 1.5rem;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(8px);
  aspect-ratio: 1;
  max-height: 280px;
  overflow: hidden;
}

.prod-lottie-inner > div {
  width: 100%;
  height: 100%;
  min-height: 200px;
}

/* Corps */
.prod-body {
  max-width: 1440px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

@media (min-width: 768px) {
  .prod-body {
    padding: 2.25rem 1.5rem 4.5rem;
  }
}

.page-produits #inner-firebase-status {
  border-radius: 1.15rem;
  border-width: 1px;
  box-shadow: 0 8px 28px -12px rgba(245, 158, 11, 0.35);
}

/* Barre recherche */
.prod-search-wrap {
  position: relative;
  max-width: 36rem;
  margin-bottom: 1.75rem;
}

@media (min-width: 1024px) {
  .prod-search-wrap {
    max-width: none;
  }
}

.prod-search-wrap::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 1.35rem;
  background: linear-gradient(135deg, rgba(28, 72, 111, 0.25), rgba(239, 129, 33, 0.2), rgba(28, 72, 111, 0.15));
  opacity: 0;
  transition: opacity 0.35s ease;
  z-index: 0;
  pointer-events: none;
}

.prod-search-wrap:focus-within::before {
  opacity: 1;
}

.prod-search-input {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: 1.25rem;
  border: 1px solid rgba(226, 232, 240, 0.95);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  padding: 0.95rem 1rem 0.95rem 3.25rem;
  font-size: 0.95rem;
  color: #0f172a;
  box-shadow: 0 8px 32px -12px rgba(28, 72, 111, 0.12);
  outline: none;
  transition:
    box-shadow 0.3s var(--p-ease),
    border-color 0.25s ease;
}

.prod-search-input::placeholder {
  color: #94a3b8;
}

.prod-search-input:focus {
  border-color: rgba(28, 72, 111, 0.35);
  box-shadow:
    0 12px 40px -14px rgba(28, 72, 111, 0.2),
    0 0 0 3px rgba(28, 72, 111, 0.08);
}

.prod-search-ic {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 6;
  color: #94a3b8;
  pointer-events: none;
  transition: color 0.25s ease;
}

.prod-search-wrap:focus-within .prod-search-ic {
  color: var(--p-primary);
}

/* Placeholder animé catalogue (aligné app home / search) */
.prod-search-input-slot.ecom-show-hint-overlay .prod-search-input.ecom-search-input--typed-hint {
  color: transparent !important;
  caret-color: transparent !important;
}

.prod-search-input-slot .ecom-search-hint-overlay--produits {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  padding-left: 3.25rem;
  padding-right: 1rem;
  font-size: 0.95rem;
  color: #94a3b8;
  pointer-events: none;
  overflow: hidden;
  line-height: 1.35;
}

.prod-search-input-slot .prod-search-input {
  position: relative;
  z-index: 4;
}

/* Panneau filtres */
.prod-filters {
  position: relative;
  border-radius: 1.35rem !important;
  background: rgba(255, 255, 255, 0.88) !important;
  backdrop-filter: blur(18px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(160%) !important;
  border: 1px solid rgba(226, 232, 240, 0.95) !important;
  box-shadow:
    0 16px 48px -24px rgba(28, 72, 111, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.7) inset !important;
}

.prod-filters::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(145deg, rgba(28, 72, 111, 0.12), rgba(239, 129, 33, 0.1), rgba(28, 72, 111, 0.06));
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.85;
}

.prod-filters h2 {
  font-size: 0.72rem !important;
  letter-spacing: 0.14em;
  background: linear-gradient(90deg, var(--p-primary), var(--p-accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

.prod-filters label {
  color: #64748b !important;
}

.prod-filters select,
.prod-filters input[type='text'],
.prod-filters input[type='number'] {
  border-radius: 0.85rem !important;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.prod-filters select:focus,
.prod-filters input:focus {
  border-color: rgba(28, 72, 111, 0.45) !important;
  box-shadow: 0 0 0 3px rgba(28, 72, 111, 0.1);
}

#produits-filter-reset {
  border-radius: 0.9rem !important;
  font-weight: 700 !important;
  transition:
    transform 0.22s var(--p-ease),
    background 0.2s ease,
    border-color 0.2s ease;
}

#produits-filter-reset:hover {
  transform: translateY(-1px);
  border-color: var(--p-primary) !important;
  color: var(--p-primary) !important;
}

/* Zone résultats — îlot glass */
.prod-results-zone {
  padding: 1.15rem 1rem 1.35rem;
  border-radius: 1.5rem;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  border: 1px solid rgba(226, 232, 240, 0.95);
  box-shadow: 0 12px 40px -20px rgba(28, 72, 111, 0.1);
}

@media (min-width: 1024px) {
  .prod-results-zone {
    padding: 1.35rem 1.35rem 1.6rem;
  }
}

.prod-results-icon {
  width: 2.65rem;
  height: 2.65rem;
  border-radius: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: linear-gradient(145deg, var(--p-primary), var(--p-primary-mid));
  color: #fff;
  box-shadow: 0 8px 22px -6px rgba(28, 72, 111, 0.45);
}

.prod-results-icon .material-icons {
  font-size: 1.3rem;
}

/* Bandeau résultats */
.prod-results-head {
  padding-bottom: 1rem;
  margin-bottom: 0.25rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
}

.prod-results-title {
  font-size: clamp(1.25rem, 2.2vw, 1.65rem);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.prod-results-count {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  background: rgba(28, 72, 111, 0.08);
  color: var(--p-primary);
  border: 1px solid rgba(28, 72, 111, 0.12);
}

.prod-results-count span {
  font-variant-numeric: tabular-nums;
}

/* Grille cartes */
.page-produits #produits-grid {
  gap: 1.25rem;
}

@media (min-width: 768px) {
  .page-produits #produits-grid {
    gap: 1.5rem;
  }
}

@keyframes prodCardReveal {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page-produits .produits-card {
  border-radius: 1.2rem;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  box-shadow: 0 4px 20px -8px rgba(15, 23, 42, 0.08);
  content-visibility: auto;
  contain-intrinsic-size: auto 340px;
  transition:
    transform 0.4s var(--p-ease),
    box-shadow 0.4s var(--p-ease),
    border-color 0.3s ease;
  animation: prodCardReveal 0.44s var(--p-ease) backwards;
}

.page-produits .produits-card:nth-child(1) {
  animation-delay: 0.04s;
}
.page-produits .produits-card:nth-child(2) {
  animation-delay: 0.08s;
}
.page-produits .produits-card:nth-child(3) {
  animation-delay: 0.12s;
}
.page-produits .produits-card:nth-child(4) {
  animation-delay: 0.16s;
}
.page-produits .produits-card:nth-child(5) {
  animation-delay: 0.2s;
}
.page-produits .produits-card:nth-child(6) {
  animation-delay: 0.24s;
}
.page-produits .produits-card:nth-child(7) {
  animation-delay: 0.28s;
}
.page-produits .produits-card:nth-child(8) {
  animation-delay: 0.32s;
}
.page-produits .produits-card:nth-child(9) {
  animation-delay: 0.36s;
}
.page-produits .produits-card:nth-child(n + 10) {
  animation-delay: 0.4s;
}

.page-produits .produits-card:hover {
  transform: translateY(-6px);
  box-shadow:
    0 24px 48px -16px rgba(28, 72, 111, 0.18),
    0 0 0 1px rgba(239, 129, 33, 0.06);
  border-color: rgba(28, 72, 111, 0.15);
}

.page-produits .produits-card-media {
  position: relative;
  overflow: hidden;
}

.page-produits .produits-card-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(15, 23, 42, 0.06) 100%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.page-produits .produits-card:hover .produits-card-media::after {
  opacity: 1;
}

.page-produits .produits-card-media img {
  transition: transform 0.55s var(--p-ease);
  transform: translateZ(0);
}

.page-produits .produits-card:hover .produits-card-media img {
  transform: scale(1.06);
}

.page-produits .produits-card .p-4 {
  padding: 1rem 1.1rem 1.15rem !important;
}

.page-produits .produits-card .text-lg.font-bold {
  font-size: 1.05rem !important;
  letter-spacing: -0.02em;
}

/* Empty state */
.prod-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2.5rem 1.5rem 3rem;
  border-radius: 1.5rem;
  background: linear-gradient(165deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  box-shadow: 0 20px 50px -28px rgba(28, 72, 111, 0.12);
  position: relative;
  overflow: hidden;
}

.prod-empty::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(28, 72, 111, 0.15), rgba(239, 129, 33, 0.12));
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.prod-empty-lottie {
  width: min(200px, 55vw);
  height: min(200px, 55vw);
  margin: 0 auto 1rem;
}

.prod-empty h3 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 0.5rem;
}

.prod-empty p {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.6;
  max-width: 22rem;
  margin: 0 auto;
}

@media (prefers-reduced-motion: reduce) {
  .prod-hero-orb--a,
  .prod-hero-orb--b {
    animation: none;
  }

  .prod-hero-rotator-line {
    animation: none;
    background-position: center;
  }

  .page-produits .produits-card {
    animation: none;
  }

  .prod-btn-gold::after {
    display: none;
  }

  .page-produits .produits-card:hover {
    transform: none;
  }

  .page-produits .produits-card:hover .produits-card-media img {
    transform: none;
  }
}
