/* Mobile-only (≤980px): keep swipe, hide scrollbar UI, and allow table to shrink */
@media (max-width: 980px){
  #overview_wrapper .dataTables_scrollBody,
  #times_wrapper .dataTables_scrollBody,
  #overview_wrapper .dt-scroll-body,
  #times_wrapper .dt-scroll-body{
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    touch-action: auto;
    overscroll-behavior-x: contain;
    padding-bottom: 12px;
    margin-bottom: -12px;
  }
  #overview_wrapper .dataTables_scrollBody::-webkit-scrollbar,
  #times_wrapper .dataTables_scrollBody::-webkit-scrollbar,
  #overview_wrapper .dt-scroll-body::-webkit-scrollbar,
  #times_wrapper .dt-scroll-body::-webkit-scrollbar{
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }

  /* Let the inner table shrink to fit visible columns (avoid forced wide min-width) */
  #overview_wrapper .dataTables_scrollBody > table,
  #overview_wrapper .dt-scroll-body > table,
  #times_wrapper .dataTables_scrollBody > table,
  #times_wrapper .dt-scroll-body > table{
    width: auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  /* Keep compact density */
  #overview, #times, .card table.dataTable{ font-size: 12px; line-height: 1.15; }
  #overview th, #overview td,
  #times th, #times td,
  .card table.dataTable th, .card table.dataTable td{
    padding: 4px 6px !important; white-space: nowrap;
  }

  /* Crush wrapper gaps on mobile */
  #overview_wrapper .row, #times_wrapper .row,
  .card .dataTables_wrapper .row{ margin:0 !important; gap:6px !important; }
  #overview_wrapper .dataTables_length, #overview_wrapper .dataTables_info,
  #times_wrapper .dataTables_length,   #times_wrapper .dataTables_info{ display:none !important; }
  #overview_wrapper .dataTables_filter, #times_wrapper .dataTables_filter{ margin:0 0 6px 0 !important; padding:0 !important; }
  #overview_wrapper .dataTables_paginate, #times_wrapper .dataTables_paginate{ margin:6px 0 0 0 !important; padding:0 !important; }
}
