/* ==========================================================================
   R.E.Solution SRLS — Main Stylesheet
   Variables, Reset, Typography, Layout, Utilities
   ========================================================================== */

/* ---------- Custom Properties ---------- */
:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f5f5f5;
  --bg-card: #ffffff;
  --accent-gold: #8B1A1A;
  --accent-gold-light: rgba(139, 26, 26, 0.08);
  --accent-gold-border: rgba(139, 26, 26, 0.2);
  --text-primary: #1a1a1a;
  --text-secondary: #555555;
  --font-display: 'DM Serif Display', serif;
  --font-body: 'Inter', sans-serif;
  --transition-base: 0.3s ease;
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.08);
  --border-radius: 4px;
  --max-width: 1200px;
}

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

html {
  scroll-behavior: smooth;
}

/* ---------- Body & Noise Texture ---------- */
body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.8;
  font-size: 17px;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.02;
}

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.25;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
}

h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  margin-bottom: 1rem;
}

h3 {
  font-size: clamp(1.3rem, 2.5vw, 1.6rem);
}

h4 {
  font-size: 1.15rem;
}

p {
  margin-bottom: 1.2rem;
  max-width: 70ch;
}

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

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

/* ---------- Layout ---------- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.grid {
  display: grid;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

section {
  padding: 100px 0;
  position: relative;
  z-index: 1;
}

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

/* ---------- Utility Classes ---------- */
.text-center {
  text-align: center;
}

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

.mb-1 {
  margin-bottom: 1rem;
}

.mb-2 {
  margin-bottom: 2rem;
}

.mb-3 {
  margin-bottom: 3rem;
}

.mb-4 {
  margin-bottom: 4rem;
}

.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;
}

/* ---------- Responsive: Tablet (768px - 1024px) ---------- */
@media (min-width: 768px) and (max-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

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

/* ---------- Responsive: Mobile (< 768px) ---------- */
@media (max-width: 767px) {
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  section {
    padding: 60px 0;
  }

  .container {
    padding: 0 16px;
  }
}
