/* Complete Mobile Responsive Fix - All Device Types */

/* Base overflow prevention */
html, body {
  overflow-x: hidden !important;
  max-width: 100vw !important;
}

* {
  box-sizing: border-box !important;
}

/* Large Mobile (414px - 768px) */
@media (max-width: 768px) and (min-width: 415px) {
  .new-responsive-header { height: 65px !important; }
  .new-logo img { height: 50px !important; }
  .new-nav { top: 65px !important; }
  .hero_content h1 { font-size: 2rem !important; }
  .container-large { padding: 0 1.5rem !important; }
  .services-grid-new { grid-template-columns: 1fr !important; }
  .four_column_grid { grid-template-columns: repeat(2, 1fr) !important; }
}

/* Standard Mobile (375px - 414px) */
@media (max-width: 414px) and (min-width: 376px) {
  .new-responsive-header { height: 60px !important; }
  .new-logo img { height: 45px !important; }
  .new-nav { top: 60px !important; }
  .hero_content h1 { font-size: 1.8rem !important; }
  .container-large { padding: 0 1rem !important; }
  .four_column_grid { grid-template-columns: repeat(2, 1fr) !important; }
}

/* Small Mobile (320px - 375px) */
@media (max-width: 375px) and (min-width: 321px) {
  .new-responsive-header { height: 55px !important; }
  .new-logo img { height: 40px !important; }
  .new-nav { top: 55px !important; }
  .hero_content h1 { font-size: 1.6rem !important; }
  .container-large { padding: 0 0.75rem !important; }
  .four_column_grid { grid-template-columns: 1fr !important; }
  .counter-grid { grid-template-columns: 1fr !important; }
}

/* Extra Small Mobile (280px - 320px) */
@media (max-width: 320px) {
  .new-responsive-header { height: 50px !important; }
  .new-logo img { height: 35px !important; }
  .new-nav { top: 50px !important; }
  .hero_content h1 { font-size: 1.4rem !important; }
  .container-large { padding: 0 0.5rem !important; }
  .four_column_grid { grid-template-columns: 1fr !important; }
  .counter-grid { grid-template-columns: 1fr !important; }
  .location-cards { grid-template-columns: 1fr !important; }
  .tech-stack-section > div > div > div:nth-child(3),
  .tech-stack-section > div > div > div:nth-child(4) { grid-template-columns: 1fr !important; }
}

/* Universal mobile fixes */
@media (max-width: 768px) {
  .new-header-container { justify-content: space-between !important; }
  .new-nav { display: none !important; }
  .new-nav.active { 
    display: flex !important;
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    background: white !important;
    flex-direction: column !important;
    padding: 1.5rem 1rem !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1) !important;
    z-index: 999 !important;
  }
  .new-hamburger { display: flex !important; }
  .services-grid-new { grid-template-columns: 1fr !important; }
  .businesses-grid-new { grid-template-columns: 1fr !important; }
  .who-we-are-section .container-large > div,
  .databricks-section .container-large > div { 
    grid-template-columns: 1fr !important;
    text-align: center !important;
  }
}