@font-face {
  font-family: Khand;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/khand-600.ttf") format("truetype");
}

@font-face {
  font-family: Khand;
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/khand-700.ttf") format("truetype");
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/poppins-400.ttf") format("truetype");
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/poppins-600.ttf") format("truetype");
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/poppins-700.ttf") format("truetype");
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("/fonts/poppins-800.ttf") format("truetype");
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 900;
  font-display: swap;
  src: url("/fonts/poppins-900.ttf") format("truetype");
}

:root {
  --paper: #fbfbf7;
  --paper-strong: #fffdfa;
  --ink: #252326;
  --muted: #665f57;
  --line: #ddd5c5;
  --red: #d9292f;
  --red-dark: #a91d25;
  --blue: #2268b2;
  --yellow: #f3bd2f;
  --olive: #7f8828;
  --turquoise: #51c4c4;
  --shadow: 0 12px 26px rgba(37, 35, 38, 0.13);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: #fbfcfb;
  color: var(--ink);
  font-family: Poppins, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  padding-bottom: calc(24px + var(--safe-bottom));
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.display {
  font-family: Khand, Impact, sans-serif;
  font-weight: 700;
  line-height: 0.9;
}

.app-shell {
  min-height: 100dvh;
  background:
    linear-gradient(180deg, var(--day-bg) 0%, #ffffff 58%, #fbfcfb 100%),
    var(--day-bg);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: calc(12px + var(--safe-top)) 12px 11px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 0;
  box-shadow: 0 6px 18px rgba(37, 35, 38, 0.1);
}

.day-tabs,
.location-tabs {
  display: flex;
  gap: 8px;
  max-width: 760px;
  margin: 0 auto;
  padding-bottom: 8px;
  overflow-x: auto;
  scroll-padding: 16px;
  scrollbar-width: none;
}

.day-tabs {
  padding-bottom: 14px;
}

.day-tabs::-webkit-scrollbar,
.location-tabs::-webkit-scrollbar {
  display: none;
}

.pill {
  flex: none;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
  padding: 8px 15px 7px;
  box-shadow: 0 2px 8px rgba(37, 35, 38, 0.13);
  font-family: Khand, Impact, sans-serif;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.pill[aria-pressed="true"] {
  background: var(--day-accent);
  color: white;
}

.pill.favorite-day-tab {
  background: #c93434;
  color: white;
}

.pill.location {
  border: 2px solid transparent;
  background: var(--location-color);
  color: var(--location-text);
  padding: 7px 12px 6px;
  font-family: Poppins, sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

.pill.location[aria-pressed="true"] {
  border-color: color-mix(in srgb, var(--location-text) 80%, transparent);
  background: var(--location-color);
  color: var(--location-text);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--location-color) 28%, white), 0 4px 13px rgba(37, 35, 38, 0.18);
}

.pill.favorite-location-filter {
  min-width: 42px;
  border-color: #c93434;
  background: white;
  color: #c93434;
  padding-inline: 12px;
  font-size: 15px;
  line-height: 1;
}

.pill.favorite-location-filter[aria-pressed="true"] {
  border-color: #c93434;
  background: white;
  color: #c93434;
  box-shadow: 0 0 0 2px rgba(201, 52, 52, 0.16), 0 3px 10px rgba(37, 35, 38, 0.12);
}

.search-row {
  display: flex;
  gap: 8px;
  max-width: 760px;
  margin: 0 auto 14px;
}

.search-row input {
  min-width: 0;
  width: 100%;
  border: 0;
  border-radius: 999px;
  background: white;
  color: var(--ink);
  padding: 12px 16px;
  font-size: 15px;
  font-weight: 800;
  box-shadow: inset 0 0 0 2px rgba(37, 35, 38, 0.12), 0 2px 8px rgba(37, 35, 38, 0.1);
}

.search-row input::placeholder {
  color: #9a9188;
  font-weight: 600;
}

.clear-btn {
  display: none;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: white;
  padding: 0 13px;
  font-size: 13px;
  font-weight: 800;
}

.clear-btn.visible {
  display: block;
}

main {
  max-width: 760px;
  margin: 14px auto 0;
  border-radius: 24px;
  background: white;
  box-shadow: 0 16px 36px rgba(37, 35, 38, 0.12);
}

.day-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
  padding: 24px 20px 12px;
}

.date-lockup {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 12px;
  row-gap: 4px;
}

.day-name,
.day-number {
  position: relative;
  z-index: 1;
  font-family: Poppins, sans-serif;
  font-size: clamp(32px, 10vw, 56px);
  font-weight: 900;
  line-height: 0.9;
}

.day-number {
  color: var(--day-accent);
}

.day-month {
  flex-basis: 100%;
  margin-top: 0;
  font-family: Khand, Impact, sans-serif;
  font-size: 25px;
  line-height: 0.9;
  text-transform: uppercase;
}

.phase-lockup {
  display: grid;
  justify-items: end;
  gap: 1px;
  padding-top: 4px;
  text-align: right;
}

.phase-lockup strong {
  margin: 0;
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.phase-lockup span,
.phase-lockup em {
  color: var(--ink);
  font-size: 12px;
  font-style: normal;
  font-weight: 500;
  line-height: 1.25;
}

.phase-lockup em {
  margin-top: 8px;
  color: var(--red);
  font-weight: 900;
}

.agenda {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 0 20px 30px;
}

.time-group {
  display: grid;
  gap: 8px;
}

.time-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--red);
  font-family: Khand, Impact, sans-serif;
  font-size: 25px;
  font-weight: 700;
}

.time-label::after {
  content: "";
  height: 2px;
  flex: 1;
  background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--day-accent) 45%, white) 0 7px, transparent 7px 14px);
}

.event-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: stretch;
  width: 100%;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: var(--card-text);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.event-card.is-live {
  outline: 3px solid color-mix(in srgb, var(--accent) 40%, white);
  outline-offset: 3px;
}

.event-main {
  min-width: 0;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 14px 6px 13px 14px;
  text-align: left;
}

.event-main:focus-visible,
.favorite-btn:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: -3px;
}

.event-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-bottom: 3px;
}

.event-title {
  display: block;
  font-family: Poppins, sans-serif;
  font-size: 15px;
  font-weight: 900;
  line-height: 1.2;
  text-transform: uppercase;
}

.event-now {
  flex: none;
  border-radius: 999px;
  background: white;
  color: var(--accent);
  padding: 3px 7px 2px;
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.event-place {
  display: block;
  color: inherit;
  opacity: 1;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.event-ranch {
  font-weight: 900;
}

.favorite-btn {
  display: grid;
  place-items: center;
  align-self: stretch;
  width: 48px;
  border: 0;
  background: transparent;
  color: var(--card-text);
  font-size: 24px;
  line-height: 1;
}

.favorite-btn[aria-pressed="true"] {
  background: transparent;
}

.agenda-day-block {
  display: grid;
  gap: 14px;
}

.agenda-day-title {
  margin: 6px 0 0;
  color: var(--ink);
  font-family: Khand, Impact, sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.empty {
  padding: 60px 24px;
  text-align: center;
  color: var(--muted);
}

.empty strong {
  display: block;
  color: var(--ink);
  font-family: Khand, Impact, sans-serif;
  font-size: 30px;
  font-weight: 700;
}

.site-footer {
  max-width: 760px;
  margin: 0 auto;
  padding: 10px 16px 12px;
  color: color-mix(in srgb, var(--ink) 68%, var(--day-bg));
  text-align: center;
  font-size: 11px;
  line-height: 1.45;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
}

.modal.open {
  display: block;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(29, 29, 28, 0.58);
}

.modal-panel {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(100%, 720px);
  max-height: min(88dvh, 760px);
  transform: translateX(-50%);
  overflow: auto;
  border-radius: 22px 22px 0 0;
  background: white;
  box-shadow: 0 -18px 44px rgba(0, 0, 0, 0.28);
}

.modal-inner {
  padding: 18px 18px calc(22px + var(--safe-bottom));
}

.modal-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: start;
  margin-bottom: 10px;
}

.modal-kicker {
  margin: 0 0 4px;
  color: var(--red-dark);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.modal h2 {
  margin: 0;
  font-family: Poppins, sans-serif;
  font-size: 28px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-transform: uppercase;
}

.artist-media {
  margin: 14px 0 16px;
}

.artist-media img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 18px;
  object-fit: cover;
  background: color-mix(in srgb, var(--accent) 16%, white);
  box-shadow: 0 10px 24px rgba(37, 35, 38, 0.1);
}

.close-btn {
  border: 0;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  background: var(--ink);
  color: white;
  font-size: 24px;
}

.meta-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin: 14px 0;
}

.meta-item {
  border: 0;
  border-radius: 10px;
  background: #f4f5f0;
  padding: 10px 12px;
}

.meta-label {
  display: block;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
}

.meta-value {
  display: block;
  margin-top: 2px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
}

.modal-section {
  margin-top: 18px;
}

.modal-section h3 {
  margin: 0 0 7px;
  text-transform: uppercase;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
}

.modal-section p {
  margin: 0;
  color: #3d3732;
  font-size: 16px;
  line-height: 1.55;
}

.tag-row,
.link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  border-radius: 999px;
  background: white;
  color: var(--ink);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 1px 6px rgba(29, 29, 28, 0.1);
}

.external-link {
  border-radius: 999px;
  background: var(--ink);
  color: white;
  padding: 10px 14px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
}

.source-link {
  color: inherit;
}

@media (min-width: 680px) {
  .topbar {
    padding-left: 18px;
    padding-right: 18px;
  }

  .meta-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .modal-panel {
    top: 50%;
    bottom: auto;
    max-height: min(86dvh, 760px);
    border-radius: 22px;
    transform: translate(-50%, -50%);
  }
}

@media (max-width: 520px) {
  body {
    padding-bottom: calc(16px + var(--safe-bottom));
  }

  .topbar {
    padding: calc(10px + var(--safe-top)) 8px 9px;
  }

  .day-tabs,
  .location-tabs {
    gap: 7px;
    padding-bottom: 7px;
    scroll-padding: 10px;
  }

  .day-tabs {
    padding-bottom: 12px;
  }

  .pill {
    padding: 6px 11px 5px;
    font-size: 17px;
  }

  .pill.location {
    padding: 6px 10px 5px;
    font-size: 11px;
  }

  .pill.favorite-location-filter {
    min-width: 38px;
    padding-inline: 10px;
    font-size: 14px;
  }

  .search-row {
    gap: 7px;
    margin-bottom: 12px;
  }

  .search-row input {
    padding: 11px 14px;
    font-size: 14px;
  }

  .clear-btn {
    padding: 0 11px;
    font-size: 12px;
  }

  main {
    margin: 10px 8px 0;
    border-radius: 18px;
  }

  .day-heading {
    gap: 8px;
    padding: 18px 14px 10px;
  }

  .date-lockup {
    column-gap: 9px;
    row-gap: 3px;
  }

  .day-name,
  .day-number {
    font-size: clamp(24px, 8vw, 32px);
  }

  .day-month {
    font-size: 19px;
  }

  .phase-lockup strong {
    font-size: 13px;
  }

  .phase-lockup span,
  .phase-lockup em {
    font-size: 10px;
  }

  .agenda {
    gap: 12px;
    padding: 0 12px 22px;
  }

  .time-label {
    font-size: 23px;
  }

  .event-main {
    padding: 12px 4px 12px 12px;
  }

  .event-title {
    font-size: 14px;
  }

  .event-now {
    font-size: 9px;
  }

  .event-place {
    font-size: 11px;
  }

  .favorite-btn {
    width: 44px;
    font-size: 23px;
  }

  .agenda-day-title {
    font-size: 25px;
  }

  .modal-inner {
    padding: 16px 16px calc(20px + var(--safe-bottom));
  }

  .modal h2 {
    font-size: 24px;
  }

  .artist-media img {
    border-radius: 14px;
  }

  .meta-value {
    font-size: 14px;
  }

  .modal-section p {
    font-size: 15px;
  }
}
