/* ============================================
   Whatstheteasmyrna — Custom Styles
   ============================================ */

/* ── Base / Reset ── */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ── Scroll Reveal (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }

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

  .reveal:nth-child(2) { transition-delay: 0.1s; }
  .reveal:nth-child(3) { transition-delay: 0.2s; }
  .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Ensure content is visible when JS is disabled */
@supports not (animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1)) {
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ── Navbar ── */
#navbar {
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
  background: rgba(255, 251, 240, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 20px rgba(123, 45, 139, 0.08);
  padding-top: 0;
  padding-bottom: 0;
}

.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #F5A623, #FFC240);
  border-radius: 2px;
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

/* ── Mobile Menu ── */
#mobile-menu {
  animation: slideDown 0.3s ease forwards;
}

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

.mobile-link {
  display: block;
}

/* Hamburger animation */
#menu-toggle[aria-expanded="true"] .menu-line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

#menu-toggle[aria-expanded="true"] .menu-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

#menu-toggle[aria-expanded="true"] .menu-line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ── Hero ── */
#hero {
  position: relative;
}

#hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(to top, #FFFBF0, transparent);
  pointer-events: none;
  z-index: 1;
}

/* ── Custom Scrollbar ── */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #FFFBF0;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #D9A0EC, #F5C240);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #C773E0, #D4880A);
}

/* ── Selection ── */
::selection {
  background: #E9C4F5;
  color: #3D1247;
}

/* ── Focus Visible ── */
:focus-visible {
  outline: 2px solid #F5A623;
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Image Hover Container ── */
.group:hover .group-hover\\:scale-105 {
  transform: scale(1.05);
}

/* ── Utility ── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
