/* ==========================================================================
   UNIV-BELOTE - Main CSS
   Variables, Reset, Utilitaires
   ========================================================================== */

/* === VARIABLES CSS === */
:root {
  /* Couleurs principales - Thème Belote */
  --color-primary: #059669;           /* Vert émeraude */
  --color-primary-dark: #047857;      /* Vert foncé */
  --color-primary-light: #10B981;     /* Vert clair */

  /* Couleur du tapis de jeu */
  --color-felt-green: #065F46;

  /* Couleur d'accent (boutons CTA) */
  --color-accent: #F59E0B;            /* Or/Ambre */
  --color-accent-dark: #D97706;

  /* Couleur secondaire */
  --color-secondary: #1E293B;         /* Bleu nuit */

  /* Couleur crème pour les cartes */
  --color-card-cream: #FEF3C7;

  /* Couleurs neutres */
  --color-dark: #0F172A;
  --color-white: #FFFFFF;
  --color-bg: #FAFAFA;
  --color-bg-alt: #F1F5F9;
  --color-text: #334155;
  --color-text-light: #64748B;
  --color-text-muted: #94A3B8;
  --color-border: #E2E8F0;

  /* Typographie */
  --font-heading: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Tailles de texte */
  --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.25rem;
  --text-5xl: 3rem;

  /* Espacements */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;

  /* Bordures */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-full: 9999px;

  /* Ombres */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 350ms ease;

  /* Largeur max du contenu */
  --max-width: 1200px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

/* === TYPOGRAPHIE === */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-secondary);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p {
  margin-bottom: var(--spacing-md);
}

strong {
  font-weight: 600;
}

/* === LAYOUT === */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

.grid {
  display: grid;
  gap: var(--spacing-lg);
}

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* === UTILITAIRES === */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

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

.bg-white { background-color: var(--color-white); }
.bg-alt { background-color: var(--color-bg-alt); }
.bg-dark { background-color: var(--color-dark); }
.bg-primary { background-color: var(--color-primary); }

.mt-1 { margin-top: var(--spacing-sm); }
.mt-2 { margin-top: var(--spacing-md); }
.mt-4 { margin-top: var(--spacing-xl); }
.mt-6 { margin-top: var(--spacing-2xl); }
.mt-8 { margin-top: var(--spacing-3xl); }

.mb-1 { margin-bottom: var(--spacing-sm); }
.mb-2 { margin-bottom: var(--spacing-md); }
.mb-4 { margin-bottom: var(--spacing-xl); }
.mb-6 { margin-bottom: var(--spacing-2xl); }
.mb-8 { margin-bottom: var(--spacing-3xl); }

.py-4 { padding-top: var(--spacing-xl); padding-bottom: var(--spacing-xl); }
.py-6 { padding-top: var(--spacing-2xl); padding-bottom: var(--spacing-2xl); }
.py-8 { padding-top: var(--spacing-3xl); padding-bottom: var(--spacing-3xl); }

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

/* === SECTIONS === */
.section {
  padding: var(--spacing-3xl) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

.section-title {
  margin-bottom: var(--spacing-sm);
}

.section-subtitle {
  color: var(--color-text-light);
  font-size: var(--text-lg);
  max-width: 600px;
  margin: 0 auto;
}

/* === LIENS === */
a:hover {
  color: var(--color-primary);
}

.link-primary {
  color: var(--color-primary);
  font-weight: 500;
  transition: color var(--transition-fast);
}

.link-primary:hover {
  color: var(--color-primary-dark);
}

/* === FOCUS STYLES === */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* === SÉLECTION === */
::selection {
  background-color: var(--color-primary);
  color: var(--color-white);
}
