/* ═══════════════════════════════════════════════════
   RESPONSIVE CSS — Complete rebuild
   Breakpoints: 1200 · 1024 · 768 · 480 · 360
   Covers: Mobile S/M/L · iPad Mini/Air/Pro · Desktop
═══════════════════════════════════════════════════ */

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   LARGE TABLETS / SMALL LAPTOPS  (≤ 1200px)
   iPad Pro 12.9" landscape, Surface Pro
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 1200px) {

  /* Hero */
  .hero-inner {
    grid-template-columns: 1fr 360px;
    gap: 48px;
  }
  .ht-reveal { font-size: clamp(52px, 7vw, 96px); }

  /* About: tighten gap */
  .about-grid {
    grid-template-columns: 320px 1fr;
    gap: 48px;
  }
  .about-photo-wrap { height: 400px; }

  /* Services */
  .svc-row { grid-template-columns: 72px 1fr 52px 44px; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   TABLETS (≤ 1024px)
   iPad Air/Mini landscape, iPad 10th gen landscape
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 1024px) {

  :root { --pad-x: clamp(24px, 4vw, 60px); }

  /* Hero: stack left/right into single column */
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-top: 20px;
  }
  .hero-left { order: 1; }
  .hero-right { order: 2; }

  /* Hero right: switch to 2-col grid of cards */
  .hero-right {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .hcard-name  { grid-column: 1 / -1; }
  .hcard-stats { grid-column: 1 / -1; }
  .hcard:hover { transform: none; } /* No horizontal shift on grid */

  /* About: stack photo + content */
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .about-photo-col {
    position: static; /* un-stick on tablet */
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
  }
  .about-photo-wrap {
    height: 340px;
    grid-row: 1;
  }
  .lang-cards { grid-row: 1; }

  /* Services */
  .svc-row { grid-template-columns: 60px 1fr 44px; }
  .svc-icon-wrap { display: none; }

  /* Work mosaic: 3 cols */
  .work-mosaic {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 220px);
  }
  .wi-large { grid-column: span 2; }

  /* Product */
  .product-layout { grid-template-columns: 1fr; gap: 48px; }
  .prod-visual { max-width: 580px; margin: 0 auto; }
  .prod-highlights { grid-template-columns: repeat(3, 1fr); }

  /* Contact */
  .contact-layout { grid-template-columns: 1fr; gap: 48px; }

  /* Footer */
  .footer-mid { grid-template-columns: repeat(2, 1fr); }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   PORTRAIT TABLETS (≤ 820px)
   iPad Mini portrait, iPad Air portrait
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 820px) {

  /* About photo col: back to single column stacked */
  .about-photo-col {
    grid-template-columns: 1fr;
  }
  .about-photo-wrap {
    /* On portrait iPad use aspect-ratio to ensure full face visible */
    height: auto;
    aspect-ratio: 4 / 5;
    max-height: 480px;
  }
  .about-photo {
    /* Show head + shoulders — never crop face */
    object-position: center 5%;
  }

  /* Product highlights: 2 cols */
  .prod-highlights { grid-template-columns: repeat(2, 1fr); }

  /* Section header row: stack */
  .section-header-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  /* Work mosaic: 2 cols */
  .work-mosaic {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(4, 200px);
  }
  .wi-large { grid-column: span 2; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   MOBILE LANDSCAPE + LARGE PHONES (≤ 768px)
   iPhone 14 Pro Max landscape, Galaxy S23+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 768px) {

  :root {
    --section-y: 64px;
    --pad-x: 20px;
  }

  /* Nav: hide links, show burger */
  .nav-list { display: none; }
  .nav-hire { display: none; }
  .nav-burger { display: flex; }

  /* Hero title: scale down */
  .ht-reveal { font-size: clamp(48px, 12vw, 80px); }
  .hero-intro { font-size: 15px; margin-bottom: 32px; }
  .hero-actions { gap: 10px; }
  .hcta-primary { padding: 13px 24px; }
  .hcta-cv { padding: 12px 18px; }

  /* Hero right cards: stay 2-col but smaller */
  .hero-right { grid-template-columns: 1fr 1fr; }
  .hcs-num { font-size: 28px; }

  /* About photo */
  .about-photo-wrap {
    aspect-ratio: 3 / 4;
    height: auto;
    max-height: 400px;
  }
  .about-photo { object-position: center 5%; }

  /* Services: simpler row */
  .svc-row {
    grid-template-columns: 48px 1fr 36px;
    padding: 18px 0;
  }
  .svc-icon-wrap, .svc-arrow { display: none; }
  .svc-desc { display: none; }
  .svc-tags { display: none; }

  /* Work filter: wrap */
  .work-filter-wrap { flex-wrap: wrap; }

  /* Product highlights: 1 col */
  .prod-highlights { grid-template-columns: 1fr; }
  .prod-tech-row { gap: 6px; }
  .compat-bar { gap: 8px; }
  .compat-item { font-size: 12px; }

  /* Contact form */
  .cf-row { grid-template-columns: 1fr; }

  /* Footer */
  .footer-top { flex-direction: column; gap: 24px; }
  .footer-mid { grid-template-columns: 1fr 1fr; gap: 24px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 8px; }

  /* Toolset: scroll horizontal */
  .toolset-wrap { flex-direction: column; align-items: flex-start; gap: 12px; }
  .toolset-row { flex-wrap: wrap; }

  /* Section headings */
  .section-heading { font-size: clamp(36px, 9vw, 56px); }
  .about-headline  { font-size: clamp(36px, 9vw, 52px); }
  .prod-heading    { font-size: clamp(48px, 12vw, 70px); }
  .contact-heading { font-size: clamp(36px, 9vw, 52px); }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   STANDARD MOBILE (≤ 600px)
   iPhone 14, Galaxy S23, Pixel 7
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 600px) {

  /* Hero right: single column cards */
  .hero-right {
    grid-template-columns: 1fr;
  }
  .hcard-name  { grid-column: unset; }
  .hcard-stats { grid-column: unset; }

  /* Hero: more vertical space */
  .hero { padding-bottom: 32px; }
  .ht-reveal { font-size: clamp(44px, 13vw, 72px); }
  .hero-status { font-size: 10px; padding: 7px 14px; }

  /* About: photo becomes portrait card */
  .about-photo-wrap {
    aspect-ratio: 3 / 4;
    max-height: 360px;
  }
  /* Stack open-to labels */
  .about-open-to { flex-direction: column; align-items: flex-start; gap: 8px; }

  /* Work: 2 cols still */
  .work-mosaic {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(4, 180px);
  }
  .wi-large { grid-column: span 2; }

  /* Product compat: 2 per row */
  .compat-bar { justify-content: flex-start; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   SMALL MOBILE (≤ 480px)
   iPhone SE, Galaxy A14, older Android
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 480px) {

  :root { --pad-x: 16px; }

  .ht-reveal { font-size: clamp(40px, 12vw, 60px); }
  .hero-actions { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hcta-primary, .hcta-cv, .hcta-ghost { width: 100%; justify-content: center; }

  /* About photo: shrink height */
  .about-photo-wrap { max-height: 300px; }
  .about-cv { flex-direction: column; align-items: flex-start; gap: 8px; }
  .cv-btn { width: 100%; justify-content: center; }

  /* Work: single col */
  .work-mosaic {
    grid-template-columns: 1fr;
    grid-template-rows: repeat(8, 160px);
  }
  .wi-large { grid-column: span 1; }

  /* Footer */
  .footer-mid { grid-template-columns: 1fr; }

  /* Nav */
  .nav-brand { font-size: 22px; }
  .brand-a   { font-size: 26px; }
  .brand-dot { font-size: 30px; }

  /* Services */
  .svc-num { display: none; }
  .svc-row { grid-template-columns: 1fr 36px; padding: 16px 0; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   VERY SMALL MOBILE (≤ 360px)
   iPhone 5/SE 1st gen, small budget Androids
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 360px) {

  :root { --pad-x: 14px; }

  .ht-reveal { font-size: 38px; }
  .hero-intro { font-size: 14px; }

  .hcs-num { font-size: 24px; }
  .hce-grid { grid-template-columns: 1fr; }

  .about-photo-wrap { max-height: 260px; }

  .section-heading { font-size: 32px; }
  .about-headline  { font-size: 32px; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   ACCESSIBILITY — Reduced Motion
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .ticker-track { animation: none; }
  .hms-track    { animation: none; }
  .scroll-thumb { animation: none; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   PRINT
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media print {
  .site-header, .page-loader, .cursor,
  .site-grain, .scroll-progress-bar,
  .mobile-overlay, .hero-canvas { display: none !important; }
  body { background: white; color: black; cursor: auto; }
  a { color: black; }
  .about-photo { filter: none; }
}