/* ===================== BASES TYPOGRAPHIQUES & COULEURS ===================== */
.contact {
    font-family: 'Inter', 'Segoe UI', 'Roboto', system-ui, sans-serif;
    background: #fefefe;
    padding: 3rem 0;
    color: #1f2d3d;
}

/* Titre principal */
.contact .section-title {
    font-size: clamp(2rem, 6vw, 2.8rem);
    font-weight: 700;
    color: #0f2b3d;
    text-align: center;
    letter-spacing: -0.01em;
    margin-bottom: 0.5rem;
    border-bottom: none;
}

.contact .section-subtitle {
    font-size: 1.1rem;
    color: #4a627a;
    text-align: center;
    max-width: 680px;
    margin: 0 auto 2.5rem auto;
    font-weight: 400;
}

/* Titres de grandes sections (ex: Formations & Expériences) */
.contact .section-heading {
    font-size: 1.6rem;
    font-weight: 600;
    color: #1f3b4c;
    margin: 2rem 0 1.2rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #9b2c3d;
    display: inline-block;
    letter-spacing: -0.2px;
}

/* Sous-titres (Diplômes, Formations complémentaires, etc.) */
.sub-heading {
    font-size: 1.35rem;
    font-weight: 600;
    color: #2c4c6c;
    margin: 1.8rem 0 1rem 0;
    padding-left: 0.5rem;
    border-left: 5px solid #9b2c3d;
}

.sub-sub-heading {
    font-size: 1.05rem;
    font-weight: 500;
    color: #3e6a8c;
    margin: 1rem 0 0.5rem 1rem;
}

/* ===================== CONTENEURS DES SECTIONS ===================== */
.section-group {
    background: #ffffff;
    border-radius: 20px;
    padding: 0.8rem 1.8rem 1.5rem 1.8rem;
    margin-bottom: 2rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02), 0 1px 1px rgba(0, 0, 0, 0.02);
    transition: box-shadow 0.2s;
}

.section-group:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.sub-section {
    margin-bottom: 1.8rem;
}

/* ===================== ACCORDÉONS (CARDS) ===================== */
.contact .item {
    background: #fff;
    border-radius: 14px;
    margin-bottom: 1rem;
    border: 1px solid #e9edf2;
    overflow: hidden;
    transition: all 0.2s ease;
    cursor: pointer;
}

.contact .item:hover {
    border-color: #cdd7e3;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transform: translateY(-1px);
}

.contact .item-header {
    padding: 0.9rem 1.3rem;
    background: #ffffff;
    font-weight: 600;
    font-size: 1rem;
    color: #1f3b4c;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f0f2f5;
    transition: background 0.15s;
}

.contact .item-header:hover {
    background: #fafcff;
}

.toggle-icon {
    transition: transform 0.25s ease;
    font-size: 1.1rem;
    color: #9b2c3d;
    font-weight: 600;
}

.contact .item-content {
    padding: 0 1.3rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease-out, padding 0.25s ease;
    background: #ffffff;
}

.contact .item.active .item-content {
    max-height: 700px;
    padding: 1rem 1.3rem 1.3rem 1.3rem;
}

.contact .item.active .toggle-icon {
    transform: rotate(90deg);
}

/* Contenu texte */
.contact .item-content p,
.contact .item-content li {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #2c3e4e;
    margin: 0.5rem 0;
}

.contact .item-content strong {
    color: #1f3b4c;
    font-weight: 600;
}

/* Listes de réalisations */
.realisations ul {
    margin: 0.3rem 0 0 1.2rem;
    padding-left: 0;
}

.realisations li {
    margin-bottom: 0.3rem;
}

/* ===================== IMAGES (formations) ===================== */
.formation-image {
    margin: 0.7rem 0;
}

.formation-image img {
    max-width: 100%;
    max-height: 240px;
    width: auto;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
    object-fit: cover;
}

/* ===================== SÉPARATEURS DOUX ===================== */
hr.divider-light {
    margin: 1rem 0;
    border: 0;
    height: 1px;
    background: linear-gradient(to right, #e2e8f0, transparent);
}


/* Style du tableau */
.competences-linguistiques table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.competences-linguistiques th {
    background: #2d3748;
    color: white;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.competences-linguistiques td {
    padding: 12px 16px;
    border-bottom: 1px solid #e2e8f0;
    color: #2d3748;
}

.competences-linguistiques tr:last-child td {
    border-bottom: none;
}

.competences-linguistiques tbody tr:hover {
    background: #f7fafc;
    transition: background 0.2s ease;
}

/* Style pour les niveaux de langue */
.competences-linguistiques td:first-child {
    font-weight: 600;
    color: #1e3c72;
}

/* Badge pour les niveaux "Excellent" */
.competences-linguistiques td:contains("Excellent") {
    position: relative;
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
    .contact {
        padding: 1.5rem 0;
    }
    .contact .container {
        padding: 0 1rem;
    }
    .section-group {
        padding: 0.5rem 1rem 1rem 1rem;
    }
    .contact .item-header {
        padding: 0.7rem 1rem;
        font-size: 0.9rem;
    }
    .sub-heading {
        font-size: 1.2rem;
    }
    .contact .section-heading {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    .contact .section-title {
        font-size: 1.8rem;
    }
    .contact .section-subtitle {
        font-size: 0.95rem;
    }
    .contact .item.active .item-content {
        padding: 0.8rem;
    }
    .formation-image img {
        max-height: 160px;
    }
}

/* ===================== VERSION IMPRESSION ===================== */
@media print {
    .contact {
        background: white;
        padding: 0;
    }
    .section-group {
        box-shadow: none;
        border: 1px solid #ddd;
        padding: 0.5rem;
        margin-bottom: 1rem;
    }
    .contact .item {
        break-inside: avoid;
        border: 1px solid #ccc;
        box-shadow: none;
    }
    .contact .item-content {
        max-height: none !important;
        display: block !important;
        padding: 0.5rem !important;
    }
    .toggle-icon {
        display: none;
    }
    .contact .item-header {
        background: #f5f5f5;
        cursor: default;
    }
    .contact .item.active .item-content {
        padding: 0.5rem !important;
    }
}
