/* Start With Chords: "After Hours" design system.
   Two themes share one palette. Dark (espresso) is used for the nav, heroes, the
   call to action band and the footer; light (cream) for content sections. */

@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/instrument-serif.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/instrument-serif-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("/assets/fonts/instrument-sans.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }

:root {
  --espresso: #1F1A17;
  --walnut: #2B2420;
  --smoke: #4A3F38;
  --oat: #CDBFA9;
  --cream: #F2E9DC;
  --parchment: #FBF6EE;
  --sand: #E4D8C6;
  --hairline: #DDD0BE;
  --clay: #B8A78F;
  --cocoa: #6B5C50;
  --bark: #3F352E;
  --apricot: #E9A268;
  --white: #FFFFFF;

  /* Role tokens, light theme (content sections) */
  --bg: var(--cream);
  --bg-raised: var(--parchment);
  --bg-sunken: var(--sand);
  --fg: var(--espresso);
  --fg-muted: var(--bark);
  --fg-subtle: var(--cocoa);
  --line: var(--hairline);
  --line-strong: var(--clay);
  --accent: var(--apricot);
  --accent-fg: var(--espresso);

  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;

  --gutter: 20px;
  --section: 64px;
  --r-photo: 4px;
  --r-ui: 6px;
  --r-pill: 999px;
  --fast: 150ms;
  --medium: 220ms;
}
@media (min-width: 900px) {
  :root { --gutter: 64px; --section: 104px; }
}

/* Dark theme: any band on espresso or walnut */
.band--dark, .band--walnut, .site-header, .menu {
  --bg: var(--espresso);
  --bg-raised: var(--walnut);
  --bg-sunken: var(--espresso);
  --fg: var(--cream);
  --fg-muted: var(--oat);
  --fg-subtle: var(--oat);
  --line: var(--walnut);
  --line-strong: var(--smoke);
  background: var(--bg);
  color: var(--fg);
}
.band--walnut { --bg: var(--walnut); --line: var(--smoke); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--sans); font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

:focus-visible { outline: 2px solid var(--apricot); outline-offset: 2px; }
/* On cream the apricot ring alone is too faint: back it with espresso. */
main :focus-visible { box-shadow: 0 0 0 4px var(--espresso); }
.band--dark :focus-visible, .band--walnut :focus-visible { box-shadow: none; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 30; padding: 10px 14px; background: var(--apricot); color: var(--espresso); border-radius: var(--r-ui); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- Layout ---------- */
.wrap { max-width: 1200px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * 0.75); }
.ruled { border-top: 1px solid var(--line); }
.split { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: start; }
.split--center { align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; }
  .split--wide-left { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
  .split--form { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); }
  .split--flip > :first-child { order: 2; }
}
.stack-2 > * + * { margin-top: 8px; }
.stack-3 > * + * { margin-top: 12px; }
.stack-4 > * + * { margin-top: 18px; }
.stack-6 > * + * { margin-top: 28px; }
.stack-8 > * + * { margin-top: 40px; }
.start { display: flex; flex-direction: column; align-items: flex-start; }
.measure { max-width: 34em; }
.measure-wide { max-width: 40em; }
.head-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }

/* ---------- Type ---------- */
h1, h2, h3, h4, .serif { font-family: var(--serif); font-weight: 400; text-wrap: balance; }
.display-xl { font-size: clamp(50px, 6.6vw, 88px); line-height: 0.98; letter-spacing: -0.01em; }
.display { font-size: clamp(40px, 5.4vw, 72px); line-height: 0.98; letter-spacing: -0.01em; }
.h2 { font-size: clamp(34px, 4vw, 52px); line-height: 1.02; }
.h2--sm { font-size: clamp(30px, 3.2vw, 44px); line-height: 1.02; }
.h3 { font-size: clamp(24px, 2.2vw, 28px); line-height: 1.08; }
.h4 { font-size: 22px; line-height: 1.1; }
.lead { font-size: 18px; line-height: 1.5; }
.body { color: var(--fg-muted); }
.small { font-size: 15px; line-height: 1.5; }
.muted { color: var(--fg-muted); }
.subtle { color: var(--fg-subtle); }
.eyebrow { font-family: var(--sans); font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-subtle); line-height: 1.4; }
.num { font-family: var(--serif); font-size: 22px; line-height: 1; color: var(--fg-subtle); }
.link { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; font-weight: 500; transition: color var(--fast) ease-out; }
.link:hover { color: var(--apricot); }
main .section .link:hover, main .prose a:hover { color: var(--cocoa); }
.band--dark .link:hover, .band--walnut .link:hover { color: var(--apricot); }
.prose > * + * { margin-top: 18px; }
.prose p, .prose li { color: var(--fg-muted); line-height: 1.6; }
.prose h2 { font-size: 30px; line-height: 1.05; margin-top: 40px; }
.prose ul { list-style: disc; padding-left: 1.2em; }
.prose li + li { margin-top: 6px; }
.prose a { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; height: 52px; padding: 0 24px; border: 0; border-radius: var(--r-ui); font-size: 16px; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color var(--fast) ease-out, border-color var(--fast) ease-out; }
.btn--accent { background: var(--apricot); color: var(--espresso); }
.btn--accent:hover { background: #DB9459; }
.btn--dark { background: var(--espresso); color: var(--cream); }
.btn--dark:hover { background: #100D0B; }
.btn--ghost { border: 1px solid var(--line-strong); color: var(--fg); font-weight: 500; }
.btn--ghost:hover { border-color: var(--apricot); }
.btn--lg { height: 56px; padding: 0 28px; font-size: 17px; }
.btn--sm { height: 44px; padding: 0 20px; font-size: 15px; }
.btn--xs { height: 44px; padding: 0 14px; font-size: 14px; }
.btn--block { display: flex; width: 100%; height: 56px; font-size: 17px; }

/* ---------- Header and mobile menu ---------- */
.site-header { border-bottom: 1px solid var(--walnut); }
.site-header__bar { height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { font-family: var(--serif); font-size: 24px; line-height: 1; text-decoration: none; white-space: nowrap; color: var(--cream); }
.brand--lg { font-size: 26px; }
.site-nav { display: none; align-items: center; gap: 28px; }
.site-nav a:not(.btn) { font-size: 15px; font-weight: 500; text-decoration: none; padding-block: 12px; transition: color var(--fast) ease-out; }
.site-nav a:not(.btn):hover { color: var(--apricot); }
.site-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; text-decoration-color: var(--apricot); }
.site-header__mobile { display: flex; align-items: center; gap: 8px; }
.menu-toggle { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--smoke); border-radius: var(--r-pill); background: transparent; color: var(--cream); cursor: pointer; }
@media (min-width: 900px) {
  .site-nav { display: flex; }
  .site-header__mobile { display: none; }
}
.menu { position: fixed; inset: 0; z-index: 20; display: flex; flex-direction: column; overflow-y: auto; }
.menu[hidden] { display: none; }
.menu__bar { height: 72px; flex-shrink: 0; display: flex; align-items: center; justify-content: space-between; padding-inline: 20px; border-bottom: 1px solid var(--walnut); }
.menu__links { display: flex; flex-direction: column; padding: 16px 20px 0; flex-grow: 1; }
.menu__links a { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; border-bottom: 1px solid var(--walnut); font-family: var(--serif); font-size: 36px; line-height: 1; text-decoration: none; }
.menu__links a[aria-current="page"] { color: var(--apricot); }
.menu__n { font-family: var(--sans); font-size: 12px; color: var(--oat); }
.menu__foot { padding: 20px 20px 32px; border-top: 1px solid var(--walnut); }
@media (prefers-reduced-motion: no-preference) {
  .menu:not([hidden]) { animation: sheet var(--medium) ease-out; }
  @keyframes sheet { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
}

/* ---------- Heroes ---------- */
.hero { padding-block: 48px; }
@media (min-width: 900px) { .hero { padding-block: 96px; } }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.hero__aside { display: flex; align-items: center; gap: 14px; font-size: 15px; color: var(--oat); }
.hero__aside a { padding-block: 12px; }
.dot { width: 3px; height: 3px; border-radius: var(--r-pill); background: var(--smoke); }
.ring-row { display: flex; align-items: center; gap: 18px; padding-top: 10px; }
.ring { position: relative; width: 120px; height: 120px; flex-shrink: 0; }
.ring--lg { width: 260px; height: 260px; }
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ring__label { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-align: center; }
.ring--lg .ring__label { padding: 50px; gap: 6px; }
.ring__label .eyebrow { font-size: 9px; }
.ring--lg .ring__label .eyebrow { font-size: 10px; }
.ring__label .serif { font-size: 19px; line-height: 1; }
.ring--lg .ring__label .serif { font-size: 22px; line-height: 1.1; }
.center { display: flex; justify-content: center; }

/* ---------- Photos ---------- */
.photo { width: 100%; overflow: hidden; border-radius: var(--r-photo); background: var(--bg-sunken); }
.photo picture, .photo img { width: 100%; height: 100%; }
.photo img { object-fit: cover; object-position: var(--pos, center); }
.photo--placeholder { display: flex; align-items: flex-end; padding: 18px; border: 1px dashed var(--clay); background: var(--sand); color: var(--cocoa); font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.photo--dark.photo--placeholder { background: var(--walnut); border-color: #5E5048; color: var(--oat); }
.band--walnut .photo--dark.photo--placeholder { background: var(--espresso); }
.photo--portrait { max-width: 460px; }

/* ---------- Lists with hairlines ---------- */
.rows > * { padding-block: 20px; border-top: 1px solid var(--line); }
.rows > :last-child { border-bottom: 1px solid var(--line); }
.row { display: flex; gap: 20px; }
.row .num { width: 36px; flex-shrink: 0; padding-top: 3px; }
.row--big .num { font-size: 28px; color: var(--fg); width: 32px; padding-top: 0; }
.row h3 + p { margin-top: 6px; }
.band--walnut .rows > * { border-color: var(--smoke); }
.facts > div { display: flex; gap: 16px; padding-block: 14px; border-top: 1px solid var(--line); font-size: 16px; }
.facts > div:last-child { border-bottom: 1px solid var(--line); }
.facts dt { width: 130px; flex-shrink: 0; color: var(--fg-subtle); }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 32px; }
.step { padding-top: 18px; border-top: 2px solid var(--apricot); }
.step__n { font-family: var(--serif); font-size: 48px; line-height: 1; }
.step h3 { margin-top: 12px; }
.step p { margin-top: 12px; font-size: 16px; color: var(--fg-muted); }

/* ---------- Cards ---------- */
.card { padding: 22px; background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--r-ui); }
.card--dark { background: var(--walnut); color: var(--cream); border: 0; --fg-subtle: var(--oat); --fg-muted: var(--oat); }
.song-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(165px, 100%), 1fr)); gap: 12px; }
.song { display: flex; flex-direction: column; gap: 6px; min-height: 118px; padding: 16px; background: var(--parchment); border: 1px solid var(--hairline); border-radius: var(--r-ui); }
.song__title { font-family: var(--serif); font-size: 24px; line-height: 1.05; }
.song__artist { font-size: 13px; color: var(--cocoa); }
.pills { display: flex; flex-wrap: wrap; gap: 10px; }
.pill { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border: 1px solid var(--smoke); border-radius: var(--r-pill); font-size: 15px; }
.pill--home { border-color: var(--apricot); }
.pill--plain { border: 0; color: var(--oat); padding-inline: 4px; }
.weeks { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 12px; }
.week { display: flex; flex-direction: column; gap: 10px; min-height: 200px; padding: 24px; border-radius: var(--r-ui); background: var(--walnut); color: var(--cream); }
.week:first-child { background: var(--espresso); }
.week .eyebrow, .week p { color: var(--oat); }
.week p { font-size: 15px; line-height: 1.5; }
.week__name { font-family: var(--serif); font-size: 32px; line-height: 1; }
.week--perform { background: var(--apricot); color: var(--espresso); }
.week--perform .eyebrow, .week--perform p { color: var(--bark); }
.threads { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 12px; }

/* ---------- Chord cards ---------- */
.chord-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.chord-card { display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--parchment); color: var(--espresso); border: 1px solid var(--hairline); border-radius: var(--r-ui); }
.chord-card__top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.chord-card__name { font-family: var(--serif); font-size: 34px; line-height: 1; }
.chord-card__notes { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--cocoa); }
.chord-card__tip { font-size: 13px; line-height: 1.4; color: var(--cocoa); }
.keys { position: relative; display: flex; gap: 1px; height: 64px; }
.keys__white { flex: 1; background: var(--white); border: 1px solid #C9BBA6; border-radius: 0 0 3px 3px; }
.keys__white.is-on { background: var(--apricot); }
.keys__black { position: absolute; top: 0; width: 8%; height: 38px; background: var(--espresso); border-radius: 0 0 2px 2px; }

/* ---------- FAQ (details/summary, no JavaScript) ---------- */
.faq { border-bottom: 1px solid var(--line); }
.faq details { border-top: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; padding-block: 18px; font-family: var(--serif); font-size: 24px; line-height: 1.15; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq__icon { width: 28px; height: 28px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border: 1px solid var(--clay); border-radius: var(--r-pill); transition: transform var(--medium) ease-in-out; }
.faq details[open] .faq__icon { transform: rotate(45deg); }
.faq details p { padding: 0 44px 22px 0; font-size: 16px; color: var(--bark); max-width: 680px; }

/* ---------- Year timeline ---------- */
.legend { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 13px; color: var(--cocoa); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: var(--r-pill); border: 2px solid var(--espresso); }
.legend .is-concert { background: var(--apricot); border-color: var(--apricot); }
.legend .is-recital { background: var(--espresso); }
.month { display: flex; gap: 20px; padding-block: 22px; border-top: 1px solid var(--hairline); }
.month:last-child { border-bottom: 1px solid var(--hairline); }
.month__rail { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 44px; flex-shrink: 0; }
.month__rail::after { content: ""; width: 1px; flex-grow: 1; background: var(--hairline); }
.month__dot { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; border: 2px solid var(--espresso); border-radius: var(--r-pill); font-family: var(--serif); font-size: 20px; }
.month--concert .month__dot { background: var(--apricot); border-color: var(--apricot); }
.month--recital .month__dot { background: var(--espresso); color: var(--cream); }
.month__body { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 14px 24px; flex-grow: 1; align-items: start; }
.month__song { font-family: var(--serif); font-size: 28px; line-height: 1.05; margin-top: 4px; }
.month__artist { font-size: 14px; color: var(--cocoa); margin-top: 4px; }
.month__body p { font-size: 16px; line-height: 1.45; margin-top: 4px; }
.month__body .small { color: var(--cocoa); margin-top: 6px; font-size: 14px; }
.badge { display: inline-flex; align-items: center; height: 30px; margin-top: 6px; padding: 0 12px; border: 1px solid var(--clay); border-radius: var(--r-pill); font-size: 13px; font-weight: 600; white-space: nowrap; }
.month--concert .badge { background: var(--apricot); border-color: var(--apricot); }
.month--recital .badge { background: var(--espresso); border-color: var(--espresso); color: var(--cream); }

/* ---------- Form ---------- */
.form { display: flex; flex-direction: column; gap: 18px; padding: 20px; background: var(--parchment); border: 1px solid var(--hairline); border-radius: var(--r-ui); }
@media (min-width: 900px) { .form { padding: 32px; } }
.form__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .form legend { font-size: 14px; font-weight: 500; }
.field .opt { color: var(--cocoa); font-weight: 400; }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 0 14px; border: 1px solid var(--clay); border-radius: var(--r-ui); background: var(--white); font-size: 16px; color: var(--espresso); }
.field textarea { padding-block: 12px; resize: vertical; }
.form fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.form legend { padding: 0; margin-bottom: 8px; }
.choices { display: flex; flex-wrap: wrap; gap: 8px; }
.choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid var(--clay); border-radius: var(--r-pill); background: var(--white); font-size: 15px; cursor: pointer; }
.choice input { width: 18px; height: 18px; margin: 0; accent-color: var(--espresso); }
.choice:has(input:checked) { border-color: var(--espresso); }
.form__hint { font-size: 13px; line-height: 1.5; color: var(--cocoa); }
.form__status { padding: 14px 16px; border-radius: var(--r-ui); font-size: 16px; }
.form__status:empty { display: none; }
.form__status[data-state="ok"] { background: var(--espresso); color: var(--cream); }
.form__status[data-state="error"] { background: var(--white); border: 2px solid #9C2B12; color: #7A200C; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Call to action band and footer ---------- */
.cta-band { padding-block: 64px; border-top: 1px solid var(--walnut); }
@media (min-width: 900px) { .cta-band { padding-block: 96px; } }
.site-footer { padding-block: 56px 32px; border-top: 1px solid var(--walnut); font-size: 15px; }
.site-footer__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 32px; }
.site-footer__cols > * { display: flex; flex-direction: column; align-items: flex-start; }
.site-footer a { text-decoration: none; padding-block: 6px; transition: color var(--fast) ease-out; }
.site-footer a:hover { color: var(--apricot); }
.site-footer .stack-3 > * + * { margin-top: 4px; }
.site-footer .stack-3 > .eyebrow + * { margin-top: 10px; }
.site-footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--walnut); font-size: 13px; color: var(--oat); }
.site-footer__base a { text-decoration: underline; text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0ms !important; animation-duration: 0ms !important; }
}

@media print {
  .site-header, .menu, .cta-band, .site-footer, .skip { display: none !important; }
  body { background: #fff; }
}
