/* ============================================================
   Pimlico Surveyors – Responsive Stylesheet
   pimlicosurveyors.com
   WCAG 2.1 AA + full mobile-responsive (320px → 1920px)
   Breakpoints: XS≤480 | SM≤600 | MD≤768 | LG≤968 | XL≤1200 | XXL≥1400
   ============================================================ */

/* ════════════════════════════════════════════════════════════
   0. GLOBAL MOBILE FOUNDATION
   ════════════════════════════════════════════════════════════ */

/* Prevent horizontal scroll on any viewport */
html, body {
  overflow-x: hidden;
  max-width: 100vw;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;  /* Prevent font inflation on iOS */
  text-size-adjust: 100%;
}

/* Remove blue tap flash on mobile */
* { -webkit-tap-highlight-color: transparent; }

/* All images responsive by default */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Tables: never cause horizontal scroll */
table {
  max-width: 100%;
}

/* ════════════════════════════════════════════════════════════
   1. ACCESSIBILITY — Focus Indicators (WCAG 2.4.7 / 2.4.11)
   ════════════════════════════════════════════════════════════ */

/* Primary focus ring — #0057b8 on white = 4.68:1 (AA ✓) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid #0057b8;
  outline-offset: 3px;
  border-radius: 2px;
}

/* Gold focus ring for elements on dark/navy backgrounds */
.site-header a:focus-visible,
.site-header button:focus-visible,
.top-bar a:focus-visible,
.site-footer a:focus-visible,
.site-footer button:focus-visible,
.cta-banner a:focus-visible,
.cta-banner button:focus-visible,
.hero-content a:focus-visible,
.hero-content button:focus-visible,
.page-hero a:focus-visible,
.post-header a:focus-visible {
  outline-color: #e4c97e;  /* #e4c97e on #0d2340 = 9.8:1 (AAA ✓) */
}

/* Suppress visible focus ring for mouse/pointer-only users */
a:focus:not(:focus-visible),
button:focus:not(:focus-visible),
input:focus:not(:focus-visible),
textarea:focus:not(:focus-visible),
select:focus:not(:focus-visible),
[tabindex]:focus:not(:focus-visible) {
  outline: none;
}

/* ── Skip to content ── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--clr-gold);
  color: var(--clr-navy);
  padding: .75rem 1.5rem;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  font-weight: 700;
  z-index: 10000;
  transition: top .2s;
  text-decoration: none;
}

.skip-link:focus { top: 0; }

/* ════════════════════════════════════════════════════════════
   2. REDUCED MOTION
   ════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ════════════════════════════════════════════════════════════
   3. XXL — Large Desktops (≥ 1400px)
   ════════════════════════════════════════════════════════════ */
@media (min-width: 1400px) {
  :root { --max-width: 1340px; }
  html { font-size: 17px; }
  .hero-grid { padding: 5.5rem 2rem 5rem; }
  .section { padding: 6rem 0; }
}

/* ════════════════════════════════════════════════════════════
   4. XL — Laptops / Small Desktops (≤ 1200px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 1200px) {
  .hero-grid {
    grid-template-columns: 1fr 380px;
    gap: 2.5rem;
  }
}

/* ════════════════════════════════════════════════════════════
   5. LARGE — Tablets Landscape / Small Laptops (≤ 1024px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  /* Hero: stack text above form card */
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding: 3.5rem 1.5rem 3rem;
  }

  .hero-form-card {
    max-width: 560px;
    width: 100%;
  }

  /* Feature split: stack */
  .feature-split {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .feature-split.reverse { direction: ltr; }

  /* Post layout: stack sidebar below */
  .post-layout {
    grid-template-columns: 1fr;
  }

  .post-sidebar { position: static; }

  /* Post container */
  .post-container {
    grid-template-columns: 1fr;
  }

  /* Stats: 2×2 on tablets */
  .stats-grid { grid-template-columns: repeat(2, 1fr); }

  /* Grid-4 → 2-col */
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* ════════════════════════════════════════════════════════════
   6. LARGE MOBILE / TABLET (≤ 968px)
   — Hamburger activates, hero goes single-col
   ════════════════════════════════════════════════════════════ */
@media (max-width: 968px) {

  /* ── Navigation ── */
  .hamburger { display: flex; }

  /* Top bar: trim on tablets */
  .top-bar { font-size: .78rem; }

  /* ── Typography ── */
  h1 { font-size: clamp(1.75rem, 4vw, 2.25rem); }
  h2 { font-size: clamp(1.5rem, 3.5vw, 1.9rem); }
  h3 { font-size: clamp(1.15rem, 2.5vw, 1.5rem); }

  /* ── Sections ── */
  .section { padding: 4rem 0; }

  /* ── Hero: single column, centred ── */
  .hero { min-height: auto; }

  .hero-grid {
    grid-template-columns: 1fr;
    padding: 3.5rem 1.5rem 3rem;
    gap: 2rem;
    text-align: center;
  }

  .hero-text { order: 1; }
  .hero-form-card {
    order: 2;
    max-width: 560px;
    margin: 0 auto;
  }

  .hero-text h1 { font-size: clamp(1.75rem, 4.5vw, 2.6rem); }
  .hero-text .lead { font-size: 1.05rem; max-width: 100%; }

  .hero-actions { justify-content: center; gap: .75rem; }
  .hero-trust   { justify-content: center; gap: 1.25rem; }

  /* ── Grid-3 → 2-col ── */
  .grid-3 { grid-template-columns: repeat(2, 1fr); }

  /* ── Reviews: 2-col ── */
  .reviews-grid { grid-template-columns: repeat(2, 1fr); }

  /* ── Blog: 2-col ── */
  .blog-grid { grid-template-columns: repeat(2, 1fr); }

  /* ── Areas: 3-col ── */
  .areas-grid { grid-template-columns: repeat(3, 1fr); }

  /* ── Contact: stack ── */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

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

  /* ── Process steps: 2-col ── */
  .process-steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  .process-steps::before { display: none; }

  /* ── Page hero ── */
  .page-hero { padding: 4rem 0 3rem; }
  .post-header { padding: 4rem 0 3rem; }

  /* ── Accreditation strip: wrap ── */
  .accred-strip .container { gap: 1.5rem; }

  /* ── Post layout: sidebar below ── */
  .post-layout { grid-template-columns: 1fr; }
  .post-sidebar { position: static; }
  .post-container { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════
   7. TABLET PORTRAIT (≤ 768px)
   — Hide hero video, shrink sections, stack most layouts
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Base font ── */
  html { font-size: 15.5px; }

  /* ── Typography ── */
  h1 { font-size: clamp(1.6rem, 5vw, 2rem); }
  h2 { font-size: clamp(1.4rem, 4vw, 1.75rem); }
  h3 { font-size: 1.2rem; }

  /* ── Sections ── */
  .section { padding: 3.5rem 0; }

  /* ── Container ── */
  .container { padding: 0 1.25rem; }

  /* ── Hero ── */
  /* Hide hero video — rely on bg image fallback */
  .hero-bg video { display: none !important; }

  .hero-grid {
    padding: 3rem 1.25rem 2.5rem;
    gap: 1.75rem;
  }

  .hero-text h1 { font-size: clamp(1.6rem, 5vw, 2.2rem); }
  .hero-text .lead { font-size: 1rem; }

  .hero-actions {
    flex-direction: column;
    gap: .75rem;
    align-items: stretch;
  }
  .hero-actions .btn { width: 100%; justify-content: center; min-height: 44px; }

  .hero-trust { gap: 1rem; flex-wrap: wrap; }
  .hero-form-card { padding: 1.75rem; }

  /* ── Feature image ── */
  .feature-image img { height: 300px; }

  /* ── Grid-2 → single col ── */
  .grid-2 { grid-template-columns: 1fr; gap: 1.5rem; }

  /* ── FAQ ── */
  .faq-question { padding: 1rem 1.25rem; font-size: .95rem; }
  .faq-answer.open { padding: 1rem 1.25rem; }

  /* ── CTA Banner ── */
  .cta-banner .container { padding: 0 1.25rem; }

  /* ── Footer bottom ── */
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: .75rem;
  }
}

/* ════════════════════════════════════════════════════════════
   8. SMALL — Mobile Landscape / Large Mobile (≤ 640px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {

  /* ── Top bar: single line, centred ── */
  .top-bar .container {
    flex-direction: column;
    text-align: center;
    gap: .3rem;
  }

  /* ── Hero ── */
  .hero-grid { padding: 2.5rem 1rem 2rem; }
  .hero-text h1 { font-size: clamp(1.5rem, 6vw, 1.85rem); }
  .hero-text .lead { font-size: .97rem; }

  /* ── Stats: 2×2 ── */
  .stats-grid { grid-template-columns: repeat(2, 1fr); }

  /* ── Blog: 1-col ── */
  .blog-grid { grid-template-columns: 1fr; }

  /* ── Reviews: 1-col ── */
  .reviews-grid { grid-template-columns: 1fr; }

  /* ── Areas: 2-col ── */
  .areas-grid { grid-template-columns: repeat(2, 1fr); }

  /* ── All grids → single column ── */
  .grid-3, .grid-4 { grid-template-columns: 1fr; gap: 1.25rem; }

  /* ── Sections ── */
  .section { padding: 3rem 0; }
  .section-header { margin-bottom: 2rem; }
  .section-header h2 { font-size: clamp(1.25rem, 5vw, 1.5rem); }
  .section-header .lead,
  .section-header p { font-size: .95rem; }

  /* ── Page hero ── */
  .page-hero { padding: 3rem 0 2.5rem; }
  .page-hero h1 { font-size: clamp(1.4rem, 5vw, 1.9rem); }
  .post-header { padding: 3rem 0 2rem; }

  /* ── Feature image ── */
  .feature-image img { height: 240px; }

  /* ── Process steps → single col ── */
  .process-steps { grid-template-columns: 1fr; gap: 1.5rem; }

  /* ── Footer: single col ── */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .footer-brand p { font-size: .9rem; }
  .footer-bottom { flex-direction: column; text-align: center; }

  /* ── CTA Banner ── */
  .cta-banner .container { text-align: center; }
  .cta-banner h2 { font-size: clamp(1.2rem, 5vw, 1.5rem); }
  .cta-banner p { font-size: .95rem; }
  .cta-banner .hero-actions,
  .cta-banner .btn-group {
    flex-direction: column;
    align-items: center;
  }
  .cta-banner .btn { width: 100%; max-width: 340px; justify-content: center; }

  /* ── Contact ── */
  .contact-form-wrap { padding: 1.5rem; }
  .contact-grid { gap: 2rem; }

  /* ── Form cards ── */
  .hero-form-card { padding: 1.25rem; }
  .hero-form-card h3 { font-size: 1.1rem; }

  /* ── Cookie banner ── */
  .cookie-banner {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
  .cookie-actions { width: 100%; justify-content: center; }
}

/* ════════════════════════════════════════════════════════════
   9. EXTRA SMALL — Mobile Portrait (≤ 480px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {

  /* ── Base font: slightly smaller ── */
  html { font-size: 15px; }

  /* ── Container ── */
  .container { padding: 0 1rem; }

  /* ── Sections ── */
  .section { padding: 2.5rem 0; }

  /* ── Typography ── */
  h1 { font-size: clamp(1.35rem, 6vw, 1.65rem); }
  h2 { font-size: clamp(1.2rem, 5vw, 1.4rem); }
  h3 { font-size: 1.1rem; }
  p  { font-size: .95rem; line-height: 1.65; }

  /* ── Hero ── */
  .hero-grid { padding: 2rem 1rem 1.75rem; }

  .hero-text h1 { font-size: clamp(1.25rem, 7vw, 1.6rem); }
  .hero-text .lead { font-size: .95rem; }

  .hero-form-card {
    padding: 1.1rem;
    border-radius: var(--radius-md);
  }

  .hero-form-card h3 { font-size: 1rem; }

  .hero-actions .btn { padding: .75rem 1.25rem; font-size: .9rem; }

  .badge { font-size: .72rem; padding: .35rem .85rem; }

  /* ── Trust items: wrap & centre ── */
  .hero-trust {
    justify-content: flex-start;
    gap: .75rem;
    flex-wrap: wrap;
  }

  .trust-item { font-size: .8rem; }

  /* ── Stats ── */
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item { padding: 1.25rem 1rem; }
  .stat-item .number { font-size: 2rem; }

  /* ── Accreditation strip ── */
  .accred-strip .container { gap: 1rem; }
  .accred-item { font-size: .78rem; }

  /* ── Service card ── */
  .service-card { padding: 1.5rem; }
  .service-icon { width: 48px; height: 48px; }
  .service-icon svg { width: 24px; height: 24px; }

  /* ── Process steps ── */
  .step-number { width: 48px; height: 48px; font-size: 1.1rem; }
  .step h4 { font-size: .95rem; }

  /* ── Areas: 2-col even on tiny phones ── */
  .areas-grid { grid-template-columns: repeat(2, 1fr); gap: .75rem; }
  .area-tag { padding: .65rem .75rem; font-size: .82rem; }

  /* ── Blog cards ── */
  .blog-card-image { height: 180px; }

  /* ── FAQ ── */
  .faq-question { padding: .9rem 1rem; font-size: .9rem; }
  .faq-answer.open { padding: .9rem 1rem; }

  /* ── Buttons: full-width on tiny screens ── */
  .hero-actions .btn,
  .btn-group .btn {
    width: 100%;
    justify-content: center;
  }

  /* ── Page hero ── */
  .page-hero { padding: 2.5rem 0 2rem; }
  .page-hero h1 { font-size: clamp(1.25rem, 6vw, 1.6rem); }

  /* ── Post header ── */
  .post-header { padding: 2.5rem 0 2rem; }

  /* ── Post layout ── */
  .post-layout, .post-container { padding: 1.5rem 1rem 2rem; }
  .post-featured-image img,
  .post-hero-image img { height: 220px; }

  /* ── Team card image ── */
  .team-card-image { height: 240px; }

  /* ── Review card ── */
  .review-card { padding: 1.25rem; }

  /* ── Contact ── */
  .contact-form-wrap { padding: 1.25rem; }
  .contact-detail-icon { width: 36px; height: 36px; }

  /* ── Footer ── */
  .footer-grid { gap: 1.25rem; }
  .footer-col h4 { font-size: .95rem; }
  .footer-links a { font-size: .85rem; }

  /* ── Section header ── */
  .section-header { margin-bottom: 1.75rem; }
  .section-header h2 { font-size: clamp(1.1rem, 6vw, 1.35rem); }
  .section-header .lead,
  .section-header p { font-size: .9rem; }
}

/* ════════════════════════════════════════════════════════════
   10. TINY — Very Small Phones (≤ 360px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 360px) {
  html { font-size: 14px; }

  .container { padding: 0 .875rem; }

  .hero-text h1 { font-size: 1.25rem; }
  .hero-form-card { padding: 1rem; }

  .stats-grid { grid-template-columns: 1fr 1fr; }
  .areas-grid { grid-template-columns: 1fr 1fr; }

  .btn { padding: .7rem 1rem; font-size: .88rem; }

  .accred-strip .container { flex-direction: column; align-items: flex-start; }
}

/* ════════════════════════════════════════════════════════════
   11. FORMS — HubSpot & Native Input Responsive
   ════════════════════════════════════════════════════════════ */

/* Prevent iOS zoom on input focus (font-size must be ≥ 16px) */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="search"],
input[type="url"],
input[type="password"],
textarea,
select {
  font-size: 1rem; /* = 16px — prevents iOS auto-zoom */
  max-width: 100%;
}

/* Label sizing on small screens */
@media (max-width: 600px) {
  label { font-size: .9rem; }

  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="number"],
  input[type="search"],
  input[type="url"],
  input[type="password"],
  textarea,
  select {
    font-size: 16px;  /* Critical: prevents iOS zoom */
    padding: .65rem .9rem;
  }

  input[type="submit"],
  button[type="submit"] {
    width: 100%;
    padding: .9rem 1.5rem;
    min-height: 44px;
  }
}

/* HubSpot form overrides for mobile */
@media (max-width: 600px) {
  /* Container */
  .hs-form { width: 100% !important; }

  /* Field groups: always stack on mobile */
  .hs-form .hs-form-field { margin-bottom: .75rem !important; }

  .hs-form fieldset {
    max-width: 100% !important;
  }

  /* Inputs & selects */
  .hs-form .hs-input,
  .hs-form input[type="text"],
  .hs-form input[type="email"],
  .hs-form input[type="tel"],
  .hs-form select {
    font-size: 16px !important;  /* Critical: prevents iOS zoom */
    padding: .65rem .9rem !important;
    width: 100% !important;
  }

  /* Textarea */
  .hs-form textarea {
    font-size: 16px !important;
    padding: .65rem .9rem !important;
    min-height: 100px !important;
    width: 100% !important;
  }

  /* Submit button */
  .hs-form .hs-button,
  .hs-form input[type="submit"] {
    width: 100% !important;
    padding: .9rem 1.5rem !important;
    font-size: 1rem !important;
    min-height: 44px !important;
  }

  /* Labels */
  .hs-form label { font-size: .9rem !important; }

  /* Error messages */
  .hs-form .hs-error-msgs li { font-size: .82rem !important; }
}

/* HubSpot iframe always full-width */
.hs-form-iframe { width: 100% !important; }

/* ════════════════════════════════════════════════════════════
   12. TABLES — Responsive Scroll
   ════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  /* Wrap overflowing tables */
  .comparison-table,
  .legal-doc table,
  .post-body table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    max-width: 100%;
    font-size: .82rem;
  }

  .comparison-table thead th { padding: .75rem 1rem; }
  .comparison-table td { padding: .65rem 1rem; }
}

/* ════════════════════════════════════════════════════════════
   13. BUTTONS — Mobile Touch Targets (WCAG 2.5.5)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .btn {
    min-height: 44px;  /* Apple / WCAG 2.5.5 touch target */
    padding: .8rem 1.5rem;
    font-size: .93rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* Hero CTA buttons always full-width */
  .hero-actions .btn { width: 100%; }

  /* Inline button groups: no left margin leak */
  .btn + .btn { margin-left: 0; }
}

/* ════════════════════════════════════════════════════════════
   14. BLOG — Single Post Responsive
   ════════════════════════════════════════════════════════════ */
@media (max-width: 968px) {
  .post-layout { grid-template-columns: 1fr; }
  .post-sidebar { position: static; }
  .post-container { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .post-body h2 { font-size: 1.35rem; margin: 1.5rem 0 .75rem; }
  .post-body h3 { font-size: 1.1rem; margin: 1.25rem 0 .5rem; }
  .post-body p  { font-size: .95rem; }

  .post-content h2 { font-size: 1.35rem; }
  .post-content h3 { font-size: 1.1rem; }

  .sidebar-widget { padding: 1.25rem; }

  .post-header h1 { font-size: clamp(1.15rem, 4.5vw, 1.45rem); line-height: 1.28; }
  .post-meta { gap: 1rem; font-size: .8rem; }
  .post-meta-author img { width: 28px; height: 28px; }

  .post-intro { font-size: 1rem; padding-left: 1rem; }

  .post-cta-box { padding: 1.5rem; }
  .post-cta-box h3 { font-size: 1.15rem; }

  .post-blockquote { padding: 1rem 1.25rem; }

  .post-hero-image img,
  .post-featured-image img { height: 220px; }
}

/* ════════════════════════════════════════════════════════════
   15. LEGAL PAGES (Privacy / Terms)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .legal-doc h2 { font-size: 1.2rem; }
  .legal-doc h3 { font-size: 1rem; }
  .legal-doc p, .legal-doc li { font-size: .93rem; }
}

/* ════════════════════════════════════════════════════════════
   16. BACK-TO-TOP & COOKIE — Mobile Polish
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .back-to-top {
    bottom: 1.25rem;
    right: 1.25rem;
    width: 40px;
    height: 40px;
  }

  .cookie-banner {
    padding: 1rem;
    gap: .75rem;
  }
}

/* ════════════════════════════════════════════════════════════
   17. SCROLL PROGRESS — Always on top, zero height on mobile
   ════════════════════════════════════════════════════════════ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--clr-gold);
  width: 0%;
  z-index: 9999;
  transition: width .1s linear;
  pointer-events: none;
}

/* ════════════════════════════════════════════════════════════
   18. PRINT — Clean output
   ════════════════════════════════════════════════════════════ */
@media print {
  .site-header,
  .site-footer,
  .back-to-top,
  .cookie-banner,
  .scroll-progress,
  .hero-particles,
  .skip-link { display: none !important; }

  body { color: #000; font-size: 12pt; }
  a { color: #000; text-decoration: underline; }
  h1, h2, h3 { page-break-after: avoid; }
  img { max-width: 100%; }
}

/* ════════════════════════════════════════════════════════════
   19. MOBILE NAV OVERLAY — Injected by JS
   ════════════════════════════════════════════════════════════ */
/* Overlay state transitions handled in style.css .nav-overlay rules */
/* Slide-down animation for nav on open */
@media (max-width: 968px) {
  /* When nav panel slides in, content fades */
  .primary-nav {
    /* Already defined in style.css: translateX(100%) → translateX(0) */
  }

  /* Nav panel shadow for depth */
  .primary-nav.open {
    box-shadow: -6px 0 30px rgba(0, 0, 0, .4);
  }

  /* Nav brand label inside mobile nav */
  .nav-brand-label {
    display: block;
    padding: .5rem 1rem 1.25rem;
    font-size: .78rem;
    color: rgba(255,255,255,.55);
    text-transform: uppercase;
    letter-spacing: .1em;
    font-weight: 600;
    border-bottom: 1px solid rgba(255,255,255,.08);
    margin-bottom: .5rem;
  }
}

/* ════════════════════════════════════════════════════════════
   20. STATS BAR — 2×2 on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 400px) {
  .stats-grid { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════
   21. SERVICES PAGE — Item padding / font-size at ≤600px
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .service-detail-section { padding: 2.5rem 0; }
  .service-item-header { flex-direction: column; gap: 1rem; }
  .service-item-icon { align-self: flex-start; }
}

/* ════════════════════════════════════════════════════════════
   22. ACCREDITATION STRIP — Responsive wrapping
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .accred-strip .container {
    gap: 1rem;
    justify-content: flex-start;
  }

  .accred-item { font-size: .8rem; }
  .accred-badge { font-size: .72rem; padding: .25rem .5rem; }
}

/* ════════════════════════════════════════════════════════════
   23. HEADER HEIGHT — Compact header on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .header-inner { padding: .65rem 1rem; }
  .logo-text .name { font-size: 1.1rem; }
  .logo-text .tagline { display: none; }
  .logo-icon { width: 36px; height: 36px; }
  .logo-icon svg { width: 22px; height: 22px; }
}

/* ════════════════════════════════════════════════════════════
   24. TEAM CARD — Full-width on tiny screens
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .team-card-image { height: 260px; }
  .team-card-body { padding: 1.25rem; }
  .team-card-body h3 { font-size: 1.05rem; }
}

/* ════════════════════════════════════════════════════════════
   25. HERO — Enhanced Mobile Fixes
   ════════════════════════════════════════════════════════════ */

/* Reduce hero min-height on mobile so it doesn't force-scroll */
@media (max-width: 968px) {
  .hero { min-height: auto; padding-bottom: 0; }
}

@media (max-width: 768px) {
  .hero { min-height: auto; }
  .hero-grid { text-align: center; }
  .hero-text { order: 1; }
  .hero-form-card {
    order: 2;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
  }
}

@media (max-width: 600px) {
  .hero { padding: 0; }
  .hero-grid {
    padding: 2.5rem 1rem 2rem;
    gap: 1.5rem;
  }
  .hero-text h1 { font-size: clamp(1.4rem, 6vw, 1.75rem); }
  .hero-text .lead { font-size: .95rem; }
  .hero-form-card { padding: 1.25rem; }
  .hero-form-card h3 { font-size: 1.05rem; }

  /* Badge row: wrap & centre */
  .hero-text .badge,
  .hero-badge {
    font-size: .72rem;
    padding: .35rem .75rem;
  }
  .hero-badges,
  .hero-trust {
    flex-wrap: wrap;
    justify-content: center;
    gap: .5rem;
  }
}

@media (max-width: 480px) {
  .hero-grid { padding: 2rem 1rem 1.5rem; gap: 1.25rem; }
  .hero-text h1 { font-size: clamp(1.25rem, 7vw, 1.5rem); }
  .hero-form-card { padding: 1rem; border-radius: var(--radius-md); }
  .hero-form-card h3 { font-size: 1rem; }
  .hero-form-card p { font-size: .85rem; }
  input[type="submit"],
  button[type="submit"],
  .hero-form-card .btn { padding: .7rem 1rem; }
}

/* ════════════════════════════════════════════════════════════
   26. NAVIGATION — Hamburger touch target & overlay polish
   ════════════════════════════════════════════════════════════ */
@media (max-width: 968px) {
  /* Ensure hamburger always has 48px touch zone */
  .hamburger {
    min-width: 48px;
    min-height: 48px;
    width: 48px;
    height: 48px;
  }

  /* Nav links: extra tap room */
  .primary-nav a {
    padding: 1rem 1.25rem;
    font-size: 1rem;
    min-height: 48px;
  }

  /* CTA link in mobile nav */
  .primary-nav .nav-cta,
  .primary-nav li:last-child a {
    padding: 1rem 1.25rem !important;
    min-height: 48px !important;
    font-size: 1rem !important;
  }
}

/* Nav overlay: smooth fade */
.nav-overlay {
  display: none;
  opacity: 0;
  transition: opacity .3s ease;
}
.nav-overlay.visible {
  display: block;
  opacity: 1;
}

/* ════════════════════════════════════════════════════════════
   27. GRID LAYOUTS — Additional breakpoints
   ════════════════════════════════════════════════════════════ */

/* Feature grid (used in why-choose sections) */
@media (max-width: 768px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
}
@media (max-width: 480px) {
  .feature-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .feature-item {
    padding: 1rem;
    text-align: center;
  }
  .feature-icon { font-size: 2rem; margin-bottom: .5rem; }
}

/* Service grid refinements */
@media (max-width: 600px) {
  .service-card { padding: 1.25rem; }
  .service-card h3 { font-size: 1.05rem; }
  .service-icon { width: 44px; height: 44px; }
  .service-icon svg { width: 22px; height: 22px; }
  .service-item { padding: 1.25rem; }
  .service-item h3 { font-size: 1.1rem; }
}

/* ════════════════════════════════════════════════════════════
   28. FOOTER — Enhanced single-column & centred badges
   ════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
    text-align: center;
  }
  .footer-brand { text-align: center; }
  .footer-brand p { font-size: .9rem; }
  .footer-accreditation {
    justify-content: center;
    flex-wrap: wrap;
    gap: .5rem;
    display: flex;
  }
  .footer-links { padding-left: 0; }
  .footer-links li { list-style: none; }
  .footer-links a { justify-content: center; }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: .5rem;
    padding: 1rem 0;
  }
}

/* ════════════════════════════════════════════════════════════
   29. CTA SECTIONS — Banner & inline CTA
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .cta-banner { padding: 2.5rem 0; }
  .cta-banner h2 { font-size: clamp(1.15rem, 5vw, 1.45rem); }
  .cta-banner p { font-size: .93rem; margin-bottom: 1.25rem; }

  /* Generic CTA section (non-banner) */
  .cta-section {
    padding: 2rem 1.5rem;
    border-radius: var(--radius-md);
    margin: 0 .75rem;
  }
  .cta-section h2 { font-size: 1.25rem; }
  .cta-section p  { font-size: .95rem; margin-bottom: 1.25rem; }
  .cta-section .btn { width: 100%; justify-content: center; }
}

/* ════════════════════════════════════════════════════════════
   30. BLOG — Article page extra fixes
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .post-body   { padding: 0 .25rem; }
  .post-meta   { flex-wrap: wrap; gap: .75rem; }
  .post-intro  { font-size: .97rem; }
}

@media (max-width: 480px) {
  .post-body h2 { font-size: 1.25rem; }
  .post-body h3 { font-size: 1.05rem; }
  .post-body p  { font-size: .93rem; }
  .related-post img { width: 56px; height: 56px; border-radius: var(--radius-sm); flex-shrink: 0; }
  .related-post { gap: .6rem; }
  .post-featured-image img,
  .post-hero-image img { height: 200px; }
}

/* ════════════════════════════════════════════════════════════
   31. CONTACT PAGE — Form/info order & padding
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  /* Show form first, then info block */
  .contact-form-wrapper { order: 1; }
  .contact-info         { order: 2; }
}

@media (max-width: 480px) {
  .contact-form-wrapper { padding: 1.25rem; }
  .contact-detail-row   { gap: .75rem; }
}

/* ════════════════════════════════════════════════════════════
   32. AREAS PAGE — Tighter grid on tiny screens
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .areas-grid {
    grid-template-columns: 1fr;
    gap: .75rem;
  }
  .area-tag  { padding: .75rem 1rem; font-size: .88rem; }
  .area-card { padding: 1rem; }
}

/* ════════════════════════════════════════════════════════════
   33. BUTTONS — Full-width & touch-friendly on small screens
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .btn-primary,
  .btn-outline,
  .btn-outline-navy {
    display: flex;
    width: 100%;
    justify-content: center;
    min-height: 48px;
    font-size: .93rem;
  }

  /* Except buttons inside nav or compact UI */
  .site-header .btn,
  .cookie-actions .btn,
  .faq-icon { width: auto; min-height: 44px; }

  /* Stacked btn groups */
  .btn-group,
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    gap: .65rem;
  }
}

/* ════════════════════════════════════════════════════════════
   34. TYPOGRAPHY — Fluid scaling refinements
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .section-header h2    { font-size: clamp(1.2rem, 5vw, 1.5rem); }
  .section-header .lead,
  .section-header p     { font-size: .93rem; }
  .section-header       { margin-bottom: 1.75rem; }
}

@media (max-width: 480px) {
  html   { font-size: 15px; }
  body   { font-size: .97rem; }
  h1     { font-size: clamp(1.3rem, 6vw, 1.6rem); }
  h2     { font-size: clamp(1.15rem, 5vw, 1.4rem); }
  h3     { font-size: 1.1rem; }
  p      { font-size: .95rem; line-height: 1.65; }
  .lead  { font-size: 1rem; }
}

/* ════════════════════════════════════════════════════════════
   35. SPACING & CONTAINERS — Tighten padding on XS
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .section        { padding: 2.25rem 0; }
  .section-header { margin-bottom: 1.5rem; }
  .container      { padding: 0 1rem; }
}

/* ════════════════════════════════════════════════════════════
   36. FAQ — Touch-friendly accordion on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .faq-item     { margin-bottom: .75rem; }
  .faq-question {
    padding: 1rem 1.1rem;
    font-size: .93rem;
    line-height: 1.45;
    min-height: 52px;
  }
  .faq-answer.open { padding: .9rem 1.1rem; }
  .faq-icon { flex-shrink: 0; }
}

/* ════════════════════════════════════════════════════════════
   37. TABLE — Overflow scroll on all screens ≤ 640px
   ════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  table:not(.no-scroll) {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
  }
}

/* ════════════════════════════════════════════════════════════
   38. ACCREDITATION / BADGE ROW — Centre on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .footer-accreditation,
  .accreditation-badges {
    justify-content: center;
    flex-wrap: wrap;
    display: flex;
    gap: .5rem;
  }
}

/* ════════════════════════════════════════════════════════════
   39. REVIEW CARDS — Stack on small screens
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .review-card  { padding: 1.1rem; }
  .review-stars { font-size: .9rem; }
  .review-card blockquote { font-size: .9rem; }
}

/* ════════════════════════════════════════════════════════════
   40. VIDEO BACKGROUND — Hide on ≤ 768px for performance
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .hero-bg video { display: none !important; }
}

/* ════════════════════════════════════════════════════════════
   41. PAGE HERO (inner pages) — Reduce padding on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .page-hero {
    padding: 2.75rem 0 2rem;
    text-align: center;
  }
  .page-hero h1   { font-size: clamp(1.3rem, 5.5vw, 1.65rem); }
  .page-hero .lead { font-size: .95rem; }
  .page-hero .breadcrumb { justify-content: center; }
}

/* ════════════════════════════════════════════════════════════
   42. PROCESS STEPS — Icon sizing on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .step { padding: 1.25rem 1rem; }
  .step-number { width: 44px; height: 44px; font-size: 1rem; }
  .step h4 { font-size: .93rem; }
  .step p  { font-size: .88rem; }
}

/* ════════════════════════════════════════════════════════════
   43. SIDEBAR (blog posts) — Compact on tablet
   ════════════════════════════════════════════════════════════ */
@media (max-width: 968px) {
  .post-sidebar { margin-top: 2rem; }
  .sidebar-widget:last-child { margin-bottom: 0; }
}

/* ════════════════════════════════════════════════════════════
   44. CALLOUT BOXES — Tighter on mobile
   ════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .post-content .callout,
  .post-body .callout {
    padding: 1rem 1.1rem;
    font-size: .92rem;
  }
  .post-cta-box { padding: 1.25rem; }
  .post-cta-box h3 { font-size: 1.05rem; }
}

/* ════════════════════════════════════════════════════════════
   25. DARK MODE PLACEHOLDER
   ════════════════════════════════════════════════════════════ */
@media (prefers-color-scheme: dark) {
  /* We intentionally keep light theme for professional consistency */
}
