/* ============================================
   Cafe Ganadara — Custom Styles
   ============================================ */

/* ---- Animations ---- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ---- Hero Animations ---- */
.hero-eyebrow {
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-headline {
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero-sub {
  animation: fadeInUp 0.8s ease-out 0.6s both;
}

.hero-ctas {
  animation: fadeInUp 0.8s ease-out 0.8s both;
}

/* ---- Scroll Reveal ---- */
.reveal-up,
.reveal-left,
.reveal-right {
  opacity: 0;
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.reveal-up {
  transform: translateY(30px);
}

.reveal-left {
  transform: translateX(-30px);
}

.reveal-right {
  transform: translateX(30px);
}

.reveal-up.is-visible,
.reveal-left.is-visible,
.reveal-right.is-visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* ---- Menu Cards ---- */
.menu-card {
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.menu-card:hover {
  transform: translateY(-4px);
}

/* ---- Navigation ---- */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #2dd4bf;
  transition: width 0.3s ease;
}

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

/* ---- Header Scroll State ---- */
#header.scrolled {
  background: rgba(2, 6, 23, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

#header.scrolled .nav-link {
  color: rgba(255, 255, 255, 0.85);
}

/* ---- Mobile Menu ---- */
#mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

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

/* ---- Selection ---- */
::selection {
  background: #0d9488;
  color: white;
}

/* ---- Focus Styles ---- */
:focus-visible {
  outline: 2px solid #14b8a6;
  outline-offset: 2px;
}

/* ---- Button Ripple ---- */
button, a {
  -webkit-tap-highlight-color: transparent;
}

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

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

::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* ---- Back to Top ---- */
#back-to-top.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .hero-headline {
    font-size: 2.5rem;
  }

  .hero-headline br {
    display: none;
  }

  .hero-headline::after {
    content: '.';
  }

  .font-serif.text-4xl,
  .font-serif.text-5xl {
    font-size: 2rem;
  }
}

/* ---- Reduced Motion ---- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  .reveal-up,
  .reveal-left,
  .reveal-right {
    opacity: 1;
    transform: none;
  }
}
