/* app/globals.css */

@import "tailwindcss";

:root {
  --primary: #FF7A00;
  --primary-dark: #E06A00;
  --primary-light: #FFB366;
  --secondary: #2E7D32;
  --secondary-dark: #1B5E20;
  --secondary-light: #4CAF50;
  --dark: #1e2a2e;
  --dark-bg: #0a1922;
  --gray: #64748b;
  --light-gray: #f5f5f5;
  --white: #ffffff;
}

/* Custom utilities for colors */
@utility bg-primary {
  background-color: var(--primary);
}

@utility text-primary {
  color: var(--primary);
}

@utility border-primary {
  border-color: var(--primary);
}

@utility bg-secondary {
  background-color: var(--secondary);
}

@utility text-secondary {
  color: var(--secondary);
}

@utility border-secondary {
  border-color: var(--secondary);
}

@utility text-gray-custom {
  color: var(--gray);
}

/* Gradient utilities */
@utility bg-gradient-primary {
  background-image: linear-gradient(135deg, var(--primary), var(--secondary));
}

@utility text-gradient-primary {
  background-image: linear-gradient(135deg, var(--primary), var(--secondary));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

@utility text-gray-custom {
  color: var(--gray);
}

@utility bg-gray-custom {
  background-color: var(--light-gray);
}

@utility bg-dark-bg {
  background-color: var(--dark-bg);
}

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

@keyframes slide-left {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slide-right {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse-slow {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* fill-mode `both` (not just `forwards`): during an animation-delay the element
   sits in its `from` state instead of showing at full opacity and then jumping
   back to opacity 0 when the animation starts (a visible flicker that also
   delays LCP). */
.animate-fade-up {
  animation: fade-up 0.6s ease both;
}

.animate-slide-left {
  animation: slide-left 0.6s ease both;
}

.animate-slide-right {
  animation: slide-right 0.6s ease both;
}

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

/* Animation Delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

/* RTL Support */
.rtl {
  direction: rtl;
}

.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

/* Hide scrollbar for IE, Edge and Firefox */
.scrollbar-hide {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

/* Custom range slider styling */
input[type="range"] {
  -webkit-appearance: none;
  background: transparent;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
/* Tab panel entrance — CSS replacement for a framer-motion fade so simple
   tab switches don't pull the animation runtime into the page bundle. */
@keyframes tab-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-tab-in {
  animation: tab-in 0.2s ease-out both;
}

@media (prefers-reduced-motion: reduce) {
  .animate-tab-in {
    animation: none;
  }
}

/* FAQ accordions — produced by lib/cms/faqify.ts from an FAQ-shaped CMS page
   (native <details>, so they work without JS and are keyboard accessible). */
.faq-item {
  border-bottom: 1px solid #f3f4f6;
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 0;
  font-weight: 500;
  color: var(--color-dark, #111827);
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: '';
  flex-shrink: 0;
  width: 0.55rem;
  height: 0.55rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  transform: rotate(-135deg);
}

.faq-item summary:hover {
  color: var(--primary, #ff7a00);
}

.faq-item .faq-answer {
  padding-bottom: 1rem;
  color: #6b7280;
  font-size: 0.925rem;
  line-height: 1.7;
}

.faq-item .faq-answer p {
  margin: 0 0 0.5rem;
}
