:root {
  --color-primary: #2E2440;
  --color-secondary: #453660;
  --color-accent: #A78BFA;
  --bg-light: #FAF5FF;
  --bg-alt: #F3E8FF;
}

html { 
  scroll-behavior: smooth; 
  scroll-padding-top: 5rem; 
}

body { 
  font-family: 'DM Sans', system-ui, sans-serif; 
}

/* Button fixes */
button, .btn, [class*="btn-"], a[href="#order_form"] {
  white-space: nowrap;
  min-width: fit-content;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

form button[type="submit"] {
  white-space: normal;
  width: 100%;
}

/* Animations */
[data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-up.animate {
  opacity: 1;
  transform: translateY(0);
}

.rotate-180 { 
  transform: rotate(180deg); 
}

/* Decorative patterns */
.decor-grid-dots {
  background-image: radial-gradient(circle, currentColor 1px, transparent 1px);
  background-size: 20px 20px;
}

.decor-grid-lines {
  background-image: linear-gradient(currentColor 1px, transparent 1px), 
                    linear-gradient(90deg, currentColor 1px, transparent 1px);
  background-size: 20px 20px;
}

.decor-diagonal {
  background-image: repeating-linear-gradient(
    45deg,
    currentColor 0px,
    currentColor 1px,
    transparent 1px,
    transparent 20px
  );
}

.decor-subtle { opacity: 0.05; }
.decor-moderate { opacity: 0.1; }
.decor-bold { opacity: 0.2; }

.decor-gradient-blur::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, var(--color-accent), var(--color-primary));
  opacity: 0.1;
  filter: blur(60px);
  border-radius: 50%;
  transform: scale(1.5);
}

/* Custom backgrounds */
.bg-gradient-primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
}

.bg-gradient-accent {
  background: linear-gradient(135deg, var(--color-accent), var(--color-primary));
}

/* Form styling */
.form-input {
  @apply w-full px-4 py-3 border border-gray-300 rounded-xl focus:outline-none focus:ring-2 focus:ring-accent focus:border-transparent transition-all;
}

.form-checkbox {
  @apply rounded border-gray-300 text-accent focus:ring-accent focus:ring-2;
}

/* Rating stars */
.rating-stars {
  color: #FCD34D;
}

/* Product badges */
.product-badge {
  @apply inline-flex items-center gap-1 px-2 py-1 text-xs font-medium rounded-full;
}

.badge-new { @apply bg-green-100 text-green-700; }
.badge-bestseller { @apply bg-orange-100 text-orange-700; }
.badge-popular { @apply bg-blue-100 text-blue-700; }

/* Testimonial quotes */
.testimonial-quote::before {
  content: '"';
  font-size: 4rem;
  line-height: 1;
  opacity: 0.2;
  position: absolute;
  top: -0.5rem;
  left: -0.5rem;
}

.testimonial-quote::after {
  content: '"';
  font-size: 4rem;
  line-height: 1;
  opacity: 0.2;
  position: absolute;
  bottom: -2rem;
  right: -0.5rem;
}

/* Loading states */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

.spinner {
  border: 2px solid #f3f3f3;
  border-top: 2px solid var(--color-accent);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Mobile menu animation */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

#mobile-menu.show {
  max-height: 500px;
}

/* Smooth hover effects */
.hover-lift {
  transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}

.hover-lift:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

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

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

::-webkit-scrollbar-thumb {
  background: var(--color-accent);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}