  :root {
    --bg:          #F7F5F0;
    --surface:     #FFFFFF;
    --surface-alt: #F0EDE6;
    --border:      #E2DDD6;
    --text-primary: #1A1714;
    --text-secondary: #5C5550;
    --text-muted:  #9C958E;
    --green:       #2D6A4F;
    --green-light: #D8EDDF;
    --green-mid:   #52B788;
    --gold:        #C9973A;
    --gold-light:  #FDF3E0;
    --accent:      #3D6B5B;
    --link:        #2D6A4F;
    --tag-bg:      #E8F4EE;
    --tag-text:    #1F5C3E;
    --code-bg:     #1E1E1E;
    --code-text:   #D4D4D4;
  }

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

  html { scroll-behavior: smooth; }

  body {
    font-family: 'DM Sans', sans-serif;
    background: var(--bg);
    color: var(--text-primary);
    line-height: 1.7;
    font-size: 16px;
  }

  /* ── Top bar ── */
  .topbar {
    background: var(--green);
    color: #fff;
    text-align: center;
    padding: 10px 20px;
    font-size: 13px;
    letter-spacing: 0.04em;
    font-weight: 500;
  }
  .topbar a { color: var(--green-mid); text-decoration: none; }

  /* ── Header ── */
  .site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 28px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
  }
  .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
  }
  .logo-icon {
    width: 42px; height: 42px;
    background: var(--green);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px;
  }
  .logo-text { font-family: 'DM Serif Display', serif; font-size: 22px; color: var(--text-primary); }
  .logo-sub { font-size: 11px; color: var(--text-muted); letter-spacing: 0.1em; text-transform: uppercase; margin-top: 1px; }

  .header-meta {
    text-align: right;
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
  }
  .header-meta strong { color: var(--green); font-weight: 600; }

  /* ── Hero ── */
  .hero {
    background: linear-gradient(135deg, #1B4332 0%, #2D6A4F 55%, #40916C 100%);
    color: #fff;
    padding: 72px 40px 64px;
    text-align: center;
    position: relative;
    overflow: hidden;
  }
  .hero::before {
    content: '';
    position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
  }
  .hero-label {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 20px;
    padding: 4px 16px;
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 22px;
    color: #B7E4C7;
  }
  .hero h1 {
    font-family: 'DM Serif Display', serif;
    font-size: clamp(36px, 6vw, 58px);
    line-height: 1.1;
    margin-bottom: 12px;
  }
  .hero h1 em { font-style: italic; color: #95D5B2; }
  .hero-slogan {
    font-size: 18px;
    color: rgba(255,255,255,0.75);
    margin-bottom: 32px;
    letter-spacing: 0.02em;
  }
  .hero-slogan strong { color: #74C69D; font-style: italic; font-family: 'DM Serif Display', serif; font-size: 22px; }
  .hero-stats {
    display: flex;
    justify-content: center;
    gap: 48px;
    flex-wrap: wrap;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid rgba(255,255,255,0.15);
  }
  .hero-stat-item { text-align: center; }
  .hero-stat-num { font-family: 'DM Serif Display', serif; font-size: 28px; color: #95D5B2; }
  .hero-stat-label { font-size: 12px; color: rgba(255,255,255,0.6); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 2px; }

  /* ── TOC ── */
  .toc-bar {
    background: var(--gold-light);
    border-bottom: 2px solid var(--gold);
    padding: 18px 40px;
    display: flex;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
    font-size: 13px;
  }
  .toc-bar span { font-weight: 600; color: var(--gold); text-transform: uppercase; letter-spacing: 0.08em; }
  .toc-bar a { color: var(--text-secondary); text-decoration: none; transition: color .2s; }
  .toc-bar a:hover { color: var(--green); }
  .toc-bar a::before { content: '→ '; color: var(--gold); }

  /* ── Layout ── */
  .content-wrapper {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 24px;
  }

  /* ── Article ── */
  .article {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin: 48px 0;
    overflow: hidden;
    box-shadow: 0 2px 20px rgba(0,0,0,0.04);
  }

  .article-header {
    padding: 36px 44px 28px;
    border-bottom: 1px solid var(--border);
  }
  .article-number {
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 10px;
  }
  .article-number span {
    display: inline-block;
    background: var(--green);
    color: #fff;
    border-radius: 4px;
    padding: 2px 8px;
    margin-right: 8px;
  }
  .article h2 {
    font-family: 'DM Serif Display', serif;
    font-size: clamp(24px, 3.5vw, 32px);
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: 10px;
  }
  .article-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 14px;
    align-items: center;
  }
  .tag {
    display: inline-block;
    background: var(--tag-bg);
    color: var(--tag-text);
    border-radius: 20px;
    padding: 3px 12px;
    font-size: 12px;
    font-weight: 500;
  }
  .tag.gold { background: var(--gold-light); color: var(--gold); }
  .tag.dark { background: var(--green); color: #fff; }
  .read-time { font-size: 12px; color: var(--text-muted); }

  .article-body {
    padding: 36px 44px 44px;
  }

  .article-body p {
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-size: 16px;
    line-height: 1.75;
  }

  .article-body h3 {
    font-family: 'DM Serif Display', serif;
    font-size: 22px;
    color: var(--text-primary);
    margin: 36px 0 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--green-light);
  }

  .article-body h4 {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--green);
    margin: 28px 0 10px;
  }

  .article-body ul, .article-body ol {
    padding-left: 24px;
    color: var(--text-secondary);
    margin-bottom: 20px;
  }
  .article-body li { margin-bottom: 8px; line-height: 1.65; }
  .article-body li strong { color: var(--text-primary); }

  /* Callout */
  .callout {
    border-left: 4px solid var(--green-mid);
    background: var(--green-light);
    border-radius: 0 8px 8px 0;
    padding: 18px 22px;
    margin: 28px 0;
  }
  .callout.gold {
    border-color: var(--gold);
    background: var(--gold-light);
  }
  .callout p { margin: 0; color: var(--text-primary) !important; font-size: 15px; }
  .callout-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--green);
    margin-bottom: 6px;
  }
  .callout.gold .callout-label { color: var(--gold); }

  /* Benchmark table */
  .bench-wrap { overflow-x: auto; margin: 28px 0; }
  table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    font-family: 'DM Mono', monospace;
  }
  thead tr { background: var(--green); color: #fff; }
  thead th {
    padding: 12px 16px;
    text-align: left;
    font-weight: 500;
    letter-spacing: 0.04em;
    font-size: 12px;
    text-transform: uppercase;
  }
  tbody tr { border-bottom: 1px solid var(--border); }
  tbody tr:hover { background: var(--surface-alt); }
  tbody td { padding: 11px 16px; color: var(--text-secondary); }
  tbody td:first-child { color: var(--text-primary); font-weight: 500; }
  .num { text-align: right; font-variant-numeric: tabular-nums; }
  .savings { color: var(--green) !important; font-weight: 600 !important; }
  .best { background: var(--green-light) !important; }

  /* Big stat cards */
  .stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 16px;
    margin: 28px 0;
  }
  .stat-card {
    background: var(--surface-alt);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 18px 16px;
    text-align: center;
  }
  .stat-card .num-big {
    font-family: 'DM Serif Display', serif;
    font-size: 30px;
    color: var(--green);
    line-height: 1;
  }
  .stat-card .num-big.gold { color: var(--gold); }
  .stat-card .num-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-top: 6px;
  }

  /* Code block */
  .code-block {
    background: var(--code-bg);
    border-radius: 8px;
    padding: 20px 22px;
    margin: 24px 0;
    overflow-x: auto;
  }
  .code-block pre {
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    color: var(--code-text);
    line-height: 1.65;
  }
  .code-label {
    font-family: 'DM Mono', monospace;
    font-size: 11px;
    color: var(--text-muted);
    background: var(--surface-alt);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 2px 8px;
    display: inline-block;
    margin-bottom: 10px;
  }

  /* Divider */
  .divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 32px 0;
  }

  /* Tree counter */
  .tree-banner {
    background: linear-gradient(135deg, #081c15, #1B4332);
    color: #fff;
    border-radius: 10px;
    padding: 24px 28px;
    margin: 32px 0;
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
  }
  .tree-icon { font-size: 42px; line-height: 1; }
  .tree-text h4 { font-family: 'DM Serif Display', serif; font-size: 18px; color: #95D5B2; margin-bottom: 4px; }
  .tree-text p { font-size: 13px; color: rgba(255,255,255,0.7); margin: 0; }
  .tree-progress {
    flex: 1;
    min-width: 180px;
  }
  .progress-bar {
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
    height: 8px;
    margin-top: 6px;
    overflow: hidden;
  }
  .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #52B788, #95D5B2);
    border-radius: 4px;
    width: 43%;
  }
  .progress-label { font-size: 11px; color: rgba(255,255,255,0.5); margin-top: 4px; }

  /* Feature pills */
  .feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 14px;
    margin: 24px 0;
  }
  .feature-pill {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 14px 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: var(--surface);
  }
  .feature-pill:hover { border-color: var(--green-mid); box-shadow: 0 2px 12px rgba(45,106,79,0.08); }
  .fp-icon { font-size: 22px; line-height: 1; flex-shrink: 0; margin-top: 1px; }
  .fp-name { font-size: 13px; font-weight: 600; color: var(--text-primary); margin-bottom: 3px; }
  .fp-desc { font-size: 12px; color: var(--text-muted); line-height: 1.4; }

  /* Pull quote */
  .pull-quote {
    border: none;
    margin: 36px 0;
    padding: 0 0 0 24px;
    border-left: 3px solid var(--green-mid);
  }
  .pull-quote p {
    font-family: 'DM Serif Display', serif;
    font-size: 22px !important;
    font-style: italic;
    color: var(--text-primary) !important;
    line-height: 1.4 !important;
  }
  .pull-quote cite { font-size: 13px; color: var(--text-muted); font-style: normal; }

  /* Irony badge */
  .irony-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #FFF3CD;
    border: 1px solid #FFC107;
    color: #856404;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 20px;
  }

  /* Steps */
  .step-list { counter-reset: steps; list-style: none; padding: 0; margin: 20px 0 28px; }
  .step-list li {
    counter-increment: steps;
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    align-items: flex-start;
  }
  .step-list li::before {
    content: counter(steps);
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px; height: 28px;
    background: var(--green);
    color: #fff;
    border-radius: 50%;
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    font-weight: 500;
    flex-shrink: 0;
    margin-top: 2px;
  }
  .step-list li strong { display: block; font-size: 15px; color: var(--text-primary); margin-bottom: 4px; }
  .step-list li span { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

  /* Footer */
  .site-footer {
    background: var(--text-primary);
    color: rgba(255,255,255,0.6);
    padding: 48px 40px;
    margin-top: 80px;
  }
  .footer-inner {
    max-width: 860px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
  }
  .footer-col h5 {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #fff;
    margin-bottom: 14px;
  }
  .footer-col p, .footer-col a {
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255,255,255,0.55);
    text-decoration: none;
    display: block;
  }
  .footer-col a:hover { color: var(--green-mid); }
  .footer-bottom {
    max-width: 860px;
    margin: 36px auto 0;
    padding-top: 24px;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 12px;
    color: rgba(255,255,255,0.35);
  }
  .footer-bottom strong { color: var(--green-mid); }

  /* Responsive */
  @media (max-width: 640px) {
    .site-header { padding: 20px; }
    .hero { padding: 52px 20px 44px; }
    .toc-bar { padding: 14px 20px; flex-direction: column; align-items: flex-start; gap: 8px; }
    .article-header, .article-body { padding: 24px 22px; }
    .footer-inner { grid-template-columns: 1fr; }
  }

  /* Animations */
  @keyframes fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  .article { animation: fadeUp .5s ease both; }
  .article:nth-child(2) { animation-delay: .1s; }
  .article:nth-child(3) { animation-delay: .2s; }

/* Article-card alias (article 4 uses this class) */
.article-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin: 48px 0;
  overflow: hidden;
  box-shadow: 0 2px 20px rgba(0,0,0,0.04);
  animation: fadeUp .5s ease both;
}
.article-card h2, .article-title {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(24px, 3.5vw, 32px);
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.article-subtitle {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-top: 8px;
}
.article-date { font-size: 12px; color: var(--text-muted); }
.callout-green {
  border-left: 4px solid #4ade80;
  background: rgba(74,222,128,0.08);
  border-radius: 0 8px 8px 0;
  padding: 18px 22px;
  margin: 28px 0;
}
.callout-yellow {
  border-left: 4px solid #fbbf24;
  background: rgba(251,191,36,0.08);
  border-radius: 0 8px 8px 0;
  padding: 18px 22px;
  margin: 28px 0;
}

/* Article page navigation */
.article-page-nav {
  max-width: 860px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: color .2s;
}
.back-link:hover { color: var(--green); }
.article-nav-pills {
  display: flex;
  gap: 8px;
}
.nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 20px;
  text-decoration: none;
  font-size: 12px;
  color: var(--text-secondary);
  background: var(--surface);
  transition: all .2s;
}
.nav-pill:hover { border-color: var(--green-mid); color: var(--green); }
.nav-pill.disabled { opacity: .35; pointer-events: none; }

/* Preview grid (index page) */
.preview-grid {
  max-width: 860px;
  margin: 48px auto 0;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 24px;
}
.preview-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px 30px 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: box-shadow .2s, border-color .2s;
  animation: fadeUp .5s ease both;
}
.preview-card:hover { box-shadow: 0 4px 24px rgba(0,0,0,0.08); border-color: var(--green-mid); }
.preview-card-num {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  display: flex;
  align-items: center;
  gap: 8px;
}
.preview-card-num span {
  display: inline-block;
  background: var(--green);
  color: #fff;
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 11px;
}
.preview-card h3 {
  font-family: 'DM Serif Display', serif;
  font-size: 20px;
  line-height: 1.25;
  color: var(--text-primary);
  margin: 0;
}
.preview-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
  margin: 0;
  flex: 1;
}
.preview-card-footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.read-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--green);
  color: #fff;
  text-decoration: none;
  border-radius: 20px;
  padding: 7px 18px;
  font-size: 13px;
  font-weight: 500;
  transition: background .2s;
}
.read-btn:hover { background: var(--accent); }

/* Subscribe section */
.subscribe-section {
  max-width: 600px;
  margin: 64px auto 80px;
  padding: 0 24px;
  text-align: center;
}
.subscribe-section h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 32px;
  margin-bottom: 12px;
}
.subscribe-section p {
  color: var(--text-secondary);
  margin-bottom: 28px;
  font-size: 16px;
}
.subscribe-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.subscribe-form input {
  width: 100%;
  padding: 12px 18px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  background: var(--surface);
  color: var(--text-primary);
  outline: none;
  transition: border-color .2s;
}
.subscribe-form input:focus { border-color: var(--green-mid); }
.subscribe-btn {
  padding: 13px 28px;
  background: var(--green);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s;
}
.subscribe-btn:hover { background: var(--accent); }
.subscribe-btn:disabled { opacity: .6; cursor: default; }
.subscribe-msg {
  margin-top: 14px;
  font-size: 14px;
  min-height: 20px;
}
.subscribe-msg.success { color: var(--green); font-weight: 500; }
.subscribe-msg.error { color: #ef4444; }

@media (max-width: 640px) {
  .preview-grid { grid-template-columns: 1fr; }
  .article-page-nav { flex-direction: column; align-items: flex-start; }
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.5} }
