/* ============================================================
   Presskit — Apple-inspired design system
   ============================================================ */

/* ---- 1. Design Tokens ---- */
:root {
  --bg:             #f5f5f7;
  --surface:        #ffffff;
  --surface-2:      #f5f5f7;
  --text:           #1d1d1f;
  --text-2:         #6e6e73;
  --text-3:         #aeaeb2;
  --blue:           #0071e3;
  --blue-dark:      #0064cc;
  --green:          #34c759;
  --red:            #ff3b30;
  --border:         rgba(0, 0, 0, 0.08);
  --border-strong:  rgba(0, 0, 0, 0.14);

  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'SF Mono', 'Fira Code', monospace;

  --max-w:    740px;
  --r-sm:     10px;
  --r-md:     18px;
  --r-lg:     24px;
  --r-pill:   100px;

  --shadow-sm:   0 2px 3px rgba(0,0,0,0.14);
  --shadow-md:   0 8px 40px rgba(0,0,0,0.22);
  --shadow-card: 0 2px 10px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:            #000000;
    --surface:       #111111;
    --surface-2:     #1c1c1e;
    --text:          #f5f5f7;
    --text-2:        #98989d;
    --text-3:        #636366;
    --border:        rgba(255, 255, 255, 0.10);
    --border-strong: rgba(255, 255, 255, 0.18);

    --shadow-sm:   0 1px 4px rgba(0,0,0,0.30);
    --shadow-md:   0 4px 24px rgba(0,0,0,0.45);
    --shadow-card: 0 2px 10px rgba(0,0,0,0.35), 0 1px 2px rgba(0,0,0,0.25);
  }
}

/* ---- 2. Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}

body {
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px 96px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); }

/* ---- 3. Header ---- */
header {
  padding: 32px 0 28px;
  margin-bottom: 8px;
}

.header-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  min-height: 28px;
}

/* ---- 4. Lang Switcher ---- */
.lang-switcher {
  position: relative;
}

/* Narrow default: show globe trigger, hide menu */
.lang-globe {
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  padding: 0.1em 0.3em;
  border-radius: var(--r-sm);
  border: 1.5px solid var(--border);
  background: none;
  color: inherit;
  user-select: none;
  transition: border-color 0.15s;
}
.lang-switcher.open > .lang-globe { border-color: var(--border-strong); }

.lang-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-sm);
  box-shadow: var(--shadow-md);
  flex-direction: column;
  min-width: 110px;
  z-index: 100;
  overflow: hidden;
}
.lang-switcher.open > .lang-menu { display: flex; }

.lang-btn {
  font-size: 0.95rem;
  line-height: 1;
  background: none;
  border: none;
  padding: 0.5em 0.75em;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.15s, background 0.15s;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5em;
  color: inherit;
}
.lang-btn:hover { opacity: 1; background: var(--surface-2); }
.lang-btn.active { opacity: 1; font-weight: 600; }
.lang-name { font-size: 0.85rem; }

/* Wide: flat flags row, no dropdown */
@media (min-width: 400px) {
  .lang-switcher { display: flex; gap: 4px; }
  .lang-globe { display: none; }
  .lang-menu {
    display: flex;
    position: static;
    flex-direction: row;
    border: none;
    box-shadow: none;
    background: none;
    min-width: 0;
    overflow: visible;
  }
  .lang-btn {
    font-size: 1.25rem;
    padding: 0.1em 0.25em;
    opacity: 0.35;
    border: 1.5px solid transparent;
    border-radius: var(--r-sm);
    gap: 0;
  }
  .lang-btn:hover { opacity: 0.7; background: none; }
  .lang-btn.active { opacity: 1; border-color: var(--border-strong); background: none; }
  .lang-name { display: none; }
}

.lang-block { display: none; }
.lang-block.active { display: block; }

/* ---- 5. Embargo ---- */
.embargo {
  display: inline-flex;
  align-items: center;
  background: var(--red);
  color: #fff;
  font-family: var(--font);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--r-pill);
}

.embargo.released {
  background: var(--green);
  color: #fff;
}

/* ---- 6. Titles ---- */
h1 {
  font-size: clamp(26px, 5vw, 36px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--text);
  margin-bottom: 8px;
}

h2 {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin: 48px 0 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

h3 {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 8px;
}

/* ---- 7. TOC & Dateline ---- */
.toc-line {
  font-size: 13px;
  color: var(--text-3);
  margin-bottom: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.toc-line a {
  color: var(--text-3);
  text-decoration: none;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: color 0.15s, background 0.15s;
  font-size: 12px;
  font-weight: 500;
}

.toc-line a:hover {
  color: var(--text);
  background: var(--surface);
}

.dateline {
  font-size: 13px;
  color: var(--text-2);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.for-fans-of {
  font-size: 14px;
  color: var(--text-2);
  margin-bottom: 32px;
}

.for-fans-of-label {
  font-weight: 600;
  color: var(--text-3);
  margin-right: 4px;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ---- 8. Artwork Card ---- */
.artwork-card {
  max-width: 400px;
  margin: 0 auto 40px;
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--surface);
}

.artwork { width: 100%; height: auto; display: block; filter: blur(20px); transition: filter 0.4s ease; }
.artwork.loaded { filter: none; }

/* ---- 9. Format chips ---- */
.formats-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--surface-2);
  flex-wrap: wrap;
}

.format-chip {
  display: inline-flex;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-sm);
}

.format-tag {
  font-family: var(--font);
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
}

.format-logo {
  height: 11px;
  width: auto;
  position: relative;
  top: 1px;
}

@media (prefers-color-scheme: dark) {
  .format-logo { filter: invert(1); }
}

/* ---- 10. Lead & Body ---- */
.lead {
  font-size: 19px;
  line-height: 1.55;
  margin-bottom: 28px;
  color: var(--text-2);
  font-weight: 400;
}

.body {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
}

.body p { margin-bottom: 1.3em; }

.body a {
  color: var(--blue);
  text-decoration: underline;
  text-decoration-color: rgba(0,113,227,0.3);
  text-underline-offset: 2px;
  transition: text-decoration-color 0.15s;
}

.body a:hover { text-decoration-color: var(--blue); }

/* ---- 11. Quotes ---- */
.quotes {
  margin: 32px 0;
}

blockquote {
  border-left: 3px solid var(--blue);
  padding: 4px 0 4px 20px;
  margin-bottom: 24px;
  font-size: 17px;
  font-style: italic;
  color: var(--text-2);
}

blockquote cite {
  display: block;
  font-style: normal;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 10px;
  color: var(--text-3);
}

blockquote cite a {
  color: var(--blue);
  text-decoration: none;
}

blockquote cite a:hover { text-decoration: underline; }

/* ---- 12. Social Copy Box ---- */
.social-copy {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 20px 24px;
  margin: 32px 0;
  box-shadow: var(--shadow-card);
}

.social-copy-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.lyrics-copy .social-copy-header {
  justify-content: flex-end;
}

.social-copy h3 {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
  margin: 0;
}

.copy-btn {
  font-family: var(--font);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.03em;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-pill);
  padding: 5px 14px;
  cursor: pointer;
  color: var(--text-2);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.copy-btn:hover {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.copy-btn.copied {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.social-copy .copy-text {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.65;
  white-space: pre-wrap;
  margin: 0;
  color: var(--text);
}

/* Artist bio variant */
.artist-bio-details {
  margin: 12px 0 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.artist-bio-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-2);
  background: var(--surface);
  padding: 10px 14px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background 0.15s;
  border-bottom: 1px solid transparent;
}

.artist-bio-details[open] > summary {
  border-bottom-color: var(--border);
}

.artist-bio-details > summary::-webkit-details-marker,
details.lyrics summary::-webkit-details-marker { display: none; }

.artist-bio-details > summary::after,
details.lyrics summary::after {
  content: attr(data-label-show);
  font-size: 11px;
  color: var(--text-3);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
}

.artist-bio-details[open] > summary::after,
details[open].lyrics summary::after { content: attr(data-label-hide); }

.artist-bio-details > summary:hover { background: var(--surface-2); }

.social-copy.artist-bio {
  margin: 0;
  border-top: none;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.social-copy.lyrics-copy {
  margin: 0;
  border: none;
  background: none;
  box-shadow: none;
  padding: 16px 20px;
}

/* ---- 13. Artist Section ---- */
.artist { margin-bottom: 32px; }

.artist-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.artist-thumb {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

.artist-header > a {
  flex-shrink: 0;
}

.artist-name {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 2px;
  color: var(--text);
}

.artist-name a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s;
}

.artist-name a:hover { color: var(--blue); }

.artist-uncredited {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
  color: var(--text);
}

.artist-comment {
  font-size: 13px;
  color: var(--text-2);
}

.artist-role {
  font-size: 13px;
  color: var(--text-2);
}

.artist-links {
  font-size: 13px;
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.artist-links a {
  color: var(--blue);
  text-decoration: none;
  transition: opacity 0.15s;
}

.artist-links a:hover { opacity: 0.75; }

/* ---- 14. Streaming Links ---- */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.links-grid a {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-card);
  transition: transform 0.15s var(--ease-out), box-shadow 0.15s var(--ease-out);
  text-align: center;
}

.links-grid a:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: var(--blue);
}

/* ---- 14a. Gallery ---- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.gallery-item {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: var(--r-md);
  transition: transform 0.15s var(--ease-out);
}

.gallery-item:hover {
  transform: translateY(-2px);
  z-index: 5;
}

.gallery-item-crop-wrap {
  display: block;
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card);
  background: var(--surface);
  transition: box-shadow 0.15s var(--ease-out);
}

.gallery-item:hover .gallery-item-crop-wrap {
  box-shadow: var(--shadow-md);
}

.gallery-item-crop {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Full-density reveal: same photo-pixel-per-screen-pixel scale as the
   crop, popped out of the grid flow and centered over the same tile,
   like a superimposed image rather than a resized one. */
.gallery-item-full {
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  max-width: none;
  transform: translate(-50%, -50%) scale(0.9);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease-out), transform 0.2s var(--ease-out);
}

.gallery-item:hover .gallery-item-full {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

@media (hover: none) {
  .gallery-item-full { display: none; }
}

/* ---- 14b. Streaming Chips ---- */
.streaming-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.streaming-chips a {
  display: inline-block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  padding: 6px 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s var(--ease-out), box-shadow 0.15s var(--ease-out), color 0.15s;
  white-space: nowrap;
}

.streaming-chips a:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  color: var(--blue);
}

/* ---- 15. Downloads ---- */
.download-zip { margin: 20px 0; }

.download-zip-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--blue);
  color: #fff;
  padding: 13px 22px;
  border-radius: var(--r-pill);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  letter-spacing: -0.01em;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s var(--ease-out), box-shadow 0.15s var(--ease-out), background 0.15s;
}

.download-zip-btn:hover {
  background: var(--blue-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  color: #fff;
}

.download-zip-btn svg { width: 18px; height: 18px; flex-shrink: 0; }

.download-zip-filename {
  font-size: 12px;
  font-weight: 400;
  opacity: 0.65;
  margin-left: 2px;
}

.downloads-individual { margin-top: 24px; }

.downloads-individual-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin: 0 0 8px;
}

.downloads { margin-top: 4px; }

.download-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  gap: 12px;
}

.download-item:last-child { border-bottom: none; }

.download-item a {
  color: var(--text);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s;
  word-break: break-all;
}

.download-item a:hover { color: var(--blue); }

.tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-2);
  background: var(--surface-2);
  border: 1px solid var(--border);
  padding: 3px 10px;
  border-radius: var(--r-pill);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ---- 16. Lyrics ---- */
details.lyrics {
  margin: 32px 0;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-card);
}

details.lyrics summary {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-2);
  padding: 14px 18px;
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid transparent;
  list-style: none;
  transition: background 0.15s;
}

details.lyrics summary:hover { background: var(--surface-2); }
details[open].lyrics summary { border-bottom-color: var(--border); }

.lyrics-credit {
  font-weight: 400;
  color: var(--text-3);
  text-transform: none;
  letter-spacing: 0;
  font-size: 12px;
  padding: 0 20px 12px;
}

.lyrics-track-title {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
  padding: 0 20px 8px;
}

.lyrics-text {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.75;
  white-space: pre-wrap;
  padding: 20px 24px;
  margin: 0;
  color: var(--text);
  cursor: text;
  user-select: text;
}

/* ---- 17. Audio Player ---- */
.player {
  background: #1d1d1f;
  padding: 16px 20px;
}

.player-title {
  font-size: 13px;
  margin-bottom: 12px;
  color: rgba(255,255,255,0.8);
  font-weight: 500;
}

.player-controls {
  display: flex;
  align-items: center;
  gap: 16px;
}

.player-btn {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border: 1.5px solid rgba(255,255,255,0.6);
  border-radius: 50%;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: background 0.15s, border-color 0.15s;
}

.player-btn:hover {
  background: rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.9);
}

.player-btn svg { width: 16px; height: 16px; }

.player-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.player-seek-wrap { width: 100%; }

.player-seek {
  width: 100%;
  accent-color: #ffffff;
  cursor: pointer;
  height: 3px;
  appearance: none;
  -webkit-appearance: none;
  background: rgba(255,255,255,0.25);
  border-radius: 2px;
  outline: none;
}

.player-seek::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  background: #fff;
  border-radius: 50%;
  cursor: pointer;
}

.player-time {
  font-size: 11px;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

/* ---- 18. Page Footer ---- */
.page-footer {
  margin-top: 48px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.lastmod {
  font-size: 12px;
  color: var(--text-3);
  margin: 0;
}

/* ---- 19. Wide Layout (2-column sticky artwork) ---- */
@media (min-width: 1100px) {
  body {
    max-width: 1160px;
    display: grid;
    grid-template-columns: 700px 1fr;
    column-gap: 48px;
    padding-left: 40px;
    padding-right: 40px;
  }

  body > * { grid-column: 1; }

  .artwork-card {
    grid-column: 2;
    grid-row: 1 / span 20;
    position: sticky;
    top: 32px;
    max-width: none;
    margin: 0;
    align-self: start;
    border-radius: var(--r-lg);
  }
}

/* ---- 20. Mobile ---- */
@media (max-width: 480px) {
  body { padding: 0 16px 64px; }
  h1 { font-size: 24px; }
  .artwork-card { border-radius: var(--r-md); }
  .links-grid { grid-template-columns: 1fr 1fr; }
}

/* ---- 21. Print ---- */
@media print {
  body {
    max-width: 100%;
    padding: 0;
    font-size: 11pt;
    color: #000;
    background: #fff;
    display: block;
  }

  .embargo { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .artwork-card { max-width: 250px; box-shadow: none; }
  .lang-switcher { display: none; }
  .lang-block { display: block !important; }
  .lang-block:not(.active) { display: none !important; }
  .download-zip-btn, .copy-btn, .player { display: none; }
}
