/* --- VARIABLES --- */
:root {
    --bg-color: #F8F7F2; 
    --primary-color: #014948; 
    --accent-color: #E27D60; 
    --text-color: #2D312E; 
    --border-color: #E2DFD6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- EN-TÊTE --- */
header {
    padding: 1.2rem 5%;
    background-color: var(--primary-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    color: #FFF;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--accent-color);
}

/* --- SECTIONS --- */
section {
    padding: 4.5rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-coloree {
    background-color: #EFECE1; 
    max-width: 100%; 
    padding-left: max(5%, calc((100vw - 1200px) / 2));
    padding-right: max(5%, calc((100vw - 1200px) / 2));
}

h2 {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 2.5rem;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 3px;
    background-color: var(--accent-color);
}

/* --- PRÉSENTATION --- */
.presentation-contenu {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    min-height: 50vh;
}

.texte { flex: 1; }

.texte h1 {
    font-size: 3.5rem;
    color: var(--primary-color);
    line-height: 1.1;
    margin-bottom: 0.5rem;
}

.texte h4 {
    font-size: 1.1rem;
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.photo-profil {
    width: 280px;
    height: 380px;
    background-color: var(--primary-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFF;
    box-shadow: 10px 10px 0px var(--accent-color);
    overflow: hidden;
    flex-shrink: 0;
}

.photo-profil img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
}

.btn-projets {
    display: inline-block;
    background-color: var(--primary-color);
    color: #FFF;
    padding: 0.8rem 1.8rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.btn-projets:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

/* --- COMPÉTENCES --- */
.competences-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.competence-card {
    background-color: var(--bg-color);
    padding: 2rem;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.competence-card h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1.2rem;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tags span {
    padding: 0.4rem 0.9rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: default;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.tags span:hover {
    background-color: var(--accent-color) !important;
    transform: translateY(-2px);
}

.tag-logiciel {
    background-color: #014948;
    color: #FFF;
}

.tag-comm {
    background-color: #E27D60;
    color: #FFF;
}

.tag-dev {
    background-color: #386641;
    color: #FFF;
}

/* --- PROJETS EN SCROLL --- */
.liste-projets {
    display: flex;
    flex-direction: column;
    gap: 5rem;
}

.projet-row {
    display: flex;
    align-items: center;
    gap: 4rem;
}

.projet-row.inverse {
    flex-direction: row-reverse;
}

.projet-texte {
    flex: 1;
}

.categorie {
    color: var(--accent-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 0.8rem;
    display: block;
    margin-bottom: 0.4rem;
}

.projet-texte h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 0.8rem;
}

.projet-texte p {
    font-size: 1rem;
    color: #555;
}

/* Style du lien dans le texte F1 */
.lien-texte {
    color: var(--accent-color);
    font-weight: 700;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.lien-texte:hover {
    color: var(--primary-color);
}

.projet-visuel-container {
    flex: 1.4;
    width: 100%;
}

.projet-visuel {
    background-color: transparent;
    display: block;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    width: 100%;
}

.sans-bordure {
    border: none !important;
    background-color: transparent !important;
}

.projet-visuel img {
    width: 100%;
    height: auto;
    display: block;
}

.projet-visuel iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

.container-short .projet-visuel {
    max-width: 320px;
    margin: 0 auto;
}

.duo-videos {
    display: flex;
    gap: 1.5rem;
}

.lien-externe-btn {
    display: inline-block;
    color: var(--accent-color);
    font-weight: bold;
    text-decoration: none;
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 2px;
}

.lien-externe-btn:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

/* --- DUOS & CARROUSELS --- */
.projet-duo-container {
    margin: 0;
}

.duo-titre-centre {
    text-align: center;
    margin-bottom: 2rem;
}

.duo-titre-centre h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-top: 0.3rem;
}

.duo-images {
    display: flex;
    gap: 2rem;
    justify-content: center;
}

.duo-images.align-center {
    align-items: center;
}

.affiches-reduites {
    max-width: 800px;
    margin: 0 auto;
}

.duo-images .projet-visuel {
    flex: 1;
}

/* Carrousel en taille classique (1200px max) */
.carrousel-grand {
    width: 100%; 
    max-width: 1200px;
    margin: 0 auto;
}

/* --- CONTACT & FOOTER --- */
#contact {
    text-align: center;
}

/* On centre aussi la petite ligne orange sous le titre "Me contacter" */
#contact h2::after {
    left: 50%;
    transform: translateX(-50%);
}

.infos-contact p {
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
}

/* Liens dans Contact */
.infos-contact a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.infos-contact a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

footer {
    text-align: center;
    padding: 1.5rem;
    background-color: var(--primary-color);
    color: #FFF;
    font-size: 0.85rem;
}
/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .presentation-contenu, .projet-row, .projet-row.inverse {
        flex-direction: column;
        text-align: center;
    }
    
    h2::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .duo-images {
        flex-direction: column;
        align-items: center;
    }

    .duo-images .projet-visuel {
        width: 100%;
    }
}