/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green-dark:  #1a3a28;
  --green-mid:   #2c5f3f;
  --gold:        #a07830;
  --gold-light:  #c49a45;
  --cream:       #f5f0e8;
  --cream-dark:  #e8e0d0;
  --text:        #1c1c1c;
  --text-light:  #4a4a4a;
  --white:       #ffffff;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Lato', sans-serif;
  background: var(--cream);
  color: var(--text);
  line-height: 1.7;
}

/* === Typography === */
h1, h2, h3, nav a {
  font-family: 'Cinzel', serif;
}

h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); color: var(--green-dark); margin-bottom: 1rem; }
h3 { font-size: 1.2rem; color: var(--green-mid); margin-bottom: 0.5rem; }
p  { color: var(--text-light); max-width: 70ch; }

/* === Navigation === */
nav {
  background: var(--green-dark);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.nav-logo {
  color: var(--gold-light);
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  text-decoration: none;
  padding: 0.6rem 0;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.nav-logo-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--white);
  padding: 1px;
  object-fit: contain;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px var(--gold);
}

/* === Logo medallion (hero sections) === */
.logo-medallion {
  display: block;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: var(--white);
  padding: 2px;
  object-fit: contain;
  margin: 0 auto 1.5rem;
  box-shadow: 0 0 0 3px var(--gold), 0 6px 24px rgba(0,0,0,0.3);
}

.page-hero .logo-medallion {
  width: 160px;
  height: 160px;
  padding: 2px;
  margin-top: 0.75rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 0 0 3px var(--gold), 0 6px 22px rgba(0,0,0,0.3);
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--cream);
  text-decoration: none;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  padding: 0.4rem 0.9rem;
  border-radius: 4px;
  transition: background 0.2s, color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  background: var(--gold);
  color: var(--white);
}

/* === Hero === */
.hero {
  background: var(--green-dark);
  color: var(--cream);
  text-align: center;
  padding: 4rem 2rem 3.5rem;
}

.hero-logo-full {
  display: block;
  width: min(260px, 70vw);
  margin: 0 auto 0.25rem;
  border-radius: 12px;
  background: var(--white);
  padding: 10px 14px;
  box-shadow: 0 0 0 3px var(--gold), 0 8px 28px rgba(0,0,0,0.35);
}

.hero .tagline {
  font-size: 1.1rem;
  color: var(--cream-dark);
  margin-top: 0.75rem;
  font-style: italic;
}

.hero-divider {
  width: 60px;
  height: 2px;
  background: var(--gold);
  margin: 1.5rem auto;
}

/* === Sections === */
.section {
  padding: 4rem 2rem;
  max-width: 960px;
  margin: 0 auto;
}

.section + .section { border-top: 1px solid var(--cream-dark); }

.section-label {
  font-family: 'Cinzel', serif;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

/* === Schedule === */
.schedule-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.schedule-card {
  background: var(--white);
  border-left: 4px solid var(--gold);
  border-radius: 6px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.schedule-card .time {
  font-size: 0.9rem;
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}

.schedule-card .location {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 0.5rem;
}

/* === Email Signup === */
.signup-section {
  background: var(--green-dark);
  color: var(--cream);
  text-align: center;
  padding: 4rem 2rem;
}

.signup-section h2 { color: var(--gold-light); }
.signup-section p  { color: var(--cream-dark); margin: 0.75rem auto 2rem; }

/* Mailchimp embed container */
.mailchimp-embed {
  max-width: 480px;
  margin: 0 auto;
}

/* Fallback placeholder form (replace with Mailchimp embed) */
.placeholder-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

.placeholder-form input[type="email"] {
  flex: 1;
  min-width: 220px;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
  background: var(--cream);
  color: var(--text);
}

.placeholder-form button {
  padding: 0.75rem 1.75rem;
  background: var(--gold);
  color: var(--white);
  border: none;
  border-radius: 4px;
  font-family: 'Cinzel', serif;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 0.2s;
}

.placeholder-form button:hover { background: var(--gold-light); }

/* === Instructor Bio === */
.bio-section { border-bottom: 1px solid var(--cream-dark); }

.bio-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 3rem;
  align-items: start;
}

@media (max-width: 720px) {
  .bio-grid { grid-template-columns: 1fr; }
}

.bio-photo-wrap {
  position: sticky;
  top: 80px; /* clears the nav */
}

.bio-photo {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 0 0 3px var(--gold), 0 8px 28px rgba(0,0,0,0.2);
  display: block;
}

.bio-text h2 { margin-top: 0.25rem; }

/* === Page Hero (inner pages) === */
.page-hero {
  background: var(--green-dark);
  color: var(--cream);
  padding: 3.5rem 2rem 3rem;
  text-align: center;
}

.page-hero h1 { color: var(--gold-light); letter-spacing: 0.06em; }
.page-hero p  { color: var(--cream-dark); margin: 0.75rem auto 0; max-width: 60ch; }
.page-hero .hero-divider { margin: 1.25rem auto 0; }

/* === Video Player === */
.video-section {
  padding: 4rem 2rem;
  max-width: 960px;
  margin: 0 auto;
}

.video-player-wrap {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1.25rem;
  align-items: start;
  margin-top: 1.5rem;
}

@media (max-width: 640px) {
  .video-player-wrap { grid-template-columns: 1fr; }
}

.video-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.video-list button {
  width: 100%;
  text-align: left;
  padding: 0.7rem 1rem;
  background: var(--white);
  border: 2px solid transparent;
  border-radius: 5px;
  font-family: 'Lato', sans-serif;
  font-size: 0.9rem;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  line-height: 1.4;
}

.video-list button:hover { border-color: var(--gold-light); }
.video-list button.active {
  border-color: var(--gold);
  background: var(--cream-dark);
  font-weight: 700;
}

.video-frame-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  background: #111;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.video-frame-wrap iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #1a1a1a;
  color: #777;
  gap: 0.5rem;
  font-size: 0.9rem;
  text-align: center;
  padding: 1rem;
}

.video-placeholder svg { opacity: 0.4; }

/* === Info Section (inner pages) === */
.info-section {
  padding: 4rem 2rem;
  max-width: 960px;
  margin: 0 auto;
  border-bottom: 1px solid var(--cream-dark);
}

/* === Video Gloss === */

/* Page wrapper — keeps tabs + body inside the content width */
.gloss-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem;
}

/* Manuscript selector tabs */
.manuscript-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 2px solid var(--cream-dark);
  padding-bottom: 1rem;
}

.manuscript-tab {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0.6rem 1.2rem;
  background: var(--white);
  border: 2px solid var(--cream-dark);
  border-radius: 6px 6px 0 0;
  cursor: pointer;
  font-family: 'Lato', sans-serif;
  transition: border-color 0.2s, background 0.2s;
  line-height: 1.3;
}

.manuscript-tab:hover { border-color: var(--gold-light); }

.manuscript-tab.active {
  border-color: var(--gold);
  background: var(--cream-dark);
  border-bottom-color: var(--cream-dark); /* blends into border-bottom of container */
}

.ms-title {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: var(--green-dark);
}

.ms-subtitle {
  font-size: 0.75rem;
  color: var(--text-light);
  font-style: italic;
}

/* Two-column gloss body: sidebar + player */
.gloss-body {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 1.5rem;
  align-items: start;
}

@media (max-width: 700px) {
  .gloss-body { grid-template-columns: 1fr; }
}

/* Sidebar */
.gloss-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: sticky;
  top: 72px; /* clears the nav */
  max-height: calc(100vh - 100px);
  overflow-y: auto;
}

.gloss-search-wrap { position: relative; }

.gloss-search {
  width: 100%;
  padding: 0.55rem 0.9rem;
  border: 2px solid var(--cream-dark);
  border-radius: 5px;
  font-family: 'Lato', sans-serif;
  font-size: 0.9rem;
  background: var(--white);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
}

.gloss-search:focus { border-color: var(--gold); }

/* Accordion */
.gloss-accordion {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.gloss-group-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.9rem;
  background: var(--green-dark);
  color: var(--cream);
  border: none;
  border-radius: 5px;
  font-family: 'Cinzel', serif;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s;
}

.gloss-group-header:hover { background: var(--green-mid); }

.gloss-chevron {
  flex-shrink: 0;
  transition: transform 0.2s;
}

.gloss-group-header[aria-expanded="true"] .gloss-chevron {
  transform: rotate(180deg);
}

.gloss-play-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.2rem 0 0.3rem 0.5rem;
}

.gloss-play-list.is-collapsed { display: none; }

.gloss-play-btn {
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.8rem;
  background: var(--white);
  border: 2px solid transparent;
  border-radius: 4px;
  font-family: 'Lato', sans-serif;
  font-size: 0.85rem;
  color: var(--text);
  cursor: pointer;
  line-height: 1.4;
  transition: border-color 0.15s, background 0.15s;
}

.gloss-play-btn:hover { border-color: var(--gold-light); }

.gloss-play-btn.active {
  border-color: var(--gold);
  background: var(--cream-dark);
  font-weight: 700;
}

.gloss-play-btn.coming-soon {
  opacity: 0.55;
  font-style: italic;
  cursor: pointer;
}

/* === Under Construction Banner === */
.under-construction-banner {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 1rem;
  background: #fdf3dc;
  border: 1px solid var(--gold);
  border-radius: 5px;
  font-size: 0.85rem;
  color: #7a5500;
  line-height: 1.4;
}

/* Player column */
.gloss-player {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.gloss-now-playing {
  font-size: 0.9rem;
  font-style: italic;
  color: var(--text-light);
  min-height: 1.4em;
}

/* === Document Download Cards === */
.doc-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

.doc-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.4rem;
  background: var(--white);
  border: 2px solid var(--cream-dark);
  border-radius: 6px;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
  min-width: 240px;
}

.doc-card:hover {
  border-color: var(--gold);
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.doc-icon {
  color: var(--gold);
  flex-shrink: 0;
}

.doc-info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.doc-info strong {
  font-size: 0.95rem;
  color: var(--green-dark);
}

.doc-info span {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* === Footer === */
footer {
  background: var(--green-dark);
  color: var(--cream-dark);
  text-align: center;
  padding: 2rem;
  font-size: 0.85rem;
}

footer a { color: var(--gold-light); text-decoration: none; }
