:root {
  color-scheme: light;
  --ink: #10231f;
  --muted: #5f6f69;
  --paper: #f7f4eb;
  --paper-strong: #fffdf7;
  --green: #163d34;
  --green-soft: #d7e6db;
  --blue: #1e6c9f;
  --red: #bb4430;
  --gold: #f1b72f;
  --gold-deep: #c98314;
  --line: rgba(16, 35, 31, 0.16);
  --shadow: 0 18px 46px rgba(25, 41, 38, 0.16);
  --radius: 8px;
  --topbar: 78px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 18% 12%, rgba(30, 108, 159, 0.12), transparent 24rem),
    linear-gradient(120deg, #f7f4eb 0%, #eef3ea 42%, #f9f0dc 100%);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.45;
  overflow-x: hidden;
}

button,
a {
  font: inherit;
}

a {
  color: inherit;
}

.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.ambient span {
  position: absolute;
  width: 10px;
  height: 10px;
  border: 1px solid rgba(22, 61, 52, 0.2);
  border-radius: 50%;
  background: rgba(255, 253, 247, 0.55);
  animation: drift 14s linear infinite;
}

.ambient span:nth-child(1) {
  left: 8%;
  bottom: -40px;
  animation-delay: 0s;
}

.ambient span:nth-child(2) {
  left: 18%;
  bottom: -80px;
  width: 16px;
  height: 16px;
  animation-delay: 3s;
  animation-duration: 19s;
}

.ambient span:nth-child(3) {
  left: 43%;
  bottom: -70px;
  animation-delay: 5s;
  animation-duration: 16s;
}

.ambient span:nth-child(4) {
  left: 66%;
  bottom: -50px;
  width: 14px;
  height: 14px;
  animation-delay: 1s;
  animation-duration: 18s;
}

.ambient span:nth-child(5) {
  left: 84%;
  bottom: -70px;
  width: 18px;
  height: 18px;
  animation-delay: 7s;
  animation-duration: 22s;
}

.ambient span:nth-child(6) {
  left: 91%;
  bottom: -30px;
  animation-delay: 10s;
  animation-duration: 15s;
}

.topbar {
  min-height: var(--topbar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px clamp(18px, 4vw, 54px);
  border-bottom: 1px solid rgba(16, 35, 31, 0.12);
  background: rgba(247, 244, 235, 0.84);
  backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  min-width: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fffdf7;
  font-weight: 900;
  letter-spacing: 0;
  box-shadow: inset 0 -5px 0 rgba(255, 255, 255, 0.14);
  flex: 0 0 auto;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 1rem;
  line-height: 1.1;
}

.brand small {
  color: var(--muted);
  margin-top: 2px;
}

.quick-facts {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.quick-facts span {
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(255, 253, 247, 0.66);
  color: var(--green);
  font-size: 0.86rem;
  white-space: nowrap;
}

main {
  width: min(1440px, 100%);
  margin: 0 auto;
}

.tour-shell {
  min-height: calc(100vh - var(--topbar));
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(330px, 0.72fr);
  gap: clamp(18px, 3vw, 34px);
  padding: clamp(18px, 3vw, 42px);
  align-items: stretch;
  min-width: 0;
}

.map-zone,
.stop-panel {
  background: rgba(255, 253, 247, 0.78);
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.map-zone {
  display: grid;
  grid-template-rows: auto minmax(340px, 1fr) auto;
  gap: 18px;
  padding: clamp(18px, 2.3vw, 28px);
  min-height: 620px;
  min-width: 0;
}

.map-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 22px;
}

.map-head > div:first-child {
  flex: 1 1 360px;
  min-width: min(100%, 300px);
}

.hero-logo {
  width: clamp(150px, 16vw, 240px);
  margin: 0;
  padding: 8px 8px 12px;
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 253, 247, 0.78);
  box-shadow: 0 14px 32px rgba(25, 41, 38, 0.12);
  flex: 0 0 auto;
}

.hero-logo img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
}

.hero-logo figcaption {
  color: var(--red);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 2.6vw, 2rem);
  font-weight: 900;
  line-height: 1;
  text-align: center;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

h1 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(2.15rem, 5vw, 5rem);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 3rem);
  line-height: 1.04;
  letter-spacing: 0;
}

h3 {
  margin: 0;
  font-size: 1.15rem;
  letter-spacing: 0;
}

.mode-toggle {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  border: 1px solid rgba(16, 35, 31, 0.15);
  border-radius: 999px;
  padding: 4px;
  background: rgba(22, 61, 52, 0.07);
  min-width: 184px;
  flex: 0 0 auto;
}

.mode-btn {
  border: 0;
  border-radius: 999px;
  color: var(--green);
  background: transparent;
  padding: 9px 12px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

.mode-btn.is-active {
  color: #fffdf7;
  background: var(--green);
  box-shadow: 0 5px 14px rgba(22, 61, 52, 0.2);
}

.route-stage {
  position: relative;
  width: 100%;
  min-width: 0;
  min-height: 340px;
  border-radius: var(--radius);
  overflow: hidden;
  background: #dfe9d9;
  isolation: isolate;
}

.poster,
#routeCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.poster {
  object-fit: cover;
  filter: saturate(1.05) contrast(0.98);
}

#routeCanvas {
  z-index: 2;
  cursor: pointer;
}

.map-badge {
  position: absolute;
  left: 16px;
  bottom: 16px;
  z-index: 3;
  max-width: calc(100% - 32px);
  border: 1px solid rgba(255, 253, 247, 0.62);
  border-radius: 999px;
  background: rgba(16, 35, 31, 0.82);
  color: #fffdf7;
  padding: 9px 12px;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

.route-controls {
  display: grid;
  grid-template-columns: 42px minmax(136px, auto) 42px minmax(120px, 1fr);
  gap: 10px;
  align-items: center;
}

.icon-btn,
.play-btn {
  border: 1px solid rgba(16, 35, 31, 0.16);
  color: var(--green);
  background: #fffdf7;
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.icon-btn {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
}

.play-btn {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 999px;
  padding: 0 16px;
  font-weight: 900;
}

.icon-btn:hover,
.play-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(22, 61, 52, 0.34);
  background: #f5fbf5;
}

.icon-btn svg,
.play-btn svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.3;
}

.route-meter {
  height: 10px;
  border-radius: 999px;
  background: rgba(16, 35, 31, 0.12);
  overflow: hidden;
}

.route-meter span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--gold), var(--red));
  transition: width 420ms ease;
}

.stop-panel {
  display: flex;
  flex-direction: column;
  padding: clamp(18px, 2.4vw, 28px);
  min-height: 620px;
  position: relative;
  overflow: hidden;
}

.stop-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 9px;
  background: var(--accent, var(--gold));
}

.stop-kicker {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 800;
}

.stop-title {
  margin-top: 12px;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 0.96;
}

.stop-copy {
  margin: 18px 0 0;
  color: #31433d;
  font-size: 1.02rem;
}

.stop-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 22px 0;
}

.meta-chip {
  border: 1px solid rgba(16, 35, 31, 0.12);
  border-radius: var(--radius);
  background: rgba(247, 244, 235, 0.74);
  padding: 12px;
  min-height: 78px;
}

.meta-chip small,
.beer-card small,
.culture-card small,
.source-link small {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.meta-chip strong {
  display: block;
  margin-top: 4px;
  font-size: 1rem;
  line-height: 1.22;
}

.beer-list {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.beer-pill {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid rgba(16, 35, 31, 0.1);
  padding: 10px 0;
}

.beer-pill:last-child {
  border-bottom: 0;
}

.beer-pill span {
  color: var(--muted);
  font-size: 0.9rem;
}

.source-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  margin-top: 20px;
  border: 1px solid rgba(16, 35, 31, 0.16);
  border-radius: 999px;
  padding: 10px 13px;
  text-decoration: none;
  color: #fffdf7;
  background: var(--green);
  font-weight: 900;
}

.source-btn svg {
  width: 16px;
  height: 16px;
}

.crew-band,
.beer-band,
.culture-band,
.timeline-band,
.source-band {
  padding: clamp(28px, 5vw, 70px) clamp(18px, 4vw, 54px);
}

.crew-band {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(310px, 0.78fr);
  gap: clamp(18px, 3vw, 34px);
  align-items: stretch;
}

.crew-visual,
.crew-copy {
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 253, 247, 0.74);
  box-shadow: var(--shadow);
}

.crew-visual {
  position: relative;
  min-height: 420px;
  overflow: hidden;
}

.crew-visual img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

.crew-stamp {
  position: absolute;
  left: 18px;
  bottom: 18px;
  border: 1px solid rgba(255, 253, 247, 0.62);
  border-radius: 999px;
  background: rgba(187, 68, 48, 0.9);
  color: #fffdf7;
  padding: 10px 14px;
  font-weight: 900;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.16);
}

.crew-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(20px, 3vw, 36px);
}

.crew-copy p:not(.eyebrow) {
  margin: 18px 0 0;
  color: #31433d;
  font-size: 1.06rem;
}

.crew-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 28px;
}

.crew-roles span {
  border-radius: 999px;
  background: rgba(22, 61, 52, 0.1);
  color: var(--green);
  padding: 8px 10px;
  font-size: 0.88rem;
  font-weight: 900;
}

.tour-logo-card {
  width: min(280px, 100%);
  margin: 30px 0 0;
  padding: 14px 14px 18px;
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fffdf7, rgba(247, 244, 235, 0.78));
  box-shadow: 0 12px 28px rgba(25, 41, 38, 0.1);
}

.tour-logo-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
}

.tour-logo-card figcaption {
  margin-top: 8px;
  color: var(--red);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 900;
  line-height: 1;
  text-align: center;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  margin-bottom: 22px;
}

.beer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.culture-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.beer-card,
.culture-card {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  padding: 18px;
  background:
    linear-gradient(160deg, rgba(255, 253, 247, 0.94), rgba(255, 253, 247, 0.64)),
    var(--accent, var(--green-soft));
  box-shadow: 0 10px 25px rgba(25, 41, 38, 0.08);
  position: relative;
  overflow: hidden;
  transition:
    transform 220ms ease,
    box-shadow 220ms ease;
}

.beer-card::after {
  content: "";
  position: absolute;
  right: 16px;
  bottom: -24px;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  border: 14px solid rgba(22, 61, 52, 0.08);
}

.beer-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 38px rgba(25, 41, 38, 0.14);
}

.culture-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 38px rgba(25, 41, 38, 0.14);
}

.beer-card p,
.culture-card p {
  margin: 0;
  color: #374943;
}

.culture-card {
  min-height: 230px;
  border-top: 7px solid var(--accent, var(--green));
}

.beer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: auto;
}

.beer-tags span {
  border-radius: 999px;
  background: rgba(16, 35, 31, 0.08);
  color: var(--green);
  padding: 6px 8px;
  font-size: 0.82rem;
  font-weight: 800;
}

.card-link {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: auto;
  border: 1px solid rgba(16, 35, 31, 0.15);
  border-radius: 999px;
  background: rgba(255, 253, 247, 0.84);
  color: var(--green);
  padding: 8px 10px;
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 900;
}

.card-link svg {
  width: 15px;
  height: 15px;
}

.card-link:hover {
  border-color: rgba(30, 108, 159, 0.42);
  background: #fffdf7;
}

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.timeline li {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  border-top: 1px solid rgba(16, 35, 31, 0.14);
  padding-top: 14px;
}

.timeline time {
  color: var(--blue);
  font-weight: 900;
}

.timeline strong {
  display: block;
  font-size: 1.04rem;
}

.timeline span {
  color: var(--muted);
}

.sources {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.source-link {
  min-height: 92px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(16, 35, 31, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 253, 247, 0.72);
  padding: 14px;
  text-decoration: none;
}

.source-link strong {
  line-height: 1.2;
}

.source-link:hover {
  border-color: rgba(30, 108, 159, 0.42);
}

@keyframes drift {
  from {
    transform: translate3d(0, 0, 0) scale(0.8);
    opacity: 0;
  }

  15%,
  80% {
    opacity: 1;
  }

  to {
    transform: translate3d(18px, -110vh, 0) scale(1.35);
    opacity: 0;
  }
}

@media (max-width: 1080px) {
  .tour-shell {
    grid-template-columns: 1fr;
  }

  .stop-panel,
  .map-zone {
    min-height: auto;
  }

  .route-stage {
    aspect-ratio: 16 / 10;
  }

  .beer-grid,
  .culture-grid,
  .sources {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .crew-band {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  :root {
    --topbar: 118px;
  }

  .topbar,
  .map-head,
  .section-title {
    align-items: stretch;
    flex-direction: column;
  }

  .quick-facts {
    justify-content: flex-start;
  }

  .tour-shell {
    padding: 14px;
  }

  .map-zone {
    padding: 14px;
    grid-template-rows: auto 390px auto;
  }

  .route-stage {
    height: 390px;
    min-height: 0;
    aspect-ratio: auto;
  }

  .mode-toggle {
    width: 100%;
  }

  .hero-logo {
    width: min(250px, 100%);
  }

  .route-controls {
    grid-template-columns: 42px 1fr 42px;
  }

  .route-meter {
    grid-column: 1 / -1;
  }

  .stop-meta,
  .beer-grid,
  .culture-grid,
  .sources {
    grid-template-columns: 1fr;
  }

  .crew-band {
    padding-top: 24px;
  }

  .crew-visual,
  .crew-visual img {
    min-height: 310px;
  }

  .tour-logo-card {
    width: min(260px, 100%);
  }

  .timeline li {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

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