/* JeremyVoices.com: dark "studio" theme by default, light theme via prefers-color-scheme */
:root {
  --bg: #0f1513;
  --bg-alt: #141c19;
  --surface: #19231f;
  --surface-2: #213029;
  --border: #2a3a33;
  --text: #e8efeb;
  --muted: #9fb2a9;
  --accent: #4fd1a1;
  --accent-strong: #7be3bb;
  --accent-ink: #062a1d;
  --danger: #ff8a7a;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --player-h: 0px;
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f5f0;
    --bg-alt: #eeebe3;
    --surface: #ffffff;
    --surface-2: #f1efe9;
    --border: #dcd7cc;
    --text: #17201c;
    --muted: #56655e;
    --accent: #0f7a55;
    --accent-strong: #0b5e41;
    --accent-ink: #ffffff;
    --danger: #b3261e;
    --shadow: 0 10px 30px rgba(30, 40, 35, .12);
    color-scheme: light;
  }
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.6 var(--font-body);
  overflow-x: hidden;
}
body.player-open { --player-h: 88px; padding-bottom: var(--player-h); }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.15; margin: 0 0 .5em; }
h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 640px) { .wrap { padding: 0 28px; } }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0; padding: 0; margin: -1px;
}
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--accent); color: var(--accent-ink); padding: 8px 14px; border-radius: 8px;
}
.skip:focus { top: 12px; }

.icon { width: 1.25em; height: 1.25em; fill: currentColor; flex: none; }
.icon-stroke { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem;
}
.brand-mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px;
  background: var(--accent); color: var(--accent-ink); font-size: .9rem;
}
.nav { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav a {
  display: block; padding: 8px 12px; border-radius: 999px;
  color: var(--muted); text-decoration: none; font-weight: 500; font-size: .95rem;
}
.nav a:hover { color: var(--text); background: var(--surface); }
.nav .nav-cta { color: var(--accent-ink); background: var(--accent); }
.nav .nav-cta:hover { color: var(--accent-ink); background: var(--accent-strong); }
@media (max-width: 420px) {
  .brand-text, .brand { font-size: 1rem; }
  .nav a { padding: 8px 9px; font-size: .9rem; }
  .nav li:first-child { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 22px; border-radius: 999px;
  font: 600 1rem/1 var(--font-body); text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: background .15s, transform .15s, border-color .15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-strong); color: var(--accent-ink); }
.btn-ghost { color: var(--text); border-color: var(--border); background: transparent; }
.btn-ghost:hover { border-color: var(--accent); color: var(--text); }

/* play/pause icon swap, shared by all play buttons */
.play .icon-pause, .player-toggle .icon-pause { display: none; }
.play.is-playing .icon-play, .player.is-playing .player-toggle .icon-play { display: none; }
.play.is-playing .icon-pause, .player.is-playing .player-toggle .icon-pause { display: block; }

/* ---------- Hero ---------- */
.hero {
  padding: 32px 0 48px;
  background:
    radial-gradient(700px 400px at 85% 10%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%),
    var(--bg);
}
.hero-inner { display: grid; gap: 24px; align-items: center; }
@media (min-width: 820px) {
  .hero { padding: 80px 0; }
  .hero-inner { grid-template-columns: 1.3fr 1fr; gap: 56px; }
  .hero-portrait img { border-radius: 24px; }
}
.eyebrow { margin: 0 0 12px; color: var(--accent); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; font-size: .8rem; }
.hero h1 { font-size: clamp(2.6rem, 8vw, 4.5rem); margin-bottom: .15em; letter-spacing: -.01em; }
.tagline { font-family: var(--font-display); font-style: italic; font-size: clamp(1.25rem, 3vw, 1.6rem); color: var(--muted); margin: 0 0 18px; }
.lede { font-size: 1.1rem; max-width: 34em; margin: 0 0 28px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.motto { margin: 28px 0 0; color: var(--muted); font-weight: 500; }
.hero-portrait { margin: 0; justify-self: start; width: 160px; order: -1; }
@media (min-width: 820px) { .hero-portrait { justify-self: center; width: min(100%, 360px); order: 0; } }
.hero-portrait img {
  width: 100%; aspect-ratio: 484 / 648; object-fit: cover;
  border-radius: 18px; box-shadow: var(--shadow); border: 1px solid var(--border);
}
@media (prefers-color-scheme: dark) { .hero-portrait img { filter: saturate(.9) contrast(1.05); } }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); }
.section-intro { color: var(--muted); max-width: 42em; margin: 0 0 28px; }

/* ---------- Tabs ---------- */
.tabs {
  display: flex; gap: 6px; padding: 6px; margin: 0 0 24px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  overflow-x: auto; scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs [role="tab"] {
  flex: 1 0 auto; min-height: 42px; padding: 8px 18px; border: 0; border-radius: 999px;
  background: transparent; color: var(--muted); font: 600 .95rem var(--font-body); cursor: pointer;
}
.tabs [role="tab"]:hover { color: var(--text); }
.tabs [role="tab"][aria-selected="true"] { background: var(--accent); color: var(--accent-ink); }
@media (max-width: 520px) {
  .tabs { display: grid; grid-template-columns: 1fr 1fr; border-radius: 18px; }
  .tabs [role="tab"] { padding: 8px 10px; font-size: .92rem; }
}

.panel + .panel { margin-top: 48px; }
.has-tabs .panel + .panel { margin-top: 0; }
.has-tabs .panel-title { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.panel-title { font-size: 1.5rem; }
.panel-lede { color: var(--muted); margin: 0 0 20px; }

/* ---------- Track list ---------- */
.tracks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.track {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px;
  padding: 10px 14px 10px 10px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
  transition: border-color .15s, background .15s;
}
.track:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.track.is-current { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.track-featured { padding-top: 14px; padding-bottom: 14px; }
.track-featured .track-name { font-family: var(--font-display); font-size: 1.2rem; }
.track-name { font-weight: 500; min-width: 0; }
.track-name small { display: block; color: var(--muted); font-weight: 400; font-size: .85rem; }
.track-links { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.track-links a {
  font-size: .8rem; font-weight: 600; text-decoration: none; white-space: nowrap;
  padding: 6px 10px; border-radius: 999px; color: var(--muted); border: 1px solid var(--border);
}
.track-links a:hover { color: var(--accent); border-color: var(--accent); }
@media (max-width: 560px) {
  .track { grid-template-columns: auto 1fr; row-gap: 8px; }
  .track-links { grid-column: 2; justify-content: flex-start; }
}

.track .play {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  border: 0; cursor: pointer; background: var(--surface-2); color: var(--accent);
  transition: background .15s, color .15s, transform .15s;
}
.track .play:hover { background: var(--accent); color: var(--accent-ink); }
.track .play.is-active { background: var(--accent); color: var(--accent-ink); }
.track-featured .play { width: 52px; height: 52px; }

/* ---------- Accents ---------- */
.accents { display: grid; gap: 20px; margin-top: 24px; }
@media (min-width: 900px) { .accents { grid-template-columns: 1fr 1fr; } .accent-group:last-child { grid-column: 1 / -1; } }
.accent-group {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px;
}
.accent-group h4 { font-size: 1.15rem; color: var(--accent); }
.accent-group dl { margin: 0; display: grid; gap: 12px; }
.accent-group dt { font-weight: 600; }
.accent-group dd { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { padding: 6px 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-weight: 500; font-size: .92rem; }
.aside { margin: 14px 0 0; color: var(--muted); font-style: italic; }

.notice {
  padding: 18px 20px; border-radius: var(--radius); border: 1px dashed var(--border);
  background: var(--surface); color: var(--muted); font-weight: 500;
}

/* ---------- About ---------- */
.about { max-width: 720px; }
.about p { font-size: 1.1rem; }
.about .btn { margin-top: 8px; }

/* ---------- Footer ---------- */
.site-footer { padding: 28px 0; border-top: 1px solid var(--border); color: var(--muted); font-size: .9rem; }
.site-footer p { margin: 0; }

/* ---------- Player bar ---------- */
.player {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border); box-shadow: 0 -8px 30px rgba(0, 0, 0, .25);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  animation: slide-up .25s ease-out;
}
@keyframes slide-up { from { transform: translateY(100%); } to { transform: none; } }
.player-inner { max-width: 1080px; margin: 0 auto; display: flex; align-items: center; gap: 14px; }
.player-toggle {
  display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: 50%;
  border: 0; cursor: pointer; background: var(--accent); color: var(--accent-ink);
}
.player-toggle .icon { width: 26px; height: 26px; }
.player-toggle:hover { background: var(--accent-strong); }
.player-main { flex: 1; min-width: 0; }
.player-meta { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.player-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); flex: none; }
.player-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-progress { display: flex; align-items: center; gap: 10px; }
.time { font-variant-numeric: tabular-nums; font-size: .8rem; color: var(--muted); min-width: 2.6em; text-align: center; }
.player-volume { display: flex; align-items: center; gap: 6px; color: var(--muted); flex: none; }
.player-volume input { width: 90px; }
.player-close {
  display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%;
  background: transparent; border: 1px solid var(--border); color: var(--muted); cursor: pointer;
}
.player-close:hover { color: var(--text); border-color: var(--text); }
.player-error { max-width: 1080px; margin: 8px auto 0; color: var(--danger); font-size: .9rem; }
@media (max-width: 600px) {
  .player-volume { display: none; } /* phones use hardware volume */
  .player-inner { gap: 10px; }
}

/* range inputs */
input[type="range"] {
  -webkit-appearance: none; appearance: none; flex: 1; min-width: 0; height: 28px;
  background: transparent; cursor: pointer; margin: 0;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 6px; border-radius: 999px;
  background: linear-gradient(to right, var(--accent) var(--progress, 0%), var(--border) var(--progress, 0%));
}
.player-volume input[type="range"]::-webkit-slider-runnable-track { background: var(--border); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px; margin-top: -5px; border-radius: 50%;
  background: var(--accent); border: 2px solid var(--surface);
}
input[type="range"]::-moz-range-track { height: 6px; border-radius: 999px; background: var(--border); }
input[type="range"]::-moz-range-progress { height: 6px; border-radius: 999px; background: var(--accent); }
input[type="range"]::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); border: 2px solid var(--surface); }
