/* Brunel B.T.P — styles complémentaires à Tailwind CSS (CDN) */

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
}

h1, h2, h3, .font-display {
  font-family: "Fraunces", ui-serif, Georgia, serif;
}

/* Sélection de texte */
::selection {
  background-color: #C1702F;
  color: #F7F4EF;
}

/* Focus clavier visible et cohérent avec la charte */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #C1702F;
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Lien avec soulignement animé au survol (nav, liens inline) */
.link-underline {
  position: relative;
  text-decoration: none;
}
.link-underline::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0%;
  height: 2px;
  background-color: #C1702F;
  transition: width 0.25s ease;
}
.link-underline:hover::after,
.link-underline:focus-visible::after,
.link-underline.is-active::after {
  width: 100%;
}

/* Overlay assombri sur les photos plein cadre pour garantir le contraste du texte */
.photo-overlay {
  background: linear-gradient(
    180deg,
    rgba(31, 37, 35, 0.55) 0%,
    rgba(31, 37, 35, 0.35) 45%,
    rgba(31, 37, 35, 0.8) 100%
  );
}

.photo-overlay-flat {
  background: rgba(31, 37, 35, 0.5);
}

/* Menu mobile */
#mobile-menu {
  transition: max-height 0.3s ease, opacity 0.25s ease;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
}
#mobile-menu.open {
  max-height: 32rem;
  opacity: 1;
}

/* Cartes de la galerie de réalisations */
.gallery-card {
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.gallery-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -20px rgba(31, 37, 35, 0.35);
}
.gallery-card img {
  transition: transform 0.6s ease;
}
.gallery-card:hover img {
  transform: scale(1.06);
}
.gallery-hidden {
  display: none;
}

/* Boutons filtre réalisations */
.filter-btn[aria-pressed="true"] {
  background-color: #C1702F;
  color: #F7F4EF;
  border-color: #C1702F;
}

/* Petites puces de communes desservies */
.zone-tag {
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* Message de confirmation formulaire */
.form-feedback {
  display: none;
}
.form-feedback.visible {
  display: block;
}
