/* ============================================
   LUXEO — Configurateur (carrelages)
   ============================================ */

/* HERO compact */
.cfg-hero {
  padding: 140px var(--gutter) 56px;
  padding-left: calc(var(--gutter) + env(safe-area-inset-left));
  padding-right: calc(var(--gutter) + env(safe-area-inset-right));
  background: linear-gradient(135deg, var(--fond-sombre) 0%, var(--fond-sombre-2) 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
  max-width: 100%;
}
.cfg-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(ellipse at 80% 20%, rgba(201, 168, 76, 0.15), transparent 50%),
    radial-gradient(ellipse at 20% 80%, rgba(14, 124, 123, 0.25), transparent 60%);
  pointer-events: none;
}
.cfg-hero > * { position: relative; z-index: 1; }
.cfg-hero .eyebrow { color: var(--or); }
.cfg-hero .eyebrow::before { background: var(--or); }
.cfg-hero h1 {
  color: #fff;
  font-size: clamp(38px, 5vw, 64px);
  margin: 20px 0 22px;
  max-width: 18ch;
}
.cfg-hero h1 em { font-style: italic; color: var(--or); font-weight: 200; }
.cfg-hero p {
  color: rgba(255,255,255,0.75);
  max-width: 60ch;
  font-size: 16px;
  line-height: 1.65;
}

.cfg-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.cfg-breadcrumb a { color: var(--or); transition: opacity .2s; }
.cfg-breadcrumb a:hover { opacity: 0.7; }
.cfg-breadcrumb .sep { opacity: 0.4; }

/* TOOLBAR / FILTERS */
.cfg-toolbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--ligne);
}
.cfg-toolbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.cfg-filters {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  flex: 1;
}
.cfg-filters::-webkit-scrollbar { display: none; }
.cfg-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  font-size: 13px;
  color: var(--texte);
  background: transparent;
  border: 1px solid var(--ligne);
  border-radius: 999px;
  white-space: nowrap;
  cursor: pointer;
  transition: all .3s var(--ease-out);
}
.cfg-filter .count {
  font-size: 11px;
  color: var(--texte-mute);
  background: rgba(0,0,0,0.04);
  padding: 2px 7px;
  border-radius: 999px;
}
.cfg-filter:hover {
  border-color: var(--turquoise);
  color: var(--turquoise);
}
.cfg-filter.active {
  background: var(--turquoise);
  color: #fff;
  border-color: var(--turquoise);
}
.cfg-filter.active .count {
  background: rgba(255,255,255,0.2);
  color: #fff;
}
.cfg-count-display {
  font-size: 12px;
  color: var(--texte-mute);
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.cfg-count-display span { color: var(--turquoise); font-weight: 600; }

/* PREVIEW STAGE */
.cfg-preview-stage {
  background: var(--fond-clair);
  padding: 60px var(--gutter);
}
.cfg-preview-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: clamp(30px, 5vw, 60px);
  align-items: center;
}
.cfg-preview-text .eyebrow { color: var(--turquoise); }
.cfg-preview-text h2 {
  margin: 18px 0 18px;
  font-size: clamp(28px, 3.4vw, 42px);
}
.cfg-preview-text h2 em { font-style: italic; color: var(--turquoise); font-weight: 200; }
.cfg-preview-text p { color: var(--texte-mute); line-height: 1.65; margin-bottom: 28px; }

.cfg-preview-info {
  background: #fff;
  border: 1px solid var(--ligne);
  border-left: 3px solid var(--or);
  padding: 18px 22px;
  border-radius: 4px;
}
.cfg-preview-info .lbl {
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--texte-mute);
  display: block;
  margin-bottom: 6px;
}
.cfg-preview-ref {
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--or);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.cfg-preview-name {
  font-size: 20px;
  font-weight: 400;
  color: var(--texte);
  margin-bottom: 4px;
}
.cfg-preview-meta {
  font-size: 13px;
  color: var(--texte-mute);
}

/* SCENE — 3D mockup */
.cfg-scene {
  position: relative;
  aspect-ratio: 4/3;
  background: #0a1f1f;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 40px 80px -30px rgba(10, 42, 42, 0.4), 0 0 0 1px var(--ligne);
  perspective: 1200px;
  transform-style: preserve-3d;
  transition: box-shadow .4s ease;
}
.cfg-wall, .cfg-floor {
  position: absolute;
  background-size: 25% auto;
  background-repeat: repeat;
  transition: background-image .6s var(--ease-out);
}
.cfg-wall-back,
.cfg-wall-left { background-image: var(--tile-murs, var(--tile-img)); }
.cfg-floor     { background-image: var(--tile-sol,  var(--tile-img)); }

/* ===== MUR DU FOND ===== */
.cfg-wall-back {
  inset: 0 0 36% 26%;
  background-blend-mode: normal;
  /* Realistic grout grid overlay */
  box-shadow:
    inset 0 -8px 18px -8px rgba(0,0,0,0.5),       /* shadow at floor junction */
    inset 8px 0 16px -8px rgba(0,0,0,0.35);        /* shadow at left wall junction */
}
.cfg-wall-back::before {
  /* Grout grid */
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,0,0,0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.18) 1px, transparent 1px);
  background-size: 25% 25%;
  mix-blend-mode: multiply;
  pointer-events: none;
}
.cfg-wall-back::after {
  /* Soft directional light from top-right */
  content: '';
  position: absolute; inset: 0;
  background:
    linear-gradient(135deg, rgba(255,235,200,0.18) 0%, transparent 45%, rgba(0,0,0,0.18) 100%),
    radial-gradient(ellipse at 80% 0%, rgba(255,220,170,0.2), transparent 50%);
  pointer-events: none;
}

/* ===== MUR LATÉRAL GAUCHE ===== */
.cfg-wall-left {
  top: 0; bottom: 36%; left: 0;
  width: 30%;
  background-size: 50% auto;
  transform: perspective(900px) rotateY(28deg);
  transform-origin: left center;
  clip-path: polygon(0 0, 100% 14%, 100% 86%, 0 100%);
}
.cfg-wall-left::before {
  /* Grout grid (smaller because of perspective) */
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,0,0,0.2) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.2) 1px, transparent 1px);
  background-size: 50% 25%;
  mix-blend-mode: multiply;
  pointer-events: none;
}
.cfg-wall-left::after {
  /* Deep shadow toward the back corner */
  content: '';
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(0,0,0,0.05) 0%, rgba(0,0,0,0.45) 100%),
    linear-gradient(180deg, transparent 60%, rgba(0,0,0,0.25) 100%);
  pointer-events: none;
}

/* ===== SOL ===== */
.cfg-floor {
  bottom: 0;
  left: 0; right: 0;
  height: 36%;
  background-size: 15% auto;
  transform: perspective(700px) rotateX(56deg);
  transform-origin: bottom center;
}
.cfg-floor::before {
  /* Grout grid for floor tiles */
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,0,0,0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.22) 1px, transparent 1px);
  background-size: 15% 24%;
  mix-blend-mode: multiply;
  pointer-events: none;
}
.cfg-floor::after {
  /* Wet/reflective floor + shadow from walls */
  content: '';
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg,
      rgba(0,0,0,0.5) 0%,
      rgba(0,0,0,0.15) 30%,
      rgba(255,255,255,0.12) 70%,
      rgba(255,255,255,0.2) 100%),
    radial-gradient(ellipse at 50% 80%, rgba(255,255,255,0.15), transparent 60%);
  pointer-events: none;
}

/* ===== JONCTION mur arrière / mur gauche (ligne d'ombre verticale) ===== */
.cfg-wall-back {
  position: absolute;
}
.cfg-wall-back::after { z-index: 1; }

/* Vertical dark line at the wall-to-wall corner */
.cfg-scene::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 36%;
  left: 26%;
  width: 8px;
  background: linear-gradient(90deg, rgba(0,0,0,0.45) 0%, rgba(0,0,0,0) 100%);
  pointer-events: none;
  z-index: 2;
}

/* Horizontal dark line at the wall-to-floor junction */
.cfg-scene::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 36%;
  height: 10px;
  background: linear-gradient(180deg, rgba(0,0,0,0.45) 0%, rgba(0,0,0,0) 100%);
  pointer-events: none;
  z-index: 2;
}

.cfg-drain {
  position: absolute;
  bottom: 7%;
  left: 50%;
  transform: translateX(-50%);
  width: 32%;
  height: 8px;
  background:
    linear-gradient(180deg, #1a1a1c 0%, #3a3a3c 30%, #5a5a5c 50%, #2a2a2c 80%, #0a0a0c 100%);
  border-radius: 2px;
  box-shadow:
    0 -2px 4px rgba(0,0,0,0.5),
    inset 0 1px 2px rgba(255,255,255,0.15);
  z-index: 3;
}
.cfg-drain::before {
  /* Tiny grate stripes */
  content: '';
  position: absolute;
  inset: 1px 2px 1px 2px;
  background:
    repeating-linear-gradient(90deg, transparent 0 2px, rgba(0,0,0,0.6) 2px 3px);
  border-radius: 1px;
}

.cfg-shower-arm {
  position: absolute;
  top: 11%;
  left: 48%;
  width: 5px;
  height: 64px;
  background: linear-gradient(90deg, #6a6a6c 0%, #c8c8ca 30%, #f5f5f7 50%, #b8b8ba 70%, #5a5a5c 100%);
  border-radius: 2px;
  box-shadow:
    -2px 2px 6px rgba(0,0,0,0.4),
    inset 0 0 1px rgba(255,255,255,0.5);
  z-index: 4;
}
.cfg-shower-head {
  position: absolute;
  top: 8%;
  left: 50%;
  transform: translateX(-50%);
  width: 84px;
  height: 18px;
  background:
    radial-gradient(ellipse at 30% 25%, #fafafa 0%, #d0d0d2 30%, #888 70%, #4a4a4c 100%);
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.2);
  box-shadow:
    0 6px 14px rgba(0,0,0,0.5),
    inset 0 -3px 6px rgba(0,0,0,0.3),
    inset 0 1px 2px rgba(255,255,255,0.6);
  z-index: 4;
}
.cfg-shower-head::after {
  /* Holes pattern */
  content: '';
  position: absolute;
  inset: 4px 8px 4px 8px;
  background:
    radial-gradient(circle, rgba(0,0,0,0.5) 1px, transparent 2px) 0 0 / 8px 6px;
  border-radius: 50%;
  opacity: 0.6;
}

.cfg-water {
  position: absolute;
  top: 14%;
  left: 42%;
  width: 90px;
  height: 50%;
  z-index: 3;
  pointer-events: none;
}
.cfg-water span {
  position: absolute;
  top: 0;
  width: 1.5px;
  height: 100%;
  background: linear-gradient(180deg,
    rgba(200,230,240,0.95) 0%,
    rgba(180,220,235,0.5) 50%,
    transparent);
  filter: blur(0.4px);
  animation: cfgWaterFall 0.95s linear infinite;
  opacity: 0.88;
}
.cfg-water span:nth-child(1) { left: 6px;  animation-delay: 0s;    }
.cfg-water span:nth-child(2) { left: 18px; animation-delay: 0.15s; }
.cfg-water span:nth-child(3) { left: 32px; animation-delay: 0.3s;  }
.cfg-water span:nth-child(4) { left: 44px; animation-delay: 0.45s; }
.cfg-water span:nth-child(5) { left: 54px; animation-delay: 0.1s;  }
.cfg-water span:nth-child(6) { left: 66px; animation-delay: 0.25s; }
.cfg-water span:nth-child(7) { left: 78px; animation-delay: 0.4s;  }
.cfg-water span:nth-child(8) { left: 38px; animation-delay: 0.55s; }
@keyframes cfgWaterFall {
  0%   { transform: translateY(-25%); opacity: 0; }
  10%  { opacity: 0.88; }
  90%  { opacity: 0.55; }
  100% { transform: translateY(85%); opacity: 0; }
}

/* ===== PAROI VITRÉE — verre réaliste ===== */
.cfg-glass-edge {
  position: absolute;
  top: 4%; bottom: 14%;
  right: 12%;
  width: 28%;
  z-index: 3;
  pointer-events: none;
  background:
    linear-gradient(115deg,
      rgba(220,235,240,0.04) 0%,
      rgba(220,235,240,0.12) 25%,
      rgba(255,255,255,0.18) 40%,
      rgba(220,235,240,0.10) 60%,
      rgba(180,210,225,0.16) 80%,
      rgba(220,235,240,0.06) 100%);
  border-radius: 2px;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.18),
    0 14px 30px -10px rgba(0,0,0,0.4),
    /* Right edge: metallic frame */
    inset -3px 0 6px -2px rgba(150,160,170,0.6);
  backdrop-filter: blur(1px);
}
.cfg-glass-edge::before {
  /* Highlight reflection diagonal */
  content: '';
  position: absolute;
  top: 8%;
  left: 12%;
  width: 30%;
  height: 38%;
  background: linear-gradient(135deg, rgba(255,255,255,0.4), transparent 70%);
  border-radius: 100%;
  filter: blur(8px);
  opacity: 0.7;
}
.cfg-glass-edge::after {
  /* Right metallic frame strip */
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: 0;
  width: 3px;
  background: linear-gradient(180deg, #9aa3a8, #d5dadd 50%, #6e7378);
  border-radius: 2px;
  box-shadow: 2px 0 6px rgba(0,0,0,0.3);
}

.cfg-light {
  position: absolute;
  inset: 0;
  background:
    /* Warm spot from ceiling */
    radial-gradient(ellipse 50% 40% at 55% 0%, rgba(255, 220, 165, 0.32), transparent 70%),
    /* Cool ambient from glass side */
    radial-gradient(ellipse 35% 60% at 100% 50%, rgba(180, 220, 235, 0.1), transparent 70%);
  mix-blend-mode: soft-light;
  z-index: 5;
  pointer-events: none;
}
.cfg-vignette {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, transparent 45%, rgba(0,0,0,0.5) 100%),
    /* Subtle steam at top */
    radial-gradient(ellipse 40% 18% at 30% 6%, rgba(255,255,255,0.08), transparent 70%),
    radial-gradient(ellipse 30% 14% at 65% 10%, rgba(255,255,255,0.05), transparent 70%);
  z-index: 6;
  pointer-events: none;
}

/* CATALOG GRID */
.cfg-catalog {
  background: #fff;
  padding: 60px var(--gutter) 100px;
}
.cfg-grid {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.cfg-tile {
  background: #fff;
  border: 2px solid transparent;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  transition: all .35s var(--ease-out);
  position: relative;
  box-shadow: 0 10px 30px -16px rgba(14, 124, 123, 0.18);
  display: flex;
  flex-direction: column;
}
.cfg-tile:hover {
  transform: translateY(-5px);
  border-color: var(--turquoise);
  box-shadow: 0 20px 50px -20px rgba(14, 124, 123, 0.35);
}
.cfg-tile.selected {
  border-color: var(--or);
  box-shadow: 0 0 0 1px var(--or), 0 20px 50px -16px rgba(201, 168, 76, 0.45);
}
.cfg-tile.selected::after {
  content: "✓";
  position: absolute;
  top: 10px; right: 10px;
  width: 28px; height: 28px;
  background: var(--or);
  color: #1a1100;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 13px;
  z-index: 3;
  box-shadow: 0 4px 12px rgba(201,168,76,0.5);
}

.cfg-tile-img {
  aspect-ratio: 1;
  background-size: cover;
  background-position: center;
  transition: transform .5s var(--ease-out);
}
.cfg-tile:hover .cfg-tile-img { transform: scale(1.06); }

.cfg-tile-info {
  padding: 14px 16px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.cfg-tile-ref {
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--or);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.cfg-tile-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--texte);
  margin-bottom: 8px;
  flex: 1;
}
.cfg-tile-meta {
  font-size: 12px;
  color: var(--texte-mute);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.cfg-tile-price {
  color: var(--turquoise);
  font-weight: 600;
}

/* STICKY PANEL */
.cfg-panel {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(150px);
  z-index: 90;
  background: var(--fond-sombre);
  color: #fff;
  border-radius: 999px;
  padding: 10px 10px 10px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 20px 50px -10px rgba(0,0,0,0.4), 0 0 0 1px rgba(201,168,76,0.25);
  transition: transform .5s var(--ease-out);
  max-width: calc(100vw - 32px);
}
.cfg-panel.show { transform: translateX(-50%) translateY(0); }

.cfg-panel .count {
  display: flex;
  align-items: baseline;
  gap: 6px;
  border-right: 1px solid rgba(255,255,255,0.12);
  padding-right: 16px;
}
.cfg-panel .count .n {
  font-size: 24px;
  font-weight: 200;
  color: var(--or);
  line-height: 1;
}
.cfg-panel .count .lbl {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
}

.cfg-panel .selected-list {
  display: flex;
  gap: 6px;
}
.cfg-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  font-size: 11px;
  color: #fff;
}
.cfg-chip.more {
  padding: 4px 12px;
  color: var(--or);
}
.cfg-chip .chip-img {
  width: 22px;
  height: 22px;
  background-size: cover;
  background-position: center;
  border-radius: 50%;
}
.cfg-chip .chip-x {
  background: rgba(255,255,255,0.08);
  border: none;
  color: rgba(255,255,255,0.7);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  cursor: pointer;
  margin-left: 4px;
}
.cfg-chip .chip-x:hover { background: #d63a3a; color: #fff; }

.cfg-panel .btn {
  padding: 11px 22px;
  font-size: 13px;
}

/* DEVIS SECTION */
.cfg-devis {
  background: var(--fond-sombre);
  color: #fff;
  padding: 80px var(--gutter);
  position: relative;
  overflow: hidden;
}
.cfg-devis::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 0% 0%, rgba(14, 124, 123, 0.3), transparent 50%),
    radial-gradient(circle at 100% 100%, rgba(201, 168, 76, 0.15), transparent 50%);
  pointer-events: none;
}
.cfg-devis-inner {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.cfg-devis-head {
  text-align: center;
  margin-bottom: 50px;
}
.cfg-devis-head .eyebrow { color: var(--or); justify-content: center; }
.cfg-devis-head .eyebrow::before, .cfg-devis-head .eyebrow::after { background: var(--or); }
.cfg-devis-head .eyebrow::after { content: ''; width: 36px; height: 1px; }
.cfg-devis-head h2 {
  color: #fff;
  margin: 18px auto 18px;
  max-width: 18ch;
}
.cfg-devis-head h2 em { font-style: italic; color: var(--or); font-weight: 200; }
.cfg-devis-head p {
  color: rgba(255,255,255,0.75);
  max-width: 60ch;
  margin: 0 auto;
}

.cfg-selection {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 4px;
  padding: 26px 28px;
  margin-bottom: 36px;
}
.cfg-selection-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-wrap: wrap;
  gap: 12px;
}
.cfg-selection-head h3 {
  color: #fff;
  font-size: 18px;
  font-weight: 400;
}
.cfg-selection .clear {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.7);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: all .25s;
}
.cfg-selection .clear:hover {
  border-color: #d63a3a;
  color: #d63a3a;
}

.cfg-selection-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.cfg-sel-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: rgba(14, 124, 123, 0.08);
  border-left: 3px solid var(--or);
  border-radius: 4px;
}
.cfg-sel-item .sel-img {
  width: 50px;
  height: 50px;
  background-size: cover;
  background-position: center;
  border-radius: 4px;
  flex-shrink: 0;
}
.cfg-sel-item .sel-info { flex: 1; min-width: 0; }
.cfg-sel-item .sel-ref {
  font-size: 10px;
  color: var(--or);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 2px;
}
.cfg-sel-item .sel-name {
  font-size: 13px;
  color: #fff;
  font-weight: 500;
  margin-bottom: 2px;
}
.cfg-sel-item .sel-meta {
  font-size: 11px;
  color: rgba(255,255,255,0.55);
}
.cfg-sel-item .sel-x {
  background: rgba(255,255,255,0.06);
  border: none;
  color: rgba(255,255,255,0.6);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 14px;
  cursor: pointer;
  flex-shrink: 0;
}
.cfg-sel-item .sel-x:hover { background: #d63a3a; color: #fff; }

.cfg-empty {
  text-align: center;
  padding: 30px 20px;
  color: rgba(255,255,255,0.45);
  font-size: 13px;
  line-height: 1.7;
}

/* Responsive */
@media (max-width: 1024px) {
  .cfg-grid { grid-template-columns: repeat(3, 1fr); }
  .cfg-preview-inner { grid-template-columns: 1fr; }
  .cfg-selection-list { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .cfg-hero { padding-top: 100px; padding-bottom: 40px; }
  .cfg-hero h1 { font-size: 36px; }
  .cfg-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .cfg-toolbar-inner { padding: 12px var(--gutter); }
  .cfg-filter { padding: 8px 12px; font-size: 12px; }
  .cfg-tile-info { padding: 12px; }
  .cfg-tile-name { font-size: 13px; }
  .cfg-scene { aspect-ratio: 4/3; }
  .cfg-panel {
    bottom: 12px;
    border-radius: 14px;
    padding: 10px 14px;
    flex-wrap: wrap;
    max-width: calc(100vw - 20px);
  }
  .cfg-panel .count { padding-right: 12px; }
  .cfg-panel .selected-list { display: none; }
  .cfg-devis { padding: 60px var(--gutter); }
  .cfg-selection { padding: 20px 18px; }
}

/* ============================================
   ZONE SUMMARY (dans le bloc preview, à gauche du visualiseur)
   ============================================ */
.cfg-zone-summary {
  margin-top: 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cfg-zsum {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--ligne);
  border-left: 3px solid var(--turquoise);
  border-radius: 4px;
  transition: border-color .3s;
}
.cfg-zsum[data-zone="murs"] { border-left-color: var(--or); }
.cfg-zsum .zs-ico {
  width: 38px;
  height: 38px;
  background: rgba(14, 124, 123, 0.08);
  color: var(--turquoise);
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 18px;
  flex-shrink: 0;
}
.cfg-zsum[data-zone="murs"] .zs-ico {
  background: rgba(201, 168, 76, 0.1);
  color: var(--or);
}
.cfg-zsum .zs-info { flex: 1; min-width: 0; }
.cfg-zsum .zs-lbl {
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--texte-mute);
  font-weight: 600;
  margin-bottom: 2px;
}
.cfg-zsum .zs-ref {
  font-size: 14px;
  font-weight: 500;
  color: var(--texte);
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cfg-zsum .zs-ref.filled { color: var(--texte); }
.cfg-zsum .zs-meta {
  font-size: 11px;
  color: var(--texte-mute);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ============================================
   ZONE PICKER (étape 1 : Sol / Murs)
   ============================================ */
.cfg-zone-picker {
  background: #fff;
  padding: 30px var(--gutter);
  border-top: 1px solid var(--ligne);
  border-bottom: 1px solid var(--ligne);
}
.cfg-zone-picker-inner {
  max-width: var(--max);
  margin: 0 auto;
}
.cfg-zp-head {
  text-align: center;
  margin-bottom: 18px;
}
.cfg-zp-head .eyebrow { color: var(--turquoise); justify-content: center; }
.cfg-zp-head .eyebrow::before { background: var(--turquoise); }
.cfg-zp-head p {
  font-size: 13px;
  color: var(--texte-mute);
  margin-top: 10px;
}

.cfg-zone-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  max-width: 800px;
  margin: 0 auto;
}
.cfg-zone-tab {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  background: #fff;
  border: 2px solid var(--ligne);
  border-radius: 8px;
  cursor: pointer;
  transition: all .3s var(--ease-out);
  text-align: left;
  position: relative;
}
.cfg-zone-tab:hover {
  border-color: var(--turquoise);
  transform: translateY(-2px);
  box-shadow: 0 12px 30px -16px rgba(14, 124, 123, 0.35);
}
.cfg-zone-tab.active {
  border-color: var(--turquoise);
  background: linear-gradient(180deg, rgba(14, 124, 123, 0.04) 0%, #fff 100%);
  box-shadow: 0 0 0 1px var(--turquoise), 0 14px 32px -14px rgba(14, 124, 123, 0.4);
}
.cfg-zone-tab[data-zone="murs"].active {
  border-color: var(--or);
  background: linear-gradient(180deg, rgba(201, 168, 76, 0.04) 0%, #fff 100%);
  box-shadow: 0 0 0 1px var(--or), 0 14px 32px -14px rgba(201, 168, 76, 0.4);
}
.cfg-zone-tab .zt-ico {
  width: 50px;
  height: 50px;
  background: rgba(14, 124, 123, 0.08);
  color: var(--turquoise);
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-size: 22px;
  flex-shrink: 0;
  transition: all .3s;
}
.cfg-zone-tab[data-zone="murs"] .zt-ico {
  background: rgba(201, 168, 76, 0.1);
  color: var(--or);
}
.cfg-zone-tab.active .zt-ico {
  transform: scale(1.05);
}
.cfg-zone-tab .zt-text { flex: 1; min-width: 0; }
.cfg-zone-tab .zt-lbl {
  display: block;
  font-size: 17px;
  font-weight: 500;
  color: var(--texte);
  margin-bottom: 2px;
}
.cfg-zone-tab .zt-help {
  display: block;
  font-size: 12px;
  color: var(--texte-mute);
}
.cfg-zone-tab .zt-status {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--texte-mute);
  background: rgba(0,0,0,0.04);
  padding: 5px 10px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}
.cfg-zone-tab .zt-status.done {
  color: #1a7a30;
  background: rgba(26, 122, 48, 0.1);
}

/* ============================================
   CATALOG HEAD (étape 2)
   ============================================ */
.cfg-cat-head {
  max-width: var(--max);
  margin: 0 auto 30px;
  text-align: center;
}
.cfg-cat-head .eyebrow { color: var(--turquoise); justify-content: center; }
.cfg-cat-head .eyebrow::before { background: var(--turquoise); }
.cfg-cat-head p {
  font-size: 13px;
  color: var(--texte-mute);
  margin-top: 10px;
}
.cfg-cat-head p strong {
  color: var(--turquoise);
  font-weight: 600;
}

/* Tile that's selected for the OTHER zone — subtle hint */
.cfg-tile.in-other {
  position: relative;
}
.cfg-tile.in-other::before {
  content: '↳ utilisé sur l\'autre zone';
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 10px;
  letter-spacing: 0.06em;
  background: rgba(10, 42, 42, 0.85);
  color: var(--or);
  padding: 4px 8px;
  border-radius: 999px;
  z-index: 3;
  backdrop-filter: blur(8px);
}

/* ============================================
   STICKY PANEL (2 zones)
   ============================================ */
.cfg-panel-zones {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-right: 16px;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.cp-zone {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(255,255,255,0.7);
}
.cp-zone .cp-ico {
  width: 26px;
  height: 26px;
  background: rgba(14, 124, 123, 0.2);
  color: var(--turquoise);
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 14px;
}
.cp-zone[data-zone="murs"] .cp-ico {
  background: rgba(201, 168, 76, 0.2);
  color: var(--or);
}
.cp-zone .cp-lbl {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
}
.cp-zone .cp-ref {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,0.5);
  font-family: 'Sora', monospace;
}
.cp-zone .cp-ref.filled { color: #fff; }

/* ============================================
   ZONE SLOTS (devis section)
   ============================================ */
.cfg-zone-slots {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.cfg-zone-slot {
  background: rgba(14, 124, 123, 0.06);
  border: 1px solid rgba(255,255,255,0.06);
  border-left: 3px solid var(--turquoise);
  border-radius: 4px;
  padding: 16px;
}
.cfg-zone-slot[data-zone="murs"] {
  background: rgba(201, 168, 76, 0.06);
  border-left-color: var(--or);
}
.cfg-zone-slot .zs-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.cfg-zone-slot .zs-header .zs-ico {
  width: 28px;
  height: 28px;
  background: rgba(14, 124, 123, 0.25);
  color: var(--turquoise);
  border-radius: 5px;
  display: grid;
  place-items: center;
  font-size: 14px;
}
.cfg-zone-slot[data-zone="murs"] .zs-header .zs-ico {
  background: rgba(201, 168, 76, 0.25);
  color: var(--or);
}
.cfg-zone-slot .zs-header .zs-zone {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fff;
  font-weight: 500;
}
.cfg-zone-slot .zs-empty {
  text-align: center;
  padding: 20px 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  line-height: 1.7;
}
.cfg-zone-slot .zs-empty span {
  display: block;
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  margin-top: 6px;
}
.cfg-zone-slot .zs-tile {
  display: flex;
  align-items: center;
  gap: 14px;
}
.cfg-zone-slot .zs-img {
  width: 56px;
  height: 56px;
  background-size: cover;
  background-position: center;
  border-radius: 4px;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.cfg-zone-slot .zs-tile-info { flex: 1; min-width: 0; }
.cfg-zone-slot .zs-tile-ref {
  font-size: 10px;
  color: var(--or);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 2px;
}
.cfg-zone-slot .zs-tile-name {
  font-size: 14px;
  color: #fff;
  font-weight: 500;
  margin-bottom: 2px;
}
.cfg-zone-slot .zs-tile-meta {
  font-size: 11px;
  color: rgba(255,255,255,0.6);
}
.cfg-zone-slot .zs-x {
  background: rgba(255,255,255,0.06);
  border: none;
  color: rgba(255,255,255,0.6);
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 16px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all .2s;
}
.cfg-zone-slot .zs-x:hover { background: #d63a3a; color: #fff; }

/* Mobile */
@media (max-width: 768px) {
  .cfg-zone-tabs { grid-template-columns: 1fr; }
  .cfg-zone-tab { padding: 14px 16px; gap: 12px; }
  .cfg-zone-tab .zt-ico { width: 42px; height: 42px; font-size: 18px; }
  .cfg-zone-tab .zt-lbl { font-size: 15px; }
  .cfg-zone-tab .zt-help { font-size: 11px; }
  .cfg-zone-slots { grid-template-columns: 1fr; }
  .cfg-panel-zones { gap: 10px; padding-right: 12px; }
  .cp-zone .cp-lbl { display: none; }
  .cp-zone { gap: 6px; }
}
