/* ============================================
   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 (.tall-2e7f) is a descendant of
   .dropdown_6af7 (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.carousel_motion_709e {
  max-width: none !important;
}

/* Fix for any potential overflow elements */
/* NOTE: ".hero_motion_697a" 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.banner_6fc0 so it can't cause
   horizontal overflow anyway. */
.avatar-stale-63d2,
.dynamic-f9e1,
.picture-east-36d8,
.video-c249,
.pressed_f001,
.notification-b8d7,
.menu_0cc4,
.heading_7aea,
.label_inner_319d,
.status-easy-36e2,
.sidebar_simple_bae8 {
  max-width: 100%;
  overflow-x: hidden;
}

/* Header mobile optimizations */
@media (max-width: 768px) {
  .shade-93de {
    padding: 8px 0;
  }
  
  .top-9074 img {
    height: 28px;
    width: auto;
  }
  
  .footer_a226 {
    display: none !important;
  }
  
  .glass_3305 {
    padding: 6px 12px !important;
    font-size: 0.8125rem !important;
    white-space: nowrap;
  }
  
  .glass_3305 svg {
    width: 14px;
    height: 14px;
  }
  
  .sidebar-selected-7f1e {
    padding: 6px;
  }
  
  .accent-pro-ec28 {
    width: 20px;
  }
}

/* Mobile-specific fixes (phones) */
@media (max-width: 768px) {
  /* Force single column layout */
  .picture-east-36d8,
  .dynamic-f9e1,
  .video-c249,
  .pressed_f001,
  .brown-33b3,
  .detail_879a,
  .pagination-f3cc,
  .icon_mini_fc32,
  .background-3a55,
  .white_9cb4,
  .pattern_pink_b4a2,
  .content-brown-86d5 {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
  }
  
  /* Ensure tables are scrollable */
  .mask_9c0b,
  .shadow_98e8 {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Fix any fixed-width elements */
  .complex-9684,
  .box_f4c8,
  .disabled_8d2f,
  .popup_bronze_6de8,
  .focus_in_5c8f,
  .column_warm_06b1,
  .detail-green-53e3 {
    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 */
  .hover-dirty-504b,
  .wrapper_next_7d2c,
  .rough_cf96,
  .disabled_copper_b191,
  .text-84c2 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  /* Fix text overflow */
  h1, h2, h3, h4, h5, h6,
  p, span, a, li, td, th,
  .small_0d2b,
  .summary_white_26d9,
  .badge_slow_1e27,
  .tabs-e17b {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
  }
  
  /* Fix code blocks */
  pre,
  code,
  .description_f321,
  .input-4f0b {
    overflow-x: auto !important;
    max-width: 100% !important;
    word-wrap: break-word !important;
  }
  
  /* Fix buttons */
  .title-west-83c7,
  .list-top-763a,
  .out_bf63,
  .tag-west-eaa4 {
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  /* Fix flex containers */
  .focused_5da7,
  .tabs_59f4,
  .tabs_over_88fc,
  .border-action-8848,
  .action-f355,
  .hard-92f7 {
    flex-wrap: wrap !important;
    width: 100% !important;
  }
}

/* Extra small screens (≤480px) */
@media (max-width: 480px) {
  /* Even more aggressive fixes */
  * {
    max-width: 100vw !important;
  }
  
  section,
  .hover-dirty-504b,
  .wrapper_next_7d2c,
  .disabled_copper_b191 {
    max-width: none !important;
  }
  
  .hero_motion_697a {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  
  /* Reduce font sizes if needed */
  .small_0d2b {
    font-size: 1.5rem !important;
  }
  
  .summary_white_26d9 {
    font-size: 1.375rem !important;
  }
  
  /* Stack everything */
  .lite_31d9,
  .prev-6692 {
    flex-direction: column !important;
  }
  
  /* Smaller stat values */
  .badge_slow_1e27 {
    font-size: 2rem !important;
  }
  
  /* Ensure score circles fit */
  .notification-next-b051 {
    width: 100px !important;
    height: 100px !important;
    font-size: 2.5rem !important;
  }
  
  .card-stone-a7af {
    width: 140px !important;
    height: 140px !important;
  }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .hover-dirty-504b,
  .disabled_copper_b191 {
    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: 531a */
.widget-item-z8 {
  padding: 0.3rem;
  font-size: 10px;
  line-height: 1.0;
}
