/* ==========================================================
   Now & Zen — Mobile-First Overrides
   Loaded after styles.css on every page.
   Active at widths <= 720px. Designed for ~375px screens.
   ========================================================== */

@media (max-width: 720px) {

  /* ---------- Base rhythm ---------- */
  html { font-size: 16px; }
  body { font-size: 16px; line-height: 1.6; }

  h1 { font-size: 2.25rem !important; line-height: 1.1 !important; letter-spacing: -0.01em; }
  h2 { font-size: 1.75rem !important; line-height: 1.15 !important; }
  h3 { font-size: 1.25rem !important; }

  .container,
  .container-wide,
  .container-narrow { padding: 0 20px; }

  section { padding: 60px 0 !important; }

  /* ---------- Header ---------- */
  .site-header { padding: 12px 0; }
  .site-header.scrolled { padding: 8px 0; }
  .header-inner { padding: 0 16px; gap: 12px; }
  .brand img { height: 42px !important; }
  .site-header.scrolled .brand img { height: 38px !important; }

  /* Hamburger: bigger tap target, visible & legible on light + dark heroes */
  .nav-toggle {
    display: inline-flex !important;
    align-items: center; justify-content: center;
    width: 44px; height: 44px;
    font-size: 1.3rem;
    background: rgba(251, 247, 236, 0.85);
    border: 1px solid rgba(64, 60, 45, 0.15);
    border-radius: 12px;
    backdrop-filter: blur(8px);
    color: var(--earth-bark);
  }

  .nav {
    width: 86vw;
    padding: 90px 24px 40px !important;
    gap: 2px !important;
  }
  .nav-link, .dropdown a {
    padding: 16px 14px !important;
    font-size: 1.05rem !important;
    border-bottom: 1px solid rgba(64,60,45,0.08);
  }
  .nav-cta { margin-top: 20px !important; width: 100%; justify-content: center; }

  /* ---------- Buttons: full-width, 48px min tap ---------- */
  .btn {
    padding: 16px 26px;
    font-size: 0.9rem;
    min-height: 48px;
  }
  .hero-cta-row .btn { width: 100%; justify-content: center; }
  .hero-cta-row { flex-direction: column; gap: 12px; }

  /* ---------- HERO ---------- */
  .hero {
    min-height: auto !important;
    padding: 110px 0 70px !important;
    text-align: center;
  }
  .hero-inner {
    grid-template-columns: 1fr !important;
    gap: 36px !important;
    padding: 0 20px !important;
  }
  .hero h1 { font-size: clamp(2.4rem, 10vw, 3rem) !important; }
  .hero-lede { font-size: 1.05rem !important; margin: 0 auto 18px !important; max-width: none !important; }
  .hero-sub { font-size: 0.98rem; margin: 0 auto 28px; max-width: none; }
  .hero-visual { max-width: 280px; margin: 0 auto; }
  .hero-quote-pill { display: none; }
  .locations {
    flex-direction: column;
    gap: 16px;
    align-items: center;
    text-align: center;
  }
  .scroll-hint { display: none; }

  /* ---------- Trust marquee: slow + smaller ---------- */
  .trust-strip { padding: 22px 0; }
  .trust-track { font-size: 1.05rem; gap: 40px; }

  /* ---------- About preview ---------- */
  .about-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }
  .about-portrait { max-width: 320px !important; margin: 0 auto !important; }

  /* ---------- Cards: stack, consistent radius ---------- */
  .services-grid,
  .specs-grid,
  .testimonial-grid,
  .blog-preview-grid,
  .rates-grid,
  .values-grid,
  .includes-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  .service-card { padding: 34px 24px; }
  .spec-card { padding: 24px 18px; }
  .testimonial { padding: 28px 24px; }

  .blog-preview-grid .big { grid-row: auto !important; }
  .blog-preview-grid .small {
    grid-template-columns: 90px 1fr;
    padding: 10px;
  }

  /* ---------- Process ---------- */
  .process-step {
    grid-template-columns: 64px 1fr !important;
    gap: 18px !important;
    padding: 26px 0 !important;
  }
  .process-step .step-num { font-size: 2.4rem !important; }
  .process-step .step-time {
    grid-column: 2 !important;
    margin-top: 6px !important;
    font-size: 0.72rem;
  }
  .process-step:hover { padding-left: 0 !important; }

  /* ---------- Section heads ---------- */
  .section-head { margin-bottom: 36px; }
  .section-head p { font-size: 0.98rem; }

  /* ---------- Blog page ---------- */
  .blog-hero { padding: 130px 0 50px; }
  .blog-filters { gap: 6px; padding: 0 4px; }
  .filter-pill {
    padding: 8px 14px;
    font-size: 0.72rem;
    letter-spacing: 0.1em;
  }
  .blog-search { margin-top: 24px; }
  .blog-search input { padding: 14px 18px 14px 42px; font-size: 0.95rem; }

  .blog-layout { grid-template-columns: 1fr !important; gap: 40px !important; }
  .masonry { column-count: 1 !important; column-gap: 0 !important; }
  .masonry > * { margin-bottom: 18px !important; }

  .post-card .body { padding: 22px 22px 24px; }
  .post-card h3 { font-size: 1.2rem !important; }
  .post-card.quote-card { padding: 30px 24px; }
  .post-card.quote-card blockquote { font-size: 1.2rem; }

  .blog-sidebar { gap: 20px !important; }
  .sidebar-widget { padding: 22px 20px; }

  .pagination { flex-wrap: wrap; gap: 6px; margin-top: 40px; }
  .pagination button, .pagination a { width: 44px; height: 44px; }
  .pagination .arrow { padding: 0 18px; }

  /* ---------- Services / Specialties pages ---------- */
  .service-inner,
  .spec-inner,
  .about-hero-inner,
  .bio-grid,
  .contact-grid {
    grid-template-columns: 1fr !important;
    gap: 40px !important;
  }
  .service-inner.reverse .svc-copy { order: 0 !important; }
  .svc-visual { max-width: 380px; margin: 0 auto; }
  .bio-side { position: static !important; }

  .specs-nav { padding: 14px 0; }
  .specs-nav-inner { gap: 6px; padding: 0 12px; }
  .specs-nav a { padding: 8px 14px; font-size: 0.72rem; }

  .spec-number { font-size: 3.8rem !important; margin-bottom: 4px; }
  .spec-detail .lede { font-size: 1.15rem; }

  /* ---------- Rates ---------- */
  .rate-card { padding: 32px 26px; }
  .rate-price { font-size: 2.8rem; }
  .ins-logo { width: 150px; height: 90px; margin: 0 8px; padding: 12px 16px; }

  .insurance-list { padding: 28px 22px; margin-top: 50px; }
  .insurance-list ul { grid-template-columns: 1fr !important; gap: 4px 0; }
  .verify-note { padding: 22px 22px; margin-top: 40px; }

  /* ---------- FAQ ---------- */
  .faq-section { padding: 70px 0 !important; }
  .faq-q { font-size: 1.1rem; }
  .faq-a { font-size: 0.98rem; }

  /* ---------- Contact form ---------- */
  .contact-form { padding: 30px 22px; }
  .field-row { grid-template-columns: 1fr !important; }
  .field input, .field textarea, .field select {
    font-size: 16px; /* prevents iOS zoom */
    padding: 14px 16px;
  }

  /* ---------- Final CTA ---------- */
  .final-cta { padding: 80px 0 !important; }
  .final-cta .final-capy { display: none; }
  .final-cta h2 { font-size: 2rem !important; }

  /* ---------- Newsletter ---------- */
  .newsletter-block { padding: 70px 0; }
  .newsletter-form { flex-direction: column; gap: 10px; }
  .newsletter-form input { min-width: 0; width: 100%; }
  .newsletter-form .btn { width: 100%; justify-content: center; }

  /* ---------- Footer ---------- */
  .site-footer { padding: 60px 0 24px; }
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
    margin-bottom: 32px !important;
    text-align: left;
  }
  .footer-brand img { height: 80px !important; padding: 14px 18px !important; }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.78rem;
  }

  /* ---------- Tweaks panel: avoid blocking content on mobile ---------- */
  .tweaks-panel {
    right: 12px;
    left: 12px;
    bottom: 12px;
    width: auto;
    max-height: 70vh;
    overflow-y: auto;
  }
}

/* Tablet polish (721 – 1000) */
@media (min-width: 721px) and (max-width: 1000px) {
  .services-grid,
  .specs-grid,
  .testimonial-grid,
  .rates-grid,
  .values-grid,
  .includes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .masonry { column-count: 2; }
  .blog-layout { grid-template-columns: 1fr; }
}


/* ==========================================================
   RESPONSIVE HARDENING (appended last — wins the cascade)

   Breakpoints:
     Desktop:  ≥ 1200px   (baseline styles.css)
     Tablet:   768–1199px
     Mobile:   < 768px

   These overrides force row-layouts to stack vertically, prevent
   text overlap, enforce spacing, and keep the hero/header/CTA
   areas readable at every width. !important is applied ONLY to
   layout primitives (display/flex/width/position) that plugins
   or page-builders commonly override.
   ========================================================== */

/* ----------------------------------------------------------
   Global safety (all screens) — no element should overflow.
   ---------------------------------------------------------- */
html, body { overflow-x: hidden; }
body, p, h1, h2, h3, h4, h5, h6, li, a, span, div {
  overflow-wrap: break-word;
  word-wrap: break-word;
}
img, video, iframe { max-width: 100%; height: auto; }

/* ==========================================================
   TABLET (768px – 1199px)
   ========================================================== */
@media (min-width: 768px) and (max-width: 1199px) {
  html { font-size: 15.5px; }

  /* Container sizing */
  .container,
  .container-wide,
  .container-narrow { padding-left: 32px; padding-right: 32px; }

  /* Header info strip: stays on one row but tighter */
  .header-info-inner {
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 10px 18px !important;
    padding: 12px 24px !important;
    row-gap: 8px !important;
  }
  .hi-item { font-size: 0.8rem; line-height: 1.3; }

  /* Two-column content grids collapse at tablet */
  .hero-inner,
  .about-grid,
  .bio-grid,
  .contact-grid,
  .service-inner,
  .spec-inner,
  .about-hero-inner {
    grid-template-columns: 1fr !important;
    gap: 48px !important;
  }
  .services-grid,
  .specs-grid,
  .testimonial-grid,
  .rates-grid,
  .values-grid,
  .includes-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px !important;
  }
  .blog-layout { grid-template-columns: 1fr !important; gap: 50px !important; }
  .masonry { column-count: 2 !important; }

  .footer-grid { grid-template-columns: 1fr 1fr !important; gap: 40px !important; }

  /* Typography */
  h1 { font-size: clamp(2.2rem, 5vw, 3.4rem) !important; line-height: 1.12 !important; }
  h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem) !important; line-height: 1.18 !important; }
}

/* ==========================================================
   MOBILE (< 768px)
   ========================================================== */
@media (max-width: 767px) {

  /* ---------- Base rhythm ---------- */
  html { font-size: 15px; }
  body {
    font-size: 16px !important;
    line-height: 1.65 !important;
  }
  p { line-height: 1.7 !important; margin-bottom: 1em; }

  h1, h2, h3, h4 {
    line-height: 1.2 !important;
    word-break: break-word;
    hyphens: auto;
  }
  h1 { font-size: clamp(1.85rem, 8vw, 2.4rem) !important; letter-spacing: -0.01em !important; }
  h2 { font-size: clamp(1.55rem, 6.5vw, 2rem) !important; }
  h3 { font-size: 1.2rem !important; line-height: 1.3 !important; }

  /* ---------- Container padding ---------- */
  .container,
  .container-wide,
  .container-narrow {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  /* ---------- Page bottom padding so any fixed widgets
       (accessibility, chat, "Call me/Contact" overlays from
       plugins) don't cover footer/CTA content ---------- */
  body { padding-bottom: 90px; }
  body.has-floating-cta { padding-bottom: 130px; }

  /* ---------- HEADER INFO STRIP — stack vertically,
       no overlap, icons aligned with text ---------- */
  .header-info {
    padding: 8px 0 !important;
  }
  .header-info-inner {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    padding: 12px 20px !important;
    text-align: center !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .header-info-inner .hi-sep { display: none !important; }
  .header-info-inner .hi-item {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    font-size: 0.82rem !important;
    line-height: 1.35 !important;
    padding: 2px 0 !important;
    margin: 0 !important;
    white-space: normal !important;
    flex-wrap: wrap !important;
  }
  .header-info-inner .hi-icon {
    flex-shrink: 0 !important;
    width: 14px !important;
    height: 14px !important;
  }
  .header-info-inner .hi-item > span:not(.hi-icon):not(.status-pill):not(.status-dot):not(.status-text) {
    flex: 0 1 auto !important;
    min-width: 0 !important;
  }
  .status-pill {
    margin-left: 6px !important;
    flex-shrink: 0 !important;
  }

  /* Hide header info strip when scrolled to save room */
  .site-header.scrolled .header-info { display: none !important; }

  /* ---------- Section padding ---------- */
  section { padding: 56px 0 !important; }

  /* ---------- Force ANY horizontal row → vertical stack ---------- */
  .hero-inner,
  .about-grid,
  .bio-grid,
  .contact-grid,
  .service-inner,
  .spec-inner,
  .about-hero-inner,
  .services-grid,
  .specs-grid,
  .testimonial-grid,
  .blog-preview-grid,
  .rates-grid,
  .values-grid,
  .includes-grid,
  .blog-layout,
  .footer-grid,
  .locations,
  .insurance-list ul,
  .field-row {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 24px !important;
    width: 100% !important;
  }

  .masonry {
    column-count: 1 !important;
    column-gap: 0 !important;
  }

  /* Any generic flex row that should collapse */
  .hero-cta-row,
  .newsletter-form,
  .footer-bottom {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
    width: 100% !important;
  }

  /* ---------- Buttons: full-width, 48px tap target ---------- */
  .hero-cta-row .btn,
  .newsletter-form .btn {
    width: 100% !important;
    justify-content: center !important;
  }
  .btn {
    min-height: 48px;
    padding: 14px 24px;
    font-size: 0.9rem;
    white-space: normal;
    text-align: center;
  }

  /* ---------- HERO content on mobile ---------- */
  .hero { text-align: center; padding: 110px 0 60px !important; }
  .hero h1, .hero-lede, .hero-sub { max-width: 100% !important; margin-left: auto !important; margin-right: auto !important; }
  .hero-visual { max-width: 280px !important; margin: 0 auto !important; }
  .hero-quote-pill { display: none !important; }

  /* ---------- Cards spacing ---------- */
  .service-card,
  .spec-card,
  .rate-card,
  .testimonial,
  .post-card,
  .sidebar-widget,
  .contact-form {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  /* ---------- Form fields: prevent iOS zoom + overlap ---------- */
  .field input, .field textarea, .field select,
  input[type="text"], input[type="email"], input[type="search"],
  input[type="tel"], input[type="url"], textarea, select {
    font-size: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* ---------- Footer ---------- */
  .footer-grid { text-align: left !important; gap: 32px !important; }
  .footer-bottom { align-items: flex-start !important; }

  /* ---------- Defensive: kill any absolute positioning that
       could land on top of content ---------- */
  .hero .scroll-hint,
  .final-capy,
  .bird-decor,
  .leaf-decor { display: none !important; }

  /* ---------- Tweaks panel (if present) ---------- */
  .tweaks-panel {
    left: 12px !important;
    right: 12px !important;
    bottom: 12px !important;
    width: auto !important;
    max-height: 60vh !important;
    overflow-y: auto !important;
  }
}

/* ==========================================================
   SMALL MOBILE (< 400px) — tiny phones, extra tightening
   ========================================================== */
@media (max-width: 399px) {
  .container,
  .container-wide,
  .container-narrow {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
  h1 { font-size: 1.7rem !important; }
  h2 { font-size: 1.4rem !important; }
  .btn { padding: 12px 20px; font-size: 0.85rem; }
  .header-info-inner .hi-item { font-size: 0.78rem !important; }
}
