@font-face {
  font-family: "Space Grotesk";
  src: url("assets/space-grotesk.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Oswald";
  src: url("assets/oswald.ttf") format("truetype");
  font-display: swap;
}

:root {
  --cobalt: #2347d8;
  --cobalt-dark: #17309b;
  --paper: #f6f7f2;
  --mist: #e9edff;
  --ink: #161b35;
  --yellow: #ffd84a;
  --white: #ffffff;
  --rule: #bac3e9;
  --font-body: "Space Grotesk", Arial, sans-serif;
  --font-display: "Oswald", Impact, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
}

button,
input,
select {
  font: inherit;
}

button,
a,
select {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 10px 14px;
  background: var(--yellow);
  color: var(--ink);
  font-weight: 700;
  transform: translateY(-150%);
}

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

.site-header {
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 78px;
  padding: 14px clamp(22px, 4vw, 68px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.38);
  background: var(--cobalt);
  color: var(--white);
}

.brand {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 11px;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand-mark {
  position: relative;
  display: block;
  width: 31px;
  height: 31px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.brand-mark i {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--yellow);
}

.brand-mark i:first-child {
  top: 4px;
  left: 4px;
}

.brand-mark i:last-child {
  right: 4px;
  bottom: 4px;
}

.header-date {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}

.saved-nav {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 5px 6px 5px 15px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 999px;
  background: transparent;
  color: var(--white);
  cursor: pointer;
}

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

.saved-count {
  display: grid;
  place-items: center;
  min-width: 29px;
  height: 29px;
  padding-inline: 6px;
  border-radius: 50%;
  background: var(--white);
  color: var(--cobalt-dark);
  font-size: 13px;
  font-weight: 800;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(460px, 0.84fr);
  min-height: 442px;
  padding: 54px clamp(22px, 5.4vw, 88px) 60px;
  overflow: hidden;
  background: var(--cobalt);
  color: var(--white);
}

.hero-copy {
  align-self: end;
}

.hero-kicker {
  width: fit-content;
  margin: 0 0 24px;
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

.hero h1 {
  max-width: 730px;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(68px, 7.5vw, 118px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.88;
}

.hero-intro {
  max-width: 590px;
  margin: 28px 0 0;
  font-size: clamp(16px, 1.4vw, 20px);
  line-height: 1.5;
}

.date-poster {
  align-self: center;
  display: grid;
  grid-template-columns: 1fr 122px 1fr;
  align-items: center;
  min-width: 0;
  transform: rotate(-3deg);
}

.date-block {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.date-block span {
  margin-bottom: -9px;
  font-size: 18px;
  font-weight: 700;
}

.date-block strong {
  font-family: var(--font-display);
  font-size: clamp(116px, 13vw, 190px);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 1;
  text-shadow: 7px 7px 0 var(--cobalt-dark);
}

.date-poster svg {
  width: 100%;
  overflow: visible;
  color: var(--yellow);
}

.date-poster path {
  fill: none;
  stroke: currentColor;
  stroke-width: 4;
  stroke-linecap: round;
}

.date-poster circle {
  fill: currentColor;
}

.planner {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: clamp(50px, 6vw, 96px);
  max-width: 1320px;
  margin: 0 auto;
  padding: 76px clamp(22px, 4vw, 58px) 110px;
}

.filter-panel {
  position: sticky;
  top: 24px;
  align-self: start;
  padding: 28px;
  background: var(--mist);
  border: 1px solid var(--rule);
  border-radius: 2px 34px 2px 2px;
}

.filter-heading,
.results-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
}

.filter-heading {
  margin-bottom: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--rule);
}

.filter-heading h2 {
  margin: 0;
  font-size: 21px;
  letter-spacing: -0.035em;
}

.clear-button {
  padding: 2px;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: var(--cobalt-dark);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.control-label {
  display: block;
  margin: 20px 0 8px;
  font-size: 13px;
  font-weight: 700;
}

.search-wrap,
.select-wrap {
  position: relative;
}

.search-wrap svg,
.select-wrap svg {
  position: absolute;
  top: 50%;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  pointer-events: none;
}

.search-wrap svg {
  left: 15px;
}

.select-wrap svg {
  right: 14px;
}

.search-wrap input,
.select-wrap select {
  width: 100%;
  height: 51px;
  border: 1px solid #8e9bcf;
  border-radius: 3px;
  background: var(--white);
  color: var(--ink);
}

.search-wrap input {
  padding: 0 13px 0 45px;
}

.search-wrap input::placeholder {
  color: #66709a;
}

.select-wrap select {
  appearance: none;
  padding: 0 42px 0 14px;
  cursor: pointer;
}

.filter-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  color: #465076;
  font-size: 12px;
  line-height: 1.45;
}

.filter-note span {
  color: var(--cobalt);
  font-size: 19px;
  font-weight: 700;
}

.filter-note p {
  margin: 1px 0 0;
}

.results {
  min-width: 0;
}

.results-heading {
  margin-bottom: 34px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.results-heading h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 500;
  letter-spacing: -0.025em;
}

.results-heading p {
  margin: 0;
  color: #525b7d;
  font-size: 14px;
  font-weight: 600;
}

.day-group + .day-group {
  margin-top: 58px;
}

.day-heading {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 0 0 18px;
  color: var(--cobalt-dark);
  font-size: 14px;
  font-weight: 700;
}

.day-heading::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
}

.day-route {
  position: relative;
}

.day-route::before {
  content: "";
  position: absolute;
  top: 26px;
  bottom: 26px;
  left: 94px;
  width: 3px;
  background: var(--cobalt);
}

.event-item {
  position: relative;
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 42px;
  padding: 0 0 24px;
}

.event-item + .event-item {
  padding-top: 10px;
}

.event-time {
  padding-top: 25px;
  text-align: right;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 500;
  line-height: 1;
}

.event-card {
  position: relative;
  min-width: 0;
  padding: 22px 26px 24px;
  border: 1px solid var(--rule);
  border-radius: 2px 22px 2px 2px;
  background: var(--white);
}

.event-card::before {
  content: "";
  position: absolute;
  top: 29px;
  left: -31px;
  width: 13px;
  height: 13px;
  border: 4px solid var(--paper);
  border-radius: 50%;
  background: var(--cobalt);
  box-shadow: 0 0 0 2px var(--cobalt);
}

.event-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
}

.category {
  color: var(--cobalt-dark);
  font-size: 12px;
  font-weight: 700;
}

.event-price {
  color: #566087;
  font-size: 13px;
  font-weight: 600;
}

.event-card h3 {
  max-width: 690px;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(28px, 2.6vw, 39px);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.12;
}

.event-summary {
  max-width: 680px;
  margin: 13px 0 18px;
  color: #414a6c;
  font-size: 15px;
  line-height: 1.55;
}

.event-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding-top: 15px;
  border-top: 1px solid #dce0ef;
}

.event-place {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
}

.event-place span {
  color: #69718f;
  font-weight: 500;
}

.open-item {
  flex: 0 0 auto;
  padding: 7px 0;
  border: 0;
  border-bottom: 2px solid var(--cobalt);
  background: transparent;
  color: var(--cobalt-dark);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.event-card:has(.open-item:hover),
.event-card:has(.open-item:focus-visible) {
  border-color: var(--cobalt);
  background: #fbfcff;
}

.saved-pin {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 0 0 0 2px var(--ink);
  vertical-align: 1px;
}

.empty-state {
  padding: 70px 24px;
  border: 1px solid var(--rule);
  background: var(--mist);
  text-align: center;
}

.empty-state[hidden] {
  display: none;
}

.empty-loop {
  display: block;
  width: 56px;
  height: 56px;
  margin: 0 auto 22px;
  border: 5px solid var(--cobalt);
  border-right-color: transparent;
  border-radius: 50%;
}

.empty-state h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 500;
}

.empty-state p {
  margin: 8px auto 22px;
  color: #525b7d;
}

.empty-state button {
  padding: 11px 16px;
  border: 2px solid var(--ink);
  background: var(--yellow);
  font-weight: 700;
  cursor: pointer;
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 30px clamp(22px, 4vw, 68px);
  background: var(--ink);
  color: var(--white);
  font-size: 13px;
}

footer p {
  margin: 0;
}

footer p span {
  color: var(--yellow);
  font-weight: 700;
}

footer a {
  text-underline-offset: 4px;
}

.detail-overlay {
  position: fixed;
  z-index: 50;
  inset: 0;
  display: flex;
  justify-content: flex-end;
  background: rgba(11, 17, 48, 0.64);
  backdrop-filter: blur(3px);
}

.detail-panel {
  position: relative;
  width: min(620px, 92vw);
  height: 100%;
  overflow-y: auto;
  background: var(--paper);
  box-shadow: -16px 0 50px rgba(7, 12, 39, 0.25);
}

.detail-bar {
  position: sticky;
  z-index: 2;
  top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 28px;
  border-bottom: 1px solid var(--rule);
  background: rgba(246, 247, 242, 0.96);
}

.detail-bar p {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}

.close-detail {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: transparent;
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.detail-content {
  padding: 54px clamp(28px, 6vw, 74px) 70px;
}

.detail-category {
  display: inline-block;
  margin-bottom: 21px;
  padding: 6px 10px;
  border: 1px solid var(--cobalt);
  border-radius: 999px;
  color: var(--cobalt-dark);
  font-size: 12px;
  font-weight: 700;
}

.detail-content h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(46px, 5.2vw, 72px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 0.98;
}

.detail-when {
  margin: 25px 0 30px;
  color: var(--cobalt-dark);
  font-size: 18px;
  font-weight: 700;
}

.save-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 52px;
  margin-bottom: 36px;
  padding: 12px 20px;
  border: 2px solid var(--ink);
  background: var(--yellow);
  font-weight: 800;
  cursor: pointer;
}

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

.save-item svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.save-item[aria-pressed="true"] svg {
  fill: var(--yellow);
  color: var(--yellow);
}

.detail-facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 0 0 38px;
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.detail-facts div {
  padding: 16px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.detail-facts dt {
  margin-bottom: 4px;
  color: #69718f;
  font-size: 11px;
  font-weight: 700;
}

.detail-facts dd {
  margin: 0;
  font-size: 14px;
  font-weight: 650;
}

.detail-body {
  font-size: 17px;
  line-height: 1.7;
}

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

.detail-body p:last-child {
  padding: 19px 20px;
  border-left: 5px solid var(--cobalt);
  background: var(--mist);
  font-size: 15px;
}

body.detail-open {
  overflow: hidden;
}

@media (max-width: 960px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .date-poster {
    max-width: 680px;
    justify-self: center;
  }

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

  .filter-panel {
    position: static;
  }
}

@media (max-width: 620px) {
  .site-header {
    grid-template-columns: 1fr auto;
    min-height: 68px;
    padding: 12px 18px;
  }

  .brand {
    font-size: 15px;
  }

  .brand-mark {
    width: 27px;
    height: 27px;
  }

  .header-date {
    display: none;
  }

  .saved-nav {
    min-height: 40px;
    padding-left: 12px;
    font-size: 13px;
  }

  .hero {
    min-height: auto;
    padding: 48px 20px 42px;
  }

  .hero-kicker {
    margin-bottom: 18px;
  }

  .hero h1 {
    font-size: clamp(58px, 18vw, 76px);
  }

  .hero-intro {
    margin-top: 22px;
    font-size: 16px;
  }

  .date-poster {
    grid-template-columns: 1fr 64px 1fr;
    width: 100%;
    transform: rotate(-2deg);
  }

  .date-block span {
    font-size: 14px;
  }

  .date-block strong {
    font-size: 98px;
    text-shadow: 5px 5px 0 var(--cobalt-dark);
  }

  .planner {
    gap: 46px;
    padding: 38px 16px 72px;
  }

  .filter-panel {
    padding: 22px;
    border-radius: 2px 26px 2px 2px;
  }

  .results-heading {
    align-items: flex-end;
    margin-bottom: 28px;
  }

  .results-heading h2 {
    font-size: 31px;
  }

  .results-heading p {
    max-width: 105px;
    text-align: right;
  }

  .day-group + .day-group {
    margin-top: 44px;
  }

  .day-route::before {
    left: 12px;
  }

  .event-item,
  .event-item + .event-item {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 0 0 22px 29px;
  }

  .event-time {
    padding-top: 0;
    text-align: left;
    font-size: 20px;
  }

  .event-card {
    padding: 19px 18px 20px;
    border-radius: 2px 18px 2px 2px;
  }

  .event-card::before {
    top: -27px;
    left: -23px;
    width: 11px;
    height: 11px;
  }

  .event-card h3 {
    font-size: 30px;
  }

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

  .event-bottom {
    align-items: flex-end;
  }

  .event-place {
    max-width: 165px;
  }

  footer {
    align-items: flex-start;
    padding: 26px 20px;
  }

  footer p {
    max-width: 220px;
  }

  .detail-overlay {
    align-items: flex-end;
  }

  .detail-panel {
    width: 100%;
    height: min(92%, 780px);
    border-radius: 24px 24px 0 0;
  }

  .detail-bar {
    padding: 12px 18px;
  }

  .detail-content {
    padding: 34px 22px 55px;
  }

  .detail-content h2 {
    font-size: 48px;
  }

  .detail-facts {
    grid-template-columns: 1fr;
  }
}

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