  *, *::before, *::after { box-sizing: border-box; }
  html { scroll-behavior: smooth; scroll-padding-top: 80px; }
  body { margin: 0; }

  @keyframes float {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-20px) scale(1.05); }
  }
  @keyframes float-delay {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-15px) scale(1.03); }
  }
  .animate-float { animation: float 6s ease-in-out infinite; }
  .animate-float-delay { animation: float-delay 8s ease-in-out infinite; }

  /* Scroll reveal — progressive enhancement via JS, hidden by default for reduced-motion */
  @media (prefers-reduced-motion: no-preference) {
    .reveal { opacity: 1; transform: translateY(0); transition: opacity 0.7s ease, transform 0.7s ease; }
  }
  .reveal.is-revealed { opacity: 1; transform: translateY(0); }

  /* Navbar transitions */
  #navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(30, 58, 138, 0.08);
  }
  #navbar.scrolled .font-display { color: #1e3a8a; }
  #navbar.scrolled a:not(.bg-midnight-900):not(.bg-mint-400) { color: #3b5bdb; }

  /* Custom scrollbar */
  ::-webkit-scrollbar { width: 8px; }
  ::-webkit-scrollbar-track { background: #f0fdf4; }
  ::-webkit-scrollbar-thumb { background: #91a7ff; border-radius: 4px; }
  ::-webkit-scrollbar-thumb:hover { background: #4c6ef5; }

  /* Selection color */
  ::selection { background: #bbf7d0; color: #1e3a8a; }

  /* Smooth image loading */
  img { loading: lazy; }
