/* ========================================
   LAPTOP MOCKUP STYLES - AVEC IFRAME
   ======================================== */

body {
    background-color: #FFFCF6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1; /* pousse le footer en bas si le contenu est court */
}

/* FONTS */
@font-face {
    font-family: 'Barbra';
    src: url('../fonts/barbra-font/Barbra-Regular.ttf') format('truetype');
    font-display: swap;
}

@font-face {
    font-family: 'Inter';
    src: url('../fonts/Inter/Inter-VariableFont_opsz\,wght.ttf') format('truetype');
    font-display: swap;
}

h1 {
    display: none;
}

/* TITRE */
.titre {
    text-align: center;
    margin-top: 30px;
    margin-bottom: 40px;
}

.titre h2, 
.titre h3 {
    display: inline-block;
    vertical-align: middle;
    margin: 0;
}

.titre h2 {
    font-family: 'Inter', sans-serif;
    font-size: 3rem;
    color: #101211;
    margin-right: 10px;
}

.titre h3 {
    font-family: 'Barbra', sans-serif;
    font-size: 3rem;
    color: #49252F;
}

.accordion {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 10px; /* réduit les marges latérales */
}

.accordion-card {
    background-color: #EBD3BB;
    border-radius: 16px;
    margin-bottom: 1.5rem;
    overflow: hidden;
    transition: all 0.3s ease;
    padding: 0; /* supprime padding interne inutile */
}

.accordion-header {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.accordion-actions {
    display: flex;
    align-items: center;
    gap: 15px; /* espace entre le bouton et la croix */
}

/* Logo */
.accordion-logo {
    max-width: 80px;
    max-height: 80px;
    border-radius: 50%;
    margin-right: 1.5rem; /* logo un peu plus à droite */
}

/* Wrapper titre + aperçu */
.accordion-title-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
}

.accordion-preview {
    font-size: 0.9rem;
    color: #333;
    margin-top: 0.3rem;
}

/* Lien plus joli */
.accordion-link {
    padding: 6px 12px;
    background-color: #49252F;
    color: #FFFCF6;
    border-radius: 25px;
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.accordion-link:hover {
    background-color: #101211;
}

/* TOGGLE */
.accordion-toggle {
    font-size: 2rem;
    font-weight: bold;
    transition: transform 0.3s ease;
}
.accordion-card.active .accordion-toggle {
    transform: rotate(45deg);
}

/* CONTENU ACCORDÉON */
.accordion-content {
    max-height: 0;
    overflow: hidden;
    padding: 0 1.5rem;
    transition: max-height 0.4s ease, padding 0.4s ease;
}
.accordion-card.active .accordion-content {
    max-height: 1200px; /* plus de place pour iframe desktop */
    padding: 1rem 1.5rem;
}

/* TECHNOLOGIES */
.techno-list {
    margin-top: 0.8rem;
    text-align: center;
}

.techno-badge {
    display: inline-block;
    margin: 0.3rem;
    padding: 0.4rem 0.8rem;
    background-color: #FFFCF6;
    border-radius: 25px;
    color: #49252F;
    font-weight: 600;
}

/* BOUTON CONTACT */
.btn-tarif-contact {
    display: flex;
    justify-content: center;
    margin: 60px 0 40px;
}
.btn-tarif-contact a {
    padding: 12px 30px;
    background-color: #49252F;
    color: #FFFCF6;
    border-radius: 40px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}
.btn-tarif-contact a:hover {
    background-color: #101211;
}

/* === MACBOOK FRAME === */
.macbook-frame {
    width: 100%;
    max-width: 900px;
    margin: 1rem auto 0 auto;
    padding: 10px; /* réduit l'espace blanc autour de l'iframe */
    background: #fff;
    border-radius: 25px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    position: relative;
}

/* Barre MacBook */
.macbook-top-bar {
    height: 20px;
    width: 100%;
    background: #333;
    border-radius: 12px 12px 0 0;
    position: absolute;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    padding-left: 12px;
    gap: 8px;
}

/* Les “boutons Mac” */
.macbook-top-bar::before,
.macbook-top-bar::after,
.macbook-top-bar span {
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
}
.macbook-top-bar::before { background: #ff605c; }   /* rouge */
.macbook-top-bar::after { background: #ffbd44; }    /* orange */
.macbook-top-bar span { background: #00ca4e; }      /* vert */

/* IFRAME DANS MACBOOK */
.macbook-frame .project-iframe {
    width: 100%;
    height: 650px; /* desktop view */
    margin-top: 20px; /* espace pour la barre */
    border-radius: 12px;
    border: 1px solid #ccc;
}

/* MEDIA QUERY */
/* Tablette large - 1024px */
@media (max-width: 1024px) {
    .accordion {
        padding: 0 15px;
    }

    .accordion-logo {
        max-width: 70px;
        max-height: 70px;
        margin-right: 1rem;
    }

    .accordion-title-wrapper h3 {
        font-size: 1.8rem;
    }

    .accordion-preview {
        font-size: 0.85rem;
    }

    .macbook-frame {
        max-width: 800px;
    }

    .macbook-frame .project-iframe {
        height: 600px;
    }
}

/* Tablette moyenne - 768px */
@media (max-width: 768px) {
    .accordion {
        padding: 0 10px;
    }

    .accordion-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .accordion-actions {
        margin-top: 0.5rem;
    }

    .accordion-logo {
        max-width: 60px;
        max-height: 60px;
        margin-right: 0.8rem;
    }

    .accordion-title-wrapper h3 {
        font-size: 1.6rem;
    }

    .accordion-preview {
        font-size: 0.8rem;
    }

    .macbook-frame {
        max-width: 700px;
        padding: 8px;
    }

    .macbook-frame .project-iframe {
        height: 500px;
    }
}

/* Mobile - 480px */
@media (max-width: 480px) {
    .accordion-card {
        position: relative; /* pour que la croix soit positionnée par rapport à la carte */
    }

    .accordion-header {
        flex-direction: column;
        align-items: flex-start;
        padding: 1rem;
    }

    .accordion-toggle {
        position: absolute;
        top: 10px;
        right: 10px;
        font-size: 1.8rem;
    }

    .accordion-actions {
        margin-top: 0.5rem;
        gap: 10px;
    }

    .accordion-logo {
        max-width: 50px;
        max-height: 50px;
        margin-right: 0.5rem;
    }

    .accordion-title-wrapper {
        width: 100%;
    }

    .accordion-title-wrapper h3 {
        font-size: 1.4rem;
    }

    .accordion-preview {
        font-size: 0.75rem;
    }

    .accordion-link {
        font-size: 0.8rem;
        padding: 5px 10px;
    }

    .macbook-frame {
        max-width: 100%;
        padding: 5px;
    }

    .macbook-frame .project-iframe {
        height: 550px;
    }
}