/* ============================================================
   Both Days · weekend guide
   Radius rule: buttons and tags are full pills; inputs, images
   and surfaces use 12px. One accent (rust). One theme per mode.
   ============================================================ */

@font-face {
  font-family: "Space Grotesk";
  src: url("assets/space-grotesk.ttf") format("truetype");
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("assets/work-sans.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/ibm-plex-mono.ttf") format("truetype");
  font-weight: 400 600;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --bg: #f3f2ef;
  --surface: #fcfcfb;
  --ink: #1d1b18;
  --ink-2: #615e58;
  --line: #dcdad3;
  --accent: #a93c17;
  --accent-hover: #8c3012;
  --on-accent: #fcfbfa;
  --scrim: rgba(29, 27, 24, 0.45);
  --pill: 999px;
  --r: 12px;
  --sans: "Work Sans", system-ui, sans-serif;
  --disp: "Space Grotesk", var(--sans);
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #191816;
    --surface: #222020;
    --ink: #edebe6;
    --ink-2: #a8a49c;
    --line: #3a3733;
    --accent: #e5703f;
    --accent-hover: #ef8356;
    --on-accent: #1d1b18;
    --scrim: rgba(10, 9, 8, 0.6);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { display: block; }

.wrap {
  max-width: 1060px;
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 32px);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.sr {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip {
  position: absolute;
  left: 12px; top: -48px;
  z-index: 60;
  background: var(--ink);
  color: var(--bg);
  padding: 10px 16px;
  border-radius: var(--pill);
  text-decoration: none;
  font-size: 14px;
  transition: top 0.15s ease;
}
.skip:focus { top: 12px; }

/* ---------- top bar ---------- */

.top { border-bottom: 1px solid var(--line); }
.top-in {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-block: 18px;
}
.brand {
  font-family: var(--disp);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}
.brand-dot { color: var(--accent); }
.top-dates {
  margin: 0;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  letter-spacing: 0.02em;
}

/* ---------- hero ---------- */

.hero-in {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: end;
  padding-block: 44px 34px;
}
.hero h1, .hero-copy h1 {
  margin: 0 0 12px;
  font-family: var(--disp);
  font-weight: 600;
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  line-height: 1.04;
  letter-spacing: -0.025em;
  max-width: 13ch;
}
.hero-sub {
  margin: 0;
  max-width: 46ch;
  color: var(--ink-2);
  font-size: 16px;
}
.hero-photos {
  display: grid;
  grid-template-columns: 150px 104px;
  gap: 10px;
  align-items: end;
}
.hero-photos img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: var(--r);
}
.hero-photos img:last-child { height: 112px; }

/* ---------- toolbar ---------- */

.toolbar-band {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.toolbar {
  display: flex;
  align-items: end;
  gap: 14px;
  padding-block: 12px;
  flex-wrap: wrap;
}
.field { display: flex; flex-direction: column; gap: 5px; }
.field label, .field-label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-2);
}
.field-search { flex: 1 1 240px; }
.field-cat { flex: 0 1 200px; }

.field input,
.field select {
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 9px 14px;
  width: 100%;
  transition: border-color 0.15s ease;
}
.field input::placeholder { color: var(--ink-2); opacity: 1; }
.field input:hover, .field select:hover { border-color: var(--ink-2); }
.field input:focus-visible, .field select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.field-saved { margin-left: auto; }
#saved-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 9px 16px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
#saved-filter svg {
  width: 15px; height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}
#saved-filter:hover { border-color: var(--ink-2); }
#saved-filter[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}
#saved-filter[aria-pressed="true"] svg { fill: currentColor; stroke: none; }
#saved-filter:active { transform: translateY(1px); }

/* ---------- count + day groups ---------- */

.count {
  margin: 18px 0 2px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
}

.day { margin-top: 26px; }
.day-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 4px;
}
.day-head h2 {
  margin: 0;
  font-family: var(--disp);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.01em;
}
.day-head .day-date {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
}
.day-head::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--line);
  transform: translateY(-4px);
}

/* ---------- event rows ---------- */

.rows { list-style: none; margin: 0; padding: 0; }

.row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px 10px;
  border-bottom: 1px solid var(--line);
  transition: background 0.15s ease;
}
.row:hover { background: var(--surface); }

.row .thumb {
  width: 56px; height: 56px;
  object-fit: cover;
  border-radius: 8px;
}

.row-open {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  text-align: left;
  cursor: pointer;
  font-family: var(--disp);
  font-weight: 500;
  font-size: 17.5px;
  line-height: 1.3;
  letter-spacing: -0.005em;
  color: var(--ink);
}
.row-open:hover { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
.row-open:active { transform: translateY(1px); }
.row-open:focus-visible { outline-offset: 3px; }

.row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin-top: 5px;
  font-size: 13px;
  color: var(--ink-2);
}
.tag {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 2.5px 9px;
  background: var(--surface);
}
.row-meta time, .row-meta .row-time { font-family: var(--mono); font-size: 12px; }
.row-venue { white-space: nowrap; }

.row-end {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: end;
}
.price {
  font-family: var(--mono);
  font-size: 13px;
  min-width: 44px;
  text-align: right;
}
.price.free { color: var(--accent); font-weight: 600; }

.quick-save {
  appearance: none;
  width: 38px; height: 38px;
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--pill);
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.quick-save svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.quick-save:hover { border-color: var(--ink-2); color: var(--ink); }
.quick-save:active { transform: translateY(1px); }
.quick-save[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}
.quick-save[aria-pressed="true"] svg { fill: currentColor; stroke: none; }

/* ---------- empty state ---------- */

.empty {
  padding: 72px 24px 84px;
  text-align: center;
}
.empty-kicker {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
  margin: 0 0 10px;
}
.empty h2 {
  margin: 0 0 10px;
  font-family: var(--disp);
  font-weight: 600;
  font-size: 26px;
  letter-spacing: -0.01em;
}
.empty p {
  margin: 0 auto 22px;
  max-width: 44ch;
  color: var(--ink-2);
}
#clear-filters {
  appearance: none;
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  background: var(--accent);
  color: var(--on-accent);
  border: 1px solid var(--accent);
  border-radius: var(--pill);
  padding: 11px 22px;
  cursor: pointer;
  transition: background 0.15s ease;
}
#clear-filters:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
#clear-filters:active { transform: translateY(1px); }

/* ---------- footer ---------- */

.foot {
  margin-top: 56px;
  border-top: 1px solid var(--line);
}
.foot-in { padding-block: 26px; }
.foot p { margin: 0; font-size: 13.5px; color: var(--ink-2); }
.brand-foot { font-family: var(--disp); font-weight: 600; color: var(--ink); }

/* ---------- detail panel ---------- */

.scrim {
  position: fixed;
  inset: 0;
  z-index: 30;
  background: var(--scrim);
  opacity: 0;
  transition: opacity 0.22s ease;
}
.scrim.open { opacity: 1; }

.panel {
  position: fixed;
  top: 0; right: 0;
  z-index: 40;
  height: 100dvh;
  width: min(460px, 100%);
  background: var(--surface);
  border-left: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  transform: translateX(102%);
  transition: transform 0.26s cubic-bezier(0.16, 1, 0.3, 1);
}
.panel.open { transform: translateX(0); }

.panel-top {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: flex-end;
}
.panel-close {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font: inherit;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 8px 15px;
  cursor: pointer;
  transition: border-color 0.15s ease;
}
.panel-close svg { width: 14px; height: 14px; }
.panel-close:hover { border-color: var(--ink-2); }
.panel-close:active { transform: translateY(1px); }

.panel-body {
  overflow-y: auto;
  padding: 22px clamp(18px, 4vw, 28px) 32px;
}

.panel-photo {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: var(--r);
  margin-bottom: 18px;
}

.panel-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.chip {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 4px 11px;
  color: var(--ink-2);
}
.chip.accent {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}

.panel h2 {
  margin: 0 0 16px;
  font-family: var(--disp);
  font-weight: 600;
  font-size: 27px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.facts { margin: 0 0 20px; }
.facts > div {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 12px;
  padding-block: 9px;
  border-top: 1px solid var(--line);
}
.facts dt {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding-top: 3px;
}
.facts dd { margin: 0; font-size: 14.5px; }

.panel-desc { margin: 0 0 20px; }
.panel-desc p { margin: 0 0 12px; font-size: 15px; line-height: 1.65; }
.panel-desc p:last-child { margin-bottom: 0; }

.access {
  background: var(--bg);
  border-radius: var(--r);
  padding: 14px 16px;
  margin-bottom: 22px;
}
.access h3 {
  margin: 0 0 5px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
  font-weight: 600;
}
.access p { margin: 0; font-size: 14px; line-height: 1.55; }

.save-btn {
  appearance: none;
  width: 100%;
  font: inherit;
  font-size: 15.5px;
  font-weight: 600;
  border-radius: var(--pill);
  padding: 13px 20px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.save-btn:active { transform: translateY(1px); }
.save-btn[aria-pressed="false"] {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: var(--on-accent);
}
.save-btn[aria-pressed="false"]:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.save-btn[aria-pressed="true"] {
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
}
.save-btn[aria-pressed="true"]:hover { background: var(--accent); color: var(--on-accent); }

/* ---------- responsive ---------- */

@media (max-width: 760px) {
  .hero-in {
    grid-template-columns: 1fr;
    gap: 22px;
    padding-block: 30px 24px;
  }
  .hero-photos { order: -1; grid-template-columns: 1fr 1fr; }
  .hero-photos img, .hero-photos img:last-child { height: 108px; }
  .hero-copy h1 { max-width: none; }

  .toolbar-band { position: static; }
  .toolbar { align-items: stretch; }
  .field-search, .field-cat { flex: 1 1 100%; }
  .field-saved { margin-left: 0; }
  #saved-filter { width: 100%; justify-content: center; }

  .row { grid-template-columns: 48px minmax(0, 1fr); gap: 12px; }
  .row .thumb { width: 48px; height: 48px; }
  .row-end {
    grid-column: 2;
    justify-self: start;
    margin-top: 2px;
  }
  .price { text-align: left; min-width: 0; }

  .panel { width: 100%; border-left: 0; }
  .panel-photo { height: 160px; }
}

/* ---------- motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
