/* ============================================================================
   AYURRARTH - Professional CSS Architecture
   ============================================================================
   
   STRUCTURE:
   1. CSS Variables & Tokens
   2. Reset & Base Styles
   3. Layouts & Grid System
   4. Components (BEM Methodology)
   5. Utilities
   6. Media Queries
   7. Accessibility & Animations

   BEM NAMING: .block__element--modifier
   Example: .button__text--active

============================================================================ */

/* ============================================================================
   1. VARIABLES & DESIGN TOKENS
   ============================================================================ */

:root {
  /* ─── Color Palette ─── */
  --color-primary: #b8941f;
  --color-primary-dark: #9a7528;
  --color-primary-light: #d4b15c;
  
  --color-neutral-950: #1a1612;
  --color-neutral-900: #2c241c;
  --color-neutral-800: #4a3d2e;
  --color-neutral-700: #7a5f20;
  --color-neutral-600: #5e574c;
  --color-neutral-100: #efe4d4;
  --color-neutral-50: #faf6ef;
  
  --color-bg: #fffefb;
  --color-text: #1c1915;
  --color-text-muted: #5e574c;
  
  /* ─── Typography ─── */
  --font-family-sans: 'Outfit', system-ui, -apple-system, sans-serif;
  --font-family-serif: 'Cormorant Garamond', Georgia, serif;
  
  --font-size-base: 1.05rem;
  --font-size-lg: 1.25rem;
  --font-size-xl: 1.5rem;
  --font-size-2xl: 2rem;
  --font-size-3xl: 3rem;
  
  --line-height-tight: 1.4;
  --line-height-normal: 1.65;
  --line-height-loose: 1.8;
  
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  
  /* ─── Spacing Scale ─── */
  --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;
  
  /* ─── Border & Radius ─── */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  
  /* ─── Shadows ─── */
  --shadow-sm: 0 4px 12px rgba(28, 22, 12, 0.08);
  --shadow-md: 0 12px 40px rgba(42, 35, 20, 0.09);
  --shadow-lg: 0 24px 60px rgba(28, 22, 12, 0.2);
  
  /* ─── Transitions & Animations ─── */
  --duration-fast: 0.15s;
  --duration-normal: 0.3s;
  --duration-slow: 0.5s;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  
  /* ─── Layout ─── */
  --header-height: 76px;
  --container-max-width: 1120px;
  --container-padding: 92vw;
}

/* ============================================================================
   2. RESET & BASE STYLES
   ============================================================================ */

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

html {
  scroll-behavior: smooth;
  -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-family-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  color: var(--color-text);
  background-color: var(--color-neutral-50);
  overflow-x: hidden;
}

/* ─── Images & Media ─── */
img,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

img {
  object-fit: cover;
}

/* ─── Links ─── */
a {
  color: var(--color-primary-dark);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--duration-fast) var(--ease-out);
}

a:visited {
  color: var(--color-neutral-700);
}

a:hover {
  color: var(--color-primary);
}

a:active {
  color: var(--color-neutral-900);
}

/* ─── Headings ─── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-serif);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-md);
}

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

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

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

/* ─── Lists ─── */
ul, ol {
  list-style-position: inside;
}

/* ============================================================================
   3. LAYOUTS & GRID SYSTEM
   ============================================================================ */

.container {
  width: min(var(--container-max-width), var(--container-padding));
  margin-inline: auto;
  padding-inline: var(--space-lg);
}

.wrap {
  width: min(var(--container-max-width), 92vw);
  margin-inline: auto;
}

.grid {
  display: grid;
  gap: var(--space-2xl);
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-2xl);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-2xl);
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
   4. COMPONENTS - BEM METHODOLOGY
   ============================================================================ */

/* ─── Button Component ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  font-family: inherit;
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-out);
  border: 2px solid transparent;
}

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

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

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

.btn--ghost:hover {
  background-color: var(--color-primary-light);
  color: var(--color-primary-dark);
}

.btn--ghost:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

.btn--sm {
  padding: var(--space-sm) var(--space-md);
  font-size: 0.9rem;
}

/* ─── Card Component ─── */
.card {
  background: var(--color-bg);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--duration-normal) var(--ease-out);
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.card__title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--space-md);
}

.card__body {
  color: var(--color-text-muted);
  line-height: var(--line-height-loose);
}

/* ─── Badge Component ─── */
.badge {
  display: inline-block;
  background-color: rgba(184, 148, 31, 0.12);
  color: var(--color-neutral-900);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 1px;
  border: 1px solid rgba(184, 148, 31, 0.22);
}

/* ============================================================================
   5. UTILITIES
   ============================================================================ */

/* Screen Reader Only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip Link */
.skip-link {
  position: absolute;
  left: var(--space-md);
  top: -100px;
  background: var(--color-neutral-900);
  color: var(--color-bg);
  padding: var(--space-md) 1.25rem;
  border-radius: var(--radius-sm);
  z-index: 1000;
  transition: top var(--duration-fast) var(--ease-out);
  text-decoration: none;
  font-weight: var(--font-weight-semibold);
}

.skip-link:focus {
  top: var(--space-md);
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Text Utilities */
.text-center {
  text-align: center;
}

.text-muted {
  color: var(--color-text-muted);
}

.text-primary {
  color: var(--color-primary);
}

..hero-title em,
.section-eyebrow,
.cinematic-eyebrow {
  color: var(--color-primary);
}

.footer-heading {
  color: var(--white);
}

/* ============================================================================
   6. RESPONSIVE & MEDIA QUERIES
   ============================================================================ */

@media (max-width: 1024px) {
  :root {
    --font-size-base: 1rem;
    --font-size-3xl: 2.5rem;
  }
}

@media (max-width: 768px) {
  :root {
    --font-size-base: 0.95rem;
    --font-size-3xl: 2rem;
    --space-3xl: 2.5rem;
    --space-4xl: 3rem;
  }

  h1 {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.5rem;
  }
}

/* ============================================================================
   7. ACCESSIBILITY & ANIMATIONS
   ============================================================================ */

/* Focus indicator for keyboard navigation */
*:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: more) {
  :root {
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.4);
  }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
  :root {
    --color-text: #f5f5f1;
    --color-text-muted: #b0a9a0;
    --color-bg: #1a1612;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

.animate-fade-in {
  animation: fadeIn var(--duration-normal) var(--ease-out);
}

.animate-slide-in-up {
  animation: slideInUp var(--duration-slow) var(--ease-out);
}
