.topnav {
  overflow: hidden;
  background-color: #222;
}

.topnav a {
  float: left;
  color: #f2f2f2;
  text-align: center;
  padding: 8px 16px;
  text-decoration: none;
  font-size: 17px;
}

.topnav a:hover {
  background-color: #ddd;
  color: black;
}

.topnav a.active {
  background-color: #178;
  color: white;
}

.station-groups {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.station-country h2,
.station-country h3 {
  font-family: Verdana, sans-serif;
}

.station-country h2 {
  margin-bottom: 0.5rem;
}

.station-country h3 {
  margin: 1rem 0 0.25rem;
}

.station-country ul {
  margin-top: 0;
}

.playlist-tabs {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 10px;
}

.playlist-tabs button {
  padding: 8px 16px;
  border: 1px solid #178;
  border-radius: 4px;
  background: white;
  color: #222;
  cursor: pointer;
  font: inherit;
}

.playlist-tabs button:hover,
.playlist-tabs button.active {
  background: #178;
  color: white;
}

.station-groups-music {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.station-groups-music h3,
.station-groups-music h4 {
  font-family: Verdana, sans-serif;
}

@media (max-width: 700px) {
  .station-groups-music {
    grid-template-columns: minmax(0, 1fr);
  }
}

.station-groups-newstalk {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.station-groups-newstalk h3 {
  font-family: Verdana, sans-serif;
}

@media (max-width: 700px) {
  .station-groups-newstalk {
    grid-template-columns: minmax(0, 1fr);
  }
}

.station-groups-public {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.station-groups-cbc {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.station-groups-reference h1,
.station-groups-reference h3,
.station-groups-reference h5 {
  font-family: Verdana, sans-serif;
}

.station-notes {
  display: block;
  font-size: 13px;
  white-space: pre-line;
}

.playlist-tabs {
  overflow-x: auto;
}

.playlist-tabs button {
  flex-shrink: 0;
}

@media (max-width: 700px) {
  .station-groups-reference {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Align station text and notes with their country, genre, or time heading. */
#playlist .station-groups ul {
  padding-inline-start: 0;
}

#playlist .station-groups li a {
  padding-inline: 0;
}

.station-groups-newstalk {
  column-gap: 0;
}

.station-groups-newstalk ul {
  margin-block: 0;
}

.station-clock {
  margin: -0.5rem 0 0.5rem;
  font-size: 0.9rem;
}

.station-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
  margin: 1rem 10px;
}

.station-toolbar .playlist-tabs {
  margin: 0;
  max-width: 100%;
}

.now-playing {
  font-size: 1rem;
  font-weight: normal;
  overflow-wrap: anywhere;
}
