:root {
    /* Palette de couleurs - Deep Blue Night (Traivis Master) */
    --primary: #1e40af;       /* Blue 700 - Bleu profond */
    --primary-dark: #1e3a8a;  /* Blue 800 - Bleu nuit */
    --primary-light: #3b82f6; /* Blue 500 - Bleu vif */
    --secondary: #0f172a;     /* Slate 900 - Nuit profonde */
    --dark: #0f172a;          /* Slate 900 - Contraste fort */
    --dark-soft: #1e293b;     /* Slate 800 */
    --accent: #3b82f6;        /* Blue 500 - Accent bleu */
    --surface: #ffffff;
    --background: #f8fafc;    /* Slate 50 - Neutre doux */
    --text-main: #0f172a;     /* Slate 900 */
    --text-muted: #64748b;    /* Slate 500 */
    
    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 24px;
    
    /* Shadows */
    --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);
}

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--background);
    color: var(--text-main);
    margin: 0;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Utilitaires */
.container {
    max-width: var(--container-width);
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Force toutes les sections à ne pas dépasser */
section {
    max-width: 100vw;
    overflow-x: hidden;
    box-sizing: border-box;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
    border: 1px solid transparent;
}
.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-main);
    border: 1px solid #e2e8f0;
}
.btn-outline:hover {
    border-color: var(--text-muted);
    background-color: white;
}

/* Header & Nav */
.main-header {
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.mobile-menu-btn, .mobile-menu {
    display: none;
}

.logo-container {
    display: flex;
    flex-direction: column;
    gap: 0px;
    line-height: 1;
}

.logo-link {
    text-decoration: none;
    transition: opacity 0.2s;
}

.logo-link:hover {
    opacity: 0.8;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--secondary);
    text-decoration: none;
    letter-spacing: -0.5px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.powered-by {
    text-decoration: none;
    opacity: 0.6;
    transition: opacity 0.2s;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.powered-by:hover {
    opacity: 1;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
}
.nav-link:hover {
    color: var(--primary);
}

/* Hero Section */
.hero-section {
    padding: 160px 0 100px;
    text-align: center;
    background: radial-gradient(circle at 50% 0%, #eef2ff 0%, rgba(255,255,255,0) 50%);
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background-color: #e0e7ff;
    color: var(--primary);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.1;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero-title span {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 40px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

/* Features Grid */
.features-section {
    padding: 100px 0;
    background-color: white;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 16px;
}

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

.feature-card {
    padding: 32px;
    background: var(--background);
    border-radius: var(--radius-md);
    border: 1px solid #f1f5f9;
    transition: transform 0.2s;
}
.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background-color: #e0e7ff;
    color: var(--primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--secondary);
}

.feature-desc {
    color: var(--text-muted);
}

/* Footer */
.main-footer {
    background-color: var(--secondary);
    color: white;
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 40px;
}

.footer-brand h3 {
    margin: 0 0 16px;
    font-size: 1.5rem;
}

.footer-brand p {
    color: #94a3b8;
    max-width: 300px;
}

.footer-col h4 {
    margin: 0 0 20px;
    font-weight: 600;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col li {
    margin-bottom: 12px;
}

.footer-col a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s;
}
.footer-col a:hover {
    color: white;
}

.copyright {
    text-align: center;
    color: #64748b;
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    /* FORCE GLOBAL WIDTH CONSTRAINTS */
    html, body {
        max-width: 100vw;
        overflow-x: hidden;
    }

    * {
        max-width: 100%;
    }

    /* Global & Layout */
    .container {
        padding: 0 16px;
        width: 100%;
        max-width: 100vw;
    }

    .hero-section {
        padding: 120px 0 60px;
        overflow-x: hidden;
    }

    /* Dashboard Mockup Mobile Fix */
    .hero-section > .container > div:last-child {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .hero-section > .container > div:last-child > div {
        height: 300px !important;
        border-radius: 12px !important;
        margin: 0 !important;
    }

    .section-header {
        margin-bottom: 40px;
    }

    /* Typography */
    .hero-title { 
        font-size: 2.25rem; 
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .section-title {
        font-size: 1.75rem;
    }

    /* Header & Nav */
    .desktop-nav {
        display: none;
    }

    /* Mobile Menu Button Fix */
    .mobile-menu-btn {
        display: block;
        background: none;
        border: none;
        cursor: pointer;
        padding: 10px;
        z-index: 1100; /* Au-dessus de tout */
        margin-left: auto; /* Pousse le bouton à droite */
        margin-right: -10px; /* Compense le padding du bouton */
    }

    .mobile-menu-btn span {
        display: block;
        width: 25px;
        height: 2px;
        background-color: var(--dark);
        margin: 5px 0;
        transition: all 0.3s ease;
    }

    /* Mobile Menu Overlay Fix - Radical */
    .mobile-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: white;
        padding: 100px 24px 40px; /* Espace en haut pour ne pas cacher sous le header */
        transform: translateX(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
        z-index: 1050; /* Juste sous le bouton menu (1100) */
        border-top: none;
        overflow-y: auto;
        display: block; /* Force display block */
    }

    .mobile-menu.active {
        transform: translateX(0);
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    }
    
    /* Bouton menu toujours visible et au-dessus */
    .mobile-menu-btn {
        position: relative;
        z-index: 1100; /* Au-dessus du menu ouvert */
    }
    
    /* Force Menu Visibility when Active */
    body.menu-open {
        overflow: hidden;
    }

    .mobile-nav-links {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }

    .mobile-nav-link {
        font-size: 1.2rem;
        font-weight: 600;
        color: var(--dark);
        text-decoration: none;
        padding: 8px 0;
    }

    /* Hamburger Animation */
    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    /* Grids -> Stack */
    .features-grid,
    .stats-grid,
    .testimonials-grid,
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    /* Pricing Grid - Force 1 column */
    .pricing-grid {
        grid-template-columns: 1fr !important;
        gap: 24px;
    }

    /* Problem Grid Specific Fix */
    .problem-grid {
        display: flex !important;
        flex-direction: column;
        gap: 40px;
    }

    /* Hero Actions */
    .hero-actions {
        flex-direction: column;
    }

    .hero-actions .btn {
        width: 100%;
    }

    /* Stats */
    .stats-grid {
        gap: 40px;
    }

    /* Problem Section */
    .problem-grid {
        gap: 40px;
    }
    
    .problem-content {
        text-align: left;
    }

    /* Pricing */
    .pricing-section {
        padding: 60px 0;
    }

    .pricing-card {
        padding: 32px 20px;
    }

    .pricing-card.featured {
        transform: none !important;
        scale: 1 !important;
    }

    .pricing-price {
        font-size: 2.5rem !important;
    }

    .pricing-features {
        font-size: 0.9rem;
    }

    /* Auth Pages */
    section[style*="min-height"] {
        padding: 20px 16px !important;
        align-items: flex-start !important;
        padding-top: 100px !important;
    }
    
    section[style*="min-height"] > .container {
        width: 100%;
    }
    
    section[style*="min-height"] .container > div {
        max-width: 100% !important;
    }
    
    section[style*="min-height"] .container > div > div {
        padding: 24px !important;
    }
}

/* Tablet Adjustments */
@media (min-width: 769px) and (max-width: 1024px) {
    .features-grid,
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .pricing-grid {
        gap: 20px;
    }
    
    .pricing-card {
        padding: 30px 20px;
    }
}

/* Stats Section */
.stats-section {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    text-align: center;
}

.stat-item h3 {
    font-size: 3rem;
    font-weight: 800;
    margin: 0 0 8px;
    line-height: 1;
}

.stat-item p {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
}

/* Problem/Solution Section */
.problem-section {
    padding: 100px 0;
    background: var(--dark);
    color: white;
}

.problem-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.problem-content h2 {
    font-size: 2.5rem;
    margin-bottom: 24px;
    font-weight: 800;
}

.problem-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.problem-list li {
    padding: 16px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.problem-list li:before {
    content: "✗";
    color: #ef4444;
    font-weight: bold;
    font-size: 1.2rem;
}

.solution-list li:before {
    content: "✓";
    color: var(--primary);
}

/* Pricing Section */
.pricing-section {
    padding: 100px 0;
    background: white;
}

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

.pricing-card {
    background: var(--background);
    border: 2px solid #e5e7eb;
    border-radius: var(--radius-md);
    padding: 40px 32px;
    text-align: center;
    transition: all 0.3s;
    position: relative;
}

.pricing-card.featured {
    background: var(--dark);
    color: white;
    border-color: var(--primary);
    transform: scale(1.05);
}

.pricing-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: white;
    padding: 4px 16px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.pricing-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.pricing-price {
    font-size: 3rem;
    font-weight: 800;
    margin: 20px 0;
}

.pricing-price span {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--text-muted);
}

.pricing-card.featured .pricing-price span {
    color: rgba(255,255,255,0.7);
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 32px 0;
    text-align: left;
}

.pricing-features li {
    padding: 12px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.pricing-features li:before {
    content: "✓";
    color: var(--primary);
    font-weight: bold;
}

/* Testimonials */
.testimonials-section {
    padding: 100px 0;
    background: var(--background);
}

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

.testimonial-card {
    background: white;
    padding: 32px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.testimonial-text {
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 24px;
    color: var(--text-main);
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 16px;
}

.author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
}

.author-info h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
}

.author-info p {
    margin: 4px 0 0;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* CTA Sections améliorées */
.cta-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 100px 0;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.cta-primary:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="2" fill="white" opacity="0.1"/></svg>');
    opacity: 0.3;
}

.cta-content {
    position: relative;
    z-index: 1;
}

/* Améliorations du header - Logo géré par composant */

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.feature-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    margin-bottom: 20px;
}
