/*
 * Smarterie — page d'attente.
 * Fond au bleu du logo « Le point juste » (#4c5ae0), logo blanc. Tout le reste en blanc :
 * l'opacité seule fait la hiérarchie (le marine du logo n'offre que 2,9:1 sur ce bleu).
 */

:root {
  --bg: #4c5ae0;
  --ink: #ffffff;
  --muted: #ffffff;   /* 5,5:1 sur --bg : aucune marge pour l'atténuer */
  --line: #ffffff;    /* fils de l'animation (l'opacité est gérée au dessin) */
  --accent: #ffffff;  /* points du globe, repères */
  --font: "Helvetica Neue", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.6, 0.2, 1);
  color-scheme: light;
}

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

html {
  background: var(--bg);
  color: var(--ink);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Paysage : marque à gauche, sphère à droite. Portrait : sphère en haut, marque en bas. */
.page {
  --pad: clamp(24px, 4vw, 64px);
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: var(--pad);
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: clamp(20px, 2.4vw, 30px);
  padding-left: clamp(0px, 5vw, 96px);
  animation: arrive 1.8s 0.4s var(--ease) both;
}

.logo {
  margin: 0;
  line-height: 0;
}

.logo img {
  display: block;
  width: clamp(176px, 17vw, 280px);
  height: auto;
}

.caption {
  display: inline-flex;
  align-items: center;
  gap: 0.95em;
  margin: 0;
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted);
}

.caption::before {
  content: "";
  flex: none;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

/* Scène : SVG statique par défaut, remplacé par le canvas dès la première image dessinée. */
.stage {
  position: relative;
  width: 100%;
  height: min(100vh - 2 * var(--pad), 820px);
  animation: arrive 1.8s var(--ease) both;
}

@supports (height: 1svh) {
  .stage {
    height: min(100svh - 2 * var(--pad), 820px);
  }
}

.stage > canvas,
.stage > svg {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.stage > svg {
  color: var(--line);
  overflow: visible;
}

/* Repli généré par tools/fallback-svg.mjs : traits en pixels CSS, comme sur le canvas. */
.stage > svg path {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.stage.is-live > svg {
  display: none;
}

@media (max-aspect-ratio: 1/1) {
  .page {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) auto;
    align-items: stretch;
    padding-bottom: clamp(32px, 7vh, 72px);
  }

  .stage {
    order: -1;
    height: auto;
    min-height: 260px;
  }

  .brand {
    padding-left: 4px;
  }
}

@keyframes arrive {
  from {
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .stage,
  .brand {
    animation: none;
  }
}
