/* ==========================================================================
   Greg Thomas — site styles
   Clean rebuild of gregthomasmusic.org (originally Squarespace).
   Design tokens: black background, white text, Abel (display) + Source Code Pro.
   Everything below is plain CSS — edit freely, no build step required.
   ========================================================================== */

/* ---- Design tokens ------------------------------------------------------- */
:root {
  --bg: #000;
  --fg: #fff;
  --muted: rgba(255, 255, 255, 0.6);
  --line: rgba(255, 255, 255, 0.15);
  --font-display: "Abel", "Arial Narrow", sans-serif;
  --font-body: "Source Code Pro", "Courier New", monospace;
  --maxw: 1080px;
  --nav-h: 118px;
}

/* ---- Reset --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

/* ---- Reusable layout ----------------------------------------------------- */
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}
.section {
  padding: 96px 0;
  border-top: 1px solid var(--line);
  text-align: center;
}
.section:first-of-type { border-top: 0; }

/* ---- Typography ---------------------------------------------------------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  margin: 0;
  line-height: 1.1;
}
.section-title {
  font-size: clamp(2.4rem, 6vw, 5rem);
  letter-spacing: 0.09em;
  margin-bottom: 0.5em;
}
.section-subtitle {
  color: var(--muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin: -0.4em 0 2.4em;
}
.lead {
  max-width: 620px;
  margin: 0 auto 2.4em;
  color: var(--fg);
}

/* ---- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.9rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--fg);
  background: transparent;
  border: 2px solid var(--fg);
  padding: 20px 32px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.btn:hover { background: var(--fg); color: var(--bg); }
.btn-row { display: flex; flex-wrap: wrap; gap: 18px; justify-content: center; }

/* ---- Header / navigation ------------------------------------------------- */
.site-header {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 32px 28px;
}
.nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
}
.nav ul {
  list-style: none;
  display: flex;
  gap: 28px;
  margin: 0; padding: 0;
}
.nav-left  { justify-content: flex-end; }
.nav-right { justify-content: flex-start; }
.nav a {
  text-decoration: none;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--muted);
  transition: color 0.2s ease;
}
.nav a:hover { color: var(--fg); }
.nav-logo { display: block; }
.nav-logo img { width: 86px; height: auto; }

/* mobile menu toggle (hidden on desktop) */
.nav-toggle { display: none; }

/* ---- Hero ---------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* Sit the title/button in the lower portion of the frame so they don't
     cover the subject's face in the background photo. */
  justify-content: flex-end;
  text-align: center;
  background: #111 center/cover no-repeat;
  padding: 120px 20px clamp(56px, 11vh, 132px);
}
.hero::after {  /* subtle darkening for legibility */
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.25);
}
.hero > * { position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(3rem, 9vw, 7rem);
  letter-spacing: 0.14em;
  margin-bottom: 0.6em;
  padding-left: 0.14em; /* optical balance for letter-spacing */
}

/* ---- Page banner (Watch / Contact tops) ---------------------------------- */
.page-banner {
  height: 46vh;
  min-height: 320px;
  background: #111 center/cover no-repeat;
  position: relative;
}
.page-banner::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

/* ---- Embeds (Spotify / SoundCloud / YouTube / Vimeo) --------------------- */
.embed { margin: 0 auto 28px; max-width: 720px; }
.embed iframe { width: 100%; border: 0; display: block; }

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  max-width: var(--maxw);
  margin: 0 auto;
}
.video {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
}
.video iframe,
.video img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
  object-fit: cover;
}
.video-caption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.8rem;
  text-align: left;
}

/* ---- Brand logo grid (licensing) ---------------------------------------- */
.logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  align-items: center;
  gap: 40px 32px;
  max-width: 900px;
  margin: 3rem auto;
}
.logo-grid a, .logo-grid span { display: flex; align-items: center; justify-content: center; }
.logo-grid img {
  max-height: 54px;
  width: auto;
  opacity: 0.85;
  transition: opacity 0.2s ease;
}
.logo-grid a:hover img { opacity: 1; }

/* ---- Forms --------------------------------------------------------------- */
.form {
  max-width: 640px;
  margin: 0 auto;
  text-align: left;
}
.form .row2 { display: flex; gap: 18px; }
.form .row2 > * { flex: 1; }
.field { margin-bottom: 22px; }
.field > label {
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  color: var(--muted);
  margin-bottom: 8px;
}
.field input[type="text"],
.field input[type="email"],
.field textarea {
  width: 100%;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 12px 14px;
}
.field input:focus,
.field textarea:focus { outline: none; border-color: var(--fg); }
.field textarea { min-height: 150px; resize: vertical; }
.radio-group { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.radio-group label {
  display: flex; align-items: center; gap: 10px;
  text-transform: none; letter-spacing: 0; font-size: 0.9rem; color: var(--fg);
}
.form .btn { margin-top: 8px; }

/* ---- Library (filterable track browser) --------------------------------- */
.library-intro { max-width: 640px; margin: 0 auto 2.5rem; color: var(--muted); }
.filters { max-width: 900px; margin: 0 auto 2.5rem; }
.filter-group { margin-bottom: 20px; }
.filter-group h3 {
  font-family: var(--font-body);
  font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 10px;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chip {
  font-family: var(--font-body);
  font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  padding: 7px 13px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.chip:hover { color: var(--fg); border-color: var(--fg); }
.chip.active { color: var(--bg); background: var(--fg); border-color: var(--fg); }

.library-count {
  color: var(--muted); font-size: 0.75rem; letter-spacing: 0.1em;
  text-transform: uppercase; margin-bottom: 1.5rem;
}

.track-list { max-width: 720px; margin: 0 auto; text-align: left; }
.track {
  border-top: 1px solid var(--line);
  padding: 20px 4px;
}
.track.hidden { display: none; }
.track-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.track-name { font-size: 1rem; letter-spacing: 0.02em; }
.track-dl {
  font-size: 0.68rem; letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--muted); text-decoration: none; white-space: nowrap;
}
.track-dl:hover { color: var(--fg); }
.track audio { width: 100%; margin: 12px 0 10px; }
.track-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.track-tags span {
  font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); padding: 3px 8px; border-radius: 2px;
  cursor: pointer;
}
.track-tags span:hover { color: var(--fg); border-color: var(--fg); }

/* ---- Footer -------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 44px 28px;
  text-align: center;
  color: var(--muted);
}
.site-footer .social { display: flex; gap: 22px; justify-content: center; margin-bottom: 18px; }
.site-footer .social a {
  text-decoration: none; text-transform: uppercase;
  letter-spacing: 0.15em; font-size: 12px; color: var(--muted);
}
.site-footer .social a:hover { color: var(--fg); }
.site-footer .copyright { font-size: 12px; letter-spacing: 0.1em; }

/* ---- Responsive ---------------------------------------------------------- */
@media (max-width: 720px) {
  /* Mobile nav.
     The two menu lists must stay in normal flow and stack. Absolutely
     positioning both at top:100% puts them on top of each other, which hides
     one list's items entirely. Collapsing via max-height/opacity (rather than
     display:none) is also what makes the open/close animate. */
  .nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    position: relative;
    gap: 0;                    /* else the two lists show a seam between them */
  }
  .nav-logo { order: 1; }

  .nav-toggle {
    display: block;
    order: 2;
    background: none;
    border: 0;
    color: var(--fg);
    cursor: pointer;
    line-height: 1;
    padding: 4px 2px;
    font-size: 0;              /* hides the literal glyph in the markup */
  }
  .nav-toggle::before { content: "\2630"; font-size: 26px; }        /* ☰ */
  #nav-check:checked ~ .nav-toggle::before { content: "\2715"; }    /* ✕ */

  .nav .nav-left  { order: 3; }
  .nav .nav-right { order: 4; }
  .nav .nav-left, .nav .nav-right {
    flex: 0 0 100%;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    margin: 0;
    padding: 0;
    background: rgba(0, 0, 0, 0.95);
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    visibility: hidden;        /* keeps collapsed links out of the tab order */
    transition: max-height 0.35s ease, opacity 0.25s ease,
                visibility 0s linear 0.35s;
  }
  .nav .nav-left a, .nav .nav-right a {
    display: block;
    padding: 14px 0;
    text-align: center;
    font-size: 13px;
  }
  #nav-check:checked ~ .nav-left,
  #nav-check:checked ~ .nav-right {
    max-height: 260px;
    opacity: 1;
    visibility: visible;
    transition: max-height 0.35s ease, opacity 0.25s ease,
                visibility 0s linear 0s;
  }

  .form .row2 { flex-direction: column; gap: 0; }
  .section { padding: 64px 0; }
}
