/* ============================================ */
/* MOBILE RESPONSIVE CSS - Simple & Clean      */
/* Works with mobile-responsive-loader.js      */
/* Applies only on screens 768px and below     */
/* ============================================ */

/* ====================== */
/* MOBILE (768px & below) */
/* ====================== */
@media only screen and (max-width: 768px) {
  
  /* Base Typography */
  html {
    font-size: 14px;
  }
  
  body {
    font-size: 0.9375rem;
    line-height: 1.6;
  }
  
  h1 { font-size: 2rem !important; line-height: 1.2; margin-bottom: 1rem; }
  h2 { font-size: 1.75rem !important; line-height: 1.3; margin-bottom: 0.875rem; }
  h3 { font-size: 1.5rem !important; line-height: 1.4; margin-bottom: 0.75rem; }
  h4 { font-size: 1.25rem !important; line-height: 1.4; margin-bottom: 0.625rem; }
  h5 { font-size: 1.125rem !important; line-height: 1.5; }
  h6 { font-size: 1rem !important; line-height: 1.5; }
  p { font-size: 0.9375rem; line-height: 1.6; margin-bottom: 1rem; }
  
  /* Container */
  .container-xl {
    padding: 0 1rem !important;
    max-width: 100% !important;
  }
  
  /* Header & Navigation */
  .header {
    padding: 0.75rem 0;
  }
  
  .nav-container {
    height: auto;
    min-height: 4rem;
    padding: 0.5rem 1rem;
  }
  
  .logo-img {
    max-width: 50% !important;
    height: auto;
  }
  
  .desktop-nav {
    display: none !important;
  }
  
  .mobile-menu-btn {
    display: flex !important;
  }
  
  .mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: hsl(var(--background));
    z-index: 100;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }
  
  .mobile-menu.active {
    transform: translateX(0);
  }

  /* Ensure mobile dropdown toggles are clickable */
  .mobile-dropdown-toggle,
  #mobileAboutToggle {
    pointer-events: auto !important;
    position: relative;
    z-index: 2;
  }

  /* Keep About dropdown visible when active */
  #mobileAboutDropdown.active {
    display: block !important;
    max-height: none !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
  
  /* Buttons */
  .btn {
    padding: 0.75rem 1.5rem !important;
    font-size: 0.9375rem !important;
    width: 100%;
    max-width: 100%;
    display: block;
    text-align: center;
  }
  
  .btn-hero,
  .btn-xl {
    padding: 0.875rem 1.5rem !important;
    font-size: 0.9375rem !important;
    height: auto !important;
    min-height: 2.75rem !important;
  }
  
  /* Schedule Demo Button */
  .demo-trigger,
  .btn.demo-trigger,
  .btn-hero.demo-trigger,
  .btn-xl.demo-trigger {
    padding: 0.75rem 1.25rem !important;
    font-size: 0.875rem !important;
    height: auto !important;
    min-height: 2.5rem !important;
    max-height: 2.75rem !important;
    width: auto !important;
    max-width: 90% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.5rem !important;
    white-space: nowrap !important;
    margin: 0 auto !important;
  }
  
  .demo-trigger svg,
  .btn.demo-trigger svg {
    width: 1rem !important;
    height: 1rem !important;
    flex-shrink: 0;
  }
  
  .hero-cta {
    display: flex !important;
    flex-direction: column !important;
    gap: 0.75rem !important;
    align-items: center !important;
    width: 100% !important;
  }
  
  .hero-cta .btn {
    width: auto !important;
    max-width: 90% !important;
    margin: 0 auto !important;
  }
  
  .btn-group {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .btn-group .btn {
    width: 100%;
  }
  
  /* Grid & Layout */
  .grid,
  [class*="grid-"],
  .footer-grid,
  .feature-grid,
  .card-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
  
  .grid-2,
  [class*="grid-cols-2"] {
    grid-template-columns: 1fr !important;
  }
  
  .grid-3,
  [class*="grid-cols-3"] {
    grid-template-columns: 1fr !important;
  }
  
  .grid-4,
  [class*="grid-cols-4"] {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 1rem !important;
  }
  
  .flex-row {
    flex-direction: column !important;
  }
  
  /* Cards */
  .card,
  .feature-card,
  .product-card {
    padding: 1.5rem !important;
    margin-bottom: 1.5rem;
  }
  
  .card h3,
  .feature-card h3 {
    font-size: 1.25rem !important;
  }
  
  /* Sections */
  section {
    padding: 3rem 0 !important;
  }
  
  .section-header {
    margin-bottom: 2rem;
    text-align: center;
  }
  
  .section-header h2 {
    font-size: 1.75rem !important;
  }
  
  .hero-section {
    padding: 4rem 0 3rem !important;
    text-align: center;
  }
  
  .hero-section h1 {
    font-size: 2.25rem !important;
    margin-bottom: 1rem;
  }
  
  .hero-section p {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }
  
  /* Images */
  img {
    max-width: 100% !important;
    height: auto;
  }
  
  .hero-image,
  .section-image {
    width: 100%;
    margin: 1.5rem 0;
  }
  
  /* Forms */
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="password"],
  textarea,
  select {
    width: 100% !important;
    padding: 0.875rem 1rem !important;
    font-size: 1rem !important;
  }
  
  .form-group {
    margin-bottom: 1.25rem;
  }
  
  .form-row {
    flex-direction: column;
    gap: 1rem;
  }
  
  /* Modal */
  .modal-content {
    width: 95% !important;
    max-width: 95% !important;
    margin: 1rem auto;
    max-height: 90vh;
    overflow-y: auto;
  }
  
  #demoModal > div {
    width: 95% !important;
    max-width: 95% !important;
    grid-template-columns: 1fr !important;
  }
  
  #demoModal .footer-contact,
  #demoModal .footer-info {
    padding: 2rem 1.5rem !important;
  }
  
  /* Footer */
  .footer-content {
    padding: 3rem 1rem 2rem !important;
  }
  
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
  
  .footer-column {
    text-align: center;
    margin-bottom: 1.5rem;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  
  /* Tables */
  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    width: 100%;
  }
  
  /* Utility Classes */
  .hide-mobile,
  .mobile-hidden {
    display: none !important;
  }
  
  .show-mobile,
  .mobile-only {
    display: block !important;
  }
  
  .text-left-mobile { text-align: left !important; }
  .text-center-mobile { text-align: center !important; }
  .text-right-mobile { text-align: right !important; }
  
  .mt-mobile-0 { margin-top: 0 !important; }
  .mb-mobile-0 { margin-bottom: 0 !important; }
  .p-mobile-1 { padding: 1rem !important; }
  .w-full-mobile { width: 100% !important; }
  
  /* Reduced Motion */
  @media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
    }
  }
}

/* ====================== */
/* SMALL MOBILE (480px & below) */
/* ====================== */
@media only screen and (max-width: 280px) {
  
  html {
    font-size: 13px;
  }
  
  h1 { font-size: 1.75rem !important; }
  h2 { font-size: 1.5rem !important; }
  
  .hero-section h1 {
    font-size: 1.875rem !important;
  }
  
  .btn {
    padding: 0.625rem 1.25rem !important;
    font-size: 0.875rem !important;
  }
  
  .demo-trigger,
  .btn.demo-trigger,
  .btn-hero.demo-trigger,
  .btn-xl.demo-trigger {
    padding: 0.625rem 1rem !important;
    font-size: 0.8125rem !important;
    min-height: 2.25rem !important;
    max-height: 2.5rem !important;
    max-width: 85% !important;
  }
  
  .demo-trigger svg,
  .btn.demo-trigger svg {
    width: 0.875rem !important;
    height: 0.875rem !important;
  }
  
  .hero-cta .btn {
    max-width: 85% !important;
  }
  
  section {
    padding: 2rem 0 !important;
  }
  
  .card,
  .feature-card {
    padding: 1.25rem !important;
  }
}

/* ====================== */
/* TABLET (769px - 1024px) */
/* ====================== */
@media only screen and (min-width: 769px) and (max-width: 1024px) {
  
  .grid-4,
  [class*="grid-cols-4"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  
  .grid-3,
  [class*="grid-cols-3"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  
  .btn {
    width: auto;
    max-width: none;
  }
}
