/* ============================================================
   responsive.css
   All media-query overrides for the site, consolidated in one
   place. Uses the BEM class names from each component file.

   Breakpoints (mobile-first in spirit, desktop-first in order):
     1024px — compact desktop / small laptop
      900px — tablet landscape
      768px — tablet portrait; hamburger nav activates
      600px — mobile; all grids collapse to single column
      480px — small phone; typography and padding adjustments
   ============================================================ */


/* ============================================================
   1024px — compact desktop / small laptop
   Reduce horizontal padding on wide sections.
   ============================================================ */
@media (max-width: 1024px) {

  .product-section   { padding: 48px 32px; }
  .vertical-hero     { padding: 56px 32px 44px; }
  .feature-section   { padding-left: 32px; padding-right: 32px; }
  .outcomes-section  { padding-left: 32px; padding-right: 32px; }
  .about-profile     { padding-left: 32px; padding-right: 32px; }
  .deployment-section { padding-left: 32px; padding-right: 32px; }
  .industries-section { padding-left: 32px; padding-right: 32px; }
  .trusted-section   { padding-left: 32px; padding-right: 32px; }
  .product-detail-hero { padding-left: 32px; padding-right: 32px; }
  .product-detail-body { padding-left: 32px; padding-right: 32px; }
}


/* ============================================================
   900px — tablet landscape
   Two-column grids, single-column heroes, reduced padding.
   ============================================================ */
@media (max-width: 900px) {

  /* --- Navigation --- */
  nav { padding: 0 24px; }

  /* --- Home hero --- */
  .hero { padding: 80px 24px 64px; min-height: 460px; }

  /* --- All other page heroes: consistent height at tablet --- */
  .vertical-hero      { min-height: 460px; }
  .about-hero         { min-height: 460px; }
  .blog-hero          { min-height: 400px; } /* filters add ~50px so total ≈ 450px */
  .cs-hero            { min-height: 460px; }
  .pt-hero            { min-height: 460px; }
  .product-detail-hero { min-height: 460px; }
  .jobs-hero          { min-height: 460px; }

  /* --- Feature grid: stack text + stats --- */
  .feature-grid { grid-template-columns: 1fr; }

  /* --- About hero and profile --- */
  .about-hero__inner       { grid-template-columns: 1fr; }
  .about-capability-grid   { grid-template-columns: 1fr; }
  .about-facts-grid        { grid-template-columns: 1fr 1fr; }

  /* --- Grids from 3-col → 2-col --- */
  .verticals-grid  { grid-template-columns: 1fr 1fr; }
  .industries-grid { grid-template-columns: 1fr 1fr; }
  .product-grid    { grid-template-columns: 1fr 1fr; }
  .product-grid--two-col { grid-template-columns: 1fr 1fr; }
  .outcomes-grid   { grid-template-columns: 1fr 1fr; }
  .deployment-grid { grid-template-columns: 1fr 1fr; }

  /* --- Footer grid: 4-col → 2-col --- */
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  footer { padding: 32px 24px; }

  /* --- Section padding --- */
  .vertical-hero    { padding-left: 24px; padding-right: 24px; }
  .product-section  { padding-left: 24px; padding-right: 24px; }
  .feature-section  { padding-left: 24px; padding-right: 24px; }
  .trusted-section  { padding-left: 24px; padding-right: 24px; }
  .industries-section { padding-left: 24px; padding-right: 24px; }
  .about-profile    { padding-left: 24px; padding-right: 24px; }
  .deployment-section { padding-left: 24px; padding-right: 24px; }
  .outcomes-section { padding-left: 24px; padding-right: 24px; }

  /* --- Contact section form stacks --- */
  .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .form-row     { grid-template-columns: 1fr; }

  /* --- Product detail pages --- */
  .product-detail-hero__grid { grid-template-columns: 1fr; }
  .product-overview          { grid-template-columns: 1fr; }
  .product-deliverables-grid { grid-template-columns: 1fr; }
  .product-detail-hero { padding-left: 24px; padding-right: 24px; }
  .product-detail-body { padding-left: 24px; padding-right: 24px; }

  /* --- Blog page --- */
  .blog-featured { grid-template-columns: 1fr; }
  .blog-featured__image-link img { height: 240px; }
  .blog-grid, .press-grid { grid-template-columns: 1fr 1fr; }
  .blog-hero, .blog-body, .blog-filters { padding-left: 24px; padding-right: 24px; }
  .newsletter-strip { padding: 24px; }
  .newsletter-form  { width: 100%; }
  .newsletter-form input { flex: 1; width: auto; }
}


/* ============================================================
   768px — tablet portrait / hamburger nav
   Mobile navigation activates; hero actions stack; font reductions.
   ============================================================ */
@media (max-width: 768px) {

  /* --- Navigation: show hamburger, hide link row --- */
  .nav-hamburger { display: flex; }

  /* Give the hamburger a subtle dark pill so it reads on any background
     (transparent nav over light sections like the Careers body would hide it) */
  .nav-hamburger {
    background: rgba(10, 22, 40, 0.45);
    border-radius: 6px;
    padding: 8px;
  }

.nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background: var(--navy);
    flex-direction: column;
    align-items: stretch;
    padding: 20px 24px 32px;
    gap: 4px;
    box-sizing: border-box;
    z-index: 199;
  }
  .nav-links.nav--open { display: flex; }

  .mobile-nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 20px;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.10);
    flex-shrink: 0;
  }
  .mobile-nav-logo {
    cursor: pointer;
    display: flex;
    align-items: center;
  }
  .mobile-nav-logo img { height: 40px; display: block; }
  .mobile-nav-close {
    background: none;
    border: none;
    color: var(--od);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.75;
    transition: background 0.15s, opacity 0.15s;
  }
  .mobile-nav-close:hover { background: rgba(255,255,255,0.10); opacity: 1; }

  .nav-link    { text-align: left; padding: 14px 14px; font-size: 17px; }
  .nav-btn-cta { margin-left: 0; width: 100%; margin-top: auto; padding: 14px 20px; text-align: center; font-size: 16px; }

  /* Dropdown: expand inline in mobile nav instead of absolute */
  .nav-dropdown { width: 100%; }
  .nav-dropdown::after { display: none; }
  .nav-dropdown-menu {
    position: static;
    display: flex;
    flex-direction: column;
    box-shadow: none;
    border: none;
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.04);
    border-radius: 0;
    margin: 0;
    padding: 6px 0;
  }
  .nav-dropdown-menu button {
    font-size: 15px;
    padding: 11px 14px;
    border-radius: 6px;
    margin: 0 8px;
    width: calc(100% - 16px);
  }
  /* On mobile the About trigger becomes a non-interactive section label;
     the sub-items (including "About alwaysAI") handle navigation */
  .nav-dropdown > .nav-link {
    pointer-events: none;
    opacity: 0.45;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 16px 14px 8px;
  }
  /* Suppress the active-page highlight on the section label — it is not a
     navigable item so it should never look selected */
  .nav-dropdown > .nav-link.active {
    background: none;
    opacity: 0.45;
  }
  .nav-dropdown > .nav-link i { display: none; }

  /* --- Hero --- */
  .hero h1       { font-size: 42px; }
  .hero-subtitle { font-size: 16px; }

  /* --- Hero CTA buttons: stack vertically on mobile --- */
  .hero-actions { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hero-actions .btn-primary,
  .hero-actions .btn-outline { width: 100%; max-width: 320px; text-align: center; justify-content: center; }

  /* --- Vertical hero headline --- */
  .vertical-hero h1 { font-size: 38px; }

  /* --- Section headings --- */
  .product-section h2   { font-size: 26px; }
  .outcomes-section h2  { font-size: 26px; }
  .deployment-section h2 { font-size: 26px; }

  /* --- Footer bottom: centre-align on smaller screens --- */
  .footer-bottom__inner { flex-direction: column; align-items: center; gap: 6px; text-align: center; }
  .footer-bottom { padding: 14px 24px; }

  /* --- Blog filters: allow wrapping --- */
  .blog-filters__inner { flex-wrap: wrap; }
}


/* ============================================================
   600px — mobile
   All multi-column grids collapse to a single column.
   ============================================================ */
@media (max-width: 600px) {

  /* --- Home hero --- */
  .hero h1  { font-size: 34px; }
  .hero     { padding: 96px 20px 48px; min-height: 420px; }

  /* --- All other page heroes: consistent height at mobile --- */
  .vertical-hero      { min-height: 420px; }
  .about-hero         { min-height: 420px; }
  .blog-hero          { min-height: 360px; } /* filters add ~50px so total ≈ 410px */
  .cs-hero            { min-height: 420px; }
  .pt-hero            { min-height: 420px; }
  .product-detail-hero { min-height: 420px; }
  .jobs-hero          { min-height: 420px; }

  /* --- Vertical hero --- */
  .vertical-hero h1          { font-size: 30px; }
  .vertical-hero__subtitle   { font-size: 15px; }
  .vertical-hero             { padding: 96px 20px 40px; }

  /* --- All grids → single column --- */
  .verticals-grid        { grid-template-columns: 1fr; }
  .industries-grid       { grid-template-columns: 1fr; }
  .product-grid          { grid-template-columns: 1fr; }
  .product-grid--two-col { grid-template-columns: 1fr; }
  .outcomes-grid         { grid-template-columns: 1fr; }
  .deployment-grid       { grid-template-columns: 1fr; }
  .tab-panel--active     { grid-template-columns: 1fr; }

  /* --- Footer → single column --- */
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  footer       { padding: 28px 20px; }
  .footer-bottom { padding: 14px 20px; }

  /* --- Section padding --- */
  .product-section    { padding: 40px 20px; }
  .feature-section    { padding-left: 20px; padding-right: 20px; }
  .trusted-section    { padding-left: 20px; padding-right: 20px; }
  .industries-section { padding-left: 20px; padding-right: 20px; }
  .outcomes-section   { padding-left: 20px; padding-right: 20px; }
  .about-profile      { padding-left: 20px; padding-right: 20px; }
  .about-capability-grid { grid-template-columns: 1fr; }
  .about-facts-grid      { grid-template-columns: 1fr; }
  .deployment-section { padding-left: 20px; padding-right: 20px; }
  .product-detail-hero { padding-left: 20px; padding-right: 20px; }
  .product-detail-body { padding-left: 20px; padding-right: 20px; }
  .blog-hero, .blog-body, .blog-filters { padding-left: 20px; padding-right: 20px; }

  /* --- Blog --- */
  .blog-grid, .press-grid { grid-template-columns: 1fr; }
  .blog-hero h1           { font-size: 28px; }

  /* --- Newsletter strip: stack icon / text / form vertically --- */
  .newsletter-strip { flex-direction: column; gap: 16px; padding: 24px 20px; }
  .newsletter-form  { flex-direction: column; width: 100%; }
  .newsletter-form input     { width: 100%; }
  .newsletter-form .btn-primary { width: 100%; }
}


/* ============================================================
   480px — small phone
   Final typography and layout tweaks for narrow viewports.
   ============================================================ */
@media (max-width: 480px) {

  /* --- Hero headline --- */
  .hero h1 { font-size: 30px; letter-spacing: -0.8px; }
  .hero-actions .btn-primary,
  .hero-actions .btn-outline { max-width: 100%; }

  /* --- Vertical hero --- */
  .vertical-hero h1 { font-size: 26px; }

  /* --- Stats panel: two stat cards stack --- */
  .stats-row { grid-template-columns: 1fr; }

  /* --- Outcome values: reduce font size --- */
  .outcome-value { font-size: 38px; }

  /* --- Tab group: compact buttons --- */
  .tab-button { font-size: 13px; padding: 6px 11px; }

  /* --- Blog hero --- */
  .blog-hero h1 { font-size: 28px; }
  .blog-hero    { min-height: 320px; }

  /* --- Other page heroes --- */
  .vertical-hero       { min-height: 380px; }
  .about-hero          { min-height: 380px; }
  .cs-hero             { min-height: 380px; }
  .pt-hero             { min-height: 380px; }
  .product-detail-hero { min-height: 380px; }
  .jobs-hero           { min-height: 380px; }

  /* --- Product detail hero --- */
  .product-detail-hero h1 { font-size: 30px; }

  /* --- Case studies / Partners hero --- */
  .cs-hero-in h1 { font-size: 34px; }
  .pt-hero-in h1 { font-size: 34px; }

  /* --- Partners become-a-partner strip: stack vertically --- */
  .pt-become { flex-direction: column; align-items: flex-start; gap: 24px; }
}
