/* ============================================================
   BLACK BEAR AI — Responsive Overrides
   Breakpoints: 768px (tablet) · 480px (mobile) · 375px (small)
   Uses data-* attrs + class names to override inline styles.
   ============================================================ */

/* ── Nav desktop: esconde hamburger e menu mobile ─────────── */
/* Hamburger e menu mobile: ocultos no desktop */
@media (min-width: 769px) {
  .nav-hamburger   { display: none !important; }
  .nav-mobile-menu { display: none !important; }
}

/* ── Tablet (≤768px) ──────────────────────────────────────── */
@media (max-width: 768px) {

  /* Nav */
  .nav-desktop-links  { display: none !important; }
  .nav-desktop-cta    { display: none !important; }
  .nav-hamburger      { display: flex !important; align-items: center; justify-content: center; }

  /* Section padding */
  .bb-section         { padding: 72px 0 !important; }

  /* Inner containers padding */
  .bb-inner           { padding: 0 20px !important; }

  /* ── Grids ── */

  /* 4-col → 2-col */
  [data-grid="4col"]  { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="stats"] { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="kpi"]   { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="how"]   {
    grid-template-columns: repeat(2, 1fr) !important;
    row-gap: 40px !important;
  }
  [data-grid="logos"] { grid-template-columns: repeat(2, 1fr) !important; }

  /* 3-col → 2-col */
  [data-grid="3col"]  { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="ben"]   { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="cases"] { grid-template-columns: repeat(2, 1fr) !important; }

  /* LeadForm: 2-col → 1-col */
  [data-grid="lead"]  { grid-template-columns: 1fr !important; gap: 40px !important; }

  /* Footer: 4-col → 2-col */
  [data-grid="footer"] { grid-template-columns: 1fr 1fr !important; gap: 32px !important; }

  /* Partners card */
  [data-grid="partner-wrap"] { justify-content: stretch !important; }
  .partner-card { max-width: 100% !important; }

  /* HowItWorks: hide horizontal connecting line */
  [data-how-line] { display: none !important; }

  /* Stats strip borders */
  [data-grid="stats"] > div:nth-child(2n) { border-right: none !important; }
  [data-grid="stats"] > div:nth-child(3),
  [data-grid="stats"] > div:nth-child(4)  { border-top: 1px solid var(--border-subtle) !important; }

  /* LogoStrip border fixes */
  [data-grid="logos"] > div:nth-child(2n) { border-right: none !important; }
}

/* ── Mobile (≤480px) ──────────────────────────────────────── */
@media (max-width: 480px) {

  /* Section padding tighter */
  .bb-section         { padding: 56px 0 !important; }
  .bb-inner           { padding: 0 16px !important; }

  /* Hero sub font */
  .hero-sub           { font-size: 16px !important; max-width: 100% !important; }

  /* ALL grids → 1 column */
  [data-grid="3col"],
  [data-grid="cases"],
  [data-grid="ben"],
  [data-grid="how"]   { grid-template-columns: 1fr !important; }

  /* 4-col kpi stays 2-col on mobile (numbers still readable) */
  [data-grid="kpi"]   { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="stats"] { grid-template-columns: repeat(2, 1fr) !important; }
  [data-grid="logos"] { grid-template-columns: repeat(2, 1fr) !important; }

  /* Footer: single col */
  [data-grid="footer"] { grid-template-columns: 1fr !important; }

  /* Nav hamburger text size */
  .nav-hamburger { font-size: 22px !important; }

  /* FinalCTA card padding */
  [data-cta-card] { padding: 40px 22px !important; }

  /* Section titles clamp override */
  .bb-section-title { font-size: clamp(24px, 7vw, 34px) !important; }
  .bb-section-desc  { font-size: 14px !important; }
}

/* ── Small mobile (≤375px) ────────────────────────────────── */
@media (max-width: 375px) {
  .bb-inner { padding: 0 14px !important; }
  .bb-section { padding: 48px 0 !important; }

  [data-grid="kpi"]   { grid-template-columns: 1fr 1fr !important; }
  [data-grid="logos"] { grid-template-columns: repeat(2, 1fr) !important; }
}
