:root {
  --bg: #14110e;
  --bg-mid: #1a1612;
  --surface: #1f1a16;
  --text: #e8ecf1;
  --muted: #9a9088;
  --accent: #f0a052;
  --accent-dim: #d4823a;
  --border: #3a3028;
  --radius: 12px;
  --max: 42rem;
  --wide: 56rem;
  --hero: 72rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "DM Sans", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  display: flex;
  flex-direction: column;
}

.home-page {
  position: relative;
}

/* Atmosphere: warm radial wash + subtle grain-like gradient */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 90% 55% at 15% -10%, rgba(240, 160, 82, 0.18), transparent 55%),
    radial-gradient(ellipse 70% 50% at 95% 20%, rgba(61, 90, 82, 0.22), transparent 50%),
    linear-gradient(180deg, var(--bg-mid) 0%, var(--bg) 45%, #0f0d0b 100%);
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #ffb86a;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--wide);
  margin: 0 auto;
  padding: 1.25rem 1.5rem;
  width: 100%;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.logo:hover {
  color: var(--text);
}

.logo img {
  width: 2rem;
  height: 2rem;
  border-radius: 0.45rem;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.85rem 1.15rem;
  font-size: 0.9rem;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--text);
}

.nav-cta {
  color: var(--bg) !important;
  background: var(--accent);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none !important;
}

.nav-cta:hover {
  background: #ffb86a;
  color: var(--bg) !important;
}

main {
  flex: 1;
  width: 100%;
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

/* Homepage — full-bleed layout */
.home-main {
  max-width: none;
  padding: 0;
}

.site-header-hero {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  max-width: none;
  background: linear-gradient(180deg, rgba(20, 17, 14, 0.85) 0%, transparent 100%);
}

.site-header-hero .nav a {
  color: rgba(232, 236, 241, 0.75);
}

.site-header-hero .nav a:hover {
  color: var(--text);
}

.hero-full {
  position: relative;
  min-height: clamp(28rem, 72vh, 40rem);
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

.hero-photo {
  position: absolute;
  inset: 0;
  background: url("/images/heroes/velocicoaster.jpg") center / cover no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(20, 17, 14, 0.82) 0%, rgba(20, 17, 14, 0.45) 50%, rgba(20, 17, 14, 0.25) 100%),
    radial-gradient(ellipse 80% 60% at 20% 0%, rgba(240, 160, 82, 0.12), transparent 55%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--hero);
  margin: 0 auto;
  padding: 5.5rem 1.5rem 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr minmax(16rem, 22rem);
  gap: 2.5rem;
  align-items: start;
}

.hero-copy {
  max-width: 36rem;
}

.hero-eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-full h1 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.85rem, 4.5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: var(--text);
}

.hero-full .lede {
  margin: 0 0 0.75rem;
  color: rgba(232, 236, 241, 0.82);
  font-size: 1.05rem;
  max-width: 32rem;
}

.hero-utility {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  font-style: italic;
}

.hero-form-card {
  padding: 1.35rem 1.4rem 1.5rem;
  background: rgba(31, 26, 22, 0.92);
  border: 1px solid rgba(58, 48, 40, 0.9);
  border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
}

.hero-form-card .hero-trip {
  max-width: none;
  margin-top: 0;
}

.photo-credit {
  margin: 1.5rem 0 0;
  font-size: 0.72rem;
  color: rgba(154, 144, 136, 0.75);
}

.showcase-trip {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 2.5rem;
  align-items: center;
  max-width: var(--hero);
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
}

.showcase-trip h2 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.showcase-trip > .showcase-trip-copy > p {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 1.02rem;
}

.showcase-glance {
  margin-bottom: 1rem !important;
}

.showcase-note {
  margin: 0 0 1.25rem !important;
  font-size: 0.88rem !important;
  color: var(--muted);
}

.showcase-trip-figure {
  margin: 0;
}

.showcase-trip-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.feature-section {
  max-width: var(--hero);
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.feature-section-heading {
  margin: 0 0 1.5rem;
  font-size: clamp(1.35rem, 3vw, 1.65rem);
  letter-spacing: -0.02em;
  text-align: center;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.feature-card {
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.feature-card img {
  display: block;
  width: 100%;
  height: auto;
  border-bottom: 1px solid var(--border);
}

.feature-card h3 {
  margin: 1rem 1.1rem 0.4rem;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.feature-card p {
  margin: 0 1.1rem 1.15rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  cursor: pointer;
  text-decoration: none;
  background: var(--surface);
  color: var(--text);
}

.btn-secondary:hover {
  border-color: var(--accent-dim);
  color: var(--accent);
}

.hero {
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  max-width: 36rem;
  padding: 1.25rem 0 3rem;
}

.hero-brand {
  font-size: clamp(2rem, 6vw, 3.25rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin: 0 0 0.75rem;
}

.hero h1 {
  font-size: clamp(1.35rem, 3.2vw, 1.75rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin: 0 0 0.85rem;
  color: var(--text);
}

.hero .lede {
  margin: 0 0 1.75rem;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 28rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.75rem 1.35rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  background: var(--accent);
  color: var(--bg);
}

.btn:hover {
  background: #ffb86a;
  color: var(--bg);
}

.hero-trip {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  max-width: 22rem;
  margin-top: 0.25rem;
}

.hero-trip-lede {
  margin: 0 0 0.5rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.hero-trip label {
  font-size: 0.82rem;
  font-weight: 600;
  margin-top: 0.45rem;
}

.hero-trip input {
  font: inherit;
  font-size: 1rem;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
}

.hero-trip input::placeholder {
  color: var(--muted);
}

.hero-trip input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.hero-trip .btn {
  margin-top: 0.85rem;
  width: 100%;
}

.geocode-status {
  font-size: 0.8rem;
  min-height: 1.15rem;
  margin: 0 0 0.15rem;
  color: var(--muted);
}

.geocode-status.geocode-ok {
  color: #8fd49a;
}

.geocode-status.geocode-bad {
  color: #e8a0a0;
}

.geocode-status.geocode-pending {
  color: var(--muted);
}

#hero-trip-error:empty {
  display: none;
}

.page-hero {
  position: relative;
  width: 100%;
  min-width: 0;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--surface);
}

.page-hero-photo {
  --hero-focus-y: 48%;
  display: block;
  width: 100%;
  height: clamp(20rem, 52vh, 30rem);
  object-fit: cover;
  object-position: center var(--hero-focus-y);
}

.page-hero-photo--top {
  --hero-focus-y: 33%;
}

.page-hero-photo--orion {
  --hero-focus-y: 36%;
}

.page-hero-photo--loop {
  --hero-focus-y: 16%;
}

.page-hero-scrim {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 4.25rem 0 1rem;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(20, 17, 14, 0.55) 42%,
    rgba(20, 17, 14, 0.94) 100%
  );
}

.page-hero-inner {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.page-hero h1 {
  margin: 0 0 0.45rem;
  font-size: clamp(1.7rem, 4vw, 2.35rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: #f4f1ec;
}

.page-hero .lede {
  margin: 0;
  max-width: 38rem;
  color: rgba(244, 241, 236, 0.88);
  font-size: 1.02rem;
}

.page-hero-credit {
  margin: 0.7rem 0 0;
  font-size: 0.72rem;
  color: rgba(198, 188, 178, 0.85);
}

.page-hero-credit a {
  color: rgba(198, 188, 178, 0.95);
}

.page-hero-credit a:hover {
  color: var(--accent);
}

.page-hero + main {
  padding-top: 1.35rem;
}

.page-hero + main .content > h2:first-child,
.page-hero + main .content > blockquote:first-child {
  margin-top: 0;
}

.page-photo {
  margin: 0 auto;
  width: 100%;
  max-width: var(--wide);
  min-width: 0;
  flex-shrink: 1;
}

.page-photo img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  background: var(--surface);
}

.page-photo figcaption {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0.45rem 1.5rem 0;
  font-size: 0.75rem;
  color: var(--muted);
}

.page-photo figcaption a {
  color: var(--muted);
}

.page-photo figcaption a:hover {
  color: var(--accent);
}

.page-photo + main .page-header {
  padding-top: 1.15rem;
}

.help-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 12.75rem;
  gap: 1.5rem;
  align-items: start;
  padding-top: 1.5rem;
}

.help-layout .content {
  min-width: 0;
}

.help-photo-inset {
  margin: 0;
  position: sticky;
  top: 1rem;
}

.help-photo-inset img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center 30%;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
}

.help-photo-inset figcaption {
  margin: 0.4rem 0 0;
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.4;
}

.help-photo-inset figcaption a {
  color: var(--muted);
}

.help-photo-inset figcaption a:hover {
  color: var(--accent);
}

.page-header {
  max-width: var(--max);
  padding: 2.5rem 0 1.5rem;
}

.page-header h1 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.85rem, 4vw, 2.35rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.page-header .lede {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.content {
  max-width: var(--max);
}

.content h2 {
  margin: 2.25rem 0 0.65rem;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.content p,
.content li {
  color: var(--muted);
}

.content p {
  margin: 0 0 1rem;
}

.content ul {
  margin: 0 0 1rem;
  padding-left: 1.2rem;
}

.content ol {
  margin: 0 0 1rem;
  padding-left: 1.2rem;
}

.content blockquote {
  margin: 0 0 1.5rem;
  padding: 0.15rem 0 0.15rem 0.9rem;
  border-left: 3px solid var(--accent);
}

.content h1 {
  margin: 0 0 1rem;
}

.stub-note {
  margin-top: 2rem;
  padding: 1rem 1.15rem;
  border-left: 3px solid var(--accent-dim);
  background: rgba(31, 26, 22, 0.65);
  color: var(--muted);
  font-size: 0.95rem;
}

.page-list {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
}

.page-list li {
  margin: 0 0 1rem;
  padding: 0;
}

.page-list a {
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  color: var(--text);
}

.page-list a:hover {
  color: var(--accent);
}

.page-list .page-list-desc {
  display: block;
  margin-top: 0.25rem;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 400;
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0 1.5rem;
  font-size: 0.95rem;
}

.compare-table th,
.compare-table td {
  border: 1px solid var(--border);
  padding: 0.65rem 0.75rem;
  text-align: left;
  vertical-align: top;
}

.compare-table th {
  background: rgba(31, 26, 22, 0.85);
  color: var(--text);
  font-weight: 600;
}

.compare-table td {
  color: var(--muted);
}

.compare-table td:first-child {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .compare-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.875rem;
}

.site-footer p {
  margin: 0.35rem 0;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--accent);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 0.85rem;
}

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

  .showcase-trip {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

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

.page-photo-help {
  display: none;
}

@media (max-width: 800px) {
  .help-layout {
    display: block;
  }

  .help-photo-inset {
    display: none;
  }

  .page-photo-help {
    display: block;
  }
}

@media (max-width: 640px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-header-hero {
    position: relative;
    background: var(--bg-mid);
  }

  .nav {
    justify-content: flex-start;
  }

  .hero-full {
    min-height: auto;
  }

  .hero-inner {
    padding-top: 1.25rem;
  }

  .hero {
    min-height: auto;
    padding-top: 3rem;
  }

  .page-hero-photo {
    height: clamp(18rem, 58vw, 26rem);
  }

  .page-hero-scrim {
    padding-top: 3.25rem;
  }

  .page-hero h1 {
    font-size: 1.55rem;
  }
}

.legal-page {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  width: 100%;
}

.legal-page h1 {
  margin-bottom: 0.25rem;
}

.legal-page h2 {
  margin-top: 1.75rem;
  font-size: 1.1rem;
}

.legal-page ul {
  padding-left: 1.25rem;
}

.legal-page li {
  margin-bottom: 0.4rem;
}

.legal-page .hint {
  color: var(--muted);
  font-size: 0.95rem;
}

/* Trip recipes (field guides) */
.content.content-recipe {
  max-width: var(--wide);
}

.page-header.recipe-header {
  max-width: var(--wide);
}

.recipe-glance {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
  gap: 0.75rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
}

.recipe-glance li {
  margin: 0;
  padding: 0.85rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.recipe-glance .glance-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.3rem;
}

.recipe-glance .glance-value {
  display: block;
  color: var(--text);
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.3;
}

.recipe-note {
  margin: 0 0 1.25rem;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(31, 26, 22, 0.65);
  color: var(--muted);
  font-size: 0.95rem;
}

.recipe-note strong {
  color: var(--text);
}

.route-map {
  margin: 0 0 1.5rem;
  padding: 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.route-map svg {
  display: block;
  width: 100%;
  height: auto;
}

.route-map figcaption {
  margin: 0.65rem 0.25rem 0.15rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.stop-card {
  margin: 0 0 1.15rem;
  padding: 1.1rem 1.2rem 0.35rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(31, 26, 22, 0.45);
}

.stop-card h3 {
  margin: 0 0 0.35rem;
  font-size: 1.08rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.stop-card .stop-meta {
  margin: 0 0 0.75rem;
  font-size: 0.88rem;
  color: var(--accent);
  font-weight: 600;
}

.stop-card p {
  margin: 0 0 0.75rem;
}

.stop-card p:last-child {
  margin-bottom: 1rem;
}

.recipe-sources {
  margin-top: 2rem;
  font-size: 0.88rem;
}

.recipe-sources summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 600;
}

.recipe-sources ul {
  margin-top: 0.65rem;
}
