/* ==========================================================================
   MEXTAPAS — Global Styles
   Brand: Mextapas | Mexican Soul
   Colors: Black #0D0D0D, Gold #FFC300, White #FFFFFF, Charcoal #1C1C1C
   Fonts: Cormorant Garamond (display), DM Sans (body)
   ========================================================================== */

/* --- CSS Custom Properties --- */
:root {
  /* Brand Colors */
  --color-black: #0D0D0D;
  --color-gold: #FFC300;
  --color-white: #FFFFFF;
  --color-charcoal: #1C1C1C;
  --color-gold-dark: #D4A200;
  --color-gold-light: #FFD54F;
  --color-gray: #A0A0A0;
  --color-gray-light: #2A2A2A;

  /* Typography */
  --font-display: 'Cormorant Garamond', 'Playfair Display', 'Georgia', serif;
  --font-body: 'DM Sans', 'Helvetica Neue', Arial, sans-serif;

  /* Font Weights */
  --fw-light: 300;
  --fw-regular: 400;
  --fw-bold: 700;
  --fw-black: 900;

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

  /* Layout */
  --max-width: 1280px;
  --nav-height: 130px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

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

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

body {
  font-family: var(--font-body);
  font-weight: var(--fw-light);
  color: var(--color-white);
  background-color: var(--color-black);
  line-height: 1.7;
  overflow-x: hidden;
}

/* --- Typography --- */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  line-height: 1.2;
  color: var(--color-white);
}

h1 {
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: var(--fw-black);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: var(--fw-bold);
  letter-spacing: -0.01em;
}

h3 {
  font-size: clamp(1.3rem, 2.5vw, 1.75rem);
  font-weight: var(--fw-bold);
}

h4 {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: var(--fw-bold);
}

p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-white);
  max-width: 65ch;
}

a {
  color: var(--color-gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

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

ul,
ol {
  list-style: none;
}

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

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

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

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

.section--gold h2,
.section--gold h3,
.section--gold p,
.section--gold label {
  color: var(--color-black);
}

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

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

.text-uppercase {
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.section-label {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: var(--fw-regular);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
  display: block;
}

.section-title {
  margin-bottom: var(--space-lg);
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 2px;
  background-color: var(--color-gold);
  margin-top: var(--space-sm);
}

.section-title.text-center::after {
  margin-left: auto;
  margin-right: auto;
}

/* Gold line divider */
.divider {
  width: 60px;
  height: 2px;
  background-color: var(--color-gold);
  border: none;
  margin: var(--space-lg) 0;
}

.divider--center {
  margin-left: auto;
  margin-right: auto;
}

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

/* Lazy load placeholder */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity var(--transition-slow);
}

img[loading="lazy"].loaded,
img[loading="lazy"][complete] {
  opacity: 1;
}

/* --- Grid Helpers --- */
.grid {
  display: grid;
  gap: var(--space-lg);
}

.grid--2 {
  grid-template-columns: 1fr;
}

.grid--3 {
  grid-template-columns: 1fr;
}

/* --- Responsive Breakpoints --- */

/* Tablet: 640px+ */
@media (min-width: 640px) {
  .grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop: 1024px+ */
@media (min-width: 1024px) {
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }

  .container {
    padding: 0 var(--space-lg);
  }
}

/* Wide Desktop: 1280px+ */
@media (min-width: 1280px) {
  .container {
    padding: 0 var(--space-xl);
  }
}

/* --- Page transition --- */
.page-content {
  padding-top: var(--nav-height);
}

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

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