/* Charte : tokens repris du code d'Elsass Dico (src/app/globals.css et tailwind.config.ts).
   Erreurs en vermillon #c2410c (DESIGN.md), jamais en rouge de marque. */

:root {
  --background: hsl(0 0% 100%);
  --foreground: hsl(210 11% 15%);
  --muted: hsl(210 17% 96%);
  --muted-foreground: hsl(210 9% 42%);
  --border: hsl(210 14% 89%);
  --input: hsl(210 14% 59%);
  --ring: hsl(47 86% 38%);
  --primary: hsl(47 86% 56%);
  --primary-hover: hsl(42 80% 46%);
  --primary-foreground: hsl(210 11% 15%);
  --marque-rouge-texte: hsl(0 100% 38%);
  --neutre-50: hsl(20 23% 97%);
  --neutre-100: hsl(24 15% 94%);
  --neutre-600: hsl(20 9% 42%);
  --bordure-forte: hsl(0 0% 7%);
  --succes-texte: hsl(145 45% 31%);
  --succes-fond: hsl(143 39% 91%);
  --attention-texte: hsl(33 73% 30%);
  --attention-fond: hsl(36 70% 90%);
  --erreur: #c2410c;
  --erreur-fond: #fbe6dc;
  --radius: 8px;
  --radius-lg: 16px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--neutre-50);
  color: var(--foreground);
  font-family: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

h1, h2, h3, p { margin: 0; }

.ecran {
  max-width: 480px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 16px 16px 96px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.entete {
  margin: -16px -16px 0;
  padding: 20px 20px 12px;
  background: var(--background);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.kicker {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

.titre-ecran {
  font-family: Azimut, Georgia, 'Times New Roman', serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.1;
  margin-top: 2px;
}

.bandeau-demo {
  padding: 8px 12px;
  border-radius: var(--radius);
  background: var(--attention-fond);
  color: var(--attention-texte);
  font-size: 13px;
  font-weight: 600;
}

.carte {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border-radius: var(--radius-lg);
  background: var(--background);
  border: 1px solid var(--border);
}

.carte-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px;
  border-radius: 12px;
  background: var(--background);
  border: 1px solid var(--border);
}

.titre-section {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

.ligne-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.pastille {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--muted);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.pastille svg { width: 14px; height: 14px; flex-shrink: 0; }
.pastille.succes { background: var(--succes-fond); color: var(--succes-texte); }
.pastille.attente { background: var(--attention-fond); color: var(--foreground); }
.pastille.erreur { background: var(--erreur-fond); color: var(--erreur); }
.pastille.neutre { background: var(--neutre-100); color: var(--neutre-600); }

.petit { font-size: 13px; color: var(--muted-foreground); }

.nombre {
  font-size: 26px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.liste-lignes { display: flex; flex-direction: column; }
.liste-lignes > * {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid var(--neutre-100);
}
.liste-lignes > *:first-child { border-top: none; }

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

.btn {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font: 600 15px 'Archivo', system-ui, sans-serif;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: background-color 180ms cubic-bezier(0.2, 0, 0, 1);
}
.btn:focus-visible,
.lien-nav:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
}
.btn-principal { background: var(--primary); color: var(--primary-foreground); flex: 1; }
.btn-principal:hover { background: var(--primary-hover); }
.btn-contour { background: var(--background); color: var(--foreground); border-color: var(--bordure-forte); flex: 1; }
.btn-contour:hover { background: var(--neutre-50); }
.btn-discret { background: transparent; color: var(--muted-foreground); padding: 0 12px; }
.btn-discret:hover { background: var(--muted); }
.btn-pleine { width: 100%; }

.groupe-actions {
  display: flex;
  gap: 8px;
}

.champ {
  width: 100%;
  padding: 10px 12px;
  border-radius: 4px;
  border: 1px solid var(--input);
  background: var(--background);
  color: var(--foreground);
  font: 15px 'Archivo', system-ui, sans-serif;
}

.lecteur-video {
  align-self: center;
  width: 220px;
  max-width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-lg);
  background: var(--foreground);
  color: var(--background);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  padding: 12px;
  overflow: hidden;
}
.lecteur-video video { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-lg); }

.texte-post {
  font-size: 15px;
  line-height: 1.5;
  white-space: pre-wrap;
}

.message-action {
  min-height: 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--foreground);
}

.erreur-bloc {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  padding: 12px;
  border-radius: var(--radius);
  background: var(--erreur-fond);
  color: var(--erreur);
  font-weight: 600;
  font-size: 14px;
}
.erreur-bloc svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 1px; }

.connexion {
  min-height: 100vh;
  justify-content: center;
}

.nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 64px;
  display: flex;
  background: var(--background);
  border-top: 1px solid var(--border);
  z-index: 10;
}
.lien-nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  text-decoration: none;
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 500;
  position: relative;
}
.lien-nav svg { width: 22px; height: 22px; }
.lien-nav[aria-current="page"] { color: var(--marque-rouge-texte); font-weight: 600; }
.badge {
  position: absolute;
  top: 8px;
  left: 56%;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--marque-rouge-texte);
  color: var(--background);
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.visuellement-cache {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  .btn { transition: none; }
}
