@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,500;0,600;0,700;1,400;1,600&family=Manrope:wght@300;400;500;600;700;800&family=Material+Icons+Outlined&display=swap');

:root {
  /* Brand Color Palette */
  --color-forest-green: #234f3d;
  --color-forest-dark: #19382c;
  --color-forest-light: #2e664f;
  --color-summit-gold: #c8a24d;
  --color-summit-gold-hover: #b38e3a;
  --color-summit-gold-light: #f5eedb;
  --color-glacier-white: #f8f8f5;
  --color-charcoal: #2b2b2b;
  --color-charcoal-muted: #595959;
  --color-stone-grey: #d9d6cf;
  --color-stone-light: #eceae5;
  --color-mist-green: #dde7df;
  --color-mist-light: #eef3ef;
  --color-volcanic-slate: #45514d;
  --color-danger: #c0392b;
  --color-danger-light: #fbeeeea0;
  --color-success: #27ae60;
  --color-success-light: #edfbf2;

  /* Semantic Variables */
  --color-bg: var(--color-glacier-white);
  --color-surface: #ffffff;
  --color-surface-muted: var(--color-mist-light);
  --color-surface-stone: var(--color-stone-light);
  --color-surface-dark: var(--color-forest-green);
  --color-text-primary: var(--color-charcoal);
  --color-text-secondary: var(--color-volcanic-slate);
  --color-text-tertiary: var(--color-charcoal-muted);
  --color-text-inverse: #ffffff;
  --color-text-accent: var(--color-summit-gold);
  --color-border: var(--color-stone-grey);
  --color-border-light: rgba(35, 79, 61, 0.08);
  --color-primary: var(--color-forest-green);
  --color-accent: var(--color-summit-gold);

  /* Typography */
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-icons: 'Material Icons Outlined';

  /* Font Scales */
  --step--1: 0.875rem;
  --step-0: 1rem;
  --step-1: 1.125rem;
  --step-2: 1.35rem;
  --step-3: 1.75rem;
  --step-4: 2.25rem;
  --step-5: 3.125rem;
  --step-6: 4rem;

  /* Spacing */
  --space-xxs: 0.25rem;
  --space-xs: 0.5rem;
  --space-s: 0.75rem;
  --space-m: 1rem;
  --space-l: 1.5rem;
  --space-xl: 2rem;
  --space-xxl: 3rem;
  --space-king: 5rem;

  /* Radii */
  --radius-xs: 4px;
  --radius-s: 6px;
  --radius-m: 8px;
  --radius-l: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(35, 79, 61, 0.05);
  --shadow-m: 0 4px 12px rgba(35, 79, 61, 0.08);
  --shadow-lg: 0 12px 28px rgba(35, 79, 61, 0.12);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
}

/* Reset & Normalization */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text-primary);
  background-color: var(--color-bg);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

a {
  color: var(--color-forest-green);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-summit-gold-hover);
}

img, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* Typography Classes */
h1, h2, h3, h4, .font-serif {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-forest-green);
}

.h1, h1 { font-size: clamp(2.25rem, 5vw, var(--step-6)); font-weight: 700; letter-spacing: -0.02em; }
.h2, h2 { font-size: clamp(1.75rem, 3.5vw, var(--step-4)); font-weight: 600; }
.h3, h3 { font-size: clamp(1.35rem, 2.5vw, var(--step-3)); font-weight: 600; }
.h4, h4 { font-size: var(--step-2); font-weight: 600; }
.h5, h5 { font-size: var(--step-1); font-weight: 600; font-family: var(--font-sans); }

.lead {
  font-size: clamp(1.05rem, 1.2vw, 1.25rem);
  line-height: 1.65;
  color: var(--color-volcanic-slate);
  font-weight: 400;
}

.body-l { font-size: var(--step-1); line-height: 1.6; }
.body-m { font-size: var(--step-0); line-height: 1.6; }
.body-s { font-size: var(--step--1); line-height: 1.5; }
.body-xs { font-size: 0.75rem; line-height: 1.4; }

.text-primary { color: var(--color-forest-green) !important; }
.text-secondary { color: var(--color-volcanic-slate) !important; }
.text-tertiary { color: var(--color-charcoal-muted) !important; }
.text-muted { color: #737373 !important; }
.text-accent { color: var(--color-summit-gold) !important; }
.text-white { color: #ffffff !important; }
.text-danger { color: var(--color-danger) !important; }
.text-success { color: var(--color-success) !important; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.material-icons-outlined {
  font-family: var(--font-icons);
  font-weight: normal;
  font-style: normal;
  font-size: 20px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  vertical-align: middle;
}

/* Global Reset Additions */
[hidden] {
  display: none !important;
}

/* Layout Primitives */
.container {
  width: 100%;
  max-width: 1440px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(1rem, 3vw, 2rem);
  padding-right: clamp(1rem, 3vw, 2rem);
}

.container--sm { max-width: 800px; }
.container--md { max-width: 1020px; }
.container--lg { max-width: 1440px; }

.section {
  padding-top: clamp(2.5rem, 5vw, 4.5rem);
  padding-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.section--sm {
  padding-top: clamp(1.5rem, 3vw, 2.5rem);
  padding-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.section--hero {
  padding-top: clamp(3rem, 6vw, 5.5rem);
  padding-bottom: clamp(3rem, 6vw, 5.5rem);
  background: radial-gradient(circle at 80% 20%, rgba(200, 162, 77, 0.08), transparent 45%),
              linear-gradient(180deg, var(--color-mist-light) 0%, var(--color-glacier-white) 100%);
  border-bottom: 1px solid var(--color-border-light);
}

.section--dark {
  background-color: var(--color-forest-green);
  color: var(--color-glacier-white);
}

.section--dark h1, .section--dark h2, .section--dark h3, .section--dark h4 {
  color: #ffffff;
}

.section--dark .lead, .section--dark .body-m {
  color: rgba(248, 248, 245, 0.85);
}

.surface-muted { background-color: var(--color-mist-light); }
.surface-stone { background-color: var(--color-stone-light); }

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

.stack { display: flex; flex-direction: column; gap: var(--space-m); }
.stack--xxs { gap: var(--space-xxs); }
.stack--xs { gap: var(--space-xs); }
.stack--sm { gap: var(--space-s); }
.stack--lg { gap: var(--space-l); }
.stack--xl { gap: var(--space-xl); }

.cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-s);
}

.cluster--xs { gap: var(--space-xs); }
.cluster--m { gap: var(--space-m); }
.cluster--l { gap: var(--space-l); }

.items-middle { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }

/* Grid Columns */
.col-12 { grid-column: span 12; }
.col-8 { grid-column: span 8; }
.col-6 { grid-column: span 6; }
.col-4 { grid-column: span 4; }
.col-3 { grid-column: span 3; }

@media (min-width: 768px) {
  .md-col-12 { grid-column: span 12; }
  .md-col-10 { grid-column: span 10; }
  .md-col-9 { grid-column: span 9; }
  .md-col-8 { grid-column: span 8; }
  .md-col-7 { grid-column: span 7; }
  .md-col-6 { grid-column: span 6; }
  .md-col-5 { grid-column: span 5; }
  .md-col-4 { grid-column: span 4; }
  .md-col-3 { grid-column: span 3; }
  .md-col-2 { grid-column: span 2; }
  
  .md-col-8-centered { grid-column: 3 / span 8; }
  .md-col-10-centered { grid-column: 2 / span 10; }
  .md-col-6-centered { grid-column: 4 / span 6; }
}

@media (min-width: 1024px) {
  .lg-col-12 { grid-column: span 12; }
  .lg-col-8 { grid-column: span 8; }
  .lg-col-7 { grid-column: span 7; }
  .lg-col-6 { grid-column: span 6; }
  .lg-col-5 { grid-column: span 5; }
  .lg-col-4 { grid-column: span 4; }
  .lg-col-3 { grid-column: span 3; }
  .lg-col-6-centered { grid-column: 4 / span 6; }
  .lg-col-8-centered { grid-column: 3 / span 8; }
}

@media (max-width: 767px) {
  .grid-12 > [class*="col-"] {
    grid-column: span 12;
  }
}

/* UI Components */
.card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-m);
  padding: clamp(1rem, 2vw, 1.5rem);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.card--interactive:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-m);
  border-color: rgba(35, 79, 61, 0.25);
}

.card--forest {
  background-color: var(--color-forest-green);
  color: #ffffff;
  border-color: var(--color-forest-dark);
}

.card--forest h2, .card--forest h3, .card--forest h4 {
  color: #ffffff;
}

.card--gold {
  background: linear-gradient(135deg, #fff9ee 0%, #f7ecd2 100%);
  border-color: rgba(200, 162, 77, 0.35);
}

.card--mist {
  background-color: var(--color-mist-light);
  border-color: var(--color-mist-green);
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: 0.625rem 1.25rem;
  font-family: var(--font-sans);
  font-size: var(--step--1);
  font-weight: 600;
  line-height: 1.2;
  border-radius: var(--radius-m);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition-fast);
  min-height: 44px;
}

.button:focus-visible {
  outline: 3px solid var(--color-summit-gold);
  outline-offset: 2px;
}

.button--primary {
  background-color: var(--color-forest-green);
  color: var(--color-glacier-white);
}

.button--primary:hover {
  background-color: var(--color-forest-dark);
  color: #ffffff;
}

.button--accent {
  background-color: var(--color-summit-gold);
  color: var(--color-forest-dark);
}

.button--accent:hover {
  background-color: var(--color-summit-gold-hover);
  color: #ffffff;
}

.button--secondary {
  background-color: transparent;
  color: var(--color-forest-green);
  border-color: var(--color-forest-green);
}

.button--secondary:hover {
  background-color: var(--color-forest-green);
  color: #ffffff;
}

.button--ghost {
  background-color: transparent;
  color: var(--color-volcanic-slate);
  border-color: transparent;
}

.button--ghost:hover {
  background-color: var(--color-mist-light);
  color: var(--color-forest-green);
}

.button--sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.8125rem;
  min-height: 36px;
}

.button--lg {
  padding: 0.85rem 1.75rem;
  font-size: var(--step-0);
  min-height: 52px;
}

.button--full { width: 100%; }

.button:disabled, .button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

/* Tags & Badges */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: var(--radius-full);
  background-color: var(--color-mist-green);
  color: var(--color-forest-green);
  border: 1px solid rgba(35, 79, 61, 0.15);
  line-height: 1.2;
}

.tag--gold {
  background-color: var(--color-summit-gold-light);
  color: #8c6e26;
  border-color: rgba(200, 162, 77, 0.3);
}

.tag--route {
  background-color: var(--color-forest-green);
  color: #ffffff;
  border-color: var(--color-forest-dark);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.15rem 0.45rem;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  background-color: var(--color-forest-green);
  color: #ffffff;
  min-width: 1.25rem;
  height: 1.25rem;
}

.badge--gold {
  background-color: var(--color-summit-gold);
  color: var(--color-forest-dark);
}

/* Avatars */
.avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background-color: var(--color-forest-green);
  color: var(--color-glacier-white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  overflow: hidden;
  flex-shrink: 0;
  border: 2px solid #ffffff;
  box-shadow: var(--shadow-sm);
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar--sm { width: 32px; height: 32px; font-size: 0.8rem; }
.avatar--lg { width: 64px; height: 64px; font-size: 1.5rem; }
.avatar--xl { width: 96px; height: 96px; font-size: 2.25rem; }

/* Guide Profile Banner & Card */
.profile-card {
  position: relative;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--space-xl);
}

.profile-banner {
  height: 140px;
  background: linear-gradient(135deg, rgba(35, 79, 61, 0.92) 0%, rgba(25, 56, 44, 0.95) 100%),
              radial-gradient(circle at 80% 30%, rgba(200, 162, 77, 0.4), transparent 60%);
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 1rem 1.25rem;
  color: #ffffff;
}

.profile-banner--guide {
  height: 200px;
  background: linear-gradient(180deg, rgba(35, 79, 61, 0.6) 0%, rgba(25, 56, 44, 0.95) 100%),
              radial-gradient(circle at 85% 20%, rgba(200, 162, 77, 0.45), transparent 55%),
              url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 300" preserveAspectRatio="none"><path d="M0,300 L250,110 L400,210 L600,50 L750,170 L1000,300 Z" fill="rgba(200,162,77,0.16)"/><path d="M0,300 L350,140 L550,230 L700,80 L850,190 L1000,300 Z" fill="rgba(248,248,245,0.12)"/></svg>') no-repeat bottom center;
  background-size: cover;
}

.profile-banner__badge {
  background-color: rgba(25, 56, 44, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(200, 162, 77, 0.6);
  border-radius: var(--radius-full);
  padding: 0.4rem 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--color-summit-gold);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.profile-body {
  padding: 1.5rem;
  position: relative;
}

.profile-avatar-wrapper {
  margin-top: -65px;
  position: relative;
  z-index: 2;
  margin-bottom: 0.75rem;
}

.profile-avatar-wrapper .avatar--xl {
  width: 104px;
  height: 104px;
  border: 4px solid #ffffff;
  box-shadow: var(--shadow-m);
}

/* Forms & Controls */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  margin-bottom: var(--space-m);
}

.label {
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--color-forest-green);
}

.input, .textarea, .select {
  width: 100%;
  padding: 0.65rem 0.95rem;
  font-family: var(--font-sans);
  font-size: var(--step-0);
  color: var(--color-text-primary);
  background-color: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-m);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--color-forest-green);
  box-shadow: 0 0 0 3px rgba(35, 79, 61, 0.15);
}

.textarea {
  min-height: 120px;
  resize: vertical;
}

.search-box {
  position: relative;
  width: 100%;
}

.search-box .material-icons-outlined {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-charcoal-muted);
  pointer-events: none;
}

.search-box .input {
  padding-left: 2.75rem;
  background-color: #ffffff;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

/* Discussion Cards */
.discussion-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  padding: var(--space-l);
  background-color: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-m);
  transition: all var(--transition-fast);
}

.discussion-card:hover {
  border-color: rgba(35, 79, 61, 0.35);
  box-shadow: var(--shadow-m);
  transform: translateY(-1px);
}

.discussion-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-s);
}

.discussion-card__title {
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  font-weight: 600;
  line-height: 1.3;
}

.discussion-card__title a {
  color: var(--color-forest-green);
}

.discussion-card__title a:hover {
  color: var(--color-summit-gold-hover);
}

.discussion-card__excerpt {
  color: var(--color-volcanic-slate);
  font-size: var(--step--1);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.discussion-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-s);
  padding-top: var(--space-xs);
  border-top: 1px solid rgba(35, 79, 61, 0.06);
  font-size: var(--step--1);
  color: var(--color-charcoal-muted);
}

/* Post Stream (Single Discussion) */
.post-stream {
  display: flex;
  flex-direction: column;
  gap: var(--space-l);
}

.post-card {
  background-color: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-m);
  padding: var(--space-l);
  box-shadow: var(--shadow-sm);
}

.post-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-s);
  margin-bottom: var(--space-m);
  padding-bottom: var(--space-s);
  border-bottom: 1px solid var(--color-border-light);
}

.post-card__content {
  font-size: var(--step-0);
  line-height: 1.7;
  color: var(--color-text-primary);
}

.post-card__content p {
  margin-bottom: 1rem;
}

.post-card__content p:last-child {
  margin-bottom: 0;
}

.post-card__content blockquote {
  border-left: 3px solid var(--color-summit-gold);
  background-color: var(--color-mist-light);
  padding: var(--space-s) var(--space-m);
  margin: 1rem 0;
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
  font-style: italic;
  color: var(--color-volcanic-slate);
}

.post-card__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-s);
  margin-top: var(--space-m);
  padding-top: var(--space-s);
  border-top: 1px solid var(--color-border-light);
}

/* Navigation Header */
.site-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: var(--space-m);
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  text-decoration: none;
}

.brand-logo__symbol {
  width: 34px;
  height: 34px;
  color: var(--color-forest-green);
}

.brand-logo__text {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--color-forest-green);
  letter-spacing: -0.01em;
}

.brand-logo__tagline {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--color-summit-gold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  display: block;
  line-height: 1;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-l);
  list-style: none;
}

.nav-link {
  font-family: var(--font-sans);
  font-size: var(--step--1);
  font-weight: 600;
  color: var(--color-volcanic-slate);
  transition: color var(--transition-fast);
  text-decoration: none;
}

.nav-link:hover, .nav-link--active {
  color: var(--color-forest-green);
}

.nav-link--active {
  border-bottom: 2px solid var(--color-summit-gold);
  padding-bottom: 4px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.auth-guest-wrapper,
.auth-user-wrapper {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}

.hide-mobile {
  display: inline-flex;
}

.mobile-menu-toggle {
  display: none;
  padding: 0.4rem;
  color: var(--color-forest-green);
}

/* Mobile Slide-Out Drawer */
.mobile-nav-drawer {
  position: fixed;
  inset: 0;
  z-index: 1200;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.mobile-nav-drawer.is-open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav-drawer__overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(25, 56, 44, 0.65);
  backdrop-filter: blur(4px);
}

.mobile-nav-drawer__content {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(85vw, 360px);
  background-color: #ffffff;
  padding: 1.5rem 1.25rem;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  z-index: 2;
}

.mobile-nav-drawer.is-open .mobile-nav-drawer__content {
  transform: translateX(0);
}

.mobile-nav-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-m);
  color: var(--color-volcanic-slate);
  font-weight: 600;
  font-size: var(--step-0);
  text-decoration: none;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.mobile-nav-link:hover, .mobile-nav-link--active {
  background-color: var(--color-mist-light);
  color: var(--color-forest-green);
}

.mobile-nav-link--active {
  font-weight: 700;
  border-left: 3px solid var(--color-summit-gold);
}

/* Footer */
.site-footer {
  background-color: var(--color-forest-green);
  color: var(--color-glacier-white);
  padding-top: clamp(3rem, 6vw, 4.5rem);
  padding-bottom: clamp(2rem, 4vw, 3rem);
  margin-top: auto;
  border-top: 4px solid var(--color-summit-gold);
}

.site-footer a {
  color: rgba(248, 248, 245, 0.85);
}

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

.site-footer .footer-title {
  font-family: var(--font-serif);
  font-size: var(--step-2);
  color: #ffffff;
  margin-bottom: var(--space-m);
}

.site-footer .footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  font-size: var(--step--1);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: var(--space-xxl);
  padding-top: var(--space-l);
  font-size: 0.8125rem;
  color: rgba(248, 248, 245, 0.65);
}

/* Modals & Dialogs */
.modal-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(25, 56, 44, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.modal-overlay[aria-hidden="false"], .modal-overlay.is-active {
  opacity: 1;
  visibility: visible;
}

.modal-window {
  background-color: #ffffff;
  border-radius: var(--radius-l);
  width: 100%;
  max-width: 620px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
  transform: translateY(12px) scale(0.98);
  transition: all var(--transition-normal);
}

.modal-overlay.is-active .modal-window {
  transform: translateY(0) scale(1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-l);
  border-bottom: 1px solid var(--color-border-light);
}

.modal-body {
  padding: var(--space-l);
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-s);
  padding: var(--space-l);
  border-top: 1px solid var(--color-border-light);
  background-color: var(--color-glacier-white);
}

/* Helpers */
.divider {
  height: 1px;
  background-color: var(--color-border);
  border: none;
  margin: var(--space-l) 0;
}

.skeleton {
  background: linear-gradient(90deg, var(--color-stone-light) 25%, var(--color-mist-light) 50%, var(--color-stone-light) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-s);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Responsive Media Queries */
@media (max-width: 960px) {
  .nav-links {
    display: none !important;
  }
  
  .hide-mobile {
    display: none !important;
  }
  
  .mobile-menu-toggle {
    display: inline-flex !important;
  }

  .site-header__inner {
    height: 64px;
  }
}

@media (max-width: 640px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .brand-logo__tagline {
    display: none;
  }

  .brand-logo__text {
    font-size: 1.35rem;
  }

  .profile-banner {
    height: 110px;
  }

  .profile-banner--guide {
    height: 150px;
  }

  .profile-avatar-wrapper {
    margin-top: -50px;
  }

  .profile-avatar-wrapper .avatar--xl {
    width: 80px;
    height: 80px;
  }

  .modal-window {
    margin: 0.5rem;
    max-height: 95vh;
  }
}
