/* RECOMEDIA — feuille unique
   Palette de marque : #203B40 (encre), #378F81 (jade), #F8F9F7 (papier)
   Aucune ressource tierce : polices système, images servies depuis ce domaine. */

:root {
  --encre:        #203B40;
  --encre-douce:  #55706F;
  --encre-faible: #8BA09C;
  --jade:         #378F81;
  --papier:       #F8F9F7;
  --carte:        #FFFFFF;
  --trait:        #E3E7E2;
  --trait-fort:   #CBD3CD;
  --ombre:        0 1px 2px rgba(32, 59, 64, .04), 0 8px 24px -12px rgba(32, 59, 64, .12);
  --ombre-haute:  0 2px 4px rgba(32, 59, 64, .05), 0 22px 44px -20px rgba(32, 59, 64, .26);
  --rayon:        18px;
  --largeur:      880px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --encre:        #ECF1EE;
    --encre-douce:  #9FB2AE;
    --encre-faible: #6F8481;
    --jade:         #5FBCAC;
    --papier:       #121819;
    --carte:        #192122;
    --trait:        #27322F;
    --trait-fort:   #37443F;
    --ombre:        0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .5);
    --ombre-haute:  0 2px 4px rgba(0, 0, 0, .35), 0 22px 44px -20px rgba(0, 0, 0, .7);
  }
}

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

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

body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; }

.enveloppe {
  width: 100%;
  max-width: var(--largeur);
  margin-inline: auto;
  padding-inline: 24px;
}

/* ─────────────────────────  En-tête  ───────────────────────── */

.tete {
  padding: clamp(56px, 11vw, 112px) 0 clamp(36px, 6vw, 60px);
  text-align: center;
}

.tete__logo {
  display: block;
  margin-inline: auto;
  width: clamp(196px, 30vw, 268px);
  height: auto;
}

.tete__ligne {
  margin: 26px auto 0;
  max-width: 42ch;
  color: var(--encre-douce);
  font-size: clamp(16px, 1.7vw, 18px);
  letter-spacing: -0.005em;
  text-wrap: balance;
}

/* ─────────────────────────  Sections  ──────────────────────── */

.domaine { padding-bottom: clamp(40px, 6vw, 64px); }

.domaine__titre {
  margin: 0 0 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--encre-faible);
}

.domaine__titre::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--trait);
}

.grille {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}

/* ─────────────────────────  Cartes  ────────────────────────── */

.carte {
  --teinte: var(--jade);
  --voile: rgba(55, 143, 129, .09);

  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px 46px 20px 20px;
  background: var(--carte);
  border: 1px solid var(--trait);
  border-radius: var(--rayon);
  box-shadow: var(--ombre);
  text-decoration: none;
  transition: transform .22s cubic-bezier(.2, .7, .3, 1),
              box-shadow .22s cubic-bezier(.2, .7, .3, 1),
              border-color .22s ease;
}

a.carte:hover,
a.carte:focus-visible {
  transform: translateY(-3px);
  border-color: var(--trait-fort);
  box-shadow: var(--ombre-haute);
}

a.carte:focus-visible {
  outline: 2px solid var(--teinte);
  outline-offset: 3px;
}

.carte__pastille {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 15px;
  background: var(--voile);
}

.carte__pastille img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  display: block;
}

.carte__texte { min-width: 0; }

.carte__nom {
  display: block;
  margin: 0;
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.015em;
  color: var(--teinte);
}

.carte__quoi {
  display: block;
  margin: 3px 0 0;
  font-size: 14.5px;
  line-height: 1.4;
  color: var(--encre-douce);
}

.carte__fleche {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 15px;
  height: 15px;
  color: var(--encre-faible);
  opacity: 0;
  transform: translate(-3px, 3px);
  transition: opacity .22s ease, transform .22s ease, color .22s ease;
}

a.carte:hover .carte__fleche,
a.carte:focus-visible .carte__fleche {
  opacity: 1;
  transform: none;
  color: var(--teinte);
}

/* Carte sans lien : projet à venir */

.carte--projet { cursor: default; }

.carte--projet .carte__pastille img { opacity: .62; }

.carte__badge {
  display: inline-block;
  margin-left: 8px;
  vertical-align: 1.5px;
  padding: 2px 8px;
  border: 1px solid var(--trait);
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--encre-faible);
}

/* Teintes par site */

.c-mastermood   { --teinte: #1D4B80; --voile: rgba(90, 138, 198, .13); }
.c-mindscaler   { --teinte: #16249B; --voile: rgba(22, 36, 155, .09);  }
.c-gardequipeut { --teinte: #A85B1E; --voile: rgba(194, 105, 31, .11); }
.c-listedattente{ --teinte: #22604F; --voile: rgba(34, 96, 79, .10);   }
.c-pneumopedia  { --teinte: #0E7490; --voile: rgba(14, 116, 144, .10); }
.c-capeclat     { --teinte: #0B2D57; --voile: rgba(141, 167, 140, .17); }

@media (prefers-color-scheme: dark) {
  .carte__pastille { background: #EEF1EC; }

  .c-mastermood   { --teinte: #8FB6E6; --voile: rgba(90, 138, 198, .17); }
  .c-mindscaler   { --teinte: #93A2F2; --voile: rgba(90, 110, 240, .15); }
  .c-gardequipeut { --teinte: #E09A5B; --voile: rgba(194, 105, 31, .16); }
  .c-listedattente{ --teinte: #6FBFA3; --voile: rgba(34, 96, 79, .22);   }
  .c-pneumopedia  { --teinte: #5CBBD4; --voile: rgba(14, 116, 144, .18); }
  .c-capeclat     { --teinte: #A8C4A6; --voile: rgba(141, 167, 140, .16); }
}

/* ─────────────────────────  Pied  ──────────────────────────── */

.pied {
  margin-top: clamp(24px, 5vw, 48px);
  padding: 28px 0 44px;
  border-top: 1px solid var(--trait);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 22px;
  font-size: 13.5px;
  color: var(--encre-faible);
}

.pied a {
  color: var(--encre-douce);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .18s ease, border-color .18s ease;
}

.pied a:hover,
.pied a:focus-visible { color: var(--jade); border-bottom-color: currentColor; }

/* ───────────────────  Page mentions légales  ───────────────── */

.doc { padding: clamp(40px, 7vw, 72px) 0 clamp(32px, 5vw, 56px); max-width: 68ch; }

.doc__retour {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 36px;
  font-size: 14px;
  color: var(--encre-douce);
  text-decoration: none;
}

.doc__retour:hover { color: var(--jade); }

.doc h1 {
  margin: 0 0 28px;
  font-size: clamp(26px, 4.2vw, 34px);
  font-weight: 650;
  letter-spacing: -0.025em;
}

.doc h2 {
  margin: 36px 0 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--encre-faible);
}

.doc p { margin: 0 0 12px; color: var(--encre-douce); }

.doc p strong { color: var(--encre); font-weight: 600; }

.doc a { color: var(--jade); text-decoration-thickness: 1px; text-underline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }
}
