@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/blog/fonts/Newsreader-normal.woff2') format('woff2');
}

@font-face {
  font-family: 'Newsreader';
  font-style: italic;
  font-weight: 200 800;
  font-display: swap;
  src: url('/blog/fonts/Newsreader-italic.woff2') format('woff2');
}

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/blog/fonts/Manrope.woff2') format('woff2');
}

:root {
  --bg:           #f8f9fa;
  --bg-card:      #ffffff;
  --bg-container: #edeeef;
  --text:         #191c1d;
  --text-muted:   #434653;
  --primary:      #00327d;
  --border:       #c3c6d5;
  --outline:      #737784;
  --shadow:       0 12px 40px rgba(25, 28, 29, 0.06);
  --radius:       0.5rem;
  --font-headline: 'Newsreader', serif;
  --font-body:     'Manrope', sans-serif;
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Navigation ──────────────────────────────────────────────── */

header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--border);
}

header nav {
  display: flex;
  gap: 2rem;
  align-items: center;
  padding: 1rem 2rem;
  background: rgba(248, 249, 250, 0.7);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

header nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

header nav a:hover { color: var(--text); }

header nav a.brand {
  margin-right: auto;
  display: flex;
  align-items: center;
}

/* ── Layout ──────────────────────────────────────────────────── */

main {
  flex: 1;
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  width: 100%;
}

/* ── Typographie ─────────────────────────────────────────────── */

h1 {
  font-family: var(--font-headline);
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin-bottom: 2rem;
  color: var(--text);
}

h2 {
  font-family: var(--font-headline);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 2rem 0 1rem;
  color: var(--text);
}

/* ── Liste des articles ──────────────────────────────────────── */

.articles h1 { margin-bottom: 2.5rem; }

.article-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.article-list li {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: box-shadow 0.2s, border-color 0.2s;
}

.article-list li:hover {
  border-color: var(--primary);
  box-shadow: 0 16px 48px rgba(25, 28, 29, 0.1);
}

.article-list li a {
  color: var(--text);
  text-decoration: none;
  font-family: var(--font-headline);
  font-size: 1.15rem;
  font-weight: 600;
  display: block;
  margin-bottom: 0.4rem;
  transition: color 0.2s;
}

.article-list li a:hover { color: var(--primary); }

.article-list time {
  color: var(--text-muted);
  font-size: 0.8rem;
  display: block;
  margin-bottom: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.article-list p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

/* ── Article (single) ────────────────────────────────────────── */

.post-header { margin-bottom: 2.5rem; }

.post-header h1 { margin-bottom: 0.5rem; }

.post-header time {
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.post-content p { margin-bottom: 1.1rem; }

.post-content a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-color: rgba(0, 50, 125, 0.3);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s;
}

.post-content a:hover { text-decoration-color: var(--primary); }

.post-content code {
  background: var(--bg-container);
  border: 1px solid var(--border);
  padding: 0.15em 0.45em;
  border-radius: 4px;
  font-size: 0.875em;
}

.post-content pre {
  background: var(--bg-container);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  overflow-x: auto;
  margin-bottom: 1.1rem;
}

.post-content pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.875em;
}

/* ── Footer ──────────────────────────────────────────────────── */

footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
  text-align: center;
}

footer a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

footer a:hover { text-decoration: underline; }

/* ── Focus visible ───────────────────────────────────────────── */

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 3px;
}
