/* nostress blog — thème Ghost aux couleurs de la charte 2026 de www.nostress.io.
   Jetons, en-tête, pied de page et boutons repris de css/brand.css du site. */

:root {
  --navy: #252f76;
  --navy-2: #2e3f8f;
  --navy-3: #1c2460;
  --blue: #5b8fd6;
  --sky: #badff6;
  --sky-50: #eef5fc;
  --teal: #83c4d7;
  --brand-teal: #047a83;
  --ink: #252f76;
  --text: #4a5170;
  --text-soft: #5c6384;
  --white: #ffffff;

  /* Polices de la charte ; --gh-font-* ne sert que si on choisit d'autres polices dans les réglages Ghost. */
  --font: var(--gh-font-body, "Open Sans"), ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-tag: "Plus Jakarta Sans", var(--font);
  --font-heading: var(--gh-font-heading, var(--font));
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --container: 1200px;
  --text-width: 720px;
  --gutter: 16px;
  --radius: 14px;
  --header-h: 76px;

  /* Couleur d'accent utilisée par les cartes Ghost (boutons, encadrés…) : le bleu marine de la charte. */
  --ghost-accent-color: var(--navy);
}

@media (min-width: 768px) {
  :root { --gutter: 32px; }
}

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

html {
  font-family: var(--font);
  font-size: 16px;
  color: var(--text);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  line-height: 1.55;
  overflow-x: clip;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4, p { margin: 0; }

/* Une seule langue visible : celle de <html lang>. */
html[lang="fr"] [data-l="en"],
html[lang="en"] [data-l="fr"] { display: none !important; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; padding: 0.75rem 1rem; background: var(--navy); color: var(--white); }
.skip-link:focus { left: 1rem; top: 1rem; }

.container { width: min(var(--container), 100% - 2 * var(--gutter)); margin-inline: auto; }
.container--text { width: min(var(--text-width), 100% - 2 * var(--gutter)); }
.container--wide { width: min(1100px, 100% - 2 * var(--gutter)); }

/* ---------- Typographie ---------- */

.display, .article__title, .post-card__title, .gh-content h2, .gh-content h3, .cta-box__title { font-family: var(--font-heading); }

.display {
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 0.005em;
  line-height: 1.08;
  color: var(--ink);
  text-wrap: balance;
}
.display--lg { font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3.25rem); }
.display--md { font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.5rem); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-tag);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
  text-decoration: none;
}
.eyebrow::before {
  content: "";
  flex: none;
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}
.eyebrow--ink { color: #2f7489; }

.lede { font-size: clamp(1.05rem, 0.95rem + 0.4vw, 1.25rem); color: var(--text-soft); max-width: 40rem; }

/* ---------- Boutons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 2px solid transparent;
  background: transparent;
  font-family: inherit;
  line-height: 1.2;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  cursor: pointer;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }
.btn--primary { background: var(--navy); color: var(--white); }
.btn--primary:hover { background: var(--navy-2); }
.btn--white { background: var(--white); color: var(--navy); }
.btn--white:hover { background: var(--sky); }
.btn--ghost { border-color: rgba(255, 255, 255, 0.7); color: var(--white); }
.btn--ghost:hover { background: rgba(255, 255, 255, 0.12); }
.btn--outline { border-color: var(--navy); color: var(--navy); }
.btn--outline:hover { background: var(--sky-50); }
.btn--sm { min-height: 40px; padding: 0.45rem 1.1rem; font-size: 0.9rem; }

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(37, 47, 118, 0.1);
}
.site-header__bar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}
.site-header__logo img { height: 52px; width: auto; }
.site-header__claim { display: none; }
@media (max-width: 1079px) {
  .site-header__claim {
    display: block;
    flex: 1;
    padding: 0 0.5rem;
    text-align: center;
    font-family: var(--font-tag);
    font-size: 0.66rem;
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #3f6fc0;
    white-space: nowrap;
  }
}
@media (max-width: 339px) { .site-header__claim { display: none; } }
@media (min-width: 1280px) {
  .site-header__claim {
    display: block;
    margin: 0 auto 0 0.25rem;
    padding-inline-start: 1.1rem;
    border-inline-start: 1px solid rgba(37, 47, 118, 0.18);
    font-family: var(--font-tag);
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #3f6fc0;
    white-space: nowrap;
  }
}

.menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(37, 47, 118, 0.3);
  background: var(--white);
  color: var(--navy);
  cursor: pointer;
}
.menu-toggle svg { width: 22px; height: 22px; }

.site-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: calc(-1 * var(--gutter));
  right: calc(-1 * var(--gutter));
  max-height: calc(100vh - var(--header-h));
  overflow-y: auto;
  background: var(--white);
  border-bottom: 1px solid rgba(37, 47, 118, 0.12);
  box-shadow: 0 20px 40px -24px rgba(37, 47, 118, 0.35);
  padding: 0.75rem var(--gutter) 1.25rem;
}
.site-nav[data-open="true"] { display: block; }
.site-nav__list { display: flex; flex-direction: column; gap: 0.25rem; }
.site-nav__actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(37, 47, 118, 0.12);
}

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  color: var(--navy);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.nav-link:hover { background: var(--sky-50); }
.nav-link:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }
.nav-link[data-active="true"] { background: var(--navy); color: var(--white); }

.lang-toggle {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid rgba(37, 47, 118, 0.3);
}
.lang-toggle__item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 36px;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  color: var(--navy);
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
}
.lang-toggle__item img { width: 18px; height: 18px; border-radius: 999px; }
.lang-toggle__item:hover { background: var(--sky-50); }
html[lang="fr"] .lang-toggle__item[data-current-l="fr"],
html[lang="en"] .lang-toggle__item[data-current-l="en"] { background: var(--sky); }

@media (min-width: 1080px) {
  .menu-toggle { display: none; }
  .site-nav {
    position: static;
    display: flex;
    align-items: center;
    gap: 1rem;
    max-height: none;
    overflow: visible;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }
  .site-nav__list { flex-direction: row; align-items: center; gap: 0.15rem; }
  .site-nav__actions { flex-direction: row; align-items: center; margin: 0; padding: 0; border: 0; }
}

/* ---------- Accueil du blog ---------- */

.blog-hero {
  background: var(--navy);
  color: rgba(255, 255, 255, 0.86);
  padding-block: clamp(3rem, 2rem + 4vw, 5.5rem);
}
.blog-hero__inner { display: grid; gap: 1.1rem; justify-items: start; }
.blog-hero .display { color: var(--white); }
.blog-hero .lede { color: var(--sky); }
.blog-hero--small { padding-block: clamp(2.5rem, 2rem + 2vw, 3.5rem); }

.section--list { padding-block: clamp(2.5rem, 1.5rem + 3vw, 4.5rem); background: var(--sky-50); }

.post-grid {
  display: grid;
  gap: clamp(1.25rem, 1rem + 1vw, 2rem);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
}

.post-card {
  display: flex;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 1px 0 rgba(37, 47, 118, 0.06), 0 18px 36px -28px rgba(37, 47, 118, 0.45);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.post-card:hover { transform: translateY(-2px); box-shadow: 0 1px 0 rgba(37, 47, 118, 0.06), 0 24px 44px -26px rgba(37, 47, 118, 0.55); }
.post-card__link { display: flex; flex-direction: column; width: 100%; text-decoration: none; color: inherit; }
.post-card__link:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: var(--radius); }
.post-card__media { aspect-ratio: 16 / 9; overflow: hidden; background: var(--sky); }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; }
.post-card__body { display: grid; gap: 0.6rem; align-content: start; flex: 1; padding: 1.25rem 1.4rem 1.5rem; }
.post-card__body .eyebrow { font-size: 0.7rem; letter-spacing: 0.14em; }
.post-card__body .eyebrow::before { width: 18px; }
.post-card__title { font-size: 1.2rem; font-weight: 700; line-height: 1.3; color: var(--navy); text-wrap: balance; }
.post-card__excerpt { color: var(--text-soft); font-size: 0.95rem; }
.post-card__meta { margin-top: auto; padding-top: 0.4rem; font-size: 0.85rem; color: var(--text-soft); }

.pagination { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-top: 2.5rem; color: var(--navy); font-weight: 600; }

/* ---------- Article ---------- */

.article { padding-top: clamp(2.5rem, 1.5rem + 3vw, 4.5rem); }
.article__head { display: grid; gap: 1rem; justify-items: start; margin-bottom: clamp(1.75rem, 1rem + 2vw, 2.75rem); }
.article__title {
  font-weight: 300;
  font-size: clamp(2rem, 1.3rem + 2.4vw, 3.1rem);
  line-height: 1.12;
  color: var(--ink);
  text-wrap: balance;
}
.article__excerpt { font-size: clamp(1.1rem, 1rem + 0.4vw, 1.3rem); line-height: 1.5; color: var(--text-soft); }
.article__meta { display: flex; flex-wrap: wrap; gap: 0.4rem; font-size: 0.9rem; color: var(--text-soft); }

.translation-link a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: var(--sky-50);
  color: var(--navy);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
}
.translation-link a:hover { background: var(--sky); }

.article__image { margin-block: 0 clamp(2rem, 1rem + 3vw, 3.5rem); }
.article__image img { width: 100%; border-radius: var(--radius); }
.article__image figcaption { margin-top: 0.6rem; text-align: center; font-size: 0.85rem; color: var(--text-soft); }

/* Contenu rédigé dans l'éditeur Ghost */
.gh-content { font-size: 1.125rem; line-height: 1.75; color: var(--text); }
.gh-content > * + * { margin-top: 1.4em; }
.gh-content h2, .gh-content h3, .gh-content h4 { color: var(--navy); line-height: 1.25; }
.gh-content h2 { margin-top: 2.2em; font-size: clamp(1.45rem, 1.2rem + 0.8vw, 1.85rem); font-weight: 700; }
.gh-content h3 { margin-top: 1.9em; font-size: 1.3rem; font-weight: 700; }
.gh-content h4 { margin-top: 1.6em; font-family: var(--font-tag); font-size: 0.85rem; letter-spacing: 0.14em; text-transform: uppercase; color: #2f7489; }
.gh-content h2 + *, .gh-content h3 + *, .gh-content h4 + * { margin-top: 0.7em; }
.gh-content strong { color: var(--navy); font-weight: 700; }
.gh-content a { color: var(--navy); text-decoration-color: var(--blue); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.gh-content a:hover { color: var(--brand-teal); }
.gh-content ul, .gh-content ol { padding-inline-start: 1.4em; }
.gh-content li + li { margin-top: 0.45em; }
.gh-content li::marker { color: var(--blue); }
.gh-content blockquote {
  margin-inline: 0;
  padding: 0.25em 0 0.25em 1.25em;
  border-inline-start: 3px solid var(--teal);
  color: var(--navy);
  font-size: 1.2rem;
  font-style: italic;
}
.gh-content blockquote.kg-blockquote-alt { border: 0; padding: 0; text-align: center; font-size: 1.5rem; font-weight: 300; font-style: normal; }
.gh-content hr { height: 1px; border: 0; background: rgba(37, 47, 118, 0.15); margin-block: 2.5em; }
.gh-content code { font-family: var(--font-mono); font-size: 0.88em; padding: 0.1em 0.35em; border-radius: 6px; background: var(--sky-50); color: var(--navy); }
.gh-content pre { overflow-x: auto; padding: 1.1rem 1.25rem; border-radius: var(--radius); background: var(--navy-3); color: var(--sky-50); font-size: 0.9rem; line-height: 1.6; }
.gh-content pre code { padding: 0; background: none; color: inherit; }
.gh-content figure { margin-inline: 0; }
.gh-content figcaption { margin-top: 0.6rem; text-align: center; font-size: 0.85rem; color: var(--text-soft); }
.gh-content img { border-radius: 10px; }
.gh-content table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.gh-content th, .gh-content td { padding: 0.6rem 0.75rem; border-bottom: 1px solid rgba(37, 47, 118, 0.12); text-align: start; }
.gh-content th { color: var(--navy); }

/* Cartes larges et pleine largeur de l'éditeur Ghost */
.kg-width-wide { width: min(1100px, 100vw - 2 * var(--gutter)); margin-inline: calc(50% - min(1100px, 100vw - 2 * var(--gutter)) / 2); }
.kg-width-full { width: 100vw; margin-inline: calc(50% - 50vw); }
.kg-width-full img { border-radius: 0; }
.gh-content .kg-callout-card, .gh-content .kg-toggle-card, .gh-content .kg-bookmark-container { border-radius: var(--radius); }
.gh-content .kg-btn, .gh-content .kg-button-card a.kg-btn { border-radius: 999px; font-weight: 700; }

/* Encadré de fin d'article */
.cta-box {
  margin-block: clamp(2.5rem, 1.5rem + 3vw, 4rem);
  padding: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  border-radius: 24px;
  background: var(--navy);
  color: rgba(255, 255, 255, 0.86);
}
.cta-box > div { display: grid; gap: 0.9rem; justify-items: start; }
.cta-box__title { font-size: clamp(1.35rem, 1.1rem + 0.9vw, 1.8rem); font-weight: 300; text-transform: uppercase; line-height: 1.15; color: var(--white); }
.cta-box__text { color: var(--sky); }
.cta-box__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 0.5rem; }

.related { padding-block: clamp(2.5rem, 1.5rem + 3vw, 4.5rem); background: var(--sky-50); }
.related__title { margin-bottom: 1.5rem; font-family: var(--font-tag); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: #2f7489; }

/* ---------- Pied de page ---------- */

.site-footer { background: var(--navy-3); color: rgba(255, 255, 255, 0.7); font-size: 0.92rem; }
.site-footer__grid { display: grid; gap: 2rem; padding-block: 3rem; grid-template-columns: 1fr; }
.site-footer__logo { display: grid; gap: 1rem; justify-items: start; }
.site-footer__logo img { height: 72px; width: auto; }
.site-footer__logo p { max-width: 22rem; }
.site-footer h2 {
  margin-bottom: 0.75rem;
  font-family: var(--font-tag);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--teal);
}
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.4rem; }
.site-footer a:not(.btn) { text-decoration: none; }
.site-footer a:not(.btn):hover { color: var(--white); text-decoration: underline; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.site-footer__legal { display: flex; gap: 1.25rem; }
.footer-social { display: inline-flex; align-items: center; gap: 0.45rem; }

@media (min-width: 768px) {
  .site-footer__grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .btn, .post-card { transition: none; }
  .btn:hover, .post-card:hover { transform: none; }
}
