/* Reuterborg reader stylesheet — shared across /blogg/ articles + blog index */
:root {
  --ink: #1c1c1e;
  --ink-soft: #6b6b70;
  --ink-faint: #a5a5a8;
  --line: rgba(28,28,30,0.10);
  --line-strong: rgba(28,28,30,0.18);
  --paper: #ffffff;
  --paper-warm: #fafaf9;
  --accent: #1c1c1e;
  --glass-blur: 36px;
  --glass-sat: 180%;
  --reader-width: 720px;
  --site-width: 1040px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  font-size: 18px;
  line-height: 1.65;
}
a { color: inherit; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
img { max-width: 100%; height: auto; }

/* ============================================================
   GLASS — clone of homepage spec
   ============================================================ */
.glass {
  position: relative;
  background: rgba(255, 255, 255, 0.42);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat));
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat));
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.95),
    inset 0 -1px 1px rgba(255, 255, 255, 0.25),
    0 1px 2px rgba(20, 20, 40, 0.04),
    0 18px 40px -18px rgba(30, 30, 60, 0.22),
    0 36px 80px -30px rgba(30, 30, 60, 0.18);
  overflow: hidden;
}

/* ============================================================
   STICKY NAV — clone of homepage nav
   ============================================================ */
.nav-wrap {
  position: fixed; top: 16px; left: 0; right: 0; z-index: 20;
  padding: 0 24px;
}
nav.bar {
  max-width: var(--site-width); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 16px 8px 22px; border-radius: 999px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img.logo-mark { height: 44px; width: auto; display: block; }
nav .links { display: flex; gap: 2px; font-size: 13px; }
nav .links a {
  padding: 8px 14px; border-radius: 999px; text-decoration: none;
  color: var(--ink-soft); transition: background 0.2s, color 0.2s;
}
nav .links a:hover { color: var(--ink); background: rgba(255,255,255,0.6); }
nav .cta {
  background: var(--ink); color: #fff; padding: 0 18px; height: 36px;
  display: inline-flex; align-items: center; border-radius: 999px;
  text-decoration: none; font-size: 13px; font-weight: 500;
}
nav .cta:hover { opacity: 0.9; }
nav .nav-right { display: flex; align-items: center; gap: 8px; }
nav .account {
  width: 36px; height: 36px; border-radius: 50%; background: transparent;
  color: var(--ink); display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none; transition: opacity 0.2s; overflow: visible;
}
nav .account:hover { opacity: 0.75; }
nav .account img { width: 150%; height: 150%; display: block; object-fit: contain; }

/* ============================================================
   ARTICLE LAYOUT
   ============================================================ */
.reader {
  max-width: var(--reader-width); margin: 0 auto;
  padding: 120px 24px 80px;
}
.reader-wide { max-width: var(--site-width); margin: 0 auto; padding: 0 24px; }

.breadcrumb {
  font-size: 13px; color: var(--ink-soft);
  margin-bottom: 32px;
  letter-spacing: 0.01em;
}
.breadcrumb a { text-decoration: none; color: var(--ink-soft); }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb .sep { margin: 0 8px; color: var(--ink-faint); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  font-weight: 600; color: var(--ink-soft);
  margin: 0 0 18px;
}
.eyebrow::before {
  content: ""; width: 28px; height: 1px; background: var(--ink-soft);
}

h1.title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: clamp(38px, 5vw, 56px);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.05;
  margin: 0 0 24px;
  color: var(--ink);
}
h1.title em { font-style: italic; }

.lede {
  font-size: 21px; line-height: 1.55; color: var(--ink);
  margin: 0 0 32px; font-weight: 400;
}

.meta-row {
  display: flex; align-items: center; gap: 14px;
  padding: 18px 0 24px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin: 0 0 40px;
  font-size: 13px; color: var(--ink-soft);
}
.meta-row .avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background-size: cover; background-position: center;
  flex-shrink: 0;
}
.meta-row .who { color: var(--ink); font-weight: 500; }
.meta-row .sep-dot { color: var(--ink-faint); }

/* TOC */
.toc {
  margin: 0 0 48px;
  padding: 20px 24px;
  background: var(--paper-warm);
  border-radius: 14px;
  border: 1px solid var(--line);
}
.toc .toc-label {
  font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink-soft); margin: 0 0 12px; font-weight: 600;
}
.toc ol { margin: 0; padding-left: 22px; }
.toc li { margin: 4px 0; font-size: 15px; }
.toc a { color: var(--ink); text-decoration: none; }
.toc a:hover { text-decoration: underline; }

/* Body */
.article-body h2 {
  font-size: 28px; font-weight: 700; line-height: 1.2;
  margin: 64px 0 18px; color: var(--ink);
  letter-spacing: -0.01em;
  scroll-margin-top: 100px;
}
.article-body h2:first-child { margin-top: 0; }
.article-body h3 {
  font-size: 20px; font-weight: 700; line-height: 1.3;
  margin: 36px 0 12px; color: var(--ink);
}
.article-body p { margin: 0 0 18px; }
.article-body ul, .article-body ol { margin: 0 0 20px; padding-left: 24px; }
.article-body li { margin: 6px 0; }
.article-body a { color: var(--ink); }

.article-body blockquote {
  margin: 32px 0; padding: 0 0 0 24px;
  border-left: 2px solid var(--ink);
  font-family: 'Instrument Serif', Georgia, serif;
  font-style: italic; font-size: 26px; line-height: 1.4;
  color: var(--ink);
}

.article-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92em;
  background: var(--paper-warm);
  padding: 2px 6px; border-radius: 4px;
}
.article-body pre {
  background: var(--paper-warm); border: 1px solid var(--line);
  padding: 20px; border-radius: 10px; overflow-x: auto; line-height: 1.5;
  font-size: 14px; margin: 24px 0;
}
.article-body pre code { background: none; padding: 0; }

.article-body table {
  width: 100%; border-collapse: collapse; margin: 24px 0;
  font-size: 15px;
}
.article-body th, .article-body td {
  text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.article-body th { font-weight: 700; color: var(--ink); }

.article-body hr {
  border: none; border-top: 1px solid var(--line); margin: 48px 0;
}

/* Mid-article CTA */
.cta-card {
  margin: 56px 0; padding: 32px;
  background: var(--paper-warm);
  border-radius: 16px; border: 1px solid var(--line);
}
.cta-card .cta-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 28px; line-height: 1.2; margin: 0 0 10px; font-weight: 400;
}
.cta-card p { margin: 0 0 16px; font-size: 16px; color: var(--ink-soft); }
.cta-card .cta-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--ink); color: #fff; padding: 10px 20px;
  border-radius: 999px; text-decoration: none; font-size: 14px; font-weight: 500;
}
.cta-card .cta-btn:hover { opacity: 0.9; }

/* Author bio */
.author-bio {
  margin: 80px 0 0; padding: 32px;
  background: var(--paper-warm); border-radius: 18px; border: 1px solid var(--line);
  display: grid; grid-template-columns: 80px 1fr; gap: 24px; align-items: start;
}
.author-bio .avatar-lg {
  width: 80px; height: 80px; border-radius: 50%;
  background-size: cover; background-position: center;
}
.author-bio .who-name {
  font-size: 18px; font-weight: 700; margin: 0 0 4px; color: var(--ink);
}
.author-bio .who-role {
  font-size: 13px; color: var(--ink-soft); margin: 0 0 12px;
}
.author-bio .who-text { font-size: 15px; line-height: 1.6; margin: 0 0 14px; }
.author-bio .who-cta {
  font-size: 14px; color: var(--ink); font-weight: 500;
  text-decoration: none; border-bottom: 1px solid var(--ink);
}

/* Related articles */
.related {
  margin: 80px 0 0; padding-top: 48px;
  border-top: 1px solid var(--line);
}
.related-label {
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  font-weight: 600; color: var(--ink-soft);
  margin: 0 0 24px;
}
.related-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.related-card {
  display: flex; flex-direction: column; gap: 8px; text-decoration: none;
  padding: 20px; border-radius: 12px; border: 1px solid var(--line);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  background: #fff;
}
.related-card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -16px rgba(30,30,60,0.18); }
.related-card .r-eyebrow {
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-soft); font-weight: 600;
}
.related-card .r-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 22px; line-height: 1.2; color: var(--ink); font-weight: 400;
}

/* Footer */
.footer-wrap { padding: 80px 24px; background: #fafaf9; margin-top: 80px; }
.footer-inner {
  max-width: var(--site-width); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 24px;
  font-size: 13px; color: var(--ink-soft);
}
.footer-inner a { color: var(--ink-soft); text-decoration: none; margin-right: 16px; }
.footer-inner a:hover { color: var(--ink); }

/* Blog index */
.index-hero { padding: 140px 24px 48px; max-width: var(--site-width); margin: 0 auto; }
.index-hero h1 {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: clamp(48px, 6vw, 72px); font-weight: 400; letter-spacing: -0.02em;
  line-height: 1.0; margin: 0 0 16px;
}
.index-hero p { font-size: 19px; color: var(--ink-soft); max-width: 600px; margin: 0; line-height: 1.55; }
.index-grid {
  max-width: var(--site-width); margin: 0 auto; padding: 0 24px 80px;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px;
}
.index-card {
  display: flex; flex-direction: column; gap: 10px; text-decoration: none;
  padding: 32px; border-radius: 18px; border: 1px solid var(--line);
  background: #fff; transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.index-card:hover { transform: translateY(-2px); box-shadow: 0 14px 32px -16px rgba(30,30,60,0.18); }
.index-card .i-eyebrow {
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-soft); font-weight: 600;
}
.index-card .i-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 28px; line-height: 1.15; color: var(--ink); font-weight: 400;
  margin: 0;
}
.index-card .i-lede { font-size: 15px; color: var(--ink-soft); line-height: 1.55; margin: 4px 0 0; }
.index-card .i-meta { font-size: 13px; color: var(--ink-faint); margin-top: auto; padding-top: 8px; }

@media (max-width: 760px) {
  .reader { padding: 100px 20px 60px; }
  .related-grid { grid-template-columns: 1fr; }
  .index-grid { grid-template-columns: 1fr; padding-bottom: 60px; }
  .author-bio { grid-template-columns: 1fr; }
  .author-bio .avatar-lg { width: 64px; height: 64px; }
  nav .links { display: none; }
  h1.title { font-size: 36px; }
  .lede { font-size: 18px; }
  .article-body h2 { font-size: 24px; margin-top: 48px; }
}
