/* === MPCS-IT Design System === */

/* --- Design Tokens --- */
:root {
  /* Type Scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 4.5rem);

  /* Spacing (4px base) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 400ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Content Widths */
  --content-narrow: 640px;
  --content-default: 1080px;
  --content-wide: 1280px;
  --content-full: 100%;

  /* Fonts */
  --font-display: 'Cabinet Grotesk', 'Inter', sans-serif;
  --font-body: 'General Sans', 'Inter', sans-serif;
}

/* --- Light Mode --- */
:root,
[data-theme='light'] {
  --color-bg: #f5f8fc;
  --color-surface: #ffffff;
  --color-surface-2: #f0f4f9;
  --color-surface-offset: #e9eff5;
  --color-surface-dynamic: #dde5ee;
  --color-divider: #dfe6ef;
  --color-border: #ccd6e0;

  --color-text: #0d1b2e;
  --color-text-muted: #5a6a7e;
  --color-text-faint: #94a3b8;
  --color-text-inverse: #ffffff;

  --color-primary: #0067c0;
  --color-primary-hover: #00549d;
  --color-primary-active: #00457e;
  --color-primary-highlight: #e0eff8;

  --color-accent: #0078d4;
  --color-success: #107c10;
  --color-warning: #ca5010;

  --shadow-sm: 0 1px 3px oklch(0.2 0.03 240 / 0.08);
  --shadow-md: 0 4px 16px oklch(0.2 0.03 240 / 0.1);
  --shadow-lg: 0 12px 40px oklch(0.2 0.03 240 / 0.15);

  --gradient-hero: linear-gradient(135deg, #0d1b2e 0%, #0a2a4a 35%, #003e6b 70%, #0067c0 100%);
  --gradient-accent: linear-gradient(135deg, #0067c0, #0078d4);
  --grid-pattern: linear-gradient(oklch(1 0 0 / 0.03) 1px, transparent 1px),
                  linear-gradient(90deg, oklch(1 0 0 / 0.03) 1px, transparent 1px);
}

/* --- Dark Mode --- */
[data-theme='dark'] {
  --color-bg: #0a0e17;
  --color-surface: #10151f;
  --color-surface-2: #161d2a;
  --color-surface-offset: #1a2230;
  --color-surface-dynamic: #243140;
  --color-divider: #1e2635;
  --color-border: #2a3545;

  --color-text: #d1d9e6;
  --color-text-muted: #7a8a9e;
  --color-text-faint: #4a5a6e;
  --color-text-inverse: #0d1b2e;

  --color-primary: #4dabf5;
  --color-primary-hover: #2b9aef;
  --color-primary-active: #1a87d9;
  --color-primary-highlight: #122030;

  --color-accent: #4dabf5;
  --color-success: #6db33f;
  --color-warning: #db8a3f;

  --shadow-sm: 0 1px 3px oklch(0 0 0 / 0.3);
  --shadow-md: 0 4px 16px oklch(0 0 0 / 0.4);
  --shadow-lg: 0 12px 40px oklch(0 0 0 / 0.5);

  --gradient-hero: linear-gradient(135deg, #050810 0%, #0a1525 35%, #0a2540 70%, #0a3560 100%);
  --gradient-accent: linear-gradient(135deg, #0078d4, #4dabf5);
  --grid-pattern: linear-gradient(oklch(1 0 0 / 0.04) 1px, transparent 1px),
                  linear-gradient(90deg, oklch(1 0 0 / 0.04) 1px, transparent 1px);
}

/* System preference fallback */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #0a0e17;
    --color-surface: #10151f;
    --color-surface-2: #161d2a;
    --color-surface-offset: #1a2230;
    --color-surface-dynamic: #243140;
    --color-divider: #1e2635;
    --color-border: #2a3545;
    --color-text: #d1d9e6;
    --color-text-muted: #7a8a9e;
    --color-text-faint: #4a5a6e;
    --color-text-inverse: #0d1b2e;
    --color-primary: #4dabf5;
    --color-primary-hover: #2b9aef;
    --color-primary-active: #1a87d9;
    --color-primary-highlight: #122030;
    --color-accent: #4dabf5;
    --color-success: #6db33f;
    --color-warning: #db8a3f;
    --shadow-sm: 0 1px 3px oklch(0 0 0 / 0.3);
    --shadow-md: 0 4px 16px oklch(0 0 0 / 0.4);
    --shadow-lg: 0 12px 40px oklch(0 0 0 / 0.5);
    --gradient-hero: linear-gradient(135deg, #050810 0%, #0a1525 35%, #0a2540 70%, #0a3560 100%);
    --gradient-accent: linear-gradient(135deg, #0078d4, #4dabf5);
    --grid-pattern: linear-gradient(oklch(1 0 0 / 0.04) 1px, transparent 1px),
                    linear-gradient(90deg, oklch(1 0 0 / 0.04) 1px, transparent 1px);
  }
}

/* === Layout === */
.container {
  max-width: var(--content-default);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (min-width: 768px) {
  .container {
    padding-inline: var(--space-8);
  }
}

.section {
  padding-block: clamp(var(--space-12), 6vw, var(--space-24));
}

/* === Header / Nav === */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: oklch(from var(--color-bg) l c h / 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid oklch(from var(--color-border) l c h / 0.5);
  transition: box-shadow var(--transition-interactive);
}

.header--scrolled {
  box-shadow: var(--shadow-sm);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: var(--space-4);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-6);
}

.nav__links {
  display: none;
  align-items: center;
  gap: var(--space-6);
  list-style: none;
}

.nav__links a {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  transition: color var(--transition-interactive);
}

.nav__links a:hover,
.nav__links a.active {
  color: var(--color-text);
}

@media (min-width: 768px) {
  .nav__links {
    display: flex;
  }
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

/* Theme toggle */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  color: var(--color-text-muted);
  transition: background var(--transition-interactive), color var(--transition-interactive);
}

.theme-toggle:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
}

/* Mobile menu toggle */
.menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  color: var(--color-text-muted);
}

@media (min-width: 768px) {
  .menu-toggle {
    display: none;
  }
}

/* Mobile menu */
.mobile-menu {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: var(--space-4);
  z-index: 49;
  flex-direction: column;
  gap: var(--space-2);
  box-shadow: var(--shadow-lg);
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  display: block;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--color-text);
}

.mobile-menu a:hover {
  background: var(--color-surface-offset);
}

/* === Logo === */
.logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-lg);
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.logo:hover {
  color: var(--color-text);
}

.logo__mark {
  flex-shrink: 0;
}

.logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo__text span {
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 600;
  font-family: var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-interactive);
  white-space: nowrap;
  min-height: 44px;
}

.btn--primary {
  background: var(--color-primary);
  color: #fff;
  border: 1px solid var(--color-primary);
}

.btn--primary:hover {
  background: var(--color-primary-hover);
  color: #fff;
  border-color: var(--color-primary-hover);
}

.btn--secondary {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn--secondary:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
  border-color: var(--color-primary);
}

.btn--ghost {
  background: transparent;
  color: var(--color-primary);
  padding: var(--space-2) var(--space-3);
}

.btn--ghost:hover {
  color: var(--color-primary-hover);
}

/* === Hero === */
.hero {
  position: relative;
  background: var(--gradient-hero);
  color: #fff;
  overflow: hidden;
  padding-block: clamp(var(--space-16), 8vw, var(--space-32));
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--grid-pattern);
  background-size: 48px 48px;
  opacity: 0.5;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to top, var(--color-bg) 0%, transparent 100%);
  pointer-events: none;
}

.hero__inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  background: oklch(1 0 0 / 0.1);
  border: 1px solid oklch(1 0 0 / 0.2);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: var(--space-6);
  color: oklch(1 0 0 / 0.9);
}

.hero__badge-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: #4dabf5;
  box-shadow: 0 0 12px oklch(77 0.15 240 / 0.8);
}

.hero h1 {
  font-size: var(--text-3xl);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-6);
  color: #fff;
  text-wrap: balance;
}

.hero__subtitle {
  font-size: var(--text-lg);
  color: oklch(1 0 0 / 0.75);
  line-height: 1.5;
  margin-bottom: var(--space-8);
  max-width: 60ch;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.hero .btn--primary {
  background: #fff;
  color: var(--color-primary);
  border-color: #fff;
}

.hero .btn--primary:hover {
  background: oklch(1 0 0 / 0.9);
  color: var(--color-primary-hover);
}

.hero .btn--secondary {
  background: oklch(1 0 0 / 0.05);
  color: #fff;
  border-color: oklch(1 0 0 / 0.25);
}

.hero .btn--secondary:hover {
  background: oklch(1 0 0 / 0.12);
  border-color: oklch(1 0 0 / 0.4);
}

/* Hero stats */
.hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-8);
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid oklch(1 0 0 / 0.12);
}

.hero__stat {
  display: flex;
  flex-direction: column;
}

.hero__stat-value {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.hero__stat-label {
  font-size: var(--text-xs);
  color: oklch(1 0 0 / 0.6);
  margin-top: var(--space-1);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* === Section Headers === */
.section-header {
  margin-bottom: var(--space-12);
  max-width: 640px;
}

.section-header--centered {
  margin-inline: auto;
  text-align: center;
}

.section-eyebrow {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-3);
}

.section-title {
  font-size: var(--text-2xl);
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-4);
}

.section-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* === Services Grid === */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 640px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.service-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  transition: all var(--transition-interactive);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.service-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.service-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}

.service-card h3 {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--color-text);
}

.service-card p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

.service-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-2);
}

.tag {
  display: inline-block;
  padding: var(--space-1) var(--space-3);
  background: var(--color-surface-offset);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
}

/* === About Section === */
.about {
  background: var(--color-surface);
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
  align-items: center;
}

@media (min-width: 768px) {
  .about__grid {
    grid-template-columns: 1fr 1fr;
  }
}

.about__content h2 {
  font-size: var(--text-2xl);
  font-weight: 700;
  margin-bottom: var(--space-6);
  letter-spacing: -0.02em;
}

.about__content p {
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-4);
}

.about__features {
  list-style: none;
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

.about__features li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text);
}

.about__features li svg {
  flex-shrink: 0;
  color: var(--color-primary);
  margin-top: 2px;
}

/* Experience badges */
.experience-badges {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

.experience-badge {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  text-align: center;
  transition: all var(--transition-interactive);
}

.experience-badge:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-sm);
}

.experience-badge__value {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: var(--space-2);
}

.experience-badge__label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* === Team Section === */
.team-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 640px) {
  .team-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.team-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  text-align: center;
  transition: all var(--transition-interactive);
}

.team-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
}

.team-card__avatar {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  color: #fff;
  background: var(--gradient-accent);
}

.team-card__name {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.team-card__role {
  font-size: var(--text-sm);
  color: var(--color-primary);
  font-weight: 500;
  margin-bottom: var(--space-3);
}

.team-card__bio {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* === Recent Work === */
.recent-work {
  background: var(--color-surface);
}

.work-card {
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.work-card__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-success);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.work-card__label::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--color-success);
}

.work-card h3 {
  font-size: var(--text-lg);
  font-weight: 600;
}

.work-card p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

.work-card__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-2);
}

.work-card__list li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text);
}

.work-card__list li::before {
  content: '→';
  color: var(--color-primary);
  font-weight: 600;
  flex-shrink: 0;
}

/* === CTA Section === */
.cta {
  background: var(--gradient-hero);
  color: #fff;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--grid-pattern);
  background-size: 48px 48px;
  opacity: 0.4;
  pointer-events: none;
}

.cta__inner {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin-inline: auto;
}

.cta h2 {
  font-size: var(--text-2xl);
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.cta p {
  color: oklch(1 0 0 / 0.7);
  font-size: var(--text-base);
  margin-bottom: var(--space-8);
}

.cta .btn--primary {
  background: #fff;
  color: var(--color-primary);
  border-color: #fff;
}

.cta .btn--primary:hover {
  background: oklch(1 0 0 / 0.9);
}

/* === Footer === */
.footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding-block: var(--space-12) var(--space-8);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-8);
}

@media (min-width: 768px) {
  .footer__grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer__brand {
  max-width: 320px;
}

.footer__brand p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-3);
  line-height: 1.6;
}

.footer__col h4 {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-4);
}

.footer__col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer__col a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.footer__col a:hover {
  color: var(--color-primary);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-divider);
}

.footer__bottom p {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.footer__partner {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  font-weight: 500;
}

/* === Blog Page === */
.blog-header {
  background: var(--gradient-hero);
  color: #fff;
  padding-block: clamp(var(--space-12), 5vw, var(--space-20));
  position: relative;
  overflow: hidden;
}

.blog-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--grid-pattern);
  background-size: 48px 48px;
  opacity: 0.4;
  pointer-events: none;
}

.blog-header__inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.blog-header h1 {
  font-size: var(--text-2xl);
  color: #fff;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.blog-header p {
  color: oklch(1 0 0 / 0.7);
  font-size: var(--text-base);
}

.blog-content {
  padding-block: clamp(var(--space-8), 4vw, var(--space-16));
}

.blog-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-divider);
}

.blog-search {
  position: relative;
  flex: 1;
  max-width: 400px;
}

.blog-search input {
  width: 100%;
  padding: var(--space-3) var(--space-3) var(--space-3) var(--space-10);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-text);
  font-size: var(--text-sm);
  min-height: 44px;
}

.blog-search input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-highlight);
}

.blog-search svg {
  position: absolute;
  left: var(--space-3);
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-faint);
}

.blog-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.blog-filter {
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--color-text-muted);
  background: var(--color-surface);
  cursor: pointer;
  transition: all var(--transition-interactive);
  min-height: 36px;
}

.blog-filter:hover {
  border-color: var(--color-primary);
  color: var(--color-text);
}

.blog-filter.active {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

/* Blog post cards */
.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 640px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.blog-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-interactive);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}

.blog-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  color: inherit;
}

.blog-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5) 0;
}

.blog-card__category {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.blog-card__date {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.blog-card__body {
  padding: var(--space-4) var(--space-5) var(--space-5);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.blog-card__title {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-2);
  line-height: 1.3;
}

.blog-card__excerpt {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
  flex: 1;
}

.blog-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-divider);
}

.blog-card__author {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  font-weight: 500;
}

.blog-card__readmore {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

/* Blog loading/empty states */
.blog-loading {
  text-align: center;
  padding: var(--space-16) 0;
  color: var(--color-text-muted);
}

.blog-loading__spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--color-surface-offset);
  border-top-color: var(--color-primary);
  border-radius: var(--radius-full);
  animation: spin 0.8s linear infinite;
  margin: 0 auto var(--space-4);
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.blog-empty {
  text-align: center;
  padding: var(--space-16) 0;
  color: var(--color-text-muted);
}

.blog-empty h3 {
  font-size: var(--text-lg);
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.blog-config-notice {
  background: var(--color-primary-highlight);
  border: 1px solid oklch(from var(--color-primary) l c h / 0.2);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
  margin-bottom: var(--space-8);
  font-size: var(--text-sm);
  color: var(--color-text);
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}

.blog-config-notice svg {
  flex-shrink: 0;
  color: var(--color-primary);
  margin-top: 1px;
}

/* === Blog Post Page === */
.article-hero {
  background: var(--gradient-hero);
  color: #fff;
  padding-block: clamp(var(--space-12), 5vw, var(--space-20));
  position: relative;
  overflow: hidden;
}

.article-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--grid-pattern);
  background-size: 48px 48px;
  opacity: 0.4;
  pointer-events: none;
}

.article-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.article-hero__breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: oklch(1 0 0 / 0.5);
  margin-bottom: var(--space-4);
}

.article-hero__breadcrumb a {
  color: oklch(1 0 0 / 0.7);
}

.article-hero__breadcrumb a:hover {
  color: #fff;
}

.article-hero h1 {
  font-size: var(--text-2xl);
  color: #fff;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.article-hero__meta {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  font-size: var(--text-sm);
  color: oklch(1 0 0 / 0.6);
}

.article-body {
  padding-block: clamp(var(--space-8), 4vw, var(--space-16));
}

.article-content {
  max-width: 720px;
  margin-inline: auto;
}

.article-content h2 {
  font-size: var(--text-xl);
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.article-content h3 {
  font-size: var(--text-lg);
  margin-top: var(--space-6);
  margin-bottom: var(--space-2);
}

.article-content p {
  margin-bottom: var(--space-4);
  line-height: 1.7;
  color: var(--color-text);
}

.article-content ul,
.article-content ol {
  margin-bottom: var(--space-4);
  padding-left: var(--space-6);
}

.article-content li {
  margin-bottom: var(--space-2);
  line-height: 1.6;
}

.article-content pre {
  background: var(--color-surface-offset);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  overflow-x: auto;
  margin-bottom: var(--space-4);
  font-size: var(--text-sm);
}

.article-content code {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-size: var(--text-sm);
}

.article-content p code,
.article-content li code {
  background: var(--color-surface-offset);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
}

.article-content blockquote {
  border-left: 3px solid var(--color-primary);
  padding-left: var(--space-4);
  margin: var(--space-4) 0;
  color: var(--color-text-muted);
  font-style: italic;
}

.article-footer {
  max-width: 720px;
  margin-inline: auto;
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-divider);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.article-footer__back {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-primary);
}

/* === Animations === */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

/* === Responsive === */
@media (max-width: 639px) {
  .hero__stats {
    gap: var(--space-4);
  }
  .hero__stat-value {
    font-size: var(--text-xl);
  }
  .experience-badges {
    grid-template-columns: 1fr;
  }
}
