.current-courses {
  box-sizing: border-box;
  margin: 0 auto 0.75rem;
  max-width: 980px;
}

.current-courses * {
  box-sizing: border-box;
}

.current-courses__notice {
  margin: 0 0 0.75rem;
  padding: 0.7rem 0.9rem;
  border-left: 0;
  border-radius: 10px;
  background: #89879f;
  color: #ffffff;
  font-weight: 700;
}

.current-courses__group {
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(44, 62, 80, 0.12);
}

.current-courses__group-title {
  margin: 0;
  padding: 0.25rem 0 0.45rem;
  border-bottom: 0;
  color: #2c3e50;
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.current-courses__table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
}

.current-courses__table th,
.current-courses__table td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(44, 62, 80, 0.08);
}

.current-courses__table th {
  color: #ffffff;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: #89879f;
}

.current-courses__table td {
  color: #2c3e50;
  font-size: 0.92rem;
  font-weight: 700;
}

.current-courses__table tbody tr:last-child td {
  border-bottom: 0;
}

.current-courses__table td:nth-child(1),
.current-courses__table td:nth-child(2) {
  white-space: nowrap;
}

.current-courses__table td.current-courses__cell--start {
  font-family: "Montserrat", sans-serif;
}

.current-courses__table td.current-courses__cell--time {
  color: #5f7486;
}

body > .current-courses {
  padding: 0.75rem;
}

@media (max-width: 575.98px) {
  .current-courses {
    margin-bottom: 0.5rem;
  }

  .current-courses__notice {
    margin-bottom: 0.6rem;
    padding: 0.65rem 0.8rem;
  }

  .current-courses__group {
    margin-bottom: 0.6rem;
    padding-bottom: 0.35rem;
  }

  .current-courses__group-title {
    padding-bottom: 0.35rem;
    font-size: 0.95rem;
  }

  .current-courses__table thead {
    display: none;
  }

  .current-courses__table,
  .current-courses__table tbody {
    display: block;
    width: 100%;
  }

  .current-courses__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "start frequency"
      "weekday time";
    gap: 0.28rem 0.6rem;
    margin-top: 0.45rem;
    padding: 0.55rem 0.65rem;
    border: 1px solid rgba(137, 135, 159, 0.24);
    border-radius: 10px;
    background: #eef3f7;
  }

  .current-courses__table tbody tr:first-child {
    margin-top: 0;
  }

  .current-courses__table td {
    display: block;
    min-width: 0;
    padding: 0;
    border: 0;
    background: transparent;
    white-space: normal;
    font-size: 0.88rem;
  }

  .current-courses__table td::before {
    content: attr(data-label);
    display: none;
    margin-bottom: 0;
    color: #5f7486;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
  }

  .current-courses__cell-value {
    display: block;
    overflow-wrap: anywhere;
  }

  .current-courses__cell--start {
    grid-area: start;
  }

  .current-courses__cell--start .current-courses__cell-value {
    color: #2c3e50;
    font-family: "Montserrat", sans-serif;
    font-size: 0.96rem;
    font-weight: 700;
    line-height: 1.25;
  }

  .current-courses__cell--weekday {
    grid-area: weekday;
  }

  .current-courses__cell--weekday .current-courses__cell-value {
    color: #5f7486;
    font-size: 0.84rem;
    font-weight: 700;
  }

  .current-courses__cell--time {
    grid-area: time;
    justify-self: end;
    text-align: right;
  }

  .current-courses__cell--time .current-courses__cell-value {
    color: #5f7486;
    font-size: 0.84rem;
    font-weight: 700;
    white-space: nowrap;
  }

  .current-courses__cell--frequency {
    grid-area: frequency;
    justify-self: end;
    align-self: start;
    text-align: right;
  }

  .current-courses__cell--frequency .current-courses__cell-value {
    display: inline-block;
    padding: 0.12rem 0.45rem;
    border-radius: 999px;
    background: #89879f;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
  }

  body > .current-courses {
    padding: 0.5rem;
  }
}
