/* Custom styles for AB Spanish & Korean School */

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #102a43;
}
::-webkit-scrollbar-thumb {
  background: #334e68;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #486581;
}

/* Selection color */
::selection {
  background: rgba(232, 145, 15, 0.3);
  color: #f0f4f8;
}

/* Navbar scroll state */
.navbar-scrolled {
  background: rgba(10, 26, 46, 0.95) !important;
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(51, 78, 104, 0.5);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Reveal animations — progressive enhancement, works without JS */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

/* When JS is enabled, add hidden state and animate */
.js-enabled .reveal {
  opacity: 0;
  transform: translateY(30px);
}

.js-enabled .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays for grid items */
.reveal:nth-child(1) { transition-delay: 0ms; }
.reveal:nth-child(2) { transition-delay: 100ms; }
.reveal:nth-child(3) { transition-delay: 200ms; }
.reveal:nth-child(4) { transition-delay: 300ms; }

/* Mobile menu animation */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
#mobile-menu.open {
  max-height: 400px;
}

/* Mobile menu links */
.mobile-menu-link {
  display: block;
  padding: 8px 0;
  border-bottom: 1px solid rgba(51, 78, 104, 0.3);
}
.mobile-menu-link:last-child {
  border-bottom: none;
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .js-enabled .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Select dropdown arrow */
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23829ab1' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.649l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

/* Focus visible for accessibility */
*:focus-visible {
  outline: 2px solid #e8910f;
  outline-offset: 2px;
}

/* Button hover glow */
button:hover, a:hover {
  /* handled by Tailwind utilities */
}
