/* =========================================================
   SUD Automatisme – Page d'attente
   ========================================================= */

/* Polices hébergées localement (pas d'appel à Google Fonts) */
@font-face {
  font-family: "Poppins";
  src: url("../fonts/Poppins-Light.ttf") format("truetype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Poppins";
  src: url("../fonts/Poppins-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Poppins";
  src: url("../fonts/Poppins-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Poppins";
  src: url("../fonts/Poppins-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --orange: #faaa1e;
  --sombre: #0e1014;
  --blanc: #ffffff;
  --gris-clair: #e1e4e8;
  --gris: #b4b9bf;
  --police: "Poppins", "Segoe UI", Roboto, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: var(--police);
  color: var(--blanc);
  background: var(--sombre);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---------- Fond photo + voile sombre ---------- */
.fond {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(180deg,
      rgba(14, 16, 20, .93) 0%,
      rgba(14, 16, 20, .62) 40%,
      rgba(14, 16, 20, .58) 68%,
      rgba(14, 16, 20, .95) 100%),
    url("../images/fond-portail.jpg");
  background-size: cover;
  background-position: 60% center;
  filter: saturate(.8);
  transform: scale(1.06);
  animation: zoom 20s ease-out forwards;
}

@keyframes zoom {
  to { transform: scale(1); }
}

/* ---------- Mise en page ---------- */
.page {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(1.8rem, 5vh, 3.5rem) 1.5rem clamp(1.2rem, 3vh, 2rem);
  text-align: center;
}

.logo {
  display: block;
  width: clamp(200px, 28vw, 340px);
  height: auto;
}

.contenu {
  max-width: 820px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.surtitre {
  color: var(--orange);
  font-weight: 500;
  font-size: clamp(.78rem, 1.6vw, 1.05rem);
  letter-spacing: .3em;
  text-transform: uppercase;
}

.filet {
  display: block;
  width: 80px;
  height: 3px;
  margin: 1.1rem auto 1.6rem;
  background: var(--orange);
}

.titre {
  font-size: clamp(2.1rem, 6vw, 4.2rem);
  line-height: 1.15;
  letter-spacing: -.01em;
}

.titre strong {
  display: block;
  font-weight: 700;
}

.titre span {
  display: block;
  font-weight: 300;
}

.texte {
  margin-top: 1.8rem;
  max-width: 640px;
  color: var(--gris-clair);
  font-weight: 300;
  font-size: clamp(1rem, 1.7vw, 1.2rem);
  line-height: 1.65;
}

/* Bloc téléphone */
.contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 2.2rem;
}

.contact-texte {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  font-weight: 400;
}

.telephone {
  display: inline-flex;
  align-items: center;
  gap: .9rem;
  margin-top: 1rem;
  padding: .8rem 2.4rem .8rem 2rem;
  border-radius: 999px;
  background: var(--orange);
  color: var(--sombre);
  font-weight: 700;
  font-size: clamp(1.7rem, 3.6vw, 2.5rem);
  letter-spacing: .01em;
  line-height: 1.2;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: 0 10px 30px rgba(250, 170, 30, .25);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
  -webkit-tap-highlight-color: transparent;
}

.telephone:hover,
.telephone:focus-visible {
  transform: translateY(-2px);
  background: #ffb935;
  box-shadow: 0 14px 36px rgba(250, 170, 30, .4);
}

.telephone:focus-visible {
  outline: 3px solid var(--blanc);
  outline-offset: 4px;
}

.telephone:active {
  transform: scale(.97);
}

.telephone-icone {
  width: .85em;
  height: .85em;
  flex-shrink: 0;
  fill: currentColor;
}

/* Le petit texte d'aide n'apparaît que sur écran tactile */
.contact-aide {
  display: none;
  margin-top: .7rem;
  color: var(--gris);
  font-size: .85rem;
  font-weight: 300;
}

@media (hover: none) and (pointer: coarse) {
  .contact-aide {
    display: block;
  }
}

/* ---------- Pied de page ---------- */
.pied {
  width: min(960px, 100%);
  padding-top: 1.8rem;
  border-top: 1px solid rgba(255, 255, 255, .25);
}

.services {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  list-style: none;
  font-weight: 500;
  font-size: clamp(.95rem, 1.6vw, 1.15rem);
  letter-spacing: .06em;
  text-transform: uppercase;
}

.services li + li::before {
  content: "•";
  margin: 0 1.1rem;
  color: var(--orange);
}

.mention {
  margin-top: .6rem;
  color: var(--gris);
  font-weight: 300;
  font-size: .92rem;
}

.copyright {
  margin-top: .9rem;
  color: rgba(255, 255, 255, .45);
  font-size: .78rem;
}

/* ---------- Apparition progressive ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .8s ease, transform .8s ease;
}

.js .reveal.visible {
  opacity: 1;
  transform: none;
}

/* ---------- Mobile ---------- */
@media (max-width: 600px) {
  .page {
    gap: 2rem;
  }

  .telephone {
    padding: .75rem 1.8rem .75rem 1.5rem;
  }

  .filet {
    width: 60px;
    margin: .9rem auto 1.3rem;
  }

  .services li + li::before {
    margin: 0 .6rem;
  }
}

/* Très petits téléphones */
@media (max-width: 360px) {
  .titre {
    font-size: 1.85rem;
  }

  .surtitre {
    letter-spacing: .2em;
  }

  .services {
    font-size: .85rem;
  }

  .services li + li::before {
    margin: 0 .4rem;
  }

  .telephone {
    font-size: 1.5rem;
    padding: .7rem 1.4rem .7rem 1.2rem;
  }
}

/* Écrans très bas (mobile en paysage) */
@media (max-height: 520px) and (orientation: landscape) {
  .page {
    justify-content: flex-start;
    gap: 1.5rem;
  }

  .logo {
    width: 180px;
  }
}

/* Respect des préférences d'accessibilité */
@media (prefers-reduced-motion: reduce) {
  .fond {
    animation: none;
  }

  .fond {
    transform: none;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

.nowrap {
  white-space: nowrap;
}
