:root {
  --color-primary: #4A4035;
  --color-secondary: #6A5A4A;
  --color-accent: #F5E6D3;
  --bg-light: #FFFDFB;
  --bg-alt: #FDF8F3;
}

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

body {
  font-family: 'Source Sans 3', system-ui, sans-serif;
  background-color: var(--bg-light);
}

/* 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;
  transition: all 0.2s ease;
}

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

/* Animations */
[data-animate] {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

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

.fade-in {
  animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

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

.transition-transform {
  transition: transform 0.3s ease;
}

/* Custom background decorations */
.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, transparent, transparent 10px, currentColor 10px, currentColor 11px);
}

.decor-subtle {
  opacity: 0.05;
}

.decor-moderate {
  opacity: 0.1;
}

.decor-bold {
  opacity: 0.2;
}

/* Form styling */
.form-input {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(74, 64, 53, 0.1);
}

.form-error {
  border-color: #ef4444;
}

.form-error:focus {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

/* Rating stars */
.stars {
  display: flex;
  gap: 2px;
}

.star {
  color: #fbbf24;
}

/* Product badge styles */
.badge-bestseller {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
}

.badge-new {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
}

.badge-popular {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  color: white;
}

/* Loading states */
.loading {
  position: relative;
  pointer-events: none;
  opacity: 0.7;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid transparent;
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

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

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

/* Price formatting */
.price-old {
  text-decoration: line-through;
  color: #9ca3af;
}

.price-current {
  font-weight: 600;
  color: var(--color-primary);
}

/* Trust indicators */
.trust-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem;
  background: rgba(245, 230, 211, 0.3);
  border-radius: 0.5rem;
  font-size: 0.875rem;
  color: var(--color-primary);
}

/* Responsive utilities */
@media (max-width: 640px) {
  .container-mobile {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}