/* GAIA - feuille de style unique
   Charte : navy #001141, teal #186A6B, fonds clairs.
   Typographie : Montserrat (titres, logo textuel, navigation), Inter (texte).
   Mobile-first : une colonne sous 768 px. */


/* 1. Polices auto-hebergees ----------------------------------------------- */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/Inter-Regular.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/Inter-Medium.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/Inter-Bold.woff2") format("woff2");
}

@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/Montserrat-SemiBold.woff2") format("woff2");
}

@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/Montserrat-Bold.woff2") format("woff2");
}


/* 2. Tokens --------------------------------------------------------------- */

:root {
  --color-navy: #001141;
  --color-teal: #186A6B;
  --color-ink: #0F1B2D;
  --color-muted: #4A5566;
  --color-line: #E1E5EB;
  --color-surface: #FFFFFF;
  --color-canvas: #F6F7F9;
  --color-teal-hover: #125355;
  --color-focus: #186A6B;

  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Montserrat", "Inter", system-ui, sans-serif;

  --fs-100: 0.875rem;
  --fs-200: 1rem;
  --fs-300: 1.125rem;
  --fs-400: 1.375rem;
  --fs-500: 1.75rem;
  --fs-600: 2.25rem;
  --fs-700: 2.75rem;

  --lh-tight: 1.2;
  --lh-snug: 1.35;
  --lh-normal: 1.6;

  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;
  --sp-9: 6rem;

  --radius-sm: 4px;
  --radius-md: 8px;

  --container: 72rem;
  --content: 44rem;
  --header-h: 64px;
}


/* 3. Reset minimal -------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--sp-4));
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--fs-200);
  line-height: var(--lh-normal);
  color: var(--color-ink);
  background: var(--color-canvas);
  -webkit-font-smoothing: antialiased;
}

img,
svg,
picture {
  max-width: 100%;
  height: auto;
  display: block;
}

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

a:hover { color: var(--color-teal-hover); }

:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}


/* 4. Typographie ---------------------------------------------------------- */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--color-navy);
  line-height: var(--lh-tight);
  margin: 0 0 var(--sp-4);
  font-weight: 700;
  letter-spacing: -0.01em;
}

h1 { font-size: var(--fs-600); }
h2 { font-size: var(--fs-500); }
h3 { font-size: var(--fs-400); font-weight: 600; }
h4 { font-size: var(--fs-300); font-weight: 600; }

p { margin: 0 0 var(--sp-4); }

.eyebrow {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-100);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-teal);
  margin: 0 0 var(--sp-3);
}


/* 5. Layout primitives ---------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--sp-5);
  padding-right: var(--sp-5);
}

.content {
  max-width: var(--content);
}

.section {
  padding-top: var(--sp-7);
  padding-bottom: var(--sp-7);
  scroll-margin-top: var(--header-h);
}

.section--dark {
  background: var(--color-navy);
  color: #E7ECF3;
}

.section--dark h1,
.section--dark h2,
.section--dark h3,
.section--dark h4 { color: #FFFFFF; }

/* Cards keep their light surface even inside dark sections, so their
   title must stay navy to remain legible. */
.section--dark .card__title { color: var(--color-navy); }

.section--dark .eyebrow { color: #6FB3BE; }

.section--dark a { color: #7ECBD5; }

.section--dark .contact__meta { color: #C7CFDB; }

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
}


/* 6. Header sticky et navigation ----------------------------------------- */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-navy);
  color: #FFFFFF;
  padding: var(--sp-3) var(--sp-4);
  z-index: 100;
}

.skip-link:focus {
  left: var(--sp-3);
  top: var(--sp-3);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: saturate(180%) blur(6px);
  border-bottom: 1px solid var(--color-line);
  min-height: var(--header-h);
}

.site-header__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  min-height: var(--header-h);
}

.site-header__brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  /* Typographie posee ici aussi : sert de mise en forme pour l'alt text
     si logo-gaia-wordmark.svg echoue a charger. */
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-300);
  color: var(--color-navy);
  letter-spacing: 0.02em;
  line-height: 1;
}

.site-header__logo {
  display: block;
  height: 26px;
  width: auto;
}

.site-nav {
  display: none;
}

.site-nav__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: var(--sp-5);
}

.site-nav__link {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-100);
  color: var(--color-ink);
  text-decoration: none;
  padding: var(--sp-2) 0;
  border-bottom: 2px solid transparent;
}

.site-nav__link[aria-current="page"] {
  color: var(--color-teal);
  border-bottom-color: var(--color-teal);
}

.lang-switch {
  font-size: var(--fs-100);
  color: var(--color-muted);
}

.lang-switch a { text-decoration: none; }
.lang-switch a[aria-current="page"] { color: var(--color-navy); font-weight: 700; }


/* 7. Boutons -------------------------------------------------------------- */

.button {
  display: inline-block;
  padding: var(--sp-3) var(--sp-5);
  font-family: var(--font-body);
  font-size: var(--fs-200);
  font-weight: 700;
  border-radius: var(--radius-md);
  text-decoration: none;
  border: 1px solid transparent;
  transition: background-color 120ms ease, color 120ms ease, border-color 120ms ease;
}

.button--primary {
  background: var(--color-teal);
  color: #FFFFFF;
}

.button--primary:hover { background: var(--color-teal-hover); color: #FFFFFF; }

.button--ghost {
  background: transparent;
  color: var(--color-navy);
  border-color: var(--color-navy);
}

.button--ghost:hover { background: var(--color-navy); color: #FFFFFF; }


/* 8. Composant : hero ---------------------------------------------------- */

.hero {
  /* Espace du haut resserre pour que H1 + lede + boutons tiennent dans un
     ecran de portable 16:9 (~568 px de haut, - 64 px de header sticky)
     sans obliger a scroller. */
  padding-top: var(--sp-5);
  padding-bottom: var(--sp-7);
  background: linear-gradient(180deg, var(--color-canvas) 0%, var(--color-surface) 100%);
}

.hero__title {
  font-size: var(--fs-600);
  max-width: 22ch;
}

.hero__lede {
  font-size: var(--fs-300);
  color: var(--color-muted);
  max-width: 48ch;
  margin-bottom: var(--sp-5);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
}


/* 9. Composant : card ---------------------------------------------------- */

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  padding: var(--sp-5);
  /* Hauteur minimale + alignement haut : evite l'effondrement quand le
     texte est court, garde les cartes stables quand les longueurs sont
     inegales entre colonnes. La grille etire deja les cartes voisines
     via align-items: stretch par defaut. */
  min-height: 12rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.card__icon {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--color-teal);
  margin-bottom: var(--sp-3);
}

.card__title {
  font-size: var(--fs-300);
  margin-bottom: var(--sp-3);
}

.card__body { color: var(--color-muted); }

.card__body > *:last-child { margin-bottom: 0; }


/* 10. Composant : timeline ---------------------------------------------- */

.timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--sp-5);
}

.timeline__item {
  position: relative;
  padding-left: var(--sp-6);
  border-left: 2px solid var(--color-line);
}

.timeline__dot {
  position: absolute;
  left: -7px;
  top: var(--sp-1);
  width: 14px;
  height: 14px;
  box-sizing: border-box;
  border-radius: 50%;
  background: var(--color-teal);
  border: 1.5px solid var(--color-teal);
  z-index: 1;
}

.timeline__item:has(.timeline__status--planned) .timeline__dot {
  background: transparent;
}

.timeline__item:has(.timeline__status--current) .timeline__dot {
  box-shadow: 0 0 0 4px rgba(24, 106, 107, 0.2);
}

.timeline__date {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--color-teal);
  font-size: var(--fs-100);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: block;
  margin-bottom: var(--sp-2);
}

.timeline__title {
  font-size: var(--fs-300);
  margin-bottom: var(--sp-2);
  font-weight: 600;
}

.timeline__status {
  display: inline-block;
  font-family: var(--font-display);
  font-size: var(--fs-100);
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 999px;
  letter-spacing: 0.02em;
  margin: 0;
}

.timeline__status--done {
  background: rgba(24, 106, 107, 0.15);
  color: var(--color-teal);
}

.timeline__status--current {
  background: var(--color-teal);
  color: #FFFFFF;
}

.timeline__status--planned {
  background: transparent;
  color: var(--color-muted);
  border: 1px solid var(--color-line);
}

.callout {
  margin: var(--sp-6) 0 0;
  padding: var(--sp-3) var(--sp-4);
  border-left: 3px solid var(--color-teal);
  font-size: var(--fs-100);
  color: var(--color-muted);
}

.section--dark .callout {
  border-left-color: #7ECBD5;
  color: #D8DEE7;
}


/* 10b. Composant : flow (chaine de valeur du procede) ------------------- */

.flow {
  list-style: none;
  padding: 0;
  margin: var(--sp-6) 0 var(--sp-7);
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
  color: #7ECBD5;
}

.flow .icon {
  width: 2rem;
  height: 2rem;
}

.flow__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  position: relative;
  text-align: center;
}

.flow__label {
  color: #D8DEE7;
  font-family: var(--font-body);
  font-size: var(--fs-100);
  line-height: 1.3;
  max-width: 16ch;
}

.flow__step:not(:last-child)::after {
  content: "\2193"; /* down arrow */
  font-size: 1.25rem;
  line-height: 1;
  margin-top: var(--sp-1);
}


/* 10d. Founder block (portrait plus texte, section Societe) ------------ */

/* Grid deux colonnes : le texte n'habille jamais la photo, il occupe une
   colonne dediee de largeur 1fr a cote d'une colonne fixe de 140px. */
.founder {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
  align-items: start;
}

.founder__media picture {
  display: block;
  line-height: 0;
}

.founder__photo {
  width: 140px;
  height: 140px;
  display: block;
}

.founder__text > *:last-child { margin-bottom: 0; }

@media (min-width: 48em) {
  .founder {
    grid-template-columns: 140px 1fr;
  }
}

/* Hierarchie de la section Societe : les h3 doivent se lire comme des
   sous-titres, nettement moins forts que le h2 de la section. */
#company h3 {
  font-size: var(--fs-200);
  font-weight: 600;
  color: var(--color-navy);
  margin: var(--sp-6) 0 var(--sp-3);
}

#company h3:first-of-type {
  margin-top: 0;
}


/* 10c. Pullquote (accroche pleine largeur entre Probleme et Approche) --- */

.pullquote-section {
  padding: var(--sp-7) var(--sp-5);
}

.pullquote {
  max-width: 34rem;
  margin: 0 auto;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-500);
  color: var(--color-navy);
  line-height: 1.25;
}


/* 11. Contact ------------------------------------------------------------ */

.contact__email,
.contact__phone {
  font-family: var(--font-display);
  font-size: var(--fs-400);
  font-weight: 600;
}

.contact__meta {
  color: var(--color-muted);
  font-size: var(--fs-100);
}


/* 12. Footer ------------------------------------------------------------- */

.site-footer {
  background: var(--color-navy);
  color: #C7CFDB;
  padding: var(--sp-6) 0;
  font-size: var(--fs-100);
}

.site-footer a { color: #7ECBD5; text-decoration: none; }

.site-footer a:hover,
.site-footer a:focus-visible { text-decoration: underline; }

.site-footer__row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  justify-content: space-between;
  align-items: center;
}

.site-footer__brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  line-height: 1;
}

.site-footer__logo {
  display: block;
  height: 26px;
  width: auto;
}

.site-footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: var(--sp-4);
  flex-wrap: wrap;
}


/* 13. Utilitaires -------------------------------------------------------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.icon {
  width: 1.75rem;
  height: 1.75rem;
  display: block;
}

.todo {
  border: 1px dashed var(--color-line);
  background: #FFFCEA;
  color: #6B5A00;
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: var(--fs-100);
}

.section--dark .todo {
  background: rgba(255, 255, 255, 0.08);
  color: #E7ECF3;
  border-color: rgba(255, 255, 255, 0.2);
}


/* 14. Breakpoints -------------------------------------------------------- */

@media (min-width: 48em) {
  h1 { font-size: var(--fs-700); }
  .hero__title { font-size: var(--fs-700); }
  .hero { padding-top: var(--sp-7); padding-bottom: var(--sp-8); }
  .hero__lede { margin-bottom: var(--sp-6); }
  .site-nav { display: block; }
  .grid--2 { grid-template-columns: 1fr 1fr; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .section { padding-top: var(--sp-8); padding-bottom: var(--sp-8); }

  .flow {
    flex-direction: row;
    align-items: flex-start;
    gap: var(--sp-4);
  }
  .flow__step { flex: 1; }
  .flow__step:not(:last-child)::after {
    content: "\2192"; /* right arrow */
    position: absolute;
    top: 1rem; /* half of .icon height in the flow (2rem), aligned with icon center */
    right: -0.5rem; /* half of the gap between two steps */
    transform: translate(50%, -50%);
    margin: 0;
    font-size: 1.1rem;
    line-height: 1;
  }
}

@media (min-width: 64em) {
  .grid--4 { grid-template-columns: repeat(4, 1fr); }

  .timeline {
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: auto auto auto auto;
    grid-auto-flow: column;
    column-gap: var(--sp-4);
    row-gap: var(--sp-3);
    position: relative;
  }

  /* Horizontal connecting line between first and last dot centres.
     top = date height (fs-100 * line-height) + row-gap + half dot.
     right = column width - half dot; column width uses the same 5col/4gap
     formula as the grid template. */
  .timeline::before {
    content: "";
    position: absolute;
    top: calc(var(--fs-100) * 1.6 + var(--sp-3) + 7px);
    left: 7px;
    right: calc((100% - 4 * var(--sp-4)) / 5 - 7px);
    height: 1px;
    background: var(--color-line);
    z-index: 0;
  }

  .timeline__item {
    display: contents;
  }

  .timeline__date { margin: 0; }

  .timeline__dot {
    position: relative;
    left: auto;
    top: auto;
    justify-self: start;
  }

  .timeline__title {
    margin: 0;
    font-size: var(--fs-200);
    line-height: 1.3;
  }

  .timeline__status {
    margin: 0;
    justify-self: start;
  }
}
