/* ============================================
   MJ STUDIO DESIGN - DESIGN SYSTEM
   Modern Design Tokens & Variables with Dark Mode
   ============================================ */

:root {
  /* === THEME COLORS === */
  
  /* Base Color Palette (theme-independent) */
  --color-gold: #C9A86A;
  --color-gold-light: #E5D5B7;
  --color-gold-dark: #A08553;
  
  /* === LIGHT MODE (DEFAULT) === */
  --color-text-primary: #2B2B2B;
  --color-text-secondary: #6B6B6B;
  --color-text-muted: #9B9B9B;
  --color-text-inverse: #FFFFFF;
  
  --color-bg-primary: #FAF8F5;
  --color-bg-secondary: #EDE8E1;
  --color-bg-tertiary: #FFFFFF;
  --color-bg-elevated: #FFFFFF;
  
  --color-surface: #FFFFFF;
  --color-surface-hover: #F5F3F0;
  
  --color-border-light: rgba(43, 43, 43, 0.08);
  --color-border-medium: rgba(43, 43, 43, 0.12);
  --color-border-strong: rgba(43, 43, 43, 0.16);
  
  --color-shadow-sm: rgba(0, 0, 0, 0.05);
  --color-shadow-md: rgba(0, 0, 0, 0.1);
  --color-shadow-lg: rgba(0, 0, 0, 0.15);
  
  /* Static colors for reference */
  --color-charcoal: #2B2B2B;
  --color-white: #FFFFFF;
  --color-warm-white: #FAF8F5;
  --color-cream: #EDE8E1;
  --color-stone-gray: #9B9B9B;
  --color-deep-charcoal: #2B2B2B;
  --color-light-gold: #E5D5B7;
}

/* === DARK MODE === */
[data-theme="dark"] {
  --color-text-primary: #F5F3F0;
  --color-text-secondary: #D1CCC4;
  --color-text-muted: #9B9B9B;
  --color-text-inverse: #1A1A1A;
  
  --color-bg-primary: #1A1A1A;
  --color-bg-secondary: #252525;
  --color-bg-tertiary: #2B2B2B;
  --color-bg-elevated: #303030;
  
  --color-surface: #252525;
  --color-surface-hover: #2F2F2F;
  
  --color-border-light: rgba(255, 255, 255, 0.08);
  --color-border-medium: rgba(255, 255, 255, 0.12);
  --color-border-strong: rgba(255, 255, 255, 0.16);
  
  --color-shadow-sm: rgba(0, 0, 0, 0.3);
  --color-shadow-md: rgba(0, 0, 0, 0.4);
  --color-shadow-lg: rgba(0, 0, 0, 0.5);
  
  /* Keep gold consistent but slightly adjusted for dark mode */
  --color-gold: #D4B67A;
  --color-gold-light: #E5D5B7;
  --color-gold-dark: #B39858;
}

/* Smooth theme transitions */
*,
*::before,
*::after {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Disable transitions on theme change to avoid flash */
.theme-transitioning *,
.theme-transitioning *::before,
.theme-transitioning *::after {
  transition: none !important;
}

:root {
  /* Neutral Scale (kept for reference) */
  --color-stone-100: #F5F3F0;
  --color-stone-200: #E8E5E0;
  --color-stone-300: #D1CCC4;
  --color-stone-400: #9B9B9B;
  --color-stone-500: #6B6B6B;
  --color-stone-600: #4A4A4A;
  
  /* === TYPOGRAPHY === */
  
  /* Font Families */
  --font-heading: 'Cormorant Garamond', 'Georgia', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Cormorant Garamond', serif; /* For hero/special headings */
  
  /* Font Sizes - Fluid Typography (scales with viewport) */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);      /* 12-14px */
  --text-sm: clamp(0.875rem, 0.8rem + 0.375vw, 1rem);        /* 14-16px */
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);      /* 16-18px */
  --text-lg: clamp(1.125rem, 1rem + 0.625vw, 1.25rem);       /* 18-20px */
  --text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem);        /* 20-24px */
  --text-2xl: clamp(1.5rem, 1.25rem + 1.25vw, 2rem);         /* 24-32px */
  --text-3xl: clamp(2rem, 1.5rem + 2.5vw, 3rem);             /* 32-48px */
  --text-4xl: clamp(2.5rem, 1.75rem + 3.75vw, 4rem);         /* 40-64px */
  --text-5xl: clamp(3rem, 2rem + 5vw, 5rem);                 /* 48-80px */
  
  /* Font Weights */
  --weight-light: 300;
  --weight-normal: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;
  
  /* Line Heights */
  --leading-tight: 1.2;
  --leading-snug: 1.375;
  --leading-normal: 1.5;
  --leading-relaxed: 1.625;
  --leading-loose: 1.75;
  
  /* Letter Spacing */
  --tracking-tight: -0.02em;
  --tracking-normal: 0;
  --tracking-wide: 0.025em;
  --tracking-wider: 0.05em;
  --tracking-widest: 0.1em;
  
  /* === SPACING SYSTEM === */
  /* Based on 8px grid (modern standard) */
  
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */
  --space-24: 6rem;     /* 96px */
  --space-32: 8rem;     /* 128px */
  
  /* Semantic Spacing */
  --section-padding-mobile: var(--space-12);
  --section-padding-desktop: var(--space-20);
  --container-padding: var(--space-6);
  
  /* === LAYOUT === */
  
  --container-max-width: 1400px;
  --container-narrow: 900px;
  --container-wide: 1600px;
  
  --nav-height: 80px;
  --nav-height-mobile: 70px;
  
  /* === BORDERS & RADIUS === */
  
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;
  
  --border-width: 1px;
  --border-width-thick: 2px;
  
  /* === SHADOWS === */
  /* Subtle, sophisticated shadows for 2025 aesthetic */
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 
               0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 
               0 4px 6px -2px rgba(0, 0, 0, 0.03);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 
               0 10px 10px -5px rgba(0, 0, 0, 0.02);
  
  /* Gold glow for hover states */
  --shadow-gold: 0 0 20px rgba(201, 168, 106, 0.2);
  
  /* === TRANSITIONS === */
  /* Smooth, elegant animations (not cheap template effects) */
  
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slower: 500ms cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Custom easing curves */
  --ease-out-quad: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-in-out-quad: cubic-bezier(0.455, 0.03, 0.515, 0.955);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1); /* Material Design standard */
  
  /* === Z-INDEX SCALE === */
  /* Organized layer management */
  
  --z-base: 1;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal-backdrop: 400;
  --z-modal: 500;
  --z-popover: 600;
  --z-tooltip: 700;
  
  /* === BREAKPOINTS === */
  /* Mobile-first approach */
  /* Use in media queries: @media (min-width: 768px) { } */
  
  /* 
  --breakpoint-sm: 640px;   (mobile landscape)
  --breakpoint-md: 768px;   (tablet)
  --breakpoint-lg: 1024px;  (small desktop)
  --breakpoint-xl: 1280px;  (desktop)
  --breakpoint-2xl: 1536px; (large desktop)
  */
}

/* ============================================
   MODERN RESET & BASE STYLES
   ============================================ */

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

/* Modern smooth scrolling */
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Base body styles */
body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text-primary);
  background-color: var(--color-bg-primary);
  overflow-x: hidden;
}

/* Typography defaults */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: var(--weight-normal);
  line-height: var(--leading-tight);
  color: var(--color-text-primary);
  margin-bottom: var(--space-4);
  letter-spacing: var(--tracking-tight);
}

h1 {
  font-size: var(--text-5xl);
  font-weight: var(--weight-light);
  letter-spacing: var(--tracking-tight);
}

h2 {
  font-size: var(--text-4xl);
  font-weight: var(--weight-light);
}

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

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

h5 {
  font-size: var(--text-xl);
}

h6 {
  font-size: var(--text-lg);
}

p {
  margin-bottom: var(--space-4);
  line-height: var(--leading-relaxed);
}

/* Link styles */
a {
  color: var(--color-gold);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--color-gold-dark);
}

/* Image defaults */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Button reset */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* List reset */
ul, ol {
  list-style: none;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding);
  padding-right: var(--container-padding);
}

.container-narrow {
  max-width: var(--container-narrow);
}

.container-wide {
  max-width: var(--container-wide);
}

/* Section spacing */
.section {
  padding-top: var(--section-padding-mobile);
  padding-bottom: var(--section-padding-mobile);
}

@media (min-width: 768px) {
  .section {
    padding-top: var(--section-padding-desktop);
    padding-bottom: var(--section-padding-desktop);
  }
}

/* Text utilities */
.text-gold {
  color: var(--color-gold);
}

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

.text-center {
  text-align: center;
}

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

/* Focus styles for accessibility */
:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

