/*
 * Renkar — World-class Marketing Styles
 */

/* ===== Scroll-triggered animations ===== */
[data-animate] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
[data-animate-stagger] > [data-animate]:nth-child(1) { transition-delay: 0ms; }
[data-animate-stagger] > [data-animate]:nth-child(2) { transition-delay: 80ms; }
[data-animate-stagger] > [data-animate]:nth-child(3) { transition-delay: 160ms; }
[data-animate-stagger] > [data-animate]:nth-child(4) { transition-delay: 240ms; }
[data-animate-stagger] > [data-animate]:nth-child(5) { transition-delay: 320ms; }
[data-animate-stagger] > [data-animate]:nth-child(6) { transition-delay: 400ms; }

/* Scale-up variant */
[data-animate="scale"] {
  opacity: 0;
  transform: scale(0.92);
}
[data-animate="scale"].is-visible {
  opacity: 1;
  transform: scale(1);
}

/* Slide-in-left */
[data-animate="slide-left"] {
  opacity: 0;
  transform: translateX(-40px);
}
[data-animate="slide-left"].is-visible {
  opacity: 1;
  transform: translateX(0);
}

/* Slide-in-right */
[data-animate="slide-right"] {
  opacity: 0;
  transform: translateX(40px);
}
[data-animate="slide-right"].is-visible {
  opacity: 1;
  transform: translateX(0);
}

/* Fade only */
[data-animate="fade"] {
  opacity: 0;
  transform: none;
}
[data-animate="fade"].is-visible {
  opacity: 1;
}

/* ===== Fade-in animation (popups) ===== */
@keyframes fade-in {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
.animate-fade-in {
  animation: fade-in 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* ===== Floating animation (hero mockup) ===== */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}
.animate-float {
  animation: float 6s ease-in-out infinite;
}

/* ===== Gradient text ===== */
.text-gradient {
  background: linear-gradient(135deg, #006a6a 0%, #004f4f 50%, #006a6a 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===== Animated gradient background ===== */
@keyframes gradient-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.animate-gradient {
  background-size: 200% 200%;
  animation: gradient-shift 8s ease infinite;
}

/* ===== Pulse glow effect ===== */
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(0, 106, 106, 0.15); }
  50% { box-shadow: 0 0 40px rgba(0, 106, 106, 0.3); }
}
.animate-pulse-glow {
  animation: pulse-glow 3s ease-in-out infinite;
}

/* ===== Grid pattern background ===== */
.bg-grid {
  background-image:
    linear-gradient(rgba(0, 106, 106, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 106, 106, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
}

/* ===== Dot pattern ===== */
.bg-dots {
  background-image: radial-gradient(circle, rgba(0, 106, 106, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* ===== Navbar scroll state ===== */
.navbar-marketing {
  transition: background-color 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
}
.navbar-marketing.is-scrolled {
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: rgba(229, 231, 235, 0.6);
}

/* ===== Smooth scroll (scoped to marketing pages only) ===== */
.marketing-page {
  scroll-behavior: smooth;
}

/* ===== Feature card hover glow ===== */
.feature-card {
  position: relative;
  overflow: hidden;
}
.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--card-accent, #3b82f6), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.feature-card:hover::before {
  opacity: 1;
}

/* ===== Feature card color variants (static classes for Tailwind JIT) ===== */
.feature-card-blue { --card-accent: #006a6a; }
.feature-card-emerald { --card-accent: #10b981; }
.feature-card-violet { --card-accent: #8b5cf6; }
.feature-card-amber { --card-accent: #f59e0b; }
.feature-card-rose { --card-accent: #f43f5e; }
.feature-card-teal { --card-accent: #14b8a6; }

/* ===== Pricing card popular highlight ===== */
.pricing-popular {
  position: relative;
}
.pricing-popular::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #006a6a, #004f4f, #006a6a);
  background-size: 200% 200%;
  animation: gradient-shift 4s ease infinite;
  z-index: -1;
}

/* ===== FAQ toggle ===== */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.faq-answer.is-open {
  max-height: 500px;
}

/* ===== Testimonial card ===== */
.testimonial-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.9) 0%, rgba(249,250,251,0.9) 100%);
}

/* ===== Mobile menu ===== */
.mobile-menu-overlay {
  transition: opacity 0.3s ease;
}
.mobile-menu-panel {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===== Auth page animations ===== */
@keyframes auth-fade-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes auth-scale-in {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
@keyframes auth-shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes auth-glow-pulse {
  0%, 100% {
    opacity: 0.4;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.05);
  }
}
.auth-animate-header {
  animation: auth-fade-up 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.auth-animate-card {
  animation: auth-scale-in 0.5s cubic-bezier(0.16, 1, 0.3, 1) 0.15s both;
}
.auth-animate-footer {
  animation: auth-fade-up 0.5s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both;
}
.auth-glow {
  animation: auth-glow-pulse 4s ease-in-out infinite;
}
.auth-btn-shimmer {
  position: relative;
  overflow: hidden;
}
.auth-btn-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.15) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: auth-shimmer 3s ease-in-out infinite;
  pointer-events: none;
}

/* Auth input focus ring */
.auth-input {
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}
.auth-input:focus {
  border-color: #006a6a;
  box-shadow: 0 0 0 3px rgba(0, 106, 106, 0.1), 0 1px 2px rgba(0, 0, 0, 0.05);
  background-color: #fff;
}

/* OAuth button hover lift */
.auth-oauth-btn {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.auth-oauth-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}
.auth-oauth-btn:active {
  transform: translateY(0);
}

/* ===== Booking flow — Step transitions ===== */
.step-exit {
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}
.step-exit-reverse {
  opacity: 0;
  transform: translateX(20px);
  transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}
.step-enter {
  opacity: 0;
  transform: translateX(20px);
}
.step-enter-reverse {
  opacity: 0;
  transform: translateX(-20px);
}
.step-enter-active,
.step-enter-reverse-active {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===== Booking flow — Progress indicator ===== */
.progress-line-fill {
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.progress-line-fill.is-filled {
  transform: scaleX(1);
}
.progress-circle {
  transition: background-color 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

/* ===== Booking flow — Calendar ===== */
@keyframes calendar-date-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}
.calendar-date-pop {
  animation: calendar-date-pop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.calendar-grid-fade {
  transition: opacity 0.12s ease-out;
}

/* ===== Booking flow — Slot buttons ===== */
@keyframes slot-fade-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.slot-enter {
  animation: slot-fade-in 0.25s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.slot-btn {
  transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}
.slot-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}
.slot-btn:active {
  transform: translateY(0);
}
.slot-check {
  opacity: 0;
  transform: scale(0.5);
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.slot-btn.is-selected .slot-check {
  opacity: 1;
  transform: scale(1);
}

/* ===== Booking flow — Form inputs ===== */
.booking-input {
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}
.booking-input:focus {
  border-color: #006a6a;
  box-shadow: 0 0 0 3px rgba(0, 106, 106, 0.1), 0 1px 2px rgba(0, 0, 0, 0.05);
  background-color: #fff;
}

/* ===== Booking flow — Skeleton shimmer ===== */
.skeleton-shimmer {
  background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
  background-size: 200% 100%;
  animation: auth-shimmer 1.5s ease-in-out infinite;
}

/* ===== Profile — Event cards ===== */
.event-card {
  position: relative;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.event-card:hover {
  transform: translateY(-2px);
}
.event-card .event-card-arrow {
  transition: transform 0.2s ease;
}
.event-card:hover .event-card-arrow {
  transform: translateX(3px);
}

/* ===== Confirmation — Celebration ===== */
@keyframes confetti-burst {
  0% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); }
  100% { opacity: 0; transform: translate(var(--confetti-x), var(--confetti-y)) rotate(var(--confetti-r)) scale(0); }
}
.confetti-container { position: relative; }
.confetti-container::before,
.confetti-container::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 8px; height: 8px;
  border-radius: 2px;
  pointer-events: none;
  animation: confetti-burst 1.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.confetti-container::before {
  --confetti-x: -60px; --confetti-y: -80px; --confetti-r: 360deg;
  background: #006a6a;
  box-shadow:
    40px 0 0 #004f4f,
    80px -20px 0 #93f2f2,
    -30px -40px 0 #191c1e;
}
.confetti-container::after {
  --confetti-x: 70px; --confetti-y: -60px; --confetti-r: -270deg;
  background: #f43f5e;
  box-shadow:
    -50px 10px 0 #06b6d4,
    30px -30px 0 #f59e0b;
  animation-delay: 0.1s;
}

@keyframes check-draw {
  from { stroke-dashoffset: 24; }
  to { stroke-dashoffset: 0; }
}
.check-draw {
  stroke-dasharray: 24;
  stroke-dashoffset: 24;
  animation: check-draw 0.4s ease-out 0.3s both;
}

@keyframes status-icon-in {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
.status-icon-in {
  animation: status-icon-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

/* ===== Reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
  [data-animate] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .animate-float {
    animation: none !important;
  }
  .animate-gradient {
    animation: none !important;
  }
  .animate-pulse-glow {
    animation: none !important;
  }
  .animate-pulse {
    animation: none !important;
  }
  .animate-bounce {
    animation: none !important;
  }
  .pricing-popular::before {
    animation: none !important;
  }
  .faq-answer {
    transition: none !important;
  }
  .mobile-menu-panel {
    transition: none !important;
  }
  .mobile-menu-overlay {
    transition: none !important;
  }
  .marketing-page {
    scroll-behavior: auto;
  }
  .auth-animate-header,
  .auth-animate-card,
  .auth-animate-footer {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  .auth-glow {
    animation: none !important;
  }
  .auth-btn-shimmer::after {
    animation: none !important;
  }
  /* Booking flow */
  .step-exit, .step-exit-reverse,
  .step-enter, .step-enter-reverse,
  .step-enter-active, .step-enter-reverse-active {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .progress-line-fill {
    transition: none !important;
    transform: scaleX(1) !important;
  }
  .progress-circle {
    transition: none !important;
  }
  .calendar-date-pop {
    animation: none !important;
  }
  .calendar-grid-fade {
    transition: none !important;
  }
  .slot-enter {
    animation: none !important;
    opacity: 1 !important;
  }
  .slot-btn {
    transition: none !important;
  }
  .slot-check {
    transition: none !important;
  }
  .skeleton-shimmer {
    animation: none !important;
  }
  .event-card {
    transition: none !important;
  }
  .event-card .event-card-arrow {
    transition: none !important;
  }
  .confetti-container::before,
  .confetti-container::after {
    animation: none !important;
    opacity: 0 !important;
  }
  .check-draw {
    animation: none !important;
    stroke-dashoffset: 0 !important;
  }
  .status-icon-in {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
