:root {
    --primary: #833ab4;
    --secondary: #fd1d1d;
    --accent: #fcb045;
    --bg: #050505;
    --glass: rgba(255, 255, 255, 0.03);
    --border: rgba(255, 255, 255, 0.1);
    --text-dim: #94a3b8;
}

* { margin: 0; padding: 0; box-sizing: border-box; cursor: none; }
html { scroll-behavior: smooth; }
body { background-color: var(--bg); color: #fff; font-family: 'Plus Jakarta Sans', sans-serif; overflow-x: hidden; }

/* --- CURSEUR & BACKGROUND --- */
#cursor { 
    width: 15px; 
    height: 15px; 
    background: white; 
    border-radius: 50%; 
    position: fixed; 
    pointer-events: none; 
    z-index: 99999; 
    mix-blend-mode: difference; 
    transition: transform 0.1s ease; 
}

.blob { 
    position: fixed; 
    width: 600px; 
    height: 600px; 
    background: linear-gradient(to right, var(--primary), var(--secondary)); 
    filter: blur(100px); 
    border-radius: 50%; 
    z-index: -1; 
    opacity: 0.15; 
    animation: move 25s infinite alternate; 
}

@keyframes move { 
    from { transform: translate(-10%, -10%); } 
    to { transform: translate(80%, 40%); } 
}

/* --- NAVIGATION --- */
nav { 
    padding: 25px 5%; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    position: fixed; 
    width: 100%; 
    z-index: 1000; 
    backdrop-filter: blur(15px); 
    border-bottom: 1px solid var(--border); 
}

.logo { 
    font-family: 'Syne'; 
    font-weight: 800; 
    font-size: 1.4rem; 
    text-transform: uppercase; 
}

.nav-links { 
    display: flex; 
    gap: 30px; 
    align-items: center; 
}

.nav-links a { 
    color: white; 
    text-decoration: none; 
    font-size: 0.9rem; 
    opacity: 0.7; 
    transition: 0.3s; 
    font-family: 'Syne'; 
}

.nav-links a:hover, 
.nav-links a.active { 
    opacity: 1; 
    color: var(--accent); 
}

/* --- GLOBAL --- */
.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 20px; 
}

/* Correction du bouton Contact */
.btn-main { 
    padding: 12px 30px; 
    background: white; 
    color: black !important; 
    border-radius: 50px; 
    text-decoration: none; 
    font-weight: 800; 
    text-transform: uppercase; 
    transition: 0.3s; 
    display: inline-block; 
    font-size: 0.8rem; 
    border: none; 
    text-align: center;
    opacity: 1 !important;
}

.btn-main:hover { 
    transform: scale(1.05) rotate(-2deg); 
    background: var(--accent); 
    box-shadow: 0 0 20px rgba(252, 176, 69, 0.4); 
}

.btn-main2 {
    padding: 12px 30px;
    background: white;
    color: white !important;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 800;
    text-transform: uppercase;
    transition: 0.3s;
    display: inline-flex;           
    align-items: center;             
    justify-content: center;         
    gap: 8px;                        
    font-size: 0.8rem;
    border: none;
    text-align: center;
    opacity: 1 !important;
}

.btn-main2:hover { 
    transform: scale(1.05) rotate(-2deg); 
    background: var(--accent); 
    box-shadow: 0 0 20px rgba(252, 176, 69, 0.4); 
}

/* Nouveau style pour le lien secondaire "Voir mes travaux" */
.btn-secondary {
    color: white;
    text-decoration: none;
    font-weight: 600;
    margin-left: 20px;
    position: relative;
    padding: 5px 0;
    transition: 0.3s;
}

.btn-secondary::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--accent);
    transition: width 0.3s ease;
}

.btn-secondary:hover {
    color: var(--accent);
    padding-left: 10px;
}

.btn-secondary:hover::after {
    width: 100%;
}

.tag { 
    font-size: 0.7rem; 
    text-transform: uppercase; 
    font-weight: 700; 
    color: var(--accent); 
    border: 1px solid var(--accent); 
    padding: 4px 12px; 
    border-radius: 50px; 
    display: inline-block; 
    margin-bottom: 15px; 
}

/* --- PORTFOLIO --- */
.portfolio-cascade { 
    display: flex; 
    flex-direction: column; 
    gap: 120px; 
    padding-bottom: 100px; 
}

.work-item { 
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 60px; 
    align-items: center; 
}

.work-img { 
    width: 100%; 
    height: 450px; 
    background: var(--glass); 
    border-radius: 30px; 
    border: 1px solid var(--border); 
    overflow: hidden; 
    position: relative; 
}

.work-img img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    opacity: 0.6; 
    transition: 0.5s; 
}

.work-item:hover img { 
    opacity: 1; 
    transform: scale(1.05); 
}

/* --- SERVICES & PRICING --- */
.pricing-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); 
    gap: 40px; 
    margin-top: 50px; 
}

.price-card { 
    background: var(--glass); 
    border: 1px solid var(--border); 
    padding: 50px; 
    border-radius: 40px; 
    transition: 0.3s; 
    position: relative; 
    overflow: hidden; 
}

.price-card:hover { 
    border-color: var(--primary); 
    transform: translateY(-10px); 
}

.demo-section { 
    margin-top: 100px; 
}

.demo-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 30px; 
}

.demo-card { 
    background: var(--glass); 
    border: 1px solid var(--border); 
    border-radius: 20px; 
    overflow: hidden; 
    height: 400px; 
    position: relative; 
    transition: 0.4s; 
}

.demo-card:hover { 
    transform: translateY(-10px); 
    border-color: var(--accent); 
}

.browser-header { 
    background: rgba(255,255,255,0.05); 
    padding: 10px 15px; 
    display: flex; 
    gap: 5px; 
    border-bottom: 1px solid var(--border); 
}

.dot { 
    width: 8px; 
    height: 8px; 
    border-radius: 50%; 
    background: #5f5f5f; 
}

.dot.r { background: #ff5f56; } 
.dot.y { background: #ffbd2e; } 
.dot.g { background: #27c93f; }

.demo-content { 
    height: 100%; 
    background-size: cover; 
    background-position: center; 
    position: relative; 
    display: flex; 
    align-items: flex-end; 
    padding: 20px; 
}

.demo-overlay { 
    position: absolute; 
    inset: 0; 
    background: rgba(0,0,0,0.8); 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
    align-items: center; 
    opacity: 0; 
    transition: 0.3s; 
    backdrop-filter: blur(5px); 
    text-align: center; 
    padding: 20px; 
}

.demo-card:hover .demo-overlay { 
    opacity: 1; 
}

/* --- CONTACT FORM --- */
.contact-wrapper { 
    max-width: 800px; 
    margin: 0 auto; 
    background: var(--glass); 
    padding: 60px; 
    border-radius: 40px; 
    border: 1px solid var(--border); 
}

.form-group { 
    margin-bottom: 30px; 
    position: relative; 
}

.form-input { 
    width: 100%; 
    background: transparent; 
    border: none; 
    border-bottom: 1px solid var(--border); 
    padding: 15px 0; 
    color: white; 
    font-size: 1.1rem; 
    outline: none; 
    transition: 0.3s; 
    font-family: 'Plus Jakarta Sans'; 
}

.form-input:focus { 
    border-color: var(--accent); 
}

.form-label { 
    position: absolute; 
    left: 0; 
    top: 15px; 
    color: var(--text-dim); 
    transition: 0.3s; 
    pointer-events: none; 
}

.form-input:focus ~ .form-label, 
.form-input:valid ~ .form-label { 
    top: -10px; 
    font-size: 0.8rem; 
    color: var(--accent); 
}

/* --- PAGE CV / A PROPOS --- */
.about-hero { 
    text-align: center; 
    margin-bottom: 80px; 
}

.about-hero h1 { 
    font-family: 'Syne'; 
    font-size: clamp(2.5rem, 6vw, 5rem); 
    text-transform: uppercase; 
    margin-bottom: 20px; 
}

.about-badge { 
    background: rgba(253, 29, 29, 0.2); 
    color: #ff6b6b; 
    padding: 5px 15px; 
    border-radius: 50px; 
    border: 1px solid #ff6b6b; 
    font-size: 0.8rem; 
    font-weight: 700; 
    display: inline-block; 
    margin-bottom: 20px; 
}

/* Animation Tech Stack */
.tech-slider { 
    overflow: hidden; 
    white-space: nowrap; 
    position: relative; 
    padding: 40px 0; 
}

.tech-slider:before, 
.tech-slider:after { 
    content: ""; 
    position: absolute; 
    top: 0; 
    width: 150px; 
    height: 100%; 
    z-index: 2; 
}

.tech-slider:before { 
    left: 0; 
    background: linear-gradient(to right, var(--bg), transparent); 
}

.tech-slider:after { 
    right: 0; 
    background: linear-gradient(to left, var(--bg), transparent); 
}

.tech-track { 
    display: inline-block; 
    animation: scroll 20s linear infinite; 
}

.tech-item { 
    display: inline-flex; 
    align-items: center; 
    gap: 10px; 
    margin: 0 30px; 
    font-family: 'Syne'; 
    font-size: 1.5rem; 
    color: var(--text-dim); 
    transition: 0.3s; 
}

.tech-item:hover { 
    color: var(--accent); 
    transform: scale(1.1); 
    text-shadow: 0 0 10px var(--accent); 
}

@keyframes scroll { 
    from { transform: translateX(0); } 
    to { transform: translateX(-50%); } 
}

/* Timeline Design */
.timeline { 
    position: relative; 
    max-width: 800px; 
    margin: 0 auto; 
    padding: 40px 0; 
}

.timeline::before { 
    content: ''; 
    position: absolute; 
    left: 50%; 
    width: 2px; 
    height: 100%; 
    background: var(--border); 
    top: 0; 
}

.timeline-item { 
    padding: 20px 40px; 
    position: relative; 
    width: 50%; 
}

.timeline-item:nth-child(odd) { 
    left: 0; 
    text-align: right; 
}

.timeline-item:nth-child(even) { 
    left: 50%; 
    text-align: left; 
}

.timeline-item::after { 
    content: ''; 
    position: absolute; 
    width: 20px; 
    height: 20px; 
    background: var(--accent); 
    border-radius: 50%; 
    top: 25px; 
    border: 4px solid var(--bg); 
    z-index: 10; 
}

.timeline-item:nth-child(odd)::after { 
    right: -10px; 
}

.timeline-item:nth-child(even)::after { 
    left: -10px; 
}

.timeline-content { 
    padding: 30px; 
    background: var(--glass); 
    border-radius: 20px; 
    border: 1px solid var(--border); 
    transition: 0.3s; 
}

.timeline-content:hover { 
    border-color: var(--primary); 
    transform: translateY(-5px); 
}

.date { 
    color: var(--accent); 
    font-weight: 700; 
    font-family: 'Syne'; 
    margin-bottom: 10px; 
    display: block; 
}

/* --- MENU DÉROULANT --- */
.dropdown { 
    position: relative; 
    display: inline-block; 
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: rgba(5, 5, 5, 0.98);
    min-width: 220px;
    border: 1px solid var(--border);
    border-radius: 12px;
    z-index: 1000;
    top: 40px;
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 0;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.dropdown::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 35px;
    display: none;
}   

.dropdown:hover .dropdown-content,
.dropdown:hover::after {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

.dropdown-content a { 
    color: white; 
    padding: 12px 20px; 
    text-decoration: none; 
    display: block; 
    font-size: 0.9rem; 
    transition: 0.2s; 
}

.dropdown-content a:hover { 
    background: var(--glass); 
    color: var(--accent); 
    padding-left: 25px; 
}

/* --- TABLES --- */
.styled-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin: 25px 0; 
    font-size: 0.9em; 
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.15); 
    border: 1px solid var(--border); 
}

.styled-table thead tr { 
    background-color: var(--primary); 
    color: #ffffff; 
    text-align: left; 
}

.styled-table th, 
.styled-table td { 
    padding: 12px 15px; 
    border-bottom: 1px solid var(--border); 
}

.styled-table tbody tr:hover { 
    background-color: var(--glass); 
    color: var(--accent); 
}

/* --- FOOTER --- */
footer { 
    padding: 80px 0; 
    text-align: center; 
    border-top: 1px solid var(--border); 
    margin-top: 100px; 
    opacity: 0.5; 
}

/* --- STYLES POUR QUALITÉS ET CENTRES D'INTÉRÊT --- */
section [style*="display: grid"] > div:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(131, 58, 180, 0.2);
}

section [style*="display: grid"] > div {
    transition: all 0.3s ease;
}

section [style*="display: grid"] > div i {
    transition: all 0.3s ease;
}

section [style*="display: grid"] > div:hover i {
    transform: scale(1.1) rotate(5deg);
}

/* =====================================================
   RESPONSIVE MEDIA QUERIES
   ===================================================== */

/* --- TABLETTES (max-width: 1024px) --- */
@media (max-width: 1024px) {
    .container {
        padding: 0 30px;
    }

    .nav-links {
        gap: 20px;
    }

    .nav-links a {
        font-size: 0.85rem;
    }

    .work-item {
        gap: 40px;
    }

    .work-img {
        height: 350px;
    }

    .pricing-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 30px;
    }

    .price-card {
        padding: 40px;
    }

    .contact-wrapper {
        padding: 50px;
    }
}

/* --- TABLETTES ET PETITS ÉCRANS (max-width: 768px) --- */
@media (max-width: 768px) {
    /* Désactiver le curseur custom sur mobile */
    * {
        cursor: auto !important;
    }

    #cursor {
        display: none;
    }

    /* Navigation */
    nav {
        padding: 20px 4%;
        flex-direction: column;
        gap: 15px;
    }

    .logo {
        font-size: 1.2rem;
    }

    .nav-links {
        flex-direction: column;
        gap: 12px;
        width: 100%;
        text-align: center;
    }

    .dropdown {
        width: 100%;
    }

    .dropdown-content {
        position: relative;
        top: 0;
        left: 0;
        transform: none;
        width: 100%;
        margin-top: 10px;
    }

    .btn-main {
        padding: 10px 20px;
        font-size: 0.75rem;
        margin-left: 0 !important;
    }

    /* Container et sections */
    .container {
        padding: 0 20px;
    }

    main.container[style*="padding-top: 150px"] {
        padding-top: 180px !important;
    }

    /* Hero section */
    section[style*="height: 90vh"] {
        height: auto !important;
        min-height: 80vh;
        padding: 60px 0;
    }

    .btn-secondary {
        margin-left: 0;
        margin-top: 10px;
        display: block;
    }

    /* Work items / Portfolio */
    .work-item {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .work-img {
        height: 280px;
    }

    /* Timeline */
    .timeline::before {
        left: 30px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
        text-align: left;
    }

    .timeline-item:nth-child(odd) {
        left: 0;
        text-align: left;
    }

    .timeline-item::after {
        left: 21px;
    }

    .timeline-item:nth-child(odd)::after {
        left: 21px;
        right: auto;
    }

    /* À propos - grids */
    section[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }

    /* Contact form */
    .contact-wrapper {
        padding: 30px;
    }

    .form-input {
        font-size: 1rem;
    }

    /* Pricing & Demo grids */
    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .demo-grid {
        grid-template-columns: 1fr;
    }

    /* Tech slider */
    .tech-item {
        font-size: 1.2rem;
        margin: 0 20px;
    }

    /* Tableau */
    .styled-table {
        font-size: 0.75em;
    }

    .styled-table th,
    .styled-table td {
        padding: 8px 10px;
    }

    /* CV iframe */
    div[style*="height: 800px"] {
        height: 500px !important;
    }

    /* Blob background */
    .blob {
        width: 400px;
        height: 400px;
    }

    /* Footer */
    footer {
        padding: 50px 0;
        margin-top: 60px;
    }
}

/* --- MOBILES (max-width: 480px) --- */
@media (max-width: 480px) {
    .logo {
        font-size: 1rem;
    }

    .nav-links a {
        font-size: 0.8rem;
    }

    /* Hero */
    .about-hero h1 {
        font-size: clamp(2rem, 8vw, 3rem);
    }

    /* Boutons */
    .btn-main,
    .btn-main2 {
        padding: 10px 20px;
        font-size: 0.7rem;
        width: 100%;
        display: block;
        text-align: center;
    }

    div[style*="display: flex"][style*="gap: 20px"] a {
        display: block;
        width: 100%;
        margin: 10px 0;
    }

    /* Contact */
    .contact-wrapper {
        padding: 25px;
    }

    /* Grids auto-fit */
    div[style*="grid-template-columns: repeat(auto-fit, minmax(250px, 1fr))"],
    div[style*="grid-template-columns: repeat(auto-fit, minmax(280px, 1fr))"] {
        grid-template-columns: 1fr !important;
    }

    /* Work images */
    .work-img {
        height: 220px;
    }

    /* Timeline content */
    .timeline-content {
        padding: 20px;
    }

    /* Blob */
    .blob {
        width: 300px;
        height: 300px;
    }

    /* Tech slider */
    .tech-slider:before,
    .tech-slider:after {
        width: 50px;
    }

    .tech-item {
        font-size: 1rem;
        margin: 0 15px;
    }

    /* Espacement général */
    section {
        margin-bottom: 60px !important;
    }

    .portfolio-cascade {
        gap: 60px;
    }

    /* Badges et petits éléments */
    .about-badge {
        font-size: 0.7rem;
        padding: 4px 12px;
    }

    /* Prix cards */
    .price-card {
        padding: 30px;
    }

    /* Demo cards */
    .demo-card {
        height: 300px;
    }
}

/* --- TRÈS PETITS ÉCRANS (max-width: 360px) --- */
@media (max-width: 360px) {
    .container {
        padding: 0 15px;
    }

    .contact-wrapper {
        padding: 20px;
    }

    .timeline-item {
        padding-left: 60px;
        padding-right: 15px;
    }

    .styled-table {
        font-size: 0.7em;
    }

    .work-img {
        height: 200px;
    }
}