/* WVIZ-858: the Schedule tab. Its sections are separated by space, not rules. */
.schedule .viz-section {
  padding-top: 0;
  border-top: 0;
}

/* Reserves: a section builds when it scrolls near, and its chart is taller than
   the title and cards the server renders, so a drag of the scrollbar to a lower
   section used to shift the page by hundreds of pixels. While a section holds
   no chart yet it keeps at least the height it renders at, measured on the NWSL
   root as the smaller of 375 and 1280 px (WVIZ-858). A section that already
   holds its chart is untouched. */
.schedule {
  --schedule-grid-reserve: 768px;
  --schedule-day-reserve: 557px;
  --schedule-month-reserve: 557px;
}

/* Phone width: the charts render taller below 768 px. Smallest built heights at
   375 px over the NWSL, WSL and USL Super League roots and a small club on each
   (grid 843 on the USL root; day and month 666 / 644 on a club page), so a
   reserve never exceeds a section that is really built. */
@media (width <= 767px) {
  .schedule {
    --schedule-grid-reserve: 843px;
    --schedule-day-reserve: 666px;
    --schedule-month-reserve: 644px;
  }
}

.schedule [data-viz-section="match-grid"]:not(:has(.timeline__pill)) {
  min-height: var(--schedule-grid-reserve);
}

.schedule [data-viz-section="day-of-week"]:not(:has(.day-of-week__bar-group)) {
  min-height: var(--schedule-day-reserve);
}

.schedule [data-viz-section="month-of-year"]:not(:has(.monthly__bar-group)) {
  min-height: var(--schedule-month-reserve);
}
