/* Keep the mirror navigation tactile and consistent without crowding its content. */
body.landing-page .nav-rail > a,
body.landing-page .landing-bottom-actions a,
body.landing-page .nav-rail-right > a {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: transform 160ms ease, box-shadow 160ms ease;
}
body.landing-page .nav-rail .nav-icon,
body.landing-page .landing-bottom-actions .nav-icon,
body.landing-page .nav-rail-right .nav-icon {
  width: 48px;
  height: 48px;
  filter: drop-shadow(0 3px 5px #0003);
  transform: none;
}
body.landing-page .nav-icon-frame { stroke-width: 4; opacity: .65; }
body.landing-page .landing-reflections-toggle,
body.landing-page .landing-signout-toggle {
  border: 1px solid #94a3b899;
  box-shadow: inset 0 1px 2px #ffffff40, 0 3px 8px #0003;
  font-size: 22px;
}
body.landing-page .nav-rail > a:hover,
body.landing-page .landing-bottom-actions a:hover,
body.landing-page .nav-rail-right > a:hover { transform: translateY(-2px); }
body.landing-page .nav-rail > a:focus-visible,
body.landing-page .landing-bottom-actions a:focus-visible,
body.landing-page .nav-rail-right > a:focus-visible {
  outline: 3px solid #60a5fa;
  outline-offset: 3px;
}
body.landing-page .nav-rail > a:active,
body.landing-page .landing-bottom-actions a:active,
body.landing-page .nav-rail-right > a:active { transform: scale(.96); }
@media (max-width: 640px) {
  body.landing-page .nav-rail,
  body.landing-page .nav-rail-right { width: 88%; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  body.landing-page .nav-rail > a,
  body.landing-page .nav-rail-right > a,
  body.landing-page .nav-rail .nav-icon,
  body.landing-page .nav-rail-right .nav-icon { transition: none; transform: none; }
}
body.landing-page .landing-header-rail { display: contents; }
body.landing-page .landing-bottom-actions {
  position: absolute;
  bottom: 28px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 20px;
  z-index: 20;
}
body.landing-page .landing-bottom-actions .privacy-wrapper,
body.landing-page .landing-bottom-actions a {
  position: relative;
  bottom: auto;
  right: auto;
}
@media (max-width: 640px) {
  body.landing-page .landing-bottom-actions {
    bottom: 24px;
    right: 16px;
  }
}
@media (max-width: 640px) {
  body.landing-page .mirror { padding-top: max(18%, 120px); }
  body.landing-page .landing-header-rail {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 88%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 1001;
  }
  body.landing-page .landing-header-rail .nav-rail,
  body.landing-page .landing-top-actions { display: contents; }
  body.landing-page .landing-header-rail .nav-rail > a { order: -1; }
  body.landing-page .landing-header-rail .nav-rail > a,
  body.landing-page .landing-header-rail .landing-top-actions > * {
    box-sizing: border-box;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    margin: 0;
    padding: 0;
  }
  body.landing-page .landing-header-rail .nav-icon,
  body.landing-page .landing-header-rail .mission-icon-toggle {
    width: 40px;
    height: 40px;
  }
  body.landing-page #globalPageControls { top: 8px; left: 12px; right: auto; }
}

/* Persistent discovery labels remain part of each link's clickable area. */
body.landing-page .nav-rail-right > a { position: relative; }
@media (min-width: 641px) {
  body.landing-page .nav-rail-right { gap: 40px; }
}
body.landing-page .landing-nav-label {
  position: absolute;
  top: calc(100% + 3px);
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: 80px;
  box-sizing: border-box;
  padding: 4px 6px;
  border-radius: 6px;
  background: #f8fafc;
  color: #172033;
  box-shadow: 0 2px 5px #0003;
  font: 600 11px/1.25 system-ui, sans-serif;
  text-align: center;
  overflow-wrap: anywhere;
}
body.landing-page.dark-mode .landing-nav-label { background: #202535; color: #eff2fa; }
@media (max-width: 640px) {
  body.landing-page .landing-nav-label {
    top: calc(100% + 3px);
    left: 50%;
    transform: translateX(-50%);
    width: 64px;
    padding: 3px 2px;
    font-size: 10px;
  }
}
@media (max-width: 640px) {
  body.landing-page .nav-rail-right {
    width: calc(100vw - 48px);
    justify-content: space-between;
    gap: 0;
  }
  body.landing-page .landing-nav-label {
    width: clamp(54px, calc(25vw - 26px), 62px);
    font-size: 9px;
  }
}

/* One surface, lighting treatment and optical inset for the entire icon family. */
body.landing-page .nav-icon-bg {
  fill: color-mix(in srgb, var(--nav-accent) 12%, var(--nav-bg));
}
body.landing-page .nav-icon-highlight {
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linecap: round;
  opacity: .5;
}
body.landing-page.dark-mode .nav-icon-highlight { opacity: .16; }
body.landing-page .nav-icon-symbol { transform: translate(7.68px, 7.68px) scale(.88); }
body.landing-page .nav-icon-mark,
body.landing-page .nav-icon-bg-stroke { stroke-width: 6; }
@media (prefers-reduced-motion: reduce) {
  body.landing-page .nav-rail > a:is(:hover, :active),
  body.landing-page .nav-rail-right > a:is(:hover, :active) {
    transform: none;
    transition: none;
  }
}

/* Shared labeled controls for navigation and quick actions. */
body.landing-page .nav-rail > a,
body.landing-page .landing-top-actions > a,
body.landing-page #darkModeToggle { position: relative; }
body.landing-page .landing-top-actions { width: 48px; gap: 40px; }
body.landing-page .landing-top-actions > *,
body.landing-page .landing-top-actions .language-toggle,
body.landing-page .landing-top-actions .mission-icon-toggle,
body.landing-page .landing-top-actions .nav-icon {
  width: 48px;
  min-width: 48px;
  height: 48px;
  box-sizing: border-box;
}
body.landing-page #darkModeToggle,
body.landing-page .landing-top-actions .language-toggle {
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}
body.landing-page .landing-top-actions .nav-icon {
  filter: drop-shadow(0 3px 5px #0003);
  transform: none;
}
body.landing-page .landing-top-actions .language-dropdown {
  top: calc(100% + 28px);
  z-index: 30;
}
body.landing-page .nav-icon-sun { display: none; }
body.landing-page.dark-mode .nav-icon-sun { display: block; }
body.landing-page.dark-mode .nav-icon-moon { display: none; }
body.landing-page .nav-icon-sun { --nav-accent-strong: #b45309; --nav-accent-soft: #fef3c7; }
body.landing-page .landing-top-actions > a:hover,
body.landing-page #darkModeToggle:hover,
body.landing-page .landing-top-actions .language-toggle:hover { transform: translateY(-2px); }
body.landing-page .landing-top-actions > a:focus-visible,
body.landing-page #darkModeToggle:focus-visible,
body.landing-page .landing-top-actions .language-toggle:focus-visible {
  outline: 3px solid #60a5fa;
  outline-offset: 3px;
  border-radius: 50%;
}
@media (min-width: 641px) {
  body.landing-page .nav-rail {
    left: auto;
    right: 14%;
    gap: 40px;
  }
  body.landing-page .nav-rail-right {
    left: 14%;
    right: auto;
  }
  body.landing-page .landing-top-actions { right: 4px; }
}
@media (max-width: 640px) {
  body.landing-page .mirror {
    padding-top: max(18%, 100px);
    padding-bottom: max(18%, 180px);
  }
  body.landing-page.signed-in .mirror { padding-bottom: max(18%, 180px); }
  body.landing-page .nav-rail-right {
    top: 20px;
    bottom: auto;
  }
  body.landing-page .landing-header-rail {
    top: auto;
    bottom: 120px;
    width: calc(100% - 32px);
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 0;
  }
  body.landing-page .landing-header-rail .nav-rail,
  body.landing-page .landing-header-rail .landing-top-actions {
    display: contents;
    position: static;
    transform: none;
    width: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-evenly;
    gap: 0;
  }
  body.landing-page .landing-header-rail .nav-rail { order: -1; }
  body.landing-page .landing-header-rail .nav-rail > a,
  body.landing-page .landing-header-rail .landing-top-actions > *,
  body.landing-page .landing-header-rail .nav-icon,
  body.landing-page .landing-header-rail .mission-icon-toggle {
    flex: 0 0 44px;
    width: 44px;
    min-width: 44px;
    height: 44px;
  }
  body.landing-page .landing-header-rail .landing-bottom-actions { display: contents; }
  body.landing-page .landing-header-rail .landing-bottom-actions a,
  body.landing-page .landing-header-rail #darkModeToggle,
  body.landing-page .landing-header-rail .privacy-wrapper,
  body.landing-page .landing-header-rail .language-toggle {
    width: 44px;
    min-width: 44px;
    height: 44px;
    flex: 0 0 44px;
  }
  body.landing-page .landing-header-rail .landing-nav-label { width: 46px; }
  body.landing-page .landing-header-rail .landing-language-switcher { position: relative; }
  body.landing-page .landing-top-actions .language-dropdown {
    top: auto;
    bottom: calc(100% + 8px);
  }
}
@media (prefers-reduced-motion: reduce) {
  body.landing-page .landing-top-actions > a,
  body.landing-page .landing-bottom-actions a,
  body.landing-page #darkModeToggle,
  body.landing-page .landing-top-actions .language-toggle {
    transition: none;
    transform: none;
  }
}
