@tailwind base;
@tailwind components;
@tailwind utilities;

:root {
  --color-emerald: #10b981;
}

body {
  font-family: 'Outfit', sans-serif;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: rgba(9, 9, 11, 1);
}
::-webkit-scrollbar-thumb {
  background: rgba(16, 185, 129, 0.3);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(16, 185, 129, 0.6);
}

/* Base styles for GSAP reveal elements to prevent unstyled flash */
.opacity-0-initial { opacity: 0; }
.service-card, .reveal-up, .reveal-fade, .reveal-zoom {
  /* Using GSAP's native handling instead of hard visibility hidden which can cause bugs */
}

/* Glass & Glow */
.glass-panel {
  background: rgba(24, 24, 27, 0.4);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-form {
  background: rgba(9, 9, 11, 0.7);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.emerald-glow {
  box-shadow: 0 0 40px -10px rgba(16, 185, 129, 0.4);
}

.emerald-glow-strong {
  box-shadow: 0 0 60px -10px rgba(16, 185, 129, 0.6);
}

.neon-blue-glow {
  box-shadow: 0 0 40px -10px rgba(59, 130, 246, 0.4);
}

.neon-blue-glow-strong {
  box-shadow: 0 0 60px -10px rgba(59, 130, 246, 0.6);
}

.neon-gold-glow {
  box-shadow: 0 0 40px -10px rgba(250, 204, 21, 0.4);
}

/* Pulse animation for urgency / dots */
@keyframes soft-pulse {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.animate-soft-pulse {
  animation: soft-pulse 2s infinite;
}

/* Magnetic Button helper */
.magnetic-btn {
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  will-change: transform;
}

/* Form Styles */   
input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
}

.gradient-text {
  background: linear-gradient(135deg, #34d399, #10b981);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-text-blue {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Premium Form Inputs with Floating Labels */
.premium-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 1rem 1.25rem;
  border-radius: 1rem;
  outline: none;
  transition: all 0.3s ease;
  font-family: inherit;
}

.premium-input:focus {
  border-color: rgba(16, 185, 129, 0.5);
  background: rgba(16, 185, 129, 0.05);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.1);
}

.floating-label {
  position: absolute;
  top: 1rem;
  left: 1.25rem;
  color: rgba(255, 255, 255, 0.4);
  pointer-events: none;
  transition: all 0.3s ease;
  transform-origin: left top;
}

.premium-input:focus ~ .floating-label,
.premium-input:not(:placeholder-shown) ~ .floating-label {
  transform: translateY(-0.8rem) scale(0.75);
  color: rgba(16, 185, 129, 0.8);
}

/* Buttons */
.premium-btn {
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 1;
}

.btn-sapphire-emerald {
  background: linear-gradient(135deg, #10b981, #3b82f6);
  color: #fff;
  box-shadow: 0 10px 20px -10px rgba(16, 185, 129, 0.4);
}

.btn-sapphire-emerald:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 30px -10px rgba(59, 130, 246, 0.5);
}

.premium-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
  z-index: -1;
}

.premium-btn:hover::before {
  left: 100%;
}

.premium-btn:active {
  transform: scale(0.97);
}

/* Styling for tabs */
.eco-tab {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.eco-tab.active {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Tab Content Transitions */
.tab-content {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.tab-content.active {
  display: block;
  opacity: 1;
}
/* Mobile Swipe Helpers */
@media (max-width: 768px) {
  .mobile-swipe-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    -ms-overflow-style: none;
    scrollbar-width: none;
  }
  .mobile-swipe-grid::-webkit-scrollbar {
    display: none;
  }
  .mobile-swipe-grid > div {
    flex: 0 0 85%;
    scroll-snap-align: center;
  }
}

/* Float Animation */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
.animate-float {
  animation: float 4s ease-in-out infinite;
}
/* Custom Smart Cursor */
.cursor-dot,
.cursor-outline {
  pointer-events: none;
  position: fixed;
  top: 0;
  left: 0;
  border-radius: 50%;
  opacity: 0;
  z-index: 9999;
  transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
}

.cursor-dot {
  width: 8px;
  height: 8px;
  background-color: var(--color-emerald);
}

.cursor-outline {
  width: 40px;
  height: 40px;
  border: 2px solid rgba(16, 185, 129, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Cursor Active State (Hovering over interactive elements) */
.cursor-outline.active {
  transform: scale(1.5);
  background-color: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.8);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.3);
}

.cursor-dot.active {
  transform: scale(0.5);
}

/* Hide on Mobile */
@media (max-width: 1024px) {
  .cursor-dot, .cursor-outline {
    display: none;
  }
}
