/* =========================================
= PAGE CONTACT — layout 2 colonnes (form gauche / photo droite)
   Desktop-first : base ≥ 64rem, bascule 1 colonne en mobile via max-width.
========================================= */

/* Section pleine largeur viewport (sort du .container) */
.nl-contact--bg {
  font-family: var(--SR);
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  min-height: calc(100vh - 2.5rem);
  padding: 4rem 2rem;
  background: var(--secondary-c);
  display: grid;
  place-items: center;
}

/* Grid 2 colonnes : form (gauche) / photo (droite) */
.nl-contact--grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  width: 100%;
  max-width: 72rem;
}

/* Carte « verre dépoli » — à gauche */
.nl-contact--card {
  width: 100%;
  margin: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 1px;
  padding: 2rem;
}

/* Media (photo) — à droite */
.nl-contact--media {
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 1px;
}
.nl-contact--media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.nl-contact--card h2 {
  margin: 0 0 1.25rem 0;
  font-family: var(--font-display);
  font-size: var(--text-xl);
  text-align: center;
  font-style: italic;
  font-weight: 500;
}

/* Formulaire : empilement régulier des champs */
.nl-contact--card .form {
  display: grid;
  gap: 0.875rem;
}
.nl-contact--card .button {
  width: 100%;
}

/* Champ message : même habillage que les inputs du thème */
.nl-contact--card textarea {
  width: 100%;
  min-height: 7rem;
  resize: vertical;
  padding: 0.5rem 0.625rem;
  border: 0.0625rem solid var(--accent);
  border-radius: 1px;
  background: var(--secondary);
  color: var(--primary);
  font: inherit;
}
.nl-contact--card textarea:focus {
  outline: none;
  border-color: var(--primary);
}

/* Zone de notice AJAX (succès / erreur) */
.nl-contact--notices:empty {
  display: none;
}
.nl-contact--notices .notice {
  margin: 0 0 0.875rem;
}

/* Honeypot anti-spam : invisible, hors flux, non focusable visuellement */
.nl-contact--hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Tablette : on conserve 2 colonnes mais avec un gap plus serré */
@media (max-width: 64rem) {
  .nl-contact--bg { padding: 3rem 1.5rem; }
  .nl-contact--grid { gap: 2rem; }
}

/* Mobile : bascule en 1 colonne, photo en premier (au-dessus du form) */
@media (max-width: 48rem) {
  .nl-contact--bg {
    padding: 2rem 1rem;
  }
  .nl-contact--grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .nl-contact--card {
    padding: 1.5rem;
  }
  .nl-contact--media {
    aspect-ratio: 16 / 9;
    order: -1; /* photo au-dessus du form sur mobile */
  }
}
