/* Motus Songs. The shelf: one card a song, its cover, one of his lines,
   the door in, and what the song has moved. Dark room, white words. */
:root {
  --bg: #05060c;
  --pearl: #f7f5ef;
  --top: calc(env(safe-area-inset-top, 0px) + 10px);
  --bottom: env(safe-area-inset-bottom, 0px);
  --ease: cubic-bezier(.2, .8, .2, 1);
}
* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  background:
    radial-gradient(ellipse at 50% -10%, rgba(127, 233, 245, .1) 0, transparent 55%),
    radial-gradient(ellipse at 90% 110%, rgba(255, 154, 210, .08) 0, transparent 50%),
    var(--bg);
  color: var(--pearl);
  font-family: Unbounded, Outfit, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--pearl); outline-offset: 4px; }

.top {
  position: sticky; z-index: 6; top: 0;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: var(--top) 16px 10px;
  font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
  background: linear-gradient(to bottom, rgba(5, 6, 12, .94) 60%, rgba(5, 6, 12, 0));
}
.top a { text-decoration: none; }
.top .app { padding: 9px 12px; border-radius: 12px; background: rgba(255, 255, 255, .12); }

.room { max-width: 1180px; margin: 0 auto; padding: 18px 16px calc(var(--bottom) + 48px); }
.title { margin: 14px 0 6px; font-size: clamp(2.2rem, 9vw, 4.4rem); font-weight: 800; letter-spacing: -.03em; line-height: 1; }
.lede { margin: 0 0 30px; font-size: clamp(1rem, 4vw, 1.35rem); font-weight: 500; line-height: 1.3; max-width: 26ch; }

.shelf { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; grid-template-columns: 1fr; }
.song {
  display: grid; gap: 16px; padding: 16px; border-radius: 26px;
  background: linear-gradient(165deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .03));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09);
}
.song-art { position: relative; display: block; border-radius: 18px; overflow: hidden; aspect-ratio: 1 / 1; }
.song-art img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease); }
.song-art:hover img, .song-art:focus-visible img { transform: scale(1.04); }
.song-art::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(5, 6, 12, .6), transparent 45%); }
/* the scrim is there to let a dark cover meet the dark shelf; over a
   cover that is already white it only makes a grey wash */
.song-art[data-tone="light"]::after { display: none; }
.song-body { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.song-n { font-size: 10px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; }
.song h2 { margin: 0; font-size: clamp(1.5rem, 6vw, 2.2rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
.song h2 a { text-decoration: none; }
.song blockquote { margin: 0; font-size: clamp(1rem, 4vw, 1.2rem); font-weight: 500; line-height: 1.28; }
.song .doors { display: flex; flex-wrap: wrap; gap: 8px; }
.song .tx { max-width: none; margin: 0; }

.foot { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; }
.toast { position: fixed; z-index: 9; left: 50%; bottom: calc(var(--bottom) + 24px); transform: translateX(-50%) translateY(8px); padding: 10px 14px; border-radius: 14px; background: rgba(255, 255, 255, .92); color: #000; font-size: 12px; font-weight: 700; opacity: 0; transition: opacity 240ms, transform 240ms var(--ease); pointer-events: none; }
.toast.shown { opacity: 1; transform: translateX(-50%); }

@media (min-width: 720px) {
  .room { padding: 24px 28px calc(var(--bottom) + 64px); }
  .song { grid-template-columns: 260px 1fr; align-items: start; gap: 22px; padding: 20px; }
  .song-art { width: 260px; }
}
@media (min-width: 1080px) {
  .song { grid-template-columns: 300px 1fr 420px; }
  .song-art { width: 300px; }
}
@media (prefers-reduced-motion: reduce) {
  .song-art img, .toast { transition: none; }
}
