:root {
  --color-primary: #3D2C2C;
  --color-secondary: #5A4040;
  --color-accent: #FFAB91;
  --color-bg-light: #FFF5F2;
  --color-bg-alt: #FFE8E0;
}

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

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

/* ============================================================
   HEADER SCROLL BEHAVIOR
   ============================================================ */
#site-header.scrolled {
  background-color: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid #f3e8e4;
  box-shadow: 0 2px 20px rgba(61, 44, 44, 0.08);
}

#site-header.scrolled .header-logo-text {
  color: var(--color-primary) !important;
}

#site-header.scrolled .header-nav-link {
  color: #6b7280 !important;
}

#site-header.scrolled .header-nav-link:hover {
  color: var(--color-primary) !important;
}

#site-header.scrolled .header-icon-mobile {
  color: var(--color-primary) !important;
}

/* ============================================================
   BUTTON & CTA BASE
   ============================================================ */
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%;
  display: flex;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
html.js-anim html.js-anim [data-animate] {
  opacity: 0;
  transform: translateX(-2rem);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

html.js-anim html.js-anim [data-animate].is-visible {
  opacity: 1;
  transform: translateX(0);
}

html.js-anim [data-animate][data-delay="100"] { transition-delay: 0.1s; }
html.js-anim [data-animate][data-delay="200"] { transition-delay: 0.2s; }
html.js-anim [data-animate][data-delay="300"] { transition-delay: 0.3s; }
html.js-anim [data-animate][data-delay="400"] { transition-delay: 0.4s; }
html.js-anim [data-animate][data-delay="500"] { transition-delay: 0.5s; }

/* ============================================================
   UTILITY
   ============================================================ */
.rotate-180 {
  transform: rotate(180deg);
}

/* ============================================================
   DECORATIVE ELEMENTS
   ============================================================ */
.decor-grid-dots {
  background-image: radial-gradient(circle, rgba(255, 171, 145, 0.3) 1px, transparent 1px);
  background-size: 24px 24px;
}

.decor-grid-lines {
  background-image:
    linear-gradient(rgba(255, 171, 145, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 171, 145, 0.1) 1px, transparent 1px);
  background-size: 40px 40px;
}

.decor-diagonal {
  background-image: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 10px,
    rgba(255, 171, 145, 0.05) 10px,
    rgba(255, 171, 145, 0.05) 20px
  );
}

.decor-mesh {
  background-image:
    radial-gradient(ellipse at 20% 50%, rgba(255, 171, 145, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(255, 232, 224, 0.2) 0%, transparent 50%);
}

.decor-gradient-blur::before {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(255, 171, 145, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(60px);
  top: -10%;
  right: -10%;
  pointer-events: none;
}

.decor-gradient-blur::after {
  content: '';
  position: absolute;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255, 232, 224, 0.4) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(40px);
  bottom: -5%;
  left: -5%;
  pointer-events: none;
}

.decor-corner-tr::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 200px;
  height: 200px;
  background: linear-gradient(135deg, rgba(255, 171, 145, 0.2) 0%, transparent 60%);
  pointer-events: none;
}

.decor-corner-bl::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200px;
  height: 200px;
  background: linear-gradient(315deg, rgba(255, 171, 145, 0.2) 0%, transparent 60%);
  pointer-events: none;
}

.decor-glow-element {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(255, 171, 145, 0.25) 0%, transparent 65%);
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.decor-subtle { opacity: 0.5; }
.decor-moderate { opacity: 1; }
.decor-bold { opacity: 1.5; filter: brightness(1.2); }

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero-gradient {
  background: linear-gradient(135deg, #3D2C2C 0%, #5A4040 40%, #7a5c5c 100%);
}

/* ============================================================
   STAR RATING
   ============================================================ */
.star-rating {
  color: #FFAB91;
}

/* ============================================================
   ORDER FORM
   ============================================================ */
.order-form-card {
  background: white;
  border-radius: 1.5rem;
  box-shadow: 0 4px 24px rgba(61, 44, 44, 0.12);
}

/* ============================================================
   INGREDIENT CARD
   ============================================================ */
.ingredient-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ingredient-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(61, 44, 44, 0.12);
}

/* ============================================================
   TESTIMONIAL
   ============================================================ */
.testimonial-card {
  transition: transform 0.2s ease;
}

.testimonial-card:hover {
  transform: translateY(-2px);
}

/* ============================================================
   FAQ ACCORDION
   ============================================================ */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease-out, padding 0.2s ease;
}

.faq-answer.open {
  max-height: 500px;
}

/* ============================================================
   FORM INPUTS
   ============================================================ */
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid #f3e8e4;
  border-radius: 9999px;
  font-size: 0.875rem;
  outline: none;
  transition: border-color 0.2s ease;
  background-color: #fff;
  color: #3D2C2C;
}

.form-input:focus {
  border-color: #FFAB91;
  box-shadow: 0 0 0 3px rgba(255, 171, 145, 0.15);
}

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

.form-error-msg {
  display: none;
  color: #ef4444;
  font-size: 0.75rem;
  margin-top: 0.25rem;
  padding-left: 1rem;
}

.form-error-msg.show {
  display: block;
}

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar {
  width: 6px;
}

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

::-webkit-scrollbar-thumb {
  background: #FFAB91;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #5A4040;
}

/* ============================================================
   MOBILE MENU TRANSITION
   ============================================================ */
#mobile-menu {
  transition: opacity 0.2s ease;
}

#mobile-menu.open {
  display: block;
}

/* ============================================================
   SECTION BACKGROUNDS
   ============================================================ */
.bg-brand-light { background-color: #FFF5F2; }
.bg-brand-alt   { background-color: #FFE8E0; }
.bg-brand-primary { background-color: #3D2C2C; }
.bg-brand-secondary { background-color: #5A4040; }

/* ============================================================
   BADGE
   ============================================================ */
.badge-accent {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  background-color: rgba(255, 171, 145, 0.15);
  color: #3D2C2C;
  border: 1px solid rgba(255, 171, 145, 0.4);
  border-radius: 9999px;
  padding: 0.25rem 0.875rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ============================================================
   PROGRESS / LOADING
   ============================================================ */
.btn-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.8;
}

.btn-loading::after {
  content: '';
  position: absolute;
  width: 1rem;
  height: 1rem;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

@keyframes spin {
  to { transform: translateY(-50%) rotate(360deg); }
}

/* ============================================================
   SELECTION
   ============================================================ */
::selection {
  background-color: rgba(255, 171, 145, 0.3);
  color: #3D2C2C;
}