/**
 * Shared blog-post styles (SOM-174).
 *
 * Extracted verbatim from blog/first-year-costs.html, where this same 434-line
 * block was inlined — byte-identical to the copy in blog/diaper-math.html.
 * Publishing seven more posts would have meant nine copies of it.
 *
 * The .site-nav / .nav-* rules in here are DEAD as of SOM-223, which replaced
 * the old header with the .tbc-header namespace and its own stylesheet. They
 * are left in place rather than picked out by hand, for the same reason the
 * inline copies were: stripping dead CSS is a separate, verifiable pass.
 */
:root {
  --bg: #f9f6f1;
  --card: #ffffff;
  --primary: #4A6B4D;
  --primary-hover: #3A5A3D;
  --primary-light: #5B7F5E;
  --accent: #8BAE8D;
  --accent-warm: #D4A574;
  --text: #1a2e1c;
  --text-muted: #5a6b5c;
  --border: #d4ddd5;
  --shadow: 0 2px 8px rgba(74,107,77,0.08), 0 1px 3px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 24px -4px rgba(74,107,77,0.15), 0 4px 8px -2px rgba(0,0,0,0.08);
  --radius: 16px;
  --radius-sm: 10px;
}

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

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.8;
}

h1, h2, h3, h4 {
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.3;
}

/* Navigation */
.site-nav {
  background: var(--primary);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.site-nav .nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}
.site-nav .nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  text-decoration: none;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
}
.site-nav .nav-brand:hover { opacity: 0.9; }
.site-nav .nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.site-nav .nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 8px;
  transition: all 0.2s;
  white-space: nowrap;
}
.site-nav .nav-link:hover {
  background: rgba(255,255,255,0.15);
  color: white;
}
.site-nav .nav-link.active {
  background: rgba(255,255,255,0.2);
  color: white;
  font-weight: 600;
}
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: white;
  border-radius: 2px;
}
.nav-mobile {
  display: none;
  position: absolute;
  top: 60px;
  left: 0;
  right: 0;
  background: var(--primary);
  padding: 16px 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.nav-mobile.open { display: block; }
.nav-mobile .nav-link {
  display: flex;
  width: 100%;
  padding: 12px 16px;
  margin-bottom: 4px;
}
@media (max-width: 768px) {
  .site-nav .nav-links { display: none; }
  .nav-hamburger { display: flex; }
}

/* Article Container */
.article-container {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 20px 60px;
}

/* Article Header */
.article-header {
  margin-bottom: 40px;
}
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.article-category {
  display: inline-block;
  padding: 3px 12px;
  background: var(--accent);
  color: white;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}
.article-header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}
.article-intro {
  font-size: 1.25rem;
  color: var(--text-muted);
  font-style: italic;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--border);
}

/* Article Content */
.article-content h2 {
  font-size: 1.75rem;
  font-weight: 700;
  margin: 48px 0 20px;
  color: var(--primary);
}
.article-content h3 {
  font-size: 1.35rem;
  font-weight: 600;
  margin: 32px 0 16px;
  color: var(--text);
}
.article-content p {
  margin-bottom: 20px;
  font-size: 1.1rem;
}
.article-content ul, .article-content ol {
  margin: 0 0 20px 24px;
  font-size: 1.1rem;
}
.article-content li {
  margin-bottom: 8px;
}
.article-content strong {
  color: var(--text);
  font-weight: 700;
}
.article-content hr {
  border: none;
  border-top: 2px solid var(--border);
  margin: 48px 0;
}

/* Cost Tables */
.cost-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  background: var(--card);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.cost-table th {
  background: var(--primary);
  color: white;
  padding: 14px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 0.9rem;
}
.cost-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}
.cost-table tr:last-child td {
  border-bottom: none;
}
.cost-table tr:nth-child(even) td {
  background: #f8faf8;
}
.cost-table .total-row td {
  background: #f0f7f0;
  font-weight: 700;
  color: var(--primary);
}

/* Callout Boxes */
.callout {
  background: var(--card);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin: 24px 0;
  border-left: 4px solid var(--primary);
  box-shadow: var(--shadow);
}
.callout-tip {
  border-left-color: var(--accent);
  background: #f5faf5;
}
.callout-warning {
  border-left-color: var(--accent-warm);
  background: #fefaf5;
}
.callout p {
  margin-bottom: 0;
  font-size: 1rem;
}
.callout strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.05rem;
}

/* CTA Links */
.cta-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--primary);
  color: white;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  margin: 8px 8px 8px 0;
  transition: all 0.2s;
}
.cta-link:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
}
.cta-secondary {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}
.cta-secondary:hover {
  background: var(--primary);
  color: white;
}

/* Summary Box */
.summary-box {
  background: var(--primary);
  border-radius: var(--radius);
  padding: 32px;
  margin: 40px 0;
  color: white;
}
.summary-box h3 {
  color: white;
  font-size: 1.5rem;
  margin-bottom: 20px;
}
.summary-box p {
  opacity: 0.95;
}

/* Footer CTA */
.footer-cta {
  background: var(--card);
  border-radius: var(--radius);
  padding: 32px;
  margin: 48px 0 0;
  text-align: center;
  box-shadow: var(--shadow-lg);
}
.footer-cta h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
}
.footer-cta p {
  color: var(--text-muted);
  margin-bottom: 20px;
  font-size: 1.05rem;
}
.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

/* Footer */
.site-footer {
  background: var(--primary);
  color: white;
  padding: 40px 0 32px;
  margin-top: 60px;
}
.site-footer .footer-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}
.site-footer .footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}
.site-footer .footer-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 8px;
  transition: all 0.2s;
}
.site-footer .footer-link:hover {
  background: rgba(255,255,255,0.1);
  color: white;
}
.site-footer .footer-divider {
  height: 1px;
  background: rgba(255,255,255,0.2);
  margin: 24px 0;
}
.site-footer .footer-info {
  text-align: center;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.7);
}
.site-footer .footer-brand {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: white;
  margin-bottom: 8px;
}

@media (max-width: 600px) {
  .article-header h1 { font-size: 1.75rem; }
  .article-intro { font-size: 1.1rem; }
  .article-content h2 { font-size: 1.4rem; }
  .article-content h3 { font-size: 1.15rem; }
  .article-content p, .article-content li { font-size: 1rem; }
  .cost-table { font-size: 0.85rem; }
  .cost-table th, .cost-table td { padding: 10px 12px; }

  /* A 3-column cost table cannot fit 320-375px: its min-content width is
     ~383px. Scrolling the table inside its own box keeps every figure readable
     while leaving the DOCUMENT at the viewport width, which is what SOM-235
     measures. Widening the page instead pushes the header's right-aligned
     controls off-screen, which was the reported symptom. */
  .cost-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
}
  
/* Nav Country / Language Pickers (SOM-93) */
.nav-picker-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-left: 8px;
  gap: 1px;
}
.nav-picker-wrap .nav-picker-label {
  font-size: 0.6rem;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  line-height: 1;
}
.nav-country-picker,
.nav-lang-picker {
  padding: 6px 10px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.1);
  color: white;
  font-size: 0.85rem;
  cursor: pointer;
  font-weight: 500;
}
.nav-country-picker option,
.nav-lang-picker option { background: #fff; color: #333; }
.nav-country-picker:hover,
.nav-lang-picker:hover { border-color: rgba(255,255,255,0.6); }
@media (max-width: 768px) {
  .nav-picker-wrap { display: none; }
}

