:root {
  color-scheme: dark;
  --ink: #07111f;
  --navy: #071833;
  --navy-2: #0a244a;
  --ocean: #073f5c;
  --cyan: #36f3ff;
  --aqua: #6fffe9;
  --ice: #effbff;
  --muted: #9bb4ca;
  --line: rgba(255, 255, 255, 0.16);
  --panel: rgba(255, 255, 255, 0.08);
  --panel-strong: rgba(255, 255, 255, 0.14);
  --shadow: 0 24px 90px rgba(0, 0, 0, 0.38);
  --radius: 28px;
  --wrap: min(1180px, calc(100vw - 40px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 12% 8%, rgba(54, 243, 255, 0.2), transparent 32rem),
    radial-gradient(circle at 82% 14%, rgba(111, 255, 233, 0.14), transparent 26rem),
    linear-gradient(180deg, #030711 0%, #071833 42%, #06111f 100%);
  color: var(--ice);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
  min-height: 100vh;
}

body.nav-open {
  overflow: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.skip-link {
  background: var(--cyan);
  color: #00101c;
  left: 1rem;
  padding: 0.75rem 1rem;
  position: fixed;
  top: 1rem;
  transform: translateY(-140%);
  z-index: 100;
}

.skip-link:focus {
  transform: translateY(0);
}

.wrap {
  margin-inline: auto;
  width: var(--wrap);
}

.site-header {
  align-items: center;
  backdrop-filter: blur(22px);
  background: linear-gradient(180deg, rgba(2, 7, 17, 0.84), rgba(2, 7, 17, 0.34));
  border-bottom: 1px solid transparent;
  display: flex;
  gap: 2rem;
  inset: 0 0 auto;
  justify-content: space-between;
  padding: 1.05rem max(20px, calc((100vw - 1180px) / 2));
  position: fixed;
  transition: background 0.25s ease, border-color 0.25s ease, padding 0.25s ease;
  z-index: 50;
}

.site-header.is-scrolled {
  background: rgba(2, 7, 17, 0.92);
  border-color: var(--line);
  padding-block: 0.72rem;
}

.brand {
  align-items: center;
  display: inline-flex;
  gap: 0.78rem;
  min-width: max-content;
}

.brand-mark {
  align-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(111, 255, 233, 0.95), rgba(54, 243, 255, 0.1) 56%, rgba(54, 243, 255, 0.02));
  border: 1px solid rgba(111, 255, 233, 0.46);
  border-radius: 16px;
  display: inline-grid;
  height: 46px;
  justify-content: center;
  width: 46px;
}

.brand-mark svg {
  height: 33px;
  width: 33px;
}

.brand-mark path:first-child {
  fill: rgba(7, 24, 51, 0.7);
  stroke: var(--aqua);
  stroke-width: 1.6;
}

.brand-mark path:nth-child(2) {
  fill: none;
  stroke: var(--cyan);
  stroke-linecap: round;
  stroke-width: 2;
}

.brand-mark circle {
  fill: var(--aqua);
}

.brand strong {
  display: block;
  font-size: 1.05rem;
  letter-spacing: 0.16em;
  line-height: 1;
}

.brand small {
  color: var(--muted);
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  margin-top: 0.24rem;
}

.site-nav {
  align-items: center;
  display: flex;
  gap: 0.25rem;
}

.site-nav a {
  border-radius: 999px;
  color: rgba(239, 251, 255, 0.86);
  font-size: 0.93rem;
  font-weight: 600;
  padding: 0.68rem 0.92rem;
  transition: background 0.2s ease, color 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: white;
  outline: none;
}

.site-nav .nav-cta {
  background: rgba(54, 243, 255, 0.14);
  border: 1px solid rgba(54, 243, 255, 0.42);
  color: var(--cyan);
  margin-left: 0.35rem;
}

.nav-toggle {
  align-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  display: none;
  gap: 0.6rem;
  padding: 0.62rem 0.8rem 0.62rem 1rem;
}

.nav-toggle i,
.nav-toggle i::before,
.nav-toggle i::after {
  background: currentColor;
  border-radius: 999px;
  display: block;
  height: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
  width: 18px;
}

.nav-toggle i {
  position: relative;
}

.nav-toggle i::before,
.nav-toggle i::after {
  content: "";
  left: 0;
  position: absolute;
}

.nav-toggle i::before {
  top: -6px;
}

.nav-toggle i::after {
  top: 6px;
}

.nav-toggle[aria-expanded="true"] i {
  background: transparent;
}

.nav-toggle[aria-expanded="true"] i::before {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] i::after {
  transform: translateY(-6px) rotate(-45deg);
}

.hero {
  min-height: 100svh;
  overflow: hidden;
  padding: 9rem 0 5rem;
  position: relative;
}

.hero::after {
  background: linear-gradient(180deg, transparent, rgba(3, 7, 17, 0.78));
  bottom: 0;
  content: "";
  height: 28vh;
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
}

.hero-grid {
  align-items: center;
  display: grid;
  gap: 4rem;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.72fr);
  min-height: calc(100svh - 14rem);
  position: relative;
  z-index: 2;
}

.hero-copy {
  max-width: 780px;
}

.eyebrow,
.section-kicker {
  color: var(--aqua);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  margin: 0 0 1rem;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  letter-spacing: -0.045em;
  line-height: 1.02;
}

h1 {
  font-size: clamp(3.4rem, 8vw, 7.8rem);
  margin-bottom: 1.5rem;
  max-width: 900px;
}

h2 {
  font-size: clamp(2.1rem, 4.2vw, 4.7rem);
  margin-bottom: 1.2rem;
}

h3 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
}

.hero-lede {
  color: rgba(239, 251, 255, 0.78);
  font-size: clamp(1.08rem, 1.7vw, 1.42rem);
  max-width: 720px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.button {
  align-items: center;
  border-radius: 999px;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 3.2rem;
  padding: 0.9rem 1.35rem;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button.primary {
  background: linear-gradient(135deg, var(--aqua), var(--cyan));
  color: #00111e;
}

.button.secondary {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.26);
  color: var(--ice);
}

.button.secondary.dark {
  background: rgba(7, 24, 51, 0.86);
}

.hero-bg {
  inset: 0;
  position: absolute;
}

.hero-bg::before {
  background:
    radial-gradient(circle at 50% 50%, rgba(54, 243, 255, 0.16), transparent 24rem),
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: auto, 72px 72px, 72px 72px;
  content: "";
  inset: 0;
  mask-image: linear-gradient(180deg, transparent 0%, black 14%, black 80%, transparent 100%);
  opacity: 0.7;
  position: absolute;
}

.hero-bg::after {
  background: radial-gradient(ellipse at 50% 100%, rgba(8, 85, 118, 0.72), transparent 60%);
  bottom: -12%;
  content: "";
  height: 46%;
  left: -10%;
  position: absolute;
  right: -10%;
}

.particle,
.beam {
  position: absolute;
}

.particle {
  background: var(--cyan);
  border-radius: 999px;
  box-shadow: 0 0 24px var(--cyan);
  height: 6px;
  opacity: 0.8;
  width: 6px;
}

.particle-a {
  animation: drift 11s ease-in-out infinite;
  left: 18%;
  top: 34%;
}

.particle-b {
  animation: drift 13s ease-in-out infinite reverse;
  left: 76%;
  top: 24%;
}

.particle-c {
  animation: drift 17s ease-in-out infinite;
  left: 62%;
  top: 68%;
}

.beam {
  background: linear-gradient(90deg, transparent, rgba(54, 243, 255, 0.8), transparent);
  height: 2px;
  opacity: 0.62;
  transform-origin: left center;
  width: 62vw;
}

.beam-one {
  left: 9%;
  top: 30%;
  transform: rotate(18deg);
}

.beam-two {
  right: 0;
  top: 66%;
  transform: rotate(-23deg);
}

@keyframes drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(34px, -28px, 0) scale(1.6);
  }
}

.mission-card {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.05));
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: calc(var(--radius) + 12px);
  box-shadow: var(--shadow);
  min-height: 590px;
  overflow: hidden;
  padding: 2rem;
  position: relative;
}

.mission-card::before {
  background: radial-gradient(circle at center, rgba(54, 243, 255, 0.24), transparent 44%);
  content: "";
  inset: 0;
  position: absolute;
}

.orbit-visual {
  aspect-ratio: 1;
  margin: 0 auto;
  max-width: 420px;
  position: relative;
}

.ring {
  border: 1px solid rgba(111, 255, 233, 0.32);
  border-radius: 50%;
  inset: 50%;
  position: absolute;
  transform: translate(-50%, -50%);
}

.ring-a {
  height: 82%;
  width: 82%;
}

.ring-b {
  height: 58%;
  transform: translate(-50%, -50%) rotateX(64deg) rotateZ(-16deg);
  width: 92%;
}

.ring-c {
  height: 92%;
  transform: translate(-50%, -50%) rotateX(66deg) rotateZ(60deg);
  width: 58%;
}

.node {
  background: var(--aqua);
  border-radius: 999px;
  box-shadow: 0 0 32px rgba(111, 255, 233, 0.9);
  height: 14px;
  position: absolute;
  width: 14px;
}

.node-a {
  left: 18%;
  top: 38%;
}

.node-b {
  right: 18%;
  top: 56%;
}

.node-c {
  left: 48%;
  top: 14%;
}

.mission-card dl {
  background: rgba(2, 7, 17, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  bottom: 1.5rem;
  display: grid;
  gap: 0.9rem;
  left: 1.5rem;
  margin: 0;
  padding: 1rem;
  position: absolute;
  right: 1.5rem;
}

.mission-card dl div {
  align-items: baseline;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  padding-bottom: 0.75rem;
}

.mission-card dl div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.mission-card dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mission-card dd {
  color: white;
  font-weight: 800;
  margin: 0;
  text-align: right;
}

.intro-panel,
.observatory,
.collaboration,
.scientists {
  padding: 7rem 0;
}

.intro-grid {
  align-items: end;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 3rem;
  grid-template-columns: 1.15fr 0.85fr;
  padding-bottom: 5rem;
}

.intro-grid p:last-child,
.collaboration-copy p,
.detector-grid > div > p,
.scientists-panel p,
.site-footer p {
  color: rgba(239, 251, 255, 0.72);
  font-size: 1.06rem;
}

.scroll-story {
  padding: 2rem 0 7rem;
}

.story-block {
  align-items: start;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 2rem;
  grid-template-columns: 90px minmax(0, 0.95fr) minmax(280px, 0.8fr);
  padding: 4.2rem 0;
}

.story-block:last-child {
  border-bottom: 1px solid var(--line);
}

.story-number {
  color: rgba(111, 255, 233, 0.54);
  font-size: 0.88rem;
  font-weight: 900;
  letter-spacing: 0.18em;
}

.story-block p:last-child {
  color: rgba(239, 251, 255, 0.7);
  font-size: 1.05rem;
}

.section-heading {
  margin-bottom: 2.5rem;
  max-width: 860px;
}

.section-heading.with-action {
  align-items: end;
  display: flex;
  justify-content: space-between;
  max-width: var(--wrap);
}

.section-heading.with-action h2 {
  max-width: 790px;
}

.observatory-grid {
  align-items: stretch;
  display: grid;
  gap: 1.4rem;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.72fr);
}

.map-card,
.feature-list article,
.spec-grid article,
.news-card,
.scientists-panel {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.055));
  border: 1px solid var(--line);
  box-shadow: 0 18px 80px rgba(0, 0, 0, 0.16);
}

.map-card {
  border-radius: calc(var(--radius) + 10px);
  min-height: 560px;
  overflow: hidden;
  padding: 1.2rem;
}

.map-visual {
  background:
    radial-gradient(circle at 72% 28%, rgba(111, 255, 233, 0.12), transparent 16rem),
    radial-gradient(circle at 30% 68%, rgba(54, 243, 255, 0.16), transparent 18rem),
    linear-gradient(145deg, #071833, #042039 48%, #06111f);
  border-radius: var(--radius);
  height: 100%;
  min-height: 520px;
  overflow: hidden;
  position: relative;
}

.map-visual::before {
  background:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 54px 54px;
  content: "";
  inset: 0;
  opacity: 0.72;
  position: absolute;
}

.map-line {
  border: 1px solid rgba(111, 255, 233, 0.32);
  border-left: 0;
  border-radius: 50%;
  height: 280px;
  left: 18%;
  position: absolute;
  top: 25%;
  transform: rotate(-18deg);
  width: 470px;
}

.map-pin {
  background: rgba(3, 7, 17, 0.76);
  border: 1px solid rgba(111, 255, 233, 0.55);
  border-radius: 999px;
  color: var(--ice);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 800;
  padding: 0.6rem 0.84rem;
  position: absolute;
  transition: transform 0.2s ease, background 0.2s ease;
  z-index: 2;
}

.map-pin::before {
  background: var(--aqua);
  border-radius: 50%;
  box-shadow: 0 0 26px var(--aqua);
  content: "";
  height: 8px;
  left: 50%;
  position: absolute;
  top: -14px;
  transform: translateX(-50%);
  width: 8px;
}

.map-pin:hover,
.map-pin:focus-visible {
  background: rgba(54, 243, 255, 0.16);
  outline: none;
  transform: translateY(-3px);
}

.pin-baikal {
  left: 18%;
  top: 32%;
}

.pin-sea {
  right: 16%;
  top: 54%;
}

.pin-ihep {
  left: 48%;
  top: 42%;
}

.map-output {
  background: rgba(3, 7, 17, 0.72);
  border: 1px solid var(--line);
  border-radius: 18px;
  bottom: 1.2rem;
  color: var(--muted);
  display: block;
  left: 1.2rem;
  padding: 0.9rem 1rem;
  position: absolute;
  right: 1.2rem;
  z-index: 2;
}

.feature-list {
  display: grid;
  gap: 1rem;
}

.feature-list article,
.spec-grid article,
.news-card {
  border-radius: var(--radius);
  padding: 1.45rem;
}

.feature-list p,
.spec-grid p,
.news-card p {
  color: rgba(239, 251, 255, 0.68);
  margin-bottom: 0;
}

.detector {
  background: linear-gradient(180deg, rgba(239, 251, 255, 0.96), rgba(215, 245, 255, 0.9));
  color: #07111f;
  padding: 7rem 0;
}

.detector .section-kicker {
  color: #006a78;
}

.detector-grid {
  align-items: start;
  display: grid;
  gap: 3rem;
  grid-template-columns: minmax(0, 0.76fr) minmax(0, 1fr);
}

.detector-grid > div > p {
  color: rgba(7, 17, 31, 0.7);
}

.text-link {
  border-bottom: 2px solid #008fa0;
  color: #006a78;
  display: inline-flex;
  font-weight: 900;
  margin-top: 0.8rem;
  padding-bottom: 0.2rem;
}

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

.spec-grid article {
  background: rgba(255, 255, 255, 0.64);
  border-color: rgba(7, 17, 31, 0.12);
  box-shadow: 0 22px 80px rgba(7, 24, 51, 0.12);
}

.spec-grid span {
  color: #007988;
  display: block;
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  margin-bottom: 2.5rem;
}

.spec-grid p {
  color: rgba(7, 17, 31, 0.68);
}

.metrics {
  background: #06111f;
  padding: 4rem 0;
}

.metric-grid {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.045));
  min-height: 190px;
  padding: 1.5rem;
}

.metric:first-child {
  border-radius: var(--radius) 0 0 var(--radius);
}

.metric:last-child {
  border-radius: 0 var(--radius) var(--radius) 0;
}

.metric strong {
  color: var(--aqua);
  display: block;
  font-size: clamp(2.2rem, 4vw, 4rem);
  letter-spacing: -0.07em;
  line-height: 0.95;
  margin-bottom: 1.5rem;
}

.metric span {
  color: rgba(239, 251, 255, 0.72);
  font-weight: 600;
}

.collaboration-grid {
  align-items: start;
  display: grid;
  gap: 3rem;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.6rem;
}

.pill-row span {
  background: rgba(54, 243, 255, 0.1);
  border: 1px solid rgba(54, 243, 255, 0.24);
  border-radius: 999px;
  color: var(--aqua);
  font-weight: 800;
  padding: 0.7rem 0.9rem;
}

.news {
  background: #effbff;
  color: #07111f;
  padding: 7rem 0;
}

.news .section-kicker {
  color: #006a78;
}

.news-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.news-card {
  background: white;
  border-color: rgba(7, 17, 31, 0.1);
  box-shadow: 0 18px 70px rgba(7, 24, 51, 0.08);
  min-height: 290px;
}

.news-card time {
  color: #007988;
  display: block;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  margin-bottom: 3rem;
  text-transform: uppercase;
}

.news-card p {
  color: rgba(7, 17, 31, 0.66);
}

.scientists-panel {
  align-items: end;
  border-radius: calc(var(--radius) + 12px);
  display: grid;
  gap: 3rem;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  overflow: hidden;
  padding: 3rem;
  position: relative;
}

.scientists-panel::before {
  background: url("data:image/svg+xml,%3Csvg width='480' height='480' viewBox='0 0 480 480' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%236fffe9' stroke-opacity='.16'%3E%3Ccircle cx='240' cy='240' r='80'/%3E%3Ccircle cx='240' cy='240' r='140'/%3E%3Ccircle cx='240' cy='240' r='210'/%3E%3Cpath d='M0 240h480M240 0v480M70 70l340 340M410 70 70 410'/%3E%3C/g%3E%3C/svg%3E") center/520px no-repeat;
  content: "";
  inset: 0;
  opacity: 0.85;
  position: absolute;
}

.scientists-panel > * {
  position: relative;
  z-index: 1;
}

.signup {
  background: rgba(3, 7, 17, 0.52);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem;
}

.signup label {
  display: block;
  font-weight: 900;
  margin-bottom: 0.9rem;
}

.signup div {
  display: flex;
  gap: 0.6rem;
}

.signup input {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: var(--ice);
  min-width: 0;
  padding: 0.9rem 1rem;
  width: 100%;
}

.signup input::placeholder {
  color: rgba(239, 251, 255, 0.48);
}

.signup small {
  color: var(--muted);
  display: block;
  margin-top: 0.8rem;
}

.site-footer {
  background: #020711;
  border-top: 1px solid var(--line);
  padding: 4rem 0;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr) auto minmax(220px, auto);
}

.footer-brand {
  margin-bottom: 1.4rem;
}

.site-footer nav,
.footer-meta {
  display: grid;
  gap: 0.7rem;
}

.site-footer nav a,
.footer-meta a {
  color: rgba(239, 251, 255, 0.76);
  font-weight: 700;
}

.footer-meta span {
  color: var(--muted);
  font-size: 0.86rem;
}

@media (max-width: 1020px) {
  .nav-toggle {
    display: inline-flex;
    position: relative;
    z-index: 60;
  }

  .site-nav {
    align-items: stretch;
    background: rgba(2, 7, 17, 0.96);
    border-left: 1px solid var(--line);
    flex-direction: column;
    gap: 0.35rem;
    inset: 0 0 0 auto;
    max-width: 420px;
    padding: 6.8rem 1.2rem 2rem;
    position: fixed;
    transform: translateX(100%);
    transition: transform 0.25s ease;
    width: min(86vw, 420px);
    z-index: 55;
  }

  .site-nav.is-open {
    transform: translateX(0);
  }

  .site-nav a {
    font-size: 1.15rem;
    padding: 1rem;
  }

  .site-nav .nav-cta {
    margin-left: 0;
    margin-top: 0.6rem;
    text-align: center;
  }

  .hero-grid,
  .intro-grid,
  .story-block,
  .observatory-grid,
  .detector-grid,
  .collaboration-grid,
  .scientists-panel,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .mission-card {
    min-height: 520px;
  }

  .story-block {
    gap: 1rem;
  }

  .metric-grid,
  .news-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .metric:first-child,
  .metric:last-child {
    border-radius: 0;
  }

  .metric:nth-child(1) {
    border-radius: var(--radius) 0 0 0;
  }

  .metric:nth-child(2) {
    border-radius: 0 var(--radius) 0 0;
  }

  .metric:nth-child(3) {
    border-radius: 0 0 0 var(--radius);
  }

  .metric:nth-child(4) {
    border-radius: 0 0 var(--radius) 0;
  }
}

@media (max-width: 680px) {
  :root {
    --wrap: min(100vw - 28px, 1180px);
  }

  .site-header {
    padding-inline: 14px;
  }

  .brand small {
    display: none;
  }

  .hero {
    padding-top: 7rem;
  }

  h1 {
    font-size: clamp(2.8rem, 14vw, 4.5rem);
  }

  h2 {
    font-size: clamp(2rem, 10vw, 3.2rem);
  }

  .hero-actions,
  .signup div,
  .section-heading.with-action {
    align-items: stretch;
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .mission-card {
    min-height: 470px;
    padding: 1rem;
  }

  .mission-card dl {
    left: 1rem;
    right: 1rem;
  }

  .mission-card dl div {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.2rem;
  }

  .mission-card dd {
    text-align: left;
  }

  .intro-panel,
  .observatory,
  .detector,
  .collaboration,
  .news,
  .scientists {
    padding: 4.5rem 0;
  }

  .scroll-story {
    padding-bottom: 4.5rem;
  }

  .story-block {
    padding: 3rem 0;
  }

  .map-card,
  .map-visual {
    min-height: 430px;
  }

  .pin-baikal {
    left: 10%;
  }

  .pin-sea {
    right: 8%;
  }

  .pin-ihep {
    left: 40%;
  }

  .spec-grid,
  .metric-grid,
  .news-grid {
    grid-template-columns: 1fr;
  }

  .metric,
  .metric:nth-child(n) {
    border-radius: 0;
  }

  .metric:first-child {
    border-radius: var(--radius) var(--radius) 0 0;
  }

  .metric:last-child {
    border-radius: 0 0 var(--radius) var(--radius);
  }

  .scientists-panel {
    padding: 1.2rem;
  }
}

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

.login-page {
  min-height: 100vh;
  overflow: hidden;
}

.login-page::before,
.login-page::after {
  content: "";
  pointer-events: none;
  position: fixed;
}

.login-page::before {
  background:
    radial-gradient(circle at 30% 25%, rgba(111, 255, 233, 0.22), transparent 20rem),
    radial-gradient(circle at 74% 72%, rgba(54, 243, 255, 0.16), transparent 24rem);
  inset: 0;
}

.login-page::after {
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  inset: 0;
  mask-image: linear-gradient(180deg, black, transparent 88%);
}

.login-shell {
  align-items: center;
  display: grid;
  min-height: 100vh;
  padding: 2rem;
  position: relative;
  z-index: 1;
}

.login-card {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.06));
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 12px);
  box-shadow: var(--shadow);
  margin: 0 auto;
  max-width: 520px;
  padding: clamp(1.4rem, 5vw, 3rem);
  width: min(100%, 520px);
}

.login-brand {
  margin-bottom: 2.4rem;
}

.login-card h1 {
  font-size: clamp(2.5rem, 8vw, 4.5rem);
  margin-bottom: 1rem;
}

.login-copy {
  color: rgba(239, 251, 255, 0.72);
  margin-bottom: 1.6rem;
}

.login-error {
  background: rgba(255, 95, 95, 0.14);
  border: 1px solid rgba(255, 95, 95, 0.36);
  border-radius: 16px;
  color: #ffd7d7;
  font-weight: 700;
  padding: 0.85rem 1rem;
}

.login-form {
  display: grid;
  gap: 0.8rem;
}

.login-form label {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.login-form input {
  background: rgba(2, 7, 17, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  color: var(--ice);
  margin-bottom: 0.6rem;
  padding: 1rem;
  width: 100%;
}

.login-form input:focus {
  border-color: rgba(111, 255, 233, 0.72);
  outline: none;
}

.login-form .button {
  border: 0;
  cursor: pointer;
  margin-top: 0.4rem;
}

.admin-page {
  min-height: 100vh;
}

.admin-header {
  align-items: center;
  backdrop-filter: blur(22px);
  background: rgba(2, 7, 17, 0.9);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  padding: 1rem max(20px, calc((100vw - 1280px) / 2));
  position: sticky;
  top: 0;
  z-index: 20;
}

.admin-actions {
  display: flex;
  gap: 0.8rem;
}

.admin-actions a {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  font-weight: 800;
  padding: 0.7rem 1rem;
}

.admin-shell {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: minmax(330px, 0.75fr) minmax(0, 1.25fr);
  margin: 0 auto;
  max-width: 1280px;
  padding: 1.2rem 20px 2rem;
}

.terminal-panel,
.editor-panel {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.055));
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.terminal-panel {
  display: grid;
  grid-template-rows: auto minmax(420px, 1fr) auto;
  min-height: calc(100vh - 120px);
}

.terminal-titlebar {
  align-items: center;
  background: rgba(3, 7, 17, 0.72);
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 0.55rem;
  padding: 0.9rem 1rem;
}

.terminal-titlebar strong {
  color: rgba(239, 251, 255, 0.86);
  font-size: 0.92rem;
  margin-left: 0.5rem;
}

.dot {
  border-radius: 999px;
  display: inline-block;
  height: 11px;
  width: 11px;
}

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.terminal-screen {
  background: rgba(0, 7, 16, 0.72);
  color: #d8fff8;
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.88rem;
  overflow: auto;
  padding: 1rem;
  white-space: pre-wrap;
}

.terminal-line,
.terminal-command,
.terminal-error {
  margin-bottom: 0.35rem;
}

.terminal-command {
  color: var(--aqua);
  font-weight: 700;
}

.terminal-error {
  color: #ffb8b8;
}

.terminal-input-row {
  align-items: center;
  background: rgba(3, 7, 17, 0.9);
  border-top: 1px solid var(--line);
  display: grid;
  gap: 0.6rem;
  grid-template-columns: auto 1fr auto;
  padding: 0.75rem;
}

.terminal-input-row span,
.terminal-input-row input {
  color: var(--aqua);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9rem;
}

.terminal-input-row input {
  background: transparent;
  border: 0;
  min-width: 0;
  outline: 0;
}

.terminal-input-row button {
  background: rgba(111, 255, 233, 0.16);
  border: 1px solid rgba(111, 255, 233, 0.34);
  border-radius: 999px;
  color: var(--aqua);
  cursor: pointer;
  font-weight: 900;
  padding: 0.55rem 0.9rem;
}

.editor-panel {
  display: grid;
  grid-template-rows: auto auto minmax(480px, 1fr) auto;
  min-height: calc(100vh - 120px);
  padding: 1.2rem;
}

.editor-toolbar {
  align-items: end;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
}

.editor-toolbar h1 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  margin-bottom: 0;
}

.editor-controls {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: flex-end;
}

.editor-controls select {
  background: rgba(2, 7, 17, 0.54);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  min-height: 3.2rem;
  padding: 0 1rem;
}

.admin-note {
  color: rgba(239, 251, 255, 0.68);
  margin: 0 0 1rem;
}

.editor-panel textarea {
  background: rgba(0, 7, 16, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  color: #effbff;
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9rem;
  line-height: 1.55;
  min-height: 480px;
  outline: 0;
  padding: 1rem;
  resize: vertical;
  width: 100%;
}

.editor-panel textarea:focus {
  border-color: rgba(111, 255, 233, 0.58);
}

.editor-status {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.82rem;
  padding-top: 0.8rem;
}

.editor-status.is-error {
  color: #ffb8b8;
}

@media (max-width: 980px) {
  .admin-shell,
  .editor-toolbar {
    grid-template-columns: 1fr;
  }

  .admin-shell {
    display: grid;
  }

  .editor-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .editor-controls {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .admin-header,
  .terminal-input-row {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-header {
    display: flex;
  }

  .admin-actions {
    width: 100%;
  }

  .admin-actions a {
    flex: 1;
    text-align: center;
  }

  .terminal-input-row {
    display: flex;
  }
}

.cms-page {
  background:
    radial-gradient(circle at 10% 0%, rgba(54, 243, 255, 0.16), transparent 30rem),
    linear-gradient(180deg, #030711 0%, #071833 100%);
  min-height: 100vh;
}

.cms-header {
  align-items: center;
  backdrop-filter: blur(22px);
  background: rgba(2, 7, 17, 0.9);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  padding: 1rem max(20px, calc((100vw - 1120px) / 2));
  position: sticky;
  top: 0;
  z-index: 20;
}

.cms-actions {
  display: flex;
  gap: 0.8rem;
}

.cms-actions a {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  font-weight: 800;
  padding: 0.7rem 1rem;
}

.cms-shell {
  margin: 0 auto;
  max-width: 1120px;
  padding: 2rem 20px 7rem;
}

.cms-hero-panel,
.cms-card,
.cms-savebar {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.055));
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: 0 18px 80px rgba(0, 0, 0, 0.16);
}

.cms-hero-panel {
  margin-bottom: 1.2rem;
  padding: clamp(1.4rem, 4vw, 2.4rem);
}

.cms-hero-panel h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  margin-bottom: 1rem;
}

.cms-hero-panel p:not(.section-kicker),
.cms-card-heading p {
  color: rgba(239, 251, 255, 0.72);
}

.cms-status {
  background: rgba(3, 7, 17, 0.52);
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--aqua);
  font-weight: 800;
  margin-top: 1.2rem;
  padding: 0.9rem 1rem;
}

.cms-status.is-error {
  color: #ffb8b8;
}

.cms-form {
  display: grid;
  gap: 1.2rem;
}

.cms-card {
  padding: clamp(1.1rem, 3vw, 2rem);
}

.cms-card-heading {
  align-items: start;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 1rem;
  margin-bottom: 1.3rem;
  padding-bottom: 1rem;
}

.cms-card-heading > span {
  align-items: center;
  background: rgba(111, 255, 233, 0.13);
  border: 1px solid rgba(111, 255, 233, 0.28);
  border-radius: 16px;
  color: var(--aqua);
  display: inline-grid;
  flex: 0 0 auto;
  font-weight: 900;
  height: 44px;
  place-items: center;
  width: 44px;
}

.cms-card-heading h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin-bottom: 0.35rem;
}

.cms-card label {
  color: var(--muted);
  display: grid;
  font-size: 0.86rem;
  font-weight: 900;
  gap: 0.45rem;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
}

.cms-card input,
.cms-card textarea {
  background: rgba(2, 7, 17, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  color: var(--ice);
  font-weight: 500;
  letter-spacing: 0;
  padding: 0.9rem 1rem;
  resize: vertical;
  width: 100%;
}

.cms-card input:focus,
.cms-card textarea:focus {
  border-color: rgba(111, 255, 233, 0.72);
  outline: none;
}

.cms-two-col {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cms-repeat {
  display: grid;
  gap: 1rem;
}

.cms-repeat fieldset {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  margin: 0;
  padding: 1rem;
}

.cms-repeat legend,
.cms-subtitle {
  color: var(--aqua);
  font-weight: 900;
}

.cms-subtitle {
  font-size: 1.1rem;
  margin: 1.4rem 0 0.8rem;
}

.cms-savebar {
  align-items: center;
  bottom: 0;
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  padding: 1rem;
  position: sticky;
  z-index: 10;
}

.cms-savebar button {
  border: 0;
  cursor: pointer;
}

.cms-savebar .secondary {
  border: 1px solid rgba(255, 255, 255, 0.26);
}

@media (max-width: 760px) {
  .cms-header,
  .cms-actions,
  .cms-savebar {
    align-items: stretch;
    flex-direction: column;
  }

  .cms-header,
  .cms-actions,
  .cms-savebar {
    display: flex;
  }

  .cms-two-col {
    grid-template-columns: 1fr;
  }

  .cms-actions a {
    text-align: center;
  }
}

.language-tabs {
  display: inline-flex;
  gap: 0.6rem;
  margin-top: 1rem;
}

.language-tabs button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  cursor: pointer;
  font-weight: 900;
  padding: 0.72rem 1rem;
}

.language-tabs button.is-active {
  background: linear-gradient(135deg, var(--aqua), var(--cyan));
  border-color: transparent;
  color: #00111e;
}

/* Baikal-HUNT CMS public site */
.cms-public-header .brand strong {
  letter-spacing: 0.08em;
}

.cms-nav {
  gap: 0.35rem;
}

.nav-item {
  position: relative;
}

.nav-item > a,
.submenu-item > a {
  display: block;
}

.nav-item.has-children > a::after {
  content: "⌄";
  margin-left: 0.35rem;
}

.submenu {
  background: rgba(2, 7, 17, 0.96);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  display: none;
  left: 0;
  min-width: 220px;
  padding: 0.45rem;
  position: absolute;
  top: calc(100% + 0.4rem);
  z-index: 90;
}

.submenu.nested {
  left: calc(100% + 0.4rem);
  top: 0;
}

.nav-item:hover > .submenu,
.nav-item:focus-within > .submenu,
.submenu-item:hover > .submenu,
.submenu-item:focus-within > .submenu {
  display: block;
}

.submenu a {
  border-radius: 12px;
  color: rgba(239, 251, 255, 0.86);
  font-size: 0.9rem;
  padding: 0.72rem 0.85rem;
  white-space: nowrap;
}

.content-section {
  padding: 6rem 0;
}

.cms-text-block {
  border-bottom: 1px solid var(--line);
  padding-bottom: 4rem;
}

.cms-cards-section .cms-card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cms-media-section {
  background: #06111f;
  padding: 6rem 0;
}

.media-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.media-card {
  background: linear-gradient(160deg, rgba(255,255,255,0.12), rgba(255,255,255,0.055));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 0;
  overflow: hidden;
}

.media-card img,
.media-card video {
  aspect-ratio: 16 / 10;
  background: rgba(0,0,0,0.28);
  object-fit: cover;
  width: 100%;
}

.media-card figcaption {
  display: grid;
  gap: 0.35rem;
  padding: 1rem;
}

.media-card figcaption span,
.empty-state {
  color: rgba(239,251,255,0.68);
}

.article-page {
  padding: 9rem 0 6rem;
}

.article-page h1 {
  max-width: 980px;
}

.article-body {
  color: rgba(239,251,255,0.78);
  font-size: 1.12rem;
  max-width: 820px;
}

.article-body p {
  margin-bottom: 1.2rem;
}

.loading-state {
  padding: 10rem 0;
}

/* Baikal-HUNT CMS admin */
.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0 0 1.2rem;
}

.admin-tabs button,
.menu-row button,
.row-actions button,
.admin-media-card button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ice);
  cursor: pointer;
  font-weight: 800;
  padding: 0.58rem 0.82rem;
}

.admin-tabs button.is-active {
  background: linear-gradient(135deg, var(--aqua), var(--cyan));
  border-color: transparent;
  color: #00111e;
}

.admin-panel {
  display: none;
}

.admin-panel.is-active {
  display: block;
}

.menu-editor-actions,
.row-actions,
.page-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 1rem;
}

.menu-tree {
  display: grid;
  gap: 0.65rem;
}

.menu-row {
  align-items: center;
  background: rgba(2, 7, 17, 0.36);
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 18px;
  display: grid;
  gap: 0.5rem;
  grid-template-columns: minmax(160px, 1.1fr) minmax(180px, 1.2fr) 110px repeat(6, auto);
  margin-left: calc(var(--depth) * 1.4rem);
  padding: 0.7rem;
}

.menu-row input,
.menu-row select,
.page-controls select,
.block-editor select,
.article-edit select,
.upload-form input {
  background: rgba(2, 7, 17, 0.48);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 12px;
  color: var(--ice);
  padding: 0.72rem 0.82rem;
  width: 100%;
}

.block-list,
.article-editor,
.media-library,
.source-list {
  display: grid;
  gap: 1rem;
}

.block-editor,
.article-edit,
.source-list article {
  background: rgba(2, 7, 17, 0.28);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 22px;
  margin: 0;
  padding: 1rem;
}

.block-editor legend,
.article-edit legend {
  color: var(--aqua);
  font-weight: 900;
  padding: 0 0.45rem;
}

.upload-form {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1.2fr repeat(3, 1fr) auto;
  margin-bottom: 1.2rem;
}

.media-library {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-media-card code {
  color: var(--aqua);
  font-size: 0.75rem;
  overflow-wrap: anywhere;
}

.source-list a {
  color: var(--aqua);
  overflow-wrap: anywhere;
}

@media (max-width: 1120px) {
  .menu-row,
  .upload-form {
    grid-template-columns: 1fr;
  }

  .cms-cards-section .cms-card-grid,
  .media-grid,
  .media-library {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1020px) {
  .site-nav .nav-item > a {
    font-size: 1.15rem;
    padding: 1rem;
  }

  .submenu,
  .submenu.nested {
    background: rgba(255,255,255,0.05);
    border: 0;
    box-shadow: none;
    display: block;
    left: auto;
    margin-left: 1rem;
    min-width: 0;
    padding: 0;
    position: static;
    top: auto;
  }

  .submenu a {
    white-space: normal;
  }
}

@media (max-width: 680px) {
  .cms-cards-section .cms-card-grid,
  .media-grid,
  .media-library {
    grid-template-columns: 1fr;
  }
}

/* Explicit dropdown behavior for secondary menus */
.nav-item.has-children,
.submenu-item.has-children {
  align-items: center;
  display: flex;
  gap: 0.15rem;
}

.nav-item.has-children > a,
.submenu-item.has-children > a {
  padding-right: 0.25rem;
}

.submenu-toggle {
  align-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: rgba(239, 251, 255, 0.86);
  cursor: pointer;
  display: inline-flex;
  font: inherit;
  height: 2rem;
  justify-content: center;
  line-height: 1;
  min-width: 2rem;
  padding: 0;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.submenu-toggle:hover,
.submenu-toggle:focus-visible {
  background: rgba(54, 243, 255, 0.14);
  color: white;
  outline: none;
}

.nav-item.is-open > .submenu-toggle,
.submenu-item.is-open > .submenu-toggle {
  background: rgba(54, 243, 255, 0.2);
  color: var(--cyan);
  transform: rotate(180deg);
}

.submenu-item.is-open > .nested-toggle {
  transform: rotate(0deg);
}

.nav-item.is-open > .submenu,
.submenu-item.is-open > .submenu {
  display: block;
}

.nav-item.has-children > a::after {
  content: none;
}

.submenu-item {
  position: relative;
}

.submenu-item.has-children {
  justify-content: space-between;
}

.submenu-item.has-children > a {
  flex: 1;
}

@media (max-width: 1020px) {
  .nav-item.has-children,
  .submenu-item.has-children {
    display: grid;
    grid-template-columns: 1fr auto;
  }

  .submenu,
  .submenu.nested {
    display: none;
    grid-column: 1 / -1;
    margin: 0.25rem 0 0.5rem 1rem;
  }

  .nav-item.is-open > .submenu,
  .submenu-item.is-open > .submenu {
    display: block;
  }
}

/* IHEP Tianfu-style horizontal nav and dropdown menus */
.cms-public-header.ihep-nav-style,
.cms-public-header {
  background: rgba(2, 18, 54, 0.92);
  border-bottom: 0;
  box-shadow: 0 10px 30px rgba(0, 18, 70, 0.22);
  gap: 2rem;
  padding-block: 0;
}

.cms-public-header .brand {
  padding: 1.1rem 0;
}

.cms-public-header .brand-mark {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.28);
  border-radius: 10px;
}

.cms-public-header .brand small {
  color: rgba(255,255,255,0.74);
  max-width: 360px;
  white-space: normal;
}

.cms-nav {
  align-items: stretch;
  display: flex;
  flex: 1;
  justify-content: flex-end;
  min-width: 0;
}

.cms-nav .navbar-nav {
  align-items: stretch;
  display: flex;
  flex: 1;
  justify-content: flex-end;
  list-style: none;
  margin: 0;
  max-width: 780px;
  padding: 0;
}

.cms-nav .navbar-nav > li {
  flex: 1 1 0;
  list-style: none;
  min-width: 0;
  position: relative;
}

.cms-nav .navbar-nav > li > a {
  align-items: center;
  border-radius: 0;
  color: #fff;
  display: flex;
  font-size: 0.96rem;
  font-weight: 700;
  height: 100%;
  justify-content: center;
  line-height: 1.25;
  min-height: 82px;
  padding: 0 0.55rem;
  position: relative;
  text-align: center;
}

.cms-nav .navbar-nav > li > a::after {
  background: #f1f1f1;
  bottom: 0;
  content: "";
  height: 4px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  transition: width 0.25s ease;
  width: 0;
}

.cms-nav .navbar-nav > li:hover > a,
.cms-nav .navbar-nav > li:focus-within > a,
.cms-nav .navbar-nav > li.is-open > a {
  background: transparent;
  color: #fff;
}

.cms-nav .navbar-nav > li:hover > a::after,
.cms-nav .navbar-nav > li:focus-within > a::after,
.cms-nav .navbar-nav > li.is-open > a::after {
  width: 46px;
}

.cms-nav li.dropdown > a::before {
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid rgba(255,255,255,0.86);
  content: "";
  margin-top: -2px;
  position: absolute;
  right: 0.18rem;
  top: 50%;
}

.cms-nav .dropdown-menu {
  animation: huntFadeInDown 0.2s ease both;
  background: #fff;
  border: 0;
  border-left: 3px solid #0247a3;
  box-shadow: 0 10px 24px rgba(0,0,0,0.18);
  display: none;
  left: 0;
  list-style: none;
  margin: 0;
  min-width: 178px;
  padding: 10px 0;
  position: absolute;
  top: 100%;
  width: 100%;
  z-index: 1000;
}

.cms-nav li.dropdown:hover > .dropdown-menu,
.cms-nav li.dropdown:focus-within > .dropdown-menu,
.cms-nav li.dropdown.is-open > .dropdown-menu {
  display: block;
}

.cms-nav .dropdown-menu li {
  list-style: none;
  position: relative;
}

.cms-nav .dropdown-menu a {
  background: transparent;
  border-radius: 0;
  color: #444;
  display: block;
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 24px;
  margin: 0;
  padding: 8px 15px;
  text-align: left;
  white-space: nowrap;
}

.cms-nav .dropdown-menu a:hover,
.cms-nav .dropdown-menu a:focus-visible {
  background: #f3f6fb;
  color: #0247a3;
  outline: none;
}

.cms-nav .dropdown-menu.nested {
  left: 100%;
  top: -10px;
}

@keyframes huntFadeInDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1180px) {
  .cms-nav .navbar-nav {
    max-width: none;
  }

  .cms-nav .navbar-nav > li > a {
    font-size: 0.86rem;
    padding-inline: 0.42rem;
  }
}

@media (max-width: 1020px) {
  .cms-public-header {
    padding-block: 0.6rem;
  }

  .cms-public-header .brand {
    padding: 0;
  }

  .cms-nav {
    align-items: stretch;
    background: rgba(2, 18, 54, 0.98);
    border-left: 1px solid var(--line);
    flex-direction: column;
    justify-content: flex-start;
  }

  .cms-nav .navbar-nav {
    display: block;
    max-width: none;
    width: 100%;
  }

  .cms-nav .navbar-nav > li {
    border-bottom: 1px solid rgba(255,255,255,0.09);
    display: block;
    width: 100%;
  }

  .cms-nav .navbar-nav > li > a {
    justify-content: flex-start;
    min-height: 0;
    padding: 1rem 1.15rem;
    text-align: left;
  }

  .cms-nav .navbar-nav > li > a::after {
    display: none;
  }

  .cms-nav li.dropdown > a::before {
    right: 1rem;
  }

  .cms-nav .dropdown-menu,
  .cms-nav .dropdown-menu.nested {
    background: rgba(255,255,255,0.96);
    border-left: 3px solid #2c7be5;
    box-shadow: none;
    left: auto;
    margin: 0 1rem 1rem;
    position: static;
    top: auto;
    width: auto;
  }

  .cms-nav li.dropdown:hover > .dropdown-menu,
  .cms-nav li.dropdown:focus-within > .dropdown-menu {
    display: none;
  }

  .cms-nav li.dropdown.is-open > .dropdown-menu {
    display: block;
  }
}

/* Harmonized Baikal-HUNT top navigation colors */
.cms-public-header {
  background:
    linear-gradient(90deg, rgba(3, 13, 35, 0.96), rgba(5, 40, 66, 0.94) 48%, rgba(6, 65, 88, 0.92));
  box-shadow: 0 12px 34px rgba(0, 10, 28, 0.28);
}

.cms-nav .navbar-nav > li > a {
  color: rgba(226, 248, 255, 0.88);
}

.cms-nav .navbar-nav > li:hover > a,
.cms-nav .navbar-nav > li:focus-within > a,
.cms-nav .navbar-nav > li.is-open > a {
  color: #ffffff;
}

.cms-nav .navbar-nav > li > a::after {
  background: linear-gradient(90deg, rgba(111, 255, 233, 0.2), rgba(111, 255, 233, 0.95), rgba(54, 243, 255, 0.75));
}

.cms-nav li.dropdown > a::before {
  border-top-color: rgba(111, 255, 233, 0.82);
}

.cms-nav .dropdown-menu {
  background: rgba(241, 251, 255, 0.98);
  border-left-color: #00a7bd;
  box-shadow: 0 14px 30px rgba(0, 22, 48, 0.2);
}

.cms-nav .dropdown-menu a {
  color: #123246;
}

.cms-nav .dropdown-menu a:hover,
.cms-nav .dropdown-menu a:focus-visible {
  background: rgba(0, 167, 189, 0.09);
  color: #006f80;
}

/* Editable media attachments for text, articles, and content blocks */
.cms-text-content {
  display: grid;
  gap: 1.1rem;
}

.cms-text-with-media .cms-text-content:has(.media-left),
.cms-text-with-media .cms-text-content:has(.media-right) {
  align-items: start;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.9fr);
}

.cms-text-with-media .cms-text-content:has(.media-left) .cms-text-copy {
  order: 2;
}

.cms-text-with-media .cms-text-content:has(.media-left) .cms-attached-media {
  order: 1;
}

.cms-attached-media {
  background: rgba(255,255,255,0.08);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 20px 60px rgba(0, 18, 70, 0.18);
  margin: 0;
  overflow: hidden;
}

.cms-attached-media img,
.cms-attached-media video {
  aspect-ratio: 16 / 10;
  background: rgba(0,0,0,0.35);
  display: block;
  object-fit: cover;
  width: 100%;
}

.cms-attached-media figcaption {
  color: rgba(239,251,255,0.72);
  font-size: 0.88rem;
  padding: 0.75rem 0.9rem;
}

.section-media.wrap {
  margin-bottom: 1.5rem;
  max-width: min(900px, calc(100% - 2rem));
}

.card-media,
.news-card-media {
  margin-bottom: 1rem;
}

.card-media img,
.card-media video,
.news-card-media img,
.news-card-media video {
  aspect-ratio: 16 / 9;
}

.hero-attached-media {
  margin: 1.3rem 0;
  max-width: 620px;
}

.article-hero-media {
  margin: 1.8rem 0 2rem;
  max-width: 920px;
}

.cms-cta-with-media {
  align-items: center;
}

.cta-media {
  min-width: min(320px, 100%);
}

.cms-media-picker {
  background: rgba(255,255,255,0.045);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px;
  display: grid;
  gap: 0.8rem;
  padding: 0.9rem;
}

.cms-help-text {
  color: rgba(239,251,255,0.62);
  font-size: 0.84rem;
  margin: 0;
}

@supports not selector(:has(*)) {
  .cms-text-with-media .cms-text-content {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .cms-text-with-media .cms-text-content,
  .cms-text-with-media .cms-text-content:has(.media-left),
  .cms-text-with-media .cms-text-content:has(.media-right) {
    grid-template-columns: minmax(0, 1fr);
  }

  .cms-text-with-media .cms-text-content:has(.media-left) .cms-text-copy,
  .cms-text-with-media .cms-text-content:has(.media-left) .cms-attached-media {
    order: initial;
  }
}

/* CMS-controlled font sizes */
body {
  font-size: var(--fs-body, 16px);
}

.brand strong {
  font-size: var(--fs-brand, 17px);
}

.brand small,
.cms-public-header .brand small {
  font-size: var(--fs-brand-subtitle, 12px);
}

.cms-nav .navbar-nav > li > a,
.site-nav a {
  font-size: var(--fs-menu, 15px);
}

.cms-nav .dropdown-menu a,
.site-nav .submenu a,
.site-nav .submenu-item > a {
  font-size: var(--fs-submenu, 15px);
}

h1,
.hero h1 {
  font-size: clamp(calc(var(--fs-hero-title, 96px) * 0.58), 8vw, var(--fs-hero-title, 96px));
}

h2,
.section-heading h2,
.cms-text-block h2,
.scientists-panel h2 {
  font-size: clamp(calc(var(--fs-section-title, 56px) * 0.62), 4.2vw, var(--fs-section-title, 56px));
}

h3,
.feature-list h3,
.spec-grid h3,
.news-card h3 {
  font-size: var(--fs-card-title, 22px);
}

.section-kicker,
.eyebrow,
.news-card time {
  font-size: var(--fs-section-kicker, 13px);
}

.hero-lede,
.hero-copy > p:not(.eyebrow) {
  font-size: var(--fs-hero-body, 22px);
}

.content-section p,
.cms-text-copy p,
.feature-list p,
.spec-grid p,
.news-card p,
.scientists-panel p {
  font-size: var(--fs-card-body, 16px);
}

.metric strong {
  font-size: clamp(calc(var(--fs-metric-number, 56px) * 0.72), 4vw, var(--fs-metric-number, 56px));
}

.metric span {
  font-size: var(--fs-metric-label, 16px);
}

.article-page h1 {
  font-size: clamp(calc(var(--fs-article-title, 64px) * 0.58), 6vw, var(--fs-article-title, 64px));
}

.article-body {
  font-size: var(--fs-article-body, 18px);
}

.button {
  font-size: var(--fs-button, 16px);
}

.site-footer,
.site-footer p,
.site-footer a,
.footer-meta span {
  font-size: var(--fs-footer, 16px);
}

.cms-attached-media figcaption,
.media-card figcaption,
.admin-media-card code {
  font-size: var(--fs-caption, 14px);
}

.typography-grid {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.typography-field {
  background: rgba(255,255,255,0.045);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  padding: 0.9rem;
}

.typography-field > div {
  align-items: center;
  display: grid;
  gap: 0.65rem;
  grid-template-columns: minmax(120px, 1fr) 86px 28px;
}

.typography-field input[type="range"] {
  accent-color: var(--aqua);
}

.typography-field input[type="number"] {
  text-align: right;
}

@media (max-width: 760px) {
  .typography-grid {
    grid-template-columns: 1fr;
  }
}

/* Project image logo */
.brand-mark.logo-mark {
  background: transparent;
  border: 0;
  border-radius: 50%;
  box-shadow: 0 10px 30px rgba(0, 25, 60, 0.3);
  height: 56px;
  overflow: hidden;
  width: 56px;
}

.brand-mark.logo-mark img {
  display: block;
  height: 100%;
  object-fit: contain;
  width: 100%;
}

.cms-public-header .brand-mark.logo-mark {
  height: 62px;
  width: 62px;
}

.login-brand .brand-mark.logo-mark,
.cms-header .brand-mark.logo-mark {
  height: 64px;
  width: 64px;
}

.footer-brand .brand-mark.logo-mark {
  height: 58px;
  width: 58px;
}

@media (max-width: 760px) {
  .cms-public-header .brand-mark.logo-mark,
  .login-brand .brand-mark.logo-mark,
  .cms-header .brand-mark.logo-mark {
    height: 50px;
    width: 50px;
  }
}

/* Mission card editable settings in admin */
.cms-subsection {
  background: rgba(255,255,255,0.045);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  display: grid;
  gap: 0.9rem;
  margin-top: 1rem;
  padding: 1rem;
}

.cms-subsection h3 {
  color: var(--text);
  font-size: 1.05rem;
  margin: 0;
}
