/* ============================================================
   MAIN.CSS - Variables, reset, typography, utilities, buttons
   ============================================================ */

/* === DESIGN TOKENS === */
:root {
  --color-bg: #f7f2ea;
  --color-bg-section: #ece3d4;
  --color-bg-dark: #14110f;
  --color-bg-dark-soft: #1f1a16;
  --color-primary: #231d18;
  --color-primary-light: #3d342c;
  --color-accent: #b48a4a;
  --color-accent-dark: #8a6428;
  --color-accent-light: #d9b97c;
  --color-sage: #7d8f7a;
  --color-plum: #6e2f4f;
  --color-text: #2d2722;
  --color-text-muted: #6f6459;
  --color-white: #fff;
  --color-cream: #f5f0e8;
  --color-border: #ded3c0;
  --color-overlay: rgb(20 17 15 / 80%);
  --font-heading: 'Cormorant Garamond', georgia, serif;
  --font-body: 'Jost', system-ui, -apple-system, sans-serif;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 2rem;
  --text-4xl: 2.5rem;
  --text-5xl: 3.25rem;
  --text-6xl: 4.25rem;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --container-max: 1200px;
  --container-padding: clamp(1rem, 4vw, 2rem);
  --radius-sm: 4px;
  --radius-md: 10px;
  --radius-lg: 18px;
  --radius-full: 9999px;
  --shadow-sm: 0 1px 3px rgb(35 29 24 / 8%);
  --shadow-md: 0 6px 18px rgb(35 29 24 / 10%);
  --shadow-lg: 0 16px 40px rgb(35 29 24 / 16%);
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 600ms ease;
  --nav-height: 76px;
}

/* === RESET === */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.65;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

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

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

ul,
ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

/* === TYPOGRAPHY === */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.1;
  color: var(--color-primary);
}

h1 {
  font-size: clamp(var(--text-4xl), 6.5vw, var(--text-6xl));
}

h2 {
  font-size: clamp(var(--text-3xl), 4.5vw, var(--text-5xl));
}

h3 {
  font-size: clamp(var(--text-xl), 2.5vw, var(--text-2xl));
}

p {
  line-height: 1.75;
  color: var(--color-text);
}

/* === LAYOUT === */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}

.section {
  padding-block: var(--space-24);
}

.section--alt {
  background-color: var(--color-bg-section);
}

.section--dark {
  background-color: var(--color-bg-dark);
  color: var(--color-cream);
}

.section--dark h1,
.section--dark h2,
.section--dark h3 {
  color: var(--color-cream);
}

.section--dark p {
  color: rgb(245 240 232 / 82%);
}

/* === SECTION HEADER === */
.section-header {
  margin-bottom: var(--space-12);
}

.section-header--center {
  max-width: 640px;
  margin-inline: auto;
  text-align: center;
}

.section-label {
  display: inline-block;
  margin-bottom: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--color-accent-dark);
}

.section-subtitle {
  margin-top: var(--space-2);
  font-size: var(--text-lg);
  color: var(--color-text-muted);
}

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn--primary {
  background-color: var(--color-accent);
  color: var(--color-bg-dark);
  border-color: var(--color-accent);
}

.btn--primary:hover {
  background-color: var(--color-accent-light);
  border-color: var(--color-accent-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

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

.btn--outline-light {
  background-color: transparent;
  color: var(--color-cream);
  border-color: rgb(245 240 232 / 55%);
}

.btn--outline-light:hover {
  background-color: var(--color-cream);
  color: var(--color-bg-dark);
  border-color: var(--color-cream);
  transform: translateY(-2px);
}

.btn--lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--text-sm);
}

.btn--whatsapp {
  background-color: #25d366;
  color: var(--color-bg-dark);
  border-color: #25d366;
}

.btn--whatsapp:hover {
  background-color: #20bc5a;
  border-color: #20bc5a;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* === WHATSAPP FLOATING BUTTON === */
.whatsapp-float {
  position: fixed;
  right: var(--space-6);
  bottom: var(--space-6);
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  background-color: #25d366;
  color: var(--color-white);
  box-shadow: 0 4px 16px rgb(37 211 102 / 45%);
  transition: all var(--transition-base);
}

.whatsapp-float:hover {
  background-color: #20bc5a;
  transform: scale(1.08);
  box-shadow: 0 6px 20px rgb(37 211 102 / 55%);
}

.whatsapp-float svg {
  width: 28px;
  height: 28px;
  fill: var(--color-white);
}

/* === DIVIDER === */
.divider {
  width: 56px;
  height: 2px;
  margin-block: var(--space-5);
  background-color: var(--color-accent);
}

.divider--center {
  margin-inline: auto;
}

/* === SCROLL REVEAL === */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(28px);
    transition:
      opacity var(--transition-slow),
      transform var(--transition-slow);
  }

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

/* === UTILITIES === */
.text-accent {
  color: var(--color-accent-light);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* === RESPONSIVE === */
@media (width <= 768px) {
  :root {
    --nav-height: 64px;
  }

  .section {
    padding-block: var(--space-16);
  }

  .section-header {
    margin-bottom: var(--space-8);
  }
}
