/* ═══════════════════════════════════════════════
   Valley to Purpose — Site Stylesheet
   valleytopurpose.com
   ═══════════════════════════════════════════════ */

/* ─── Foundations ─── */
:root {
  /* Parchment & Ink */
  --parchment: #E8DFC8;
  --parchment-dark: #D4C9AD;
  --ink: #2C2416;
  --ink-mid: rgba(44, 36, 22, 0.65);
  --ink-light: rgba(44, 36, 22, 0.4);
  --ink-faint: rgba(44, 36, 22, 0.1);

  /* David's Bitters — natural dye palette */
  --log-house: #E38F39;       /* Scripture · honey/gold */
  --black-walnut: #5D4434;    /* Ancient World · earth */
  --elderberry: #53405B;      /* Psychologists · transformation */
  --staghorn: #C12026;        /* Theologians · blood/cross */
  --shagbark: #F2D3A6;        /* Modern Storytellers · light */

  /* Functional */
  --accent: var(--log-house);
  --bg: var(--parchment);
  --bg-secondary: var(--parchment-dark);
  --text: var(--ink);
  --text-mid: var(--ink-mid);
  --text-light: var(--ink-light);
  --border: var(--ink-faint);

  /* Type */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Cormorant Garamond', Georgia, serif;

  /* Spacing */
  --page-max: 680px;
  --page-pad: 2em;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 18px;
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* Paper texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1000;
}

/* ─── Typography ─── */
h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 2.4rem;
  line-height: 1.2;
  margin-bottom: 0.5em;
}

h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.6rem;
  line-height: 1.3;
  margin-bottom: 0.5em;
}

h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.2rem;
  line-height: 1.4;
  margin-bottom: 0.4em;
}

p { margin-bottom: 1em; }
p:last-child { margin-bottom: 0; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.3s ease;
}
a:hover { color: var(--black-walnut); }

blockquote {
  border-left: 3px solid var(--accent);
  padding-left: 1.25em;
  margin: 1.5em 0;
  font-style: italic;
  color: var(--text-mid);
}

hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 3em auto;
  max-width: 200px;
}

/* ─── Layout ─── */
.page {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--page-pad);
}

.page-header {
  text-align: center;
  padding: 4em 0 2em;
}

.page-header .subtitle {
  font-size: 1.15rem;
  color: var(--text-mid);
  font-style: italic;
  max-width: 500px;
  margin: 0 auto;
}

/* ─── Navigation ─── */
.site-nav {
  padding: 1.25em var(--page-pad);
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 900px;
  margin: 0 auto;
}

.site-nav .nav-home {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--text);
  text-decoration: none;
}
.site-nav .nav-home:hover { color: var(--accent); }

.site-nav .nav-links {
  display: flex;
  gap: 1.75em;
  list-style: none;
}

.site-nav .nav-links a {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mid);
  text-decoration: none;
  transition: color 0.3s ease;
}
.site-nav .nav-links a:hover { color: var(--accent); }

/* ─── Sections ─── */
.section {
  padding: 3em 0;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 0.5em;
  display: block;
}

/* ─── Stage Cards (homepage) ─── */
.stage-card {
  display: flex;
  align-items: baseline;
  gap: 1em;
  padding: 1em 1.25em;
  background: var(--bg-secondary);
  border-left: 3px solid var(--accent);
  margin-bottom: 0.75em;
}

.stage-card .stage-num {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  min-width: 1.5em;
}

.stage-card .stage-name {
  font-size: 1.1rem;
  font-weight: 500;
}

.stage-card .stage-desc {
  margin: 0.25em 0 0;
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.5;
}

/* ─── Audio Player ─── */
.audio-block {
  background: var(--bg-secondary);
  padding: 1.5em;
  border-left: 3px solid var(--accent);
  margin: 1.5em 0;
}

.audio-block audio {
  width: 100%;
  max-width: 500px;
  display: block;
  margin: 0.75em auto 0;
}

.audio-block .audio-label {
  font-size: 0.95rem;
  font-weight: 500;
  text-align: center;
}

.audio-block .audio-note {
  font-size: 0.8rem;
  color: var(--text-mid);
  text-align: center;
  margin-top: 0.5em;
}

/* ─── Transcript Toggle ─── */
.transcript-toggle {
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--text-mid);
  cursor: pointer;
  padding: 0.5em 0;
  display: flex;
  align-items: center;
  gap: 0.5em;
  transition: color 0.3s;
}
.transcript-toggle:hover { color: var(--accent); }
.transcript-toggle svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  transition: transform 0.3s;
}
.transcript-toggle.open svg { transform: rotate(180deg); }

.transcript-content {
  display: none;
  padding: 1em 0;
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--text-mid);
}
.transcript-content.open { display: block; }

/* ─── CTA Block ─── */
.cta-block {
  text-align: center;
  padding: 2.5em 2em;
  background: var(--bg-secondary);
  border-left: 4px solid var(--accent);
  margin: 3em 0;
}

.cta-block h2 { margin-bottom: 0.25em; }

.cta-block .cta-sub {
  color: var(--text-mid);
  margin-bottom: 1.5em;
}

/* ─── Email Form ─── */
.email-form {
  max-width: 400px;
  margin: 0 auto;
}

.email-form input[type="email"] {
  width: 100%;
  padding: 0.875em;
  border: 2px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  margin-bottom: 0.75em;
  outline: none;
  transition: border-color 0.3s;
}
.email-form input[type="email"]:focus {
  border-color: var(--accent);
}
.email-form input[type="email"]::placeholder {
  color: var(--text-light);
}

.email-form button {
  width: 100%;
  padding: 0.875em 2em;
  background: var(--accent);
  color: var(--ink);
  border: none;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s;
}
.email-form button:hover {
  background: var(--black-walnut);
  color: var(--parchment);
}

/* ─── Song List ─── */
.song-list {
  list-style: none;
  margin: 1em 0;
}

.song-list li {
  padding: 0.5em 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

.song-list li:last-child { border-bottom: none; }

.song-list .song-title {
  font-style: italic;
  font-weight: 500;
}

.song-list .song-artist {
  color: var(--text-mid);
  font-size: 0.85rem;
}

/* ─── Footer / Badge ─── */
.site-footer {
  text-align: center;
  padding: 3em var(--page-pad) 2em;
  margin-top: 3em;
  border-top: 1px solid var(--border);
}

.site-footer .badge-link {
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-light);
  text-decoration: none;
}
.site-footer .badge-link:hover { color: var(--accent); }

.site-footer .footer-copy {
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 0.75em;
}

/* ─── Responsive ─── */
@media (max-width: 600px) {
  :root { --page-pad: 1.5em; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.4rem; }
  body { font-size: 17px; }

  .site-nav {
    flex-direction: column;
    gap: 0.75em;
    text-align: center;
  }

  .site-nav .nav-links { gap: 1.25em; }
}
