/* =========================================================
   Hammig String Quartet Workshops — site styles
   ========================================================= */

:root {
  /* Spring Holiday palette: pastel greens (from the SHS logo green #E8FFCB),
     with a deep leaf green as the accent. Variable names are kept from the
     original build so the HTML needs no changes. */
  --paper: #FAFCF5;
  --paper-2: #EDF6E0;
  --ink: #1B2119;
  --ink-soft: #3F4A3C;
  --slate: #67755F;
  --line: #D8E4CB;
  --line-strong: #B9CDA8;
  --varnish: #2F6137;        /* primary accent: links, eyebrows, buttons */
  --varnish-dark: #214529;
  --varnish-tint: #DDEFD0;
  --rosin: #5F9B4F;          /* secondary accent: motif notes, callout rule, focus ring */
  --band: #1E3A26;           /* dark green contact band */

  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;

  --max: 1120px;
  --gutter: clamp(20px, 4vw, 48px);
  --radius: 14px;
  --shadow: 0 1px 2px rgba(27, 33, 25, .05), 0 10px 30px -12px rgba(27, 33, 25, .18);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--varnish); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--varnish-dark); }

:focus-visible {
  outline: 3px solid var(--rosin);
  outline-offset: 3px;
  border-radius: 4px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-variation-settings: "SOFT" 60, "WONK" 1;
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.012em;
  margin: 0 0 .5em;
  color: var(--ink);
}

h1 { font-size: clamp(2.2rem, 5.2vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.3rem; }

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

.wrap {
  width: min(100% - 2 * var(--gutter), var(--max));
  margin-inline: auto;
}

.eyebrow {
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--varnish);
  margin: 0 0 .9rem;
}

.lede {
  font-size: clamp(1.1rem, 1.6vw, 1.28rem);
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 62ch;
}

.measure { max-width: 66ch; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .8rem 1.3rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: transform .18s ease, background-color .18s ease, color .18s ease, border-color .18s ease;
}
.btn-primary { background: var(--varnish); color: #fff; }
.btn-primary:hover { background: var(--varnish-dark); color: #fff; transform: translateY(-1px); }
.btn-ghost { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-1px); }
.btn svg { width: 1em; height: 1em; }

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  color: var(--ink);
  text-decoration: none;
}
.brand-mark { width: 42px; height: 30px; color: var(--ink); flex: none; }
.brand-name {
  font-family: var(--font-display);
  font-variation-settings: "SOFT" 60, "WONK" 0;
  font-weight: 500;
  font-size: 1.12rem;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.brand-name em { font-style: italic; color: var(--varnish); }

.site-nav { display: flex; gap: .25rem; }
.site-nav a {
  padding: .5rem .8rem;
  border-radius: 999px;
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 500;
  font-size: .95rem;
  transition: background-color .15s ease, color .15s ease;
}
.site-nav a:hover { background: var(--paper-2); color: var(--ink); }
.site-nav a[aria-current="page"] { background: var(--varnish-tint); color: var(--varnish-dark); }

.nav-toggle {
  display: none;
  appearance: none;
  border: 1.5px solid var(--line-strong);
  background: transparent;
  border-radius: 999px;
  padding: .5rem .9rem;
  font: inherit;
  font-size: .9rem;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
}

/* ---------- Hero with stave ---------- */

.hero {
  position: relative;
  padding: clamp(3.5rem, 9vw, 7rem) 0 clamp(2.5rem, 6vw, 4.5rem);
  overflow: hidden;
}
.hero .wrap { position: relative; }

.hero-title {
  position: relative;
  margin-bottom: 1.25rem;
}
.title-measure { max-width: 640px; position: relative; z-index: 1; }
.stave {
  position: absolute;
  left: -100vw;
  right: -100vw;
  top: 50%;
  transform: translateY(-50%);
  height: 57px;
  pointer-events: none;
  z-index: 0;
  background: repeating-linear-gradient(
    to bottom,
    var(--line-strong) 0 1px,
    transparent 1px 14px
  );
  opacity: .8;
}
/* The engraved excerpt sits on the stave, flush with the right edge of the
   page content. motif.svg is drawn with 14px staff spacing and its viewBox
   starts 42px above the top line, so top:-42px lines it up with the CSS stave. */
.stave-music {
  position: absolute;
  right: 100vw;
  top: -42px;
  height: 142px;
  width: auto;
  pointer-events: none;
}
.stave-music-short { display: none; }

.hero h1 {
  position: relative;
  z-index: 1;
  background: var(--paper);
  display: inline;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
  padding: .02em .18em .02em 0;
  margin: 0;
}
.hero .lede { margin-top: 1.2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }

.hero-compact { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: clamp(1.5rem, 4vw, 3rem); }

/* Page-load reveal, once, opt-out for reduced motion */
.reveal { animation: rise .7s cubic-bezier(.2,.7,.2,1) both; }
.reveal:nth-child(2) { animation-delay: .08s; }
.reveal:nth-child(3) { animation-delay: .16s; }
.reveal:nth-child(4) { animation-delay: .24s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none; }
  html { scroll-behavior: auto; }
  .btn, .card, .site-nav a { transition: none; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.section-tint { background: var(--paper-2); }
.section-head { margin-bottom: clamp(1.5rem, 3vw, 2.25rem); }
.section-head p { color: var(--ink-soft); max-width: 60ch; }

/* At-a-glance strip */
.glance {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}
.glance > div {
  padding: 1.25rem 1.25rem 1.25rem 0;
  border-right: 1px solid var(--line);
}
.glance > div:last-child { border-right: 0; }
.glance > div + div { padding-left: 1.25rem; }
.glance dt {
  font-size: .74rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--slate);
  font-weight: 600;
  margin-bottom: .25rem;
}
.glance dd {
  margin: 0;
  font-family: var(--font-display);
  font-variation-settings: "SOFT" 60, "WONK" 0;
  font-size: 1.3rem;
  line-height: 1.2;
}
.glance dd small { display: block; font-family: var(--font-body); font-size: .88rem; color: var(--ink-soft); margin-top: .2rem; }

/* ---------- Cards ---------- */

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease;
}
a.card { text-decoration: none; color: inherit; display: block; }
a.card:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(27,33,25,.05), 0 18px 40px -14px rgba(27,33,25,.25); }
.card h3 { margin-bottom: .35rem; }
.card p { color: var(--ink-soft); }

/* Venue label (shared) */
.venue-name {
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--varnish);
  font-weight: 600;
  margin-bottom: .35rem;
}

/* Workshop programme card */
.programme {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 1.25rem;
  align-items: start;
}
.programme .date {
  border-right: 2px solid var(--rosin);
  padding-right: 1rem;
}
.programme .date .day {
  font-family: var(--font-display);
  font-variation-settings: "SOFT" 60, "WONK" 0;
  font-size: 2.6rem;
  line-height: 1;
  font-weight: 500;
}
.programme .date .month {
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--slate);
  font-weight: 600;
  margin-top: .25rem;
}
.programme .date .weekday { font-size: .85rem; color: var(--ink-soft); }
.programme .venue-name {
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--varnish);
  font-weight: 600;
  margin-bottom: .35rem;
}
.programme h3 { font-size: 1.45rem; margin-bottom: .6rem; }
.programme dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: .3rem 1rem; font-size: .95rem; }
.programme dt { color: var(--slate); }
.programme dd { margin: 0; color: var(--ink); }
.programme .card-foot { margin-top: 1rem; font-size: .92rem; }

/* Dates table */
.dates {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}
.dates th, .dates td { text-align: left; padding: .9rem 1rem .9rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.dates th { font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--slate); font-weight: 600; }
.dates td:first-child { font-family: var(--font-display); font-variation-settings: "SOFT" 60, "WONK" 0; font-size: 1.15rem; }
.dates .muted { color: var(--slate); font-size: .9rem; }

/* Callout */
.callout {
  border-left: 3px solid var(--rosin);
  background: #fff;
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.25rem 1.5rem;
}
.callout h3 { margin-bottom: .4rem; }
.callout p { color: var(--ink-soft); }

/* "Read more" line used at the foot of cards and callouts */
.more { margin-top: .75rem; font-weight: 600; color: var(--varnish); text-decoration: none; display: block; }
a.more:hover, a.card:hover .more { color: var(--varnish-dark); text-decoration: underline; }

/* Photos */
.photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.photos figure { margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--paper-2); aspect-ratio: 4 / 3; }
.photos img { width: 100%; height: 100%; object-fit: cover; }
.photos-2 { grid-template-columns: repeat(2, 1fr); }

/* Two-column prose with aside */
.split { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.split .prose { max-width: 62ch; }

/* Tutors */
.tutor .instrument {
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--varnish);
  font-weight: 600;
  margin-bottom: .3rem;
}
.tutor h3 { margin-bottom: .2rem; }
.tutor { border-top: 3px solid var(--rosin); }

/* Venue cards with maps */
.venue { padding: 0; overflow: hidden; }
.venue .map { aspect-ratio: 16 / 10; background: var(--paper-2); border-bottom: 1px solid var(--line); }
.venue .map iframe { width: 100%; height: 100%; border: 0; display: block; }
.venue .body { padding: 1.25rem 1.5rem 1.5rem; }
.venue .body p { color: var(--ink-soft); }
.venue address { font-style: normal; margin-bottom: .75rem; }

/* Day timeline */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, 1fr); gap: 0; position: relative; }
.timeline::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 15px;
  height: 1px;
  background: var(--line-strong);
}
.timeline li { position: relative; padding: 2.2rem .75rem 0 0; }
.timeline li::before {
  content: "";
  position: absolute;
  top: 10px; left: 0;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--varnish);
  border: 2px solid var(--paper);
  box-shadow: 0 0 0 1px var(--varnish);
}
.timeline li.break::before { background: var(--rosin); box-shadow: 0 0 0 1px var(--rosin); width: 9px; height: 9px; top: 11px; }
.timeline .t-label { font-weight: 600; display: block; line-height: 1.25; }
.timeline .t-desc { font-size: .88rem; color: var(--ink-soft); display: block; margin-top: .2rem; }
.timeline li.break .t-label { color: var(--rosin); font-size: .9rem; }

/* Facts list (info page) */
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }

/* ---------- Repertoire ---------- */

.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.chip {
  appearance: none;
  border: 1.5px solid var(--line-strong);
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: .9rem;
  font-weight: 600;
  padding: .45rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--varnish); border-color: var(--varnish); color: #fff; }

.rep-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem 2.5rem; }
.composer { break-inside: avoid; padding-top: 1rem; border-top: 1px solid var(--line-strong); }
.composer h3 {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: .6rem;
}
.composer h3 .count { font-family: var(--font-body); font-size: .8rem; color: var(--slate); font-weight: 500; }
.composer ul { list-style: none; margin: 0; padding: 0; }
.composer li { padding: .35rem 0; display: flex; justify-content: space-between; gap: .75rem; align-items: baseline; border-bottom: 1px dotted var(--line); }
.composer li:last-child { border-bottom: 0; }
.composer li[hidden] { display: none; }
.composer[hidden] { display: none; }
.tag {
  flex: none;
  font-size: .7rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--slate);
  background: var(--paper-2);
  border-radius: 4px;
  padding: .15rem .4rem;
}
.rep-empty { display: none; color: var(--slate); padding: 2rem 0; }
.rep-empty.show { display: block; }

/* ---------- Contact band ---------- */

.contact-band {
  background: var(--band);
  color: #E6F0DF;
  padding: clamp(2.5rem, 6vw, 4rem) 0;
}
.contact-band h2 { color: #fff; }
.contact-band p { color: #B8CDAE; max-width: 56ch; }
.contact-band a { color: #fff; }
.contact-band .btn-primary { background: #CFEAB7; color: var(--ink); }
.contact-band .btn-primary:hover { background: #DEF3CB; color: var(--ink); }
.contact-band .inner { display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap; }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2.5rem 0 3rem;
  font-size: .92rem;
  color: var(--ink-soft);
}
.site-footer .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { font-family: var(--font-body); font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--slate); margin-bottom: .6rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: .3rem 0; }
.site-footer a { color: var(--ink); text-decoration: none; }
.site-footer a:hover { color: var(--varnish); text-decoration: underline; }
.site-footer .fine { margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-size: .82rem; color: var(--slate); }

/* ---------- Responsive ---------- */

@media (max-width: 1260px) {
  .stave-music-full { display: none; }
  .stave-music-short { display: block; }
}
@media (max-width: 1060px) {
  .stave-music { display: none; }
}

@media (max-width: 980px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .rep-grid { grid-template-columns: repeat(2, 1fr); }
  .glance { grid-template-columns: repeat(2, 1fr); }
  .glance > div:nth-child(2) { border-right: 0; }
  .glance > div:nth-child(3) { padding-left: 0; border-top: 1px solid var(--line); }
  .glance > div:nth-child(4) { border-top: 1px solid var(--line); }
  .timeline { grid-template-columns: 1fr; gap: 0; padding-left: 1.4rem; }
  .timeline::before { top: 0; bottom: 0; left: 5px; right: auto; width: 1px; height: auto; }
  .timeline li { padding: .5rem 0 .9rem 0; }
  .timeline li::before { left: -1.4rem; top: .9rem; }
  .timeline li.break::before { left: calc(-1.4rem + 1px); top: .95rem; }
  .facts { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .site-header .wrap { flex-wrap: wrap; min-height: 64px; padding-block: .6rem; }
  .brand { flex: 1 1 0; min-width: 0; gap: .6rem; }
  .brand-name { font-size: .95rem; }
  .brand-mark { width: 35px; height: 25px; }
  .nav-toggle { display: inline-block; flex: none; }
  .site-nav {
    display: none;
    flex-direction: column;
    width: 100%;
    padding: .5rem 0 .75rem;
    border-top: 1px solid var(--line);
    gap: .15rem;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: .7rem .8rem; font-size: 1.02rem; }

  .stave {
    position: static;
    transform: none;
    height: auto;
    background: none;
    opacity: 1;
    margin: 0 0 .25rem;
  }
  .stave-music-full {
    display: block;
    position: static;
    width: min(100%, 420px);
    height: auto;
    margin-left: -6px;
  }
  .stave-music-short { display: none; }
  .hero h1 { background: transparent; display: block; }
  .grid-2, .grid-3, .grid-4, .split, .photos, .rep-grid { grid-template-columns: 1fr; }
  .photos-2 { grid-template-columns: 1fr 1fr; }
  .glance { grid-template-columns: 1fr; }
  .glance > div { border-right: 0; padding-left: 0 !important; border-top: 1px solid var(--line); }
  .glance > div:first-child { border-top: 0; }
  .programme { grid-template-columns: 76px 1fr; gap: 1rem; }
  .programme .date .day { font-size: 2.1rem; }
  .programme dl { grid-template-columns: 1fr; gap: .15rem; }
  .programme dt { font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; margin-top: .4rem; }
  .dates thead { display: none; }
  .dates tr { display: block; padding: .75rem 0; border-bottom: 1px solid var(--line-strong); }
  .dates td { display: block; border: 0; padding: .3rem 0; }
  .dates td[data-label]:not(:first-child)::before {
    content: attr(data-label);
    display: block;
    font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--slate); font-weight: 600;
  }
  .dates td:first-child { font-size: 1.3rem; padding-bottom: .5rem; }
  .site-footer .cols { grid-template-columns: 1fr; gap: 1.5rem; }
  .card:not(.venue) { padding: 1.25rem; }
}

@media (max-width: 420px) {
  .photos-2 { grid-template-columns: 1fr; }
}

/* Utility */
.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;
}
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }

/* ---------- Spring Holiday additions ---------- */

.badge {
  display: inline-block;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: .3rem .7rem;
  border-radius: 999px;
  margin-bottom: .6rem;
}
.badge-full { background: var(--varnish-tint); color: var(--varnish-dark); }
.badge-soon { background: #F3F8EA; color: #4A7A3B; border: 1px solid var(--line); }

.programme .date .range {
  font-family: var(--font-display);
  font-variation-settings: "SOFT" 60, "WONK" 0;
  font-size: 1.9rem;
  line-height: 1.05;
  font-weight: 500;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: .75rem;
}
.gallery a {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  background: var(--paper-2);
  aspect-ratio: 4 / 3;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 980px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) { .gallery { grid-template-columns: repeat(2, 1fr); gap: .5rem; } }
