/* site/assets/css/media.css */

/* The title band carries a ghost of Daniel with the kora, the page's own subject (music),
   a photograph that appears nowhere else on this page. */
.media .page-head {
  --page-ghost: url('../img/pages/ceremony-kora-800.jpg');
  --page-ghost-pos: center 62%;
}

/* The five songs from the weekend, with the portrait beside them from 900px and
   above them below that: the two are a similar height, so the pair is even. */
.weekend-pair {
  display: grid;
  gap: 32px;
  max-width: 1040px;
  margin: clamp(36px, 4vw, 48px) auto 0;
}

@media (min-width: 900px) {
  .weekend-pair {
    grid-template-columns: minmax(260px, 320px) minmax(0, 640px);
    justify-content: center;
    align-items: start;
    gap: 56px;
  }
}

.media-portrait {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
}

.media-portrait img {
  width: 100%;
  height: auto;
  background: rgba(44, 42, 32, 0.08);
}

/* Below the two column layout the portrait is cropped to a calm band rather
   than running the height of the screen before the first song. */
@media (max-width: 899.98px) {
  .media-portrait img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center 28%;
  }
}

/* Long section titles get a slightly smaller heading than the shared panel-heading size. */
.media-panel .panel-heading { font-size: clamp(30px, 4vw, 48px); text-wrap: balance; }

.media-lede {
  margin: 20px 0 0;
  text-align: center;
  font-weight: 300;
  font-style: italic;
  font-size: clamp(20px, 2.4vw, 24px);
}

/* The playlists ------------------------------------------------------------ */

.playlists-body > .playlist:first-child { margin-top: clamp(36px, 4vw, 48px); }

.playlist { max-width: 900px; margin: 56px auto 0; }

/* A hairline between one list and the next, in place of the old heavier rule. */
.playlist + .playlist {
  padding-top: 56px;
  border-top: 1px solid var(--color-accent-hair);
}

.playlist-name {
  margin: 0;
  text-align: center;
  font-weight: 500;
  font-style: italic;
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.15;
}

/* "Playlist, 28 songs": small tracked capitals. */
.playlist-count {
  margin: 10px 0 0;
  text-align: center;
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.playlist-link { margin: 12px 0 0; text-align: center; }

/* One column on phones, two from 800px. The numbers continue down the first column and on into the second. */
.song-list {
  margin: 32px 0 0;
  padding: 0 0 0 2em;
}

@media (min-width: 800px) {
  .song-list { columns: 2; column-gap: 56px; }
}

.song { padding: 0 0 16px 6px; break-inside: avoid; line-height: 1.35; }
.song::marker { font-weight: 300; font-size: 14px; }

.song-title {
  display: block;
  font-weight: 500;
  font-style: italic;
  font-size: 19px;
  line-height: 1.3;
}

.song-artist {
  display: block;
  margin-top: 3px;
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.2em;
  line-height: 1.5;
  text-transform: uppercase;
}

/* The five songs from the weekend and the honeymoon ------------------------- */

.weekend-list {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.weekend-song {
  padding: 26px 0;
  text-align: center;
  border-top: 1px solid var(--color-accent-hair);
}

.weekend-song:last-child { border-bottom: 1px solid var(--color-accent-hair); }

.weekend-song .song-title { font-size: clamp(21px, 2.4vw, 24px); }

.weekend-note {
  display: block;
  margin-top: 6px;
  font-size: 16px;
  line-height: 1.6;
}

.weekend-link {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 0;
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: inherit;
  text-underline-offset: 5px;
}

.weekend-song a { color: inherit; text-underline-offset: 3px; }

/* Colin's video: a card with a play button until pressed ---------------------- */

.media-slot { max-width: 760px; margin: 40px auto 0; }

.video-facade {
  aspect-ratio: 16 / 9;
  background: var(--color-brown);
  color: var(--color-cream);
}

.video-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: inherit;
  font-size: 19px;
}

.video-fallback[hidden] { display: none; }

.video-play {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 100%;
  padding: 20px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: center;
  cursor: pointer;
}

.video-play[hidden] { display: none; }

.video-play:hover .video-play-icon { transform: scale(1.06); }
.video-play:focus-visible { outline: 2px solid var(--color-cream); outline-offset: -8px; }

.video-play-icon { transition: transform 0.15s ease; }

@media (prefers-reduced-motion: reduce) {
  .video-play-icon { transition: none; }
}

.video-title {
  font-weight: 500;
  font-style: italic;
  font-size: clamp(20px, 3.4vw, 30px);
  line-height: 1.2;
}

.video-hint {
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.video-source { font-weight: 300; font-size: 13px; opacity: 0.85; }

.video-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
