/* ============================================================
   MOBILE RESPONSIVE ENHANCEMENTS - HAMBURGER MENU
   ============================================================ */

/* Logo Icon Styling */
.logo-icon {
  width: 40px !important;
  height: 40px !important;
  max-width: 40px !important;
  max-height: 40px !important;
  object-fit: contain;
  vertical-align: middle;
  margin-right: 12px;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.logo {
  display: flex;
  align-items: center;
  font-size: 24px;
  font-weight: 700;
  color: var(--theme-primary);
}

/* Mobile Menu Toggle Button (Hamburger) */
.mobile-menu-toggle {
  display: none; /* Hidden by default on desktop */
  background: transparent;
  border: 2px solid var(--theme-primary);
  color: var(--theme-primary);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  padding: 8px 16px;
  border-radius: 6px;
  line-height: 1;
  transition: all 0.2s;
}

.mobile-menu-toggle:hover {
  background: var(--theme-primary);
  color: white;
}

.mobile-menu-toggle:active {
  transform: scale(0.95);
}

/* Tablet and below (768px) */
@media (max-width: 768px) {
  /* Show hamburger menu button */
  .mobile-menu-toggle {
    display: block !important;
  }
  
  /* Hide navigation by default on mobile - MUST override main theme */
  nav ul {
    display: none !important;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--theme-card);
    padding: var(--spacing-md);
    border-radius: 0 0 8px 8px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    z-index: 1000;
  }
  
  /* Show navigation when menu is open */
  nav ul.mobile-menu-open {
    display: flex !important;
  }
  
  /* Navigation items styling */
  nav li {
    width: 100%;
    text-align: left;
  }
  
  nav a {
    display: block;
    font-size: 16px;
    padding: 12px 16px;
    border-radius: 4px;
    transition: background 0.2s;
  }
  
  nav a:hover {
    background: rgba(255, 255, 255, 0.05);
  }
  
  /* Header needs relative positioning for absolute menu */
  header {
    position: relative;
  }
  
  nav {
    position: relative;
  }
  
  /* Hero responsive */
  .hero h1 {
    font-size: 36px !important;
  }
  
  .hero .tagline {
    font-size: 20px !important;
  }
  
  .hero p {
    font-size: 16px !important;
  }
  
  .hero-ctas {
    flex-direction: column;
    width: 100%;
  }
  
  .hero-ctas .btn {
    width: 100%;
  }
  
  /* Feature grid - single column */
  .feature-grid {
    grid-template-columns: 1fr !important;
  }
  
  /* Stats grid - 2 columns */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  
  /* Comparison - stack vertically */
  .comparison {
    flex-direction: column !important;
  }
  
  .comparison-box {
    max-width: 100% !important;
  }
  
  /* Tables - horizontal scroll */
  .demo-table {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .demo-table table {
    min-width: 600px;
  }
  
  /* Section padding */
  section {
    padding: 48px 0 !important;
  }
}

/* Mobile phones (480px and below) */
@media (max-width: 480px) {
  /* Reduce spacing */
  .wrap {
    padding: 0 16px !important;
  }
  
  /* Header compact */
  header {
    padding: 16px 0 !important;
  }
  
  .logo {
    font-size: 20px !important;
  }
  
  /* Hero mobile */
  .hero {
    padding: 32px 0 !important;
  }
  
  .hero h1 {
    font-size: 28px !important;
    line-height: 1.2 !important;
  }
  
  .hero .tagline {
    font-size: 18px !important;
  }
  
  .hero p {
    font-size: 15px !important;
  }
  
  /* Buttons full width */
  .btn {
    width: 100%;
    display: block;
    text-align: center;
    padding: 16px !important;
    font-size: 16px !important;
  }
  
  /* Feature cards */
  .feature-card {
    padding: 24px !important;
  }
  
  .feature-card h3 {
    font-size: 24px !important;
  }
  
  .feature-card h4 {
    font-size: 16px !important;
  }
  
  /* Stats - single column */
  .stats-grid {
    grid-template-columns: 1fr !important;
  }
  
  .stat-card {
    padding: 20px !important;
  }
  
  /* Section headers */
  .section-header h2 {
    font-size: 24px !important;
  }
  
  .section-header p {
    font-size: 16px !important;
  }
  
  /* Comparison boxes */
  .comparison-box {
    padding: 20px !important;
  }
  
  .comparison-box h4 {
    font-size: 18px !important;
  }
  
  .comparison-box ul {
    font-size: 14px !important;
  }
  
  .comparison-box li {
    margin-bottom: var(--spacing-sm) !important;
  }
  
  /* Tables */
  .demo-table table {
    font-size: 13px !important;
  }
  
  .demo-table th,
  .demo-table td {
    padding: 10px 8px !important;
  }
  
  /* Callout sections */
  .callout {
    padding: 32px 0 !important;
  }
  
  .callout h3 {
    font-size: 22px !important;
  }
  
  .callout p {
    font-size: 16px !important;
  }
  
  /* Footer */
  footer {
    padding: 32px 0 !important;
    font-size: 14px !important;
  }
  
  /* Trust badges */
  .trust-badge {
    flex-direction: column;
    gap: var(--spacing-sm);
  }
  
  .trust-item {
    text-align: center;
    font-size: 13px !important;
    padding: 10px 16px !important;
  }
  
  /* Section padding reduced */
  section {
    padding: 32px 0 !important;
  }
}

/* Very small screens (360px) */
@media (max-width: 360px) {
  .hero h1 {
    font-size: 24px !important;
  }
  
  .hero .tagline {
    font-size: 16px !important;
  }
  
  .section-header h2 {
    font-size: 20px !important;
  }
  
  .btn {
    font-size: 14px !important;
    padding: 14px !important;
  }
  
  .feature-card h3 {
    font-size: 20px !important;
  }
  
  .demo-table table {
    font-size: 12px !important;
  }
  
  .demo-table th,
  .demo-table td {
    padding: 8px 6px !important;
  }
}

/* Landscape mobile optimization */
@media (max-height: 600px) and (orientation: landscape) {
  .hero {
    padding: 24px 0 !important;
  }
  
  .hero h1 {
    font-size: 24px !important;
    margin-bottom: 8px !important;
  }
  
  .hero .tagline {
    font-size: 16px !important;
    margin-bottom: 8px !important;
  }
  
  .hero p {
    font-size: 14px !important;
    margin-bottom: 16px !important;
  }
  
  .hero-ctas {
    gap: 8px !important;
  }
  
  section {
    padding: 24px 0 !important;
  }
}
