/* ============================================
   MENDIEN ARTEAN — Design System
   ============================================ */

/* Google Fonts — cargadas como <link> en el HTML con preconnect para mejor rendimiento */

/* ---- CSS Variables ---- */
:root {
  /* Earthy, nature-inspired palette */
  --color-primary: #2D5016;
  /* Deep forest green */
  --color-primary-light: #4A7C28;
  /* Lighter green */
  --color-primary-dark: #1A3009;
  /* Darkest green */
  --color-accent: #C8956C;
  /* Warm terracotta */
  --color-accent-light: #E8C4A0;
  /* Light sand */
  --color-accent-dark: #A67443;
  /* Dark terracotta */

  --color-bg: #FAFAF5;
  /* Warm off-white */
  --color-bg-alt: #F0EDE5;
  /* Sand background */
  --color-bg-dark: #1B1B16;
  /* Dark sections */

  --color-text: #2C2C27;
  /* Near-black warm */
  --color-text-light: #6B6B60;
  /* Muted text */
  --color-text-inverse: #F5F5F0;
  /* Light text for dark bg */

  --color-white: #FFFFFF;
  --color-border: #D4D0C8;
  --color-overlay: rgba(27, 27, 22, 0.6);
  --color-overlay-dark: rgba(159, 159, 92, 0.85);

  /* Typography */
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Font Sizes */
  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.125rem;
  --fs-lg: 1.25rem;
  --fs-xl: 1.5rem;
  --fs-2xl: 2rem;
  --fs-3xl: 2.5rem;
  --fs-4xl: 3.5rem;
  --fs-5xl: 4.5rem;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
  --shadow-xl: 0 16px 50px rgba(0, 0, 0, 0.15);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 500ms ease;
  --transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.7;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  font-family: var(--font-body);
  border: none;
  background: none;
}

ul,
ol {
  list-style: none;
}

/* ---- Typography ---- */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  font-weight: 600;
}

h1 {
  font-size: var(--fs-4xl);
}

h2 {
  font-size: var(--fs-3xl);
}

h3 {
  font-size: var(--fs-2xl);
}

h4 {
  font-size: var(--fs-xl);
}

p {
  margin-bottom: var(--space-md);
  line-height: 1.8;
}

/* ---- Utility Classes ---- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.section {
  padding: var(--space-5xl) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.section-header h2 {
  color: var(--color-primary);
  margin-bottom: var(--space-md);
  position: relative;
  display: inline-block;
}

.section-header h2::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--color-accent);
  border-radius: var(--radius-full);
}

.section-header p {
  color: var(--color-text-light);
  font-size: var(--fs-md);
  max-width: 600px;
  margin: var(--space-lg) auto 0;
}

/* ---- Button Styles ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-size: var(--fs-base);
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 4px 15px rgba(45, 80, 22, 0.3);
}

.btn-primary:hover {
  background: var(--color-primary-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(45, 80, 22, 0.4);
}

.btn-secondary {
  background: transparent;
  color: var(--color-white);
  border: 2px solid var(--color-white);
}

.btn-secondary:hover {
  background: var(--color-white);
  color: var(--color-primary);
  transform: translateY(-2px);
}

.btn-accent {
  background: var(--color-accent);
  color: var(--color-white);
  box-shadow: 0 4px 15px rgba(200, 149, 108, 0.3);
}

.btn-accent:hover {
  background: var(--color-accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(200, 149, 108, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
}

.btn-lg {
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--fs-md);
}

/* ---- Scroll Animations ---- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Stagger children */
.stagger-children .reveal:nth-child(1) {
  transition-delay: 0.1s;
}

.stagger-children .reveal:nth-child(2) {
  transition-delay: 0.2s;
}

.stagger-children .reveal:nth-child(3) {
  transition-delay: 0.3s;
}

.stagger-children .reveal:nth-child(4) {
  transition-delay: 0.4s;
}

.stagger-children .reveal:nth-child(5) {
  transition-delay: 0.5s;
}

.stagger-children .reveal:nth-child(6) {
  transition-delay: 0.6s;
}
