/* Native scrolling and short, single-pass transitions. No scroll capture or parallax. */
:root {
  --motion-ease: cubic-bezier(.22, 1, .36, 1);
}

.site-menu,
#section-menu {
  transform-origin: top center;
  max-height: calc(100svh - 140px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

#section-menu {
  border-top: 1px solid #ffffff16;
  box-shadow: 0 18px 30px -18px #0006;
}

.site-menu a,
#section-menu a {
  min-height: 44px;
  border-bottom: 1px solid #ffffff16;
  transition: color 220ms ease, background-color 220ms ease;
}

.site-menu a:last-child,
#section-menu a:last-child { border-bottom: 0; }

.site-menu a:focus-visible,
#section-menu a:focus-visible { outline-offset: -2px; }

.section-menu-toggle span {
  transform-origin: center;
  transition: transform 280ms var(--motion-ease), opacity 160ms ease;
}
.section-menu-toggle[aria-expanded='true'] span:first-child { transform: translateY(5px) rotate(45deg); }
.section-menu-toggle[aria-expanded='true'] span:nth-child(2) { opacity: 0; }
.section-menu-toggle[aria-expanded='true'] span:last-child { transform: translateY(-5px) rotate(-45deg); }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  .site-menu[data-open='true'] a,
  #section-menu[data-open='true'] a {
    animation: menu-item-in 320ms var(--motion-ease) backwards;
  }
  :is(.site-menu, #section-menu) a:nth-child(2) { animation-delay: 35ms; }
  :is(.site-menu, #section-menu) a:nth-child(3) { animation-delay: 70ms; }
  :is(.site-menu, #section-menu) a:nth-child(4) { animation-delay: 105ms; }
  :is(.site-menu, #section-menu) a:nth-child(5) { animation-delay: 140ms; }

  .floating-header:not([hidden]) { animation: header-in 380ms var(--motion-ease); }
  .sectors-list details[open] .sector-details { animation: content-in 380ms var(--motion-ease) both; }
  .expand-icon { transition: transform 280ms var(--motion-ease); }
  .approach-panel:not([hidden]) { animation: content-in 380ms var(--motion-ease) both; }

  .materials-link .icon,
  .hero-secondary .icon,
  .edge-button .arrow-box,
  .text-link .icon,
  .site-menu .icon {
    transition: transform 300ms var(--motion-ease);
  }
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .materials-link:hover .icon,
  .edge-button:not(:disabled):hover .arrow-box { transform: translateX(3px); }
  .hero-secondary:hover .icon,
  .text-link:hover .icon,
  .site-menu a:hover .icon { transform: translate(2px, -2px); }
}

@keyframes menu-item-in {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes header-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes content-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .floating-header,
  .site-menu a,
  #section-menu a,
  .sector-details,
  .approach-panel { animation: none !important; }
}

@media print {
  .floating-header { display: none; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
