/* ============================================================
   NewRiverNavigation.com — Global Stylesheet
   Design: High-contrast dark mode, mobile-first, premium
   Typography: Inter (headers) + Roboto Mono (data/citations)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Roboto+Mono:wght@400;500&display=swap');

/* ── DESIGN TOKENS ──────────────────────────────────────── */
:root {
  --navy:        #0a0f1e;
  --navy-mid:    #111827;
  --navy-light:  #1e2a3a;
  --amber:       #f59e0b;
  --amber-light: #fcd34d;
  --red-alert:   #ef4444;
  --green-safe:  #10b981;
  --blue-data:   #38bdf8;
  --text-primary: #f0f4f8;
  --text-secondary: #94a3b8;
  --text-muted:  #64748b;
  --border:      #1e2d40;
  --card-bg:     #111827;
  --card-hover:  #162032;

  --font-heading: 'Inter', sans-serif;
  --font-mono:    'Roboto Mono', monospace;

  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   20px;

  --shadow-card: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 40px rgba(245,158,11,0.12);

  --transition: 0.2s ease;
  --max-width: 1200px;
}

/* ── RESET ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-heading);
  background: var(--navy);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--amber); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--amber-light); }

/* ── UTILITY ─────────────────────────────────────────────── */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 5rem 0; }
.section--tight { padding: 3rem 0; }
.text-amber { color: var(--amber); }
.text-mono { font-family: var(--font-mono); }
.text-muted { color: var(--text-secondary); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ── NAVIGATION ──────────────────────────────────────────── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(10, 15, 30, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.nav.scrolled { box-shadow: 0 2px 24px rgba(0,0,0,0.5); }
.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.5rem; max-width: var(--max-width); margin: 0 auto;
}
.nav__brand {
  display: flex; align-items: center; gap: 0.75rem;
  font-weight: 700; font-size: 1.05rem; color: var(--text-primary);
  text-decoration: none;
}
.nav__brand-icon {
  width: 36px; height: 36px; background: var(--amber);
  border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: var(--navy); font-weight: 900;
}
.nav__links {
  display: flex; align-items: center; gap: 0.25rem;
  list-style: none;
}
.nav__links a {
  padding: 0.5rem 0.85rem; border-radius: var(--radius-sm);
  font-size: 0.9rem; font-weight: 500; color: var(--text-secondary);
  transition: all var(--transition);
}
.nav__links a:hover, .nav__links a.active {
  color: var(--text-primary); background: var(--navy-light);
}
.nav__cta {
  background: var(--amber); color: var(--navy);
  padding: 0.5rem 1.1rem; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 0.875rem;
  transition: background var(--transition);
}
.nav__cta:hover { background: var(--amber-light); color: var(--navy); }
.nav__hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 4px;
}
.nav__hamburger span {
  width: 24px; height: 2px; background: var(--text-primary);
  border-radius: 2px; transition: all var(--transition);
}
.nav__mobile {
  display: none; flex-direction: column;
  background: var(--navy-mid); border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
}
.nav__mobile a {
  padding: 0.75rem 0; border-bottom: 1px solid var(--border);
  font-weight: 500; color: var(--text-secondary);
}
.nav__mobile a:last-child { border-bottom: none; }
@media (max-width: 768px) {
  .nav__links, .nav__cta { display: none; }
  .nav__hamburger { display: flex; }
  .nav__mobile.open { display: flex; }
}

/* ── HERO ────────────────────────────────────────────────── */
.hero {
  min-height: 100vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
  padding-top: 80px;
  background: linear-gradient(135deg, var(--navy) 0%, #0d1a2e 50%, #0a1628 100%);
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(245,158,11,0.06) 0%, transparent 60%),
              radial-gradient(ellipse at 80% 20%, rgba(56,189,248,0.04) 0%, transparent 50%);
}
.hero__grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 4rem; align-items: center; position: relative; z-index: 1;
}
.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: rgba(245,158,11,0.12); border: 1px solid rgba(245,158,11,0.3);
  border-radius: 100px; padding: 0.35rem 0.9rem;
  font-size: 0.78rem; font-weight: 600; color: var(--amber);
  font-family: var(--font-mono); letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}
.hero__eyebrow::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%;
  background: var(--amber); animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}
.hero__title {
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 900; line-height: 1.1;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}
.hero__title span { color: var(--amber); }
.hero__subtitle {
  font-size: 1.15rem; color: var(--text-secondary);
  line-height: 1.7; margin-bottom: 2.5rem; max-width: 520px;
}
.hero__actions { display: flex; gap: 1rem; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.8rem 1.75rem; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 0.95rem;
  transition: all var(--transition); cursor: pointer; border: none;
}
.btn--primary {
  background: var(--amber); color: var(--navy);
}
.btn--primary:hover { background: var(--amber-light); color: var(--navy); transform: translateY(-2px); }
.btn--ghost {
  background: transparent; color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn--ghost:hover { background: var(--navy-light); border-color: var(--amber); color: var(--amber); }
.hero__visual {
  position: relative;
}
.hero__map-card {
  background: var(--navy-mid); border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-card), var(--shadow-glow);
}
.hero__map-placeholder {
  aspect-ratio: 4/3; background: linear-gradient(135deg, #0d2137 0%, #0f2b3d 50%, #0a1f30 100%);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem;
  position: relative; overflow: hidden;
}
.hero__map-placeholder::after {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 30px,
    rgba(56,189,248,0.03) 30px, rgba(56,189,248,0.03) 31px
  ),
  repeating-linear-gradient(
    90deg, transparent, transparent 30px,
    rgba(56,189,248,0.03) 30px, rgba(56,189,248,0.03) 31px
  );
}
.hero__map-label {
  font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--blue-data); text-align: center; z-index: 1;
  background: rgba(0,0,0,0.5); padding: 0.5rem 1rem; border-radius: var(--radius-sm);
  border: 1px solid rgba(56,189,248,0.2);
}
.hero__map-icon { font-size: 3rem; z-index: 1; }
.hero__map-footer {
  padding: 1rem 1.25rem; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.hero__map-stat { font-family: var(--font-mono); font-size: 0.78rem; }
.hero__map-stat strong { color: var(--amber); display: block; font-size: 1.1rem; }
@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero__visual { order: -1; }
}

/* ── ALERT BANNER ────────────────────────────────────────── */
.alert-banner {
  background: linear-gradient(90deg, rgba(239,68,68,0.15), rgba(239,68,68,0.08));
  border-left: 4px solid var(--red-alert);
  border-radius: var(--radius-sm); padding: 1rem 1.5rem;
  display: flex; align-items: flex-start; gap: 1rem;
  margin-bottom: 2rem;
}
.alert-banner__icon { font-size: 1.25rem; flex-shrink: 0; margin-top: 2px; }
.alert-banner__text { font-size: 0.9rem; line-height: 1.5; }
.alert-banner__text strong { color: var(--red-alert); }

/* ── STAT STRIP ──────────────────────────────────────────── */
.stat-strip {
  background: var(--navy-mid); border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat-strip__inner {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 0; max-width: var(--max-width); margin: 0 auto;
}
.stat-strip__item {
  padding: 2rem 1.5rem; text-align: center;
  border-right: 1px solid var(--border);
  transition: background var(--transition);
}
.stat-strip__item:last-child { border-right: none; }
.stat-strip__item:hover { background: var(--navy-light); }
.stat-strip__value {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 900; color: var(--amber);
  font-family: var(--font-mono); display: block;
}
.stat-strip__label { font-size: 0.82rem; color: var(--text-secondary); margin-top: 0.25rem; }
@media (max-width: 640px) {
  .stat-strip__inner { grid-template-columns: repeat(2, 1fr); }
  .stat-strip__item:nth-child(2) { border-right: none; }
}

/* ── SECTION HEADER ──────────────────────────────────────── */
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-header__eyebrow {
  font-family: var(--font-mono); font-size: 0.78rem; font-weight: 500;
  color: var(--amber); letter-spacing: 0.1em; text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.section-header__title {
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 800; line-height: 1.2; letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
.section-header__subtitle {
  font-size: 1.05rem; color: var(--text-secondary);
  max-width: 600px; margin: 0 auto; line-height: 1.7;
}

/* ── CARDS ───────────────────────────────────────────────── */
.card {
  background: var(--card-bg); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 1.75rem;
  transition: all var(--transition);
}
.card:hover { background: var(--card-hover); border-color: rgba(245,158,11,0.3); transform: translateY(-3px); box-shadow: var(--shadow-card); }
.card__icon {
  width: 48px; height: 48px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 1.25rem;
}
.card__icon--amber { background: rgba(245,158,11,0.12); }
.card__icon--red { background: rgba(239,68,68,0.12); }
.card__icon--blue { background: rgba(56,189,248,0.12); }
.card__icon--green { background: rgba(16,185,129,0.12); }
.card__title { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.75rem; }
.card__text { font-size: 0.92rem; color: var(--text-secondary); line-height: 1.65; }
.card__cite {
  margin-top: 1rem; font-family: var(--font-mono); font-size: 0.72rem;
  color: var(--text-muted); background: var(--navy);
  padding: 0.35rem 0.6rem; border-radius: var(--radius-sm);
  display: inline-block;
}

/* ── GRID LAYOUTS ────────────────────────────────────────── */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

/* ── PULL QUOTE ──────────────────────────────────────────── */
.pull-quote {
  border-left: 4px solid var(--amber); padding: 1.5rem 2rem;
  background: rgba(245,158,11,0.05); border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 2.5rem 0;
}
.pull-quote__text {
  font-size: 1.2rem; font-weight: 600; line-height: 1.5;
  color: var(--text-primary); font-style: italic;
}
.pull-quote__attr {
  margin-top: 0.75rem; font-size: 0.82rem;
  color: var(--text-muted); font-family: var(--font-mono);
}

/* ── ACTION CARDS (THE THREE ASKS) ──────────────────────── */
.action-card {
  background: var(--navy-mid); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 2rem;
  display: flex; gap: 1.5rem; align-items: flex-start;
  transition: all var(--transition);
}
.action-card:hover { border-color: var(--amber); background: var(--card-hover); }
.action-card__number {
  font-family: var(--font-mono); font-size: 2.5rem; font-weight: 900;
  color: var(--amber); opacity: 0.4; flex-shrink: 0; line-height: 1;
  min-width: 3rem; text-align: center;
}
.action-card__title { font-size: 1.05rem; font-weight: 700; margin-bottom: 0.5rem; }
.action-card__text { font-size: 0.9rem; color: var(--text-secondary); line-height: 1.65; }

/* ── JURISDICTION TABLE ──────────────────────────────────── */
.juris-table {
  width: 100%; border-collapse: collapse;
  background: var(--card-bg); border-radius: var(--radius-md);
  overflow: hidden; box-shadow: var(--shadow-card);
}
.juris-table th {
  background: var(--navy-light); padding: 0.9rem 1.25rem;
  text-align: left; font-size: 0.8rem; font-weight: 600;
  color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em;
  font-family: var(--font-mono);
}
.juris-table td {
  padding: 0.9rem 1.25rem; border-top: 1px solid var(--border);
  font-size: 0.9rem; vertical-align: top;
}
.juris-table td:first-child { font-weight: 600; color: var(--amber); width: 30%; }
.juris-table tr:hover td { background: var(--card-hover); }

/* ── Q&A ACCORDION ───────────────────────────────────────── */
.qa-item {
  border: 1px solid var(--border); border-radius: var(--radius-md);
  overflow: hidden; margin-bottom: 1rem;
  transition: border-color var(--transition);
}
.qa-item:hover { border-color: rgba(245,158,11,0.3); }
.qa-item__question {
  width: 100%; text-align: left; padding: 1.25rem 1.5rem;
  background: var(--card-bg); border: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-heading); font-size: 1rem; font-weight: 600;
  color: var(--text-primary); transition: background var(--transition);
  gap: 1rem;
}
.qa-item__question:hover { background: var(--card-hover); }
.qa-item__chevron {
  flex-shrink: 0; width: 20px; height: 20px;
  border-radius: 50%; background: rgba(245,158,11,0.15);
  display: flex; align-items: center; justify-content: center;
  color: var(--amber); font-size: 0.7rem;
  transition: transform var(--transition);
}
.qa-item.open .qa-item__chevron { transform: rotate(180deg); }
.qa-item__answer {
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 1.5rem;
  font-size: 0.95rem; color: var(--text-secondary); line-height: 1.7;
}
.qa-item.open .qa-item__answer { max-height: 400px; padding: 1.25rem 1.5rem; }
.qa-item__note {
  margin-top: 0.75rem; padding: 0.75rem 1rem;
  background: rgba(245,158,11,0.07); border-left: 3px solid var(--amber);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.82rem; font-family: var(--font-mono); color: var(--amber);
}

/* ── BARGE VISUAL ────────────────────────────────────────── */
.barge-diagram {
  background: var(--navy-mid); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2rem; text-align: center;
  position: relative; overflow: hidden;
}
.barge-diagram::before {
  content: ''; position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 120%; height: 40%;
  background: rgba(56,189,248,0.06);
  border-top: 1px dashed rgba(56,189,248,0.2);
  border-bottom: 1px dashed rgba(56,189,248,0.2);
}
.barge-diagram__label {
  font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--blue-data); margin-bottom: 1.5rem;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.barge-box {
  display: inline-block; position: relative; z-index: 1;
  background: rgba(239,68,68,0.15); border: 2px solid var(--red-alert);
  border-radius: var(--radius-sm);
  width: 80%; max-width: 400px; height: 72px;
  display: flex; align-items: center; justify-content: center;
}
.barge-box__text {
  font-family: var(--font-mono); font-size: 0.88rem; font-weight: 500;
  color: var(--red-alert);
}
.barge-dims {
  display: flex; justify-content: center; gap: 2rem;
  margin-top: 1.5rem; position: relative; z-index: 1;
}
.barge-dim { text-align: center; }
.barge-dim__value { font-family: var(--font-mono); font-size: 1.4rem; font-weight: 700; color: var(--amber); }
.barge-dim__label { font-size: 0.78rem; color: var(--text-muted); }

/* ── FOOTER ──────────────────────────────────────────────── */
.footer {
  background: var(--navy-mid); border-top: 1px solid var(--border);
  padding: 3rem 0;
}
.footer__inner {
  display: grid; grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem; max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem;
}
.footer__brand p { font-size: 0.88rem; color: var(--text-secondary); margin-top: 0.75rem; line-height: 1.6; }
.footer__heading { font-size: 0.82rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 1rem; font-family: var(--font-mono); }
.footer__links { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.footer__links a { font-size: 0.88rem; color: var(--text-secondary); }
.footer__links a:hover { color: var(--amber); }
.footer__bottom {
  border-top: 1px solid var(--border); margin-top: 2.5rem; padding-top: 1.5rem;
  text-align: center; font-size: 0.8rem; color: var(--text-muted);
  font-family: var(--font-mono);
}
@media (max-width: 768px) {
  .footer__inner { grid-template-columns: 1fr; gap: 2rem; }
}

/* ── PAGE HERO (INNER PAGES) ─────────────────────────────── */
.page-hero {
  padding: 9rem 0 4rem;
  background: linear-gradient(135deg, var(--navy) 0%, #0d1a2e 100%);
  border-bottom: 1px solid var(--border); position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 50%, rgba(245,158,11,0.05) 0%, transparent 60%);
}
.page-hero__inner { position: relative; z-index: 1; }
.page-hero__eyebrow {
  font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--amber); letter-spacing: 0.1em; text-transform: uppercase;
  margin-bottom: 1rem;
}
.page-hero__title {
  font-size: clamp(2rem, 4vw, 3rem); font-weight: 900;
  line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 1rem;
}
.page-hero__subtitle {
  font-size: 1.1rem; color: var(--text-secondary);
  max-width: 580px; line-height: 1.7;
}

/* ── HIGHLIGHT BOX ───────────────────────────────────────── */
.highlight-box {
  background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.25);
  border-radius: var(--radius-md); padding: 1.75rem 2rem; margin: 2rem 0;
}
.highlight-box__title {
  font-weight: 700; font-size: 1rem; color: var(--amber);
  margin-bottom: 0.75rem; font-family: var(--font-mono);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.highlight-box p { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.7; }

/* ── SCROLL ANIMATION ────────────────────────────────────── */
.fade-in { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ── MAP CARDS (MAPS PAGE) ───────────────────────────────── */
.choke-point {
  margin-bottom: 5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 4rem;
}
.choke-point:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.choke-point__header {
  margin-bottom: 2rem;
}
.choke-point__title {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}
.choke-point__desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 800px;
}
.map-card {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.map-card:hover {
  border-color: rgba(245,158,11,0.3);
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
}
.map-card__header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--navy-light);
}
.map-card__type {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.type--geometry {
  color: var(--blue-data);
}
.type--barge {
  color: var(--green-safe);
}
.map-card__scale {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
}
.map-card__image-container {
  background: #050a15;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.map-card__image {
  width: 100%;
  height: auto;
  transition: transform 0.3s ease;
}
.map-card:hover .map-card__image {
  transform: scale(1.02);
}
.map-card__footer {
  padding: 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  background: var(--navy-mid);
  flex-grow: 1;
}

/* ── MAP CHOKE POINT LAYOUT (maps/index.njk) ── */
.cpx {
  margin-bottom: 5rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid var(--border);
  width: 100%;
}
.cpx:last-of-type {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 2rem;
}
.cpx__header {
  max-width: 800px;
  margin: 0 auto 3rem;
  text-align: center;
  padding: 0 1.5rem;
}
.cpx__number {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}
.cpx__title {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  color: var(--text-primary);
}
.cpx__desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ── IMAGE PANEL (maps/index.njk) ── */
.img-panel {
  max-width: 1400px; /* Expands to a wider layout than standard 1200px */
  width: 95vw;
  margin: 0 auto 3.5rem;
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: border-color var(--transition), transform var(--transition);
}
.img-panel:hover {
  border-color: rgba(245,158,11,0.3);
}
.img-panel__label-bar {
  padding: 1rem 1.5rem;
  background: var(--navy-light);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.img-panel__type {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.img-panel__type--geometry {
  color: var(--blue-data);
}
.img-panel__type--barge {
  color: var(--green-safe);
}
.img-panel__meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: right;
  line-height: 1.4;
}
.img-panel__scroll {
  width: 100%;
  overflow-x: auto;
  background: #050a15;
  cursor: grab;
  /* Smooth scrolling on touch devices */
  -webkit-overflow-scrolling: touch;
}
.img-panel__img {
  display: block;
  min-width: 1200px; /* Ensures detail is large enough to see well and clear even on smaller screens */
  width: 100%;
  height: auto;
  max-width: none; /* Allows the image to expand beyond parent width if smaller screen */
  transition: transform 0.3s ease;
}
@media (min-width: 1280px) {
  .img-panel__img {
    min-width: 100%; /* Scale fully to fill container on wide desktop viewports */
  }
}
.img-panel__caption {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.65;
  background: var(--navy-mid);
}

/* ── SCROLL HINTS & UTILITIES ── */
.scroll-hint {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--amber);
  opacity: 0.8;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* ── MAPS INTRO SECTION (maps/index.njk) ── */
.maps-intro {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ── LEGEND GRID ── */
.legend-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}
@media (max-width: 768px) {
  .legend-grid {
    grid-template-columns: 1fr;
  }
}
.legend-card {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  transition: border-color var(--transition);
}
.legend-card:hover {
  border-color: rgba(245, 158, 11, 0.2);
}
.legend-card__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}
.legend-card__title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.legend-card__body {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ── JUMP NAV ── */
.jump-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1.25rem;
  margin-bottom: 2rem;
}
.jump-nav__link {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--amber);
  transition: color var(--transition);
}
.jump-nav__link:hover {
  color: var(--amber-light);
  text-decoration: underline;
}

