/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: #ffffff;
  color: #0f172a;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection {
  background: rgba(79, 70, 229, 0.15);
  color: #0f172a;
}

/* ===== LAYOUT ===== */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 1rem + 4vw, 5rem);
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px;
  position: relative;
  background: #faf8f5;
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 680px;
}
.headshot {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.08);
  object-fit: cover;
  margin-bottom: 28px;
  box-shadow: 0 2px 16px rgba(15, 23, 42, 0.06);
}
.hero h1 {
  font-size: clamp(2.5rem, 2rem + 2vw, 4rem);
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1.05;
  margin-bottom: 16px;
  color: #0f172a;
}
.hero .tagline {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.1rem, 1rem + 0.4vw, 1.35rem);
  color: #475569;
  margin-bottom: 32px;
  line-height: 1.7;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}
.pills {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 36px;
}
.pill {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 6px 14px;
  letter-spacing: 0.3px;
}
.hero-links {
  display: flex;
  gap: 16px;
  justify-content: center;
}
.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #ffffff;
  border: 1px solid #0f172a;
  background: #0f172a;
  transition: box-shadow 100ms ease-in-out, background 100ms ease-in-out, transform 100ms ease-in-out;
}
.hero-link:hover {
  background: #1e293b;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}
.hero-link:active {
  transform: translateY(0);
  transition-duration: 50ms;
}
.hero-link.secondary {
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #e2e8f0;
}
.hero-link.secondary:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}
.hero-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}
.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  animation: scroll-fade 2s ease-in-out infinite;
}
.scroll-hint svg {
  width: 20px;
  height: 20px;
  stroke: #94a3b8;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
@keyframes scroll-fade {
  0%, 100% { opacity: 0.3; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.6; transform: translateX(-50%) translateY(6px); }
}

/* ===== SECTIONS ===== */
.section {
  padding: clamp(4rem, 3rem + 3vw, 8rem) 0;
}
.bg-warm {
  background: #faf8f5;
}
.bg-cream {
  background: #f5f2ed;
}
.section-divider {
  display: none;
}
.section-label {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: clamp(1.5rem, 1.25rem + 0.75vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #0f172a;
  margin-bottom: 48px;
}

/* ===== ABOUT ===== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.loop-container {
  display: flex;
  align-items: center;
  justify-content: center;
  order: 0;
}
.loop-svg {
  width: 100%;
  max-width: 480px;
  height: auto;
}
.loop-node-bg {
  fill: #0f172a;
}
.loop-label-text {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 700;
  fill: #ffffff;
  text-anchor: middle;
  dominant-baseline: central;
  letter-spacing: 0.5px;
}
.loop-line {
  stroke: #cbd5e1;
  stroke-width: 1.5;
  fill: none;
}
.loop-dot {
  fill: #0f172a;
  r: 3.5;
}
/* Traveling dot animations along triangle edges */
@keyframes travel-build-ship {
  0% { cx: 180; cy: 100; }
  100% { cx: 295; cy: 245; }
}
@keyframes travel-ship-learn {
  0% { cx: 275; cy: 260; }
  100% { cx: 85; cy: 260; }
}
@keyframes travel-learn-build {
  0% { cx: 65; cy: 245; }
  100% { cx: 180; cy: 100; }
}
.dot-1 {
  animation: travel-build-ship 1.5s ease-in-out 0s infinite;
}
.dot-2 {
  animation: travel-ship-learn 1.5s ease-in-out 1.5s infinite;
}
.dot-3 {
  animation: travel-learn-build 1.5s ease-in-out 3s infinite;
}
/* Node pulse: each node highlights when the dot arrives */
@keyframes node-pulse {
  0%, 28% { r: 40; fill: #0f172a; }
  33%, 38% { r: 44; fill: #1e293b; }
  43%, 100% { r: 40; fill: #0f172a; }
}
.pulse-build { animation: node-pulse 4.5s ease-in-out 0s infinite; }
.pulse-ship { animation: node-pulse 4.5s ease-in-out 1.5s infinite; }
.pulse-learn { animation: node-pulse 4.5s ease-in-out 3s infinite; }
.about p {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.05rem, 1rem + 0.2vw, 1.175rem);
  color: #475569;
  line-height: 1.85;
}
.about p + p {
  margin-top: 20px;
}
.about strong {
  color: #0f172a;
  font-weight: 600;
}
.about a {
  color: #0f172a;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 0.06em;
  transition: color 100ms ease-in-out;
}
.about a:hover {
  color: #475569;
}

/* ===== PROJECTS ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}
.project-card {
  background: #f0ede8;
  border: none;
  border-radius: 12px;
  padding: 32px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  position: relative;
}
.project-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
}
.project-name {
  font-size: clamp(1.35rem, 1.2rem + 0.5vw, 1.6rem);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
  line-height: 1.2;
}
.project-desc {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.95rem;
  color: #475569;
  line-height: 1.75;
  margin-bottom: 24px;
  flex: 1;
}
.project-meta {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  padding-top: 16px;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.project-meta-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #94a3b8;
}
.project-meta-value {
  font-size: 0.85rem;
  color: #475569;
  font-weight: 500;
}
.project-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  color: #ffffff;
  background: #0f172a;
  border: none;
  transition: background 100ms ease-in-out, transform 100ms ease-in-out;
  align-self: flex-start;
}
.project-cta:hover {
  background: #1e293b;
  transform: translateY(-1px);
}
.project-cta:active {
  transform: translateY(0);
  transition-duration: 50ms;
}
.project-cta svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ===== TIMELINE ===== */
.timeline {
  position: relative;
  padding-left: 32px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  bottom: 8px;
  width: 1px;
  background: #cbd5e1;
}
.timeline-item {
  position: relative;
  padding-bottom: 36px;
}
.timeline-item:last-child {
  padding-bottom: 0;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -28px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #0f172a;
}
.timeline-year {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  color: #94a3b8;
  letter-spacing: 1px;
  margin-bottom: 4px;
}
.timeline-role {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 2px;
}
.timeline-company {
  font-size: 0.9rem;
  font-weight: 500;
  color: #475569;
  margin-bottom: 4px;
}
.timeline-detail {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.85rem;
  color: #94a3b8;
  line-height: 1.6;
}
.education-row {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid #f1f5f9;
}
.edu-item {
  display: flex;
  flex-direction: column;
}
.edu-school {
  font-size: 0.9rem;
  font-weight: 600;
  color: #0f172a;
}
.edu-degree {
  font-size: 0.8rem;
  color: #94a3b8;
}

/* ===== CREDENTIALS ===== */
.credentials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.credential {
  background: #f0ede8;
  border: none;
  border-radius: 12px;
  padding: 32px;
}
.credential-title {
  font-size: clamp(1.15rem, 1rem + 0.3vw, 1.3rem);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.3px;
  margin-bottom: 12px;
}
.credential-title a {
  color: inherit;
  text-decoration: none;
  transition: color 100ms ease-in-out;
}
.credential-title a:hover {
  color: #475569;
}
.credential-desc {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.7;
}

/* ===== FOOTER ===== */
.footer {
  padding: clamp(3rem, 2rem + 3vw, 6rem) 0;
  text-align: center;
  background: #0f172a;
  color: #ffffff;
}
.footer .section-label {
  color: #ffffff;
}
.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 24px;
}
.footer-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  transition: box-shadow 100ms ease-in-out, background 100ms ease-in-out, transform 100ms ease-in-out;
}
.footer-link:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transform: translateY(-1px);
}
.footer-link:active {
  transform: translateY(0);
  transition-duration: 50ms;
}
.footer-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}
.footer-quote {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1.05rem;
  font-style: italic;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 auto 8px;
}
.footer-quote-attr {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 40px;
}
.footer-copy {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.3);
}

/* ===== ANIMATIONS ===== */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 0; }
  .projects-grid { grid-template-columns: 1fr; }
  .credentials-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .hero { min-height: 90vh; padding: 60px 20px; }
  .headshot { width: 120px; height: 120px; }
  .hero h1 { letter-spacing: -1px; }
  .pills { gap: 8px; }
  .pill { font-size: 0.62rem; padding: 5px 10px; }
  .hero-links { flex-direction: column; align-items: center; }
  .section-label { font-size: 1.25rem; }
  .project-name { font-size: 1.2rem; }
  .timeline { padding-left: 28px; }
  .footer-links { flex-direction: column; align-items: center; }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-hint { animation: none; opacity: 0.5; }
  .fade-in { opacity: 1; transform: none; transition: none; }
  .project-card { transition: none; }
  .hero-link, .footer-link { transition: none; }
  .dot-1, .dot-2, .dot-3 { animation: none; }
  .pulse-build, .pulse-ship, .pulse-learn { animation: none; }
}

/* ===== NAV ===== */
.site-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px calc((100% - 1100px) / 2 + clamp(1.5rem, 1rem + 4vw, 5rem));
  background: #0f172a;
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-nav a {
  text-decoration: none;
  color: #ffffff;
  transition: color 100ms ease-in-out;
}
.site-nav-brand {
  font-weight: 700;
  font-size: 1rem;
}
.site-nav-links {
  display: flex;
  gap: 24px;
}
.site-nav-link {
  font-weight: 500;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}
.site-nav-link:hover {
  color: #ffffff;
}

/* ===== BLOG CARDS ===== */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}
.blog-card {
  background: #f0ede8;
  border-radius: 12px;
  padding: 32px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
}
.blog-card-date {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #94a3b8;
  margin-bottom: 8px;
}
.blog-card-title {
  font-size: clamp(1.15rem, 1rem + 0.3vw, 1.35rem);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.5px;
  line-height: 1.3;
  margin-bottom: 8px;
}
.blog-card-excerpt {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.7;
  margin-bottom: 16px;
  flex: 1;
}
.blog-card-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.blog-card-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 4px 10px;
  letter-spacing: 0.3px;
}
.writing-cta {
  text-align: center;
  margin-top: 40px;
}

/* ===== BLOG ARTICLE ===== */
.article-header {
  max-width: 860px;
  margin: 0 auto;
  padding: clamp(3rem, 2rem + 3vw, 5rem) clamp(1.5rem, 1rem + 4vw, 5rem) 0;
}
.article-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #94a3b8;
  margin-bottom: 16px;
}
.article-title {
  font-size: clamp(1.8rem, 1.5rem + 1vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.15;
  color: #0f172a;
  margin-bottom: 16px;
}
.article-subtitle {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.05rem, 1rem + 0.2vw, 1.2rem);
  font-style: italic;
  color: #475569;
  line-height: 1.7;
  margin-bottom: 16px;
}
.article-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}
.article-divider {
  max-width: 860px;
  margin: 0 auto;
  border: none;
  border-top: 1px solid #e2e8f0;
}
.article-body {
  max-width: 860px;
  margin: 0 auto;
  padding: 40px clamp(1.5rem, 1rem + 4vw, 5rem) clamp(3rem, 2rem + 3vw, 5rem);
}
.article-body p {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.05rem, 1rem + 0.15vw, 1.125rem);
  color: #475569;
  line-height: 1.85;
  margin-bottom: 24px;
}
.article-body h2 {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: clamp(1.3rem, 1.1rem + 0.5vw, 1.6rem);
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.3px;
  margin-top: 48px;
  margin-bottom: 20px;
}
.article-body h3 {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: clamp(1.1rem, 1rem + 0.3vw, 1.25rem);
  font-weight: 600;
  color: #0f172a;
  margin-top: 36px;
  margin-bottom: 16px;
}
.article-body strong {
  color: #0f172a;
  font-weight: 600;
}
.article-body a {
  color: #0f172a;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 0.06em;
  transition: color 100ms ease-in-out;
}
.article-body a:hover {
  color: #475569;
}
.article-body ul, .article-body ol {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.05rem, 1rem + 0.15vw, 1.125rem);
  color: #475569;
  line-height: 1.85;
  margin-bottom: 24px;
  padding-left: 24px;
}
.article-body li {
  margin-bottom: 8px;
}

/* Blog visual components */
.visual-comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 32px 0;
}
.visual-comparison-card {
  background: #f0ede8;
  border-radius: 12px;
  padding: 24px;
}
.visual-comparison-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #94a3b8;
  margin-bottom: 12px;
}
.visual-comparison-title {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}
.visual-comparison-text {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.7;
}
.visual-flow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 32px 0;
  flex-wrap: wrap;
  justify-content: center;
}
.visual-flow-step {
  background: #f0ede8;
  border-radius: 8px;
  padding: 12px 20px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: #0f172a;
  text-align: center;
}
.visual-flow-step.active {
  background: #0f172a;
  color: #ffffff;
}
.visual-flow-arrow {
  font-size: 1.2rem;
  color: #94a3b8;
}
.visual-callout {
  border-left: 4px solid #0f172a;
  background: #faf8f5;
  padding: 20px 24px;
  margin: 32px 0;
  border-radius: 0 8px 8px 0;
}
.visual-callout p {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1rem;
  color: #0f172a;
  line-height: 1.7;
  margin-bottom: 0;
  font-weight: 500;
}
.visual-metric {
  display: flex;
  gap: 32px;
  margin: 32px 0;
  flex-wrap: wrap;
}
.visual-metric-item {
  text-align: center;
  flex: 1;
  min-width: 120px;
}
.visual-metric-number {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -1px;
  line-height: 1.1;
}
.visual-metric-label {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.85rem;
  color: #94a3b8;
  margin-top: 4px;
}
.visual-code {
  background: #f0ede8;
  border-radius: 12px;
  padding: 24px;
  margin: 32px 0;
  overflow-x: auto;
}
.visual-code-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #94a3b8;
  margin-bottom: 12px;
}
.visual-code pre {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #0f172a;
  margin: 0;
  white-space: pre;
}
.visual-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin: 32px 0;
}
.visual-grid-item {
  background: #f0ede8;
  border-radius: 8px;
  padding: 12px 16px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.8rem;
  font-weight: 500;
  color: #0f172a;
  text-align: center;
}
.visual-framework {
  counter-reset: framework;
  margin: 32px 0;
  list-style: none;
  padding: 0;
}
.visual-framework li {
  counter-increment: framework;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid #e2e8f0;
}
.visual-framework li:last-child {
  border-bottom: none;
}
.visual-framework li::before {
  content: counter(framework);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: #0f172a;
  min-width: 32px;
}

/* Article footer */
.article-footer {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 1rem + 4vw, 5rem) clamp(3rem, 2rem + 3vw, 5rem);
}
.article-author {
  border-top: 1px solid #e2e8f0;
  padding-top: 32px;
  margin-bottom: 32px;
}
.article-author-name {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}
.article-author-bio {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 0.85rem;
  color: #94a3b8;
  line-height: 1.6;
}
.article-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  border-top: 1px solid #e2e8f0;
}
.article-nav a {
  font-size: 0.85rem;
  font-weight: 600;
  color: #0f172a;
  text-decoration: none;
  transition: color 100ms ease-in-out;
}
.article-nav a:hover {
  color: #475569;
}
.article-back {
  text-align: center;
  margin-bottom: 24px;
}
.article-back a {
  font-size: 0.85rem;
  font-weight: 600;
  color: #475569;
  text-decoration: none;
  transition: color 100ms ease-in-out;
}
.article-back a:hover {
  color: #0f172a;
}

/* Blog listing header */
.blog-header {
  padding: clamp(4rem, 3rem + 3vw, 6rem) 0 clamp(2rem, 1.5rem + 1.5vw, 3rem);
}
.blog-header-subtitle {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.05rem, 1rem + 0.2vw, 1.175rem);
  color: #475569;
  line-height: 1.7;
}

/* ===== CONTACT FORM ===== */
.contact-header {
  padding: clamp(4rem, 3rem + 3vw, 6rem) 0 clamp(2rem, 1.5rem + 1.5vw, 3rem);
}
.contact-form-wrapper {
  max-width: 560px;
  margin: 0 auto;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.form-label {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: #0f172a;
}
.form-input {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1rem;
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px 16px;
  transition: border-color 150ms ease-in-out, box-shadow 150ms ease-in-out;
  outline: none;
}
.form-input:focus {
  border-color: #0f172a;
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.06);
}
.form-input::placeholder {
  color: #94a3b8;
}
.form-textarea {
  resize: vertical;
  min-height: 140px;
}
.form-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #ffffff;
  background: #0f172a;
  border: 1px solid #0f172a;
  cursor: pointer;
  transition: background 100ms ease-in-out, transform 100ms ease-in-out, box-shadow 100ms ease-in-out;
  align-self: flex-start;
}
.form-submit:hover {
  background: #1e293b;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}
.form-submit:active {
  transform: translateY(0);
  transition-duration: 50ms;
}
.form-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.contact-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 48px 0;
}
.success-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #0f172a;
  color: #ffffff;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.contact-success h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 8px;
}
.contact-success p {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 1rem;
  color: #475569;
  line-height: 1.7;
}

@media (max-width: 900px) {
  .blog-grid { grid-template-columns: 1fr; }
  .visual-comparison { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .article-title { letter-spacing: -0.5px; }
  .visual-metric { gap: 16px; }
  .visual-flow { flex-direction: column; }
  .visual-flow-arrow { transform: rotate(90deg); }
}
