.blog-shell { background: var(--white); }

.blog-hero,
.blog-category-hero {
  background: var(--navy);
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.blog-hero::before,
.blog-category-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, #000, transparent 90%);
}
.blog-hero-inner,
.blog-category-hero-inner {
  position: relative;
  z-index: 1;
}
.blog-hero-inner { padding: 92px 0 86px; }
.blog-hero-copy { max-width: 900px; }
.blog-hero h1,
.blog-category-hero h1 {
  margin-top: 18px;
  font-size: clamp(42px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -.045em;
}
.blog-hero p,
.blog-category-hero p {
  max-width: 820px;
  margin-top: 24px;
  color: var(--slate-300);
  font-size: 18px;
  line-height: 1.75;
}
.blog-category-hero-inner { padding: 66px 0 62px; }

.blog-featured-section { padding-top: 72px; }
.blog-featured {
  margin-top: 40px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, .8fr);
  gap: 0;
  border: 1px solid var(--slate-100);
  border-radius: 22px;
  overflow: hidden;
  background: white;
  box-shadow: 0 20px 50px rgba(15,23,42,.06);
}
.blog-featured-media {
  min-height: 430px;
  background: var(--slate-light);
}
.blog-featured-media img,
.blog-card-media img,
.article-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.blog-cover-sprite { position: relative; }
.blog-cover-sprite::after {
  content: "";
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: #182033 url('/favicon.svg') center / 100% 100% no-repeat;
  box-shadow: 0 5px 16px rgba(15,23,42,.22);
  pointer-events: none;
}
.article-hero-media .blog-cover-sprite::after {
  right: 22px;
  bottom: 22px;
  width: 56px;
  height: 56px;
  border-radius: 13px;
}
.blog-featured-copy {
  padding: 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
}
.blog-featured-copy h3 {
  margin-top: 18px;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.18;
  letter-spacing: -.03em;
}
.blog-featured-copy p {
  margin-top: 18px;
  color: var(--slate-600);
  font-size: 16px;
  line-height: 1.75;
}
.blog-featured-copy .btn { margin-top: 26px; }

.blog-card-meta,
.blog-card-footer,
.article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--slate-500);
  font-size: 12px;
  font-weight: 600;
}
.blog-card-meta a { color: var(--action); }
.blog-card-meta a:hover { text-decoration: underline; }

.blog-library-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 460px);
  gap: 48px;
  align-items: end;
}
.blog-search-wrap { display: grid; gap: 9px; }
.blog-search-wrap label {
  color: var(--slate-600);
  font-size: 12px;
  font-weight: 700;
}
.blog-search-wrap input {
  width: 100%;
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  padding: 15px 16px;
  background: white;
  color: var(--navy);
  outline: none;
  box-shadow: 0 1px 2px rgba(15,23,42,.03);
}
.blog-search-wrap input:focus {
  border-color: var(--action);
  box-shadow: 0 0 0 3px color-mix(in oklch, var(--action) 12%, white);
}
.blog-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 36px;
}
.blog-categories a {
  padding: 10px 14px;
  border: 1px solid var(--slate-200);
  border-radius: 999px;
  background: white;
  color: var(--slate-600);
  font-size: 12px;
  font-weight: 700;
  transition: .2s ease;
}
.blog-categories a:hover,
.blog-categories a.active {
  border-color: var(--action);
  background: color-mix(in oklch, var(--action) 7%, white);
  color: var(--action);
}
.blog-search-status {
  min-height: 24px;
  margin-top: 18px;
  color: var(--slate-500);
  font-size: 13px;
  scroll-margin-top: 110px;
}
.blog-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-top: 22px;
}
.blog-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--slate-100);
  border-radius: 18px;
  background: white;
  box-shadow: 0 8px 24px rgba(15,23,42,.035);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.blog-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in oklch, var(--action) 25%, white);
  box-shadow: 0 18px 38px rgba(15,23,42,.07);
}
.blog-card[hidden] { display: none; }
.blog-card-media {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--slate-light);
}
.blog-card-media img { transition: transform .35s ease; }
.blog-card:hover .blog-card-media img { transform: scale(1.02); }
.blog-card-body { padding: 24px; }
.blog-card h3 {
  margin-top: 14px;
  font-size: 19px;
  line-height: 1.35;
  letter-spacing: -.02em;
}
.blog-card h3 a:hover { color: var(--action); }
.blog-card p {
  margin-top: 11px;
  color: var(--slate-600);
  font-size: 14px;
  line-height: 1.65;
}
.blog-card-footer {
  justify-content: space-between;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--slate-100);
}
.blog-read-link {
  color: var(--action);
  font-size: 13px;
  font-weight: 700;
}
.blog-read-link span { display: inline-block; transition: transform .2s ease; }
.blog-read-link:hover span { transform: translateX(3px); }

.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 38px;
}
.blog-pagination[hidden] { display: none; }
.blog-page-btn {
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border: 1px solid var(--slate-200);
  border-radius: 10px;
  background: white;
  color: var(--slate-600);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: .2s ease;
}
.blog-page-btn:hover:not(:disabled),
.blog-page-btn.active {
  border-color: var(--action);
  background: color-mix(in oklch, var(--action) 7%, white);
  color: var(--action);
}
.blog-page-btn:disabled {
  opacity: .42;
  cursor: not-allowed;
}

.article-header {
  background: var(--navy);
  color: white;
  padding: 62px 0 72px;
}
.article-header-inner { max-width: 960px; }
.article-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
  color: var(--slate-400);
  font-size: 12px;
}
.article-breadcrumb a:hover { color: white; }
.blog-category-hero .article-breadcrumb { margin-bottom: 24px; }
.article-header h1 {
  max-width: 940px;
  margin-top: 16px;
  font-size: clamp(42px, 5vw, 62px);
  line-height: 1.08;
  letter-spacing: -.045em;
}
.article-deck {
  max-width: 820px;
  margin-top: 22px;
  color: var(--slate-300);
  font-size: 19px;
  line-height: 1.7;
}
.article-meta { margin-top: 28px; color: var(--slate-400); }
.article-media-wrap { margin-top: -28px; position: relative; z-index: 2; }
.article-hero-media {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--slate-100);
  border-radius: 20px;
  background: var(--slate-light);
  box-shadow: 0 20px 50px rgba(15,23,42,.1);
}
.article-hero-media img { aspect-ratio: 16 / 9; }
.article-hero-media figcaption,
.article-inline-figure figcaption {
  padding: 10px 16px;
  background: white;
  color: var(--slate-500);
  font-size: 11px;
  line-height: 1.5;
}
.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) minmax(260px, 320px);
  gap: 72px;
  padding-top: 62px;
  padding-bottom: 84px;
  align-items: start;
}
.article-content {
  color: #243047;
  font-size: 17px;
  line-height: 1.82;
}
.article-content > *:first-child { margin-top: 0; }
.article-content p { margin: 22px 0; }
.article-content h2 {
  margin: 48px 0 16px;
  color: var(--navy);
  font-size: 30px;
  line-height: 1.25;
  letter-spacing: -.025em;
}
.article-content h3 {
  margin: 34px 0 12px;
  color: var(--navy);
  font-size: 22px;
  line-height: 1.3;
}
.article-content ul,
.article-content ol { padding-left: 24px; margin: 18px 0 26px; }
.article-content li { margin: 8px 0; }
.article-content strong { color: var(--navy); }
.article-content a {
  color: var(--action);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.article-content blockquote {
  margin: 30px 0;
  padding: 22px 24px;
  border-left: 4px solid var(--action);
  border-radius: 0 12px 12px 0;
  background: var(--slate-light);
  color: var(--slate-700);
}
.article-inline-figure {
  margin: 34px 0;
  overflow: hidden;
  border: 1px solid var(--slate-100);
  border-radius: 16px;
  background: var(--slate-light);
}
.article-inline-figure img { width: 100%; }
.article-aside {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 16px;
}
.article-aside-card {
  padding: 24px;
  border: 1px solid var(--slate-100);
  border-radius: 16px;
  background: white;
  box-shadow: 0 8px 24px rgba(15,23,42,.035);
}
.article-aside-card p {
  margin-top: 14px;
  color: var(--slate-600);
  font-size: 13px;
  line-height: 1.65;
}
.article-aside-cta { width: 100%; margin-top: 18px; padding-inline: 14px; }
.related-grid { margin-top: 36px; }
.article-final-cta { padding-top: 72px; }

@media (max-width: 1040px) {
  .blog-featured { grid-template-columns: 1fr; }
  .blog-featured-media { min-height: 0; aspect-ratio: 16 / 9; }
  .blog-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout { grid-template-columns: 1fr; gap: 42px; }
  .article-aside { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .blog-hero-inner { padding: 66px 0 62px; }
  .blog-hero h1,
  .blog-category-hero h1,
  .article-header h1 { font-size: 40px; }
  .blog-library-head { grid-template-columns: 1fr; gap: 28px; }
  .blog-featured-copy { padding: 28px 24px; }
  .blog-card-grid { grid-template-columns: 1fr; }
  .blog-pagination { justify-content: flex-start; }
  .blog-page-btn { min-width: 40px; height: 40px; padding-inline: 12px; }
  .article-header { padding: 48px 0 54px; }
  .article-deck { font-size: 17px; }
  .article-layout { padding-top: 42px; padding-bottom: 64px; }
  .article-content { font-size: 16px; }
  .article-content h2 { font-size: 27px; }
  .article-aside { grid-template-columns: 1fr; }
  .blog-cover-sprite::after { right: 10px; bottom: 10px; width: 38px; height: 38px; border-radius: 9px; }
  .article-hero-media .blog-cover-sprite::after { right: 14px; bottom: 14px; width: 46px; height: 46px; border-radius: 11px; }
}
