/* On the Road — Carey's Cross-Country Trip 2026 */
:root {
  --bg: #0c0f14;
  --bg-elevated: #141a22;
  --bg-card: #1a222d;
  --bg-card-hover: #222c3a;
  --border: rgba(255, 255, 255, 0.08);
  --text: #f0ebe3;
  --text-muted: #9aa3b2;
  --text-dim: #6b7485;
  --accent: #e07a3d;
  --accent-soft: rgba(224, 122, 61, 0.15);
  --teal: #3db8a8;
  --teal-soft: rgba(61, 184, 168, 0.15);
  --gold: #d4a017;
  --blue: #5b8def;
  --purple: #8b6bc9;
  --green: #4caf7a;
  --font-display: "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Segoe UI", system-ui, -apple-system, sans-serif;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  --max: 1120px;
  --nav-h: 64px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
}

body.nav-open {
  overflow: hidden;
}

/* Background atmosphere */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 20% -10%, rgba(224, 122, 61, 0.18), transparent 50%),
    radial-gradient(ellipse 60% 40% at 90% 10%, rgba(61, 184, 168, 0.1), transparent 45%),
    radial-gradient(ellipse 50% 30% at 50% 100%, rgba(91, 141, 239, 0.08), transparent 40%);
  pointer-events: none;
  z-index: 0;
}

a {
  color: var(--teal);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  display: block;
}

/* Nav */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
  padding-top: env(safe-area-inset-top, 0px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-left: max(1rem, env(safe-area-inset-left, 0px));
  padding-right: max(1rem, env(safe-area-inset-right, 0px));
  background: rgba(12, 15, 20, 0.75);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.nav-brand {
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 0.95rem;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-brand span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  transition: color 0.15s, background 0.15s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  text-decoration: none;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  min-height: 44px;
  min-width: 44px;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
}

/* Layout */
main {
  position: relative;
  z-index: 1;
}

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

.section-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.section-lead {
  color: var(--text-muted);
  max-width: 40rem;
  font-size: 1.05rem;
  margin-bottom: 2.5rem;
}

/* Hero */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-h) + env(safe-area-inset-top, 0px) + 2rem) 1.5rem 4rem;
  max-width: var(--max);
  margin: 0 auto;
  position: relative;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.hero-kicker::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--accent);
}

.hero h1 {
  font-size: clamp(2.8rem, 9vw, 5.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 0.75rem;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--accent), var(--gold) 50%, var(--teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.hero-tagline {
  font-size: 1rem;
  color: var(--text-dim);
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
  margin-bottom: 2.5rem;
  max-width: 640px;
}

.stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.stat-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dim);
  margin-top: 0.2rem;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.75rem 1.35rem;
  min-height: 44px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, background 0.15s, box-shadow 0.15s;
  text-decoration: none;
  touch-action: manipulation;
}

.btn:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #c45f28);
  color: #fff;
  box-shadow: 0 4px 20px rgba(224, 122, 61, 0.35);
}

.btn-primary:hover {
  color: #fff;
  box-shadow: 0 6px 28px rgba(224, 122, 61, 0.5);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.motto {
  margin-top: 3rem;
  font-style: italic;
  color: var(--text-dim);
  font-size: 0.95rem;
}

.motto::before {
  content: "✦ ";
  color: var(--gold);
}

/* Map */
.map-wrap {
  border-radius: 22px;
  overflow: hidden;
  border: 6px solid #f3d27a;
  box-shadow:
    0 0 0 4px #c47a32,
    var(--shadow);
  height: min(580px, 74vh);
  background: #8fd4ff;
}

#route-map {
  width: 100%;
  height: 100%;
}

.cartoon-map {
  width: 100%;
  height: 100%;
  display: block;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
}

.cartoon-map .atlas-title {
  fill: #2a4a6a;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.cartoon-map .pin-num {
  font-size: 6.2px;
  font-weight: 800;
  fill: #3a2a18;
}

.cartoon-map .pin-label {
  font-size: 8.5px;
  font-weight: 700;
  fill: #2d3a28;
  paint-order: stroke;
  stroke: #fff8e8;
  stroke-width: 3px;
  pointer-events: none;
  opacity: 0;
}

.cartoon-map .pin-label.is-key,
.cartoon-pin:hover .pin-label {
  opacity: 1;
}

.cartoon-pin {
  cursor: pointer;
}

.cartoon-pin:hover {
  filter: brightness(1.08);
}

.cartoon-pin:hover .pin-label {
  font-size: 10px;
}

.map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin-top: 1.25rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.city-overview {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.city-overview-title {
  font-size: 1.15rem;
  margin-bottom: 0.25rem;
}

.city-overview-lead {
  color: var(--text-dim);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.city-album {
  margin-bottom: 2.25rem;
  scroll-margin-top: calc(var(--nav-h) + env(safe-area-inset-top, 0px) + 0.75rem);
}

.city-album-head {
  margin-bottom: 0.7rem;
}

.city-album-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.85rem;
  width: 100%;
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.city-album-title h3 {
  font-size: 1.15rem;
}

.city-album-title span {
  font-size: 0.8rem;
  color: var(--text-dim);
}

.collection-row,
.collection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 0.75rem;
}

.collection-tile {
  display: flex;
  flex-direction: column;
  text-align: left;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-elevated);
  color: inherit;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s;
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(224, 122, 61, 0.25);
  text-decoration: none;
}

a.collection-tile:hover {
  text-decoration: none;
  color: inherit;
}

.collection-tile:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.2);
}

.collection-photo {
  display: block;
  aspect-ratio: 4 / 3;
  background-size: cover;
  background-position: center;
}

.collection-photo.is-empty {
  opacity: 0.55;
}

.collection-copy {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.65rem 0.75rem 0.8rem;
}

.collection-name {
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.25;
}

.collection-meta {
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Chicago feature */
.feature-panel {
  background: linear-gradient(145deg, rgba(61, 184, 168, 0.12), rgba(26, 34, 45, 0.9));
  border: 1px solid rgba(61, 184, 168, 0.25);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.feature-panel h3 {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.feature-block h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--teal);
  margin-bottom: 0.5rem;
}

.feature-block ul {
  list-style: none;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.feature-block li {
  padding: 0.25rem 0;
  padding-left: 0.9rem;
  position: relative;
}

.feature-block li::before {
  content: "·";
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* Side trips */
.side-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.25rem;
}

.side-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.side-card h3 {
  font-size: 1.25rem;
}

.side-card .sub {
  color: var(--gold);
  font-size: 0.85rem;
  font-weight: 600;
}

.side-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.side-card details {
  margin-top: 0.25rem;
  border-top: 1px solid var(--border);
  padding-top: 0.75rem;
}

.side-card summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.side-card summary::after {
  content: "+";
  color: var(--text-dim);
  font-size: 1.1rem;
}

.side-card details[open] summary::after {
  content: "−";
}

.side-card details ul {
  list-style: none;
  margin-top: 0.6rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.side-card details li {
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* Summary */
.summary-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  line-height: 1.75;
  color: var(--text-muted);
}

.summary-box strong {
  color: var(--text);
}

.summary-end {
  margin-top: 1.5rem;
  text-align: center;
  font-style: italic;
  color: var(--gold);
  font-size: 1.05rem;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.modal-backdrop.open {
  display: flex;
}

.modal {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-width: 520px;
  width: 100%;
  max-height: min(85vh, 640px);
  overflow-y: auto;
  padding: 1.75rem;
  box-shadow: var(--shadow);
  position: relative;
  animation: modalIn 0.2s ease;
}

.modal.has-photos {
  max-width: 760px;
  max-height: min(90vh, 860px);
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.modal-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.1);
}

.modal-phase {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.modal h2 {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
  padding-right: 2rem;
}

.modal-role {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.modal-blurb {
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  font-size: 0.95rem;
}

.modal-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.modal-meta dt {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dim);
}

.modal-meta dd {
  font-size: 0.9rem;
  font-weight: 600;
}

.modal-section {
  margin-top: 1rem;
}

.modal-section h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 0.4rem;
}

.modal-section ul {
  list-style: none;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.modal-section li {
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 1.5rem;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  position: relative;
  z-index: 1;
}

.footer p + p {
  margin-top: 0.35rem;
}

/* Photo albums */
.photo-album {
  margin-bottom: 2.25rem;
}

.photo-album-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.photo-album-head h3 {
  font-size: 1.15rem;
}

.photo-album-head button {
  background: none;
  border: 0;
  color: var(--teal);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 0.4rem;
}

.photo-tile {
  position: relative;
  aspect-ratio: 1;
  border: 0;
  padding: 0;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: #111;
  touch-action: manipulation;
  min-height: 44px;
}

.photo-tile img,
.photo-tile video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-tile.is-video::after {
  content: "▶";
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-gallery {
  margin-top: 1.25rem;
}

.chicago-photos {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.4rem;
  margin-top: 1.5rem;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 400;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3.5rem 4.5rem 4rem;
}

.lightbox[hidden] {
  display: none;
}

.lightbox-stage {
  max-width: min(1100px, 100%);
  max-height: 100%;
}

.lightbox-stage img,
.lightbox-stage video {
  max-width: 100%;
  max-height: calc(100vh - 8rem);
  object-fit: contain;
  margin: 0 auto;
  border-radius: 6px;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
  border-radius: 50%;
}

.lightbox-close {
  top: 1rem;
  right: 1rem;
  width: 40px;
  height: 40px;
  font-size: 1.4rem;
}

.lightbox-nav {
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  font-size: 1.8rem;
  line-height: 1;
}

.lightbox-nav.prev {
  left: 1rem;
}

.lightbox-nav.next {
  right: 1rem;
}

.lightbox-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.85rem;
}

/* Touch / no-hover */
@media (hover: none) {
  .btn:hover,
  .collection-tile:hover {
    transform: none;
  }

  .cartoon-pin:hover .pin-label:not(.is-key) {
    opacity: 0;
    font-size: 8.5px;
  }
}

/* Phones & small tablets */
@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
    left: 0;
    right: 0;
    background: rgba(12, 15, 20, 0.98);
    flex-direction: column;
    align-items: stretch;
    padding: 0.75rem 1rem calc(1rem + env(safe-area-inset-bottom, 0px));
    border-bottom: 1px solid var(--border);
    max-height: calc(100dvh - var(--nav-h) - env(safe-area-inset-top, 0px));
    overflow-y: auto;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    font-size: 1rem;
    padding: 0.85rem 0.9rem;
    border-radius: 10px;
  }

  .hero {
    min-height: auto;
    padding: calc(var(--nav-h) + env(safe-area-inset-top, 0px) + 1.5rem) 1.15rem 2.75rem;
  }

  .hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: none;
    gap: 0.65rem;
  }

  .stat {
    padding: 0.85rem 0.9rem;
  }

  .stat-value {
    font-size: 1.15rem;
  }

  .hero-cta {
    width: 100%;
  }

  .hero-cta .btn {
    flex: 1 1 auto;
  }

  .section {
    padding: 3rem 1.15rem;
  }

  .section-lead {
    font-size: 0.98rem;
    margin-bottom: 1.5rem;
  }

  .map-wrap {
    height: min(420px, 62dvh);
    border-width: 4px;
    box-shadow: 0 0 0 3px #c47a32, var(--shadow);
    border-radius: 16px;
  }

  .cartoon-map .atlas-title {
    font-size: 15px;
  }

  .collection-row,
  .collection-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem;
  }

  .photo-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .feature-panel {
    padding: 1.35rem;
  }

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

  .summary-box {
    padding: 1.35rem;
  }

  .modal-backdrop {
    padding: 0;
    align-items: stretch;
    justify-content: stretch;
  }

  .modal,
  .modal.has-photos {
    max-width: none;
    max-height: none;
    height: 100%;
    border-radius: 0;
    padding: 1.25rem 1.1rem calc(1.5rem + env(safe-area-inset-bottom, 0px));
  }

  .modal-close {
    width: 44px;
    height: 44px;
    top: 0.65rem;
    right: 0.65rem;
  }

  .modal-meta {
    grid-template-columns: 1fr;
  }

  .lightbox {
    padding: 4.25rem 0.6rem calc(5.5rem + env(safe-area-inset-bottom, 0px));
  }

  .lightbox-stage img,
  .lightbox-stage video {
    max-height: calc(100dvh - 10rem);
  }

  .lightbox-close {
    top: max(0.75rem, env(safe-area-inset-top, 0px));
    right: 0.75rem;
    width: 44px;
    height: 44px;
  }

  .lightbox-nav {
    top: auto;
    bottom: calc(1.1rem + env(safe-area-inset-bottom, 0px));
    transform: none;
    width: 48px;
    height: 48px;
  }

  .lightbox-caption {
    bottom: calc(4.4rem + env(safe-area-inset-bottom, 0px));
    padding: 0 0.75rem;
    font-size: 0.8rem;
  }

  .footer {
    padding: 2rem 1.15rem calc(2rem + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 420px) {
  .hero h1 {
    font-size: 2.35rem;
  }

  .collection-row,
  .collection-grid {
    grid-template-columns: 1fr 1fr;
  }

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

/* Leaflet popup tweak */

