/* Variables globales */
:root {
  color-scheme: dark;
  --bg: #0b1020;
  --bg-soft: #0e1730;
  --panel: #111b38;
  --panel-2: #0f1933;
  --line: rgba(122, 92, 255, .20);
  --line-strong: rgba(0, 194, 255, .35);
  --ink: #eaf7ff;
  --muted: rgba(234, 247, 255, .67);
  --muted-2: rgba(234, 247, 255, .45);
  --cyan: #00c2ff;
  --blue: #5ea8ff;
  --purple: #7a5cff;
  --danger: #ff7b92;
  --success: #79e6c7;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 24px 70px rgba(0, 0, 0, .25);
  --container: 1180px;
  --header-h: 76px;
  --font-body: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

/* Normalisation de base */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 18px);
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(
      circle at 85% 3%,
      rgba(0, 194, 255, .08),
      transparent 26rem
    ),
    radial-gradient(
      circle at 3% 42%,
      rgba(122, 92, 255, .08),
      transparent 28rem
    ),
    var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.nav-open {
  overflow: hidden;
}

.construction-banner {
  border-bottom: 1px solid rgba(255, 123, 146, .28);
  background: rgba(255, 123, 146, .08);
  color: var(--muted);
  font-size: .84rem;
}

.construction-banner .container {
  padding-block: 10px;
}

.construction-banner strong {
  color: var(--ink);
}

main {
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
}

button {
  color: inherit;
}

img, svg {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
  object-fit: contain;
}

figure {
  margin: 0;
}

p, h1, h2, h3, dl, dd {
  margin-top: 0;
}

::selection {
  background: var(--purple);
  color: #fff;
}

/* Mise en page commune */
.container {
  width: min(calc(100% - 40px), var(--container));
  margin-inline: auto;
}

.section {
  padding: clamp(76px, 9vw, 118px) 0;
}

.section--soft {
  background: linear-gradient(180deg, rgba(14, 23, 48, .70), rgba(14, 23, 48, .38));
  border-block: 1px solid var(--line);
}

.section__head {
  max-width: 760px;
  margin-bottom: 42px;
}

.section__eyebrow {
  margin-bottom: 12px;
  color: var(--cyan);
  font: 600 .74rem/1.2 var(--font-mono);
  letter-spacing: .16em;
  text-transform: uppercase;
}

.section__title {
  max-width: 800px;
  margin-bottom: 16px;
  font-size: clamp(2rem, 4vw, 3.35rem);
  line-height: 1.04;
  letter-spacing: -.035em;
}

.section__lead {
  max-width: 720px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.08rem);
}

/* Composants communs */
.card {
  background: linear-gradient(145deg, rgba(17, 27, 56, .96), rgba(13, 23, 48, .92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .015) inset;
}

.btn {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 750;
  line-height: 1.2;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn--primary {
  background: linear-gradient(120deg, var(--cyan), var(--blue) 58%, var(--purple));
  color: #05101f;
  box-shadow: 0 12px 30px -12px rgba(0, 194, 255, .7);
}

.btn--ghost {
  border-color: rgba(234, 247, 255, .20);
  background: rgba(255,255,255,.015);
}

.btn--ghost:hover {
  border-color: var(--cyan);
  color: var(--cyan);
}

.btn--sm {
  min-height: 38px;
  padding: 8px 16px;
  font-size: .87rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font: 500 .72rem/1.2 var(--font-mono);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 0 5px rgba(0,194,255,.08);
}

/* Formulaires communs */
.form-card {
  padding: clamp(22px, 4vw, 34px);
}

.form-grid {
  display: grid;
  gap: 16px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-field {
  display: grid;
  gap: 7px;
}

.form-field > span, .form-label {
  color: var(--muted);
  font: 600 .76rem/1.35 var(--font-mono);
  letter-spacing: .04em;
}

.form-field input, .form-field select, .form-field textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(7, 13, 29, .60);
  color: var(--ink);
  padding: 11px 13px;
  outline: 0;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.form-field textarea {
  min-height: 122px;
  resize: vertical;
}

.form-field input::placeholder, .form-field textarea::placeholder {
  color: var(--muted-2);
}

.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(0,194,255,.09);
}

.form-check {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 10px;
  align-items: start;
  color: var(--muted);
  font-size: .84rem;
}

.form-check input {
  width: 17px;
  height: 17px;
  margin: 3px 0 0;
  accent-color: var(--cyan);
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.form-status {
  margin: 0;
  min-height: 1.5em;
  font-size: .84rem;
  color: var(--muted);
}

.form-status.is-error {
  color: var(--danger);
}

.form-status.is-success {
  color: var(--success);
}

.form-status.is-disabled {
  color: var(--blue);
}

.btn:disabled {
  cursor: not-allowed;
  opacity: .52;
  transform: none;
  box-shadow: none;
}

.form-note {
  margin: 0;
  color: var(--muted-2);
  font-size: .75rem;
}

.form-honey {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

/* Accessibilité et messages techniques */
.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 9999;
  transform: translateY(-180%);
  padding: 9px 13px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 800;
}

.skip-link:focus {
  transform: translateY(0);
}

.noscript, .section-load-error {
  width: min(calc(100% - 40px), 900px);
  margin: 100px auto 30px;
  padding: 18px 20px;
  border: 1px solid var(--danger);
  border-radius: 12px;
  background: rgba(255,123,146,.08);
}

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/*
 * Animations d'apparition.
 * Le contenu n'est jamais masqué par JavaScript : si l'animation échoue,
 * les éléments restent visibles.
 */
.reveal {
  opacity: 1;
  transform: none;
}

.js .reveal.is-visible {
  animation: reveal-in .48s ease both;
}

@keyframes reveal-in {
  from {
    opacity: .01;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(calc(100% - 28px), var(--container));
  }
  .section {
    padding: 72px 0;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .btn {
    width: 100%;
  }
  .form-actions .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
  .js .reveal {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
