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

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #0ea5e9;
    --dark: #0f172a;
    --gray: #64748b;
    --light-gray: #f1f5f9;
    --white: #ffffff;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark);
    overflow-x: hidden;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 15px 0;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo a {
    display: inline-block;
    line-height: 0;
}

.logo img {
    height: 70px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.nav {
    display: flex;
    gap: 25px;
    align-items: center;
}

.nav-link {
    color: var(--dark);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

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

.nav-link:hover::after {
    width: 100%;
}

/* Header / Hero */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    padding: 160px 20px 100px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::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"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

.hero-banner {
    max-width: 600px;
    width: 100%;
    height: auto;
    margin: 0 auto 30px;
    display: block;
    animation: fadeInUp 0.6s ease-out;
    border-radius: 16px;
    background: var(--white);
    padding: 10px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

.hero-banner:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 20px;
    animation: fadeInUp 0.8s ease-out;
}

.hero .subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    margin-bottom: 40px;
    opacity: 0.95;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.cta-button {
    display: inline-block;
    background: var(--white);
    color: var(--primary);
    padding: 16px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

/* Section Description */
.description {
    padding: 80px 20px;
    background: var(--white);
}

.description-content {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.description h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    color: var(--dark);
    margin-bottom: 50px;
}

.about-container {
    display: flex;
    align-items: center;
    gap: 50px;
    text-align: left;
}

.about-photo {
    flex-shrink: 0;
}

.about-photo img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border: 5px solid var(--light-gray);
    transition: transform 0.3s ease;
}

.about-photo img:hover {
    transform: scale(1.05);
}

.about-text {
    flex: 1;
}

.description p {
    font-size: 1.2rem;
    color: var(--gray);
    line-height: 1.8;
}

/* Services */
.services {
    padding: 80px 20px;
    background: var(--light-gray);
}

.services h2 {
    text-align: center;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 60px;
    color: var(--dark);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    background: var(--white);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    font-size: 2.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--dark);
}

.service-card p {
    color: var(--gray);
    line-height: 1.7;
}

/* Technologies */
.technologies {
    padding: 80px 20px;
    background: var(--white);
}

.technologies h2 {
    text-align: center;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 50px;
    color: var(--dark);
}

.tech-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.tech-tag {
    background: var(--light-gray);
    padding: 12px 25px;
    border-radius: 30px;
    font-weight: 500;
    color: var(--dark);
    transition: all 0.3s ease;
}

.tech-tag:hover {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.05);
}

/* CTA Section */
.cta-section {
    padding: 100px 20px;
    background: linear-gradient(135deg, var(--dark) 0%, #1e293b 100%);
    color: var(--white);
    text-align: center;
}

.cta-section h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    margin-bottom: 30px;
}

.cta-section p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.cta-button-secondary {
    display: inline-block;
    background: transparent;
    color: var(--white);
    padding: 16px 40px;
    border: 2px solid var(--white);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    margin: 0 10px;
}

.cta-button-secondary:hover {
    background: var(--white);
    color: var(--dark);
}

/* Contact Form */
.contact-form {
    max-width: 700px;
    margin: 50px auto 0;
    text-align: left;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.15);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form button[type="submit"] {
    width: 100%;
    margin-top: 10px;
    cursor: pointer;
    border: 2px solid var(--white);
}

.contact-form button[type="submit"]:hover {
    background: var(--white);
    color: var(--dark);
    transform: translateY(-2px);
}

.contact-form button[type="submit"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Messages de formulaire */
.form-message {
    max-width: 700px;
    margin: 20px auto;
    padding: 16px 20px;
    border-radius: 12px;
    font-size: 1rem;
    text-align: center;
    animation: slideDown 0.3s ease-out;
}

.form-message.success {
    background: rgba(34, 197, 94, 0.2);
    border: 2px solid rgba(34, 197, 94, 0.5);
    color: #22c55e;
}

.form-message.error {
    background: rgba(239, 68, 68, 0.2);
    border: 2px solid rgba(239, 68, 68, 0.5);
    color: #ef4444;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Footer */
footer {
    background: var(--dark);
    color: var(--white);
    padding: 30px 20px;
    text-align: center;
}

footer p {
    opacity: 0.7;
}

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

/* Bouton retour en haut */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(99, 102, 241, 0.4);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.5);
}

/* Responsive */
@media (max-width: 768px) {
    .header {
        padding: 10px 0;
    }

    .logo img {
        height: 55px;
    }

    .nav {
        gap: 15px;
    }

    .nav-link {
        font-size: 0.85rem;
    }

    .nav-link::after {
        display: none;
    }

    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }

    .hero {
        padding: 140px 20px 60px;
    }

    .hero-banner {
        max-width: 90%;
        padding: 8px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .cta-button-secondary {
        display: block;
        margin: 10px auto;
        max-width: 300px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .about-container {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }

    .about-photo img {
        width: 150px;
        height: 150px;
    }
}

/* Stats Section */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 60px auto 0;
    text-align: center;
}

.stat-item {
    padding: 20px;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    color: var(--white);
    opacity: 0.95;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.8;
    margin-top: 5px;
}

/* Très petits écrans */
@media (max-width: 480px) {
    .header-container {
        padding: 0 10px;
    }

    .logo img {
        height: 45px;
    }

    .nav {
        gap: 8px;
    }

    .nav-link {
        font-size: 0.75rem;
        padding: 5px 8px;
    }
}
