/* ============================================================
   MRL FERFORJE - DESIGN SYSTEM (main.css)
   Skills: frontend-design, UI/UX Pro Max, Taste Skill, Web Animation
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@700;900&family=Cormorant+Garamond:ital,wght@0,400;0,600;0,700;1,400&family=Playfair+Display:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  /* Colors */
  --color-primary: #1C1C1C;
  --color-primary-light: #2A2A2A;
  --color-accent: #B8860B;
  --color-accent-light: #D4A843;
  --color-accent-dark: #8B6508;
  --color-accent-contrast: #9A7209;   /* WCAG AA on light bg (UI/UX Pro Max) */
  --color-bg: #F8F5F0;
  --color-bg-alt: #EFEBE4;
  --color-bg-dark: #141414;
  --color-danger: #8B1A1A;
  --color-text: #2D2D2D;
  --color-text-light: #6B6B6B;
  --color-white: #FFFFFF;
  --color-border: #E0DCD6;
  --color-overlay: rgba(28, 28, 28, 0.88);

  /* Fonts */
  --font-display: 'Cinzel', Georgia, serif;        /* H1 only — architectural drama */
  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-subheading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, sans-serif;

  /* Type Scale */
  --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: 1.875rem;
  --text-4xl: 2.5rem;
  --text-5xl: 3.5rem;
  --text-6xl: 4.75rem;   /* NEW — hero title */
  --text-7xl: 6.5rem;    /* NEW — decorative numbers */

  /* Spacing (8px grid) */
  --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;
  --space-6xl: 10rem;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 800px;
  --container-padding: 1.5rem;
  --header-height: 80px;

  /* Radii */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.10);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --shadow-xl: 0 16px 50px rgba(0,0,0,0.15);
  --shadow-accent: 0 4px 20px rgba(184,134,11,0.30);
  --shadow-gold-lg: 0 8px 40px rgba(184,134,11,0.22);  /* NEW */
  --shadow-glass: 0 8px 32px rgba(0,0,0,0.24);          /* NEW */

  /* Easing (Web Animation Skill) */
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);

  /* Transitions */
  --transition-fast: 150ms var(--ease-out);
  --transition-base: 300ms var(--ease-smooth);
  --transition-slow: 500ms var(--ease-spring);
  --transition-hero: 800ms var(--ease-spring);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  /* Custom scrollbar */
  scrollbar-width: thin;
  scrollbar-color: var(--color-accent) var(--color-primary);
}
html::-webkit-scrollbar { width: 5px; }
html::-webkit-scrollbar-track { background: var(--color-primary); }
html::-webkit-scrollbar-thumb { background: var(--color-accent); border-radius: 3px; }

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-accent); text-decoration: none; transition: color var(--transition-fast); }
a:hover { color: var(--color-accent-light); }
ul, ol { list-style: none; }
::selection { background: var(--color-accent); color: var(--color-white); }

/* ============================================================
   TYPOGRAPHY (UI/UX Pro Max — font pairings)
   ============================================================ */
h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.15; text-wrap: balance; }

h1 {
  font-family: var(--font-display);
  font-size: var(--text-6xl);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}
h2 { font-family: var(--font-subheading); font-size: var(--text-4xl); font-weight: 600; }
h3 { font-family: var(--font-subheading); font-size: var(--text-3xl); font-weight: 500; }
h4 { font-family: var(--font-body); font-size: var(--text-xl); font-weight: 600; }
p { margin-bottom: var(--space-md); }

.text-accent { color: var(--color-accent); }
.text-light { color: var(--color-text-light); }
.text-white { color: var(--color-white); }
.text-center { text-align: center; }

.section-label {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--color-accent);
  margin-bottom: var(--space-md);
  display: flex;
  align-items: center;
  gap: var(--space-md);
}
.section-label::before {
  content: '';
  display: block;
  width: 28px;
  height: 1px;
  background: var(--color-accent);
  flex-shrink: 0;
}
.section-title {
  font-family: var(--font-subheading);
  font-size: var(--text-4xl);
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: var(--space-lg);
}
.section-subtitle {
  font-size: var(--text-lg);
  color: var(--color-text-light);
  max-width: 580px;
  line-height: 1.75;
}
.section-header { margin-bottom: var(--space-3xl); }
.section-header.centered { text-align: center; }
.section-header.centered .section-label { justify-content: center; }
.section-header.centered .section-subtitle { margin: 0 auto; }

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}
.container--narrow { max-width: var(--container-narrow); }
section { padding: var(--space-5xl) 0; }
.grid { display: grid; gap: var(--space-xl); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

/* Section backgrounds */
.section--dark { background: var(--color-primary); color: var(--color-white); }
.section--dark .section-title { color: var(--color-white); }
.section--dark .section-subtitle { color: rgba(255,255,255,0.7); }
.section--dark p { color: rgba(255,255,255,0.8); }
.section--alt { background: var(--color-bg-alt); }

/* Diagonal section break (Taste Skill / frontend-design) */
.section--diagonal-top {
  clip-path: polygon(0 3%, 100% 0, 100% 100%, 0 100%);
  margin-top: -3vw;
  padding-top: calc(var(--space-5xl) + 3vw);
}

/* ============================================================
   ACCESSIBILITY (UI/UX Pro Max)
   ============================================================ */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ============================================================
   ANIMATIONS (Web Animation Skill)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s var(--ease-spring), transform 0.75s var(--ease-spring);
}
.reveal.active { opacity: 1; transform: translateY(0); }
.reveal--delay-1 { transition-delay: 0.09s; }
.reveal--delay-2 { transition-delay: 0.18s; }
.reveal--delay-3 { transition-delay: 0.27s; }
.reveal--delay-4 { transition-delay: 0.36s; }

/* Hero entrance animations */
.hero-fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: heroFadeIn 0.9s var(--ease-spring) forwards;
}
@keyframes heroFadeIn {
  to { opacity: 1; transform: translateY(0); }
}

/* Hero title line stagger */
.hero__title--animate .hero__line {
  display: block;
  opacity: 0;
  transform: translateY(48px);
  animation: lineReveal 0.9s var(--ease-spring) forwards;
}
@keyframes lineReveal {
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   REDUCED MOTION (Web Animation Skill — mandatory)
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal, .hero-fade-in, .hero__line { opacity: 1; transform: none; }
}

/* ============================================================
   UTILITIES
   ============================================================ */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }

/* Glass card utility (Taste Skill — hero stat card) */
.glass-card {
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-lg);
}

/* Trust chip utility (CRO Skill) */
.trust-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.05em;
  color: rgba(255,255,255,0.85);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 100px;
  padding: 5px 12px;
}
.trust-chip svg { width: 12px; height: 12px; flex-shrink: 0; }

/* Badge utility (CRO Skill) */
.badge--popular {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: var(--color-accent);
  color: var(--color-white);
  padding: 3px 8px;
  border-radius: 4px;
  margin-bottom: var(--space-sm);
}

/* Star rating (CRO Skill) */
.star-rating {
  display: flex;
  gap: 2px;
  color: var(--color-accent);
  font-size: 1rem;
  margin-bottom: var(--space-sm);
}
