/* ==========================================================================
   NORTHERN COMPASS — EXPEDITION DISPATCHES & WILDERNESS JOURNAL
   Autonomous Design System | Natural Palette | High Air Ratio
   ========================================================================== */

:root {
  --bg-deep: #0b1318;
  --bg-surface: #131f26;
  --bg-card: #182730;
  --bg-elevated: #20333e;

  --border-subtle: rgba(245, 243, 233, 0.08);
  --border-medium: rgba(245, 243, 233, 0.16);
  --border-accent: rgba(224, 169, 109, 0.45);

  --text-pure: #ffffff;
  --text-high: #f5f3e9;
  --text-mid: #a8b8b6;
  --text-muted: #6f8582;

  --accent-amber: #e0a96d;
  --accent-amber-glow: rgba(224, 169, 109, 0.2);
  --accent-moss: #52796f;

  --font-serif: "Playfair Display", "Cormorant Garamond", Georgia, serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;

  --max-w: 1360px;
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background-color: var(--bg-deep);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-deep);
  color: var(--text-high);
  font-family: var(--font-sans);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* Atmospheric Topographic Map Backdrop */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(circle at 18% 18%, rgba(224, 169, 109, 0.05) 0%, transparent 45%),
    radial-gradient(circle at 82% 28%, rgba(82, 121, 111, 0.08) 0%, transparent 50%),
    linear-gradient(rgba(245, 243, 233, 0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245, 243, 233, 0.012) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 64px 64px, 64px 64px;
  pointer-events: none;
  z-index: 0;
}

:focus-visible {
  outline: 2px solid var(--accent-amber);
  outline-offset: 4px;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 400;
  color: var(--text-pure);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

h1 {
  font-size: clamp(3rem, 5.5vw, 5.2rem);
  margin-bottom: 2rem;
}

h2 {
  font-size: clamp(2.2rem, 3.8vw, 3.2rem);
  margin-bottom: 1.5rem;
}

h3 {
  font-size: clamp(1.4rem, 2.2vw, 2rem);
  margin-bottom: 0.85rem;
}

p {
  color: var(--text-mid);
  font-size: 1.1rem;
  line-height: 1.85;
  font-weight: 300;
  margin-bottom: 1.5rem;
}

.mono-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-amber);
  margin-bottom: 1.5rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(11, 19, 24, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
}

.header-container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 1.35rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--text-pure);
}

.brand-icon {
  width: 32px;
  height: 32px;
  transition: transform 0.6s var(--ease-expo);
}

.brand:hover .brand-icon {
  transform: rotate(45deg);
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 500;
}

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

.site-nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--text-mid);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.35rem 0;
  position: relative;
  transition: color 0.2s ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent-amber);
  transition: width 0.35s var(--ease-expo);
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--text-pure);
}

.site-nav a.active::after,
.site-nav a:hover::after {
  width: 100%;
}

/* Main */
.site-main {
  flex: 1;
  max-width: var(--max-w);
  width: 100%;
  margin: 0 auto;
  padding: 6.5rem 2.5rem 8.5rem;
  position: relative;
  z-index: 1;
}

.hero-strip {
  padding-bottom: 5.5rem;
  margin-bottom: 6rem;
  border-bottom: 1px solid var(--border-subtle);
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 5rem;
  align-items: end;
}

.hero-quote {
  border-left: 1px solid var(--border-accent);
  padding-left: 2.25rem;
  color: var(--text-mid);
  font-size: 1.25rem;
  line-height: 1.85;
  font-weight: 300;
}

/* Metrics Row */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  margin-bottom: 6rem;
}

.metric-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 2.25rem 2rem;
  border-radius: 4px;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.metric-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-accent);
}

.metric-num {
  font-family: var(--font-serif);
  font-size: 3.2rem;
  color: var(--accent-amber);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.metric-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Featured Expedition Showcase */
.featured-case {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 6.5rem;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  transition: border-color 0.4s ease, transform 0.4s var(--ease-expo);
}

.featured-case:hover {
  border-color: var(--border-accent);
  transform: translateY(-6px);
  box-shadow: 0 30px 60px -25px rgba(0, 0, 0, 0.7);
}

.featured-canvas {
  min-height: 460px;
  background: #091015;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--border-subtle);
}

.featured-canvas svg {
  width: 100%;
  height: 100%;
}

.featured-info {
  padding: 4.5rem 3.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Expeditions Asymmetric Grid */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 3.5rem 2.5rem;
  margin-bottom: 6.5rem;
}

.col-7 { grid-column: span 7; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }

.catalog-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s var(--ease-expo), border-color 0.4s ease;
}

.catalog-item:hover {
  border-color: var(--border-accent);
  transform: translateY(-8px);
}

.catalog-viewport {
  height: 340px;
  background: #091015;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-subtle);
  overflow: hidden;
}

.catalog-viewport.tall {
  height: 440px;
}

.catalog-viewport svg {
  width: 100%;
  height: 100%;
  transition: transform 0.6s var(--ease-expo);
}

.catalog-item:hover .catalog-viewport svg {
  transform: scale(1.04);
}

.catalog-details {
  padding: 2.75rem 2.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.catalog-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-amber);
  margin-bottom: 1rem;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: auto;
  padding-top: 1.75rem;
}

.pill {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-mid);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 0.3rem 0.75rem;
  border-radius: 2px;
}

/* Gear & Provisions Grid (Materials Equivalent) */
.specimen-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 3rem;
  margin-bottom: 6rem;
}

.specimen-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 3rem 2.5rem;
  border-radius: 4px;
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.specimen-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-5px);
}

.specimen-header {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  margin-bottom: 2rem;
}

.swatch {
  width: 76px;
  height: 76px;
  border-radius: 4px;
  border: 1px solid var(--border-medium);
  flex-shrink: 0;
}

.swatch-canvas { background: linear-gradient(135deg, #78350f, #292524); }
.swatch-wool { background: linear-gradient(135deg, #44403c, #1c1917); }
.swatch-optics { background: linear-gradient(135deg, #134e4a, #042f2e); }
.swatch-alloy { background: linear-gradient(135deg, #475569, #1e293b); }

.specimen-params {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem 1rem;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  font-size: 0.9rem;
}

.param-k {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  color: var(--text-muted);
  display: block;
}

.param-v {
  color: var(--text-high);
}

/* Expedition Logistics Track (Process Equivalent) */
.timeline-track {
  position: relative;
  max-width: 1100px;
  margin: 4rem auto 6.5rem;
  padding-left: 5rem;
}

.timeline-track::before {
  content: "";
  position: absolute;
  left: 24px;
  top: 20px;
  bottom: 30px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-amber) 0%, rgba(224, 169, 109, 0.15) 100%);
}

.step-card {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 3.5rem;
  border-radius: 4px;
  margin-bottom: 3.5rem;
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.step-card:hover {
  border-color: var(--border-accent);
  transform: translateX(8px);
}

.step-node {
  position: absolute;
  left: -5rem;
  top: 3.25rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-deep);
  border: 2px solid var(--accent-amber);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--accent-amber);
  box-shadow: 0 0 16px var(--accent-amber-glow);
}

.step-diagram-box {
  margin: 2.25rem 0 1.25rem;
  background: #080f14;
  border: 1px solid var(--border-subtle);
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.step-diagram-box svg {
  width: 100%;
  height: 100%;
}

/* Journal Broadsheet */
.broadsheet {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  gap: 4.5rem;
  margin-bottom: 6.5rem;
}

.broadsheet-primary {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 4rem 3.5rem;
  border-radius: 4px;
  display: flex;
  flex-direction: column;
}

.broadsheet-graphic {
  height: 280px;
  background: #080f14;
  border: 1px solid var(--border-subtle);
  margin: 2.5rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.broadsheet-graphic svg {
  width: 100%;
  height: 100%;
}

.broadsheet-column {
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
}

.dispatch-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 2.5rem 2.25rem;
  border-radius: 4px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.dispatch-box:hover {
  border-color: var(--border-accent);
  transform: translateY(-4px);
}

/* About Section Matrices */
.matrix-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2.5rem;
  margin: 4rem 0 6rem;
}

.matrix-cell {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 3rem 2.5rem;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.matrix-cell::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--accent-amber);
  opacity: 0.7;
}

.profile-pod {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 3.5rem;
  border-radius: 4px;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 3rem;
  align-items: center;
  margin-bottom: 2.5rem;
}

.profile-avatar {
  width: 120px;
  height: 120px;
  border: 1px solid var(--border-accent);
  background: #091015;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Tables & Shared Components */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 3rem 0 5rem;
  font-size: 0.95rem;
}

.data-table th,
.data-table td {
  padding: 1.4rem 1.75rem;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.data-table th {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-medium);
  background: rgba(245, 243, 233, 0.02);
}

.data-table td {
  color: var(--text-mid);
  font-weight: 300;
}

.data-table tr:hover td {
  background: var(--bg-surface);
  color: var(--text-pure);
}

.data-table .highlight {
  color: var(--text-pure);
  font-weight: 500;
}

.quote-banner {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--accent-amber);
  padding: 3.5rem 4rem;
  margin: 4.5rem 0;
}

.quote-banner p {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 300;
  line-height: 1.6;
  color: var(--text-pure);
  margin-bottom: 1.5rem;
}

.quote-banner span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-amber);
  display: block;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  background: #080e12;
  padding: 5rem 2.5rem 3.5rem;
  position: relative;
  z-index: 10;
}

.footer-grid {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2.2fr 1fr 1fr;
  gap: 5rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid var(--border-subtle);
}

.footer-title {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  letter-spacing: 0.15em;
  color: var(--text-pure);
  margin-bottom: 1.25rem;
}

.footer-col-header {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-amber);
  margin-bottom: 1.5rem;
}

.footer-nav {
  list-style: none;
}

.footer-nav li {
  margin-bottom: 0.85rem;
}

.footer-nav a {
  color: var(--text-mid);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-nav a:hover {
  color: var(--text-pure);
}

.footer-bottom {
  max-width: var(--max-w);
  margin: 2.5rem auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: 1.25rem;
}

@media (max-width: 1080px) {
  .hero-strip,
  .featured-case,
  .broadsheet,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 3.5rem;
  }
  .col-7, .col-5, .col-6 {
    grid-column: span 12;
  }
  .featured-canvas {
    border-right: none;
    border-bottom: 1px solid var(--border-subtle);
  }
}

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.25rem 1.5rem;
  }
  .site-nav ul {
    gap: 1rem 1.25rem;
  }
  .site-main {
    padding: 4rem 1.5rem 6rem;
  }
  .timeline-track {
    padding-left: 3rem;
  }
  .timeline-track::before {
    left: 12px;
  }
  .step-node {
    left: -3rem;
    width: 36px;
    height: 36px;
    font-size: 0.75rem;
  }
  .profile-pod {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 2.5rem;
  }
  .profile-avatar {
    margin: 0 auto;
  }
  .quote-banner {
    padding: 2.5rem 2rem;
  }
}