/* Prisma (séminaires PR2I-BT) — feuille de style unique (landing + salle).
   Charte : bleu Reflex UE/Interreg #003399 (clair) et #9faee5 (sombre) en accent unique,
   jaune #ffcc00 en touche seulement. Voir audit_saas/09_charte_graphique.md.
   Direction : « la lumière qui se sépare » — une voix entre dans un prisme, deux langues en
   sortent. Scènes sombres (hero, appel final, salle) ; le reste suit le thème du système. */

/* Police hébergée avec le site (pas d'appel à Google Fonts) — licence OFL dans fonts/OFL.txt */
@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin-ext.woff2) format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}
@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin.woff2) format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ───────────────────────── Jetons ───────────────────────── */
:root {
  --bg: #f5f7fc;
  --bg-2: #ffffff;
  --surface: #ffffff;
  --surface-2: #eef2fa;
  --fg: #0a1a33;
  --fg-muted: #44546b;
  --fg-soft: #5d6c82;
  --line: rgb(10 26 51 / 0.11);
  --line-strong: rgb(10 26 51 / 0.24);
  --input-bg: #ffffff;
  --input-line: #8193ab;
  --primary: #003399;
  --primary-fg: #ffffff;
  --primary-hover: #1f4fc2;
  --primary-soft: rgb(0 51 153 / 0.08);
  --beam: #3557ff;
  --sun: #ffcc00;
  --sun-ink: #7a5600;
  --ring: #003399;
  --ok: #1a7f37;
  --warn: #8a5a00;
  --bad: #b42318;
  --glass-bg: linear-gradient(180deg, rgb(255 255 255 / 0.85), rgb(255 255 255 / 0.62));
  --glass-line: rgb(10 26 51 / 0.12);
  --glass-hi: rgb(255 255 255 / 0.9);
  --glass-fg: #0a1a33;
  --shadow-lg: 0 40px 90px -40px rgb(0 32 96 / 0.45), 0 12px 30px -18px rgb(0 32 96 / 0.25);
  --shadow-md: 0 18px 40px -24px rgb(0 32 96 / 0.4);
  --led-dot: #3557ff;
  --led-hot: #003399;
  --led-warm: #c89400;

  --radius-s: 10px;
  --radius: 16px;
  --radius-l: 24px;
  --radius-xl: 32px;
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.4, 0.64, 1);
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 68px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #050f22;
    --bg-2: #081733;
    --surface: #0a1a38;
    --surface-2: #10244a;
    --fg: #eef3fb;
    --fg-muted: #b4c2d6;
    --fg-soft: #9aabc4;
    --line: rgb(159 174 229 / 0.14);
    --line-strong: rgb(159 174 229 / 0.3);
    --input-bg: #06132b;
    --input-line: #5a73a8;
    --primary: #9faee5;
    --primary-fg: #06122a;
    --primary-hover: #c3ccf0;
    --primary-soft: rgb(159 174 229 / 0.1);
    --beam: #9faee5;
    --sun-ink: #ffd24d;
    --ring: #ffd24d;
    --ok: #4ade80;
    --warn: #fbbf24;
    --bad: #ff8a80;
    --glass-bg: linear-gradient(180deg, rgb(255 255 255 / 0.1), rgb(255 255 255 / 0.03));
    --glass-line: rgb(255 255 255 / 0.16);
    --glass-hi: rgb(255 255 255 / 0.28);
    --glass-fg: #eef3fb;
    --shadow-lg: 0 40px 90px -40px rgb(0 0 0 / 0.8), 0 12px 30px -18px rgb(0 0 0 / 0.6);
    --shadow-md: 0 18px 40px -24px rgb(0 0 0 / 0.7);
    --led-dot: #9faee5;
    --led-hot: #ffffff;
    --led-warm: #ffcc00;
    color-scheme: dark;
  }
}
/* Scènes sombres : mêmes jetons quel que soit le thème (hero, appel final, salle, écran de fin). */
.on-dark,
.hero,
.final-cta,
.demo-screen,
.led-board,
.showcase-screen,
body.room-page {
  --bg: #050f22;
  --surface: #0a1a38;
  --surface-2: #10244a;
  --fg: #eef3fb;
  --fg-muted: #b8c5da;
  --fg-soft: #9aabc4;
  --line: rgb(159 174 229 / 0.14);
  --line-strong: rgb(159 174 229 / 0.3);
  --input-bg: #06132b;
  --input-line: #5a73a8;
  --primary: #9faee5;
  --primary-fg: #06122a;
  --primary-hover: #c3ccf0;
  --primary-soft: rgb(159 174 229 / 0.12);
  --beam: #9faee5;
  --sun-ink: #ffd24d;
  --ring: #ffd24d;
  --ok: #4ade80;
  --warn: #fbbf24;
  --bad: #ff8a80;
  --glass-bg: linear-gradient(180deg, rgb(255 255 255 / 0.12), rgb(255 255 255 / 0.03));
  --glass-line: rgb(255 255 255 / 0.17);
  --glass-hi: rgb(255 255 255 / 0.32);
  --glass-fg: #eef3fb;
  --led-dot: #9faee5;
  --led-hot: #ffffff;
  --led-warm: #ffcc00;
  color-scheme: dark;
  color: var(--fg);
}

/* ───────────────────────── Base ───────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
}
html {
  scroll-padding-top: calc(var(--header-h) + 16px);
}
body {
  background: var(--bg);
  color: var(--fg);
  font-family:
    "Atkinson Hyperlegible Next",
    ui-sans-serif,
    system-ui,
    -apple-system,
    "Segoe UI",
    sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100dvh;
}
h1,
h2,
h3 {
  text-wrap: balance;
}
p {
  text-wrap: pretty;
}
a {
  color: inherit;
}
:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 3px;
  border-radius: 6px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.skip {
  position: absolute;
  left: 8px;
  top: -60px;
  background: var(--sun);
  color: #0a1a33;
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 700;
  z-index: 100;
}
.skip:focus {
  top: 8px;
}
[hidden] {
  display: none !important;
}
.icon {
  width: 20px;
  height: 20px;
  flex: none;
  fill: currentColor;
}

/* ───────────────────────── Boutons ───────────────────────── */
.btn {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--fg);
  font: inherit;
  font-weight: 650;
  font-size: 0.9375rem;
  line-height: 1.1;
  text-decoration: none;
  cursor: pointer;
  overflow: hidden;
  transition:
    transform 220ms var(--ease-out),
    background-color 200ms var(--ease-out),
    border-color 200ms var(--ease-out),
    box-shadow 260ms var(--ease-out),
    color 200ms var(--ease-out);
}
.btn:active:not(:disabled) {
  transform: translateY(1px) scale(0.985);
}
.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.btn-sm {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.875rem;
}
.btn-lg {
  width: 100%;
  min-height: 54px;
  font-size: 1.0625rem;
}
.btn-cta {
  min-height: 54px;
  padding: 0 24px;
  font-size: 1rem;
}
.btn-cta .icon {
  width: 18px;
  height: 18px;
  transition: transform 260ms var(--ease-spring);
}
.btn-cta:hover .icon:last-child {
  transform: translateX(3px);
}
/* Bouton principal : plein, avec un reflet qui balaie la surface au survol. */
.btn-primary,
.btn-accent {
  background: var(--primary);
  color: var(--primary-fg);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.25),
    0 10px 30px -12px color-mix(in srgb, var(--primary) 70%, transparent);
}
.btn-primary:hover:not(:disabled),
.btn-accent:hover:not(:disabled) {
  background: var(--primary-hover);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.3),
    0 16px 40px -14px color-mix(in srgb, var(--primary) 85%, transparent);
}
/* « Verre liquide » : surface translucide, flou d'arrière-plan, filet clair en haut. */
.btn-glass {
  background: var(--glass-bg);
  border-color: var(--glass-line);
  color: var(--glass-fg);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  backdrop-filter: blur(14px) saturate(160%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    inset 0 -1px 0 rgb(255 255 255 / 0.04),
    0 10px 30px -16px rgb(0 0 0 / 0.45);
}
.btn-glass:hover:not(:disabled) {
  border-color: color-mix(in srgb, var(--glass-line) 50%, var(--fg) 30%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 14px 36px -16px rgb(0 0 0 / 0.5);
}
.btn-outline {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--fg);
}
.btn-outline:hover:not(:disabled) {
  border-color: var(--primary);
  background: var(--primary-soft);
}
.btn-ghost {
  background: transparent;
  color: var(--fg);
}
.btn-ghost:hover:not(:disabled) {
  background: var(--primary-soft);
}
.btn-danger {
  background: #c4271a;
  color: #fff;
}
.btn-danger:hover:not(:disabled) {
  background: #db3626;
}
.spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
}
.btn[aria-busy="true"] {
  cursor: progress;
  opacity: 0.85;
}
.btn[aria-busy="true"] .spinner {
  display: inline-block;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ───────────────────────── En-tête ───────────────────────── */
.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding: 10px var(--gutter) 0;
  color: #eef3fb;
  transition: color 300ms var(--ease-out);
}
.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  height: calc(var(--header-h) - 10px);
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 10px 0 16px;
  border: 1px solid transparent;
  border-radius: 999px;
  transition:
    background-color 300ms var(--ease-out),
    border-color 300ms var(--ease-out),
    box-shadow 300ms var(--ease-out);
}
/* Sur le hero : verre sombre, pour que le texte qui défile dessous ne se mêle pas au menu. */
.header:not(.scrolled) .header-inner {
  background: rgb(3 10 26 / 0.32);
  border-color: rgb(255 255 255 / 0.08);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
/* Hors du hero, la barre devient une pastille de verre. */
.header.scrolled {
  color: var(--fg);
}
.header.scrolled .header-inner {
  background: color-mix(in srgb, var(--bg-2) 78%, transparent);
  border-color: var(--line);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  backdrop-filter: blur(16px) saturate(160%);
  box-shadow: var(--shadow-md);
}
.header:not(.scrolled) .btn-glass {
  --glass-bg: linear-gradient(180deg, rgb(255 255 255 / 0.12), rgb(255 255 255 / 0.03));
  --glass-line: rgb(255 255 255 / 0.2);
  --glass-hi: rgb(255 255 255 / 0.3);
  --glass-fg: #eef3fb;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  font-weight: 750;
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
}
.brand-mark {
  width: 28px;
  height: 28px;
  flex: none;
  stroke: currentColor;
}
.brand-rays {
  stroke: var(--sun);
}
/* Navigation : liens vers les pages de présentation. Grand écran : en ligne dans la barre ;
   mobile : bouton « Menu » qui ouvre un panneau sous la barre (site-nav.js). */
.header-inner {
  position: relative;
}
.nav-links {
  display: none;
  gap: 4px;
}
.nav-links a {
  position: relative;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  opacity: 0.85;
  transition:
    background-color 200ms var(--ease-out),
    opacity 200ms var(--ease-out);
}
.nav-links a:hover {
  opacity: 1;
  background: color-mix(in srgb, currentColor 10%, transparent);
}
/* Page courante : pastille pleine et trait jaune, rappel du filet du prisme. */
.nav-links a[aria-current="page"] {
  opacity: 1;
  background: color-mix(in srgb, currentColor 12%, transparent);
}
.nav-links a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 3px;
  width: 16px;
  height: 2px;
  margin-left: -8px;
  border-radius: 2px;
  background: var(--sun);
}
.nav-links .nav-extra {
  display: none;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-toggle {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid color-mix(in srgb, currentColor 22%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, currentColor 6%, transparent);
  color: inherit;
  cursor: pointer;
}
.nav-toggle:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}
.nav-toggle-bars {
  display: grid;
  gap: 5px;
  width: 18px;
}
.nav-toggle-bars span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 300ms var(--ease-out);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:first-child {
  transform: translateY(3.5px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}
@media (max-width: 959px) {
  .nav-links.open {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    display: grid;
    gap: 2px;
    padding: 8px;
    border-radius: 24px;
    border: 1px solid rgb(255 255 255 / 0.1);
    /* Opaque : un flou d'arrière-plan ne fonctionne pas dans la barre, déjà floutée. */
    background: #061229;
    box-shadow: 0 30px 60px -24px rgb(0 0 0 / 0.7);
    color: #eef3fb;
  }
  .nav-links.open a {
    padding: 14px 16px;
    border-radius: 16px;
    font-size: 1.0625rem;
  }
  .nav-links.open a[aria-current="page"]::after {
    left: auto;
    right: 18px;
    bottom: 50%;
    width: 8px;
    height: 8px;
    margin: 0 0 -4px;
    border-radius: 50%;
  }
  .nav-links.open .nav-extra {
    display: block;
    margin-top: 6px;
    border-top: 1px solid rgb(255 255 255 / 0.1);
    border-radius: 0 0 16px 16px;
  }
}
@media (prefers-reduced-motion: no-preference) and (max-width: 959px) {
  .nav-links.open {
    animation: nav-drop 260ms var(--ease-out);
  }
  @keyframes nav-drop {
    from {
      opacity: 0;
      transform: translateY(-8px);
    }
  }
}
@media (min-width: 960px) {
  .nav-links {
    display: flex;
  }
  .nav-toggle {
    display: none;
  }
}
/* Petits écrans : la marque se réduit au logo pour laisser la place à la langue et au menu. */
@media (max-width: 400px) {
  .header .brand span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .header-actions {
    gap: 6px;
  }
}
/* Sélecteur de langue : une pastille claire glisse sous la langue choisie (data-active, posé
   par i18n.js). Deux boutons de même largeur, cibles de 44 px de haut au doigt. */
.lang-switch {
  position: relative;
  isolation: isolate;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, currentColor 22%, transparent);
  background: color-mix(in srgb, currentColor 6%, transparent);
}
.lang-switch::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 3px;
  bottom: 3px;
  left: 3px;
  width: calc(50% - 3px);
  border-radius: 999px;
  background: linear-gradient(160deg, #ffffff, #dfe5fa 90%);
  box-shadow:
    inset 0 0 10px rgb(255 255 255 / 0.7),
    0 2px 8px -2px rgb(0 0 0 / 0.35);
  transition: transform 420ms var(--ease-spring);
}
.lang-switch[data-active="en"]::before {
  transform: translateX(100%);
}
.lang-switch button {
  min-width: 42px;
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  opacity: 0.72;
  transition:
    opacity 300ms var(--ease-out),
    color 300ms var(--ease-out);
}
.lang-switch button[aria-pressed="true"] {
  opacity: 1;
  color: #06122a;
}
.lang-switch button:hover {
  opacity: 1;
}
.lang-switch button:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}
/* Sans script, aucune langue n'est marquée : pas de pastille. */
.lang-switch:not([data-active])::before {
  display: none;
}
@media (pointer: coarse) {
  .lang-switch button {
    min-height: 40px;
  }
}

/* ───────────────────────── Révélations ───────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    filter: blur(8px);
    transition:
      opacity 900ms var(--ease-out),
      transform 900ms var(--ease-out),
      filter 900ms var(--ease-out);
  }
  .js [data-reveal].revealed {
    opacity: 1;
    transform: none;
    filter: none;
  }
  .js [data-stagger] > * {
    opacity: 0;
    transform: translateY(18px);
    transition:
      opacity 700ms var(--ease-out) var(--stagger, 0ms),
      transform 700ms var(--ease-out) var(--stagger, 0ms);
  }
  .js [data-stagger].revealed > * {
    opacity: 1;
    transform: none;
  }
  /* Entrée du hero : chaque bloc monte et se précise, en décalé. */
  .rise {
    opacity: 0;
    transform: translateY(14px);
    filter: blur(6px);
    animation: rise 1s var(--ease-out) forwards;
  }
  .hero-copy > .rise:nth-child(2) {
    animation-delay: 0.1s;
  }
  .hero-copy > .rise:nth-child(3) {
    animation-delay: 0.22s;
  }
  .hero-copy > .rise:nth-child(4) {
    animation-delay: 0.32s;
  }
  .hero-copy > .rise:nth-child(5) {
    animation-delay: 0.42s;
  }
  .hero-copy > .rise:nth-child(6) {
    animation-delay: 0.52s;
  }
}
@keyframes rise {
  to {
    opacity: 1;
    transform: none;
    filter: none;
  }
}

/* ───────────────────────── Hero ───────────────────────── */
.landing {
  display: flex;
  flex-direction: column;
}
.hero {
  position: relative;
  isolation: isolate;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(60% 70% at 72% 50%, rgb(5 15 48 / 0.9), transparent 70%),
    linear-gradient(180deg, #071330, #030b1c);
  padding: calc(var(--header-h) + 32px) var(--gutter) 96px;
}
/* Le bas du hero se fond dans la page : un lever de jour en thème clair. */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 140px;
  z-index: 1;
  background: linear-gradient(180deg, transparent, var(--page-bg, #050f22));
  pointer-events: none;
}
:root {
  --page-bg: #f5f7fc;
}
@media (prefers-color-scheme: dark) {
  :root {
    --page-bg: #050f22;
  }
}
.hero-stage {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0;
  transition: opacity 1.6s ease 0.2s;
}
.hero-stage.ready {
  opacity: 1;
}
.hero-stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
/* Avec WebGL, la lumière n'est qu'une texture : seul le canvas 3D s'affiche. */
.hero-stage:not(.no-gl) #prism-fx {
  visibility: hidden;
}
.hero-stage.no-gl #prism-gl {
  display: none;
}
.hero-stage.no-gl #prism-fx {
  mix-blend-mode: screen;
}
.hero-copy {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
}
.hero-copy > * {
  max-width: 640px;
}
/* Voile sombre sous le texte : la lumière passe derrière sans gêner la lecture. */
.hero-copy::before {
  content: "";
  position: absolute;
  inset: -10% auto -10% -20%;
  width: min(820px, 120%);
  z-index: -1;
  background: radial-gradient(closest-side, rgb(3 10 26 / 0.78), transparent);
  pointer-events: none;
}
.hero h1 {
  margin: 0;
  font-size: clamp(2.6rem, 5.6vw, 5.1rem);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.035em;
  color: #fff;
}
/* Le titre dans l'autre langue, comme un sous-titre : un simple filet, sans encadré. */
.title-translation {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin: 22px 0 0;
  padding-left: 14px;
  border-left: 2px solid var(--primary);
  color: #dfe5fa;
  font-size: clamp(1rem, 1.5vw, 1.1875rem);
}
.lang-pair {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--fg-soft);
}
.intro {
  margin: 22px 0 0;
  color: var(--fg-muted);
  font-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
  line-height: 1.6;
}
.cta-pair {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.territories {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 36px 0 0;
  padding: 0;
  list-style: none;
  color: var(--fg-soft);
  font-size: 0.875rem;
  font-weight: 600;
}
.territories li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
@media (max-width: 859px) {
  .hero {
    justify-content: flex-start;
    min-height: max(100svh, 760px);
    padding-bottom: 46svh;
  }
}

/* ───────────────────────── Sections ───────────────────────── */
.section {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: clamp(72px, 10vw, 136px) var(--gutter);
}
.section-head {
  max-width: 760px;
  margin-bottom: clamp(36px, 5vw, 64px);
}
.display {
  margin: 0;
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.lead {
  margin: 18px 0 0;
  color: var(--fg-muted);
  font-size: clamp(1.0625rem, 1.3vw, 1.1875rem);
  line-height: 1.6;
  max-width: 62ch;
}
.help {
  margin: 6px 0 0;
  color: var(--fg-muted);
  font-size: 0.875rem;
}
.error {
  margin: 6px 0 0;
  color: var(--bad);
  font-size: 0.9375rem;
  font-weight: 650;
}

.card {
  position: relative;
  isolation: isolate;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  padding: clamp(20px, 3vw, 36px);
  box-shadow: var(--shadow-lg);
}
.card h2 {
  margin: 0 0 24px;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
}
form {
  display: grid;
  gap: 20px;
}
.field {
  display: grid;
  gap: 8px;
  min-width: 0;
}
.field label {
  font-weight: 650;
  font-size: 0.9375rem;
}
.field .help,
.field .error {
  margin: 0;
}
input,
select,
textarea {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid var(--input-line);
  border-radius: 12px;
  background: var(--input-bg);
  color: var(--fg);
  font: inherit;
  font-size: 1rem;
  transition:
    border-color 180ms var(--ease-out),
    box-shadow 180ms var(--ease-out);
}
input::placeholder,
textarea::placeholder {
  color: var(--fg-soft);
  opacity: 1;
}
input:hover,
select:hover,
textarea:hover {
  border-color: var(--fg-muted);
}
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 28%, transparent);
}
select {
  appearance: none;
  padding-right: 40px;
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, currentColor 50%),
    linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position:
    calc(100% - 21px) 52%,
    calc(100% - 15px) 52%;
  background-size:
    6px 6px,
    6px 6px;
  background-repeat: no-repeat;
}
input[aria-invalid="true"] {
  border-color: var(--bad);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--bad) 18%, transparent);
}
.row-2 {
  display: grid;
  gap: 16px;
}
.lang-row {
  grid-template-columns: minmax(0, 1fr);
}
.lang-arrow {
  display: none;
}
@media (min-width: 480px) {
  .lang-row {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: end;
    gap: 10px;
  }
  .lang-arrow {
    display: grid;
    place-items: center;
    width: 38px;
    height: 50px;
    color: var(--primary);
  }
}
.input-icon {
  position: relative;
}
.input-icon > .icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--fg-soft);
  pointer-events: none;
}
.input-icon input {
  padding-left: 44px;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.field.locked .input-icon input {
  background: var(--surface-2);
  border-style: dashed;
}
.field.locked .input-icon > .icon {
  color: var(--primary);
}
.code-edit {
  justify-self: start;
  padding: 2px 0;
  border: 0;
  background: none;
  color: var(--primary);
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.device-check {
  display: grid;
  gap: 12px;
}
.device-check .btn {
  justify-self: start;
  border: 1px solid var(--line-strong);
}
.preview {
  display: grid;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.preview video {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  background: #050f22;
  object-fit: cover;
  transform: scaleX(-1);
}
.preview-meter {
  display: grid;
  gap: 6px;
}
.preview-meter .help {
  margin: 0;
}
.meter {
  height: 10px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--line);
  overflow: hidden;
}
.meter > span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--beam), var(--primary) 60%, var(--sun));
  transition: width 80ms linear;
}
.reassure {
  text-align: center;
}
.or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0;
  color: var(--fg-soft);
  font-size: 0.875rem;
  font-weight: 650;
}
.or::before,
.or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.invite {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding: 18px;
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--ok) 8%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent);
  animation: pop-in 380ms var(--ease-spring);
}
@keyframes pop-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
}
.invite-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-weight: 750;
}
.invite-title .icon {
  color: var(--ok);
}
.invite label {
  font-weight: 650;
  font-size: 0.9375rem;
}
.invite .help {
  margin: 0;
}
.copy-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.copy-row input {
  flex: 1 1 220px;
  min-height: 46px;
  font-size: 0.9375rem;
}
.copy-row .btn {
  min-height: 46px;
}
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 60;
  max-width: calc(100% - 32px);
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--glass-line);
  background: color-mix(in srgb, var(--bg-2) 85%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-md);
  font-weight: 650;
  opacity: 0;
  transform: translate(-50%, 16px);
  pointer-events: none;
  transition:
    opacity 260ms var(--ease-out),
    transform 260ms var(--ease-out);
}
.toast:empty {
  visibility: hidden;
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ───────────────────────── Accès à la séance (landing) ───────────────────────── */
.join-teaser {
  display: grid;
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  padding-bottom: 0;
}
@media (min-width: 960px) {
  .join-teaser {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  }
}
.join-teaser-side {
  display: grid;
  gap: 28px;
  padding: clamp(24px, 3vw, 36px);
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.join-teaser-side .cta-pair {
  margin-top: 0;
}
.mini-steps {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.mini-steps li {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 650;
  font-size: 1.0625rem;
}
.mini-num {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

/* ───────────────────────── Démo : salle de visio miniature ───────────────────────── */
.demo {
  margin: 0;
}
.demo-screen {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 14px;
  min-height: clamp(420px, 46vw, 560px);
  padding: clamp(14px, 2vw, 22px);
  border-radius: var(--radius-xl);
  border: 1px solid rgb(159 174 229 / 0.18);
  background:
    radial-gradient(80% 60% at 20% 0%, rgb(53 87 255 / 0.18), transparent 70%),
    radial-gradient(60% 50% at 100% 100%, rgb(255 204 0 / 0.06), transparent 70%), #050f22;
  box-shadow: var(--shadow-lg);
}
.demo-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.demo-live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.06);
  border: 1px solid var(--line);
  font-size: 0.8125rem;
  font-weight: 700;
}
.demo-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff5a4f;
  box-shadow: 0 0 10px #ff5a4f;
}
@media (prefers-reduced-motion: no-preference) {
  .demo-dot {
    animation: breathe 1.6s ease-in-out infinite;
  }
}
.demo-code {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--fg-soft);
}
.demo-tiles {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 10px;
  min-height: 0;
}
.demo-tile {
  position: relative;
  display: grid;
  place-items: center;
  border-radius: 18px;
  border: 1px solid rgb(255 255 255 / 0.06);
  overflow: hidden;
  background: linear-gradient(160deg, #10244a, #081733);
}
.demo-tile span {
  display: grid;
  place-items: center;
  width: clamp(48px, 6vw, 76px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: linear-gradient(160deg, #2a4a8f, #142a57);
  font-weight: 800;
  font-size: clamp(1rem, 1.6vw, 1.4rem);
  color: #dfe5fa;
}
.demo-tile-a {
  grid-row: 1 / span 2;
  background:
    radial-gradient(70% 60% at 50% 40%, rgb(53 87 255 / 0.25), transparent 70%),
    linear-gradient(160deg, #10244a, #081733);
  box-shadow: inset 0 0 0 2px rgb(159 174 229 / 0.65);
}
@media (prefers-reduced-motion: no-preference) {
  .demo-tile-a span {
    animation: speak 1.8s ease-in-out infinite;
  }
}
@keyframes speak {
  50% {
    box-shadow: 0 0 0 10px rgb(159 174 229 / 0.12);
  }
}
.demo-caption {
  display: grid;
  gap: 6px;
  padding: 14px 18px 16px;
  border-radius: 18px;
  border: 1px solid var(--glass-line);
  background: rgb(3 10 26 / 0.72);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 var(--glass-hi);
  transition:
    opacity 340ms var(--ease-out),
    transform 340ms var(--ease-out);
}
.demo-caption.leaving {
  opacity: 0;
  transform: translateY(8px);
}
.demo-who {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 0.875rem;
}
.demo-name {
  font-weight: 800;
  color: var(--primary);
}
.demo-place {
  color: var(--fg-soft);
}
.demo-source {
  margin: 0;
  min-height: 1.4em;
  font-size: clamp(1.0625rem, 1.6vw, 1.3125rem);
  color: var(--fg-muted);
  font-style: italic;
}
.demo-source.typing::after {
  content: "";
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-left: 4px;
  vertical-align: -0.15em;
  background: var(--sun);
}
@media (prefers-reduced-motion: no-preference) {
  .demo-source.typing::after {
    animation: blink 0.9s steps(1) infinite;
  }
}
@keyframes blink {
  50% {
    opacity: 0;
  }
}
.demo-target {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0;
  font-size: clamp(1.1875rem, 2vw, 1.625rem);
  font-weight: 650;
  line-height: 1.3;
  opacity: 0;
  transform: translateY(6px);
  filter: blur(4px);
  transition:
    opacity 500ms var(--ease-out),
    transform 500ms var(--ease-out),
    filter 500ms var(--ease-out);
}
.demo-caption.translated .demo-target {
  opacity: 1;
  transform: none;
  filter: none;
}
.demo-pair {
  flex: none;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgb(255 204 0 / 0.12);
  color: #ffe27a;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  font-style: normal;
}
.demo-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}
.demo-foot .help {
  margin: 0;
}
.demo-toggle {
  border: 1px solid var(--line-strong);
}
.demo-toggle .icon {
  width: 18px;
  height: 18px;
}
@media (max-width: 600px) {
  .demo-tiles {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1.3fr 1fr;
  }
  .demo-tile-a {
    grid-row: auto;
    grid-column: 1 / -1;
  }
}

/* ───────────────────────── Étapes ───────────────────────── */
.steps {
  position: relative;
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
@media (min-width: 860px) {
  .steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
  }
  /* Rappel du hero : un filet de lumière court le long des trois étapes, et un paquet de
     lumière le parcourt au même rythme que les « phrases » du prisme. */
  .steps::before,
  .steps::after {
    content: "";
    position: absolute;
    top: -1px;
    z-index: 2;
    height: 1px;
    pointer-events: none;
  }
  .steps::before {
    left: 4%;
    right: 4%;
    background: linear-gradient(
      90deg,
      transparent,
      var(--line-strong) 15%,
      var(--line-strong) 85%,
      transparent
    );
  }
  .steps::after {
    left: 0;
    width: 160px;
    height: 2px;
    top: -1.5px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, var(--beam), #fff 70%, var(--sun));
    box-shadow:
      0 0 12px var(--beam),
      0 0 24px color-mix(in srgb, var(--beam) 60%, transparent);
    opacity: 0;
  }
}
@media (min-width: 860px) and (prefers-reduced-motion: no-preference) {
  .steps.revealed::after {
    animation: travel 6.5s var(--ease-out) 0.8s infinite;
  }
}
@keyframes travel {
  0% {
    left: -160px;
    opacity: 0;
  }
  8% {
    opacity: 1;
  }
  38% {
    opacity: 1;
  }
  45%,
  100% {
    left: 100%;
    opacity: 0;
  }
}
.steps li {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 28px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
  counter-increment: step;
  transition:
    border-color 300ms var(--ease-out),
    opacity 700ms var(--ease-out) var(--stagger, 0ms),
    transform 700ms var(--ease-out) var(--stagger, 0ms);
}
.steps li:hover {
  border-color: var(--line-strong);
}
.step-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 12px;
  border-radius: 14px;
  background: var(--primary);
  color: var(--primary-fg);
  box-shadow: 0 8px 24px -10px var(--primary);
}
.steps strong {
  font-size: 1.1875rem;
  letter-spacing: -0.01em;
}
.steps li > span:last-child {
  color: var(--fg-muted);
}

/* ───────────────────────── Fonctionnalités (bento + projecteur) ───────────────────────── */
.features {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 720px) {
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1000px) {
  .features {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .feature-wide:first-child {
    grid-column: span 2;
  }
  .feature-wide:last-child {
    grid-column: span 3;
  }
}
.feature {
  position: relative;
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 220px;
  padding: 28px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
  transition:
    border-color 300ms var(--ease-out),
    opacity 700ms var(--ease-out) var(--stagger, 0ms),
    transform 700ms var(--ease-out) var(--stagger, 0ms);
}
.feature:hover {
  border-color: color-mix(in srgb, var(--primary) 40%, var(--line));
}
.feature-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 14px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent);
  background: var(--primary-soft);
  color: var(--primary);
}
.feature-icon .icon {
  width: 24px;
  height: 24px;
}
.feature h3 {
  margin: 0;
  font-size: 1.25rem;
  letter-spacing: -0.015em;
}
.feature p {
  margin: 0;
  color: var(--fg-muted);
  max-width: 52ch;
}

/* ───────────────────────── Écran de salle : panneau LED + maquette ───────────────────────── */
.led-board {
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  border-radius: var(--radius-xl);
  border: 1px solid rgb(159 174 229 / 0.18);
  background: radial-gradient(80% 90% at 50% 50%, rgb(16 36 74 / 0.9), transparent), #040c1c;
  box-shadow: var(--shadow-lg);
}
#led-canvas {
  display: block;
  width: 100%;
  height: clamp(170px, 24vw, 300px);
}
.led-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 14px 22px 18px;
  border-top: 1px solid var(--line);
  color: var(--fg-muted);
  font-size: 0.875rem;
}
.led-pair {
  padding: 3px 10px;
  border-radius: 999px;
  background: rgb(255 204 0 / 0.12);
  color: #ffe27a;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
}
.showcase-screen {
  padding: clamp(20px, 3.5vw, 44px);
  border-radius: var(--radius-xl);
  border: 1px solid rgb(159 174 229 / 0.18);
  background: #040c1c;
  box-shadow: var(--shadow-lg);
}
.showcase-cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px clamp(20px, 4vw, 56px);
  font-size: clamp(1rem, 2.2vw, 1.75rem);
  line-height: 1.3;
}
.showcase-head {
  margin: 0;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary);
  color: var(--primary);
  font-size: 0.55em;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.showcase-cell span {
  color: var(--fg-soft);
  font-size: 0.5em;
  font-weight: 700;
}
.showcase-cell p {
  margin: 4px 0 0;
  font-weight: 600;
}
.showcase-cell.past {
  opacity: 0.5;
}

/* ───────────────────────── Chiffres ───────────────────────── */
.stats-section {
  padding-top: 0;
}
.stats {
  display: grid;
  gap: 0;
  margin: 0;
  border-top: 1px solid var(--line);
}
@media (min-width: 720px) {
  .stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.stat {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  gap: 8px;
  padding: 28px 20px 24px 0;
  border-bottom: 1px solid var(--line);
}
.stat dd {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 4px;
}
.stat-value {
  font-size: clamp(3rem, 6vw, 4.5rem);
  font-weight: 750;
  line-height: 1;
  letter-spacing: -0.045em;
  font-variant-numeric: tabular-nums;
  color: var(--fg);
}
.stat-unit {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
}
.stat dt {
  color: var(--fg-muted);
  max-width: 26ch;
}
.stats-note {
  margin-top: 16px;
}

/* ───────────────────────── Questions ───────────────────────── */
.faq {
  display: grid;
  gap: 10px;
  max-width: 860px;
}
.faq-item {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  transition:
    border-color 250ms var(--ease-out),
    opacity 700ms var(--ease-out) var(--stagger, 0ms),
    transform 700ms var(--ease-out) var(--stagger, 0ms);
}
.faq-item[open] {
  border-color: color-mix(in srgb, var(--primary) 40%, var(--line));
}
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
  font-size: 1.0625rem;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  border-radius: inherit;
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary .icon {
  color: var(--primary);
  transition: transform 300ms var(--ease-spring);
}
.faq-item[open] summary .icon {
  transform: rotate(45deg);
}
.faq-item p {
  margin: 0;
  padding: 0 22px 22px;
  color: var(--fg-muted);
  max-width: 68ch;
}
@media (prefers-reduced-motion: no-preference) {
  .faq-item[open] p {
    animation: fade-up 360ms var(--ease-out);
  }
}
@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
}

/* ───────────────────────── Appel final (brume) ───────────────────────── */
.final-cta {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  width: calc(100% - 2 * var(--gutter));
  max-width: 1240px;
  margin: 0 auto clamp(48px, 7vw, 96px);
  padding: clamp(72px, 10vw, 128px) var(--gutter);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(70% 80% at 50% 0%, rgb(53 87 255 / 0.22), transparent 70%),
    linear-gradient(180deg, #071330, #030b1c);
  text-align: center;
}
.mist {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.final-inner {
  display: grid;
  justify-items: center;
}
.final-inner .lead {
  margin-inline: auto;
}
.final-inner .cta-pair {
  justify-content: center;
}

/* ───────────────────────── Pied de page ───────────────────────── */
body.home-page {
  overflow-x: clip;
}
.site-footer {
  border-top: 1px solid var(--line);
  padding: clamp(40px, 6vw, 64px) var(--gutter) calc(32px + env(safe-area-inset-bottom));
}
.site-footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  gap: 32px;
}
@media (min-width: 760px) {
  .site-footer-inner {
    grid-template-columns: minmax(0, 2fr) repeat(2, minmax(0, 1fr));
  }
}
.footer-brand {
  display: grid;
  gap: 10px;
  justify-items: start;
}
.footer-brand .brand {
  margin: 0;
}
.site-footer p {
  margin: 0;
  max-width: 44ch;
  color: var(--fg-muted);
  font-size: 0.9375rem;
}
.site-footer .footer-note {
  color: var(--fg-soft);
  font-size: 0.8125rem;
}
.footer-col h2 {
  margin: 0 0 12px;
  font-size: 0.8125rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.footer-col ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer-col a {
  display: inline-block;
  padding: 6px 0;
  color: var(--fg);
  text-decoration: none;
}
.footer-col a:hover {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ───────────────────────── Micro-animations 3D (motion.js) ───────────────────────── */
:root {
  --glare: rgb(53 87 255 / 0.1);
}
@media (prefers-color-scheme: dark) {
  :root {
    --glare: rgb(255 255 255 / 0.1);
  }
}
/* Cartes inclinables : le contenu flotte à des profondeurs différentes, un reflet de verre
   suit le pointeur. L'inclinaison ne s'applique qu'après l'apparition (.tilt-ready). */
[data-tilt] {
  transform-style: preserve-3d;
}
.js [data-tilt].tilt-ready {
  transform: perspective(var(--persp, 900px)) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition:
    transform 700ms var(--ease-out),
    border-color 300ms var(--ease-out);
}
.js [data-tilt].tilt-ready.tilting {
  transition:
    transform 140ms linear,
    border-color 300ms var(--ease-out);
}
[data-tilt]::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(
    380px circle at var(--gx, 50%) var(--gy, 0%),
    var(--glare),
    transparent 60%
  );
  opacity: 0;
  transition: opacity 400ms var(--ease-out);
}
[data-tilt].tilting::after {
  opacity: 1;
}
[data-tilt] .feature-icon,
[data-tilt] .step-icon,
[data-tilt] h3,
[data-tilt] strong {
  transition: transform 520ms var(--ease-spring);
}
[data-tilt].tilting .feature-icon,
[data-tilt].tilting .step-icon {
  transform: translateZ(30px);
}
[data-tilt].tilting h3,
[data-tilt].tilting strong {
  transform: translateZ(14px);
}
/* Redressement au défilement : l'écran se relève en perspective (--p de 0 à 1). */
.rise3d-on {
  transform: perspective(1600px) rotateX(calc((1 - var(--p, 1)) * 26deg))
    translateY(calc((1 - var(--p, 1)) * 48px)) scale(calc(0.94 + var(--p, 1) * 0.06));
  transform-origin: 50% 100%;
  opacity: calc(0.3 + var(--p, 1) * 0.7);
  will-change: transform;
}

/* Mini-prisme de l'appel final : rappel du hero, une voix entre, deux langues sortent. */
.mini-prism {
  display: block;
  width: min(260px, 72%);
  height: auto;
  margin: 0 auto 28px;
  overflow: visible;
  filter: drop-shadow(0 0 6px rgb(159 174 229 / 0.55));
}
@media (prefers-reduced-motion: no-preference) {
  .mini-prism {
    animation: sway 11s ease-in-out infinite;
  }
}
@keyframes sway {
  0%,
  100% {
    transform: perspective(700px) rotateY(-14deg) rotateX(6deg);
  }
  50% {
    transform: perspective(700px) rotateY(14deg) rotateX(-4deg);
  }
}
.mp-beam {
  fill: none;
  stroke-linecap: round;
  stroke-width: 2;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.mp-in {
  stroke: #fff;
}
.mp-mid {
  stroke: rgb(255 255 255 / 0.5);
}
.mp-a {
  stroke: #9faee5;
}
.mp-b {
  stroke: #ffcc00;
  stroke-width: 1.5;
}
.mp-glass {
  fill: rgb(159 174 229 / 0.08);
  stroke: url(#mp-glass);
  stroke-width: 1.5;
  stroke-linejoin: round;
}
.mp-pulse {
  fill: #fff;
  opacity: 0;
}
@media (prefers-reduced-motion: no-preference) {
  /* Les faisceaux se tracent à l'apparition, dans l'ordre du trajet de la lumière. */
  .js .final-inner .mp-beam {
    transition: stroke-dashoffset 700ms var(--ease-out);
  }
  .js .final-inner:not(.revealed) .mp-beam {
    stroke-dashoffset: 1;
  }
  .js .final-inner .mp-mid {
    transition-delay: 0.6s;
  }
  .js .final-inner .mp-a {
    transition-delay: 0.8s;
  }
  .js .final-inner .mp-b {
    transition-delay: 0.95s;
  }
  @supports (offset-path: path("M0 0")) {
    .mp-pulse {
      offset-rotate: 0deg;
    }
    .mp-pulse-a {
      offset-path: path("M48 0 L103 62 L139 65 L240 98");
    }
    .mp-pulse-b {
      offset-path: path("M48 0 L103 62 L139 65 L240 124");
    }
    .final-inner.revealed .mp-pulse {
      animation: mp-travel 6.5s ease-in-out 2s infinite;
    }
  }
}
@keyframes mp-travel {
  0% {
    offset-distance: 0%;
    opacity: 0;
  }
  6% {
    opacity: 1;
  }
  40% {
    opacity: 1;
  }
  48%,
  100% {
    offset-distance: 100%;
    opacity: 0;
  }
}

/* ───────────────────────── Page « Rejoindre » : écran d'avant-séance ───────────────────────── */
body.join-page {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background:
    radial-gradient(70% 55% at 25% 0%, rgb(53 87 255 / 0.16), transparent 70%),
    radial-gradient(40% 40% at 100% 100%, rgb(255 204 0 / 0.04), transparent 70%), #040b1c;
}
.join-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 16px var(--gutter);
}
.prejoin {
  position: relative;
  isolation: isolate;
  flex: 1;
  display: grid;
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(8px, 2vw, 28px) var(--gutter) 48px;
}
@media (min-width: 1000px) {
  .prejoin {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 460px);
    align-items: center;
  }
}
/* Sur mobile, le formulaire passe en premier : c'est l'action de la page. */
@media (max-width: 999px) {
  .prejoin .join-panel {
    order: -1;
  }
}
.prejoin > .mist {
  z-index: -1;
  opacity: 0.75;
}
.prejoin-stage {
  display: grid;
  gap: 16px;
}
.preview-tile {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border-radius: 28px;
  border: 1px solid rgb(255 255 255 / 0.08);
  background:
    radial-gradient(70% 60% at 50% 40%, rgb(53 87 255 / 0.18), transparent 70%),
    linear-gradient(160deg, #0d2042, #071431);
  box-shadow: var(--shadow-lg);
}
@media (max-width: 600px) {
  .preview-tile {
    aspect-ratio: 4 / 5;
  }
}
.preview-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  padding: 0 24px 96px;
  color: var(--fg-soft);
  text-align: center;
}
.preview-placeholder .avatar {
  width: clamp(84px, 9vw, 116px);
  height: clamp(84px, 9vw, 116px);
  font-size: clamp(1.8rem, 2.6vw, 2.5rem);
}
@media (prefers-reduced-motion: no-preference) {
  .preview-placeholder .avatar {
    animation: speak 3.2s ease-in-out infinite;
  }
}
.preview-hint {
  font-size: 0.9375rem;
}
/* L'aperçu caméra remplit la vignette ; le niveau du micro s'affiche dessus. */
.prejoin .preview {
  position: absolute;
  inset: 0;
  display: block;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #050f22;
}
.prejoin .preview video {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  border-radius: 0;
}
.prejoin .preview-meter {
  position: absolute;
  top: 14px;
  right: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgb(255 255 255 / 0.12);
  background: rgb(3 10 26 / 0.62);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: 0.8125rem;
  font-weight: 650;
}
.prejoin .meter {
  width: clamp(72px, 10vw, 120px);
  height: 8px;
  background: rgb(255 255 255 / 0.08);
}
/* Spécificité renforcée : .tile-label (salle) est déclaré plus bas avec bottom: 10px. */
.preview-tile .preview-label {
  top: 14px;
  bottom: auto;
}
.sample-caption {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  font-size: clamp(1rem, 1.6vw, 1.25rem);
  pointer-events: none;
}
.prejoin-stage .device-check {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
}
.prejoin-stage .device-check .help,
.prejoin-stage .device-check .error {
  margin: 0;
  flex: 1 1 240px;
}
.prejoin .join-panel {
  background: rgb(10 26 56 / 0.74);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
}
.join-panel h1 {
  margin: 0;
  font-size: clamp(1.6rem, 2.4vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.join-lead {
  margin: 10px 0 24px;
  color: var(--fg-muted);
}
.join-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 20px var(--gutter) calc(20px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  color: var(--fg-soft);
  font-size: 0.8125rem;
}
.join-footer p {
  margin: 0;
  flex: 1 1 280px;
}

/* Formulaire en trois étapes : une pastille numérotée par étape, reliées par un filet qui
   s'allume quand l'étape est remplie (rappel du faisceau du prisme). */
.join-steps {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}
.join-step {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 14px;
  padding-bottom: 20px;
}
.join-step:last-child {
  padding-bottom: 4px;
}
.join-step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14.5px;
  top: 34px;
  bottom: 4px;
  width: 1px;
  background: var(--line-strong);
  transition: background 400ms var(--ease-out);
}
.join-step[data-done]:not(:last-child)::after {
  background: linear-gradient(180deg, var(--primary), var(--sun));
}
.step-num {
  position: relative;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin-top: -3px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--surface-2);
  color: var(--fg-muted);
  font-size: 0.8125rem;
  font-weight: 800;
  transition:
    background-color 300ms var(--ease-out),
    border-color 300ms var(--ease-out),
    color 300ms var(--ease-out);
}
.step-num > * {
  grid-area: 1 / 1;
  transition:
    opacity 260ms var(--ease-out),
    transform 360ms var(--ease-spring);
}
.step-num .icon {
  width: 16px;
  height: 16px;
  opacity: 0;
  transform: scale(0.4);
}
.join-step[data-done] .step-num {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-fg);
  box-shadow: 0 0 16px -2px color-mix(in srgb, var(--primary) 70%, transparent);
}
.join-step[data-done] .step-num span {
  opacity: 0;
  transform: scale(0.4);
}
.join-step[data-done] .step-num .icon {
  opacity: 1;
  transform: none;
}
.join-step .lang-row {
  margin: 0;
}
/* Prêt à rejoindre : le bouton s'éclaire une fois, puis reste vif. */
#join-btn:not(.ready) {
  filter: saturate(0.75);
  opacity: 0.88;
}
@media (prefers-reduced-motion: no-preference) {
  #join-btn.ready {
    animation: ready-glow 900ms var(--ease-out);
  }
}
@keyframes ready-glow {
  40% {
    box-shadow:
      inset 0 1px 0 rgb(255 255 255 / 0.3),
      0 0 0 6px color-mix(in srgb, var(--primary) 30%, transparent),
      0 18px 46px -12px var(--primary);
  }
}
/* Organiser : une ligne discrète sous le formulaire. */
.host-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 8px;
  margin: 20px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--fg-muted);
  font-size: 0.9375rem;
}
.link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--primary);
  font: inherit;
  font-weight: 750;
  cursor: pointer;
}
.link-btn:hover {
  background: var(--primary-soft);
}
.link-btn .icon {
  width: 18px;
  height: 18px;
}
/* Colonnes alignées en haut ; l'aperçu reste visible pendant qu'on remplit (bureau). */
@media (min-width: 1000px) {
  .prejoin {
    align-items: start;
  }
  .prejoin-stage {
    position: sticky;
    top: 24px;
  }
}
.prejoin .join-panel {
  padding: clamp(20px, 2.4vw, 30px);
}
.prejoin .join-panel .join-lead {
  margin-bottom: 20px;
}
.prejoin .join-panel .reassure {
  margin: -6px 0 0;
}
.prejoin form {
  gap: 16px;
}
.prejoin .join-panel.rise {
  animation-delay: 0.12s;
}
/* Caméra coupée : un rai de lumière traverse lentement la vignette (rappel du prisme). */
.preview-tile::before {
  content: "";
  position: absolute;
  inset: -20% -40%;
  pointer-events: none;
  background: linear-gradient(
    105deg,
    transparent 42%,
    rgb(159 174 229 / 0.09) 48%,
    rgb(255 204 0 / 0.05) 50%,
    transparent 56%
  );
  transform: translateX(-30%);
}
@media (prefers-reduced-motion: no-preference) {
  .preview-tile::before {
    animation: tile-beam 9s ease-in-out infinite alternate;
  }
}
@keyframes tile-beam {
  to {
    transform: translateX(30%);
  }
}

/* Zone de texte (description de la séance, message d'invitation). */
textarea {
  padding: 12px 14px;
  line-height: 1.5;
  resize: vertical;
}
textarea[readonly] {
  background: var(--surface-2);
  font-size: 0.9375rem;
}
/* ───────────── Fiche de séance (organiser.html et rejoindre.html) ───────────── */
.stage-note {
  margin: 0;
  color: var(--fg-soft);
  font-size: 0.875rem;
}
.session-card {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 10px;
  padding: clamp(22px, 3vw, 34px);
  border-radius: 28px;
  border: 1px solid var(--glass-line);
  background:
    radial-gradient(80% 70% at 0% 0%, rgb(53 87 255 / 0.22), transparent 70%),
    radial-gradient(50% 60% at 100% 100%, rgb(255 204 0 / 0.06), transparent 70%),
    linear-gradient(160deg, #0d2042, #071431);
  box-shadow: var(--shadow-lg);
}
.session-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--sun));
}
.session-status {
  justify-self: start;
  margin: 0;
  padding: 3px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--fg-muted);
  font-size: 0.8125rem;
  font-weight: 750;
}
.session-card[data-state="live"] .session-status {
  border-color: rgb(74 222 128 / 0.45);
  color: var(--ok);
}
.session-card[data-state="ended"] .session-status {
  color: var(--fg-soft);
}
.session-title {
  margin: 0;
  font-size: clamp(1.6rem, 2.6vw, 2.25rem);
  line-height: 1.12;
  letter-spacing: -0.025em;
  overflow-wrap: anywhere;
}
.session-card.is-placeholder .session-title {
  color: var(--fg-soft);
}
.session-desc {
  margin: 0;
  color: var(--fg-muted);
  overflow-wrap: anywhere;
}
.session-meta {
  display: grid;
  gap: 10px;
  margin: 8px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.session-meta > div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 12px;
}
.session-meta dt {
  color: var(--fg-soft);
  font-size: 0.875rem;
}
.session-meta dd {
  margin: 0;
  font-weight: 650;
  overflow-wrap: anywhere;
}
.session-meta dd span[data-part="time"] {
  display: block;
  color: var(--fg-muted);
  font-weight: 550;
}
.session-code {
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}
/* Version compacte, en tête du formulaire « Rejoindre ». */
.session-card.compact {
  gap: 6px;
  padding: 18px 18px 16px;
  border-radius: 18px;
  box-shadow: none;
}
.session-card.compact .session-title {
  font-size: 1.25rem;
}
.session-card.compact .session-desc {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 0.9375rem;
}
.session-card.compact .session-meta {
  gap: 6px;
  margin-top: 4px;
  padding-top: 10px;
  font-size: 0.9375rem;
}
.session-card.compact .session-meta > div {
  grid-template-columns: 90px minmax(0, 1fr);
}
/* Page « Rejoindre » avec une fiche : elle prend le haut de la colonne de gauche (bureau) ou
   passe en tout premier (mobile), pour que le formulaire tienne à l'écran. */
@media (min-width: 1000px) {
  body.has-session .prejoin {
    grid-template-areas:
      "card panel"
      "stage panel";
    grid-template-rows: auto 1fr;
  }
  body.has-session .prejoin > .session-card {
    grid-area: card;
  }
  body.has-session .prejoin-stage {
    grid-area: stage;
    position: static;
  }
  body.has-session .prejoin .join-panel {
    grid-area: panel;
  }
}
@media (max-width: 999px) {
  .prejoin > .session-card {
    order: -2;
  }
}
/* La fiche dit déjà de quoi il s'agit : on retire la phrase d'accroche. */
body.has-session .join-lead {
  display: none;
}
/* Étapes « Organiser » : plusieurs champs par étape. */
.step-fields {
  display: grid;
  gap: 14px;
  min-width: 0;
}
.when-row {
  display: grid;
  gap: 12px;
}
/* Deux lignes : date et heure, puis durée et fuseau horaire. */
@media (min-width: 420px) {
  .when-row {
    grid-template-columns: 1.2fr 1fr;
  }
}
.when-help {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  margin: 0;
}
.field-count {
  text-align: right;
}
.created {
  display: grid;
  gap: 16px;
}
.created:focus {
  outline: none;
}
.created-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.created .invite-title {
  font-size: 1.25rem;
}
/* Titre de la séance dans la salle et sur l'écran de salle. */
.session-name {
  overflow: hidden;
  max-width: 34ch;
  color: var(--fg-muted);
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.screen-title {
  margin-left: 14px;
  padding-left: 14px;
  border-left: 1px solid var(--rs-line, var(--line));
  font-weight: 650;
}

/* ═════════════════════════ Salle de visio ═════════════════════════ */
body.room-page {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  overflow: hidden;
  background:
    radial-gradient(70% 60% at 50% 0%, rgb(53 87 255 / 0.12), transparent 70%),
    radial-gradient(50% 40% at 100% 100%, rgb(255 204 0 / 0.04), transparent 70%), #040b1c;
}
.statusbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  align-items: center;
  margin: 10px 10px 0;
  padding: 8px 10px 8px 14px;
  border-radius: 20px;
  border: 1px solid var(--glass-line);
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  box-shadow: inset 0 1px 0 var(--glass-hi);
  font-size: 0.875rem;
}
.statusbar .title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  font-weight: 750;
}
.statusbar .brand-mark {
  width: 24px;
  height: 24px;
}
.room-code {
  padding: 3px 10px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.07);
  border: 1px solid var(--line);
  color: var(--fg-muted);
  font-weight: 750;
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}
.room-code:empty {
  display: none;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.05);
  border: 1px solid var(--line);
  font-weight: 650;
  transition:
    background-color 300ms var(--ease-out),
    border-color 300ms var(--ease-out);
}
.pill[data-state="ok"] {
  border-color: rgb(74 222 128 / 0.3);
}
.pill[data-state="warn"] {
  border-color: rgb(251 191 36 / 0.35);
}
.pill[data-state="bad"] {
  border-color: rgb(255 138 128 / 0.35);
}
.pill .icon {
  width: 16px;
  height: 16px;
  color: var(--fg-muted);
}
#mic-pill {
  background: rgb(196 39 26 / 0.22);
}
#mic-pill .icon {
  color: var(--bad);
}
.dot {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #8a99ad;
}
.pill[data-state="ok"] .dot {
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
}
.pill[data-state="warn"] .dot {
  background: var(--warn);
}
.pill[data-state="bad"] .dot {
  background: var(--bad);
}
@media (prefers-reduced-motion: no-preference) {
  .pill[data-state="warn"] .dot {
    animation: breathe 1.4s ease-in-out infinite;
  }
}
@keyframes breathe {
  50% {
    opacity: 0.35;
  }
}
.stage {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
/* Grille : vignettes 16:9 de largeur --tile-w sur --cols colonnes, calculées par room.js
   (layoutGrid) pour être aussi grandes que possible, centrées dans la scène. */
.grid {
  flex: 1;
  min-height: 0;
  display: grid;
  gap: 10px;
  padding: 10px;
  grid-template-columns: repeat(var(--cols, 1), var(--tile-w, minmax(0, 1fr)));
  grid-auto-rows: max-content;
  place-content: center;
  overflow: auto;
}
.grid > .tile {
  aspect-ratio: 16 / 9;
}
/* Vue principale (partage d'écran, ou orateur mis en avant) : elle occupe toute la hauteur,
   les autres vignettes forment une colonne à droite (au moins 4 rangées, proches du 16:9). */
.grid.featured {
  grid-template-columns: minmax(0, 1fr) clamp(170px, 19%, 300px);
  grid-template-rows: repeat(max(var(--n), 4), minmax(0, 1fr));
  place-content: stretch;
}
.grid.featured > .tile {
  aspect-ratio: auto;
  min-height: 0;
}
.grid.featured > .tile:not(.featured-tile) {
  grid-column: 2;
}
.grid.featured > .featured-tile {
  grid-column: 1;
  grid-row: 1 / -1;
}
/* Panneau « Transcription » ouvert : la grille lui laisse la place au lieu de passer dessous. */
@media (min-width: 641px) {
  .stage:has(.transcript:not([hidden])) .grid {
    margin-right: 400px;
  }
}
/* Partage d'écran : les sous-titres passent sous le partage, jamais par-dessus. */
.stage:has(.grid.featured .tile.screen) .captions {
  position: static;
  transform: none;
  width: min(980px, calc(100% - 28px));
  margin: 0 auto 10px;
}
.tile {
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  border-radius: 22px;
  border: 1px solid rgb(255 255 255 / 0.06);
  background:
    radial-gradient(70% 60% at 50% 40%, rgb(53 87 255 / 0.14), transparent 70%),
    linear-gradient(160deg, #0d2042, #071431);
  transition: box-shadow 260ms var(--ease-out);
}
@media (prefers-reduced-motion: no-preference) {
  .tile {
    animation: tile-in 420ms var(--ease-spring);
  }
}
@keyframes tile-in {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
}
/* Intervenant actif : liseré bleu et halo dont l'épaisseur suit le volume de sa voix
   (--level, de 0 à 1, posé par room.js). */
.tile.speaking {
  box-shadow:
    inset 0 0 0 2px var(--primary),
    0 0 0 calc(3px + var(--level, 0) * 9px) rgb(159 174 229 / calc(0.14 + var(--level, 0) * 0.3)),
    0 0 calc(30px + var(--level, 0) * 40px) -6px rgb(159 174 229 / 0.45);
  transition: box-shadow 90ms linear;
}
/* Mise en avant : à 3 participants ou plus, l'orateur devient la vue principale. */
@media (prefers-reduced-motion: no-preference) {
  .grid.featured > .featured-tile.spotlight {
    animation: spotlight-in 520ms var(--ease-spring);
  }
}
@keyframes spotlight-in {
  from {
    opacity: 0.6;
    transform: scale(0.96);
  }
}
.tile video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.tile.screen video {
  object-fit: contain;
  background: #000;
}
.tile.local:not(.screen) video {
  transform: scaleX(-1);
}
.tile.screen {
  background: #000;
}
.avatar {
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: linear-gradient(160deg, #2a4a8f, #142a57);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.2),
    0 12px 30px -12px rgb(0 0 0 / 0.7);
  font-size: 1.875rem;
  font-weight: 800;
  color: #dfe5fa;
}
.tile.speaking .avatar {
  box-shadow:
    0 0 0 calc(4px + var(--level, 0) * 10px) rgb(159 174 229 / 0.18),
    0 0 0 calc(10px + var(--level, 0) * 22px) rgb(159 174 229 / 0.07);
  transition: box-shadow 90ms linear;
}
.tile-label {
  position: absolute;
  left: 10px;
  bottom: 10px;
  display: flex;
  align-items: center;
  gap: 7px;
  max-width: calc(100% - 20px);
  padding: 5px 12px 5px 8px;
  border-radius: 999px;
  border: 1px solid rgb(255 255 255 / 0.12);
  background: rgb(3 10 26 / 0.62);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: 0.875rem;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tile-label .icon {
  width: 16px;
  height: 16px;
  color: var(--bad);
}
.tile-lang {
  padding: 1px 7px;
  border-radius: 999px;
  background: rgb(159 174 229 / 0.18);
  color: var(--primary);
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}
/* Salle vide : panneau de verre en haut de la scène, avec le lien à envoyer. */
.waiting {
  position: absolute;
  top: 22px;
  left: 50%;
  z-index: 3;
  transform: translateX(-50%);
  width: min(460px, calc(100% - 28px));
  display: grid;
  gap: 8px;
  padding: 18px 20px;
  border-radius: 22px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.78);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 24px 60px -24px rgb(0 0 0 / 0.8);
  text-align: center;
}
@media (prefers-reduced-motion: no-preference) {
  .waiting {
    animation: pop-in 420ms var(--ease-spring);
  }
}
.waiting p {
  margin: 0;
}
.waiting-title {
  font-weight: 750;
  font-size: 1.0625rem;
}
.waiting-help {
  color: var(--fg-muted);
  font-size: 0.9375rem;
}
.waiting-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 6px;
}
.waiting-actions .room-code {
  max-width: 100%;
  overflow-wrap: anywhere;
}

/* Bandeau de sous-titres */
.captions {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 14px;
  width: min(980px, calc(100% - 28px));
  display: grid;
  gap: 8px;
  pointer-events: none;
}
.caption {
  padding: 12px 18px 14px;
  border-radius: 18px;
  border: 1px solid rgb(255 255 255 / 0.1);
  background: rgb(3 10 26 / 0.82);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.12),
    0 18px 40px -18px rgb(0 0 0 / 0.8);
  font-size: 1.3125rem;
  font-weight: 550;
  line-height: 1.38;
}
/* Une phrase arrive en glissant ; quand le texte provisoire devient la traduction, le texte
   se recompose en fondu (classes posées une seule fois par room.js). */
@media (prefers-reduced-motion: no-preference) {
  .caption.entering {
    animation: caption-in 360ms var(--ease-out);
  }
  .caption.settling .txt {
    animation: caption-settle 480ms var(--ease-out);
  }
  .caption.settling {
    animation: caption-glow 700ms var(--ease-out);
  }
}
@keyframes caption-in {
  from {
    opacity: 0;
    transform: translateY(10px);
    filter: blur(4px);
  }
}
@keyframes caption-settle {
  from {
    opacity: 0.25;
    transform: translateY(4px);
    filter: blur(3px);
  }
}
@keyframes caption-glow {
  from {
    border-color: color-mix(in srgb, var(--speaker, #9faee5) 70%, transparent);
  }
}
.caption .txt {
  transition: color 300ms var(--ease-out);
}
.speaker-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--speaker, var(--primary));
  box-shadow: 0 0 8px var(--speaker, var(--primary));
}
.caption .who {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
  font-size: 0.8125rem;
}
.caption .who .name {
  font-weight: 800;
  color: var(--primary);
}
.caption .who .pair {
  padding: 1px 8px;
  border-radius: 999px;
  background: rgb(255 204 0 / 0.12);
  color: #ffe27a;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.caption.interim .txt {
  color: var(--fg-muted);
  font-style: italic;
}
.caption .badge {
  padding: 1px 8px;
  border-radius: 999px;
  background: rgb(255 138 128 / 0.14);
  color: var(--bad);
  font-size: 0.75rem;
  font-weight: 750;
}
/* Réglages d'affichage : la taille « m » garde les valeurs par défaut (et celle du mobile). */
.captions[data-pos="top"] {
  bottom: auto;
  top: 14px;
}
.captions[data-size="s"] .caption {
  font-size: 1.0625rem;
}
.captions[data-size="l"] .caption {
  font-size: 1.75rem;
}
.captions[data-size="xl"] .caption {
  font-size: 2.25rem;
}
.caption .orig {
  margin-top: 4px;
  font-size: 0.78em;
  color: var(--fg-muted);
}
.captions-empty {
  justify-self: center;
  margin: 0;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgb(3 10 26 / 0.6);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--fg-soft);
  font-size: 0.9375rem;
  text-align: center;
}

/* Dock de commandes en verre */
.controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 0 auto calc(12px + env(safe-area-inset-bottom));
  padding: 8px;
  border-radius: 26px;
  border: 1px solid var(--glass-line);
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 20px 50px -20px rgb(0 0 0 / 0.8);
  max-width: calc(100% - 20px);
}
.controls .btn {
  flex-direction: column;
  gap: 4px;
  min-width: 78px;
  min-height: 62px;
  padding: 6px 10px;
  border-radius: 18px;
  background: rgb(255 255 255 / 0.07);
  border: 1px solid rgb(255 255 255 / 0.06);
  color: var(--fg);
}
.controls .btn:hover:not(:disabled) {
  background: rgb(255 255 255 / 0.13);
}
.controls .btn .icon {
  width: 22px;
  height: 22px;
}
/* Micro et caméra : l'icône barrée suit l'état aria-pressed posé par room.js. */
.controls .btn .if-off,
.controls .btn[aria-pressed="false"] .if-on {
  display: none;
}
.controls .btn[aria-pressed="false"] .if-off {
  display: block;
}
.controls .btn[aria-pressed="false"] {
  background: #c4271a;
  border-color: transparent;
  color: #fff;
}
.controls .btn[aria-pressed="false"]:hover {
  background: #db3626;
}
.controls .btn.sharing {
  background: var(--primary);
  color: var(--primary-fg);
}
.controls .btn-danger {
  background: #c4271a;
  border-color: transparent;
  color: #fff;
}
.controls .btn-danger:hover:not(:disabled) {
  background: #db3626;
}
/* Libellés du dock : toujours visibles, sur deux lignes au plus. */
.controls .lbl {
  max-width: 11ch;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}
.controls .key {
  position: absolute;
  top: 5px;
  right: 6px;
}
/* « Sous-titres » : une pastille avec la langue de lecture, et son nom dessous. */
.controls .dock-select {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 78px;
  min-height: 62px;
  padding: 6px 10px;
  border-radius: 18px;
  border: 1px solid rgb(255 255 255 / 0.06);
  background: rgb(255 255 255 / 0.07);
  cursor: pointer;
}
.controls .dock-select:hover {
  background: rgb(255 255 255 / 0.13);
}
.controls .dock-select:focus-within {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
}
.dock-select-box {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.controls .dock-select select {
  width: auto;
  min-height: 26px;
  padding: 0 22px 0 4px;
  border: 0;
  border-radius: 8px;
  background-color: transparent;
  background-position:
    calc(100% - 11px) 52%,
    calc(100% - 6px) 52%;
  font-size: 0.875rem;
  font-weight: 800;
  box-shadow: none;
}
.controls .dock-select select:focus-visible {
  box-shadow: none;
}
/* Séparateurs entre les trois groupes du dock. */
.controls-sep {
  align-self: center;
  width: 1px;
  height: 30px;
  margin: 0 4px;
  background: var(--line-strong);
}
/* Touche du raccourci clavier, visible au survol ou au focus sur grand écran. */
.controls .key {
  min-width: 20px;
  padding: 1px 5px;
  border-radius: 6px;
  border: 1px solid rgb(255 255 255 / 0.22);
  background: rgb(0 0 0 / 0.25);
  font: inherit;
  font-size: 0.6875rem;
  font-weight: 750;
  line-height: 1.4;
  text-align: center;
  opacity: 0;
  transition: opacity 200ms var(--ease-out);
}
.controls .btn:hover .key,
.controls .btn:focus-visible .key {
  opacity: 0.85;
}
.timer-pill {
  font-variant-numeric: tabular-nums;
  color: var(--fg-muted);
}

.audio-unlock {
  position: absolute;
  top: 35%;
  left: 50%;
  z-index: 5;
  transform: translateX(-50%);
  min-height: 64px;
  padding: 0 28px;
  font-size: 1.25rem;
}

/* Panneau « Transcription » */
.transcript {
  position: absolute;
  top: 10px;
  right: 10px;
  bottom: 10px;
  z-index: 4;
  width: min(390px, calc(100% - 20px));
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.86);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  backdrop-filter: blur(20px) saturate(150%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 30px 60px -24px rgb(0 0 0 / 0.8);
}
@media (prefers-reduced-motion: no-preference) {
  .transcript {
    animation: slide-in 320ms var(--ease-out);
  }
}
@keyframes slide-in {
  from {
    opacity: 0;
    transform: translateX(24px);
  }
}
/* Panneau ouvert sur grand écran : le bandeau se recentre sur la zone vidéo restante. */
@media (min-width: 641px) {
  .stage:has(.transcript:not([hidden])) .captions {
    left: calc((100% - min(390px, 100%) - 10px) / 2);
    width: min(980px, calc(100% - min(390px, 100%) - 38px));
  }
}
.transcript-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.transcript-head h2 {
  margin: 0;
  font-size: 1.125rem;
}
.transcript-head .btn {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  background: transparent;
}
.transcript input[type="search"] {
  min-height: 44px;
  border-radius: 999px;
  padding: 0 18px;
}
.transcript-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  align-content: start;
}
.transcript-list li {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.transcript-list li:first-child {
  border-top: 0;
}
.transcript-list .meta {
  font-size: 0.8125rem;
  font-weight: 750;
  color: var(--primary);
}
.transcript-list p {
  margin: 3px 0 0;
  line-height: 1.5;
}
.transcript-list .empty {
  color: var(--fg-muted);
}

/* Panneau « Transcription » : bascule de langue, recherche surlignée, groupes par orateur. */
.transcript-view {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.transcript .opt {
  min-height: 38px;
  font-size: 0.875rem;
}
.transcript-search {
  position: relative;
}
.transcript-search input {
  padding-right: 44px;
}
.transcript-search input::-webkit-search-cancel-button {
  display: none;
}
.transcript-clear {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.08);
  color: var(--fg);
  cursor: pointer;
}
.transcript-clear .icon {
  width: 16px;
  height: 16px;
}
.transcript-count {
  margin: -4px 0 0;
  min-height: 1.2em;
}
.transcript-list li {
  --speaker: var(--primary);
}
.transcript-list li.cont {
  padding-top: 4px;
  border-top: 0;
}
.transcript-list .meta {
  display: flex;
  align-items: center;
  gap: 6px;
}
.transcript-list li.cont .meta {
  color: var(--fg-soft);
  font-weight: 600;
  font-size: 0.75rem;
}
.transcript-list .orig {
  margin-top: 2px;
  color: var(--fg-muted);
  font-size: 0.875rem;
}
.transcript-list .badge {
  padding: 1px 8px;
  border-radius: 999px;
  background: rgb(255 138 128 / 0.14);
  color: var(--bad);
  font-size: 0.75rem;
  font-weight: 750;
}
.transcript mark {
  padding: 0 2px;
  border-radius: 4px;
  background: rgb(255 204 0 / 0.28);
  color: inherit;
}
.transcript-latest {
  position: absolute;
  left: 50%;
  bottom: 84px;
  transform: translateX(-50%);
  box-shadow: 0 12px 30px -12px rgb(0 0 0 / 0.7);
}
.transcript-download {
  border: 1px solid var(--line-strong);
}
.transcript-download:disabled {
  opacity: 0.45;
}

/* Écran de salle : projeté pour le public, lisible de loin. Deux fonds au choix
   (data-theme) : sombre par défaut, clair pour une salle éclairée. */
.room-screen {
  --rs-bg: #030a18;
  --rs-text: #f4f7fd;
  --rs-old: #b4c2d6;
  --rs-line: rgb(255 255 255 / 0.08);
  --rs-glow: rgb(159 174 229 / 0.16);
  flex: 1;
  min-height: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px clamp(16px, 4vw, 64px) 16px;
  background:
    radial-gradient(60% 40% at 50% 0%, rgb(53 87 255 / 0.12), transparent 70%), var(--rs-bg);
  color: var(--rs-text);
}
.room-screen[data-theme="light"] {
  --rs-bg: #ffffff;
  --rs-text: #0a1a33;
  --rs-old: #44546b;
  --rs-line: rgb(10 26 51 / 0.1);
  --rs-glow: rgb(0 51 153 / 0.08);
  --primary: #003399;
  --primary-fg: #ffffff;
  --primary-hover: #1f4fc2;
  --fg: #0a1a33;
  --fg-muted: #44546b;
  --fg-soft: #5d6c82;
  --line: rgb(10 26 51 / 0.12);
  --glass-bg: linear-gradient(180deg, rgb(10 26 51 / 0.04), rgb(10 26 51 / 0.02));
  --glass-line: rgb(10 26 51 / 0.12);
  --glass-hi: rgb(255 255 255 / 0.8);
  --ring: #003399;
  color-scheme: light;
  background: var(--rs-bg);
}
/* Bandeau pour le public */
.screen-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--rs-line);
}
.screen-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 750;
}
.screen-brand .brand-mark {
  width: 30px;
  height: 30px;
  stroke: currentColor;
}
.screen-join {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  font-size: clamp(1rem, 1.6vw, 1.375rem);
  color: var(--rs-old);
}
.screen-join strong {
  color: var(--rs-text);
  font-weight: 750;
}
.screen-code {
  padding: 2px 12px;
  border-radius: 999px;
  border: 1px solid var(--rs-line);
  background: var(--rs-glow);
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}
.room-screen-cols {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr));
  /* Les cellules ont overflow: hidden (balayage lumineux) : sans ce max-content, la grille
     écraserait les lignes pour tout faire tenir au lieu de défiler. */
  grid-auto-rows: max-content;
  align-content: start;
  column-gap: clamp(24px, 4vw, 72px);
  row-gap: 0.6em;
  font-size: var(--screen-size, 2.5rem);
  line-height: 1.25;
}
.room-screen-cols .head {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 0.1em 0 0.3em;
  border-bottom: 3px solid transparent;
  border-image: linear-gradient(90deg, var(--primary), var(--sun)) 1;
  background: var(--rs-bg);
  color: var(--primary);
  font-size: 0.48em;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.room-screen-cols .who {
  display: flex;
  align-items: center;
  gap: 0.35em;
  font-size: 0.42em;
  font-weight: 750;
  color: var(--primary);
}
.room-screen-cols .speaker-dot {
  width: 0.55em;
  height: 0.55em;
}
.room-screen-cols p {
  margin: 0;
  text-wrap: pretty;
}
/* Chaque paire de phrases sur sa ligne ; la plus récente reste en pleine lumière, les
   précédentes s'estompent selon leur âge pour guider l'œil du public. */
.room-screen-cols .cell {
  position: relative;
  overflow: hidden;
  padding-top: 0.35em;
  border-top: 1px solid var(--rs-line);
  color: var(--rs-old);
  opacity: max(0.5, calc(1 - var(--age, 0) * 0.1));
  transition:
    color 500ms var(--ease-out),
    opacity 500ms var(--ease-out);
}
.room-screen-cols .cell.latest {
  color: var(--rs-text);
  opacity: 1;
}
.room-screen-cols p.interim {
  color: var(--rs-old);
  font-style: italic;
}
.room-screen-cols p.interim::after {
  content: "";
  display: inline-block;
  width: 0.08em;
  height: 0.9em;
  margin-left: 0.15em;
  vertical-align: -0.1em;
  background: var(--sun);
}
.room-screen-cols p.missing {
  color: var(--rs-old);
}
.room-screen-cols .empty {
  grid-column: 1 / -1;
  margin-top: 1em;
  color: var(--rs-old);
  font-size: 0.6em;
}
/* Arrivée et mise en lumière : une phrase glisse en place, puis un trait de lumière la
   balaie quand elle est complète (rappel du faisceau du prisme). */
.room-screen-cols .cell::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    100deg,
    transparent 30%,
    var(--rs-glow) 45%,
    color-mix(in srgb, var(--sun) 22%, transparent) 50%,
    var(--rs-glow) 55%,
    transparent 70%
  );
  transform: translateX(-110%);
}
@media (prefers-reduced-motion: no-preference) {
  .room-screen-cols .cell.arriving {
    animation: screen-arrive 520ms var(--ease-out);
  }
  .room-screen-cols .cell.lit::after {
    animation: screen-sweep 1100ms var(--ease-out);
  }
  .room-screen-cols p.interim::after {
    animation: blink 0.9s steps(1) infinite;
  }
}
@keyframes screen-arrive {
  from {
    opacity: 0;
    transform: translateY(0.4em);
  }
}
@keyframes screen-sweep {
  to {
    transform: translateX(110%);
  }
}
/* Mode « Orateur + sous-titres » : l'image en grand, les sous-titres FR et EN dessous, en très
   gros caractères (taille réglable avec + et −). */
.screen-stage {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 16px;
}
.screen-video {
  position: relative;
  overflow: hidden;
  min-height: 0;
  display: grid;
  place-items: center;
  border-radius: 24px;
  border: 1px solid var(--rs-line);
  background: radial-gradient(60% 60% at 50% 40%, rgb(53 87 255 / 0.18), transparent 70%), #050f22;
}
.screen-video video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}
.screen-video video.mirror {
  transform: scaleX(-1);
}
.screen-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}
.screen-placeholder .avatar {
  width: clamp(96px, 14vh, 160px);
  height: clamp(96px, 14vh, 160px);
  font-size: clamp(2rem, 5vh, 3.5rem);
}
.screen-video .screen-who {
  left: 16px;
  bottom: 16px;
  font-size: 1rem;
}
.screen-lines {
  display: grid;
  gap: 0.35em;
  font-size: calc(var(--screen-size, 2.5rem) * 0.8);
  line-height: 1.25;
}
.stage-block {
  display: grid;
  gap: 0.15em;
  padding: 0.3em 0.5em 0.35em;
  border-radius: 0.4em;
  border-left: 4px solid var(--speaker, var(--primary));
  background: color-mix(in srgb, var(--rs-bg) 70%, transparent);
}
.stage-block:not(.latest) {
  font-size: 0.55em;
  opacity: 0.6;
}
@media (prefers-reduced-motion: no-preference) {
  .stage-block.latest {
    animation: screen-arrive 420ms var(--ease-out);
  }
}
.stage-block .who {
  display: flex;
  align-items: center;
  gap: 0.35em;
  font-size: 0.42em;
  font-weight: 750;
  color: var(--primary);
}
.stage-block .speaker-dot {
  width: 0.55em;
  height: 0.55em;
}
.stage-row {
  display: flex;
  align-items: baseline;
  gap: 0.45em;
  margin: 0;
  color: var(--rs-text);
  text-wrap: pretty;
}
.stage-row + .stage-row {
  color: var(--rs-old);
}
.stage-lang {
  flex: none;
  padding: 0.1em 0.35em;
  border-radius: 0.3em;
  border: 1px solid var(--rs-line);
  font-size: 0.38em;
  font-weight: 800;
  letter-spacing: 0.08em;
  transform: translateY(-0.25em);
}
.stage-row.interim .stage-text {
  font-style: italic;
  color: var(--rs-old);
}
.stage-row.pending .stage-text,
.stage-row.missing .stage-text {
  color: var(--rs-old);
}
.stage-empty {
  margin: 0;
  color: var(--rs-old);
  font-size: 0.6em;
}
/* Partage d'écran projeté : la ligne de sous-titres reste compacte pour laisser l'image grande. */
.screen-stage.is-share .screen-lines {
  font-size: calc(var(--screen-size, 2.5rem) * 0.6);
}
/* Sélecteur de mode dans la barre de l'écran de salle. */
.screen-modes {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border-radius: 18px;
  border: 1px solid var(--glass-line);
}
.screen-modes .btn[aria-pressed="true"] {
  background: var(--primary);
  color: var(--primary-fg);
}
/* Défilement suspendu : rappel des phrases arrivées entre-temps. */
.screen-new {
  position: absolute;
  left: 50%;
  bottom: 96px;
  z-index: 2;
  transform: translateX(-50%);
  box-shadow: 0 16px 40px -14px rgb(0 0 0 / 0.6);
}
.screen-new .icon {
  transform: rotate(90deg);
}
.room-screen-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 8px;
  border-radius: 24px;
  border: 1px solid var(--glass-line);
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  transition: opacity 300ms var(--ease-out);
}
.room-screen-bar .btn {
  min-height: 46px;
  border-radius: 16px;
  background: color-mix(in srgb, var(--fg) 7%, transparent);
  border: 1px solid color-mix(in srgb, var(--fg) 8%, transparent);
  color: var(--fg);
}
.room-screen-bar .btn[aria-pressed="true"] {
  border-color: var(--primary);
}
.room-screen-bar .btn-accent {
  background: var(--primary);
  color: var(--primary-fg);
}
.room-screen-hint {
  margin-right: auto;
  padding-left: 10px;
  color: var(--fg-soft);
  font-size: 0.875rem;
}
/* Raccourcis clavier inutiles sur téléphone. */
@media (max-width: 640px) {
  .room-screen-hint {
    display: none;
  }
}
/* En plein écran, la barre et le curseur se cachent après 3 s sans mouvement (.awake posé
   par room.js) ; la barre revient au survol ou au clavier. */
.room-screen:fullscreen:not(.awake) {
  cursor: none;
}
.room-screen:fullscreen:not(.awake) .room-screen-bar {
  opacity: 0;
}
.room-screen:fullscreen .room-screen-bar:hover,
.room-screen:fullscreen .room-screen-bar:focus-within {
  opacity: 1;
}

/* Dialogue « Affichage » */
.display-dialog {
  width: min(460px, calc(100% - 32px));
  padding: 24px;
  border-radius: 28px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.92);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  backdrop-filter: blur(24px) saturate(150%);
  color: var(--fg);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 40px 90px -30px rgb(0 0 0 / 0.9);
}
.display-dialog::backdrop {
  background: rgb(2 7 18 / 0.62);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
@media (prefers-reduced-motion: no-preference) {
  .display-dialog[open] {
    animation: dialog-in 320ms var(--ease-spring);
  }
}
@keyframes dialog-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.96);
  }
}
.display-dialog form {
  gap: 18px;
}
.display-dialog h2 {
  margin: 0;
  font-size: 1.3125rem;
  letter-spacing: -0.015em;
}
.display-dialog fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.display-dialog legend {
  margin-bottom: 8px;
  padding: 0;
  font-weight: 700;
  color: var(--fg-muted);
  font-size: 0.875rem;
}
/* Contrôle segmenté en verre : la pastille sélectionnée apparaît en fondu enchaîné.
   La puce radio est masquée à l'œil mais reste au clavier. */
.transcript .options,
.display-dialog .options {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgb(0 0 0 / 0.25);
}
.transcript .opt,
.display-dialog .opt {
  position: relative;
  isolation: isolate;
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 12px;
  color: var(--fg-muted);
  font-weight: 650;
  cursor: pointer;
  transition: color 300ms var(--ease-out);
}
.transcript .opt::before,
.display-dialog .opt::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: linear-gradient(160deg, #c9d2f3, #9faee5 90%);
  box-shadow: inset 0 0 14px rgb(255 255 255 / 0.55);
  opacity: 0;
  transition: opacity 320ms var(--ease-out);
}
.transcript .opt input,
.display-dialog .opt input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.transcript .opt:hover,
.display-dialog .opt:hover {
  color: var(--fg);
}
.transcript .opt:has(input:checked),
.display-dialog .opt:has(input:checked) {
  color: #06122a;
}
.transcript .opt:has(input:checked)::before,
.display-dialog .opt:has(input:checked)::before {
  opacity: 1;
}
.transcript .opt:has(input:focus-visible),
.display-dialog .opt:has(input:focus-visible) {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
}
.display-dialog {
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
}
.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.dialog-x {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.05);
  color: var(--fg);
  cursor: pointer;
  transition: background-color 200ms var(--ease-out);
}
.dialog-x:hover {
  background: rgb(255 255 255 / 0.12);
}
/* Aperçu : une mini-scène de visio où l'exemple de sous-titre suit les réglages. */
.display-preview {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 170px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background:
    radial-gradient(60% 70% at 50% 40%, rgb(53 87 255 / 0.18), transparent 70%),
    linear-gradient(160deg, #0d2042, #071431);
  overflow: hidden;
}
.dp-caption {
  --speaker: #9faee5;
  padding: 8px 12px 10px;
  border-radius: 12px;
  border: 1px solid rgb(255 255 255 / 0.1);
  background: rgb(3 10 26 / 0.82);
  font-size: 0.95rem;
  font-weight: 550;
  line-height: 1.35;
  transition: font-size 220ms var(--ease-out);
}
.dp-caption[data-pos="top"] {
  margin-bottom: auto;
  order: -1;
}
.display-preview:has(.dp-caption[data-pos="top"]) {
  justify-content: flex-start;
}
.dp-caption[data-size="s"] {
  font-size: 0.8rem;
}
.dp-caption[data-size="l"] {
  font-size: 1.15rem;
}
.dp-caption[data-size="xl"] {
  font-size: 1.4rem;
}
.dp-caption .who {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
  font-size: 0.72em;
}
.dp-caption .name {
  font-weight: 800;
  color: var(--primary);
}
.dp-caption .pair {
  padding: 0 6px;
  border-radius: 999px;
  background: rgb(255 204 0 / 0.12);
  color: #ffe27a;
  font-size: 0.85em;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.dp-caption .orig {
  margin-top: 2px;
  font-size: 0.78em;
  color: var(--fg-muted);
}
/* Options plus parlantes : un « A » à la bonne taille, une icône pour la position. */
.display-dialog .size-options {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.size-options .opt {
  flex-direction: column;
  gap: 2px;
  min-height: 62px;
  padding: 0 4px;
  text-align: center;
}
@media (max-width: 480px) {
  .display-preview {
    min-height: 130px;
  }
}
.opt-a {
  position: relative;
  font-weight: 800;
  line-height: 1;
}
.size-options .opt:nth-child(1) .opt-a {
  font-size: 0.85rem;
}
.size-options .opt:nth-child(2) .opt-a {
  font-size: 1.05rem;
}
.size-options .opt:nth-child(3) .opt-a {
  font-size: 1.35rem;
}
.size-options .opt:nth-child(4) .opt-a {
  font-size: 1.7rem;
}
.size-options .opt span:last-child {
  font-size: 0.75rem;
}
.pos-icon {
  position: relative;
  width: 24px;
  height: 18px;
  margin-right: 8px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
}
.pos-icon .pos-bar {
  fill: currentColor;
  stroke: none;
}
.mode-help {
  margin: 8px 0 0;
  min-height: 2.6em;
}
.dialog-foot {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
}
.display-dialog .btn {
  min-height: 50px;
}
.dialog-foot .btn-ghost {
  border: 1px solid var(--line-strong);
}

/* Écran de fin : brume en fond, carte de verre */
.left-screen {
  position: relative;
  isolation: isolate;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  overflow: auto;
}
.left-screen .mist {
  position: fixed;
}
/* Clôture : la lumière est coupée à la source, les faisceaux se retirent l'un après l'autre,
   le verre s'assombrit ; la carte arrive ensuite. Mouvement réduit : prisme éteint d'emblée. */
.end-prism {
  width: min(200px, 50vw);
  height: auto;
  overflow: visible;
}
.ep-beam {
  fill: none;
  stroke-linecap: round;
  stroke-width: 2;
  stroke-dasharray: 1;
  stroke-dashoffset: -1;
}
.ep-in {
  stroke: #fff;
}
.ep-mid {
  stroke: rgb(255 255 255 / 0.5);
}
.ep-a {
  stroke: #9faee5;
}
.ep-b {
  stroke: #ffcc00;
  stroke-width: 1.5;
}
.ep-glass {
  fill: rgb(159 174 229 / 0.05);
  stroke: rgb(159 174 229 / 0.35);
  stroke-width: 1.5;
  stroke-linejoin: round;
}
@media (prefers-reduced-motion: no-preference) {
  .left-screen:not([hidden]) .ep-beam {
    animation: ep-off 900ms var(--ease-out) backwards;
  }
  .left-screen:not([hidden]) .ep-mid {
    animation-delay: 0.3s;
  }
  .left-screen:not([hidden]) .ep-a,
  .left-screen:not([hidden]) .ep-b {
    animation-delay: 0.45s;
    animation-duration: 1.2s;
  }
  .left-screen:not([hidden]) .ep-glass {
    animation: ep-dim 1.6s var(--ease-out) backwards;
  }
}
@keyframes ep-off {
  from {
    stroke-dashoffset: 0;
  }
}
@keyframes ep-dim {
  from {
    stroke: #fff;
    fill: rgb(159 174 229 / 0.2);
    filter: drop-shadow(0 0 10px rgb(159 174 229 / 0.8));
  }
}
.left-screen .mist {
  z-index: -1;
}
.left-card {
  width: min(460px, 100%);
  display: grid;
  justify-items: center;
  gap: 18px;
  padding: 40px 28px 32px;
  border-radius: 28px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.6);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  backdrop-filter: blur(20px) saturate(150%);
  box-shadow:
    inset 0 1px 0 var(--glass-hi),
    0 40px 90px -30px rgb(0 0 0 / 0.9);
  text-align: center;
}
@media (prefers-reduced-motion: no-preference) {
  .left-card {
    animation: pop-in 560ms var(--ease-spring) 0.9s backwards;
  }
}
.left-card p {
  margin: 0;
}
.end-message {
  font-size: 1.25rem;
  font-weight: 650;
  line-height: 1.4;
  text-wrap: balance;
}
.end-tip {
  color: var(--fg-muted);
  font-size: 0.9375rem;
}
/* Bilan : trois chiffres côte à côte. */
.end-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: 100%;
  margin: 4px 0 0;
  padding: 14px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.end-stats > div {
  display: flex;
  flex-direction: column-reverse;
  gap: 2px;
}
.end-stats > div + div {
  border-left: 1px solid var(--line);
}
.end-stats dd {
  margin: 0;
  font-size: 1.625rem;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.end-stats dt {
  color: var(--fg-soft);
  font-size: 0.8125rem;
}
.end-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.end-download {
  border: 1px solid var(--line-strong);
}
.left-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgb(159 174 229 / 0.14);
  color: var(--primary);
  box-shadow: 0 0 0 10px rgb(159 174 229 / 0.06);
}
.left-icon[data-state="bad"] {
  background: rgb(255 138 128 / 0.14);
  color: var(--bad);
  box-shadow: 0 0 0 10px rgb(255 138 128 / 0.05);
}
.left-icon .icon {
  width: 30px;
  height: 30px;
}
.left-card .btn {
  min-height: 52px;
  padding: 0 26px;
}

@media (max-width: 640px) {
  .statusbar {
    margin: 8px 8px 0;
    border-radius: 16px;
  }
  /* Deux zones : la vidéo en haut, les sous-titres dans la moitié basse (pas de superposition). */
  .stage {
    flex-direction: column;
  }
  .grid {
    gap: 8px;
    padding: 8px;
  }
  /* Vue principale en haut, les autres vignettes en rangée dessous. */
  .grid.featured {
    grid-template-columns: repeat(var(--n), minmax(0, 1fr));
    grid-template-rows: minmax(0, 1fr) auto;
  }
  .grid.featured > .featured-tile {
    grid-column: 1 / -1;
    grid-row: 1;
  }
  .grid.featured > .tile:not(.featured-tile) {
    grid-column: auto;
    grid-row: 2;
    aspect-ratio: 16 / 9;
  }
  .tile {
    border-radius: 16px;
  }
  .captions {
    position: static;
    transform: none;
    width: auto;
    flex: 0 1 50%;
    min-height: 0;
    overflow-y: auto;
    align-content: end;
    padding: 8px;
  }
  .captions[data-pos="top"] {
    order: -1;
    align-content: start;
  }
  .caption {
    font-size: 1.0625rem;
  }
  /* Téléphone : deux rangées de quatre, chaque bouton garde son nom en petit. */
  .controls {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    width: calc(100% - 16px);
    padding: 6px;
    border-radius: 22px;
  }
  .controls .lbl {
    font-size: 0.6875rem;
  }
  /* Pas de clavier physique ni de place pour les séparateurs sur téléphone. */
  .controls .key,
  .controls-sep {
    display: none;
  }
  .controls .btn,
  .controls .dock-select {
    min-width: 0;
    min-height: 56px;
    padding: 6px 4px;
    border-radius: 16px;
  }
}

/* Mouvement réduit : aucune transition décorative. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Transition entre les pages du site (navigateurs compatibles) : la page sortante s'efface,
   la nouvelle monte légèrement ; le logo Prisma reste en place. Rien en mouvement réduit. */
@media (prefers-reduced-motion: no-preference) {
  @view-transition {
    navigation: auto;
  }
  .brand {
    view-transition-name: brand;
  }
  ::view-transition-old(root) {
    animation: vt-out 260ms var(--ease-out) both;
  }
  ::view-transition-new(root) {
    animation: vt-in 420ms var(--ease-out) both;
  }
}
@keyframes vt-out {
  to {
    opacity: 0;
    transform: scale(0.985);
  }
}
@keyframes vt-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
}

/* ───────────────────────── Gestion de la réunion ───────────────────────── */
/* Panneau « Participants » : même coque que « Transcription », contenu en liste. */
.people {
  overflow-y: auto;
}
.people-count {
  color: var(--fg-soft);
  font-weight: 600;
}
.room-settings {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgb(255 255 255 / 0.04);
}
.room-settings h3 {
  margin: 0 0 6px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
/* Interrupteur : la case native reste (clavier, lecteurs d'écran), seul son aspect change. */
.switch {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 40px;
  font-size: 0.9375rem;
  cursor: pointer;
}
.switch input {
  appearance: none;
  flex: none;
  position: relative;
  width: 40px;
  height: 24px;
  /* Neutralise le style global des champs (hauteur mini, marge intérieure, bordure). */
  min-height: 0;
  padding: 0;
  border: 0;
  margin: 0;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.18);
  cursor: pointer;
  transition: background 180ms var(--ease-out);
}
.switch input::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.4);
  transition: transform 180ms var(--ease-out);
}
.switch input:checked {
  background: var(--primary);
}
.switch input:checked::after {
  transform: translateX(16px);
}
.switch input:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
}
.switch input:disabled {
  opacity: 0.5;
  cursor: progress;
}
.settings-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.settings-actions .btn {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
}
.people-list {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.person {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 6px 8px;
  border-radius: 14px;
}
.person:hover {
  background: rgb(255 255 255 / 0.05);
}
.person-avatar {
  flex: none;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1f4fc2, #3557ff);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 750;
}
.person-main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.person-name {
  max-width: 100%;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.role-badge {
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  background: rgb(159 174 229 / 0.16);
  color: #c3ccf0;
}
.role-badge.role-host {
  background: rgb(255 204 0 / 0.16);
  color: #ffd24d;
}
.role-badge.role-viewer {
  background: rgb(255 255 255 / 0.08);
  color: var(--fg-soft);
}
.person-state {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--fg-muted);
}
.person-state .icon {
  width: 18px;
  height: 18px;
}
.person-state .icon.off {
  color: var(--bad);
}
.hand-badge,
.tile-hand {
  display: inline-grid;
  place-items: center;
  color: var(--sun);
}
.person-more {
  flex: none;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--fg);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.person-more:hover,
.person-more[aria-expanded="true"] {
  background: rgb(255 255 255 / 0.1);
}
.person-more:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 1px;
}

/* Menu d'actions sur un membre (positionné par moderation.js). */
.member-menu {
  position: fixed;
  z-index: 70;
  display: grid;
  min-width: 240px;
  max-height: min(70vh, 460px);
  overflow-y: auto;
  padding: 6px;
  border-radius: 16px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.97);
  box-shadow: 0 24px 50px -20px rgb(0 0 0 / 0.9);
}
.member-menu button {
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--fg);
  font: inherit;
  font-size: 0.9375rem;
  text-align: left;
  cursor: pointer;
}
.member-menu button:hover,
.member-menu button:focus-visible {
  background: rgb(255 255 255 / 0.1);
  outline: none;
}
.member-menu button.danger {
  color: var(--bad);
}

/* Mains levées et rôles sur les vignettes. */
.tile-hand .icon {
  width: 16px;
  height: 16px;
  color: var(--sun);
}
.tile-role {
  padding: 0 7px;
  border-radius: 999px;
  background: rgb(255 204 0 / 0.18);
  color: #ffd24d;
  font-size: 0.75rem;
}

/* Dock : nombre de présents, main levée active, droits retirés. */
.controls #btn-people {
  position: relative;
}
.dock-badge {
  position: absolute;
  top: 4px;
  right: 8px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--primary-fg);
  font-size: 0.75rem;
  font-weight: 750;
  line-height: 20px;
  text-align: center;
}
.dock-badge:empty {
  display: none;
}
.controls #btn-hand[aria-pressed="true"] {
  background: rgb(255 204 0 / 0.2);
  border-color: rgb(255 204 0 / 0.5);
  color: #ffd24d;
}
/* Le bouton « main » reste neutre quand personne ne lève la main (pas le style « coupé »). */
.controls #btn-hand[aria-pressed="false"] {
  background: rgb(255 255 255 / 0.07);
  border-color: rgb(255 255 255 / 0.06);
  color: var(--fg);
}
.controls #btn-hand.has-hands .icon {
  color: var(--sun);
}
.controls .btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Quitter (hôte) : quitter seul ou terminer pour tous. */
.controls {
  position: relative;
}
.leave-menu {
  position: absolute;
  right: 8px;
  bottom: calc(100% + 8px);
  z-index: 8;
  display: grid;
  gap: 6px;
  padding: 8px;
  border-radius: 18px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.97);
  box-shadow: 0 24px 50px -20px rgb(0 0 0 / 0.9);
}
.leave-menu .btn {
  min-height: 44px;
  justify-content: flex-start;
  padding: 0 16px;
}

/* Confirmation et notifications de la réunion. */
.confirm-dialog p {
  margin: 0 0 18px;
  font-size: 1.0625rem;
  font-weight: 600;
}
.room-toast {
  position: fixed;
  left: 50%;
  top: calc(70px + env(safe-area-inset-top));
  z-index: 65;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: calc(100% - 32px);
  padding: 10px 12px 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.94);
  box-shadow: var(--shadow-md);
  font-weight: 650;
  opacity: 0;
  transform: translate(-50%, -12px);
  pointer-events: none;
  transition:
    opacity 240ms var(--ease-out),
    transform 240ms var(--ease-out);
}
.room-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}
.room-toast:empty {
  visibility: hidden;
}

/* Pages d'entrée : rôle d'hôte annoncé, lien animateur mis à part. */
.host-note {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--primary-soft);
  color: var(--fg);
  font-weight: 600;
}
.host-field input {
  border-color: var(--sun-ink);
}

/* ───────────────────────── Pages de présentation (Exemple, Questions…) ───────────────────────── */
/* En-tête de page : sous la barre fixe, une scène sombre courte qui rappelle le hero. */
.page-hero {
  position: relative;
  padding: calc(var(--header-h) + clamp(48px, 8vw, 104px)) var(--gutter) clamp(48px, 7vw, 88px);
  background:
    radial-gradient(60% 90% at 85% 0%, rgb(53 87 255 / 0.28), transparent 70%),
    radial-gradient(40% 60% at 10% 100%, rgb(255 204 0 / 0.06), transparent 70%),
    linear-gradient(180deg, #061229, #0a1a38);
  color: #eef3fb;
  overflow: hidden;
}
/* Filet lumineux en bas, comme le faisceau qui sort du prisme. */
.page-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgb(159 174 229 / 0.6),
    rgb(255 204 0 / 0.5),
    transparent
  );
}
.page-hero-inner {
  max-width: 1240px;
  margin: 0 auto;
}
.page-hero h1 {
  max-width: 18ch;
}
.page-hero .lead {
  max-width: 60ch;
  margin-top: 18px;
  color: #b4c2d6;
}
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 0.8125rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #ffd24d;
}
.kicker::before {
  content: "";
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.subpage .section:first-of-type {
  padding-top: clamp(56px, 8vw, 96px);
}

/* Lien « en savoir plus » en bas d'une section de l'accueil. */
.section-more {
  margin: 28px 0 0;
}
.section-more a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  font-weight: 650;
  color: var(--primary);
  text-decoration: none;
}
.section-more a .icon {
  width: 18px;
  height: 18px;
  transition: transform 300ms var(--ease-out);
}
.section-more a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.section-more a:hover .icon {
  transform: translateX(4px);
}

/* Exemple : trois écrans pour une même phrase. */
.views {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 900px) {
  .views {
    grid-template-columns: 1fr 1fr 1.4fr;
  }
}
.view-card {
  position: relative;
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 24px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
}
.view-head {
  display: grid;
  gap: 2px;
}
.view-meta {
  color: var(--fg-soft);
  font-size: 0.875rem;
}
.view-caption {
  display: grid;
  gap: 6px;
  padding: 16px 18px;
  border-radius: 16px;
  background: linear-gradient(160deg, #0d2042, #071431);
  color: #eef3fb;
}
.view-caption p {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.4;
}
.view-speaker {
  color: #9faee5;
  font-size: 0.8125rem;
  font-weight: 650;
}
.view-split {
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.view-split p + p {
  padding-left: 14px;
  border-left: 1px solid rgb(255 255 255 / 0.12);
}
/* Exemple : aperçu du fichier de transcription. */
.transcript-mock {
  max-width: 720px;
  padding: 22px 24px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 0.9375rem;
}
.transcript-mock p {
  margin: 0;
}
.transcript-mock-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -4px 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--fg-soft);
  font-family: inherit;
  font-size: 0.8125rem;
}
.transcript-mock-bar .icon {
  width: 16px;
  height: 16px;
}
.tm-meta {
  color: var(--fg-soft);
}
.tm-tr {
  color: var(--primary);
}

/* Comment ça se passe : frise des quatre moments, reliés par le faisceau. */
.timeline {
  position: relative;
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.timeline::before {
  content: "";
  position: absolute;
  top: 28px;
  bottom: 28px;
  left: 27px;
  width: 2px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--primary), var(--sun));
  opacity: 0.5;
}
.phase {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.phase-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent);
  background: var(--surface);
  color: var(--primary);
  box-shadow: var(--shadow-md);
}
.phase-icon .icon {
  width: 26px;
  height: 26px;
}
.phase-body {
  padding: 22px 24px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
}
.phase-label {
  font-size: 0.8125rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--sun-ink);
}
.phase h3 {
  margin: 6px 0 8px;
  font-size: 1.25rem;
}
.phase p {
  margin: 0;
  max-width: 70ch;
  color: var(--fg-muted);
}
@media (min-width: 1000px) {
  .timeline {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
  }
  .timeline::before {
    top: 27px;
    bottom: auto;
    left: 28px;
    right: 28px;
    width: auto;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--sun));
  }
  .phase {
    grid-template-columns: 1fr;
  }
  .phase-body {
    height: 100%;
  }
}
/* Rôles : quatre cartes ; les pastilles reprennent les couleurs de la salle. */
.roles {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 720px) {
  .roles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1100px) {
  .roles {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.role-card {
  position: relative;
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 24px;
  border-radius: var(--radius-l);
  border: 1px solid var(--line);
  background: var(--surface);
}
.role-card p {
  margin: 0;
  color: var(--fg-muted);
}
.roles .role-badge {
  justify-self: start;
  padding: 4px 12px;
  font-size: 0.875rem;
  background: var(--primary-soft);
  color: var(--primary);
}
.roles .role-badge.role-host {
  background: rgb(255 204 0 / 0.18);
  color: var(--sun-ink);
}
.roles .role-badge.role-viewer {
  background: color-mix(in srgb, var(--fg) 8%, transparent);
  color: var(--fg-muted);
}
/* Ce qu'il vous faut : liste cochée. */
.needs {
  display: grid;
  gap: 28px;
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: var(--surface);
}
@media (min-width: 900px) {
  .needs {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    align-items: center;
  }
}
.checklist {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.checklist .icon {
  flex: none;
  width: 22px;
  height: 22px;
  margin-top: 2px;
  color: var(--ok);
}

/* Questions : thèmes, accès direct à chaque thème. */
.faq-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 28px var(--gutter) 0;
}
.faq-jump a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--fg);
  font-weight: 650;
  font-size: 0.9375rem;
  text-decoration: none;
  transition:
    background-color 200ms var(--ease-out),
    border-color 200ms var(--ease-out);
}
.faq-jump a:hover {
  border-color: var(--primary);
  background: var(--primary-soft);
}
.faq-group {
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.subpage .faq-group {
  padding-top: clamp(40px, 6vw, 72px);
  padding-bottom: 0;
}
.faq-group-title {
  margin: 0 0 20px;
  font-size: clamp(1.375rem, 2.4vw, 1.75rem);
  letter-spacing: -0.015em;
}

/* Appel final des pages : bandeau sobre (la brume reste réservée à l'accueil et à la fin de séance). */
.cta-band-inner {
  display: grid;
  gap: 24px;
  padding: clamp(28px, 5vw, 56px);
  border-radius: var(--radius-xl);
  border: 1px solid rgb(255 255 255 / 0.08);
  background:
    radial-gradient(70% 120% at 100% 0%, rgb(53 87 255 / 0.3), transparent 70%),
    linear-gradient(160deg, #0a1a38, #061229);
  color: #eef3fb;
}
.cta-band-inner .lead {
  color: #b4c2d6;
}
.cta-band-inner .btn-outline {
  --line-strong: rgb(255 255 255 / 0.3);
  color: #eef3fb;
}
@media (min-width: 900px) {
  .cta-band-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }
}

/* Pied de page compact des pages Rejoindre et Organiser. */
.join-footer-links {
  display: flex;
  gap: 16px;
}
.join-footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: inherit;
}

/* ───────────────────────── Nouveautés de démonstration ───────────────────────── */
/* QR code : toujours sur fond blanc (lisible par les téléphones), coins arrondis. */
.qr {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
}
.qr-card {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
}
.qr-box {
  flex: none;
  width: 112px;
  padding: 6px;
  border-radius: 14px;
  background: #fff;
}
.qr-card figcaption {
  display: grid;
  gap: 4px;
  color: var(--fg-muted);
  font-size: 0.875rem;
}
.qr-card figcaption strong {
  color: var(--fg);
  font-size: 0.9375rem;
}
.waiting-qr {
  justify-self: center;
  width: 132px;
  margin: 4px 0;
  padding: 6px;
  border-radius: 14px;
  background: #fff;
}
/* Écran de salle : le QR code en haut à droite, assez grand pour être scanné du fond de la salle. */
.screen-qr-card {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  color: var(--rs-old);
  font-size: clamp(0.9375rem, 1.3vw, 1.125rem);
}
.screen-qr-card figcaption {
  max-width: 16ch;
}
.screen-qr {
  flex: none;
  width: clamp(96px, 9vw, 150px);
  padding: 6px;
  border-radius: 14px;
  background: #fff;
}

/* Sous-titres : délai de traduction et termes du glossaire. */
.caption .who .lat {
  padding: 1px 8px;
  border-radius: 999px;
  background: rgb(74 222 128 / 0.14);
  color: #86efac;
  font-size: 0.75em;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.term {
  position: relative;
  text-decoration: underline dotted color-mix(in srgb, var(--sun) 80%, transparent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.18em;
  cursor: help;
}
/* Équivalent dans l'autre langue, au survol (le title reste pour le clavier et le tactile). */
.term::after {
  content: attr(data-tr);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 6px);
  translate: -50% 4px;
  padding: 3px 10px;
  border-radius: 8px;
  background: #ffcc00;
  color: #06122a;
  font-size: 0.6em;
  font-weight: 750;
  font-style: normal;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition:
    opacity 160ms var(--ease-out),
    translate 160ms var(--ease-out);
}
.term:hover::after {
  opacity: 1;
  translate: -50% 0;
}
/* Le final s'écrit mot à mot, très vite (35 ms par mot), une seule fois. */
@media (prefers-reduced-motion: no-preference) {
  .caption .txt .w {
    display: inline-block;
    animation: word-in 420ms var(--ease-out) both;
    animation-delay: calc(var(--i) * 35ms);
  }
  @keyframes word-in {
    from {
      opacity: 0;
      transform: translateY(0.25em);
      filter: blur(4px);
    }
  }
}

/* Vignette de la personne qui parle : un liseré de lumière fait le tour, rappel du prisme. */
@property --ring-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}
.tile.speaking::after {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 2;
  border-radius: inherit;
  padding: 2px;
  background: conic-gradient(
    from var(--ring-angle),
    transparent 0deg,
    #9faee5 60deg,
    #ffcc00 100deg,
    transparent 160deg,
    transparent 360deg
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .tile.speaking::after {
    animation: ring-spin 2.4s linear infinite;
  }
  @keyframes ring-spin {
    to {
      --ring-angle: 360deg;
    }
  }
}

/* Réactions : sélecteur au-dessus du bouton, émojis qui montent sur la vidéo. */
.react-wrap {
  position: relative;
  display: inline-flex;
}
.react-picker {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  z-index: 8;
  display: flex;
  gap: 4px;
  padding: 6px;
  translate: -50% 0;
  border-radius: 999px;
  border: 1px solid var(--glass-line);
  background: rgb(8 20 46 / 0.96);
  box-shadow: 0 24px 50px -20px rgb(0 0 0 / 0.9);
}
.react-picker[hidden] {
  display: none;
}
.react-choice {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  font-size: 1.625rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 200ms var(--ease-spring);
}
.react-choice:hover,
.react-choice:focus-visible {
  background: rgb(255 255 255 / 0.1);
  transform: scale(1.18);
  outline: none;
}
.react-layer {
  position: absolute;
  right: 6%;
  bottom: 18%;
  z-index: 4;
  width: min(260px, 40%);
  height: 60%;
  pointer-events: none;
}
.react-bubble {
  position: absolute;
  left: var(--x);
  bottom: 0;
  display: grid;
  justify-items: center;
  gap: 2px;
}
.react-emoji {
  font-size: 2.25rem;
  line-height: 1;
  filter: drop-shadow(0 6px 12px rgb(0 0 0 / 0.5));
}
.react-name {
  padding: 1px 8px;
  border-radius: 999px;
  background: rgb(3 10 26 / 0.7);
  color: #eef3fb;
  font-size: 0.75rem;
  font-weight: 650;
  white-space: nowrap;
}
@media (prefers-reduced-motion: no-preference) {
  .react-bubble {
    animation: react-rise 3.2s var(--ease-out) forwards;
  }
  @keyframes react-rise {
    0% {
      opacity: 0;
      transform: translateY(20px) scale(0.6);
    }
    12% {
      opacity: 1;
      transform: translateY(0) scale(1.1);
    }
    80% {
      opacity: 1;
    }
    100% {
      opacity: 0;
      transform: translate(var(--drift), -260px) scale(0.9);
    }
  }
}
@media (prefers-reduced-motion: reduce) {
  .react-bubble {
    animation: react-fade 2.4s linear forwards;
  }
  @keyframes react-fade {
    80% {
      opacity: 1;
    }
    100% {
      opacity: 0;
    }
  }
}

/* ───────────────────────── Fil de sous-titres et cadrage vidéo ───────────────────────── */
/* Fil compact : jusqu'à 3 phrases empilées, la plus récente en bas et en avant ; il ne prend
   pas plus d'un tiers de la scène (la moitié sur téléphone), le haut s'estompe. */
.captions {
  max-height: 36%;
  overflow: hidden;
  align-content: end;
  gap: 6px;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 22px);
  mask-image: linear-gradient(180deg, transparent 0, #000 22px);
}
.caption {
  padding: 9px 16px 11px;
  border-radius: 16px;
  font-size: 1.125rem;
  transition:
    opacity 300ms var(--ease-out),
    font-size 300ms var(--ease-out);
}
.caption.older {
  opacity: 0.68;
  font-size: 0.92em;
}
.caption.older .who .lat {
  display: none;
}
/* Ses propres paroles (si on a choisi de les voir) : plus discrètes que celles des autres. */
.caption.mine {
  opacity: 0.6;
  background: rgb(3 10 26 / 0.6);
}
.captions[data-size="s"] .caption {
  font-size: 0.9375rem;
}
.captions[data-size="l"] .caption {
  font-size: 1.5rem;
}
.captions[data-size="xl"] .caption {
  font-size: 1.9375rem;
}
@media (max-width: 640px) {
  .captions {
    max-height: none;
  }
  .caption {
    font-size: 1rem;
  }
}
.display-check {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  margin-top: 4px;
  font-weight: 600;
  cursor: pointer;
}
.display-check input {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
}

/* Vignettes : l'image entière, jamais rognée sur le visage.
   Paysage : elle remplit la vignette, cadrée un peu au-dessus du centre (là où sont les visages).
   Portrait (caméra de téléphone) : elle s'affiche en entier, sur un fond flou de la même image. */
/* Calée sur les bords de la vignette : sinon sa hauteur suit celle de l'image (2 300 px pour un
   téléphone en portrait dans une vignette de 730 px) et seul le milieu du visage est visible. */
.tile video:not(.backdrop) {
  position: absolute;
  inset: 0;
  z-index: 1;
  object-position: 50% 38%;
}
.tile[data-orient="portrait"]:not(.screen) video:not(.backdrop) {
  object-fit: contain;
}
.tile .backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.15);
  filter: blur(26px) brightness(0.55) saturate(1.2);
  pointer-events: none;
}
.tile:not([data-orient="portrait"]) .backdrop,
.tile.screen .backdrop {
  display: none;
}
.tile.local:not(.screen) .backdrop {
  transform: scaleX(-1) scale(1.15);
}
.tile .tile-label,
.tile .tile-hand,
.tile .avatar {
  z-index: 2;
}
/* Les calques d'une vignette (fond flou, image, nom, lueur de celui qui parle) restent dans la
   vignette : ils ne passent jamais au-dessus des sous-titres ni des panneaux de la salle. */
.tile {
  isolation: isolate;
}

/* Page Rejoindre : l'aperçu montre l'image entière, comme les autres la verront. */
.prejoin .preview video {
  object-fit: contain;
  background: #050f22;
}
