/* ============================================
   CRITICAL MOBILE FIXES
   Additional layer to ensure perfect mobile display
   ============================================ */

/* Prevent horizontal scroll at all costs */
html {
  width: 100%;
  scroll-behavior: smooth;
  /* NO position:relative - it breaks sticky! */
  /* NO overflow-x here either - mixed with body's overflow-x: hidden
     it makes <html> its own scroll container and breaks sticky too! */
}

body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  /* NO position:relative - it breaks sticky! */
}

/* Ensure all major containers respect viewport */
/* NOTE: "nav" is intentionally excluded here. Giving a <nav> element
   overflow-x: hidden makes its overflow-y auto-compute to "auto" (per the
   CSS overflow spec), turning it into a clipping/scroll container. Since
   the header's dropdown submenu (.soft_8ef3) is a descendant of
   .center-896a (a <nav>), it was getting clipped and forced into a tiny
   internal scrollbar instead of opening naturally below the nav link. */
main,
section,
article,
footer {
  max-width: 100%;
  overflow-x: hidden;
}

/* Header must NOT have max-width restriction for sticky to work */
header.under_17bb {
  max-width: none !important;
}

/* Fix for any potential overflow elements */
/* NOTE: ".video_bottom_0454" is intentionally excluded here for the same reason as
   "nav" above — the header's <div class="container"> wraps the nav and
   must not clip the dropdown submenu with an auto-computed overflow-y.
   It's already width-capped via max-width in style.thick-9eec so it can't cause
   horizontal overflow anyway. */
.modal_22dc,
.yellow_1089,
.advanced-cb45,
.shade_3141,
.tiny-0515,
.tooltip-cool-584b,
.nav-north-cc1f,
.caption_3a62,
.active_center_5c2e,
.stale-fbba,
.paragraph_7768 {
  max-width: 100%;
  overflow-x: hidden;
}

/* Header mobile optimizations */
@media (max-width: 768px) {
  .summary-f028 {
    padding: 8px 0;
  }
  
  .nav-last-6ade img {
    height: 28px;
    width: auto;
  }
  
  .fluid-d2b6 {
    display: none !important;
  }
  
  .disabled_3d3d {
    padding: 6px 12px !important;
    font-size: 0.8125rem !important;
    white-space: nowrap;
  }
  
  .disabled_3d3d svg {
    width: 14px;
    height: 14px;
  }
  
  .photo-1588 {
    padding: 6px;
  }
  
  .fresh-a712 {
    width: 20px;
  }
}

/* Mobile-specific fixes (phones) */
@media (max-width: 768px) {
  /* Force single column layout */
  .advanced-cb45,
  .yellow_1089,
  .shade_3141,
  .tiny-0515,
  .lite_7ba9,
  .background_7607,
  .tertiary_4354,
  .dark-4899,
  .shade_205b,
  .glass-7cb5,
  .yellow_fc1b,
  .content_6818 {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
  }
  
  /* Ensure tables are scrollable */
  .menu-south-3d89,
  .module-aedd {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Fix any fixed-width elements */
  .block-d100,
  .modal-c79a,
  .slider-short-2ee8,
  .notice_fluid_a59f,
  .texture-stone-6f0b,
  .new_ddcd,
  .gas-18cc {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
  }
  
  /* Ensure images are responsive */
  img,
  svg,
  picture {
    max-width: 100% !important;
    height: auto !important;
  }
  
  /* Better padding for mobile */
  .main_west_3656,
  .description-soft-4ba9,
  .background-749e,
  .disabled_up_b60c,
  .aside-2af9 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Fix text overflow */
  h1, h2, h3, h4, h5, h6,
  p, span, a, li, td, th,
  .link-gold-c162,
  .cool-913c,
  .shade_f049,
  .black-c016 {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
  }
  
  /* Fix code blocks */
  pre,
  code,
  .upper_5595,
  .box_847a {
    overflow-x: auto !important;
    max-width: 100% !important;
    word-wrap: break-word !important;
  }
  
  /* Fix buttons */
  .container_e44b,
  .selected-96a0,
  .text-brown-1c88,
  .south-27ec {
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  /* Fix flex containers */
  .title_new_3dee,
  .element_1d6a,
  .hard_28c5,
  .component-95a3,
  .tall-3e61,
  .surface_tiny_322f {
    flex-wrap: wrap !important;
    width: 100% !important;
  }
}

/* Extra small screens (≤480px) */
@media (max-width: 480px) {
  /* Even more aggressive fixes */
  * {
    max-width: 100vw !important;
  }
  
  section,
  .main_west_3656,
  .description-soft-4ba9,
  .disabled_up_b60c {
    max-width: none !important;
  }
  
  .video_bottom_0454 {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  
  /* Reduce font sizes if needed */
  .link-gold-c162 {
    font-size: 1.5rem !important;
  }
  
  .cool-913c {
    font-size: 1.375rem !important;
  }
  
  /* Stack everything */
  .sort_5c83,
  .menu-1824 {
    flex-direction: column !important;
  }
  
  /* Smaller stat values */
  .shade_f049 {
    font-size: 2rem !important;
  }
  
  /* Ensure score circles fit */
  .green_f1de {
    width: 100px !important;
    height: 100px !important;
    font-size: 2.5rem !important;
  }
  
  .feature-1482 {
    width: 140px !important;
    height: 140px !important;
  }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .main_west_3656,
  .disabled_up_b60c {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
  }
}

/* iPhone X and notch devices */
@supports (padding: max(0px)) {
  body {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }
}

/* css-noise: 4c1b */
.widget-item-f0 {
  padding: 0.5rem;
  font-size: 13px;
  line-height: 1.0;
}
