:root {
  --paper: #F4F8FF;
  --paper-raised: #FFFFFF;
  --ink: #0B1F4F;
  --ink-soft: #4C5F89;
  --line: #D8E2FF;
  --board: #1D5EFF;
  --board-soft: #E9F0FF;
  --copper: #6C4BFF;
  --copper-soft: #EFEAFF;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.mono { font-family: ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", monospace; }
.display { font-family: "Avenir Next", "Century Gothic", Futura, "Segoe UI", sans-serif; font-weight: 700; letter-spacing: -0.02em; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 32px; }
a { color: inherit; }

/* Écran d'attente avant l'ouverture du site */
body.site-waiting { min-height: 100vh; min-height: 100dvh; overflow: hidden; }
.opening-screen {
  position: fixed; inset: 0; z-index: 9999; display: grid; place-items: center;
  min-height: 100vh; min-height: 100dvh; padding: 24px;
  background: radial-gradient(circle at 15% 15%, rgba(29, 94, 255, .14), transparent 32rem), radial-gradient(circle at 85% 85%, rgba(108, 75, 255, .12), transparent 30rem), var(--paper);
}
.opening-screen::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .45;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 48px 48px; mask-image: linear-gradient(to bottom, transparent, #000 25%, #000 75%, transparent);
}
.opening-dialog {
  position: relative; width: min(100%, 620px); max-height: calc(100dvh - 48px); overflow: auto;
  margin: 0; padding: clamp(32px, 7vw, 64px); color: var(--ink); text-align: center;
  background: rgba(255, 255, 255, .96); border: 1px solid var(--line); border-top: 4px solid var(--board);
  border-radius: 8px; box-shadow: 0 28px 80px rgba(11, 31, 79, .16);
}
.opening-logo { display: block; width: 72px; height: 72px; margin: 0 auto 24px; border-radius: 14px; object-fit: cover; }
.opening-label { margin-bottom: 12px; color: var(--board); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.opening-dialog h1 { max-width: none; margin-bottom: 16px; font-size: clamp(30px, 6vw, 44px); }
.opening-dialog > p:not(.opening-label):not(.opening-note) { max-width: 460px; margin: 0 auto; color: var(--ink-soft); font-size: 16px; }
.opening-date {
  display: inline-flex; align-items: baseline; gap: 10px; margin: 32px 0 22px; padding: 10px 20px;
  color: var(--ink); background: var(--board-soft); border: 1px solid var(--line); font-size: 18px;
}
.opening-date span:first-child { color: var(--board); font-size: 30px; font-weight: 700; }
.opening-note { color: var(--ink-soft); font-size: 12px; }

header { border-bottom: 1px solid var(--line); background: linear-gradient(180deg, #FFFFFF 0%, #F5F8FF 100%); }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 22px 0; }
.logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.logo-mark {
  display: block;
  height: 52px;
  width: 52px;
  object-fit: cover;
  object-position: center;
  border-radius: 10px;
}
.logo-title { font-size: 22px; line-height: 1; color: var(--ink); letter-spacing: -0.01em; }
.logo-title span { color: var(--board); }
nav { display: flex; gap: 32px; align-items: center; }
nav a { font-size: 14px; color: var(--ink-soft); text-decoration: none; transition: color .15s ease; }
nav a:hover, nav a.active { color: var(--ink); }
.nav-cta { border: 1px solid var(--ink); color: var(--ink); padding: 8px 18px; border-radius: 2px; font-size: 13px; text-decoration: none; transition: background .15s ease, color .15s ease; }
.nav-cta:hover { background: var(--board); border-color: var(--board); color: #FFFFFF; }

/* Home hero */
.hero { padding: 88px 0 40px; }
.eyebrow { font-family: ui-monospace, monospace; font-size: 12px; letter-spacing: 0.12em; color: var(--copper); text-transform: uppercase; margin-bottom: 20px; }
.eyebrow::before { content: "// "; color: var(--line); }
h1 { font-size: 42px; line-height: 1.15; max-width: 680px; margin-bottom: 22px; }
.lede { font-size: 18px; color: var(--ink-soft); max-width: 540px; margin-bottom: 32px; }
.cta-row { display: flex; gap: 16px; align-items: center; margin-bottom: 72px; }
.cta-primary { background: linear-gradient(135deg, var(--board) 0%, var(--copper) 100%); color: #FFFFFF; padding: 13px 26px; border-radius: 2px; text-decoration: none; font-size: 14px; font-weight: 500; display: inline-block; transition: transform .15s ease, filter .15s ease; }
.cta-primary:hover { filter: brightness(1.05); transform: translateY(-1px); }
.cta-primary:active { transform: translateY(0) scale(0.98); }
.cta-secondary { color: var(--ink-soft); text-decoration: none; font-size: 14px; border-bottom: 1px solid var(--line); transition: border-color .15s ease, color .15s ease; }
.cta-secondary:hover { color: var(--ink); border-color: var(--ink-soft); }

.hero-anim { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .hero-anim { opacity: 0; animation: fadeUp .7s ease forwards; }
  .hero-anim.d1 { animation-delay: .05s; }
  .hero-anim.d2 { animation-delay: .15s; }
  .hero-anim.d3 { animation-delay: .28s; }
  .hero-anim.d4 { animation-delay: .4s; }
  .hero-anim.d5 { animation-delay: .55s; }
}
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

.trace-wrap { padding: 20px 0 20px; overflow-x: auto; }
.trace-caption { font-family: ui-monospace, monospace; font-size: 11px; color: var(--ink-soft); text-align: center; margin-top: 14px; letter-spacing: 0.04em; }
.trace-line { stroke-dasharray: 1; stroke-dashoffset: 0; }
@media (prefers-reduced-motion: no-preference) {
  .trace-line { stroke-dashoffset: 1; animation: drawLine 1s ease forwards; }
  .trace-node { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(.7); animation: popIn .4s ease forwards; }
}
@keyframes drawLine { to { stroke-dashoffset: 0; } }
@keyframes popIn { to { opacity: 1; transform: scale(1); } }
.signal-pulse { opacity: 0; transition: opacity .3s ease; }
.signal-pulse.active { opacity: 1; }

/* Sub-page hero (lighter banner for Offre / A propos / Contact) */
.page-hero { padding: 64px 0 48px; border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: 34px; max-width: 640px; }
.page-hero .lede { margin-bottom: 0; }

.benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; padding: 56px 0; border-top: 1px solid var(--line); }
.benefit .num { font-family: ui-monospace, monospace; font-size: 12px; color: var(--copper); margin-bottom: 10px; }
.benefit h3 { font-size: 17px; margin-bottom: 8px; }
.benefit p { font-size: 14px; color: var(--ink-soft); }

.section { padding: 64px 0; border-top: 1px solid var(--line); }
.section:first-child { border-top: none; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 40px; flex-wrap: wrap; gap: 12px; }
.section-head h2 { font-size: 26px; }
.section-head .mono { font-size: 12px; color: var(--ink-soft); }

.offer-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.offer-card { background: var(--paper-raised); padding: 28px; transition: background .2s ease, transform .2s ease; }
.offer-card:hover { background: #F7F9FF; transform: translateY(-2px); }
.offer-ref { font-family: ui-monospace, monospace; font-size: 12px; color: var(--board); margin-bottom: 14px; }
.offer-card h3 { font-size: 18px; margin-bottom: 10px; }
.offer-card p { font-size: 14px; color: var(--ink-soft); margin-bottom: 14px; }
.offer-card ul { list-style: none; font-size: 13px; color: var(--ink-soft); }
.offer-card li { padding: 4px 0; padding-left: 14px; position: relative; }
.offer-card li::before { content: "–"; position: absolute; left: 0; color: var(--line); }

.modality-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; }
.modality { border: 1px solid var(--line); padding: 20px; background: var(--paper-raised); }
.modality h4 { font-size: 15px; margin-bottom: 6px; }
.modality p { font-size: 13px; color: var(--ink-soft); }

.quote { border-left: 2px solid var(--copper); padding: 4px 0 4px 28px; max-width: 680px; font-size: 19px; color: var(--ink); font-style: normal; }
.quote-attr { font-family: ui-monospace, monospace; font-size: 12px; color: var(--ink-soft); margin-top: 16px; }

.timeline { position: relative; padding-left: 28px; max-width: 640px; }
.timeline::before { content: ""; position: absolute; left: 4px; top: 6px; bottom: 6px; width: 1px; background: var(--line); }
.tl-item { position: relative; padding-bottom: 32px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ""; position: absolute; left: -28px; top: 4px; width: 9px; height: 9px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--board); transition: background .2s ease; }
.tl-item:hover::before { background: var(--board); }
.tl-date { font-family: ui-monospace, monospace; font-size: 12px; color: var(--copper); margin-bottom: 4px; }
.tl-item h4 { font-size: 16px; margin-bottom: 4px; }
.tl-item p { font-size: 14px; color: var(--ink-soft); }

.bio-lede { font-size: 17px; color: var(--ink-soft); max-width: 680px; margin-bottom: 48px; }

.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 56px; }
.contact-info p { font-size: 14px; color: var(--ink-soft); margin-bottom: 20px; }
.contact-info .mono { font-size: 13px; color: var(--ink); }
form { display: flex; flex-direction: column; gap: 14px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
label { font-size: 12px; color: var(--ink-soft); display: block; margin-bottom: 6px; }
input, select, textarea { width: 100%; border: 1px solid var(--line); background: var(--paper-raised); padding: 10px 12px; font-size: 14px; font-family: inherit; border-radius: 2px; color: var(--ink); transition: border-color .15s ease; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--board); }
textarea { min-height: 90px; resize: vertical; }
.submit-btn { background: var(--ink); color: var(--paper); padding: 12px 24px; border: none; border-radius: 2px; font-size: 14px; cursor: pointer; align-self: flex-start; margin-top: 4px; transition: background .15s ease, transform .15s ease; }
.submit-btn:hover { background: #2E3A4A; }
.submit-btn:active { transform: scale(.98); }
.response-note { font-size: 12px; color: var(--ink-soft); margin-top: 6px; }
.form-hp { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.form-alert { padding: 12px 14px; border: 1px solid var(--line); font-size: 13px; }
.form-alert.success { color: #145C3E; background: #EAF8F1; border-color: #B9E3CE; }
.form-alert.error { color: #8A2632; background: #FFF0F2; border-color: #F1C2C8; }
.form-alert ul { margin: 6px 0 0 18px; }

footer { border-top: 1px solid var(--line); padding: 28px 0; }
.footer-inner { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-soft); flex-wrap: wrap; gap: 10px; }
.footer-inner a { text-decoration: none; margin-left: 18px; transition: color .15s ease; }
.footer-inner a:hover { color: var(--ink); }

.reveal-init { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s ease; }
.reveal-init.in-view { opacity: 1; transform: none; }

.legal-content .todo { color: var(--copper); font-weight: 600; }
.legal-content .note {
  background: var(--board-soft);
  border: 1px solid var(--line);
  border-left: 3px solid var(--board);
  padding: 14px 16px;
  margin-bottom: 24px;
  color: var(--ink-soft);
}

@media (max-width: 720px) {
  h1 { font-size: 30px; }
  .page-hero h1 { font-size: 26px; }
  .logo-mark { height: 42px; }
  .logo-title { font-size: 18px; }
  .benefits { grid-template-columns: 1fr; }
  .offer-grid { grid-template-columns: 1fr; }
  .modality-row { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  nav { display: none; }
}
