/* ============================================================
   BLOG PAGE — APPLE-INSPIRED REDESIGN
   Extends global.css / corporate.css tokens. Scoped to this page.
   ============================================================ */

/* ===== HERO — dark, ambient motion ===== */
.blog-hero {
  position: relative;
  overflow: hidden;
  padding: 150px 0 128px;
  background: var(--black);
  border-bottom: none;
}

.blog-hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  pointer-events: none;
}

.blog-hero-blob--a {
  width: 460px;
  height: 460px;
  top: -200px;
  left: -100px;
  background: radial-gradient(circle, rgba(227,6,19,0.5), transparent 70%);
  animation: blogBlobA 17s ease-in-out infinite;
}

.blog-hero-blob--b {
  width: 360px;
  height: 360px;
  bottom: -180px;
  right: -90px;
  background: radial-gradient(circle, rgba(255,255,255,0.09), transparent 70%);
  animation: blogBlobB 21s ease-in-out infinite;
}

@keyframes blogBlobA {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(36px, -28px) scale(1.07); }
}

@keyframes blogBlobB {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-30px, 24px) scale(1.05); }
}

.blog-hero .container { position: relative; z-index: 1; }

.blog-hero .breadcrumb { color: rgba(255,255,255,0.45); margin-bottom: 26px; }
.blog-hero .breadcrumb a { color: rgba(255,255,255,0.82); }

.blog-hero h1 {
  color: #fff;
  font-size: clamp(2.5rem, 5.6vw, 4.2rem);
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 1.03;
  margin-bottom: 20px;
  max-width: 740px;
}

.blog-hero h1 .red-text { -webkit-text-fill-color: unset; background: none; color: var(--red); }

.blog-hero p {
  color: rgba(255,255,255,0.62);
  font-size: 1.08rem;
  line-height: 1.85;
  max-width: 580px;
}

@media (prefers-reduced-motion: reduce) {
  .blog-hero-blob { animation: none; }
}

/* ===== SECTION HEAD, tightened ===== */
.blog-main-section { padding-top: 0; }
.blog-main-section .section-head { max-width: 640px; margin-bottom: 36px; }

/* ===== FEATURED ARTICLE — floats up out of the hero ===== */
.blog-featured {
  position: relative;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 0;
  align-items: stretch;
  background: #fff;
  border-radius: 24px;
  overflow: hidden;
  margin-top: -96px;
  margin-bottom: 48px;
  box-shadow: 0 30px 70px rgba(10,10,10,0.22);
  transition: transform 320ms cubic-bezier(.22,1,.36,1), box-shadow 320ms ease;
}

.blog-featured:hover {
  transform: translateY(-6px);
  box-shadow: 0 40px 90px rgba(10,10,10,0.28);
}

.blog-featured-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,0.08), transparent 55%),
    linear-gradient(145deg, #17181a, #2a2b2d);
  padding: 32px;
}

.blog-featured-icon svg { width: 72px; height: 72px; color: var(--red); stroke-width: 1.3; }

.blog-featured > div:last-child { padding: 40px 44px; display: flex; flex-direction: column; justify-content: center; }

.blog-featured-tag {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 6px;
  color: var(--red);
  font-family: 'Outfit', sans-serif;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.blog-featured h3 {
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 850;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  line-height: 1.28;
  margin-bottom: 14px;
}

.blog-featured p {
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.8;
  max-width: 640px;
  margin-bottom: 20px;
}

/* ===== CATEGORY FILTERS — sliding pill indicator ===== */
.blog-filters {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 5px;
  background: var(--bg-off);
  border-radius: 100px;
  width: fit-content;
  max-width: 100%;
  margin-bottom: 44px;
}

.blog-filter-indicator {
  position: absolute;
  top: 0;
  left: 0;
  height: 0;
  background: var(--black);
  border-radius: 100px;
  transition: transform 380ms cubic-bezier(.22,1,.36,1), width 380ms cubic-bezier(.22,1,.36,1);
  z-index: 0;
}

.blog-filter-btn {
  position: relative;
  z-index: 1;
  padding: 9px 18px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  border-radius: 100px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  transition: color 220ms ease;
}

.blog-filter-btn:hover { color: var(--text-primary); }
.blog-filter-btn.active { color: #fff; }

.blog-editorial-panel .proof-list li { color: var(--text-body); }

/* ===== BLOG GRID / CARD REDESIGN — spotlight hover ===== */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.blog-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 30px;
  overflow: hidden;
  isolation: isolate;
  transition: transform 260ms cubic-bezier(.22,1,.36,1), border-color 260ms ease, box-shadow 260ms ease, opacity 220ms ease;
}

.blog-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(
    340px circle at var(--spot-x, 50%) var(--spot-y, 50%),
    rgba(227,6,19,0.08),
    transparent 65%
  );
  opacity: 0;
  transition: opacity 300ms ease;
}

.blog-card:hover::before { opacity: 1; }

.blog-card:hover {
  transform: translateY(-6px);
  border-color: rgba(227,6,19,0.26);
  box-shadow: 0 20px 44px rgba(15,27,45,0.1);
}

.blog-card.is-hidden { display: none; }

.blog-icon {
  width: 50px;
  height: 50px;
  border-radius: 13px;
  background: var(--black);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.blog-icon svg { width: 24px; height: 24px; color: var(--red); stroke-width: 1.7; }

.blog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.blog-card h3 {
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  line-height: 1.42;
  margin-bottom: 10px;
}

.blog-card p {
  color: var(--text-muted);
  font-size: 0.87rem;
  line-height: 1.72;
  flex: 1;
  margin-bottom: 18px;
}

.blog-card .read-link { margin-top: 0; }
.blog-card-link { color: inherit; }
.blog-card-link:hover, .blog-card-link:focus-visible { color: var(--red); }

/* ===== EDITORIAL STRUCTURE — lighter panel ===== */
.blog-editorial-panel {
  background: var(--bg-off);
  border: none;
  border-radius: 20px;
  padding: 34px;
}

.blog-editorial-panel h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 18px;
}

.blog-editorial-panel .proof-list li {
  padding-left: 0;
}

/* ===== CTA MOTION (reuses the projects-cta blob pattern) ===== */
.blog-cta { position: relative; overflow: hidden; }

.blog-cta-blob {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(227,6,19,0.18), transparent 70%);
  filter: blur(60px);
  top: -140px;
  left: -80px;
  animation: blogBlobA 19s ease-in-out infinite;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .blog-cta-blob { animation: none; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .blog-featured { grid-template-columns: 1fr; margin-top: -60px; border-radius: 20px; }
  .blog-featured-icon { padding: 26px; }
  .blog-featured-icon svg { width: 48px; height: 48px; }
  .blog-featured > div:last-child { padding: 28px; }
}

@media (max-width: 680px) {
  .blog-grid { grid-template-columns: 1fr; }
  .blog-hero { padding: 126px 0 100px; }
}

/* ============================================================
   ARTICLE PAGE (insights-*.html)
   Single-column reading layout for full Insights articles.
   ============================================================ */
.article-hero { padding-bottom: 72px; }
.article-hero h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); max-width: 860px; }
.article-hero p { max-width: 720px; }

.article-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.article-tags span {
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(227,6,19,0.16);
  color: #ff6b73;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.article-byline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
  color: rgba(255,255,255,0.55);
  font-size: 0.86rem;
}

.article-section { padding-top: 56px; }

.article-body {
  max-width: 800px;
  margin: 0 auto;
  color: var(--text-secondary, #333);
  font-size: 1.05rem;
  line-height: 1.85;
}

.article-body > * + * { margin-top: 1.1em; }
.article-body h2 {
  margin-top: 2.2em;
  color: var(--text-primary);
  font-size: clamp(1.4rem, 2.6vw, 1.8rem);
  line-height: 1.25;
}
.article-body h3 { margin-top: 1.6em; color: var(--text-primary); font-size: 1.15rem; }
.article-body strong { color: var(--text-primary); }
.article-lede { font-size: 1.15rem; }
.article-body p a:not(.btn):not(.read-link),
.article-body li a:not(.btn):not(.read-link) { color: var(--red); text-decoration: underline; text-underline-offset: 3px; }
.article-body p a:not(.btn):not(.read-link):hover,
.article-body li a:not(.btn):not(.read-link):hover { color: var(--red-dark); }

.article-figure { margin: 0 0 1.6em; }
.article-figure img {
  width: 100%;
  height: auto;
  border-radius: 18px;
  display: block;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
}

.article-list { padding-left: 1.3em; list-style: disc; }
.article-list--numbered { list-style: decimal; }
.article-list li + li { margin-top: 0.6em; }
.article-list li::marker { color: var(--red); font-weight: 800; }

.article-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 14px; }
.article-table { width: 100%; min-width: 0; border-collapse: collapse; font-size: 0.95rem; line-height: 1.6; }
.article-table th,
.article-table td { padding: 14px 16px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.article-table thead th { background: var(--black, #111); color: #fff; font-size: 0.82rem; letter-spacing: 0.04em; text-transform: uppercase; }
.article-table tbody th { color: var(--text-primary); width: 26%; }
.article-table tr:last-child th,
.article-table tr:last-child td { border-bottom: 0; }

.article-callout {
  margin-top: 2.2em;
  padding: 26px 28px;
  border-left: 4px solid var(--red);
  border-radius: 14px;
  background: var(--red-pale, #fff0f0);
}
.article-callout h3 { margin-top: 0; }
.article-callout p { margin: 8px 0 14px; }

.article-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.6em; }

.article-disclaimer {
  margin-top: 2.6em;
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fafafa;
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.7;
}
.article-disclaimer h3 { margin: 0 0 6px; font-size: 0.82rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-primary); }
.article-disclaimer p + p { margin-top: 0.7em; }

.article-back { max-width: 800px; margin: 48px auto 0; padding-top: 24px; border-top: 1px solid var(--border); }

@media (max-width: 640px) {
  .article-body { font-size: 1rem; }
  .article-table { min-width: 0; font-size: 0.8rem; line-height: 1.5; }
  .article-table th,
  .article-table td { padding: 9px 6px; overflow-wrap: anywhere; hyphens: auto; }
  .article-table thead th { font-size: 0.66rem; letter-spacing: 0.02em; }
  .article-table tbody th { width: 24%; }
  .article-callout { padding: 20px; }
}
