*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  overflow-x: hidden;
}

/* Navbar scroll state */
.nav-scrolled {
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(20px);
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

.nav-scrolled .nav-logo-text {
  color: #1c1c1f !important;
}

.nav-scrolled .nav-link {
  color: rgba(28, 28, 31, 0.8) !important;
}

.nav-scrolled .nav-link:hover {
  color: #E86A5B !important;
}

/* Scroll reveal */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Float animations */
@keyframes float {
  0%, 100% { transform: translateY(0px) scale(1); }
  50% { transform: translateY(-20px) scale(1.05); }
}

@keyframes float-delay {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-14px); }
}

.animate-float {
  animation: float 6s ease-in-out infinite;
}

.animate-float-delay {
  animation: float-delay 5s ease-in-out infinite 1.5s;
}

/* Mobile menu */
#mobile-menu {
  animation: slideDown 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Input autofill */
input:-webkit-autofill,
textarea:-webkit-autofill {
  box-shadow: 0 0 0 30px white inset !important;
  -webkit-text-fill-color: #27272a !important;
}

/* Focus visible */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid #E86A5B;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Selection */
::selection {
  background: rgba(232, 106, 91, 0.2);
  color: #1c1c1f;
}

/* Smooth image loading */
img {
  opacity: 1;
  transition: opacity 0.3s ease;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
  .scroll-reveal {
    opacity: 1;
    transform: none;
  }
}
