:root {
  --color-primary: #2C1810;
  --color-secondary: #4A2C20;
  --color-accent: #DC2626;
}

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

body { 
  font-family: 'Source Sans 3', 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(32px);
  transition: all 0.7s ease-out;
}

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

/* Utility classes */
.rotate-180 { 
  transform: rotate(180deg); 
}

.aspect-square {
  aspect-ratio: 1 / 1;
}

.aspect-video {
  aspect-ratio: 16 / 9;
}

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

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

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

.decor-mesh::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 25% 25%, var(--color-accent), transparent 50%),
              radial-gradient(circle at 75% 75%, var(--color-primary), transparent 50%);
  opacity: 0.05;
  pointer-events: none;
}

.decor-gradient-blur::before,
.decor-gradient-blur::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  pointer-events: none;
}

.decor-gradient-blur::before {
  width: 300px;
  height: 300px;
  background: var(--color-accent);
  top: -150px;
  right: -150px;
  opacity: 0.1;
}

.decor-gradient-blur::after {
  width: 200px;
  height: 200px;
  background: var(--color-primary);
  bottom: -100px;
  left: -100px;
  opacity: 0.1;
}

.decor-corner-tr::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 100px;
  height: 100px;
  background: linear-gradient(-45deg, var(--color-accent), transparent);
  opacity: 0.1;
}

.decor-corner-bl::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100px;
  height: 100px;
  background: linear-gradient(45deg, var(--color-accent), transparent);
  opacity: 0.1;
}

.decor-glow-element {
  position: relative;
}

.decor-glow-element::before {
  content: '';
  position: absolute;
  inset: -20px;
  background: radial-gradient(circle, var(--color-accent), transparent 70%);
  opacity: 0.15;
  filter: blur(20px);
  z-index: -1;
}

.decor-rings-svg {
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Ccircle cx='30' cy='30' r='15' stroke='%23DC2626' stroke-opacity='0.05' stroke-width='2'/%3E%3Ccircle cx='30' cy='30' r='25' stroke='%232C1810' stroke-opacity='0.05' stroke-width='1'/%3E%3C/g%3E%3C/svg%3E");
}

/* Modifier classes */
.decor-subtle { opacity: 0.05; }
.decor-moderate { opacity: 0.1; }
.decor-bold { opacity: 0.2; }

/* Form styling */
input[type="text"],
input[type="tel"],
input[type="email"],
select,
textarea {
  transition: border-color 0.2s, box-shadow 0.2s;
}

input[type="text"]:focus,
input[type="tel"]:focus,
input[type="email"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

/* Error states */
.error-field {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.error-message {
  color: #ef4444;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* Loading state */
.loading {
  opacity: 0.7;
  pointer-events: none;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Header scroll effect */
.header-scrolled {
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

/* Order form styling */
#order_form {
  scroll-margin-top: 6rem;
}

.order-summary {
  border: 2px solid var(--color-accent);
  background: linear-gradient(135deg, #FEF2F2 0%, #FEE2E2 100%);
}

.price-badge {
  background: linear-gradient(135deg, var(--color-accent), #b91c1c);
  color: white;
}

/* Testimonial styling */
.testimonial-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

/* Responsive utilities */
@media (max-width: 640px) {
  .text-responsive {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
  }
  
  .container-mobile {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}