:root {
    --black: #000;
    --white: #fff;
    --blue: #4b76f1;
    --pink: #f14b4b;
    --yellow: #ffc05c;
    --font: 'Outfit', sans-serif;
}

* { margin:0; padding:0; box-sizing: border-box; font-family: var(--font); }
body { background: var(--white); overflow-x: hidden; }

/* NAVBAR & DROPDOWN RÉTABLI */
.navbar {
    position: fixed; width:100%; display:flex; justify-content:space-between; 
    padding:20px 5%; background: rgba(255,255,255,0.95); z-index:1000; border-bottom:3px solid #000;
}
.nav-links { display:flex; list-style:none; gap:25px; align-items: center; }
.nav-links a { text-decoration:none; color:#000; font-weight:900; font-size:0.8rem; text-transform: uppercase; }

/* Style du Dropdown */
.dropdown { position: relative; }
.dropdown-content {
    display: none; 
    position: absolute; 
    background: #fff; 
    border: 3px solid #000; 
    min-width: 200px; 
    top: 100%; 
    left: 0;
    box-shadow: 8px 8px 0 var(--black);
    z-index: 1001;
}
.dropdown:hover .dropdown-content { display: block; }
.dropdown-content a { 
    display: block; 
    padding: 12px; 
    border-bottom: 1px solid #eee; 
    text-transform: none;
    font-size: 0.85rem;
}
.dropdown-content a:hover { background: var(--yellow); color: #000; }

/* HERO & BOUTON STYLISÉ */
.hero { height:100vh; position:relative; display:flex; align-items:center; justify-content:center; }
#bg-video { position:absolute; top:0; left:0; width:100%; height:100%; object-fit:contain; z-index:-1; }
.scroll-btn-styled {
    display: inline-block; padding: 15px 35px; background: var(--white);
    color: var(--black); text-decoration: none; font-weight: 900;
    border: 3px solid var(--black); box-shadow: 10px 10px 0 var(--blue); transition: 0.2s;
}
.scroll-btn-styled:hover { transform: translate(5px, 5px); box-shadow: 0px 0px 0 var(--blue); }

/* ABOUT MONDRIAN */
/* SECTION À PROPOS - GRILLE ASYMÉTRIQUE (2, 3, 3) */
.section-padding { padding: 0px 6%;}
.about-mondrian { 
    display: grid; 
    grid-template-columns: repeat(6, 1fr); /* 6 colonnes pour plus de flexibilité */
    grid-auto-rows: 250px; 
    gap: 15px; 
}
.m-box { border:3px solid #000; overflow:hidden; background: #fff; display: flex; flex-direction: column; justify-content: center; }

/* Ligne 1 : 2 Blocs */
.photo { grid-column: span 3; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.bio { grid-column: span 3; padding: 40px; }

/* Ligne 2 : 3 Blocs (Inégaux) */
.stage-box { grid-column: span 3; padding: 30px; color: #fff; }
.fill-blue { grid-column: span 1; }
.fill-red { grid-column: span 2; }

/* Ligne 3 : 3 Blocs (Inégaux) */
.fill-yellow { grid-column: span 1; }
.fill-dark { grid-column: span 1; }
.alternance-box { grid-column: span 4; padding: 30px; color: #fff; }

.search-box h4 { font-size: 1.8rem; font-weight: 900; margin-bottom: 10px; border-bottom: 3px solid #fff; width: fit-content; }
.search-box p { font-size: 0.95rem; font-weight: 700; line-height: 1.4; }

/* EXPERTISE LOGICIELLE */
/* On change le conteneur pour permettre des tailles variées */
.skills-software { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); 
    grid-auto-rows: minmax(150px, auto); /* Permet aux boîtes de s'adapter au contenu */
    gap: 20px; 
    margin-top: 30px; 
}

.skill-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end; /* Texte en bas pour changer */
    padding: 25px;
    border: 3px solid #000;
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: #fff;
}

/* --- C'est ici qu'on casse le truc --- */

/* La 1ère boîte prend 2 colonnes */
.skill-item:nth-child(1) { grid-column: span 2; background: #fff; }

/* La 3ème boîte est plus haute */
.skill-item:nth-child(3) { grid-row: span 2; background: var(--yellow); }

/* La 4ème boîte a un fond noir texte blanc pour le contraste */
.skill-item:nth-child(4) { background: #000; color: #fff; }
.skill-item:nth-child(4) .skill-desc { color: #eee; }

/* Effet de décalage au survol */
.skill-item:hover {
    transform: translate(-5px, -5px);
    box-shadow: 8px 8px 0px #000;
    z-index: 10;
}

.skill-name {
    font-size: 1.4rem; /* Plus gros */
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.skill-desc {
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.3;
}/* BAG BENTO */
.bag-bento-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 140px; gap: 15px; margin-top: 30px;
}
.bento-item { border:3px solid #000; display:flex; align-items:center; justify-content:center; position: relative; background:#fff; overflow: hidden; transition: 0.4s; }
.bento-item img { max-width: 65%; max-height: 65%; object-fit: contain; pointer-events: none; }
.h-2 { grid-row: span 2; }
.w-2 { grid-column: span 2; }
.sac-trigger { grid-row: span 2; cursor: pointer; background: #f0f0f0; }
.main-bag-img { width: 60%; transition: 0.3s; animation: pulse 2s infinite; }
.asset { opacity: 0; transform: translateY(20px); pointer-events: none; }
.asset.active { opacity: 1; transform: translateY(0); pointer-events: auto; }
.info-box { grid-column: span 3; background: var(--black); color: var(--white); text-align: center; padding: 20px; font-weight: 900; }

/* DOMAINES - ANIMATION FLÈCHE EXPERT */
.domain-section { background: #000; }
.domain-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-bottom: 15px; }
.row-4 { grid-template-columns: repeat(4, 1fr); }
.domain-box { 
    height: 250px; border: 3px solid #fff; position: relative; overflow: hidden; 
    text-decoration: none; transition: 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    background-size: 105%; background-position: center;
}
.box-content { position: absolute; bottom: 20px; left: 20px; display: flex; align-items: center; gap: 10px; transition: 0.3s; }
.domain-box span { background:#fff; color:#000; font-weight:900; padding:8px 15px; font-size:0.8rem; transition: 0.3s; }
.arrow-icon {
    background: var(--pink); color: #fff; width: 35px; height: 35px; display: flex;
    align-items: center; justify-content: center; font-style: normal; font-weight: 900;
    opacity: 0; transform: translateX(-20px); transition: 0.3s; border: 2px solid #fff;
}
.domain-box:hover { background-size: 115%; border-color: var(--yellow); }
.domain-box:hover .box-content { transform: translateX(10px); }
.domain-box:hover .arrow-icon { opacity: 1; transform: translateX(0); }
.domain-box:hover span { background: var(--yellow); }
.no-hover { pointer-events: none; }

/* UTILS */
.blue-bg { background: var(--blue) !important; }
.red-bg { background: var(--pink) !important; }
.yellow-bg { background: var(--yellow) !important; }
.dark-bg { background: var(--black) !important; }
.white-text { color: #fff; margin-bottom: 30px; }
.title-left { font-size:2rem; font-weight:900; margin-bottom:30px; text-transform: uppercase; }

@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }

footer { display:flex; justify-content:space-between; padding:40px 8%; border-top:3px solid #000; }
.f-dots { display:flex; gap:10px; }
.dot { width:20px; height:20px; border:2px solid #000; }

/* --- CONTACT PAGE --- */
.contact-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: repeat(3, 100px);
    gap: 15px;
}
.form-container { grid-row: span 3; padding: 30px; border: 3px solid #000; }
.form-container input, .form-container textarea {
    width: 100%; padding: 15px; margin-bottom: 15px; border: 2px solid #000;
    font-family: var(--font); font-weight: 700; outline: none;
}
.reveal-links { display: flex; align-items: center; justify-content: center; border: 3px solid #000; }
.reveal-links a { text-decoration: none; color: #fff; font-weight: 900; font-size: 1.2rem; }

/* --- TEMPLATE PROJET --- */
/* --- PAGE CONTACT BENTO --- */
#titre-box{
    padding: 100px 6%;
}
.contact-bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 180px;
    gap: 15px;
}
.message-box { grid-column: span 3; padding: 40px; border: 3px solid #000; display: flex; flex-direction: column; justify-content: center; }
.status-badge { background: var(--pink); color: #fff; padding: 5px 10px; width: fit-content; font-weight: 900; font-size: 0.7rem; margin-top: 15px; }

.link-box { 
    text-decoration: none; padding: 30px; border: 3px solid #000; 
    display: flex; flex-direction: column; justify-content: space-between; 
    transition: 0.3s; color: #fff; 
}
.link-box:hover { transform: scale(0.98); filter: brightness(1.1); }
.link-box span { font-size: 0.6rem; opacity: 0.8; font-weight: 900; }
.link-box p { font-size: 1.2rem; font-weight: 900; }
.link-box i { align-self: flex-end; font-style: normal; font-weight: 900; font-size: 1.5rem; }

/* --- PROJET TEMPLATE --- */
.mondrian-header { display: flex; border: 3px solid #000; }
.m-title-box { flex: 3; padding: 30px; }
.m-filler { flex: 1; border-left: 3px solid #000; }
.category-tag { font-weight: 900; color: var(--pink); font-size: 0.8rem; }

.bento-details { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; margin-top: 15px; }
.detail-card { padding: 20px; border: 3px solid #000; color: #fff; }
.detail-card h4 { font-size: 1.2rem; opacity: 0.9; margin-bottom: 5px; }
.detail-card p { font-weight: 900; font-size: 0.9rem; }

/* Conteneur fluide */
.gallery-mini {
    column-count: 2; /* Nombre de colonnes (ajuste à 2 ou 4 selon tes goûts) */
    column-gap: 15px; /* Espace entre les colonnes */
    width: 100%;
    margin: 40px 0;
}

/* Style de chaque boîte */
.mini-box {
    display: inline-block; /* Indispensable pour que le column-count fonctionne */
    width: 100%; /* Prend toute la largeur de sa colonne */
    margin-bottom: 15px; /* Espace vertical entre les photos */
    border: 3px solid #000;
    background: #fff;
    line-height: 0; /* Supprime l'espace vide sous l'image */
    overflow: hidden;
    transition: transform 0.3s ease;
}

/* Les images gardent leur ratio d'origine */
.mini-box img {
    width: 100%;
    height: auto; /* Adapte la hauteur selon le format de la photo */
    display: block;
}

/* Hover pour rester dans ton style banger */
.mini-box:hover {
    transform: scale(1.02);
    border-color: var(--blue);
    z-index: 10;
}

/* Cas particulier pour tes blocs de couleur */
.mini-box.blue-bg {
    height: 200px; /* On leur donne quand même une hauteur fixe car ils n'ont pas d'image */
    background-color: var(--blue);
}

/* Responsive : On réduit à 2 colonnes sur tablette et 1 sur mobile */
@media (max-width: 900px) {
    .gallery-mini {
        column-count: 2;
    }
}

@media (max-width: 500px) {
    .gallery-mini {
        column-count: 1;
    }
}

.content-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; margin: 80px 0; align-items: flex-start; }
.text-block h3 { font-size: 1.5rem; font-weight: 900; text-transform: uppercase; margin-bottom: 20px; border-bottom: 5px solid var(--yellow); display: inline-block; }
.text-block p { line-height: 1.8; color: #333; }

.big-preview { border: 3px solid #000; height: 500px; overflow: hidden; margin: 40px 0; }
.big-preview img { width: 100%; height: 100%; object-fit: cover; }

/* --- CODE BLOCK --- */
.code-preview-container { margin-top: 60px; }
.code-block { background: #1a1a1a; color: #00ff95; padding: 30px; border: 3px solid #000; font-family: 'Courier New', monospace; overflow-x: auto; }

/* --- FOOTER --- */
footer { border-top: 3px solid #000; padding: 40px 8%; display: flex; justify-content: space-between; }
.social-link { text-decoration: none; color: #000; font-weight: 900; padding: 5px 15px; border: 2px solid #000; transition: 0.2s; font-size: 0.8rem; }
.social-link:hover { background: #000; color: #fff; }