/* ============================================
   DIGITAL WORLD COACHING — BASE PRO DESIGN
   Structure inspirée d'un design dark premium
   Palette DWC : or #f59e0b + violet #a855f7
   ============================================ */

/* CSS Variables */
:root {
  /* Colors - Brand (or doré) */
  --brand-50: #fffbeb;
  --brand-100: #fef3c7;
  --brand-200: #fde68a;
  --brand-300: #fcd34d;
  --brand-400: #fbbf24;
  --brand-500: #f59e0b;
  --brand-600: #d97706;
  --brand-700: #b45309;
  --brand-800: #92400e;
  --brand-900: #78350f;
  --brand-950: #451a03;

  /* Colors - Background (noir violacé DWC) */
  --bg-primary: #0a0812;
  --bg-secondary: #120d1f;
  --bg-tertiary: #1c1430;

  /* Colors - Accents (violet profond + touche émeraude) */
  --purple-500: #a855f7;
  --purple-600: #9333ea;
  --emerald-500: #10b981;
  --emerald-600: #059669;
  --orange-500: #f97316;

  /* Colors - Text */
  --text-primary: #ffffff;
  --text-secondary: #e2e0ec;
  --text-tertiary: #a9a4bd;
  --text-muted: #7d768f;

  /* Colors - Borders */
  --border-primary: rgba(255, 255, 255, 0.1);
  --border-secondary: rgba(255, 255, 255, 0.05);

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

  /* Typography */
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'Fira Code', monospace;

  /* Sizes */
  --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;
  --text-6xl: 3.75rem;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 40px rgba(245, 158, 11, 0.25);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Container */
  --container-sm: 640px;
  --container-md: 768px;
  --container-lg: 1024px;
  --container-xl: 1280px;
  --container-2xl: 1536px;
}

/* ============================================
   RESET & BASE
   ============================================ */

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text-secondary);
  background-color: var(--bg-primary);
  overflow-x: hidden;
  position: relative;
}

/* Background Pattern (halos or/violet) */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 20% 30%, rgba(245, 158, 11, 0.10) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(168, 85, 247, 0.10) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
}

h1 { font-size: clamp(2rem, 5vw, var(--text-6xl)); }
h2 { font-size: clamp(1.75rem, 4vw, var(--text-5xl)); }
h3 { font-size: clamp(1.5rem, 3vw, var(--text-4xl)); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

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

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

a:hover {
  color: var(--brand-300);
}

strong {
  font-weight: 600;
  color: var(--text-primary);
}

/* ============================================
   UTILITIES
   ============================================ */

.container {
  width: 100%;
  max-width: var(--container-xl);
  margin: 0 auto;
  padding: 0 var(--spacing-xl);
  position: relative;
  z-index: 1;
}

.section {
  padding: var(--spacing-4xl) 0;
  position: relative;
}

.section-sm {
  padding: var(--spacing-3xl) 0;
}

.section-lg {
  padding: calc(var(--spacing-4xl) * 1.5) 0;
}

/* Text Utilities */
.text-gradient {
  background: linear-gradient(135deg, var(--brand-400), var(--purple-500));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

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

/* ============================================
   NAVIGATION (base — la nav pilule est dans dwc.css)
   ============================================ */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  background: rgba(10, 8, 18, 0.6);
  border-bottom: 1px solid rgba(245, 158, 11, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  transition: all var(--transition-base);
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand-500), var(--purple-600));
  color: var(--text-primary);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(168, 85, 247, 0.45);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid var(--border-primary);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--brand-400);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: var(--text-xs);
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: var(--text-base);
}

/* ============================================
   CARDS - GLASSMORPHISM
   ============================================ */

.card {
  background: rgba(18, 13, 31, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-primary);
  border-radius: var(--radius-2xl);
  padding: var(--spacing-xl);
  transition: all var(--transition-base);
}

.card:hover {
  background: rgba(18, 13, 31, 0.75);
  border-color: rgba(245, 158, 11, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.card-header {
  margin-bottom: var(--spacing-lg);
}

.card-title {
  font-size: var(--text-2xl);
  margin-bottom: var(--spacing-sm);
}

.card-description {
  color: var(--text-tertiary);
  font-size: var(--text-sm);
}

.card-content {
  margin-bottom: var(--spacing-lg);
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--border-secondary);
}

/* ============================================
   GRID SYSTEM
   ============================================ */

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

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

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
  .container { padding: 0 var(--spacing-lg); }
  .grid-cols-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-cols-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-cols-2 { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  :root {
    --spacing-4xl: 3rem;
    --spacing-3xl: 2rem;
  }

  .container { padding: 0 var(--spacing-md); }

  .grid-cols-2,
  .grid-cols-3,
  .grid-cols-4 { grid-template-columns: 1fr; }

  .section { padding: var(--spacing-3xl) 0; }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-fade-in-up {
  animation: fadeInUp 0.8s ease-out forwards;
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

/* Scroll reveal (activé par js/nav.js) */
.stitch-body h1, .stitch-body h2 { text-wrap: balance; }

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

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

/* ============================================
   SCROLLBAR
   ============================================ */

::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--purple-600);
  border-radius: var(--radius-full);
  border: 3px solid var(--bg-primary);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--brand-500);
}

/* ============================================
   SELECTION
   ============================================ */

::selection {
  background: var(--brand-500);
  color: var(--text-primary);
}

/* ============================================
   TEXT VISIBILITY + GLOW EFFECTS
   ============================================ */

h1, h2, h3, h4 {
  color: #faf9fc;
  text-shadow: 0 0 40px rgba(248, 250, 252, 0.05);
}

p, li, span, div {
  color: #e2e0ec;
}

.card:hover h3,
.card:hover h2 {
  text-shadow: 0 0 20px rgba(245, 158, 11, 0.3);
}

.text-glow {
  text-shadow: 0 0 60px rgba(245, 158, 11, 0.2);
}

a:hover {
  text-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

/* ============================================
   ACCESSIBILITY - Focus states
   ============================================ */

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
    outline: 2px solid var(--brand-400);
    outline-offset: 2px;
}

.btn:focus-visible {
    outline: 2px solid var(--brand-400);
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.15);
}

.card:focus-visible,
.card:focus-within {
    outline: 2px solid var(--brand-400);
    outline-offset: 2px;
}

/* Skip to content link */
.skip-link {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.75rem 1.5rem;
    background: var(--brand-500);
    color: white;
    border-radius: var(--radius-lg);
    z-index: 10000;
    font-weight: 600;
}
.skip-link:focus {
    top: 1rem;
}