/* Home: the video grid is the page. Shorts rail high, maps band deliberately small. */
.video-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px 16px;
  margin-bottom: 4px;
}
@media (max-width: 1500px) { .video-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 1180px) { .video-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 860px)  { .video-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px)  { .video-grid { grid-template-columns: 1fr; } }

.home-live:empty { display: none; }
.home-live { margin-bottom: 18px; max-width: 420px; }

.video-card {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.video-card__thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  background: #1c1c20;
}
.video-card__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-card:hover .video-card__thumb { outline: 2px solid var(--app-accent); outline-offset: 2px; }
.video-card__dur,
.video-card__live {
  position: absolute;
  right: 7px; bottom: 7px;
  background: rgba(0, 0, 0, .82);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 5px;
}
.video-card__live { left: 7px; right: auto; background: #e0203a; display: flex; align-items: center; gap: 5px; }
.video-card__dot { width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.video-card__title {
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.32;
  margin-top: 7px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.video-card__sub { font-size: 13px; color: var(--app-dim); }

/* Shorts: 9:16, horizontal scroll, high on the page. */
.shorts-shelf[hidden] { display: none; }
.shorts-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 182px;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: 8px;
  scrollbar-width: thin;
}
.short-card { text-decoration: none; color: inherit; scroll-snap-align: start; cursor: pointer; }
.short-card__thumb {
  display: block;
  aspect-ratio: 9 / 16;
  border-radius: 12px;
  overflow: hidden;
  background: #1c1c20;
}
.short-card__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.short-card:hover .short-card__thumb { outline: 2px solid var(--app-accent); outline-offset: 2px; }
.short-card__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 13.5px;
  font-weight: 600;
  margin-top: 7px;
  line-height: 1.3;
}
@media (max-width: 560px) { .shorts-rail { grid-auto-columns: 148px; } }

/* Maps: one small band, never a shelf. Two cards maximum. */
.maps-band[hidden] { display: none; }
.maps-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 260px));
  gap: 16px;
}
@media (max-width: 560px) { .maps-row { grid-template-columns: 1fr; } }
.map-card { text-decoration: none; color: inherit; cursor: pointer; }
.map-card__thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  background: #1c1c20;
  border: 1px solid var(--app-line);
}
.map-card__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.map-card__play {
  position: absolute;
  left: 8px; bottom: 8px;
  background: var(--app-accent);
  color: #06210f;
  font-size: 12.5px;
  font-weight: 800;
  padding: 4px 9px;
  border-radius: 999px;
}
.map-card:hover .map-card__thumb { outline: 2px solid var(--app-accent); outline-offset: 2px; }
.map-card__title { display: block; font-size: 14px; font-weight: 600; margin-top: 7px; }
.maps-note { color: var(--app-dim); font-size: 12.5px; margin: 8px 0 0; }
