/* Vue d'Ici : contraste du titre et de l'adresse sur la photo d'accueil. */
.vdi-photo-legible-text {
  color: #1d3024 !important;
  background: rgba(247, 244, 238, 0.96) !important;
  box-shadow: 0 0 0 0.18em rgba(247, 244, 238, 0.96);
  border-radius: 0.08em;
  text-shadow: none !important;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.vdi-photo-legible-text * {
  color: #1d3024 !important;
  text-shadow: none !important;
}

/* Navigation sous les deux galeries : uniquement sur telephone. */
.vdi-gallery-nav { display: none; }

@media (max-width: 767px) {
  .vdi-gallery-scroll-track {
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }
  .vdi-gallery-scroll-track::-webkit-scrollbar { display: none; }

  /* Force le defilement horizontal seulement si la galerie ne defile pas deja. */
  .vdi-gallery-scroll-track.vdi-gallery-force-scroll {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    grid-template-columns: none !important;
    gap: 12px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    padding-bottom: 6px !important;
    max-width: 100% !important;
  }
  .vdi-gallery-scroll-track.vdi-gallery-force-scroll > .vdi-gallery-scroll-card {
    flex: 0 0 min(82vw, 385px) !important;
    width: min(82vw, 385px) !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 !important;
    scroll-snap-align: start;
  }
  .vdi-gallery-force-scroll > .vdi-gallery-scroll-card img {
    max-width: 100%;
  }

  .vdi-gallery-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 13px;
    margin-bottom: 8px;
    width: 100%;
    grid-column: 1 / -1;
  }
  .vdi-gallery-nav-label {
    color: #4f5f4b;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.35;
    letter-spacing: 0.01em;
  }
  .vdi-gallery-nav-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
  }
  .vdi-gallery-arrow {
    width: 52px;
    height: 52px;
    padding: 0;
    border: 2px solid #274032;
    border-radius: 50%;
    background: #274032;
    color: #ffffff;
    font: normal 36px/1 Georgia, serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 18px rgba(39, 64, 50, 0.18);
    transition: background-color 160ms ease, opacity 160ms ease, transform 160ms ease;
    -webkit-tap-highlight-color: transparent;
  }
  .vdi-gallery-arrow:active {
    background: #1d3024;
    transform: scale(0.97);
  }
  .vdi-gallery-arrow:focus-visible {
    outline: 2px solid #274032;
    outline-offset: 3px;
  }
  .vdi-gallery-arrow:disabled {
    opacity: 0.45;
    background: #dbe2d6;
    border-color: #c7d0c0;
    color: #6f7d6c;
    cursor: default;
    box-shadow: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .vdi-gallery-scroll-track { scroll-behavior: auto !important; }
  .vdi-gallery-arrow { transition: none; }
}

@media (max-width: 767px) {
  .vdi-gallery-nav-buttons::before {
    content: '←';
    color: #6a7765;
    font-size: 18px;
    margin-right: 2px;
    display: none;
  }
}
