/* ─── Variables ─────────────────────────────────────────────────────────── */

:root {
  --bg:        #080808;
  --text:      #e8e8e8;
  --accent:    #c49a2b;
  --muted:     #555;
  --border:    #1c1c1c;
  --font:      'Space Grotesk', system-ui, -apple-system, sans-serif;
  --max:       760px;
  --pad-x:     clamp(1.25rem, 5vw, 3rem);
  --section-y: 3rem;
}

/* ─── Reset ─────────────────────────────────────────────────────────────── */

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

/* ─── Base ───────────────────────────────────────────────────────────────── */

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ─── Layout ─────────────────────────────────────────────────────────────── */

.layout {
  max-width: calc(var(--max) + var(--pad-x) * 2);
  margin: 0 auto;
  padding: 0 var(--pad-x);
}

main {
  display: block;
  width: 100%;
}

/* ─── Header ─────────────────────────────────────────────────────────────── */

header {
  display: flex;
  align-items: flex-end;
  gap: 2rem;
  padding: clamp(2rem, 6vh, 4rem) 0 2rem;
  border-bottom: 1px solid var(--border);
}

.header-text {
  flex: 1;
  min-width: 0;
}

.header-photo {
  flex-shrink: 0;
  width: clamp(7rem, 18vw, 12rem);
}

.header-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center 20%;
}

h1 {
  font-size: clamp(4.5rem, 18vw, 10rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: var(--text);
}

/* Shrinks to h1's natural width so the tagline can match it exactly */
.title-group {
  display: inline-flex;
  flex-direction: column;
}

.tagline {
  display: flex;
  justify-content: space-between;
  margin-top: 0.75rem;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  color: var(--accent);
  text-transform: lowercase;
}

/* On narrow screens, allow wrapping and add separators for readability */
@media (max-width: 500px) {
  .tagline {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0 0.15em;
  }

  .tagline span:not(:last-child)::after {
    content: '\00a0·';
  }
}

/* ─── Sections ───────────────────────────────────────────────────────────── */

section {
  padding: var(--section-y) 0;
  border-bottom: 1px solid var(--border);
}

section:last-child {
  border-bottom: none;
}

h2 {
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.75rem;
}

/* ─── Bio ────────────────────────────────────────────────────────────────── */

#bio p {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.75;
  max-width: 60ch;
  color: var(--text);
}

/* ─── Music ──────────────────────────────────────────────────────────────── */

.music-embed {
  position: relative;
  max-width: 560px;
  margin: 2rem auto 0;
}

.bandcamp-player {
  display: block;
  width: 100%;
  height: 439px;
  border: none;
}

.music-fallback {
  display: none;
  align-items: center;
  gap: 1.5rem;
}

.music-embed.failed .bandcamp-player {
  display: none;
}

.music-embed.failed .music-fallback {
  display: flex;
}

.music-fallback img {
  width: 5rem;
  height: 5rem;
  object-fit: cover;
  flex-shrink: 0;
}

.music-fallback a {
  font-size: 1rem;
}

/* ─── Gigs ───────────────────────────────────────────────────────────────── */

.gig {
  display: grid;
  grid-template-columns: 7rem 1fr 1fr;
  column-gap: 1.5rem;
  align-items: baseline;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.gig:last-child {
  border-bottom: none;
}

.gig-date {
  font-size: 0.82rem;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.gig-venue {
  font-size: 0.95rem;
  color: var(--text);
}

a.gig-venue::after {
  content: ' ↗';
  font-size: 0.7em;
  opacity: 0.5;
}

a.gig-venue:hover {
  color: var(--accent);
  text-decoration: none;
}

a.gig-venue:hover::after {
  opacity: 1;
}

.gig-city {
  font-size: 0.95rem;
  color: var(--muted);
}


.no-gigs {
  color: var(--muted);
  font-size: 0.9rem;
}

.gigs-archive {
  margin-top: 2rem;
}

.archive-toggle {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: var(--font);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.15s;
}

.archive-toggle:hover {
  color: var(--text);
}

.archive-count {
  font-size: 0.7rem;
}

.archive-list {
  margin-top: 1rem;
  opacity: 0.5;
}

/* ─── Booking ────────────────────────────────────────────────────────────── */

#booking p {
  color: var(--text);
  margin-bottom: 1.5rem;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.75;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: center;
  margin: 1.5rem 0;
}

.contact-links a {
  font-size: 1.1rem;
  color: var(--accent);
}

/* ─── Footer ─────────────────────────────────────────────────────────────── */

footer {
  padding: 2rem 0 2.5rem;
  font-size: 0.75rem;
  color: var(--muted);
}

/* ─── Video embed ────────────────────────────────────────────────────────── */

.video-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* ─── Sub-page extras (used in pages/*.html) ─────────────────────────────── */

.page-header {
  padding: clamp(2rem, 6vh, 3.5rem) 0 2rem;
  border-bottom: 1px solid var(--border);
}

.page-back {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

.page-back:hover {
  color: var(--accent);
  text-decoration: none;
}

.page-title {
  font-size: clamp(1.8rem, 6vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.page-body {
  padding: 3rem 0;
}

.page-body h3 {
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 2.5rem 0 0.75rem;
}

.page-body h3:first-child {
  margin-top: 0;
}

.page-body p,
.page-body ul,
.page-body ol {
  max-width: none;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.75;
  margin-bottom: 1rem;
  color: var(--text);
}

.page-body ul,
.page-body ol {
  padding-left: 1.25rem;
}

.page-body li {
  margin-bottom: 0.3rem;
}

/* ─── Responsive ─────────────────────────────────────────────────────────── */

@media (max-width: 520px) {
  .gig {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    row-gap: 0.15rem;
  }

  .gig-date {
    font-size: 0.75rem;
  }
}
