/* Nibi blog — shared styles. Mirrors the design tokens used across the marketing pages. */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --accent: oklch(52% 0.12 160);
  --text: oklch(18% 0.01 155);
  --text-muted: oklch(40% 0.02 155);
  --bg: oklch(99% 0.005 155);
  --bg-warm: oklch(97% 0.008 155);
  --border: oklch(90% 0.01 155);
  --font-serif: 'Literata', Georgia, serif;
  --font-sans: 'Source Sans 3', system-ui, sans-serif;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

header {
  padding: 1.25rem 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header .brand {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.header-links { display: flex; align-items: center; gap: 1.25rem; }

.header-links a {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--text-muted);
  text-decoration: none;
}
.header-links a:hover { color: var(--accent); }

main {
  max-width: 720px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 5rem;
}

/* ---- Article typography ---- */
article h1, .page-title {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 1rem;
  line-height: 1.25;
}

.post-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

.lead {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

article h2 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  margin: 2.75rem 0 1rem;
  line-height: 1.3;
}

article h3 {
  font-family: var(--font-sans);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  margin: 1.75rem 0 0.75rem;
}

article p { font-size: 1.08rem; margin-bottom: 1.4rem; }
article ul, article ol { margin: 0 0 1.6rem 1.4rem; }
article li { font-size: 1.08rem; margin-bottom: 0.6rem; }
article strong { font-weight: 600; }
article a { color: var(--accent); }

.highlight-block {
  background: var(--bg-warm);
  border-left: 3px solid var(--accent);
  padding: 1.5rem 1.75rem;
  margin: 2.5rem 0;
  border-radius: 0 8px 8px 0;
}
.highlight-block p {
  margin-bottom: 0;
  font-family: var(--font-serif);
  font-size: 1.12rem;
  font-style: italic;
  color: var(--text-muted);
}

.faq { margin-top: 1rem; }
.faq h3 { margin-bottom: 0.4rem; }
.faq p { margin-bottom: 1.6rem; }

.sources {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-size: 0.92rem;
  color: var(--text-muted);
}
.sources h2 { font-size: 1.2rem; margin-top: 0; }
.sources li { font-size: 0.92rem; }

.cta-row { margin-top: 3rem; text-align: center; }
.cta-row a {
  display: inline-block;
  background: var(--accent);
  color: oklch(99% 0.005 155);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1rem;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  text-decoration: none;
  transition: opacity 0.2s ease;
}
.cta-row a:hover { opacity: 0.88; }

/* ---- Blog index ---- */
.index-intro { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 2.5rem; }

.post-card-wrap { margin-bottom: 1.75rem; }
.post-card {
  display: block;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1.75rem;
  margin-bottom: 0.6rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.post-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.post-card .card-title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}
.post-card .card-excerpt { color: var(--text-muted); font-size: 1rem; margin-bottom: 0; }
.card-meta { color: var(--text-muted); font-size: 0.85rem; padding: 0 0.25rem; }
.card-meta a { color: var(--accent); text-decoration: none; }

.lang-switch { margin-bottom: 2rem; font-size: 0.9rem; color: var(--text-muted); }
.lang-switch a { color: var(--accent); text-decoration: none; margin: 0 0.35rem; }
.lang-switch a[aria-current="true"] { color: var(--text-muted); font-weight: 600; text-decoration: none; }

footer {
  text-align: center;
  padding: 2rem 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
}
footer a { color: var(--text-muted); margin: 0 0.75rem; text-decoration: none; }
footer a:hover { color: var(--accent); }

@media (max-width: 600px) {
  header { padding: 1.25rem 1.25rem; }
  main { padding: 2.25rem 1.25rem 3rem; }
  article h1, .page-title { font-size: 1.8rem; }
  .lead { font-size: 1.12rem; }
  article h2 { font-size: 1.4rem; }
}
