:root {
  --ink: #10131b;
  --muted: #64748b;
  --line: #e3e9f2;
  --paper: #ffffff;
  --wash: #f8fafc;
  --blue: #3f63d6;
  --navy: #0b172a;
  --teal: #0f7a6f;
  --mint: #dff8ed;
  --lime: #a8db27;
  --white: #ffffff;
  --font-heading: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --shadow-sm: 0 4px 12px rgba(16, 19, 27, 0.03);
  --shadow-md: 0 12px 32px rgba(16, 19, 27, 0.06);
  --shadow-lg: 0 24px 50px rgba(16, 19, 27, 0.10);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--wash);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--teal); transition: all 0.2s ease; }
a:hover { color: var(--blue); }
img { max-width: 100%; height: auto; }

/* Unified Sticky Navigation (supports both .nav and .blog-nav) */
.blog-nav,
nav.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 72px;
  padding: 12px max(24px, calc((100vw - 1200px) / 2));
  border-bottom: 1px solid rgba(227, 233, 242, 0.8);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.blog-brand,
nav.nav .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
}
.blog-brand img,
nav.nav .brand img { width: auto; height: 26px; border-radius: 0; box-shadow: none; }
.blog-brand span,
nav.nav .brand span { background: linear-gradient(135deg, var(--navy), var(--teal)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; font-weight: 700; }

.blog-nav-links,
nav.nav .nav-actions { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; white-space: nowrap; }
.blog-nav-links a,
nav.nav .nav-actions a:not(.nav-cta) { color: #334056; font-family: var(--font-body); font-weight: 600; font-size: 14px; text-decoration: none; transition: color 0.2s ease; white-space: nowrap; }
.blog-nav-links a:hover,
nav.nav .nav-actions a:hover { color: var(--teal); }

.blog-nav-links .launch,
nav.nav .nav-actions .nav-cta {
  padding: 10px 22px;
  border-radius: 999px;
  color: #fff !important;
  background: linear-gradient(135deg, var(--blue), var(--teal)) !important;
  box-shadow: 0 6px 16px rgba(18, 141, 128, 0.25);
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.blog-nav-links .launch:hover,
nav.nav .nav-actions .nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(18, 141, 128, 0.35);
}
.blog-hero {
  padding: 64px 24px 56px;
  color: #fff;
  background: radial-gradient(120% 120% at 50% 0%, #172a46 0%, var(--navy) 100%);
  position: relative;
}
.blog-hero-inner { width: min(1160px, 100%); margin: auto; }
.eyebrow {
  display: inline-block;
  margin: 0 0 16px;
  padding: 4px 12px;
  background: rgba(168, 219, 39, 0.14);
  border: 1px solid rgba(168, 219, 39, 0.3);
  border-radius: 999px;
  color: var(--lime);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.blog-hero h1 {
  max-width: 900px;
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(32px, 5vw, 54px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.blog-hero p:not(.eyebrow) {
  max-width: 760px;
  margin: 20px 0 0;
  color: #94a3b8;
  font-size: 19px;
  line-height: 1.55;
}
.blog-shell {
  display: grid;
  grid-template-columns: minmax(0, 780px) 310px;
  gap: 38px;
  width: min(1160px, calc(100% - 40px));
  margin: 44px auto 80px;
}
.article-card, .sidebar-card, .blog-list-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}
.article-card { padding: clamp(24px, 5vw, 54px); }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}
.article-figure {
  margin: 0 0 34px;
}
.article-hero {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  object-fit: cover;
  object-position: center;
  background: #eef3fa;
}
.article-figure figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.article-toc {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 22px;
  margin: 0 0 36px;
  padding: 24px;
  border: 1px solid #cfe0ef;
  border-radius: 8px;
  background: #f5f9fd;
}
.article-toc h2 {
  grid-column: 1 / -1;
  margin: 0 0 12px;
  font-size: 22px;
}
.article-toc a {
  padding: 9px 0;
  border-bottom: 1px solid #dce7f1;
  color: #285c84;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
  text-decoration: none;
}
.article-card h2 { margin: 42px 0 14px; font-size: clamp(27px, 4vw, 36px); line-height: 1.12; }
.article-card h3 { margin: 28px 0 10px; font-size: 22px; }
.article-card p, .article-card li { color: #3e4b61; font-size: 17px; line-height: 1.75; }
.article-card ul, .article-card ol { padding-left: 24px; }
.article-card li { margin-bottom: 9px; }
.article-card strong { color: var(--ink); }
.callout {
  margin: 32px 0;
  padding: 24px;
  border-left: 5px solid var(--teal);
  border-radius: 6px;
  background: #eaf8f5;
}
.callout p { margin: 0; color: #173f3a; font-weight: 700; }
.takeaways {
  margin: 32px 0;
  padding: 26px 28px;
  border: 1px solid #cce7df;
  border-radius: 8px;
  background: #f0faf7;
}
.takeaways h2 { margin: 0 0 14px; font-size: 25px; }
.takeaways ul { margin: 0; }
.takeaways li { color: #173f3a; font-weight: 700; }
.article-cta {
  margin-top: 44px;
  padding: 30px;
  border-radius: 8px;
  color: #fff;
  background: var(--navy);
}
.article-cta h2 { margin-top: 0; }
.article-cta p { color: #dfe8f8; }
.article-cta a {
  display: inline-flex;
  margin-top: 8px;
  padding: 14px 20px;
  border-radius: 999px;
  color: #fff;
  background: var(--teal);
  font-weight: 900;
  text-decoration: none;
}
.sidebar { display: grid; align-content: start; gap: 18px; }
.sidebar-card { padding: 24px; }
.sidebar-card h2 { margin: 0 0 14px; font-size: 20px; }
.sidebar-card a { display: block; padding: 10px 0; border-bottom: 1px solid var(--line); font-weight: 800; line-height: 1.35; text-decoration: none; }
.sidebar-card a:last-child { border-bottom: 0; }
.blog-index {
  width: min(1160px, calc(100% - 40px));
  margin: 44px auto 80px;
}
.blog-index-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}
.blog-index-head h2 {
  margin: 0 0 6px;
  font-size: 32px;
  line-height: 1.1;
}
.blog-count {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}
.blog-filter-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 28px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #fff;
  background: var(--teal);
  font-size: 13px;
  font-weight: 900;
}
.blog-filters {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 2px 0 18px;
  margin-bottom: 18px;
  scrollbar-width: thin;
}
.blog-filter {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #334056;
  background: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}
.blog-filter[aria-pressed="true"] {
  color: #fff;
  border-color: var(--teal);
  background: var(--teal);
}
.blog-filter[aria-pressed="true"] span {
  color: var(--teal);
  background: #fff;
}
.blog-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.blog-list-card { overflow: hidden; }
.blog-list-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: top; background: #eef3fa; }
.blog-list-body { padding: 24px; }
.blog-list-body span { color: var(--teal); font-size: 12px; font-weight: 900; letter-spacing: 1.4px; text-transform: uppercase; }
.blog-list-body h2 { margin: 10px 0; font-size: 25px; line-height: 1.15; }
.blog-list-body p { color: var(--muted); line-height: 1.6; }
.blog-list-body a { font-weight: 900; text-decoration: none; }
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 34px;
}
.blog-pagination button {
  min-width: 112px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--teal);
  border-radius: 999px;
  color: #fff;
  background: var(--teal);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}
.blog-pagination button:disabled {
  color: #7b8799;
  border-color: var(--line);
  background: #eef3f8;
  cursor: default;
}
.blog-pagination span {
  min-width: 106px;
  color: var(--muted);
  text-align: center;
  font-weight: 900;
}
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  max-width: 1180px;
  margin: 0 auto 16px;
  padding: 12px 20px;
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  backdrop-filter: blur(8px);
}
.breadcrumb a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}
.breadcrumb a:hover { color: var(--blue); text-decoration: underline; }
.breadcrumb span:not(.breadcrumb-sep) { color: var(--navy); font-weight: 700; }
.breadcrumb-sep { margin: 0 4px; opacity: 0.45; color: #94a3b8; }
.blog-footer {
  padding: 38px 20px;
  color: #dfe8f8;
  text-align: center;
  background: #11141d;
}
.blog-footer a { color: #fff; }

@media (max-width: 900px) {
  .blog-shell { grid-template-columns: 1fr; }
  .sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .blog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .blog-nav { align-items: flex-start; }
  .blog-nav-links { gap: 12px; font-size: 13px; }
  .blog-nav-links a:first-child { display: none; }
  .blog-hero { padding-top: 48px; }
  .blog-shell, .blog-index { width: min(100% - 28px, 1160px); }
  .blog-index-head { align-items: flex-start; flex-direction: column; }
  .article-card { padding: 24px 20px; }
  .article-toc { grid-template-columns: 1fr; padding: 20px; }
  .sidebar, .blog-grid { grid-template-columns: 1fr; }
  .blog-pagination { gap: 10px; }
  .blog-pagination button { min-width: 96px; padding-inline: 14px; }
}

/* Blog filter toolbar: search + curated category chips */
.blog-toolbar { position: sticky; top: 72px; z-index: 40; background: #fff; padding-top: 4px; }
.blog-search { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.blog-search-label { font-weight: 900; font-size: 15px; color: #334056; }
.blog-search input {
  flex: 0 1 460px;
  min-width: 0;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fafc;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: #102a43;
}
.blog-search input:focus { outline: 2px solid var(--teal); outline-offset: 1px; background: #fff; }
.blog-search input::placeholder { color: #8a99ad; font-weight: 500; }
.blog-search-clear {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  color: #334056;
  cursor: pointer;
  white-space: nowrap;
}
.blog-search-clear:hover { border-color: var(--teal); color: var(--teal); }
.blog-search-clear[hidden] { display: none; }
@media (max-width: 640px) {
  .blog-search { flex-wrap: wrap; }
  .blog-search input { flex: 1 1 100%; }
  .blog-toolbar { top: 64px; }
}

/* Date select — styled to match the search pill (inline copy in blog/index.html bypasses the 4h CSS asset cache) */
.blog-date {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  flex: 0 0 auto;
  width: 212px;
  min-height: 44px;
  padding: 10px 40px 10px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="12" height="8" viewBox="0 0 12 8"><path d="M1 1.5 6 6.5 11 1.5" fill="none" stroke="%2366788e" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>') no-repeat right 18px center;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  color: #334056;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.blog-date:hover { border-color: var(--teal); }
.blog-date:focus { outline: 2px solid var(--teal); outline-offset: 1px; border-color: var(--teal); }
@media (max-width: 640px) {
  .blog-date { flex: 1 1 140px; width: auto; }
  .blog-search-clear { flex: 0 0 auto; }
}
