/* ==========================================================================
   ANKS MODERN VANILLA CSS - DESIGN SYSTEM
   ========================================================================== */

@font-face {
  font-family: Comfortaa;
  src: url("../fonts/comfortaa/Comfortaa-Variable.ttf") format("truetype");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: metropolis;
  src: url("../fonts/metropolis/Metropolis-Regular.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: metropolis;
  src: url("../fonts/metropolis/Metropolis-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: metropolis;
  src: url("../fonts/metropolis/Metropolis-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Lora;
  src: local("Lora Regular"), url("../fonts/lora/lora-v14-latin-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* --- RESET MODERNE --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { 
    font-family: var(--font-body); 
    line-height: 1.6; 
    color: var(--text); 
    background-color: var(--bg-body);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: background-color 0.3s ease, color 0.3s ease;
    background-image: radial-gradient(circle at 10% 20%, rgba(139, 92, 246, 0.03) 0%, transparent 40%),
                      radial-gradient(circle at 90% 80%, rgba(236, 72, 153, 0.03) 0%, transparent 40%);
    background-attachment: fixed;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; transition: 0.2s; }
a:hover { opacity: 0.8; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* --- VARIABLES --- */
:root {
    --font-sans: "Comfortaa", sans-serif;
    --font-body: "metropolis", sans-serif;
    
    --primary: hsl(285, 80%, 60%);
    --primary-soft: rgba(139, 92, 246, 0.1);
    --text: #1f2937;
    --text-light: #6b7280;
    --bg-body: #ffffff;
    
    /* Glassmorphism Adouci */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-bg-hbg: rgba(18, 15, 30, 0.6);
    --glass-border: rgba(139, 92, 246, 0.12); /* Bordure ultra-légère */
    --glass-blur: 12px;
    --radius: 0.5rem; /* Angles adoucis */
    --shadow: 0 10px 30px rgba(31, 38, 135, 0.04);
    
    --container-width: 1200px;
    --header-height: 80px;

    /* Échelle Typographique */
    --fs-h1: clamp(1.75rem, 5vw, 2.5rem);
    --fs-h2: clamp(1.5rem, 4vw, 2.25rem);
    --fs-h3: clamp(1.25rem, 3vw, 1.75rem);
    --fs-body: 1.1rem;
    --fs-lead: 1.25rem;
}

[data-theme='dark'] {
    --text: #f3f4f6;
    --text-light: #9ca3af;
    --bg-body: #0b0914;
    --glass-bg: rgba(18, 15, 30, 0.75);
    --glass-border: rgba(255, 255, 255, 0.06);
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* --- LAYOUT UTILITIES --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}



.section { padding: 2rem 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.is-flex { display: flex; align-items: center; gap: 1rem; }
.is-justify-between { justify-content: space-between; }
.is-center { text-align: center; justify-content: center; }

/* --- COMPOSANTS --- */

/* Header */
.site-header {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    box-shadow: var(--shadow);
    position: sticky;
    width: 100%;
    top: 0;
    z-index: 1000;   
}

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

.nav-brand { 
    display: flex;
    align-items: center;
}
.nav-menu { display: flex; align-items: center; gap: 1.5rem; list-style: none; }
.nav-menu li { list-style: none; }
.nav-link { color: var(--text); font-weight: 500; font-size: 0.95rem; text-decoration: none; }
.nav-link.active { color: var(--primary); font-weight: 700; }

/* Burger Menu (Vanilla) */
.menu-toggle { display: none; flex-direction: column; gap: 5px; }
.menu-toggle span { width: 25px; height: 2px; background: var(--text); border-radius: 2px; transition: 0.3s; }

/* Hero Section (Centrée) */
.hero {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.hero-sm {
    padding: 2.5rem 2rem;
}

.hero::after {
    content: '';
    position: absolute;
    top: -50%; right: -20%; width: 60%; height: 150%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.hero-title { font-family: var(--font-sans); font-size: clamp(3rem, 5vw, 4rem); line-height: 1.5; margin-bottom: 1.5rem; color: var(--primary); }
.hero-subtitle { font-size: clamp(1.1rem, 2vw, 1.5rem); color: var(--text-light); max-width: 700px; }

/* Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow);
    transition: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    height: 100%;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 15px 40px rgba(139, 92, 246, 0.1);
}

/* Boutons */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    border-radius: 2rem;
    font-weight: 600;
    transition: 0.3s;
    font-family: var(--font-sans);
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { transform: scale(1.05); box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3); }

/* Theme Toggle */
.theme-btn {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--primary-soft);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
}

/* FAQ Accordion */
details.faq-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
}
details.faq-item summary {
    list-style: none;
    font-weight: 700;
    cursor: pointer;
    font-size: 1.1rem;
    display: flex;
    justify-content: space-between;
}
details.faq-item summary::after { content: '→'; transition: 0.3s; color: var(--primary); }
details[open].faq-item summary::after { transform: rotate(90deg); }

/* Footer Navigation */
.footer-nav { display: flex; justify-content: center; gap: 2rem; flex-wrap: wrap; margin-bottom: 1.5rem; list-style: none; padding: 0; }
.footer-link { font-size: 0.85rem; color: var(--text-light); text-decoration: none; transition: 0.3s; }
.footer-link:hover { color: var(--primary); }

/* Mobile Adaptations */
@media (max-width: 768px) {
    .nav-menu {
        display: none; /* Cache par défaut sur mobile */
        position: absolute;
        top: calc(100% + 10px); left: 1rem; right: 1rem;
        background: var(--glass-bg);
        backdrop-filter: blur(25px) saturate(180%);
        -webkit-backdrop-filter: blur(25px) saturate(180%);
        background-image: linear-gradient(135deg, var(--primary-soft) 0%, transparent 100%);
        border: 1px solid var(--primary); /* Bordure colorée pour distinction */
        border-radius: var(--radius);
        padding: 2.5rem 1.5rem;
        flex-direction: column;
        gap: 1.5rem;
        box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
        text-align: center;
        z-index: 1100;
    }
    .nav-menu.is-active { display: flex; }
    .nav-menu .nav-link { font-size: 1.1rem; width: 100%; display: block; }
    .menu-toggle { display: flex; }
    .hero { padding: 3rem 1.5rem; }
    .hero-title { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.25; margin-bottom: 1.25rem; }
    .hero-sm { padding: 2rem 1.5rem; }
}

/* Typography Helpers */
h1 { font-family: var(--font-sans); font-size: var(--fs-h1); color: var(--text); line-height: 1.1; margin-bottom: 1.5rem; }
h2 { font-family: var(--font-sans); font-size: var(--fs-h2); color: var(--text); line-height: 1.2; margin-bottom: 1.25rem; }
h3 { font-family: var(--font-sans); font-size: var(--fs-h3); color: var(--text); line-height: 1.3; margin-bottom: 1rem; }

.lead { font-size: var(--fs-lead); color: var(--text-light); line-height: 1.6; font-style: italic; }

.content { font-size: var(--fs-body); line-height: 1.8; color: var(--text); }
.content p { margin-bottom: 1.5rem; }
.content ul, .content ol { margin-bottom: 1.5rem; padding-left: 1.5rem; }
.content li { margin-bottom: 0.5rem; }

.tag { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; padding: 0.2rem 0.6rem; border-radius: 1rem; background: var(--primary-soft); color: var(--primary); }
.breadcrumb { font-size: 0.85rem; color: var(--text-light); margin-bottom: 1rem; }
.breadcrumb a { color: var(--text-light); }
