/* Supercopter en ligne : couleurs de la page du simulateur (web/style.css, règles
   R105 et R208), sans police ni fichier extérieurs. */
:root {
  --bleu: #5d97e0;
  --bleu-nuit: #1a375b;
  --bleu-clair: #e3edfb;
  --fond: #f5f7fa;
  --carte: #ffffff;
  --texte: #1b2230;
  --discret: #5d6878;
  --filet: #dde3ec;
  --erreur: #a3261f;
  --erreur-fond: #fbeceb;
  --police: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--fond);
  color: var(--texte);
  font: 15px/1.5 var(--police);
}

a { color: var(--bleu-nuit); }

.marque {
  margin: 0;
  color: var(--bleu);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.18em;
}

.carte {
  background: var(--carte);
  border: 1px solid var(--filet);
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(26, 55, 91, 0.06);
}

/* Page d'accueil d'authentification */
body.accueil {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.connexion {
  width: 100%;
  max-width: 400px;
  padding: 32px 28px 24px;
  border-top: 4px solid var(--bleu-nuit);
}

.connexion h1 {
  margin: 6px 0 4px;
  color: var(--bleu-nuit);
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

.sous-titre {
  margin: 0 0 22px;
  color: var(--discret);
}

form { display: flex; flex-direction: column; }

label {
  margin: 12px 0 6px;
  font-weight: 600;
  font-size: 14px;
}

input {
  padding: 10px 12px;
  border: 1px solid #b9c3d1;
  border-radius: 6px;
  background: #fff;
  color: var(--texte);
  font: 16px/1.3 var(--police);
}

input:focus-visible, button:focus-visible, a:focus-visible {
  outline: 3px solid var(--bleu);
  outline-offset: 2px;
}

button {
  margin-top: 22px;
  padding: 11px 16px;
  border: 0;
  border-radius: 6px;
  background: var(--bleu-nuit);
  color: #fff;
  font: 600 15px/1.2 var(--police);
  cursor: pointer;
}

button:hover { background: #24497a; }

button.secondaire {
  margin: 0;
  padding: 7px 12px;
  border: 1px solid var(--filet);
  background: #fff;
  color: var(--bleu-nuit);
}

button.secondaire:hover { background: var(--bleu-clair); }

.message {
  margin: 0 0 6px;
  padding: 10px 12px;
  border-radius: 6px;
  background: var(--bleu-clair);
  color: var(--bleu-nuit);
  font-size: 14px;
}

.message.erreur {
  background: var(--erreur-fond);
  color: var(--erreur);
}

.aide {
  margin: 20px 0 0;
  color: var(--discret);
  font-size: 13px;
}

.pied {
  margin-top: 18px;
  color: var(--discret);
  font-size: 12.5px;
  text-align: center;
}

/* Espace du conseiller */
.bandeau {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 24px;
  background: var(--bleu-nuit);
  color: #fff;
}

.bandeau .marque { color: #a9c6ee; }

.nom-outil {
  margin: 0;
  font-weight: 700;
  font-size: 20px;
}

.compte {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
}

.espace main {
  max-width: 960px;
  margin: 24px auto;
  padding: 0 16px;
  display: grid;
  /* Une colonne qui ne s'élargit pas au tableau : il défile dans sa carte. */
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
}

.espace .carte { padding: 20px 22px; min-width: 0; }

.espace h1, .espace h2 {
  margin: 0 0 12px;
  color: var(--bleu-nuit);
  font-size: 18px;
}

.annonce { border-left: 4px solid var(--bleu); }
.annonce p { margin: 0; }

.vide { margin: 0; color: var(--discret); }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th, td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--filet);
  text-align: left;
}

th {
  color: var(--bleu-nuit);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

@media (max-width: 560px) {
  .bandeau { flex-direction: column; align-items: flex-start; padding: 12px 16px; }
  table { display: block; overflow-x: auto; }
}

/* Hélicoptère de l'accueil (R425) : dessin original, noir à liseré blanc et
   mini-missiles ; arrivée par la gauche, vol stationnaire ; à la connexion, il se
   tourne vers le visiteur et tire, le missile l'atteint au changement de page ;
   immobile si le système demande moins d'animations. */
body.accueil { position: relative; padding-top: 150px; overflow-x: hidden; }
.helico-zone { position: absolute; top: 0; left: 0; right: 0; height: 150px; overflow: hidden; pointer-events: none; }
.helico {
  position: absolute; top: 22px; left: 50%; width: 300px; margin-left: -150px;
  animation: helico-arrivee 2.4s cubic-bezier(0.22, 0.9, 0.3, 1) both, helico-vol 3.2s ease-in-out 2.4s infinite;
}
.helico-dessin { display: block; width: 100%; height: auto; overflow: visible; }
/* Le demi-tour vers le visiteur : le profil se replie, la face se déplie. */
.vue-profil { transform-origin: 50% 50%; transition: transform 0.2s ease-in; }
.vue-face { position: absolute; top: 0; left: 50%; width: 63%; margin-left: -31.5%; transform: scaleX(0); transform-origin: 50% 50%; transition: transform 0.2s ease-out 0.2s; }
.helico.face .vue-profil { transform: scaleX(0); }
.helico.face .vue-face { transform: scaleX(1); }
.fuselage, .nacelle { fill: #121418; }
.mat, .rotor, .rotor-queue rect { fill: #0b0c0e; }
.lisere { fill: #f2f4f7; }
.verriere { fill: #34465c; }
.reflet { fill: none; stroke: #8fa6c2; stroke-width: 1.5; stroke-linecap: round; opacity: 0.7; }
.pylone { stroke: #0b0c0e; stroke-width: 2.5; }
.corps-missile { fill: #d9dde3; }
.ailette, .ailette-face { fill: #8a929d; stroke: #8a929d; stroke-width: 2; }
.flamme, .fumee { opacity: 0; }
.depart { fill: #ffd34d; opacity: 0; }
.helico.feu .missile-face.droite { opacity: 0; }
.helico.feu .depart { animation: helico-depart 0.25s ease-out forwards; }
.rotor { transform-box: fill-box; transform-origin: center; animation: helico-rotor 0.11s linear infinite alternate; }
.rotor-queue { transform-box: fill-box; transform-origin: center; animation: helico-queue 0.16s linear infinite; }
/* Le missile qui vient vers le visiteur : placé et animé par accueil.js. */
.missile-approche { position: fixed; top: 0; left: 0; width: 100px; height: 100px; margin: -50px 0 0 -50px; opacity: 0; pointer-events: none; z-index: 10; }
.missile-approche svg { display: block; width: 100%; height: 100%; }
.missile-approche .halo { fill: #ff9a2e; opacity: 0.55; }
.missile-approche .ogive { fill: #5d6878; }
.impact {
  position: fixed; inset: 0; opacity: 0; pointer-events: none; z-index: 11;
  background: radial-gradient(circle at 50% 50%, #ffffff 0%, #fff3c4 25%, #ffb347 55%, #e2571e 100%);
}
.impact.visible { opacity: 1; transition: opacity 0.12s ease-in; }
@keyframes helico-depart { 0% { opacity: 1; transform: scale(0.5); } 100% { opacity: 0; transform: scale(2.2); } }
@keyframes helico-arrivee {
  0% { transform: translateX(-110vw) rotate(-10deg); }
  75% { transform: translateX(14px) rotate(5deg); }
  100% { transform: translateX(0) rotate(0); }
}
@keyframes helico-vol { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes helico-rotor { from { transform: scaleX(1); } to { transform: scaleX(0.1); } }
@keyframes helico-queue { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .helico, .rotor, .rotor-queue { animation: none; } .vue-profil, .vue-face { transition: none; } }
@media (max-width: 560px) { .helico { width: 220px; margin-left: -110px; } }

/* Case « Se souvenir de mon identifiant et de mon mot de passe » (R425) */
label.case { display: flex; align-items: center; gap: 8px; margin: 16px 0 0; font-weight: 400; font-size: 14px; cursor: pointer; }
label.case input { width: 18px; height: 18px; margin: 0; accent-color: var(--bleu-nuit); }

/* Arrivée dans l'espace après l'impact (R425) : l'éclair s'efface. */
.impact-arrivee {
  display: none; position: fixed; inset: 0; pointer-events: none; z-index: 11;
  background: radial-gradient(circle at 50% 50%, #ffffff 0%, #fff3c4 25%, #ffb347 55%, #e2571e 100%);
}
html.avec-impact .impact-arrivee { display: block; animation: impact-efface 0.8s ease-out forwards; }
@keyframes impact-efface { 0% { opacity: 1; } 100% { opacity: 0; visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { html.avec-impact .impact-arrivee { display: none; } }
