@font-face {
  font-family: "DM Serif Display";
  src: url("assets/dm-serif.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Work Sans";
  src: url("assets/work-sans.ttf") format("truetype");
  font-display: swap;
}

:root {
  --ink: #14213d;
  --ink-soft: #465064;
  --paper: #f3efe6;
  --paper-raised: #fffdf8;
  --line: #c9c2b6;
  --orange: #ed5d36;
  --orange-dark: #b93617;
  --chartreuse: #c8df53;
  --blue: #9fc7ec;
  --pink: #e9a0ad;
  --lavender: #c6b8e9;
  --gold: #e7bc51;
  --mint: #94cfb4;
  --focus: #005fcc;
  --display: "DM Serif Display", Georgia, serif;
  --sans: "Work Sans", Arial, sans-serif;
  --ease: 180ms ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
}

button,
input,
select {
  color: inherit;
  font: inherit;
}

button,
select,
a {
  touch-action: manipulation;
}

button,
select {
  cursor: pointer;
}

a {
  color: inherit;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 12px 16px;
  background: var(--ink);
  color: #fff;
  transform: translateY(-150%);
  transition: transform var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 82px;
  padding: 16px clamp(24px, 4vw, 64px);
  border-bottom: 1px solid var(--ink);
}

.brand {
  display: inline-flex;
  width: max-content;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-decoration: none;
}

.brand svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.issue {
  margin: 0;
  color: var(--ink-soft);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.issue span {
  margin: 0 7px;
  color: var(--orange-dark);
}

.header-link {
  justify-self: end;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: .84rem;
  font-weight: 650;
  text-underline-offset: 4px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(420px, .95fr);
  min-height: 620px;
  overflow: hidden;
  border-bottom: 1px solid var(--ink);
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 72px clamp(24px, 5.7vw, 88px);
}

.eyebrow {
  margin: 0 0 25px;
  font-size: .73rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.eyebrow span {
  margin-left: 16px;
  padding-left: 17px;
  border-left: 1px solid var(--orange);
  color: var(--ink-soft);
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin-top: 0;
}

h1 {
  max-width: 780px;
  margin-bottom: 30px;
  font-family: var(--display);
  font-size: clamp(4.4rem, 7.4vw, 7.2rem);
  font-weight: 400;
  letter-spacing: -.055em;
  line-height: .85;
}

h1 em {
  color: var(--orange-dark);
  font-weight: 400;
}

.hero-intro {
  max-width: 590px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
  line-height: 1.7;
}

.hero-art {
  display: grid;
  place-items: center;
  min-width: 0;
  padding: 58px clamp(30px, 5vw, 70px);
  background: var(--chartreuse);
  border-left: 1px solid var(--ink);
}

.hero-art svg {
  width: 100%;
  max-width: 570px;
  overflow: visible;
}

.hero-art .sun {
  fill: var(--orange);
  stroke: var(--ink);
  stroke-width: 2;
}

.hero-art .river {
  fill: var(--blue);
  stroke: var(--ink);
  stroke-width: 2;
}

.hero-art .route {
  fill: none;
  stroke: var(--ink);
  stroke-dasharray: 2 10;
  stroke-linecap: round;
  stroke-width: 3;
}

.hero-art .route-dot,
.hero-art .spark {
  fill: var(--paper);
  stroke: var(--ink);
  stroke-width: 2;
}

.hero-art text {
  fill: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 5px;
  text-anchor: middle;
}

.weekend-stamp {
  position: absolute;
  right: clamp(18px, 3vw, 48px);
  bottom: 24px;
  display: flex;
  width: 122px;
  height: 122px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--paper);
  transform: rotate(7deg);
  text-align: center;
  text-transform: uppercase;
}

.weekend-stamp span {
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .15em;
}

.weekend-stamp strong {
  font-family: var(--display);
  font-size: 2.4rem;
  font-weight: 400;
  line-height: .95;
}

.browse {
  max-width: 1440px;
  margin: 0 auto;
  padding: 88px clamp(24px, 4vw, 64px) 112px;
}

.browse-heading {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  align-items: end;
  gap: 48px;
  margin-bottom: 50px;
}

.browse-heading .eyebrow {
  margin-bottom: 10px;
  color: var(--orange-dark);
}

.browse-heading h2 {
  margin-bottom: 0;
  font-family: var(--display);
  font-size: clamp(3.2rem, 5.5vw, 5.2rem);
  font-weight: 400;
  letter-spacing: -.045em;
  line-height: .95;
}

.browse-heading > p {
  max-width: 480px;
  margin: 0 0 7px;
  color: var(--ink-soft);
  line-height: 1.65;
}

.toolbox {
  display: grid;
  grid-template-columns: minmax(300px, 1.5fr) minmax(210px, .8fr) minmax(190px, .5fr);
  border: 1px solid var(--ink);
  background: var(--paper-raised);
}

.search-field,
.filter-field {
  padding: 15px 20px 13px;
  border-right: 1px solid var(--ink);
}

.toolbox label {
  display: block;
  margin-bottom: 2px;
  font-size: .67rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.input-wrap,
.select-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrap > svg,
.select-wrap > svg {
  position: absolute;
  width: 21px;
  height: 21px;
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.7;
  pointer-events: none;
}

.input-wrap > svg {
  left: 0;
}

.select-wrap > svg {
  right: 0;
}

input,
select {
  width: 100%;
  height: 42px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: .95rem;
  font-weight: 550;
}

input {
  padding: 0 6px 0 32px;
}

input::placeholder {
  color: #68717f;
  opacity: 1;
}

select {
  appearance: none;
  padding: 0 31px 0 0;
}

.saved-toggle {
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 20px;
  border: 0;
  background: var(--ink);
  color: #fff;
  font-size: .86rem;
  font-weight: 650;
  transition: background var(--ease), color var(--ease);
}

.saved-toggle svg,
.save-item svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.saved-toggle:hover {
  background: #263657;
}

.saved-toggle[aria-pressed="true"] {
  background: var(--orange);
  color: var(--ink);
}

.saved-count {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: .68rem;
}

.results-bar {
  display: flex;
  min-height: 78px;
  align-items: center;
  gap: 20px;
}

.results-count {
  margin: 0;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.rule {
  height: 1px;
  flex: 1;
  background: var(--line);
}

.reset-button {
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: var(--orange-dark);
  font-size: .78rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.event-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.event-card {
  position: relative;
  display: grid;
  grid-template-columns: 155px minmax(0, 1fr);
  min-height: 300px;
  overflow: hidden;
  border: 1px solid var(--ink);
  background: var(--paper-raised);
  transition: background var(--ease);
}

.event-card:hover {
  background: #fff;
}

.card-visual {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  border-right: 1px solid var(--ink);
  background: var(--category-color, var(--blue));
}

.card-number {
  font-family: var(--display);
  font-size: 3.8rem;
  line-height: .8;
}

.card-sigil {
  width: 88px;
  height: 88px;
  align-self: center;
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.5;
}

.card-content {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 22px 24px 20px;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.category-label,
.day-label {
  font-size: .65rem;
  font-weight: 750;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.day-label {
  color: var(--ink-soft);
}

.saved-mark {
  position: absolute;
  top: 14px;
  right: 14px;
  display: none;
  width: 31px;
  height: 31px;
  place-items: center;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--paper);
}

.saved-mark svg {
  width: 15px;
  fill: var(--ink);
}

.event-card.is-saved .saved-mark {
  display: grid;
}

.event-card h3 {
  margin-bottom: 12px;
  font-family: var(--display);
  font-size: clamp(1.55rem, 2vw, 2rem);
  font-weight: 400;
  letter-spacing: -.025em;
  line-height: 1.03;
}

.card-summary {
  display: -webkit-box;
  margin: 0 0 24px;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: .83rem;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.card-footer {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.card-meta {
  margin: 0;
  color: var(--ink-soft);
  font-size: .7rem;
  line-height: 1.55;
}

.card-meta strong {
  display: block;
  color: var(--ink);
  font-weight: 700;
}

.open-item {
  display: inline-flex;
  min-width: 104px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 14px;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-size: .72rem;
  font-weight: 700;
  transition: background var(--ease), color var(--ease);
}

.open-item svg {
  width: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.open-item:hover,
.open-item:active {
  background: var(--ink);
  color: #fff;
}

.empty-state {
  padding: 72px 24px;
  border: 1px solid var(--ink);
  background: var(--paper-raised);
  text-align: center;
}

.empty-state svg {
  width: 62px;
  fill: none;
  stroke: var(--orange-dark);
  stroke-width: 1.5;
}

.empty-state h3 {
  margin: 17px 0 8px;
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 400;
}

.empty-state p {
  max-width: 440px;
  margin: 0 auto 24px;
  color: var(--ink-soft);
}

.empty-reset {
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  font-weight: 650;
}

footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 30px;
  min-height: 150px;
  padding: 32px clamp(24px, 4vw, 64px);
  border-top: 1px solid var(--ink);
  background: var(--chartreuse);
}

.footer-brand {
  font-size: 1.5rem;
}

footer p {
  margin: 0;
  font-family: var(--display);
  font-size: 1.4rem;
  text-align: center;
}

.footer-note {
  justify-self: end;
  font-family: var(--sans);
  font-size: .67rem;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.detail-dialog {
  width: min(1010px, calc(100vw - 48px));
  max-width: none;
  max-height: min(800px, calc(100dvh - 48px));
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
}

.detail-dialog::backdrop {
  background: rgb(20 33 61 / 74%);
}

.detail-shell {
  position: relative;
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  min-height: 640px;
  max-height: calc(100dvh - 50px);
  overflow: auto;
}

.close-detail {
  position: absolute;
  z-index: 2;
  top: 18px;
  right: 18px;
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid var(--ink);
  background: var(--paper-raised);
  font-size: .72rem;
  font-weight: 700;
  transition: background var(--ease), color var(--ease);
}

.close-detail:hover {
  background: var(--ink);
  color: #fff;
}

.close-detail svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.detail-visual {
  position: relative;
  display: flex;
  min-height: 640px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 55px;
  border-right: 1px solid var(--ink);
  background: var(--category-color, var(--blue));
}

.detail-visual::before,
.detail-visual::after {
  position: absolute;
  width: 200px;
  height: 200px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  content: "";
}

.detail-visual::before {
  top: -112px;
  left: -72px;
}

.detail-visual::after {
  right: -102px;
  bottom: -78px;
}

.detail-number {
  position: absolute;
  top: 26px;
  left: 30px;
  font-family: var(--display);
  font-size: 5rem;
  line-height: 1;
}

.detail-mark {
  width: min(230px, 70%);
  fill: var(--paper);
  stroke: var(--ink);
  stroke-width: 1.2;
}

.detail-category {
  position: absolute;
  bottom: 25px;
  left: 30px;
  margin: 0;
  font-size: .7rem;
  font-weight: 750;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.detail-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 88px clamp(38px, 5vw, 70px) 54px;
}

.detail-kicker {
  margin: 0 0 18px;
  color: var(--orange-dark);
  font-size: .68rem;
  font-weight: 750;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.detail-kicker span:first-child {
  margin: 0 5px;
}

.detail-content h2 {
  max-width: 570px;
  margin-bottom: 25px;
  font-family: var(--display);
  font-size: clamp(2.6rem, 4.2vw, 4rem);
  font-weight: 400;
  letter-spacing: -.04em;
  line-height: .96;
}

.detail-body {
  max-width: 610px;
  color: var(--ink-soft);
  font-size: .92rem;
  line-height: 1.65;
}

.detail-body p {
  margin: 0 0 12px;
}

.detail-body p:last-child {
  padding-left: 15px;
  border-left: 3px solid var(--orange);
  color: var(--ink);
}

.fact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 27px 0 28px;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.fact-grid div {
  min-width: 0;
  padding: 14px 16px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.fact-grid dt {
  margin-bottom: 3px;
  color: var(--ink-soft);
  font-size: .6rem;
  font-weight: 750;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.fact-grid dd {
  margin: 0;
  font-size: .8rem;
  font-weight: 600;
}

.save-item {
  display: flex;
  width: 100%;
  min-height: 54px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  font-size: .82rem;
  font-weight: 700;
  transition: background var(--ease), color var(--ease);
}

.save-item:hover {
  background: #263657;
}

.save-item[aria-pressed="true"] {
  background: var(--chartreuse);
  color: var(--ink);
}

.save-item[aria-pressed="true"] svg {
  fill: currentColor;
}

body:has(dialog[open]) {
  overflow: hidden;
}

[hidden] {
  display: none !important;
}

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

@media (max-width: 1100px) {
  .hero {
    grid-template-columns: 1.15fr .85fr;
  }

  .hero-art {
    padding: 44px 28px;
  }

  .event-card {
    grid-template-columns: 125px minmax(0, 1fr);
  }

  .card-content {
    padding-inline: 19px;
  }

  .card-sigil {
    width: 70px;
  }
}

@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .issue {
    display: none;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    min-height: 520px;
  }

  .hero-art {
    min-height: 430px;
    border-top: 1px solid var(--ink);
    border-left: 0;
  }

  .weekend-stamp {
    bottom: 24px;
  }

  .toolbox {
    grid-template-columns: 1fr 1fr;
  }

  .filter-field {
    border-right: 0;
  }

  .saved-toggle {
    grid-column: 1 / -1;
    border-top: 1px solid var(--ink);
  }

  .event-grid {
    grid-template-columns: 1fr;
  }

  .event-card {
    grid-template-columns: 175px minmax(0, 1fr);
  }
}

@media (max-width: 620px) {
  .site-header {
    min-height: 68px;
    padding: 12px 18px;
  }

  .brand svg {
    width: 30px;
    height: 30px;
  }

  .header-link {
    font-size: .7rem;
  }

  .hero-copy {
    min-height: 450px;
    padding: 60px 20px 62px;
  }

  .eyebrow {
    margin-bottom: 24px;
    font-size: .65rem;
  }

  .eyebrow span {
    display: block;
    margin: 7px 0 0;
    padding-left: 0;
    border-left: 0;
  }

  h1 {
    margin-bottom: 25px;
    font-size: clamp(3.65rem, 18vw, 4.6rem);
    line-height: .89;
  }

  .hero-intro {
    font-size: .94rem;
  }

  .hero-art {
    min-height: 320px;
    padding: 35px 18px 48px;
  }

  .weekend-stamp {
    width: 96px;
    height: 96px;
    right: 13px;
    bottom: 13px;
  }

  .weekend-stamp strong {
    font-size: 1.9rem;
  }

  .browse {
    padding: 66px 16px 80px;
  }

  .browse-heading {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-bottom: 34px;
  }

  .browse-heading .eyebrow {
    margin-bottom: 8px;
  }

  .browse-heading h2 {
    font-size: 3.3rem;
  }

  .browse-heading > p {
    font-size: .9rem;
  }

  .toolbox {
    grid-template-columns: 1fr;
  }

  .search-field,
  .filter-field {
    padding-inline: 16px;
    border-right: 0;
  }

  .search-field {
    border-bottom: 1px solid var(--ink);
  }

  .saved-toggle {
    grid-column: auto;
    min-height: 58px;
  }

  .results-bar {
    min-height: 70px;
    gap: 12px;
  }

  .rule {
    display: none;
  }

  .reset-button {
    margin-left: auto;
  }

  .event-grid {
    gap: 18px;
  }

  .event-card {
    display: flex;
    min-height: 0;
    flex-direction: column;
  }

  .card-visual {
    min-height: 124px;
    flex-direction: row;
    align-items: center;
    padding: 16px 18px;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .card-number {
    align-self: flex-start;
    font-size: 3.1rem;
  }

  .card-sigil {
    width: 86px;
    height: 86px;
    margin-right: 22px;
  }

  .card-content {
    padding: 20px 19px 18px;
  }

  .card-topline {
    margin-bottom: 14px;
  }

  .event-card h3 {
    font-size: 1.7rem;
  }

  .card-summary {
    -webkit-line-clamp: 4;
  }

  .card-footer {
    align-items: center;
  }

  .open-item {
    min-width: 116px;
  }

  footer {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 13px;
    padding: 38px 20px;
  }

  footer p,
  .footer-note {
    justify-self: start;
    text-align: left;
  }

  .detail-dialog {
    width: 100vw;
    height: 100dvh;
    max-height: none;
    border: 0;
  }

  .detail-shell {
    display: block;
    max-height: 100dvh;
    padding-bottom: max(20px, env(safe-area-inset-bottom));
  }

  .close-detail {
    position: fixed;
    top: max(12px, env(safe-area-inset-top));
    right: 12px;
  }

  .detail-visual {
    min-height: 300px;
    padding: 60px 40px 36px;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .detail-number {
    top: 22px;
    left: 20px;
    font-size: 4rem;
  }

  .detail-mark {
    width: 150px;
  }

  .detail-category {
    bottom: 16px;
    left: 20px;
  }

  .detail-content {
    padding: 39px 20px 18px;
  }

  .detail-content h2 {
    font-size: 2.65rem;
  }

  .fact-grid {
    grid-template-columns: 1fr;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}
