.federation-cinematic.gov-hero {
  min-height: 820px;
  background: #05090e;
}

.federation-cinematic::before {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(4, 10, 17, .98) 0%, rgba(4, 10, 17, .9) 31%, rgba(4, 10, 17, .52) 51%, rgba(4, 10, 17, .08) 78%),
    linear-gradient(0deg, rgba(4, 10, 17, .88) 0%, transparent 36%, rgba(4, 10, 17, .22) 100%);
}

.federation-cinematic::after {
  z-index: 1;
  box-shadow: inset 0 -8rem 9rem rgba(0, 0, 0, .4), inset 0 0 10rem rgba(0, 0, 0, .3);
}

.federation-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #05090e;
}

.federation-fallback,
.federation-scene-host {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.federation-fallback {
  object-fit: cover;
  object-position: center;
  opacity: .48;
  filter: saturate(.72) contrast(1.08) brightness(.62);
  transition: opacity .45s cubic-bezier(.16, 1, .3, 1);
}

.federation-scene-host {
  opacity: 0;
  touch-action: pan-y;
  cursor: grab;
  transition: opacity .55s cubic-bezier(.16, 1, .3, 1);
}

.federation-scene-host:active { cursor: grabbing; }
.federation-scene-host:focus-visible {
  outline: 3px solid #8eeaff;
  outline-offset: -6px;
}
.federation-scene-host canvas { width: 100%; height: 100%; display: block; }
.federation-cinematic.scene-ready .federation-scene-host { opacity: 1; }
.federation-cinematic.scene-ready .federation-fallback { opacity: 0; }
.federation-cinematic.scene-failed .federation-scene-host { visibility: hidden; }
.federation-cinematic.scene-failed .federation-fallback { opacity: .62; }

.federation-site-label {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 3;
  min-width: 4.6rem;
  padding: .44rem .62rem;
  border: 1px solid rgba(112, 226, 255, .45);
  border-radius: .35rem;
  color: #e8faff;
  background: rgba(4, 17, 27, .82);
  box-shadow: 0 8px 26px rgba(0, 0, 0, .28);
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .11em;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
}

.federation-cinematic .gov-hero-grid {
  min-height: 650px;
  grid-template-columns: minmax(0, 35rem) minmax(25rem, 1fr);
  gap: clamp(2rem, 5vw, 5.5rem);
  align-items: end;
}

.federation-cinematic .gov-hero-copy {
  align-self: center;
  max-width: 35rem;
  padding-top: 1.5rem;
}

.federation-cinematic h1 {
  max-width: 35rem;
  font-size: clamp(3.2rem, 4.75vw, 5rem);
  line-height: 1.02;
  letter-spacing: -.04em;
}

.federation-cinematic .gov-hero-copy > p:not(.eyebrow) {
  max-width: 31rem;
  font-size: 1.08rem;
  line-height: 1.72;
}

.federation-explorer {
  position: absolute;
  right: 0;
  bottom: 1.5rem;
  z-index: 5;
  display: flex;
  align-items: stretch;
  width: auto;
  max-width: calc(100% - 1rem);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #fff;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.federation-explorer-head,
.federation-state-copy,
.federation-concept-note,
.federation-drag-hint {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.federation-mode-control {
  display: flex;
  gap: 0;
  border: 1px solid rgba(167, 214, 228, .3);
  background: rgba(3, 13, 22, .76);
  backdrop-filter: blur(10px);
}

.federation-mode-control button {
  min-width: 6.7rem;
  min-height: 44px;
  padding: .45rem .7rem;
  border: 0;
  border-right: 1px solid rgba(167, 214, 228, .22);
  border-radius: 0;
  color: rgba(229, 246, 252, .72);
  background: transparent;
  font-size: .7rem;
  font-weight: 760;
  line-height: 1.1;
  cursor: pointer;
  transition: color .16s ease, background-color .16s ease, box-shadow .16s ease;
}

.federation-mode-control button:last-child { border-right: 0; }

.federation-mode-control button:hover {
  color: #fff;
  background: rgba(156, 236, 255, .09);
}

.federation-mode-control button[aria-pressed="true"] {
  color: #fff;
  background: rgba(71, 208, 241, .16);
  box-shadow: inset 0 -2px #8eeaff;
}

.federation-mode-control button:focus-visible,
.federation-control-row button:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.federation-mode-control button span {
  display: inline;
  margin-right: .3rem;
  font-size: .56rem;
  letter-spacing: .08em;
  opacity: .58;
}

.federation-control-row {
  display: flex;
  gap: 0;
  align-items: center;
  margin-left: .4rem;
  padding: 0;
  border: 1px solid rgba(160, 214, 231, .26);
  background: rgba(3, 13, 22, .7);
  backdrop-filter: blur(10px);
}

.federation-control-row button {
  min-height: 44px;
  padding: .45rem .65rem;
  border: 0;
  border-right: 1px solid rgba(160, 214, 231, .2);
  border-radius: 0;
  color: rgba(231, 248, 253, .78);
  background: transparent;
  font-size: .68rem;
  font-weight: 720;
  cursor: pointer;
}

.federation-control-row button:hover { background: rgba(255, 255, 255, .1); }
.federation-control-row button:last-of-type { border-right: 0; }

.federation-cinematic .hero-scroll-cue { z-index: 4; }
.federation-cinematic .hero-scroll-cue svg { width: .9rem; }

@media (max-width: 1100px) {
  .federation-cinematic .gov-hero-grid { grid-template-columns: minmax(0, 32rem) minmax(22rem, 1fr); }
  .federation-cinematic .gov-hero-copy { max-width: 32rem; }
}

@media (max-width: 860px) {
  .federation-cinematic.gov-hero {
    min-height: 1040px;
    padding: 8.7rem 0 3rem;
  }
  .federation-cinematic::before {
    background:
      linear-gradient(180deg, #05090e 0%, rgba(5, 9, 14, .98) 36%, rgba(5, 9, 14, .32) 57%, rgba(5, 9, 14, .88) 79%, #05090e 100%);
  }
  .federation-cinematic .gov-hero-grid {
    min-height: 860px;
    display: block;
  }
  .federation-cinematic .gov-hero-copy {
    position: relative;
    z-index: 4;
    max-width: 100%;
    padding-top: 0;
  }
  .federation-cinematic h1 {
    max-width: 34rem;
    font-size: clamp(2.8rem, 11.2vw, 4rem);
  }
  .federation-cinematic .gov-hero-copy > p:not(.eyebrow) {
    max-width: 35rem;
    font-size: 1rem;
    line-height: 1.62;
  }
  .federation-backdrop {
    top: 26.5rem;
    height: 34rem;
    bottom: auto;
  }
  .federation-explorer {
    position: relative;
    z-index: 4;
    right: auto;
    bottom: auto;
    display: flex;
    align-items: stretch;
    width: max-content;
    max-width: 100%;
    margin: 28rem 0 0 auto;
  }
  .federation-cinematic .hero-assurance { display: none; }
  .federation-cinematic .hero-scroll-cue { display: none; }
}

@media (max-width: 520px) {
  .federation-cinematic.gov-hero { min-height: 1010px; }
  .federation-backdrop { top: 29rem; height: 31rem; }
  .federation-explorer { margin-top: 26rem; }
  .federation-mode-control { flex: 1 1 auto; min-width: 0; }
  .federation-mode-control button { min-width: 0; min-height: 46px; padding: .45rem .42rem; font-size: .67rem; }
  .federation-mode-control button span { display: block; margin: 0 0 .12rem; }
  .federation-control-row { flex: 0 0 auto; margin-left: .3rem; }
  .federation-control-row button { min-height: 46px; padding: .42rem .48rem; font-size: .62rem; }
  .federation-site-label { font-size: .58rem; }
}

@media (prefers-reduced-motion: reduce) {
  .federation-fallback,
  .federation-scene-host,
  .federation-mode-control button { transition-duration: .01ms; }
}
