:root {
  --ink: #0b3539;
  --muted: #607d7e;
  --paper: #f6faf5;
  --aqua: #22b8aa;
  --aqua-dark: #067f7a;
  --coral: #ff6f5d;
  --line: #dce9e5;
  --race: #071f29;
  --display: 'Manrope', sans-serif;
  --body: 'DM Sans', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { max-width: 100%; overflow-x: hidden; }
body { font-family: var(--body); color: var(--ink); background: var(--paper); line-height: 1.6; }
.container { width: min(1120px, calc(100% - 32px)); margin: auto; }
a { color: inherit; text-decoration: none; }

.stage-header { padding: 18px 0; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.92); }
.stage-header .container { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { font: 800 .9rem var(--display); letter-spacing: .08em; }
.brand span { color: var(--aqua); }
.stage-header-actions { display: flex; align-items: center; gap: 22px; }
.stage-studio-link { display: inline-flex; align-items: center; gap: 7px; color: #28366e; font: 800 .68rem var(--display); letter-spacing: .035em; }
.stage-studio-link img { width: 28px; height: 28px; object-fit: contain; }
.stage-studio-link em { color: #008dd2; font-style: normal; }
.back { font-weight: 800; color: var(--aqua-dark); }
.stage-studio-link:focus-visible, .back:focus-visible, .stage-footer-brand:focus-visible, .stage-actions a:focus-visible, .stage-nav a:focus-visible, .photo-credit summary:focus-visible { outline: 3px solid var(--coral); outline-offset: 4px; }

.stage-main { padding: clamp(48px, 7vw, 82px) 0; }
.crumbs { margin-bottom: 24px; color: var(--muted); font-size: .72rem; }
.stage-kicker { color: var(--aqua-dark); font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.stage-main h1 { max-width: 1000px; margin: 14px 0 22px; font: 800 clamp(2.55rem, 7vw, 5.25rem)/1.02 var(--display); letter-spacing: -.055em; }
.lead { max-width: 780px; margin-bottom: 34px; color: #486d6f; font-size: clamp(1.02rem, 2vw, 1.18rem); }

.stage-visual { position: relative; margin: 0 0 46px; border-radius: 28px; overflow: hidden; background: #dcebe8; box-shadow: 0 22px 56px rgba(11,53,57,.12); }
.stage-photo { display: block; width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.photo-credit { position: absolute; right: 14px; bottom: 14px; z-index: 2; color: #fff; }
.photo-credit summary { display: inline-flex; align-items: center; min-height: 32px; padding: 6px 10px; border: 1px solid rgba(255,255,255,.38); border-radius: 999px; background: rgba(7,31,41,.74); backdrop-filter: blur(10px); cursor: pointer; list-style: none; font-size: .68rem; font-weight: 800; }
.photo-credit summary::-webkit-details-marker { display: none; }
.photo-credit div { position: absolute; right: 0; bottom: 40px; display: grid; gap: 5px; width: max-content; max-width: min(330px, calc(100vw - 52px)); padding: 12px 14px; border-radius: 12px; background: rgba(7,31,41,.94); box-shadow: 0 14px 30px rgba(0,0,0,.2); font-size: .7rem; }
.photo-credit a { color: #8af1e8; text-decoration: underline; text-underline-offset: 2px; }

.stage-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(30px, 5vw, 62px); align-items: start; }
.stage-grid > * { min-width: 0; }
.territory-story h2 { margin: 10px 0 15px; font: 800 clamp(1.85rem, 4vw, 2.55rem)/1.12 var(--display); }
.territory-story > p:not(.stage-kicker) { max-width: 640px; color: #486d6f; font-size: 1.05rem; }
.stage-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 25px; }
.stage-actions a { display: inline-flex; min-height: 45px; align-items: center; justify-content: center; padding: 11px 17px; border-radius: 999px; font-weight: 800; color: var(--aqua-dark); }
.stage-actions .gpx-button { background: var(--race); color: #fff; }

.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.facts div { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.facts small { display: block; color: var(--muted); }
.facts strong { display: block; overflow-wrap: anywhere; font: 800 clamp(1rem, 2.2vw, 1.28rem) var(--display); }

.territory-stories { margin-top: 58px; padding-top: 34px; border-top: 1px solid var(--line); }
.territory-stories-heading { margin-bottom: 22px; }
.territory-stories-heading h2 { margin-top: 8px; font: 800 clamp(1.7rem, 4vw, 2.45rem)/1.12 var(--display); }
.territory-stories-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.territory-mini-story { display: flex; min-width: 0; min-height: 280px; flex-direction: column; padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.territory-mini-story h3 { margin: 13px 0 11px; font: 800 1.2rem/1.2 var(--display); }
.territory-mini-story > p:not(.stage-kicker) { color: #486d6f; }
.territory-mini-story a { margin-top: auto; padding-top: 18px; color: var(--aqua-dark); font-weight: 800; }

.stage-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 60px; padding-top: 24px; border-top: 1px solid var(--line); }
.stage-nav a { min-width: 0; color: var(--aqua-dark); font-weight: 800; overflow-wrap: anywhere; }
.stage-nav a:last-child { text-align: right; }
.route-note { margin-top: 24px; color: var(--muted); font-size: .78rem; }

.stage-footer { padding: 28px 0; background: var(--race); color: #fff; }
.stage-footer .container { display: flex; align-items: center; justify-content: space-between; gap: 20px; color: #b9d0cf; font-size: .78rem; }
.stage-footer-brand { display: inline-flex; align-items: center; gap: 10px; }
.stage-footer-brand > span { color: #70ddd4; font-size: .66rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.stage-footer-brand img { display: block; width: 132px; height: 44px; object-fit: contain; object-position: right center; }

@media (max-width: 700px) {
  .stage-main { padding: 48px 0; }
  .stage-header-actions { gap: 13px; }
  .stage-studio-link span { display: none; }
  .stage-grid { grid-template-columns: minmax(0, 1fr); }
  .territory-stories-grid { grid-template-columns: minmax(0, 1fr); }
  .territory-mini-story { min-height: auto; }
  .stage-visual { margin-bottom: 36px; border-radius: 20px; }
  .stage-photo { aspect-ratio: 4/3; }
  .stage-nav { margin-top: 44px; }
  .stage-footer .container { align-items: flex-start; flex-direction: column; }
  .stage-footer-brand img { object-position: left center; }
}

@media (max-width: 420px) {
  .container { width: calc(100% - 24px); }
  .stage-header .container { gap: 9px; }
  .brand { font-size: .7rem; }
  .stage-header-actions { gap: 8px; }
  .stage-studio-link img { width: 24px; height: 24px; }
  .back { font-size: .7rem; }
  .stage-main h1 { font-size: clamp(2.25rem, 12vw, 2.85rem); }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .stage-nav { grid-template-columns: minmax(0, 1fr); }
  .stage-nav a:last-child { text-align: left; }
}

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