:root {
  /* Overridden per track by /<slug>/theme.css (picked from the cover at build time). */
  --accent: #8c8c99;

  --text: #111113;
  --text-strong: #ffffff;
  --text-artist: #edf3f7;
  --text-muted: #404047;
  --focus: #0a84ff;

  /* Liquid glass */
  --glass-fill: rgb(255 255 255 / 0.01);
  --glass-fallback: rgb(255 255 255 / 0.92);
  --glass-edge: rgb(255 255 255 / 0.38);
  --glass-blur: blur(6px) saturate(150%) brightness(1.08);
  --glass-highlight:
    radial-gradient(120% 60% at 20% 0%, rgb(255 255 255 / 0.1) 0%, rgb(255 255 255 / 0) 60%),
    linear-gradient(160deg, rgb(255 255 255 / 0.03) 0%, rgb(255 255 255 / 0) 45%, rgb(255 255 255 / 0.02) 100%);
  --pill-fill: rgb(255 255 255 / 0.82);
  --pill-fill-hover: rgb(255 255 255 / 0.96);
  --pill-highlight: linear-gradient(180deg, rgb(255 255 255 / 0.16) 0%, rgb(255 255 255 / 0.04) 48%, rgb(255 255 255 / 0) 100%);

  --card-width: 420px;
  --cover-size: min(calc(100vw - 3rem), 360px);
  --radius-card: 28px;
  --radius-cover: 16px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-press: 360ms;
  --duration-fade: 200ms;
  --breathe: 7s;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

html, body { overflow-x: clip; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: var(--font);
  color: var(--text);
  background: #e9e9ec;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Background layers (back to front) ----------
   1. .backdrop       blurred cover
   2. body::before    light wash, tinted with the cover's accent
   3. .effect-layer   optional animated effect (snow, ...), only on pages that set one
   4. .page, .label   all content                                                     */

.backdrop {
  position: fixed;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.3);
  filter: blur(36px) saturate(1.4);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgb(255 255 255 / 0.3);
  background: linear-gradient(rgb(0 0 0 / var(--background-dim, 0)), rgb(0 0 0 / var(--background-dim, 0))),
    linear-gradient(180deg,
    color-mix(in srgb, var(--accent) 12%, rgb(255 255 255 / 0.24)),
    color-mix(in srgb, var(--accent) 8%, rgb(255 255 255 / 0.36)));
}

.effect-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.effect-layer[data-effect="clouds"] {
  filter: blur(6px);
  opacity: 0.7;
}

@media (width < 600px) {
  .page:has(.effect-layer[data-effect="neeya-dog"]) {
    padding-bottom: 292px;
  }

  .page > .effect-layer[data-effect="neeya-dog"] {
    position: absolute;
    inset: auto 0 0 auto;
    width: 100vw;
    height: 100dvh;
  }
}

.page,
.label {
  position: relative;
  z-index: 1;
}

.page {
  width: 100%;
  max-width: calc(var(--card-width) + 2rem);
  padding: clamp(2rem, 7vh, 4.5rem) 1rem 1.5rem;
  flex: 1;
}

/* ---------- Release header ---------- */

.release { text-align: center; }

.cover-art {
  position: relative;
  isolation: isolate;
  width: var(--cover-size);
  aspect-ratio: 1;
  margin: 0 auto 1.5rem;
}

/* Accent-coloured bloom under the glow, so the colour still reads on very dark covers. */
.cover-art::before {
  content: "";
  position: absolute;
  inset: 8%;
  z-index: -2;
  border-radius: 50%;
  background: var(--accent);
  filter: blur(60px);
  opacity: 0.45;
}

/* Ambient glow: a blurred, enlarged copy of the cover, breathing slowly. */
.cover-glow {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(60px) saturate(1.4);
  opacity: 0.6;
  transform: scale(1.1);
  animation: breathe var(--breathe) ease-in-out infinite alternate;
  will-change: transform, opacity;
}

@keyframes breathe {
  from { transform: scale(1.06); opacity: 0.5; }
  to   { transform: scale(1.16); opacity: 0.68; }
}

.cover {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-cover);
  box-shadow: 0 2px 6px rgb(0 0 0 / 0.08), 0 24px 50px -14px rgb(0 0 0 / 0.4);
  background: #ddd;
}

/* Crisp, editorial release typography without a glow behind the text. */
.release-text {
  margin-bottom: 1.4rem;
  font-family: "Avenir Next", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.artist {
  margin: 0 0 0.45rem;
  font-size: 0.9375rem;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: 0.22em;
  text-indent: 0.22em;
  text-transform: uppercase;
  color: var(--text-artist);
  text-shadow: 0 2px 4px rgb(0 0 0 / 0.2);
}

.title {
  margin: 0;
  font-size: clamp(2.5rem, 2rem + 2vw, 3.25rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.045em;
  overflow-wrap: anywhere;
  color: var(--text-strong);
  text-shadow: 0 2px 4px rgb(0 0 0 / 0.2);
}

.hint {
  margin: 0.55rem 0 0;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-muted);
}

/* ---------- Services card: liquid glass ---------- */

.services {
  position: relative;
  isolation: isolate;
  list-style: none;
  margin: 0;
  padding: 0.5rem;
  border-radius: var(--radius-card);
  background: var(--glass-highlight), var(--glass-fallback);
  box-shadow:
    inset 0 1px 1px rgb(255 255 255 / 0.7),
    inset 0 -1px 1px rgb(255 255 255 / 0.18),
    inset 0 0 22px rgb(255 255 255 / 0.05),
    0 1px 2px rgb(19 30 42 / 0.06),
    0 8px 20px -12px rgb(19 30 42 / 0.1),
    0 30px 60px -32px rgb(19 30 42 / 0.2);
}

@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .services {
    background: var(--glass-highlight), var(--glass-fill);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
  }
}

/* Specular rim: a 1px gradient ring, bright at the top-left and bottom-right like light catching a glass edge. */
.services::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  padding: 1px;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(145deg,
    rgb(255 255 255 / 0.85) 0%,
    rgb(255 255 255 / 0.18) 28%,
    rgb(255 255 255 / 0.06) 55%,
    rgb(255 255 255 / 0.4) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}

.service {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 3.75rem;
  padding: 0.4rem 0.75rem;
  border-radius: 20px;
  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--duration-fade) var(--ease), box-shadow var(--duration-fade) var(--ease);
}

@media (hover: hover) {
  .service:hover {
    background-color: rgb(255 255 255 / 0.14);
    box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.4), inset 0 0 0 1px rgb(255 255 255 / 0.1);
  }
}

.service:active { background-color: rgb(255 255 255 / 0.2); }

.service-logo {
  flex: none;
  display: block;
  width: auto;
  height: var(--logo-h, 28px);
  max-width: 11rem;
  object-fit: contain;
  object-position: left center;
}

/* Logos that ship in colour are forced to solid white. */
.service-logo[alt="Amazon Music"] { filter: brightness(0) invert(1); }

.service-spacer { flex: 1; }

.service-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  min-width: 5.8rem;
  min-height: 2.375rem;
  padding: 0.5rem 1.125rem;
  border-radius: 999px;
  border: 1px solid rgb(255 255 255 / 0.9);
  background-image: var(--pill-highlight);
  background-color: var(--pill-fill);
  color: var(--text);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.025em;
  text-align: center;
  
  box-shadow:
    inset 0 1px 1px rgb(255 255 255 / 0.6),
    inset 0 -1px 1px rgb(255 255 255 / 0.12),
    0 1px 2px rgb(19 30 42 / 0.08),
    0 6px 14px -6px rgb(19 30 42 / 0.18);
  transition:
    transform 200ms var(--ease),
    border-color var(--duration-fade) var(--ease),
    background-color var(--duration-fade) var(--ease),
    box-shadow var(--duration-fade) var(--ease);
}

@media (hover: hover) {
  .service:hover .service-action {
    background-color: var(--pill-fill-hover);
    border-color: rgb(255 255 255 / 0.55);
    transform: translateY(-1px);
    box-shadow:
      inset 0 1px 0 rgb(255 255 255 / 0.28),
      inset 0 -1px 0 rgb(0 0 0 / 0.04),
      0 3px 6px -2px rgb(19 30 42 / 0.1),
      0 9px 18px -7px rgb(19 30 42 / 0.18);
  }
}

.service:active .service-action {
  background-color: var(--pill-fill-hover);
  transform: translateY(0) scale(0.98);
  box-shadow: inset 0 2px 4px rgb(0 0 0 / 0.08), 0 1px 3px rgb(19 30 42 / 0.06);
}

.service:focus-visible { outline: none; }
.service:focus-visible .service-action { outline: 2px solid var(--focus); outline-offset: 2px; }

.label {
  padding: 1.5rem 1rem 2rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-shadow: 0 0 12px rgb(255 255 255 / 0.8);
}

.label a { display: inline-block; color: inherit; text-decoration: none; }
.label a:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; border-radius: 4px; }

/* Crop the original logo's transparent canvas without changing the source file. */
.brand-logo {
  display: block;
  width: 180px;
  height: 57px;
  margin-inline: auto;
  object-fit: cover;
  object-position: center 53.25%;
  filter: brightness(0) invert(1);
}

.brand-logo-heading {
  width: 240px;
  height: 76px;
}

/* ---------- Index + 404 ---------- */

.plain {
  text-align: center;
  padding-top: clamp(3rem, 14vh, 8rem);
}

.plain h1 { margin: 0 0 0.5rem; font-size: 1.6rem; font-weight: 800; }
.plain p { margin: 0 0 1.75rem; color: var(--text-muted); }

.release-thumb {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
}

.release-meta { flex: 1; text-align: left; min-width: 0; }
.release-meta strong, .release-meta span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.release-meta span { font-size: 0.85rem; color: var(--text-muted); }

.plain .services { text-align: left; }

/* Small phones (iPhone SE etc.): give the platform name more room. */
@media (max-width: 360px) {
  .services { padding: 0.4rem; }
  .service { gap: 0.7rem; padding-inline: 0.6rem; }
  .service-action { min-width: 0; padding: 0.5rem 0.85rem; }
}

@media (prefers-reduced-motion: reduce) {
  .cover-glow { animation: none; will-change: auto; }
  .service-action { transition: background-color var(--duration-fade) linear; }
  .service:hover .service-action,
  .service:active .service-action { transform: none; }
}

/* Homepage uses a darker cover backdrop and light release text. */
.home {
  --text: #f5f5f7;
  --text-muted: #c5c5cc;
  --glass-fallback: #242428;
  background: #111114;
}

.home::before {
  background: linear-gradient(180deg, rgb(0 0 0 / 0.50), rgb(0 0 0 / 0.72));
}

.home .service-action { color: #000000; }
.home .release-meta span { color: #ffffff; }

.home .plain h1 { margin-bottom: 1.5rem; }
