:root {
    --bg-color: #f4f7f6;
    --accent-color: #e74c3c; /* Rouge bouton Home */
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --blue-tag: #3498db;
    --white: #ffffff;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-color);
    margin: 0;
    color: var(--text-dark);
}

/* Navbar Style */
.navbar {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.nav-container {
    background-color: #000;
    padding: 10px 30px;
    border-radius: 50px;
    display: flex;
    gap: 20px;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 15px;
    border-radius: 20px;
    transition: 0.3s;
}

.nav-link.active {
    background-color: var(--accent-color);
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 40px auto;
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 40px;
    padding: 0 20px;
}

/* Sidebar */
.sidebar {
    padding: 20px;
}

.avatar {
    width: 150px;
    height: 150px;
    border-radius: 20px;
    background-color: #000;
    object-fit: cover;
    margin-bottom: 20px;
}

.subtitle {
    color: var(--text-light);
    font-size: 0.9em;
    margin-bottom: 15px;
}

.location {
    font-size: 0.85em;
    color: var(--text-light);
    margin-bottom: 20px;
}

.social-icons {
    display: flex;
    gap: 15px;
    font-size: 1.2em;
    margin-bottom: 30px;
}

.social-icons a {
    color: #e67e22; /* Couleur orange des icones */
    text-decoration: none;
}

.about h2 {
    font-size: 1.5em;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

/* Experience Card */
.content {
    background: var(--white);
    border-radius: 30px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.section-title {
    text-align: center;
    font-size: 2em;
    color: #1a2a44;
    margin-bottom: 40px;
}

.exp-item {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
    background: #f8fafd;
    padding: 20px;
    border-radius: 15px;
}

.exp-date {
    min-width: 100px;
    color: #7d89ff;
    font-weight: bold;
    display: flex;
    flex-direction: column;
}

.exp-details h3 {
    margin: 0;
    color: #1a2a44;
}

.company {
    color: #3498db;
    text-decoration: underline;
}

.duration, .location-text {
    font-size: 0.85em;
    color: #7d89ff;
    margin: 5px 0;
}

ul {
    padding-left: 20px;
    margin: 15px 0;
}

li {
    margin-bottom: 8px;
    color: #444;
}

.tags {
    display: flex;
    gap: 10px;
}

.tag {
    background-color: var(--blue-tag);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8em;
}

/* --- Styles spécifiques à la page Projets --- */

.projects-container {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 colonnes sur PC */
    gap: 30px;
}

/* Style de la Carte */
.project-card {
    background-color: #2e3141; /* Couleur sombre du header de la carte */
    border-radius: 25px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
}

/* Header de la carte (Titre) */
.project-header {
    padding: 15px 20px;
    color: white;
    font-weight: bold;
    font-size: 0.95em;
    min-height: 45px;
    display: flex;
    align-items: center;
}

/* Corps de la carte (Image blanche) */
.project-body {
    background-color: white;
    margin: 0 10px 10px 10px; /* Marges internes pour l'effet de cadre */
    border-radius: 20px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.project-body img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Style spécifique pour la carte Portfolio */
.portfolio-preview {
    text-align: center;
}

.mini-avatar {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    background: black;
    margin-bottom: 10px;
}

.portfolio-preview p {
    font-weight: bold;
    font-size: 1.2em;
    margin: 0;
}

/* Responsivité (Mobile) */
@media (max-width: 900px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 colonnes sur tablette */
    }
}

@media (max-width: 600px) {
    .projects-grid {
        grid-template-columns: 1fr; /* 1 seule colonne sur mobile */
    }
}

/* --- Styles spécifiques à la page Contact --- */

.contact-container {
    display: flex;
    justify-content: center;
    padding: 40px 20px;
}

.contact-card {
    background: white;
    width: 100%;
    max-width: 800px;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
}

.main-title {
    color: #1a2a44;
    margin: 0;
    font-size: 1.8em;
}

.title-underline {
    border: none;
    border-top: 2px solid #3498db;
    width: 100%;
    margin: 15px 0 30px 0;
    opacity: 0.5;
}

h3 {
    color: #1a2a44;
    margin-bottom: 15px;
    font-size: 1.1em;
}

/* Boutons */
.button-group {
    display: flex;
    gap: 15px;
    margin-bottom: 40px;
}

.btn {
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9em;
    transition: 0.3s;
}

.btn-blue {
    background-color: #3498db;
    color: white;
}

.btn-blue-light {
    background-color: #5dade2;
    color: white;
}

.btn:hover {
    opacity: 0.8;
}

/* Grille de contact */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 40px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95em;
}

.contact-item a {
    text-decoration: none;
    color: inherit;
}

/* Couleurs des icônes */
.icon-li { color: #0077b5; }
.icon-git { color: #333; }
.icon-blue { color: #3498db; }

/* Formations */
.education-section {
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.education-item {
    border-left: 4px solid #3498db;
    padding-left: 15px;
    margin-bottom: 15px;
    background-color: #f9f9f9;
    padding: 10px 15px;
}

.education-item p {
    margin: 0;
    color: #555;
    font-size: 0.95em;
}

/* Mobile */
@media (max-width: 600px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .button-group {
        flex-direction: column;
    }
}

/* --- Correction pour enlever les lignes et couleurs de liens --- */

.project-card-link {
    text-decoration: none; /* Enlève le soulignement */
    color: inherit;        /* Empêche le texte de devenir bleu/violet */
    display: block;        /* Permet à tout le bloc d'être cliquable proprement */
}

/* Force l'état même après avoir cliqué */
.project-card-link:visited, 
.project-card-link:active {
    text-decoration: none;
    color: inherit;
}

/* Optionnel : pour garder le texte "Lepine Mattéo" en noir dans la carte Portfolio */
.portfolio-preview p {
    color: var(--text-dark);
    text-decoration: none;
}