/* ============================================================
   Living the Goood Life — Festival Guide styles
   ============================================================ */

@font-face {
  font-family: "Fredoka";
  src: url("fonts/Fredoka-Variable.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Nunito Sans";
  src: url("fonts/NunitoSans-Variable.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --brown: #825740;
  --brown-dark: #5e3e2c;
  --olive: #485342;
  --olive-dark: #2f3a29;
  --rust: #cb5323;
  --maroon: #7a2e3f;
  --cream: #faf1e2;
  --cream-2: #f3e6cf;
  --ink: #2a2118;
  --white: #ffffff;

  --font-heading: "Fredoka", "Baloo 2", system-ui, sans-serif;
  --font-body: "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --shadow: 0 6px 20px rgba(46, 30, 18, 0.12);
  --tabbar-h: 72px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}


h1, h2, h3, .heading {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--brown-dark);
  margin: 0 0 8px;
}

a { color: var(--rust); }
img { max-width: 100%; display: block; }
button { font-family: inherit; }

.muted { color: #6b5d4f; }
.muted.small { font-size: 0.85rem; }

/* ---------- Layout helpers ---------- */
.view { min-height: 100%; }
.section { padding: 28px 20px; }
.section__title { font-size: 1.4rem; margin-bottom: 14px; }

.page-header {
  padding: 28px 20px 4px;
}
.page-header h1 {
  font-size: 1.8rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 20px;
  border-radius: 999px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  min-height: 48px;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.btn:active { transform: scale(0.97); }
.btn--primary { background: var(--rust); color: var(--white); }
.btn--outline { background: transparent; color: var(--brown-dark); border-color: var(--brown); }
.btn--outline:active { background: rgba(130, 87, 64, 0.08); }
.btn[disabled] { opacity: 0.6; pointer-events: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  height: 62vh;
  min-height: 380px;
  max-height: 620px;
  overflow: hidden;
  color: var(--white);
}
.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.farm-map-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  margin-bottom: 12px;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  text-align: center;
  padding: 24px 20px 32px;
  background: linear-gradient(180deg, rgba(47,58,41,0.15) 0%, rgba(42,33,24,0.15) 40%, rgba(42,33,24,0.85) 100%);
}
.hero__eyebrow {
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  margin: 0 0 6px;
  opacity: 0.9;
}
.hero__title {
  font-size: clamp(1.5rem, 8.2vw, 2.6rem);
  line-height: 1.05;
  color: var(--cream);
  margin: 0;
  white-space: nowrap;
  text-shadow: 0 2px 10px rgba(0,0,0,0.25);
}
.hero__edition {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  color: var(--rust);
  background: var(--cream);
  display: inline-block;
  padding: 4px 18px;
  border-radius: 999px;
  margin: 12px 0 6px;
  font-weight: 600;
}
.hero__dates {
  margin: 4px 0 0;
  font-size: 1.05rem;
  font-weight: 600;
}

/* ---------- Countdown ---------- */
.countdown-section { padding-top: 24px; padding-bottom: 8px; }
.countdown {
  background: var(--olive-dark);
  color: var(--cream);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow);
}
.countdown__label {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  opacity: 0.85;
  margin-bottom: 12px;
}
.countdown__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.countdown__cell {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.countdown__num {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--white);
}
.countdown__unit {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.75;
  margin-top: 2px;
}
.countdown.is-live .countdown__label::after { content: " 🎉"; }

/* ---------- Quick actions ---------- */
.quick-actions {
  display: flex;
  gap: 10px;
  padding-top: 6px;
  padding-bottom: 6px;
  flex-wrap: wrap;
}
.quick-actions .btn { flex: 1 1 auto; min-width: 100px; }

/* ---------- Cards ---------- */
.about-section { padding-top: 20px; padding-bottom: 8px; }
.about-text {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--brown-dark);
  margin: 0;
  text-align: center;
}

.arrive-list {
  margin: 14px 0 0;
  padding-left: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.arrive-list li {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--ink);
  padding-left: 4px;
}
.arrive-list a { color: var(--rust); font-weight: 600; text-decoration: underline; }

.card-stack { display: flex; flex-direction: column; gap: 12px; }
.card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow);
}
.card h3 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}
.card p { margin: 0; font-size: 0.93rem; }

/* ---------- Now / Next ---------- */
.now-next { display: flex; flex-direction: column; gap: 10px; }
.now-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  border-left: 5px solid var(--rust);
}
.now-card.is-next { border-left-color: var(--olive); opacity: 0.9; }
.now-card__tag {
  font-family: var(--font-heading);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--rust);
}
.now-card.is-next .now-card__tag { color: var(--olive); }
.now-card__title { font-weight: 700; font-size: 1rem; margin: 4px 0 2px; }
.now-card__meta { font-size: 0.85rem; color: #6b5d4f; }
.empty-state { padding: 12px 4px; color: #6b5d4f; font-size: 0.92rem; }

/* ---------- Gallery ---------- */
.gallery__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.gallery__header .section__title { margin-bottom: 0; }
.gallery__arrows { display: flex; gap: 8px; }
.gallery__arrow {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--brown);
  background: var(--white);
  color: var(--brown);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}
.gallery__arrow:active { background: var(--cream-2); }
.gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.gallery img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--cream-2);
}

/* ---------- Backups ---------- */
.backup-buttons { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.backup-buttons .btn { flex: 1 1 auto; }

/* ---------- Day tabs / area filter (Lineup) ---------- */
.music-status {
  margin: 4px 20px 18px;
  background: var(--cream-2);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}
.music-status strong { font-family: var(--font-heading); color: var(--brown-dark); display: block; margin-bottom: 4px; }
.music-status p { margin: 0; font-size: 0.9rem; }

.day-tabs {
  display: flex;
  gap: 8px;
  padding: 0 20px 10px;
  overflow-x: auto;
}
.day-tabs__btn {
  font-family: var(--font-heading);
  font-weight: 600;
  border: none;
  background: var(--cream-2);
  color: var(--brown-dark);
  padding: 10px 18px;
  border-radius: 999px;
  white-space: nowrap;
  cursor: pointer;
}
.day-tabs__btn.is-active { background: var(--brown); color: var(--white); }

.area-filter {
  display: flex;
  gap: 8px;
  padding: 0 20px 16px;
  overflow-x: auto;
}
.area-filter__btn {
  font-size: 0.82rem;
  border: 1.5px solid var(--olive);
  color: var(--olive-dark);
  background: transparent;
  padding: 6px 14px;
  border-radius: 999px;
  white-space: nowrap;
  cursor: pointer;
}
.area-filter__btn.is-active { background: var(--olive); color: var(--white); border-color: var(--olive); }

.area-info {
  margin: 0 20px 16px;
  background: var(--cream-2);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}
.area-info strong { font-family: var(--font-heading); color: var(--brown-dark); display: block; margin-bottom: 4px; }
.area-info p { margin: 0; font-size: 0.9rem; }

.lineup-list { padding: 0 20px 20px; display: flex; flex-direction: column; gap: 10px; }
.my-schedule-day-heading {
  margin: 18px 0 -2px;
  font-size: 1.1rem;
}
.my-schedule-day-heading:first-child { margin-top: 0; }
.lineup-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 14px 14px;
  box-shadow: var(--shadow);
  position: relative;
}
.lineup-item.is-live { border-left: 5px solid var(--rust); }
.lineup-item__time {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--brown-dark);
  min-width: 68px;
  font-size: 0.85rem;
  padding-top: 2px;
}
.lineup-item__body { flex: 1; }
.lineup-item__title { font-weight: 700; font-size: 1rem; margin-bottom: 2px; }
.kind-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-right: 7px;
  vertical-align: middle;
}
.kind-dot--live { background: var(--olive); }
.kind-dot--dj { background: var(--brown); }
.kind-dot--session { background: var(--maroon); }
.lineup-legend {
  display: flex;
  gap: 16px;
  font-size: 0.85rem;
  color: #6b5d4f;
  margin: 4px 0 14px;
  padding: 0 20px;
}
.lineup-legend span { display: inline-flex; align-items: center; }
.lineup-item__area { font-size: 0.82rem; color: var(--rust); font-weight: 600; }
.lineup-item__note { font-size: 0.8rem; color: #7a6c5c; margin-top: 4px; }
.lineup-item.has-desc .lineup-item__body { cursor: pointer; }
.lineup-item__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.lineup-item__expand {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: none;
  background: none;
  padding: 0;
  color: var(--rust);
  cursor: pointer;
  opacity: 0.7;
}
.lineup-item__expand:active { opacity: 1; }
.expand-icon { position: absolute; inset: 0; width: 16px; height: 16px; margin: auto; transition: opacity 0.15s ease; }
.expand-icon--minus { opacity: 0; }
.lineup-item.is-expanded .expand-icon--chevron { opacity: 0; }
.lineup-item.is-expanded .expand-icon--minus { opacity: 1; }
.lineup-item.is-expanded .lineup-item__expand { opacity: 1; }
.lineup-item__desc {
  font-size: 0.85rem;
  color: #4a3d31;
  margin-top: 6px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}
.lineup-item.is-expanded .lineup-item__desc { max-height: 300px; }
.lineup-item__live-badge {
  font-size: 0.68rem;
  font-family: var(--font-heading);
  background: var(--rust);
  color: var(--white);
  padding: 2px 8px;
  border-radius: 999px;
  margin-left: 6px;
  vertical-align: middle;
}
.heart-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  display: inline-flex;
  flex-shrink: 0;
}
.heart-icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--brown);
  stroke-width: 1.6;
  opacity: 0.55;
}
.heart-btn.is-hearted .heart-icon {
  fill: var(--maroon);
  stroke: var(--maroon);
  opacity: 1;
}

/* ---------- FAQ / accordion ---------- */
.accordion { display: flex; flex-direction: column; gap: 8px; }
.accordion__item {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.accordion__btn {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 14px 16px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--brown-dark);
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}
.accordion__btn::after {
  content: "+";
  font-size: 1.3rem;
  color: var(--rust);
  margin-left: 10px;
  transition: transform 0.2s ease;
}
.accordion__item.is-open .accordion__btn::after { transform: rotate(45deg); }
.accordion__panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
  padding: 0 16px;
  font-size: 0.92rem;
  color: #4a3d31;
}
.accordion__item.is-open .accordion__panel {
  max-height: 400px;
  padding-bottom: 16px;
}

/* ---------- Check list / rules ---------- */
.check-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.check-list li {
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  box-shadow: var(--shadow);
  font-size: 0.92rem;
}

.rules-section { background: var(--cream-2); border-radius: var(--radius-lg); margin: 0 20px; padding: 20px; }
.rules-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.rules-list li {
  font-size: 0.92rem;
  padding-left: 26px;
  position: relative;
}
.rules-list li::before {
  content: "⚠";
  position: absolute;
  left: 0;
  color: var(--rust);
}

/* ---------- Contact list ---------- */
.contact-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.contact-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  box-shadow: var(--shadow);
  text-decoration: none;
  font-size: 0.92rem;
  color: var(--ink);
}
.contact-list a strong { color: var(--brown-dark); font-family: var(--font-heading); font-weight: 600; }

/* ---------- Tab bar ---------- */
.tabbar {
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--tabbar-h) + var(--safe-b));
  padding-bottom: var(--safe-b);
  background: var(--white);
  border-top: 1px solid rgba(130,87,64,0.15);
  display: flex;
  z-index: 100;
  box-shadow: 0 -4px 14px rgba(46,30,18,0.08);
}
.tabbar__btn {
  flex: 1;
  border: none;
  background: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: 0.72rem;
  color: #8a7a68;
  cursor: pointer;
  padding: 6px 2px;
}
.tabbar__icon { display: flex; line-height: 1; }
.tabbar__icon svg { width: 22px; height: 22px; }
.tabbar__btn.is-active { color: var(--rust); font-weight: 700; }

/* ---------- Banners ---------- */
.offline-banner, .update-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 150;
  text-align: center;
  font-size: 0.82rem;
  padding: 8px 16px;
  padding-top: max(8px, env(safe-area-inset-top));
}
.offline-banner { background: var(--olive-dark); color: var(--cream); }
.update-banner { background: var(--rust); color: var(--white); }
.update-banner button {
  background: rgba(255,255,255,0.2);
  border: none;
  color: var(--white);
  border-radius: 999px;
  padding: 3px 10px;
  margin-left: 8px;
  font-weight: 700;
  cursor: pointer;
}

/* ---------- Desktop ---------- */
@media (min-width: 860px) {
  body { padding-bottom: 24px; }
  .tabbar { display: none; }

  .view {
    max-width: 900px;
    margin: 0 auto;
  }
  .gallery { grid-template-columns: repeat(4, 1fr); }
  .hero { border-radius: 0 0 28px 28px; overflow: hidden; }
}

.top-nav {
  display: none;
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--cream);
  border-bottom: 1px solid rgba(130,87,64,0.15);
  padding: 14px 24px;
  align-items: center;
  grid-template-columns: 1fr auto 1fr;
}
@media (min-width: 860px) {
  .top-nav { display: grid; }
}
.top-nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--brown-dark);
  font-size: 1.1rem;
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
  justify-self: start;
}
.top-nav__logo { height: 30px; width: auto; }
.top-nav__links { display: flex; gap: 6px; justify-self: center; }
.top-nav__links button {
  border: none;
  background: none;
  font-family: var(--font-heading);
  font-weight: 600;
  color: #8a7a68;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
}
.top-nav__links button.is-active { background: var(--brown); color: var(--white); }
