/* MMSS — public front (landing · privacy · terms · share landing).
   Self-contained, CSP-safe: external stylesheet, system fonts, no inline JS.
   Warm operatic dark theme; "opera gold" is the accent, matching the app. */

:root {
  --bg: #100c09;
  --bg-grad-1: #1a130d;
  --bg-grad-2: #0c0907;
  --surface: #1b1510;
  --surface-2: #221a13;
  --text: #efe8dd;
  --muted: #a99e8f;
  --gold: #d8b06a;
  --gold-soft: #e7c98c;
  --line: rgba(216, 176, 106, 0.16);
  --line-strong: rgba(216, 176, 106, 0.32);
  --radius: 16px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background:
    radial-gradient(1200px 600px at 50% -10%, var(--bg-grad-1), transparent 60%),
    linear-gradient(180deg, var(--bg-grad-2), var(--bg));
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

a { color: var(--gold-soft); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }

/* ---- masthead ---- */
.masthead { padding: 56px 0 8px; text-align: center; }
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--serif); font-size: 1.5rem; letter-spacing: 0.01em;
  color: var(--text);
}
.brand .mark {
  width: auto; height: 38px; flex: none;
}
.brand b { font-weight: 600; }
.brand .gold { color: var(--gold); }

/* ---- hero (landing) ---- */
.hero { text-align: center; padding: 40px 0 8px; }
.hero h1 {
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(2.1rem, 6vw, 3.2rem); line-height: 1.1;
  margin: 0 0 16px; letter-spacing: -0.01em;
}
.hero h1 .gold { color: var(--gold); }
.hero .lede { font-size: 1.2rem; color: var(--muted); max-width: 560px; margin: 0 auto 28px; }

.cta-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin: 8px 0 8px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 1rem;
  border: 1px solid var(--line-strong); color: var(--text); background: var(--surface-2);
  transition: transform 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); border-color: var(--gold); }
.btn.primary { background: linear-gradient(180deg, var(--gold-soft), var(--gold)); color: #2a1d09; border-color: transparent; }
.btn.primary:hover { filter: brightness(1.04); }

/* ---- feature grid (landing) ---- */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin: 48px 0; }
.feature {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 20px;
}
.feature h3 { font-family: var(--serif); font-weight: 600; margin: 0 0 6px; font-size: 1.12rem; }
.feature p { margin: 0; color: var(--muted); font-size: 0.98rem; line-height: 1.55; }
.feature .ico { font-size: 1.4rem; margin-bottom: 8px; display: block; }

/* ---- document pages (privacy/terms) ---- */
.doc { padding: 8px 0 64px; }
.doc h1 { font-family: var(--serif); font-weight: 600; font-size: 2.1rem; margin: 24px 0 4px; }
.doc .eyebrow { color: var(--gold); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.78rem; }
.doc .effective { color: var(--muted); font-size: 0.95rem; margin: 4px 0 28px; }
.doc h2 { font-family: var(--serif); font-weight: 600; font-size: 1.32rem; margin: 36px 0 8px; }
.doc p, .doc li { color: var(--text); }
.doc .muted { color: var(--muted); }
.doc ul { padding-left: 22px; }
.doc li { margin: 6px 0; }
.callout {
  background: var(--surface); border: 1px solid var(--line-strong); border-left: 3px solid var(--gold);
  border-radius: 12px; padding: 16px 20px; margin: 20px 0;
}
.callout strong { color: var(--gold-soft); }

/* ---- share landing ---- */
.share-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 8px; margin: 28px 0; overflow: hidden;
}
.share-head { display: flex; gap: 18px; padding: 16px; align-items: center; }
.share-cover {
  width: 116px; height: 116px; flex: none; border-radius: 12px; object-fit: cover;
  background: var(--surface-2); border: 1px solid var(--line);
}
.share-cover.placeholder { display: flex; align-items: center; justify-content: center; font-size: 2.4rem; color: var(--muted); }
.share-meta { min-width: 0; }
.share-meta .kicker { color: var(--gold); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600; }
.share-meta h2 { font-family: var(--serif); font-weight: 600; margin: 4px 0 4px; font-size: 1.5rem; line-height: 1.15; }
.share-meta .sub { color: var(--muted); margin: 0; }

.tracklist { border-top: 1px solid var(--line); }
.track {
  display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 12px;
  padding: 11px 18px; border-bottom: 1px solid var(--line); cursor: pointer;
  transition: background 0.1s ease;
}
.tracklist .track:last-child { border-bottom: none; }
.track:hover { background: var(--surface-2); }
.track .num { color: var(--muted); font-variant-numeric: tabular-nums; text-align: center; }
.track.playing .num { color: var(--gold); }
.track .t-title { min-width: 0; }
.track .t-title .name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track .t-title .artist { color: var(--muted); font-size: 0.88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track .dur { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 0.92rem; }
.track.playing .name { color: var(--gold-soft); }

.player-bar {
  position: sticky; bottom: 0; margin-top: 18px;
  background: rgba(27, 21, 16, 0.92); backdrop-filter: blur(12px);
  border: 1px solid var(--line-strong); border-radius: 14px; padding: 12px 16px;
}
.player-bar audio { width: 100%; }

.state {
  text-align: center; padding: 48px 24px; color: var(--muted);
}
.state .big { font-size: 2.6rem; display: block; margin-bottom: 10px; }
.state h2 { font-family: var(--serif); color: var(--text); font-weight: 600; margin: 0 0 8px; }
.spinner {
  width: 30px; height: 30px; border: 3px solid var(--line-strong); border-top-color: var(--gold);
  border-radius: 50%; animation: spin 0.8s linear infinite; margin: 0 auto 16px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.hidden { display: none !important; }

/* ---- footer ---- */
.footer { border-top: 1px solid var(--line); margin-top: 40px; padding: 28px 0 56px; text-align: center; color: var(--muted); font-size: 0.92rem; }
.footer a { color: var(--muted); }
.footer .dot { margin: 0 8px; opacity: 0.5; }
