/* ==========================================================================
   MONEHPAD — Fiche Détail Établissement (Modèle fd__*)
   Respect strict de la charte Bleu & Blanc + Rose/Blush (monehpad-charte.css)
   Aucune couleur hors charte (zéro orange, zéro violet).
   ========================================================================== */

:root {
  --brand-ink: #FFFFFF;
  --brand-hover: var(--brand-deep, #12345F);
  --line-strong: var(--line, #D6E0EC);
  --radius-pill: var(--radius-full, 9999px);
  --success-bg: #E9F4EE;
  --shadow-soft: 0 1px 2px rgba(20, 35, 58, 0.05), 0 4px 12px rgba(20, 35, 58, 0.06);
  --shadow-pop: 0 10px 30px rgba(20, 35, 58, 0.16);
  --focus-ring: 0 0 0 3px rgba(91, 155, 213, 0.35);
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

#details-modal.modal-overlay {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

#details-modal.modal-overlay.active {
  display: flex !important;
}

#details-modal .modal-window {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.fd,
.fd *,
.fd *::before,
.fd *::after {
  box-sizing: border-box;
}

.fd {
  font-family: var(--font-texte);
  color: var(--ink);
  background: var(--surface);
  height: 100%;
  min-height: 0;
  max-height: 100%;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-bottom: 0;
}

.fd__scroll-area {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding-bottom: 48px;
}

/* ── Barre supérieure (Navigation retour / fermer) ── */
.fd__topbar {
  position: relative;
  flex-shrink: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 14px clamp(16px, 4vw, 40px);
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--line);
}

.fd__back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background: var(--surface-raised);
  color: var(--brand);
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-md);
  font-family: var(--font-texte);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.12s ease;
}

.fd__back:hover {
  background: var(--mist);
  border-color: var(--brand);
}

.fd__topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.fd__finess-pill {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-muted);
  background: var(--mist);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
}

.fd__close {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px solid var(--line-strong);
  background: var(--surface-raised);
  color: var(--ink);
  font-size: 1.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.fd__close:hover {
  background: var(--brand);
  color: var(--brand-ink);
  border-color: var(--brand);
}

/* ── Conteneur central ── */
.fd__container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 24px clamp(16px, 4vw, 40px) 0;
}

/* ── 1. PHOTOS EN PREMIER (.fd__photos / .fd__photo-main) ── */
.fd__photos {
  margin-bottom: 22px;
}

.fd__photo-main {
  position: relative;
  width: 100%;
  height: clamp(280px, 46vw, 480px);
  border-radius: 18px;
  overflow: hidden;
  background: var(--brand-deep);
  box-shadow: 0 6px 24px rgba(15, 39, 71, 0.08);
  border: 1px solid #D5E4F7;
}

.fd__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.fd__slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.fd__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fd__photo-gradient {
  position: absolute;
  inset: auto 0 0 0;
  height: 76px;
  background: linear-gradient(to top, rgba(15, 39, 71, 0.52) 0%, rgba(15, 39, 71, 0.16) 55%, transparent 100%);
  pointer-events: none;
  z-index: 2;
}

.fd__photo-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.90);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #0F2747;
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 4px 14px rgba(15, 39, 71, 0.18);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.fd__photo-arrow:hover {
  background: #0F2747;
  color: #FFFFFF;
  border-color: #0F2747;
  transform: translateY(-50%) scale(1.05);
  box-shadow: 0 6px 18px rgba(15, 39, 71, 0.26);
}

.fd__photo-arrow--prev {
  left: 16px;
}

.fd__photo-arrow--next {
  right: 16px;
}

.fd__photo-bar {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 12px;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.fd__photo-caption {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  color: #FFFFFF;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  background: rgba(15, 39, 71, 0.58);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-pill);
  max-width: 60%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fd__photo-bar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.fd__photo-360-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 14px;
  background: rgba(37, 99, 235, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: var(--radius-pill);
  font-family: var(--font-texte);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(15, 39, 71, 0.2);
  transition: background 0.18s ease, transform 0.15s ease, box-shadow 0.18s ease;
}

.fd__photo-360-btn:hover {
  background: #1D4ED8;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(15, 39, 71, 0.28);
}

.fd__photo-counter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 13px;
  color: #0F2747;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.65);
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  box-shadow: 0 2px 8px rgba(15, 39, 71, 0.12);
}

.fd__photo-counter i {
  color: #2563EB;
  font-size: 0.82rem;
}

.fd__photo-thumbs {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  overflow-x: auto;
  padding: 2px 2px 4px;
  -webkit-overflow-scrolling: touch;
}

.fd__thumb {
  width: 92px;
  height: 62px;
  border-radius: 10px;
  overflow: hidden;
  border: 1.5px solid #D5E4F7;
  padding: 0;
  background: var(--mist);
  cursor: pointer;
  flex-shrink: 0;
  opacity: 0.74;
  transition: opacity 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.15s ease;
}

.fd__thumb:hover {
  opacity: 0.96;
  border-color: #93C5FD;
  transform: translateY(-1px);
}

.fd__thumb.is-active {
  opacity: 1;
  border: 2px solid #2563EB;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15), 0 4px 10px rgba(15, 39, 71, 0.08);
}

.fd__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── 2. EN-TÊTE COMPACT (.fd__header) ── */
.fd__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding: 24px 28px;
  background: var(--surface-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  margin-bottom: 20px;
}

.fd__header-main {
  flex: 1 1 520px;
  min-width: 0;
}

.fd__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.fd__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 13px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 700;
  background: var(--mist);
  color: var(--brand);
  border: 1px solid var(--line);
}

.fd__badge--medical {
  background: var(--brand);
  color: var(--brand-ink);
  border-color: var(--brand);
}

.fd__badge--rose {
  background: var(--blush);
  color: var(--rose-ink);
  border-color: var(--rose);
}

.fd__badge--success {
  background: var(--success-bg);
  color: var(--success);
  border-color: #B7E4CE;
}

.fd__title {
  font-family: var(--font-titre);
  font-size: clamp(1.55rem, 2.6vw, 2.2rem);
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink);
  margin: 0 0 10px;
}

.fd__submeta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  color: var(--ink-muted);
  font-size: 1rem;
}

.fd__address {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--ink-muted);
  font-weight: 500;
}

.fd__address i {
  color: var(--brand);
}

.fd__rating {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: var(--blush);
  color: var(--rose-ink);
  border: 1px solid var(--rose);
  font-size: 0.9rem;
  font-weight: 700;
}

.fd__rating i {
  color: var(--rose-ink);
}

.fd__head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

/* Encadré Rappel Avis des familles à droite de l'en-tête (.fd__header-reviews) */
.fd__header-reviews {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 18px;
  padding: 18px 22px;
  background: linear-gradient(135deg, #14284b 0%, #1e3d70 100%);
  color: #FFFFFF;
  border-radius: 16px;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(20, 40, 75, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-sizing: border-box;
}

.fd__header-reviews:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(20, 40, 75, 0.26);
  color: #FFFFFF;
}

.fd__header-reviews--empty {
  grid-template-columns: 1fr;
}

.fd__hr-score {
  text-align: center;
  padding-right: 18px;
  border-right: 1px solid rgba(255, 255, 255, 0.18);
}

.fd__hr-value {
  font-family: var(--font-texte);
  font-size: 36px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  color: #FFFFFF;
}

.fd__hr-value small {
  font-size: 15px;
  opacity: 0.65;
  font-weight: 600;
}

.fd__hr-stars {
  display: flex;
  gap: 2.5px;
  justify-content: center;
  margin: 6px 0 4px;
}

.fd__hr-stars svg {
  width: 15px;
  height: 15px;
  fill: #f2b705;
}

.fd__hr-stars svg.half {
  fill: url(#half);
}

.fd__hr-stars svg.empty {
  fill: rgba(255, 255, 255, 0.3);
}

.fd__hr-count {
  font-size: 12.5px;
  opacity: 0.78;
  color: #FFFFFF;
}

.fd__hr-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.fd__hr-eyebrow {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.68;
  font-weight: 600;
  color: #FFFFFF;
}

.fd__hr-title {
  font-family: var(--font-titre);
  font-size: 19px;
  font-weight: 600;
  color: #FFFFFF;
  margin: 3px 0 6px;
  line-height: 1.2;
}

.fd__hr-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 600;
  color: #93C5FD;
}

.fd__header-reviews:hover .fd__hr-link {
  color: #DBEAFE;
}

.fd__action-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: var(--radius-md);
  font-family: var(--font-texte);
  font-size: 0.95rem;
  font-weight: 700;
  background: var(--surface-raised);
  color: var(--brand);
  border: 1.5px solid var(--line-strong);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.fd__action-btn:hover {
  background: var(--mist);
  border-color: var(--brand);
}

.fd__action-btn.is-active {
  background: var(--brand);
  color: var(--brand-ink);
  border-color: var(--brand);
}

/* ── 3. QUATRE CHIFFRES CLÉS (.fd__kpis) ── */
.fd__kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}

.fd__kpi {
  background: var(--surface-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.fd__kpi--highlight {
  background: var(--blush);
  border-color: var(--rose);
}

.fd__kpi-top {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
}

.fd__kpi-top i {
  color: var(--brand);
  font-size: 0.95rem;
}

.fd__kpi--highlight .fd__kpi-top,
.fd__kpi--highlight .fd__kpi-top i {
  color: var(--rose-ink);
}

.fd__kpi-value {
  font-family: var(--font-titre);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
  margin-top: 2px;
}

.fd__kpi--highlight .fd__kpi-value {
  color: var(--rose-ink);
}

.fd__kpi-sub {
  font-size: 0.85rem;
  color: var(--ink-muted);
}

/* ── 4. GRILLE PRINCIPALE : GAUCHE (Contenu) + DROITE (Aside) ── */
.fd__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 28px;
  align-items: start;
}

.fd__main {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

/* Sections de gauche */
.fd__section {
  background: var(--surface-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-soft);
}

.fd__section-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.fd__section-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--mist);
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.fd__section-icon--rose {
  background: var(--blush);
  color: var(--rose-ink);
}

.fd__section-title {
  font-family: var(--font-titre);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0;
}

.fd__text {
  color: var(--ink);
  font-size: 1.02rem;
  line-height: 1.7;
  margin: 0 0 20px;
}

.fd__identity-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.fd__identity-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.fd__identity-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
  margin-bottom: 3px;
}

.fd__identity-val {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--ink);
}

/* Tableau Tarifs & Aides */
.fd__table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.fd__table th,
.fd__table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  font-size: 0.98rem;
}

.fd__table tr:last-child td {
  border-bottom: none;
}

.fd__table tr:nth-child(even) {
  background: var(--surface);
}

.fd__table td:last-child {
  text-align: right;
  font-weight: 700;
  color: var(--brand);
  white-space: nowrap;
}

.fd__aides-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
  align-items: start;
}

.fd__aide-card {
  display: flex;
  flex-direction: column;
  padding: 13px 15px;
  border-radius: var(--radius-sm);
  background: var(--mist);
  border: 1.5px solid var(--line);
  font-size: 0.92rem;
  color: var(--ink);
  cursor: pointer;
  user-select: none;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.15s ease;
}

.fd__aide-card:hover {
  border-color: var(--brand);
  background: #E6F0FD;
  box-shadow: 0 4px 12px rgba(26, 75, 140, 0.09);
  transform: translateY(-1px);
}

.fd__aide-card.is-open {
  background: #FFFFFF;
  border-color: var(--brand);
  box-shadow: 0 6px 18px rgba(26, 75, 140, 0.12);
}

.fd__aide-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
}

.fd__aide-head-left {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  flex: 1;
  line-height: 1.45;
}

.fd__aide-head-left > i {
  color: var(--brand);
  margin-top: 3px;
  flex-shrink: 0;
  font-size: 1rem;
}

.fd__aide-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--brand);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line-strong);
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 1px;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.fd__aide-card:hover .fd__aide-toggle {
  background: var(--brand);
  color: #FFFFFF;
  border-color: var(--brand);
}

.fd__aide-card.is-open .fd__aide-toggle {
  background: var(--mist);
  color: var(--brand);
  border-color: var(--brand);
}

.fd__aide-toggle i {
  font-size: 0.7rem;
  transition: transform 0.22s ease;
}

.fd__aide-card.is-open .fd__aide-toggle i {
  transform: rotate(180deg);
}

.fd__aide-details {
  display: none;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--line-strong);
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--ink);
  cursor: default;
  user-select: text;
}

.fd__aide-card.is-open .fd__aide-details {
  display: block;
  animation: fdAideFadeIn 0.2s ease;
}

.fd__aide-details ul {
  margin: 0;
  padding-left: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fd__aide-details li strong {
  color: var(--brand-deep, #0F2747);
}

@keyframes fdAideFadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.fd__simu-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 16px 20px;
  background: var(--blush);
  border: 1px solid var(--rose);
  border-radius: var(--radius-md);
}

.fd__simu-text {
  font-size: 0.95rem;
  color: var(--ink);
  font-weight: 500;
}

.fd__simu-text strong {
  color: var(--rose-ink);
  display: block;
  font-size: 1rem;
}

.fd__simu-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: var(--brand);
  color: var(--brand-ink);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-texte);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.fd__simu-btn:hover {
  background: var(--brand-hover);
}

/* Listes Soins & Cadre de vie */
.fd__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.fd__list-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.fd__list-item i {
  color: var(--brand);
  font-size: 1rem;
  flex-shrink: 0;
}

/* ── COLONNE DE DROITE (.fd__aside) — Scrolle en 1 seul bloc avec la colonne de gauche ── */
.fd__aside {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: static !important;
  top: auto !important;
}

.fd__card {
  background: var(--surface-raised);
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
}

.fd__price-box {
  background: linear-gradient(135deg, #EFF6FF 0%, #F8FAFC 100%);
  border: 1.5px solid #BFDBFE;
  border-radius: var(--radius-md);
  padding: 16px 18px;
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fd__price-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.fd__price-label {
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #1E40AF;
}

.fd__price-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #15803D;
  background: #DCFCE7;
  border: 1px solid #BBF7D0;
  padding: 3px 9px;
  border-radius: 999px;
}

.fd__price-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.fd__price-val {
  font-family: var(--font-titre);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--brand);
  line-height: 1.15;
}

.fd__price-val small {
  font-family: var(--font-texte);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.fd__price-month {
  font-size: 0.88rem;
  color: #475569;
  font-weight: 600;
}

.fd__price-month strong {
  color: #0F172A;
  font-weight: 700;
}

/* Formulaire .fd__form */
.fd__form-title {
  font-family: var(--font-titre);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 6px;
}

.fd__form-sub {
  font-size: 0.9rem;
  color: var(--ink-muted);
  margin: 0 0 16px;
}

.fd__form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fd__field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 4px;
}

.fd__field input,
.fd__field select,
.fd__field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  color: var(--ink);
  font-family: var(--font-texte);
  font-size: 0.95rem;
}

.fd__field input:focus,
.fd__field select:focus,
.fd__field textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: var(--focus-ring);
}

.fd__submit {
  width: 100%;
  padding: 14px 20px;
  background: var(--brand);
  color: var(--brand-ink);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-texte);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 4px;
  transition: background 0.15s ease;
}

.fd__submit:hover {
  background: var(--brand-hover);
}

.fd__phone-box {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  text-align: center;
}

.fd__phone-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-muted);
  margin-bottom: 8px;
}

.fd__phone-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1.5px solid var(--brand);
  color: var(--brand);
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.fd__phone-link:hover {
  background: var(--mist);
}

/* Ligne simple « Vous gérez cet établissement ? Mettre à jour la fiche » */
.fd__owner {
  padding: 14px 18px;
  background: var(--surface-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  color: var(--ink-muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.fd__owner a {
  color: var(--brand);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.fd__owner a:hover {
  color: var(--brand-deep);
}

/* ── 6. PUB PARTENAIRE (#ad-slot & Plein Écran 100% de la page) ── */
#ad-slot:empty {
  display: none;
}

.ad-partner {
  background: var(--surface-raised);
  border: 1px solid var(--rose);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.ad-partner:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.ad-partner__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: var(--blush);
  border-bottom: 1px solid var(--rose);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--rose-ink);
}

.ad-partner__media {
  width: 100%;
  height: 170px;
  overflow: hidden;
  background: var(--mist);
  position: relative;
}

.ad-partner__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ad-partner__zoom {
  position: absolute;
  right: 10px;
  bottom: 10px;
  background: rgba(13, 39, 68, 0.85);
  color: #FFFFFF;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.ad-partner__body {
  padding: 14px 16px;
}

.ad-partner__name {
  font-family: var(--font-titre);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 4px;
}

.ad-partner__tagline {
  font-size: 0.88rem;
  color: var(--ink-muted);
  margin: 0 0 12px;
  line-height: 1.45;
}

.ad-partner__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.ad-partner__site-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand);
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ad-partner__visit-hint {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--rose-ink);
}

.ad-partner__edit-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: var(--mist);
  border: 1px solid var(--line-strong);
  color: var(--brand);
  font-family: var(--font-texte);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.ad-partner__edit-trigger:hover {
  background: var(--brand);
  color: var(--brand-ink);
  border-color: var(--brand);
}

/* ── PUB PARTENAIRE AGRANDIE : PREND TOUTE LA PAGE DU SITE (100vw x 100vh) ── */
.ad-lightbox {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 25000;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  padding: 0;
  margin: 0;
}

.ad-lightbox[hidden] {
  display: none !important;
}

.ad-lightbox__dialog {
  position: relative;
  width: 100vw;
  height: 100vh;
  max-width: 100vw;
  max-height: 100vh;
  background: var(--surface-raised);
  border-radius: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Barre supérieure pleine page */
.ad-lightbox__topbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px clamp(16px, 3vw, 36px);
  background: var(--surface-raised);
  border-bottom: 1px solid var(--line);
  z-index: 5;
  flex-wrap: wrap;
}

.ad-lightbox__topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  min-width: 0;
}

.ad-lightbox__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: var(--blush);
  color: var(--rose-ink);
  border: 1px solid var(--rose);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ad-lightbox__top-title {
  font-family: var(--font-titre);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--ink);
}

.ad-lightbox__topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.ad-lightbox__edit-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--brand);
  background: var(--mist);
  color: var(--brand);
  font-family: var(--font-texte);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.ad-lightbox__edit-btn:hover,
.ad-lightbox__edit-btn.is-active {
  background: var(--brand);
  color: var(--brand-ink);
}

.ad-lightbox__edit-btn--secondary {
  background: var(--surface-raised);
  border-color: var(--line-strong);
  color: var(--ink);
}

.ad-lightbox__top-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  background: var(--brand);
  color: var(--brand-ink);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.15s ease;
}

.ad-lightbox__top-cta:hover {
  background: var(--brand-hover);
  color: var(--brand-ink);
}

.ad-lightbox__close {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--line-strong);
  background: var(--surface-raised);
  color: var(--ink);
  font-family: var(--font-texte);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.ad-lightbox__close:hover {
  background: var(--brand-deep);
  color: #FFFFFF;
  border-color: var(--brand-deep);
}

/* Corps central pleine page */
.ad-lightbox__body {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  display: flex;
  position: relative;
  overflow: hidden;
  background: #0D1F38;
}

.ad-lightbox__stage {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ad-lightbox__bg {
  position: absolute;
  inset: -24px;
  background-size: cover;
  background-position: center;
  filter: blur(28px) brightness(0.45);
  transform: scale(1.08);
  pointer-events: none;
}

.ad-lightbox__stage-link {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  text-decoration: none;
}

.ad-lightbox__img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* Panneau latéral d'édition (Upload visuel + Lien annonceur) */
.ad-lightbox__editor {
  width: 420px;
  max-width: 100vw;
  height: 100%;
  background: var(--surface-raised);
  border-left: 1px solid var(--line);
  padding: 24px;
  overflow-y: auto;
  z-index: 6;
  box-shadow: -12px 0 36px rgba(13, 39, 68, 0.22);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.ad-lightbox__editor[hidden] {
  display: none !important;
}

.ad-lightbox__editor-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.ad-lightbox__editor-head h4 {
  font-family: var(--font-titre);
  font-size: 1.15rem;
  color: var(--ink);
  margin: 0 0 4px;
}

.ad-lightbox__editor-head p {
  font-size: 0.85rem;
  color: var(--ink-muted);
  margin: 0;
}

.ad-lightbox__editor-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 1.2rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ad-lightbox__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ad-lightbox__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ad-lightbox__field label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--ink);
}

.ad-lightbox__dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 6px;
  padding: 20px 16px;
  border: 2px dashed var(--brand);
  border-radius: var(--radius-md);
  background: var(--mist);
  color: var(--brand);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.ad-lightbox__dropzone:hover {
  background: #DCE8F7;
  border-color: var(--brand-deep);
}

.ad-lightbox__dropzone i {
  font-size: 1.65rem;
}

.ad-lightbox__dropzone span {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink);
}

.ad-lightbox__dropzone small {
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.ad-lightbox__dropzone input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.ad-lightbox__input-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.ad-lightbox__input-icon i {
  position: absolute;
  left: 13px;
  color: var(--brand);
  pointer-events: none;
}

.ad-lightbox__input-icon input {
  padding-left: 38px !important;
}

.ad-lightbox__field input[type="text"],
.ad-lightbox__field input[type="url"],
.ad-lightbox__field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-texte);
  font-size: 0.95rem;
}

.ad-lightbox__field input:focus,
.ad-lightbox__field textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: var(--focus-ring);
}

.ad-lightbox__hint {
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.ad-lightbox__status {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
}

.ad-lightbox__status--success {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid #B7E4CE;
}

.ad-lightbox__status--error {
  background: var(--blush);
  color: var(--rose-ink);
  border: 1px solid var(--rose);
}

.ad-lightbox__save-btn {
  width: 100%;
  padding: 14px 18px;
  border: 0;
  border-radius: var(--radius-md);
  background: var(--brand);
  color: var(--brand-ink);
  font-family: var(--font-texte);
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.15s ease;
}

.ad-lightbox__save-btn:hover {
  background: var(--brand-hover);
}

/* Barre inférieure pleine page */
.ad-lightbox__footer {
  flex: 0 0 auto;
  padding: 18px clamp(16px, 3vw, 36px);
  background: var(--surface-raised);
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  z-index: 5;
}

.ad-lightbox__footer-info {
  flex: 1 1 360px;
  min-width: 0;
}

.ad-lightbox__title {
  font-family: var(--font-titre);
  font-size: 1.35rem;
  color: var(--ink);
  margin: 0 0 4px;
}

.ad-lightbox__desc {
  font-size: 0.95rem;
  color: var(--ink-muted);
  margin: 0;
}

.ad-lightbox__footer-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.ad-lightbox__cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  background: var(--brand);
  color: var(--brand-ink);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
  transition: background 0.15s ease, transform 0.12s ease;
}

.ad-lightbox__cta:hover {
  background: var(--brand-hover);
  color: var(--brand-ink);
  transform: translateY(-1px);
}

/* ── RESPONSIVE (Tablette & Mobile 375px) ── */
@media (max-width: 980px) {
  .fd__layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .fd__aside {
    position: static;
    min-width: 0;
  }

  .fd__kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fd__header-reviews {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 600px) {
  .fd__topbar {
    padding: 10px 14px;
  }

  .fd__finess-pill {
    display: none;
  }

  .fd__container {
    padding: 12px 12px 0;
  }

  .fd__photo-main {
    height: 240px;
    border-radius: 14px;
  }

  .fd__photo-gradient {
    height: 68px;
  }

  .fd__photo-arrow {
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
  }

  .fd__photo-arrow--prev {
    left: 10px;
  }

  .fd__photo-arrow--next {
    right: 10px;
  }

  .fd__photo-bar {
    left: 10px;
    right: 10px;
    bottom: 10px;
    gap: 6px;
    justify-content: flex-end;
  }

  .fd__photo-caption {
    display: none;
  }

  .fd__photo-bar-actions {
    width: 100%;
    justify-content: space-between;
    gap: 6px;
  }

  .fd__photo-360-btn,
  .fd__photo-counter {
    min-height: 30px;
    font-size: 0.75rem;
    padding: 0 10px;
  }

  .fd__thumb {
    width: 78px;
    height: 54px;
    border-radius: 8px;
  }

  .fd__header {
    padding: 16px 14px;
    gap: 14px;
  }

  .fd__header-main {
    flex: 1 1 100%;
    min-width: 0;
  }

  .fd__badges {
    gap: 6px;
  }

  .fd__badge {
    font-size: 0.78rem;
    padding: 4px 10px;
    max-width: 100%;
    box-sizing: border-box;
  }

  .fd__title {
    font-size: 1.38rem;
    overflow-wrap: break-word;
  }

  .fd__head-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
  }

  .fd__action-btn {
    width: 100%;
    min-width: 0;
    padding: 10px 8px;
    font-size: 0.82rem;
    justify-content: center;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-sizing: border-box;
  }

  .fd__kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .fd__kpi {
    padding: 12px;
    min-width: 0;
    box-sizing: border-box;
    overflow: hidden;
  }

  .fd__kpi-top {
    font-size: 0.72rem;
    gap: 5px;
    letter-spacing: 0.02em;
  }

  .fd__kpi-value {
    font-size: 0.98rem;
    line-height: 1.22;
    overflow-wrap: break-word;
  }

  .fd__kpi-sub {
    font-size: 0.77rem;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: break-word;
  }

  .fd__section,
  .fd__card {
    padding: 16px 14px;
    min-width: 0;
    box-sizing: border-box;
  }

  .fd__table th,
  .fd__table td {
    padding: 10px 10px;
    font-size: 0.84rem;
  }

  .fd__table td:last-child {
    white-space: normal;
  }

  .fd__table td:last-child small {
    display: block;
    margin-top: 2px;
  }

  .fd__simu-btn {
    width: 100%;
    justify-content: center;
  }

  .fd__identity-grid,
  .fd__aides-grid,
  .fd__list {
    grid-template-columns: minmax(0, 1fr);
  }

  .fd__identity-val {
    overflow-wrap: anywhere;
  }

  .ad-lightbox__topbar {
    padding: 10px 12px;
    gap: 8px;
  }

  .ad-lightbox__top-title {
    display: none;
  }

  .ad-lightbox__edit-btn,
  .ad-lightbox__top-cta,
  .ad-lightbox__close {
    padding: 8px 12px;
    font-size: 0.82rem;
  }

  .ad-lightbox__editor {
    position: absolute;
    inset: 0;
    width: 100%;
    border-left: 0;
  }

  .ad-lightbox__footer {
    padding: 12px 14px;
    gap: 10px;
  }

  .ad-lightbox__title {
    font-size: 1.1rem;
  }

  .ad-lightbox__footer-actions,
  .ad-lightbox__cta {
    width: 100%;
    justify-content: center;
  }
}
