/* ==========================================================================
   Aptus Solutions — responsive.css
   Desktop-first. 1600 → 1280 → 1024 → 768 → 480. Then motion preferences.
   ========================================================================== */

@media (max-width: 1600px) {
  .home-hero .hero-play { right: 18%; }
}

@media (max-width: 1280px) {
  .service-carousel { --cards: 3; }
  /* Nav collapses into the drawer (same <ul>, restyled in style.css) */
  .site-header .main-nav { display: none; }
  .nav-open .site-header .main-nav { display: flex; }
  .site-header .header-cta, .site-header .header-search { display: none; }
  .site-header .header-call { display: flex; }

  .home-hero .hero-play { right: 12%; }
  .industry-panels { height: 500px; }
}

@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
  .home-hero .hero-call, .home-hero .hero-play, .home-hero .hero-top { display: none; }
  .home-hero .corner-blocks .block-grey, .home-hero .corner-blocks .block-step { display: none; }

  .industry-panels { flex-direction: column; height: auto; }
  .industry-panel { flex: none; height: 76px; }
  .industry-panel.is-active { flex: none; height: 380px; }
  .industry-panel .panel-label { flex-direction: row; align-items: center; justify-content: flex-start; }
  .industry-panel .panel-name { writing-mode: horizontal-tb; transform: none; }
  .industry-panel .panel-detail { width: 100%; }

  .catalog-sidebar { position: static; max-width: none; flex-basis: 100%; }
  .category-nav { display: flex; flex-wrap: wrap; gap: 0 24px; }
  .category-nav a { flex: 1 1 260px; }

  .site-footer .footer-contact { grid-template-columns: 1fr; }
  .site-footer .footer-contact-item, .site-footer .footer-contact-item:first-child, .site-footer .footer-contact-item:last-child { padding-inline: 0; }
  .site-footer .footer-contact-item + .footer-contact-item { border-left: 0; border-top: 1px solid var(--line-on-dark); }
}

@media (max-width: 768px) {
  .service-carousel { --cards: 2; }
  :root { --rail: 0px; }
  .home-hero .hero-rail, .page-hero .rail-label, .corner-blocks { display: none; }
  .page-hero { height: auto; min-height: 340px; margin-bottom: 0; }
  .page-hero .hero-content { padding-block: 70px 110px; }
  .breadcrumb { height: 60px; }
  .home-hero { min-height: 600px; }
  .home-hero .hero-controls { height: 64px; padding-left: 12px; }

  .service-card { height: 400px; }
  .about-media .years-badge { width: 180px; min-height: 0; padding: 22px 22px 24px; }
  .about-media .years-badge strong { font-size: 36px; }

  .strength-item { margin-right: 0; padding-right: 0; border-right: 0; border-bottom: 1px solid var(--color-border); }
  .industry-list li { margin-right: 0; }

  .principal-trigger { grid-template-columns: 40px 1fr 44px; }
  .principal-item.is-open .principal-trigger { padding-left: 0; }
  .principal-panel .panel-content { padding: 0 0 28px; }

  .solution-row .solution-index { font-size: 72px; top: -32px; }
  .modal-dialog .modal-body { padding: 32px 24px; }
  .modal-dialog .modal-media { min-height: 240px; }
  .icon-list { grid-template-columns: 1fr; }

  .map-block { height: auto; display: flex; flex-direction: column-reverse; }
  .map-block iframe { position: static; height: 340px; }
  .map-block .map-card { position: static; transform: none; width: 100%; }

  .lightbox .lightbox-bar { flex-wrap: wrap; gap: 12px; }
  .lightbox .lightbox-caption { flex-basis: 100%; order: -1; }
}

@media (max-width: 480px) {
  .service-carousel { --cards: 1.15; }
  .product-grid { grid-template-columns: 1fr; }
  .btn-split span { padding: 0 18px; }
  .home-hero .hero-copy .btn-split { width: 100%; }
  .home-hero .hero-copy .btn-split span { flex: 1; }
  .section-actions .action-buttons, .section-actions .action-buttons a { width: 100%; }
  .section-actions .action-buttons .btn-split span { flex: 1; }
  .stat-row { grid-template-columns: 1fr; }
  .stat-row .stat-item { padding: 20px 0; }
  .stat-row .stat-item + .stat-item { border-left: 0; border-top: 1px solid var(--color-border); }
  .about-media { padding-bottom: 50px; }
  .apt-card { min-height: 280px; padding: 32px 26px; }
  .contact-card { min-height: 240px; padding: 28px 24px; }
  .site-footer .legal-links { margin-left: 0; }
  .site-footer .footer-bottom-inner { padding-right: var(--gutter); }
  .site-footer .back-to-top { margin-left: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .word-marquee .marquee-track, .logo-marquee .marquee-track { animation: none; }
  .logo-marquee { overflow-x: auto; }
}
