:root {
  color-scheme: dark;
  --bg: #050505;
  --text: #f1f0ec;
  --sub: #858580;
  --line: #242424;
  --gap: 3px;
  --liquid-edge-scale: 1.004;
  --liquid-modal-scale: 1.001;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 56px;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: 0;
  padding: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

a:focus-visible,
button:focus-visible {
  outline: 1px solid #fff;
  outline-offset: 5px;
}

.site-header {
  height: 64px;
  margin: 0 5vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.site-header > a {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -1px;
}

nav {
  display: flex;
  gap: clamp(20px, 3vw, 40px);
  color: var(--sub);
  font-size: 9px;
  letter-spacing: .08em;
}

nav a {
  transition: color 180ms ease;
}

nav a:hover {
  color: var(--text);
}

main {
  margin: 0 5vw;
}

.release {
  width: min(100%, 1040px);
  margin: 0 auto;
  padding: clamp(38px, 6vh, 70px) 0 clamp(48px, 8vh, 88px);
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(300px, 420px);
  gap: clamp(34px, 7vw, 100px);
  align-items: center;
}

.release-kicker {
  margin: 0 0 clamp(34px, 6vh, 68px);
  color: var(--text);
  font-size: clamp(16px, 2.6vw, 30px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: .08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.release-artist {
  margin: 0;
  color: var(--sub);
  font-size: 9px;
  letter-spacing: .28em;
}

.release-heading h1 {
  margin: 18px 0 0;
  font-size: clamp(54px, 8vw, 112px);
  font-weight: 400;
  line-height: .86;
  letter-spacing: -.06em;
}

.release-stage {
  width: 100%;
}

.artwork {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: #0a0a0a;
}

.artwork-open {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: pan-y pinch-zoom;
}

.artwork-open img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  filter: none;
}

.artwork .ripple-canvas {
  position: absolute;
  z-index: 2;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.artwork.ripple-active .ripple-canvas {
  opacity: 1;
}

.play-toggle {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%);
  opacity: .94;
  -webkit-tap-highlight-color: transparent;
  transition: opacity 180ms ease, transform 180ms ease;
}

.play-toggle:hover,
.play-toggle:focus-visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.06);
}

.play-symbol {
  width: 0;
  height: 0;
  margin-left: 5px;
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-left: 15px solid #fff;
  filter: drop-shadow(0 1px 8px #000b);
}

.play-toggle.is-playing .play-symbol {
  width: 14px;
  height: 18px;
  margin-left: 0;
  border: 0;
  background: linear-gradient(90deg, #fff 0 5px, transparent 5px 9px, #fff 9px 14px);
}

.release-status {
  min-height: 16px;
  margin: 13px 0 0;
  color: #d6d5d0;
  font-size: 9px;
  letter-spacing: .26em;
  text-align: center;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 300ms ease, transform 300ms ease;
}

.release-status.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.visuals {
  padding: 0 0 clamp(76px, 10vh, 120px);
  border-top: 1px solid var(--line);
}

.gallery-switch {
  position: sticky;
  z-index: 10;
  top: 0;
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: #050505ef;
  backdrop-filter: blur(10px);
}

.gallery-tabs {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
}

.gallery-tabs > span {
  color: #41413e;
}

.gallery-tabs button {
  padding: 8px 0;
  color: #656560;
  transition: color 180ms ease;
}

.gallery-tabs button[aria-selected="true"] {
  color: var(--text);
}

#category-count {
  color: var(--sub);
  font-size: 8px;
  letter-spacing: .12em;
}

.collage {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--gap);
  padding-top: var(--gap);
}

.collage::after {
  content: "";
  flex: 100 1 120px;
}

.collage-card {
  --grow: 1;
  --basis: 180px;
  min-width: 108px;
  flex: var(--grow) 1 var(--basis);
  position: relative;
  display: block;
  overflow: visible;
  background: var(--bg);
  line-height: 0;
}

.ratio-square {
  --grow: 1;
  --basis: 180px;
}

.ratio-wide {
  --grow: 1.78;
  --basis: 320px;
}

.ratio-landscape {
  --grow: 1.25;
  --basis: 225px;
}

.ratio-four-three {
  --grow: 1.33;
  --basis: 240px;
}

.ratio-tall {
  --grow: .667;
  --basis: 120px;
}

.ratio-four-five {
  --grow: .8;
  --basis: 144px;
}

.ratio-three-four {
  --grow: .75;
  --basis: 135px;
}

.collage-card > img,
.photo-color-layer > img {
  width: 100%;
  height: auto;
  display: block;
  transform: scale(var(--liquid-edge-scale));
  transform-origin: center;
  will-change: filter;
}

.collage-card > img {
  filter: var(--liquid-filter, blur(0)) invert(1);
  transition: filter 300ms ease;
}

.photo-color-layer {
  width: 100%;
  display: block;
  pointer-events: none;
  filter: invert(1);
  will-change: filter;
  transition: filter 300ms ease;
}

.photo-color-layer > img {
  filter: var(--liquid-filter, blur(0));
}

.liquid-text {
  filter: var(--liquid-filter, blur(0));
  will-change: filter;
}

.notes {
  padding: 28px 0 92px;
  border-top: 1px solid var(--line);
}

footer,
.gallery-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notes-copy {
  margin: 0;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: .02em;
}

footer {
  margin: 0 5vw;
  padding: 26px 0 36px;
  border-top: 1px solid var(--line);
  color: var(--sub);
  font-size: 8px;
  letter-spacing: .1em;
}

footer > span:first-child {
  color: var(--text);
}

dialog {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 54px 5vw 16px;
  overflow: hidden;
  border: 0;
  background: #030303;
}

dialog[open] {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

dialog::backdrop {
  background: #000;
}

dialog img {
  max-width: 90vw;
  max-height: calc(100dvh - 122px);
  display: block;
  align-self: center;
  justify-self: center;
  object-fit: contain;
  transform: scale(var(--liquid-modal-scale));
  transform-origin: center;
  filter: var(--liquid-filter, blur(0));
  will-change: filter;
}

#gallery[data-kind="cover"] #gallery-image {
  transform: none;
  filter: none;
  will-change: auto;
}

dialog .close {
  position: absolute;
  right: 5vw;
  top: 18px;
  color: var(--sub);
  font-size: 10px;
}

.gallery-controls {
  width: 100%;
  padding-top: 12px;
  color: var(--sub);
  font-size: 9px;
}

.gallery-controls button {
  padding: 8px 4px;
}

.gallery-controls button:disabled {
  opacity: .24;
  cursor: default;
}

body:has(dialog[open]) {
  overflow: hidden;
}

@media (hover: hover) and (pointer: fine) {
  .collage-card:hover .photo-color-layer,
  .collage-card:focus-visible .photo-color-layer {
    filter: invert(0);
  }

  .collage-card:hover > img,
  .collage-card:focus-visible > img {
    filter: var(--liquid-filter, blur(0)) invert(0);
  }
}

@media (min-width: 1800px) {
  main,
  .site-header,
  footer {
    max-width: 1680px;
    margin-right: auto;
    margin-left: auto;
  }
}

@media (max-width: 800px) {
  :root {
    --gap: 2px;
  }

  html {
    scroll-padding-top: 52px;
  }

  .site-header {
    height: 56px;
    margin: 0 4vw;
  }

  .site-header > a {
    font-size: 15px;
  }

  nav {
    gap: 17px;
    font-size: 8px;
  }

  main {
    margin: 0 4vw;
  }

  .release {
    padding: 30px 0 40px;
    grid-template-columns: minmax(84px, .72fr) minmax(0, 1.28fr);
    gap: clamp(12px, 4vw, 16px);
  }

  .release-artist {
    font-size: 7px;
    letter-spacing: .2em;
  }

  .release-kicker {
    margin-bottom: 24px;
    font-size: clamp(13px, 3vw, 20px);
    letter-spacing: .06em;
  }

  .release-heading h1 {
    margin-top: 13px;
    font-size: clamp(38px, 12vw, 54px);
  }

  .play-toggle {
    width: 58px;
    height: 58px;
  }

  .release-status {
    margin-top: 9px;
    font-size: 8px;
  }

  .gallery-switch {
    min-height: 50px;
  }

  .gallery-tabs {
    gap: 9px;
    font-size: 10px;
  }

  .collage::after {
    flex-basis: 44%;
  }

  .collage-card {
    min-width: 0;
  }

  .collage-card--feature {
    min-width: 100%;
    max-width: 100%;
  }

  .ratio-square {
    --basis: 145px;
  }

  .ratio-wide {
    --basis: 270px;
  }

  .ratio-landscape {
    --basis: 180px;
  }

  .ratio-four-three {
    --basis: 210px;
  }

  .ratio-tall {
    --basis: 130px;
  }

  .ratio-four-five {
    --basis: 138px;
  }

  .ratio-three-four {
    --basis: 132px;
  }

  .notes {
    padding: 24px 0 70px;
  }

  footer {
    margin: 0 4vw;
    font-size: 7px;
  }

  dialog {
    padding: 50px 10px 10px;
  }

  dialog img {
    max-width: calc(100vw - 20px);
    max-height: calc(100dvh - 106px);
  }

  dialog .close {
    right: 15px;
    top: 15px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .artwork .ripple-canvas {
    display: none;
  }

  .photo-color-layer,
  .collage-card > img,
  .release-status,
  .play-toggle {
    transition: none;
  }

  .liquid-text {
    filter: none;
    will-change: auto;
  }

  .photo-color-layer > img {
    transform: none;
    filter: none;
    will-change: auto;
  }

  .collage-card > img {
    transform: none;
    filter: invert(1);
    will-change: auto;
  }

  dialog img {
    transform: none;
    filter: none;
    will-change: auto;
  }
}
