/* ============================================
   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 (.image_over_9f09) is a descendant of
   .slider_e888 (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.notification_6f8a {
  max-width: none !important;
}

/* Fix for any potential overflow elements */
/* NOTE: ".footer_mini_9bc2" 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-4e08 so it can't cause
   horizontal overflow anyway. */
.widget_cdd8,
.down_867f,
.aside-yellow-faf8,
.steel_3ded,
.article_b785,
.liquid_1b0f,
.soft_db54,
.layout_blue_5ce7,
.center-8c18,
.item_fresh_3b26,
.preview_middle_d10c {
  max-width: 100%;
  overflow-x: hidden;
}

/* Header mobile optimizations */
@media (max-width: 768px) {
  .video_1536 {
    padding: 8px 0;
  }
  
  .list-outer-e503 img {
    height: 28px;
    width: auto;
  }
  
  .notice-4f2e {
    display: none !important;
  }
  
  .simple_9c70 {
    padding: 6px 12px !important;
    font-size: 0.8125rem !important;
    white-space: nowrap;
  }
  
  .simple_9c70 svg {
    width: 14px;
    height: 14px;
  }
  
  .progress_f524 {
    padding: 6px;
  }
  
  .info-9514 {
    width: 20px;
  }
}

/* Mobile-specific fixes (phones) */
@media (max-width: 768px) {
  /* Force single column layout */
  .aside-yellow-faf8,
  .down_867f,
  .steel_3ded,
  .article_b785,
  .hidden-dark-a1d8,
  .label_complex_b2ff,
  .green-19b8,
  .shadow_6147,
  .input_fast_433f,
  .frame-iron-fbbc,
  .row-tall-822b,
  .box-f125 {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
  }
  
  /* Ensure tables are scrollable */
  .paper_b739,
  .message_67e1 {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Fix any fixed-width elements */
  .layout_paper_eb5d,
  .plasma_64a9,
  .description-red-45f1,
  .bronze-d008,
  .glass_1ef7,
  .accordion_dim_d2bc,
  .summary_6910 {
    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 */
  .filter-6f8b,
  .out-d9cc,
  .item-last-5358,
  .inner-fc3b,
  .element-pink-9adc {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Fix text overflow */
  h1, h2, h3, h4, h5, h6,
  p, span, a, li, td, th,
  .frame_hard_046c,
  .image-plasma-0843,
  .hidden_orange_aff7,
  .disabled_7e0d {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
  }
  
  /* Fix code blocks */
  pre,
  code,
  .disabled_9f47,
  .content_lower_d2e1 {
    overflow-x: auto !important;
    max-width: 100% !important;
    word-wrap: break-word !important;
  }
  
  /* Fix buttons */
  .search-up-2d9d,
  .content-334e,
  .media-yellow-04ab,
  .slider_blue_e461 {
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  /* Fix flex containers */
  .last-7deb,
  .tabs_rough_4194,
  .focused-4852,
  .yellow_b318,
  .border_gold_4fb0,
  .media-f72f {
    flex-wrap: wrap !important;
    width: 100% !important;
  }
}

/* Extra small screens (≤480px) */
@media (max-width: 480px) {
  /* Even more aggressive fixes */
  * {
    max-width: 100vw !important;
  }
  
  section,
  .filter-6f8b,
  .out-d9cc,
  .inner-fc3b {
    max-width: none !important;
  }
  
  .footer_mini_9bc2 {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  
  /* Reduce font sizes if needed */
  .frame_hard_046c {
    font-size: 1.5rem !important;
  }
  
  .image-plasma-0843 {
    font-size: 1.375rem !important;
  }
  
  /* Stack everything */
  .active-active-47a8,
  .accent-bc8d {
    flex-direction: column !important;
  }
  
  /* Smaller stat values */
  .hidden_orange_aff7 {
    font-size: 2rem !important;
  }
  
  /* Ensure score circles fit */
  .info-d209 {
    width: 100px !important;
    height: 100px !important;
    font-size: 2.5rem !important;
  }
  
  .picture_c425 {
    width: 140px !important;
    height: 140px !important;
  }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .filter-6f8b,
  .inner-fc3b {
    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: 98ac */
.ghost-box-f7 {
  padding: 0.2rem;
  font-size: 14px;
  line-height: 1.2;
}
