/* ============================================
   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 (.cold_11ab) is a descendant of
   .disabled-bronze-d75c (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.slow-88b9 {
  max-width: none !important;
}

/* Fix for any potential overflow elements */
/* NOTE: ".inner_e825" 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.hot_7d78 so it can't cause
   horizontal overflow anyway. */
.fixed-8dbd,
.cold_3f98,
.module-advanced-04ba,
.main_ddfc,
.tiny-b716,
.active-bd07,
.box_c917,
.list-copper-2f56,
.banner_soft_0b67,
.steel_164a,
.progress-purple-19de {
  max-width: 100%;
  overflow-x: hidden;
}

/* Header mobile optimizations */
@media (max-width: 768px) {
  .notice-7597 {
    padding: 8px 0;
  }
  
  .breadcrumb_6067 img {
    height: 28px;
    width: auto;
  }
  
  .panel_4619 {
    display: none !important;
  }
  
  .input_white_c288 {
    padding: 6px 12px !important;
    font-size: 0.8125rem !important;
    white-space: nowrap;
  }
  
  .input_white_c288 svg {
    width: 14px;
    height: 14px;
  }
  
  .pink_8bed {
    padding: 6px;
  }
  
  .accent-middle-dbc4 {
    width: 20px;
  }
}

/* Mobile-specific fixes (phones) */
@media (max-width: 768px) {
  /* Force single column layout */
  .module-advanced-04ba,
  .cold_3f98,
  .main_ddfc,
  .tiny-b716,
  .dynamic_a4d7,
  .label-motion-9971,
  .gallery-bfa6,
  .copper_fbfa,
  .image_south_ba28,
  .gallery-yellow-14e7,
  .layout_953d,
  .column_6c18 {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
  }
  
  /* Ensure tables are scrollable */
  .search_d8e7,
  .center-0a2b {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Fix any fixed-width elements */
  .image_large_f312,
  .chip-e883,
  .preview-solid-e61f,
  .hidden_fee7,
  .media_3944,
  .orange_39a6,
  .hard-67a7 {
    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 */
  .liquid_4749,
  .caption_clean_db13,
  .sidebar-stone-9665,
  .section-fc67,
  .rough_d36f {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Fix text overflow */
  h1, h2, h3, h4, h5, h6,
  p, span, a, li, td, th,
  .next-7afb,
  .notice-e0f6,
  .menu-plasma-42d5,
  .advanced-1b24 {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
  }
  
  /* Fix code blocks */
  pre,
  code,
  .up_3070,
  .upper-066b {
    overflow-x: auto !important;
    max-width: 100% !important;
    word-wrap: break-word !important;
  }
  
  /* Fix buttons */
  .wrapper-bee7,
  .link-44c1,
  .easy_ede5,
  .container-1ed0 {
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  /* Fix flex containers */
  .chip_ed36,
  .element_first_7454,
  .liquid_b001,
  .background-335a,
  .stone-7dc5,
  .dirty_cb72 {
    flex-wrap: wrap !important;
    width: 100% !important;
  }
}

/* Extra small screens (≤480px) */
@media (max-width: 480px) {
  /* Even more aggressive fixes */
  * {
    max-width: 100vw !important;
  }
  
  section,
  .liquid_4749,
  .caption_clean_db13,
  .section-fc67 {
    max-width: none !important;
  }
  
  .inner_e825 {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  
  /* Reduce font sizes if needed */
  .next-7afb {
    font-size: 1.5rem !important;
  }
  
  .notice-e0f6 {
    font-size: 1.375rem !important;
  }
  
  /* Stack everything */
  .card-1914,
  .video_copper_edab {
    flex-direction: column !important;
  }
  
  /* Smaller stat values */
  .menu-plasma-42d5 {
    font-size: 2rem !important;
  }
  
  /* Ensure score circles fit */
  .summary-9cfc {
    width: 100px !important;
    height: 100px !important;
    font-size: 2.5rem !important;
  }
  
  .layout-d74b {
    width: 140px !important;
    height: 140px !important;
  }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .liquid_4749,
  .section-fc67 {
    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: d6c5 */
.ghost-box-s0 {
  padding: 0.2rem;
  font-size: 13px;
  line-height: 1.2;
}
