/* Couleurs reprises du site principal (apps/web/src/app/globals.css). */
:root {
  color-scheme: light dark;
  --background: #f7f0e8;
  --foreground: #1b1a24;
  --surface: #fffcf8;
  --border: #e8dfd3;
  --muted: #625d59;
  --brand: #187a4f;
  --brand-strong: #156b45;
  --on-brand: #ffffff;
  --focus: #1b1a24;
  --sun: #ffc23d;
  --coral: #f2544b;
  --leaf: #22a06b;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #1b1a24;
    --foreground: #f3eee8;
    --surface: #252431;
    --border: #34333f;
    --muted: #aba6b0;
    --brand: #2bb07a;
    --brand-strong: #3fbf83;
    --on-brand: #1b1a24;
    --focus: #ffc23d;
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--background);
  color: var(--foreground);
  font-family:
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Bande aux trois couleurs du symbole, en haut de chaque page. */
body::before {
  content: '';
  display: block;
  height: 6px;
  background: linear-gradient(
    90deg,
    var(--sun) 0 33.33%,
    var(--leaf) 33.33% 66.66%,
    var(--coral) 66.66% 100%
  );
}

a {
  color: var(--brand);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--brand-strong);
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  padding: 0.5rem 1rem;
  background: var(--surface);
  color: var(--foreground);
  border-radius: 8px;
  z-index: 10;
}

.skip-link:focus {
  top: 1rem;
}

.wrap {
  width: 100%;
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

header.site {
  padding: 1.5rem 0 0;
}

header.site .brand-link {
  display: inline-block;
  line-height: 0;
}

header.site img {
  height: 2.25rem;
  width: auto;
}

main {
  flex: 1;
}

/* Accueil */
.hero {
  padding: 4.5rem 0 3rem;
  text-align: center;
}

.hero .logo {
  width: min(22rem, 80%);
  height: auto;
}

.hero h1 {
  margin: 2.5rem 0 1rem;
  font-size: clamp(1.75rem, 1.2rem + 2.4vw, 2.6rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.hero .lead {
  margin: 0 auto;
  max-width: 34rem;
  color: var(--muted);
  font-size: 1.1875rem;
  text-wrap: pretty;
}

.status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 2rem;
  padding: 0.5rem 1.1rem;
  border: 1px solid var(--border);
  /* Rayon fixe plutôt qu'une pilule : le texte passe sur deux lignes sur téléphone. */
  border-radius: 1.4rem;
  text-align: left;
  background: var(--surface);
  font-size: 0.975rem;
  font-weight: 600;
}

.status .dot {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--sun);
  flex: none;
}

.nowrap {
  white-space: nowrap;
}

.card {
  margin: 0 0 4rem;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  text-align: center;
}

.card h2 {
  margin: 0 0 0.5rem;
  font-size: 1.375rem;
  line-height: 1.3;
}

.card p {
  margin: 0 0 1.5rem;
  color: var(--muted);
}

.button {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  border-radius: 999px;
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 700;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.button:hover {
  background: var(--brand-strong);
  color: var(--on-brand);
}

/* Pages de texte (confidentialité, 404) */
.prose {
  padding-top: 3rem;
  padding-bottom: 4rem;
}

.prose h1 {
  margin: 0 0 1.5rem;
  font-size: clamp(1.75rem, 1.4rem + 1.6vw, 2.25rem);
  line-height: 1.2;
}

.prose h2 {
  margin: 2rem 0 0.5rem;
  font-size: 1.25rem;
}

.prose p,
.prose ul {
  margin: 0 0 1rem;
}

.prose .meta {
  color: var(--muted);
  font-size: 0.95rem;
}

footer.site {
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.925rem;
}

footer.site .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}

footer.site p {
  margin: 0;
}

footer.site a {
  color: inherit;
}

@media (max-width: 30rem) {
  .hero {
    padding: 3rem 0 2.5rem;
  }

  .card {
    padding: 1.5rem 1.25rem;
  }

  /* Retour à la ligne forcé : la pastille d'état garde ainsi la largeur de son texte. */
  .status .nowrap {
    display: block;
  }
}
