/* Charte du site, alignée sur le logo et l'application : blanc, bleu
   Kubernetes (accents, illustrations), bleu de l'application (actions) et
   bleu nuit du logo (titres, bandeaux). Clair et sombre définis ici. */
@font-face {
  font-family: "Inter";
  src: url("/static/fonts/inter-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root {
  --navy: #102850;
  --navy-2: #0b1d3d;
  --kube: #326ce5;
  --blue: #1d4ed8;
  --sky: #eaf1fd;
  --bg: #ffffff;
  --bg-alt: #f5f8fe;
  --surface: #ffffff;
  --text: #13213d;
  --heading: #102850;
  --muted: #56627a;
  --border: #dbe3f1;
  --accent: #1d4ed8;
  --accent-hover: #1a43bb;
  --accent-text: #ffffff;
  --eyebrow: #2459c9;
  --danger: #b91c1c;
  --ok: #15803d;
  --warn: #a16207;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(16 40 80 / 6%), 0 8px 24px rgb(16 40 80 / 8%);
  --shadow-lg: 0 20px 50px rgb(16 40 80 / 18%);
  --header-h: 64px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a1530;
    --bg-alt: #0e1c3d;
    --surface: #12224a;
    --text: #e3eaf8;
    --heading: #ffffff;
    --muted: #a3b2cf;
    --border: #233a6b;
    --sky: #16295a;
    --accent: #5b8def;
    --accent-hover: #7aa2f7;
    --accent-text: #08122a;
    --eyebrow: #8db3ff;
    --danger: #f87171;
    --ok: #4ade80;
    --warn: #facc15;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px rgb(0 0 0 / 25%);
    --shadow-lg: 0 20px 50px rgb(0 0 0 / 40%);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font: 16px/1.6 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--accent); }
h1, h2, h3 { color: var(--heading); line-height: 1.2; letter-spacing: -0.02em; font-weight: 800; text-wrap: balance; }
h3 { font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 34px; margin: 28px 0 12px; }
h2 { font-size: 22px; margin: 24px 0 8px; }
h3 { font-size: 18px; margin: 0 0 6px; }
p { text-wrap: pretty; }
.lead { font-size: 18px; color: var(--muted); max-width: 720px; }
.muted { color: var(--muted); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
:focus-visible { outline: 2px solid var(--kube); outline-offset: 2px; }

/* En-tête */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.top.scrolled { border-bottom-color: var(--border); box-shadow: 0 4px 16px rgb(16 40 80 / 6%); }
.top .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; color: var(--heading); text-decoration: none; letter-spacing: -0.01em; }
.brand img { display: block; }
.brand .name span { color: var(--kube); }
nav { display: flex; gap: 6px; align-items: center; }
nav a { text-decoration: none; color: var(--text); font-weight: 500; font-size: 15px; padding: 8px 12px; border-radius: 8px; transition: color .15s, background .15s; }
nav a:hover { color: var(--accent); background: var(--sky); }
nav a[aria-current="page"] { color: var(--accent); font-weight: 600; }
nav .button { margin-left: 8px; padding: 9px 16px; }
nav .button.primary:hover { color: var(--accent-text); background: var(--accent-hover); }
.menu { display: none; }

main { max-width: 1120px; margin: 0 auto; padding: 8px 24px 80px; }
main.wide { max-width: none; padding: 0; }
main > .section:last-child { padding-bottom: 0; }

/* Boutons */
.button, button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--heading);
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s, background .15s, box-shadow .15s, border-color .15s;
}
.button:hover, button:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.button.primary, button.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.button.primary:hover, button.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.button.large { padding: 14px 26px; font-size: 16px; }
.button.ghost { background: transparent; color: #ffffff; border-color: rgb(255 255 255 / 40%); }
.button.ghost:hover { background: rgb(255 255 255 / 10%); border-color: rgb(255 255 255 / 70%); }
button.danger { color: var(--danger); border-color: var(--danger); }

/* Accueil : bandeau */
.hero {
  position: relative;
  background:
    radial-gradient(900px 480px at 85% -10%, rgb(50 108 229 / 55%) 0%, transparent 65%),
    radial-gradient(600px 400px at -10% 110%, rgb(50 108 229 / 25%) 0%, transparent 70%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #ffffff;
  overflow: hidden;
}
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; padding-top: 80px; padding-bottom: 88px; }
.hero h1 { color: #ffffff; font-size: 54px; line-height: 1.08; letter-spacing: -0.03em; margin: 18px 0 20px; }
.hero h1 em { display: block; font-style: normal; color: #8db3ff; }
.hero .lead { color: #c9d8fb; font-size: 18px; line-height: 1.65; }
.hero .actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 32px; }
.hero .visual img { display: block; width: 100%; filter: drop-shadow(0 30px 40px rgb(0 0 0 / 35%)); }
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--eyebrow);
}
.hero .eyebrow { color: #c9d8fb; background: rgb(255 255 255 / 8%); border: 1px solid rgb(255 255 255 / 18%); padding: 5px 14px; border-radius: 999px; font-size: 12px; }
.sources { display: flex; gap: 8px; flex-wrap: wrap; margin: 36px 0 0; color: #a9c0ee; font-size: 13px; }
.sources span { background: rgb(255 255 255 / 6%); border: 1px solid rgb(255 255 255 / 12%); border-radius: 999px; padding: 5px 12px; }
.sources strong { color: #ffffff; font-weight: 700; margin-right: 4px; }

/* Chiffres clés */
.stats { background: var(--bg-alt); border-bottom: 1px solid var(--border); }
.stats .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; padding-top: 36px; padding-bottom: 36px; }
.stat { text-align: center; margin: 0; }
.stat b { display: block; font-size: 30px; font-weight: 800; letter-spacing: -0.02em; color: var(--accent); font-variant-numeric: tabular-nums; }
.stat > span { display: block; color: var(--muted); font-size: 15px; max-width: 240px; margin: 4px auto 0; }

/* Sections */
.section { padding: 96px 0; }
.section.alt { background: var(--bg-alt); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 56px; }
.section-head h2 { font-size: 38px; letter-spacing: -0.03em; margin: 10px 0 14px; }
.section-head .lead { margin: 0 auto; }

/* Fonctionnalités : récit au défilement. Sur grand écran avec script, le
   texte défile à gauche et l'illustration reste fixe à droite et change
   avec la fonctionnalité lue. Sinon, chaque texte a son illustration. */
.story { position: relative; }
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; margin: 0 0 96px; }
.feature:last-child { margin-bottom: 0; }
.feature:nth-child(even) .feature-text { order: 2; }
.feature h3 { font-size: 30px; letter-spacing: -0.02em; margin: 10px 0 14px; }
.feature p { color: var(--muted); font-size: 17px; }
.feature .eyebrow b { display: inline-grid; place-items: center; min-width: 30px; height: 22px; margin-right: 8px; padding: 0 6px; border-radius: 6px; background: var(--sky); color: var(--accent); font-size: 12px; letter-spacing: 0; }
.feature-visual img, .split img, .stage-frame img { display: block; width: 100%; border-radius: 24px; box-shadow: var(--shadow-lg); }
.story-stage { display: none; }
.checks { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 32px; }
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--kube) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px no-repeat;
}

@media (min-width: 961px) {
  .js .story { display: grid; grid-template-columns: 1fr 1.05fr; gap: 72px; }
  .js .feature { display: flex; flex-direction: column; justify-content: center; min-height: 64vh; margin: 0; }
  .js .feature:nth-child(even) .feature-text { order: 0; }
  .js .feature-visual { display: none; }
  .js .feature-text { transition: opacity .5s ease; }
  .js .feature:not(.active) .feature-text.visible { opacity: .35; }
  .js .story-stage { display: block; position: sticky; top: calc(50vh - 230px + var(--header-h) / 2); align-self: start; height: 460px; margin-top: calc(36vh - 230px); }
  .js .stage-frame { position: relative; aspect-ratio: 4 / 3; }
  .js .stage-frame img { position: absolute; inset: 0; opacity: 0; transform: translateY(24px) scale(.96); transition: opacity .6s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
  .js .stage-frame img.active { opacity: 1; transform: none; }
  .js .stage-frame img.past { transform: translateY(-24px) scale(.96); }
  .stage-progress { list-style: none; display: flex; gap: 8px; justify-content: center; padding: 0; margin: 24px 0 0; }
  .stage-progress li { width: 28px; height: 4px; border-radius: 4px; background: var(--border); transition: background .3s, width .3s; }
  .stage-progress li.active { width: 48px; background: var(--kube); }
}

/* Comment ça marche */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; margin-bottom: 72px; }
.split h3 { font-size: 30px; letter-spacing: -0.02em; margin: 10px 0 14px; }
.split p { color: var(--muted); font-size: 17px; }

/* Cartes */
.cards { display: grid; gap: 20px; grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--kube) 40%, var(--border)); }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--muted); margin: 0; }
.icon {
  width: 46px;
  height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  background: var(--kube);
  color: #ffffff;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  font-weight: 800;
  font-size: 18px;
}

/* Étapes */
.steps { counter-reset: step; display: grid; gap: 24px; grid-template-columns: repeat(3, 1fr); padding-top: 20px; }
.steps .card { position: relative; padding-top: 38px; }
.steps .card::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  top: -20px;
  left: 24px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--accent);
  color: var(--accent-text);
  font-weight: 800;
  box-shadow: var(--shadow);
}
.steps code { font-size: 14px; }

/* Appel final */
.cta {
  background:
    radial-gradient(500px 300px at 100% 0%, rgb(255 255 255 / 12%) 0%, transparent 70%),
    linear-gradient(135deg, var(--navy) 0%, var(--blue) 100%);
  color: #ffffff;
  border-radius: 24px;
  padding: 64px 32px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta::after {
  content: "";
  position: absolute;
  right: -60px;
  bottom: -70px;
  width: 240px;
  height: 270px;
  background: rgb(255 255 255 / 6%);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  pointer-events: none;
}
.cta h2 { color: #ffffff; font-size: 36px; letter-spacing: -0.03em; margin: 0 0 12px; }
.cta p { color: #c9d8fb; font-size: 18px; margin: 0 auto 28px; max-width: 560px; }
.cta .button { margin: 4px; }
.cta .button.primary { background: #ffffff; border-color: #ffffff; color: var(--navy); }
.cta .button.primary:hover { background: var(--sky); border-color: var(--sky); color: var(--navy); }
@media (prefers-color-scheme: dark) { .cta .button.primary:hover { background: #dbe6fb; border-color: #dbe6fb; } }

/* Tarifs */
.pricing-head { text-align: center; padding: 56px 0 8px; }
.pricing-head h1 { font-size: 46px; letter-spacing: -0.03em; margin: 12px 0 16px; }
.pricing-head .lead { margin: 0 auto; }
.plans { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin: 48px 0 24px; align-items: stretch; }
.plan {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 28px 24px;
  box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s;
}
.plan:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.plan h2 { margin: 0; font-size: 21px; }
.plan .mode { font-size: 12px; font-weight: 700; color: var(--eyebrow); text-transform: uppercase; letter-spacing: .08em; }
.plan .price { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; color: var(--heading); margin: 6px 0 0; white-space: nowrap; }
.plan .price small { font-size: 15px; font-weight: 600; letter-spacing: 0; color: var(--muted); }
.plan .quota { display: inline-block; align-self: flex-start; background: var(--sky); color: var(--accent); font-weight: 700; font-size: 13px; border-radius: 999px; padding: 4px 12px; }
.plan p { color: var(--muted); margin: 8px 0 16px; font-size: 15px; }
.plan .limits { color: var(--heading); font-weight: 600; font-size: 14px; margin: 0; }
.plan .features { list-style: none; padding: 0; margin: 0 0 16px; font-size: 14px; color: var(--muted); }
.plan .features li { padding-left: 20px; position: relative; margin: 6px 0; }
.plan .features li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.plan .button { margin-top: auto; width: 100%; }
.plan .button.soon { cursor: default; color: var(--muted); background: var(--bg-alt); border-style: dashed; }
.plan .button.soon:hover { transform: none; box-shadow: none; }
.plan.shared { border-top: 4px solid var(--kube); }
.plan.container { border-top: 4px solid var(--blue); }
.plan.dedicated { border-top: 4px solid var(--navy); }
@media (prefers-color-scheme: dark) { .plan.dedicated { border-top-color: #8db3ff; } }
.included { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin: 16px 0 24px; }
.faq { max-width: 820px; margin: 0 auto 32px; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 0 20px; margin: 12px 0; box-shadow: var(--shadow); }
.faq summary { cursor: pointer; font-weight: 700; color: var(--heading); padding: 16px 32px 16px 0; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%); color: var(--kube); font-size: 22px; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { color: var(--muted); margin: 0 0 18px; }

/* Pied de page */
footer { background: var(--navy-2); color: #a9c0ee; }
footer .wrap { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; padding-top: 56px; padding-bottom: 40px; }
footer .about p { margin: 14px 0 0; max-width: 340px; font-size: 15px; }
footer .brand { color: #ffffff; }
footer .brand .name span { color: #8db3ff; }
footer h2 { color: #ffffff; margin: 4px 0 14px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
footer a { color: #c9d8fb; text-decoration: none; font-size: 15px; transition: color .15s; }
footer a:hover { color: #ffffff; }
footer .legal { border-top: 1px solid rgb(255 255 255 / 10%); font-size: 13px; }
footer .legal .wrap { display: block; padding-top: 18px; padding-bottom: 18px; }
footer .legal a { font-size: inherit; }

/* Apparition au défilement : seulement si le script tourne (classe js),
   jamais si l'utilisateur limite les animations. */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
  .js .reveal.from-left { transform: translateX(-36px); }
  .js .reveal.from-right { transform: translateX(36px); }
  .js .reveal.visible { opacity: 1; transform: none; }
  .js .reveal.delay-1 { transition-delay: .1s; }
  .js .reveal.delay-2 { transition-delay: .2s; }
  .js .reveal.delay-3 { transition-delay: .3s; }
  .js .checks li { opacity: 0; transform: translateX(-12px); transition: opacity .5s ease, transform .5s ease; }
  .js .visible .checks li { opacity: 1; transform: none; }
  .js .visible .checks li:nth-child(1) { transition-delay: .25s; }
  .js .visible .checks li:nth-child(2) { transition-delay: .4s; }
  .js .visible .checks li:nth-child(3) { transition-delay: .55s; }
  .hero .visual img { animation: float 6s ease-in-out infinite; }
  @keyframes float { 50% { transform: translateY(-10px); } }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button, .card, .plan, .stage-frame img { transition: none !important; }
}

/* Pages de service : formulaires, espace client, documentation */
.narrow { max-width: 520px; }
.page { max-width: 820px; }
.page h2 { margin-top: 32px; }
form label { display: block; margin: 12px 0; font-size: 14px; color: var(--muted); }
form input:not([type="radio"]), form textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
}
form input:focus, form textarea:focus { outline: 2px solid var(--kube); outline-offset: 1px; }
fieldset { border: 1px solid var(--border); border-radius: 10px; padding: 8px 14px; }
label.choice { color: var(--text); }
/* Compte de la console partagée : masqué quand un plan à console propre
   est choisi (visible sans :has, le serveur ignore alors ces champs). */
form.signup:has(input[name=plan]:checked:not([data-mode=shared])) .shared-account { display: none; }
.plans-note { text-align: center; margin: 16px auto 0; max-width: 720px; }
.legal-page h2 { margin-top: 32px; }
.legal-page dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; }
.legal-page dt { color: var(--muted); }
.legal-page dd { margin: 0; }
.legal-page table { border-collapse: collapse; width: 100%; margin: 12px 0; }
.legal-page th, .legal-page td { border: 1px solid var(--border); padding: 8px 10px; text-align: left; vertical-align: top; }
@media (max-width: 640px) { .legal-page dl { grid-template-columns: 1fr; } .legal-page table { display: block; overflow-x: auto; } }
.alert { padding: 12px 16px; border-radius: 10px; border: 1px solid; margin: 16px 0; }
.alert.error { color: var(--danger); border-color: var(--danger); }
.alert.notice { color: var(--ok); border-color: var(--ok); }
.head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.tenant { margin: 16px 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); }
dl { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; }
dt { color: var(--muted); }
dd { margin: 0; overflow-wrap: anywhere; }
.state { font-weight: 600; }
.state-active { color: var(--ok); }
.state-provisioning, .state-deleting, .state-suspended { color: var(--warn); }
.state-failed { color: var(--danger); }
code { background: var(--bg-alt); border: 1px solid var(--border); border-radius: 6px; padding: 1px 6px; font-size: .9em; overflow-wrap: anywhere; }
code.secret { font-size: 18px; }
.tenant details { margin-top: 12px; }
.tenant summary { cursor: pointer; color: var(--danger); }

@media (max-width: 960px) {
  .hero .wrap, .feature, .split { grid-template-columns: 1fr; gap: 32px; }
  .feature:nth-child(even) .feature-text { order: 0; }
  .hero .wrap { padding-top: 56px; padding-bottom: 64px; }
  .hero h1 { font-size: 42px; }
  .hero .visual { max-width: 560px; }
  .section { padding: 72px 0; }
  .section-head h2 { font-size: 30px; }
  .feature { margin-bottom: 72px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  footer .wrap { grid-template-columns: 1fr 1fr; }
  footer .about { grid-column: 1 / -1; }
}

/* Menu replié dès que le bandeau ne tient plus sur une ligne (allemand,
   italien : libellés longs). */
@media (max-width: 960px) {
  .menu {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border-radius: 10px;
  }
  .menu:hover { transform: none; box-shadow: none; }
  .menu span, .menu span::before, .menu span::after { display: block; width: 18px; height: 2px; border-radius: 2px; background: var(--heading); transition: transform .2s, background .2s; }
  .menu span { position: relative; }
  .menu span::before, .menu span::after { content: ""; position: absolute; left: 0; }
  .menu span::before { top: -6px; }
  .menu span::after { top: 6px; }
  .menu[aria-expanded="true"] span { background: transparent; }
  .menu[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
  .menu[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }
  .js nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px 16px 16px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 24px rgb(16 40 80 / 10%);
    display: none;
  }
  .js nav.open { display: flex; }
  .js nav a { padding: 12px; font-size: 16px; }
  .js nav .button { margin: 8px 0 0; }
  .js nav .lang-menu ul { position: static; margin-top: 6px; box-shadow: none; }
  html:not(.js) .menu { display: none; }
  html:not(.js) .top .wrap { flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
  html:not(.js) nav { flex-wrap: wrap; }
}

@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  main { padding: 8px 16px 64px; }
  h1 { font-size: 30px; }
  .hero .wrap { padding-top: 40px; padding-bottom: 56px; gap: 40px; }
  .hero h1 { font-size: 34px; }
  .hero .lead { font-size: 17px; }
  .hero .actions .button { flex: 1 1 100%; }
  .stats .wrap { grid-template-columns: 1fr 1fr; gap: 24px 12px; padding-top: 32px; padding-bottom: 32px; }
  .stat b { font-size: 24px; }
  .stat > span { font-size: 14px; }
  .section { padding: 56px 0; }
  .section-head { margin-bottom: 40px; }
  .section-head h2 { font-size: 27px; }
  .feature h3, .split h3 { font-size: 24px; }
  .feature { margin-bottom: 56px; gap: 24px; }
  .cards, .steps { grid-template-columns: 1fr; }
  .steps { gap: 36px; }
  .cta { padding: 44px 20px; border-radius: 20px; }
  .cta h2 { font-size: 27px; }
  .cta .button { width: 100%; margin: 4px 0; }
  .pricing-head { padding-top: 32px; }
  .pricing-head h1 { font-size: 32px; }
  footer .wrap { gap: 32px 24px; padding-top: 40px; padding-bottom: 32px; }
  dl { grid-template-columns: 1fr; }
}

/* Consentement à la mesure d'audience : deux choix de même poids. */
.consent { position: fixed; z-index: 50; left: 16px; right: 16px; bottom: 16px; max-width: 560px; margin: 0 auto; padding: 18px 20px; background: var(--surface, #fff); color: inherit; border: 1px solid var(--border, #d8dee8); border-radius: 14px; box-shadow: 0 10px 30px rgb(16 40 80 / 18%); }
.consent[hidden] { display: none; }
.consent p { margin: 0 0 14px; font-size: 15px; }
.consent-actions { display: flex; gap: 12px; justify-content: flex-end; flex-wrap: wrap; }
.consent-actions .button { min-width: 120px; }
footer .legal button.link { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; font: inherit; box-shadow: none; }
footer .legal button.link:hover { transform: none; }

/* Console d'administration */
.admin-totals { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; margin: 16px 0 24px; }
.admin-totals dt { font-weight: 600; }
.admin-table { overflow-x: auto; margin-bottom: 32px; }
.admin-table table { border-collapse: collapse; width: 100%; font-size: 0.9rem; }
.admin-table th, .admin-table td { text-align: left; vertical-align: top; padding: 8px; border-bottom: 1px solid #e2e8f0; }
.admin-actions form { display: inline-block; margin: 0 4px 4px 0; }
.mono { font-family: ui-monospace, monospace; font-size: 0.8rem; word-break: break-all; }
.state-awaiting_payment { color: var(--warn); }
.status-list { list-style: none; padding: 0; }
.status-list li { padding: 10px 0; border-bottom: 1px solid #e2e8f0; }
.admin-nav { margin: 0 0 8px; }
.admin h3 { margin: 0 0 4px; font-size: 15px; }
.capacity { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin: 16px 0; }
.capacity .gauge { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.capacity .big { font-size: 26px; font-weight: 700; margin: 4px 0; }
.capacity meter { width: 100%; height: 10px; }
.capacity .muted { font-size: 13px; margin: 6px 0 0; }
.admin-details { margin: 0 0 24px; }
.admin-form { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: end; margin: 12px 0 16px; }
.admin-form label { display: grid; gap: 4px; font-size: 13px; }
.admin-form input, .admin-form select { min-width: 0; width: 170px; padding: 8px 10px; }
.admin .over { color: var(--danger); font-weight: 600; }

/* Inscription et connexion à l'administration */
form [hidden] { display: none !important; }
.signup-shell { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); gap: 40px; align-items: start; padding: 32px 0 56px; }
.signup-aside { position: sticky; top: calc(var(--header-h) + 24px); background: var(--navy); color: #fff; border-radius: 18px; padding: 32px 28px; box-shadow: var(--shadow-lg); }
.signup-aside h2 { color: #fff; font-size: 24px; line-height: 1.25; letter-spacing: -0.02em; margin: 16px 0 12px; }
.signup-aside p { color: #c9d6ee; margin: 0 0 16px; }
.signup-aside ul { list-style: none; margin: 0; padding: 0; color: #e3eaf8; font-size: 15px; }
.signup-aside li { position: relative; padding-left: 24px; margin: 12px 0; }
.signup-aside li::before { content: "✓"; position: absolute; left: 0; color: #8db3ff; font-weight: 700; }
.signup-aside code { color: #fff; background: rgb(255 255 255 / 14%); border-radius: 4px; padding: 1px 5px; white-space: nowrap; }
.signup-main { min-width: 0; max-width: 720px; }
.signup-main h1 { font-size: 34px; letter-spacing: -0.02em; margin: 24px 0 8px; }
.signup-steps { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 0; padding: 0; font-size: 14px; color: var(--muted); }
.signup-steps li { display: flex; align-items: center; gap: 8px; }
.signup-steps span { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--border); font-weight: 700; font-size: 13px; }
.signup-steps .current { color: var(--heading); font-weight: 700; }
.signup-steps .current span { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.signup-steps .done span { background: var(--sky); border-color: var(--sky); color: var(--accent); }
.signup-card, fieldset.signup-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; margin: 20px 0; min-width: 0; }
fieldset.signup-card legend { float: left; width: 100%; padding: 0; margin-bottom: 12px; font-size: 18px; font-weight: 700; color: var(--heading); }
fieldset.signup-card legend + * { clear: both; }
.signup-card p.muted { font-size: 14px; margin: 8px 0 0; }
.plan-choices { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
form label.plan-choice, .plan-choice { position: relative; display: flex; flex-direction: column; gap: 2px; margin: 0; padding: 16px; border: 1px solid var(--border); border-radius: 12px; color: var(--text); font-size: 13px; }
label.plan-choice { cursor: pointer; transition: border-color .15s, box-shadow .15s; }
label.plan-choice:hover { border-color: var(--accent); }
label.plan-choice:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); background: var(--sky); }
label.plan-choice:has(input:focus-visible) { outline: 2px solid var(--kube); outline-offset: 2px; }
.plan-choice input { position: absolute; top: 14px; right: 14px; margin: 0; accent-color: var(--accent); }
.plan-choice strong { font-size: 16px; color: var(--heading); padding-right: 20px; }
.plan-choice-price { font-weight: 700; color: var(--heading); font-size: 14px; margin-bottom: 4px; }
.plan-choice.closed { background: var(--bg-alt); border-style: dashed; opacity: .75; }
.plan-choice.closed strong, .plan-choice.closed .plan-choice-price { color: var(--muted); }
.password-field { display: flex; gap: 8px; align-items: stretch; margin-top: 4px; }
form .password-field input:not([type="radio"]) { margin-top: 0; flex: 1; min-width: 0; }
.password-toggle { flex: none; }
form label.signup-terms { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--text); margin: 20px 0; }
form label.signup-terms input:not([type="radio"]) { display: inline-block; flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--accent); }
.signup-submit { width: 100%; padding-block: 14px; font-size: 16px; }
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--bg-alt); }
.auth-card { width: min(400px, 100%); background: var(--surface); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow-lg); padding: 32px; }
.auth-card h1 { font-size: 26px; margin: 16px 0 4px; }
.auth-card button { width: 100%; margin-top: 8px; }
@media (max-width: 860px) {
  .signup-shell { grid-template-columns: 1fr; gap: 24px; padding-top: 16px; }
  .signup-aside { position: static; }
  .signup-aside ul, .signup-aside p { display: none; }
  .signup-aside h2 { margin-bottom: 0; }
}

/* Choix de la langue : <details>, sans script. */
.lang-menu { position: relative; }
.lang-menu summary { display: flex; align-items: center; gap: .4em; cursor: pointer; list-style: none; text-transform: uppercase; font-size: .85em; font-weight: 600; padding: .4em .6em; border: 1px solid #d8dee9; border-radius: 6px; }
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary::after { content: "▾"; font-size: .85em; opacity: .7; }
.lang-menu img { border-radius: 2px; box-shadow: 0 0 0 1px rgba(16, 40, 80, .15); vertical-align: -2px; }
.lang-menu ul { position: absolute; right: 0; top: calc(100% + 6px); margin: 0; padding: .4em 0; list-style: none; min-width: 10em; background: #fff; color: #102850; border: 1px solid #d8dee9; border-radius: 8px; box-shadow: 0 6px 20px rgba(16, 40, 80, .15); z-index: 20; }
.lang-menu li a { display: flex; align-items: center; gap: .6em; padding: .4em .9em; color: inherit; text-decoration: none; }
.lang-menu li a:hover { background: #eef2f8; }
.lang-menu a[aria-current] { font-weight: 700; }

/* Assistance et assistant du site. */
.chat { position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 30; }
.chat[hidden], .chat-panel[hidden], .chat-open[hidden] { display: none; }
.chat-panel { width: min(22rem, calc(100vw - 2.4rem)); background: #fff; color: #102850; border: 1px solid #d8dee9; border-radius: 12px; box-shadow: 0 10px 30px rgba(16, 40, 80, .2); display: flex; flex-direction: column; }
.chat-panel header { display: flex; justify-content: space-between; align-items: center; padding: .6em .9em; border-bottom: 1px solid #d8dee9; }
.chat-close { background: none; border: 0; font-size: 1.3em; cursor: pointer; color: inherit; }
.chat-log { max-height: 18rem; overflow-y: auto; padding: .7em .9em; }
.chat-log p { margin: 0 0 .6em; padding: .5em .7em; border-radius: 8px; font-size: .92em; }
.chat-bot { background: #eef2f8; }
.chat-me { background: #102850; color: #fff; margin-left: 2rem !important; }
.chat-form { display: flex; gap: .4em; padding: .6em .9em; border-top: 1px solid #d8dee9; }
.chat-form input { flex: 1; min-width: 0; }

/* Formulaire de contact : le champ piège reste hors de l'écran, pas masqué par display. */
.contact-form { display: grid; gap: 1rem; }
.contact-form textarea { min-height: 200px; line-height: 1.5; resize: vertical; }
.contact-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.chat-contact { display: inline-block; margin-bottom: .6em; font-size: .9em; }
