/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Variables CSS */
:root {
    --primary-color: #1a237e;
    --secondary-color: #3949ab;
    --accent-color: #ff6b35;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --white: #ffffff;
    --dark-bg: #0f1419;
    --gradient-primary: linear-gradient(135deg, #1a237e 0%, #3949ab 50%, #5c6bc0 100%);
    --gradient-accent: linear-gradient(135deg, #ff6b35 0%, #ff8a65 100%);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 15px 50px rgba(0, 0, 0, 0.2);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s ease-out;
    --border-radius: 12px;
    --border-radius-lg: 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(26, 35, 126, 0.95);
    backdrop-filter: blur(20px);
    z-index: 1000;
    transition: var(--transition);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar.scrolled {
    background: rgba(26, 35, 126, 0.98);
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid rgba(255, 107, 53, 0.2);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.nav-logo {
    display: flex;
    align-items: center;
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'Playfair Display', serif;
}

.nav-logo i {
    margin-right: 0.5rem;
    color: var(--accent-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    background: var(--accent-color);
    transform: translateY(-2px);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background: var(--white);
    margin: 3px 0;
    transition: var(--transition);
}

/* Section Hero */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: var(--gradient-primary);
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 107, 53, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.05) 0%, transparent 50%),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><polygon fill="%23ffffff08" points="0,1000 1000,0 1000,1000"/></svg>');
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 35, 126, 0.1);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    z-index: 2;
    position: relative;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 1rem;
    animation: slideInLeft 1s ease-out;
    word-wrap: break-word;
    hyphens: auto;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: 1.5rem;
    animation: slideInLeft 1s ease-out 0.2s both;
}

.hero-description {
    font-size: 1.2rem;
    color: var(--white);
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: slideInLeft 1s ease-out 0.4s both;
}

.hero-stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    animation: slideInLeft 1s ease-out 0.6s both;
}

.stat {
    display: flex;
    align-items: center;
    color: var(--white);
    font-weight: 500;
}

.stat i {
    color: var(--accent-color);
    margin-right: 0.5rem;
    font-size: 1.2rem;
}

.hero-image {
    display: flex;
    justify-content: center;
    animation: slideInRight 1s ease-out 0.4s both;
}

.portrait-container {
    position: relative;
    width: 320px;
    height: 320px;
    margin: 0 auto;
}

.portrait-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 6px solid var(--white);
    box-shadow: var(--shadow-xl);
    transition: var(--transition);
    position: relative;
    z-index: 2;
}

.portrait-frame {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border-radius: 50%;
    background: var(--gradient-accent);
    z-index: 1;
    animation: pulse-ring 3s infinite;
}

.portrait-image:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-xl), 0 0 40px rgba(255, 107, 53, 0.3);
}

@keyframes pulse-ring {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.4;
    }
    100% {
        transform: scale(1);
        opacity: 0.8;
    }
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

/* Sections */
.section {
    padding: 6rem 0;
}

.alt-bg {
    background: var(--light-bg);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.section-divider {
    width: 80px;
    height: 4px;
    background: var(--accent-color);
    margin: 0 auto;
    border-radius: 2px;
}

/* Formation Grid */
.formation-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.formation-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(26, 35, 126, 0.05);
}

.formation-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-accent);
}

.formation-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    transition: left 0.6s ease;
}

.formation-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: var(--accent-color);
}

.formation-card:hover::after {
    left: 100%;
}

.formation-card.featured {
    transform: scale(1.05);
    border: 2px solid var(--accent-color);
}

.card-icon {
    width: 90px;
    height: 90px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    position: relative;
    transition: var(--transition);
}

.card-icon::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: var(--gradient-accent);
    border-radius: 50%;
    z-index: -1;
    opacity: 0;
    transition: var(--transition);
}

.formation-card:hover .card-icon::before {
    opacity: 1;
    transform: scale(1.1);
}

.card-icon i {
    font-size: 2.2rem;
    color: var(--white);
    transition: var(--transition);
}

.formation-card:hover .card-icon i {
    transform: scale(1.1) rotateY(360deg);
}

.formation-card h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.institution {
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.description {
    color: #666;
    line-height: 1.6;
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--primary-color);
    transform: translateX(-50%);
}

.timeline-item {
    position: relative;
    margin: 3rem 0;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
    padding-right: 3rem;
}

.timeline-item:nth-child(even) {
    left: 50%;
    padding-left: 3rem;
}

.timeline-marker {
    position: absolute;
    top: 1rem;
    width: 20px;
    height: 20px;
    background: var(--white);
    border: 4px solid var(--primary-color);
    border-radius: 50%;
    right: -13px;
}

.timeline-item:nth-child(even) .timeline-marker {
    left: -13px;
}

.timeline-marker.active {
    background: var(--accent-color);
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.5);
}

.timeline-content {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    position: relative;
}

.timeline-content::before {
    content: '';
    position: absolute;
    top: 1.5rem;
    width: 0;
    height: 0;
    border: 10px solid;
    right: -20px;
    border-color: transparent transparent transparent var(--white);
}

.timeline-item:nth-child(even) .timeline-content::before {
    left: -20px;
    border-color: transparent var(--white) transparent transparent;
}

.timeline-content h3 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.timeline-period {
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.timeline-description {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.specializations {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.spec-tag {
    background: var(--light-bg);
    color: var(--primary-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Magistrature */
.magistrature-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.info-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.info-card.highlight {
    border-left: 5px solid var(--accent-color);
    background: linear-gradient(135deg, #fff5f0 0%, var(--white) 100%);
}

.card-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}

.card-header i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-right: 1rem;
}

.info-card.highlight .card-header i {
    color: var(--accent-color);
}

.card-header h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
}

.card-content p {
    margin-bottom: 0.5rem;
    color: #666;
    line-height: 1.6;
}

.expertise-area {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.expertise-area h3 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.expertise-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.expertise-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    background: var(--light-bg);
    border-radius: 10px;
    transition: var(--transition);
}

.expertise-item:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.expertise-item i {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-right: 1rem;
}

.expertise-item:hover i {
    color: var(--white);
}

/* Contact */
.contact-content {
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.contact-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: var(--transition);
    border: 1px solid rgba(26, 35, 126, 0.05);
    position: relative;
    overflow: hidden;
}

.contact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient-primary);
}

.contact-card.primary-contact {
    border-color: var(--accent-color);
    background: linear-gradient(135deg, #fff5f0 0%, var(--white) 100%);
}

.contact-card.primary-contact::before {
    background: var(--gradient-accent);
    height: 4px;
}

.contact-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.contact-card i {
    font-size: 3.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    transition: var(--transition);
}

.contact-card.primary-contact i {
    color: var(--accent-color);
}

.contact-card:hover i {
    transform: scale(1.1) rotateY(360deg);
}

.contact-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.4rem;
    font-weight: 600;
}

.contact-card.primary-contact h3 {
    color: var(--accent-color);
}

.contact-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.contact-detail {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.contact-card.primary-contact .contact-detail {
    color: var(--accent-color);
}

.contact-link {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--white);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: var(--transition);
    margin-top: 0.5rem;
}

.contact-card.primary-contact .contact-link {
    background: var(--gradient-accent);
}

.contact-link:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--white);
    text-decoration: none;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.7;
}

/* Animations */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    40% {
        transform: translateY(-20px) translateX(-50%);
    }
    60% {
        transform: translateY(-10px) translateX(-50%);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */

/* Large tablets et petits laptops */
@media (max-width: 1024px) {
    .container {
        padding: 0 30px;
    }
    
    .hero-content {
        gap: 3rem;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
    
    .portrait-container {
        width: 280px;
        height: 280px;
    }
}

/* Tablets */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: rgba(26, 35, 126, 0.98);
        backdrop-filter: blur(20px);
        width: 100%;
        text-align: center;
        transition: var(--transition);
        box-shadow: var(--shadow-lg);
        padding: 2rem 0;
        border-top: 1px solid rgba(255, 107, 53, 0.2);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 1.2rem 0;
    }

    .nav-link {
        font-size: 1.1rem;
        padding: 0.8rem 1.5rem;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
        padding: 2rem 0;
    }

    .hero-title {
        font-size: 2.8rem;
        line-height: 1.1;
        word-wrap: break-word;
        hyphens: auto;
    }

    .hero-subtitle {
        font-size: 1.3rem;
    }

    .hero-description {
        font-size: 1.1rem;
        max-width: 600px;
        margin: 0 auto 2rem;
    }

    .hero-stats {
        justify-content: center;
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .stat {
        background: rgba(255, 255, 255, 0.1);
        padding: 0.8rem 1.2rem;
        border-radius: 25px;
        backdrop-filter: blur(10px);
    }

    .portrait-container {
        width: 250px;
        height: 250px;
    }

    .section {
        padding: 5rem 0;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .formation-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .formation-card.featured {
        transform: none;
        border: 2px solid var(--accent-color);
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item {
        width: 100%;
        left: 0 !important;
        padding-left: 3.5rem !important;
        padding-right: 0 !important;
    }

    .timeline-marker {
        left: 7px !important;
        right: auto !important;
    }

    .timeline-content::before {
        left: -20px !important;
        right: auto !important;
        border-color: transparent var(--white) transparent transparent !important;
    }

    .magistrature-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .expertise-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }

    .contact-info {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }

    .footer-content {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        text-align: center;
    }
}

/* Mobile phones */
@media (max-width: 480px) {
    .container {
        padding: 0 20px;
    }

    .nav-logo {
        font-size: 1.3rem;
    }

    .hero-title {
        font-size: 2rem;
        line-height: 1.1;
        word-wrap: break-word;
        hyphens: auto;
        text-align: center;
        padding: 0 10px;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .hero-stats {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .stat {
        width: 100%;
        max-width: 280px;
        justify-content: center;
        text-align: center;
    }

    .portrait-container {
        width: 200px;
        height: 200px;
    }

    .section {
        padding: 4rem 0;
    }

    .section-title {
        font-size: 2rem;
        line-height: 1.2;
    }

    .formation-card {
        padding: 2rem 1.5rem;
    }

    .card-icon {
        width: 70px;
        height: 70px;
    }

    .card-icon i {
        font-size: 1.8rem;
    }

    .timeline-item {
        padding-left: 3rem !important;
    }

    .timeline-content {
        padding: 1.5rem 1.2rem;
    }

    .specializations {
        justify-content: center;
    }

    .expertise-grid {
        grid-template-columns: 1fr;
    }

    .expertise-item {
        padding: 1.2rem;
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }

    .expertise-item i {
        margin-right: 0;
        margin-bottom: 0.5rem;
    }

    .contact-info {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding: 2rem 1.5rem;
    }

    .contact-card i {
        font-size: 2.5rem;
    }

    .contact-detail {
        font-size: 1.1rem;
    }

    .contact-link {
        padding: 0.8rem 1.2rem;
        font-size: 0.9rem;
    }
}

/* Extra small devices */
@media (max-width: 320px) {
    .container {
        padding: 0 15px;
    }

    .hero-title {
        font-size: 1.7rem;
        line-height: 1.1;
        word-wrap: break-word;
        hyphens: auto;
        text-align: center;
        padding: 0 10px;
        margin-bottom: 0.5rem;
    }

    .section-title {
        font-size: 1.7rem;
    }

    .formation-card,
    .contact-card {
        padding: 1.5rem 1rem;
    }

    .portrait-container {
        width: 180px;
        height: 180px;
    }
}

/* Effets de scroll */
.section {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.section.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Nouveaux effets visuels */
.glass-effect {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Gestion du nom pour éviter la coupure */
.hero-title {
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
}

@media (max-width: 768px) {
    .hero-title {
        white-space: normal;
        word-break: keep-all;
        overflow-wrap: break-word;
    }
}

@media (max-width: 480px) {
    .hero-title {
        white-space: normal;
        word-break: normal;
        overflow-wrap: break-word;
        hyphens: none;
    }
}

/* Amélioration de l'affichage du titre */
.title-line {
    display: inline-block;
    margin-right: 0.3em;
}

@media (max-width: 600px) {
    .hero-title {
        display: flex;
        flex-direction: column;
        align-items: center;
        line-height: 0.9;
    }
    
    .title-line {
        display: block;
        margin-right: 0;
        margin-bottom: 0.1em;
    }
    
    .title-line:last-child {
        margin-bottom: 0;
    }
}

.glow-effect {
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.3);
}

.text-gradient {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Amélioration des boutons */
.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Animations de chargement */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Améliorations du footer */
.footer {
    background: var(--gradient-primary);
}

/* Scrollbar personnalisée */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-accent);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

/* Effets hover avancés */
.formation-card {
    position: relative;
    overflow: hidden;
}

.formation-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.formation-card:hover::after {
    left: 100%;
}

/* Amélioration de l'accessibilité */
.nav-link:focus,
.formation-card:focus,
.expertise-item:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* Mode sombre (optionnel) */
@media (prefers-color-scheme: dark) {
    :root {
        --text-color: #e0e0e0;
        --light-bg: #1e1e1e;
        --white: #2d2d2d;
    }
}

/* --- Expertise détaillée --- */
.expertise-detailed {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  justify-content: space-between;
  margin-top: 3rem;
}
.expertise-category {
  flex: 1 1 300px;
  background: var(--white);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 2rem 1.5rem;
  margin-bottom: 1.5rem;
  min-width: 280px;
  transition: var(--transition);
  border: 1px solid rgba(26,35,126,0.07);
}
.expertise-category:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-color);
  transform: translateY(-6px) scale(1.02);
}
.category-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.category-icon {
  width: 48px;
  height: 48px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.5rem;
  box-shadow: var(--shadow-sm);
}
.category-header h3 {
  color: var(--primary-color);
  font-size: 1.2rem;
  font-weight: 700;
}
.expertise-list {
  margin: 1rem 0 0 0;
  padding-left: 0;
  list-style: none;
}
.expertise-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #555;
  margin-bottom: 0.5rem;
  font-size: 1rem;
}
.expertise-list i {
  color: var(--accent-color);
}

/* --- Jurisprudence --- */
.jurisprudence-content {
  margin-top: 3rem;
}
.jurisprudence-stats {
  display: flex;
  gap: 2rem;
  justify-content: center;
  margin-bottom: 2.5rem;
}
.stat-card {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 2rem 1.5rem;
  text-align: center;
  min-width: 120px;
  border: 1px solid rgba(26,35,126,0.07);
}
.stat-number {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}
.stat-label {
  color: var(--primary-color);
  font-size: 1rem;
}
.jurisprudence-areas {
  margin-top: 2.5rem;
}
.areas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.area-item {
  background: var(--white);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  padding: 1.5rem 1rem;
  text-align: center;
  border: 1px solid rgba(26,35,126,0.07);
  transition: var(--transition);
}
.area-item i {
  font-size: 2rem;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}
.area-item h4 {
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}
.area-item p {
  color: #666;
  font-size: 0.97rem;
}

/* --- Publications & Contributions --- */
.publications-content {
  margin-top: 3rem;
}
.publications-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 2.5rem;
}
.pub-category {
  flex: 1 1 320px;
  background: var(--white);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 2rem 1.5rem;
  min-width: 260px;
  border: 1px solid rgba(26,35,126,0.07);
}
.pub-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.pub-header i {
  font-size: 1.5rem;
  color: var(--accent-color);
}
.pub-header h3 {
  color: var(--primary-color);
  font-size: 1.1rem;
  font-weight: 700;
}
.pub-list {
  margin-top: 1rem;
}
.pub-item {
  margin-bottom: 1.2rem;
  padding-bottom: 0.7rem;
  border-bottom: 1px solid #f0f0f0;
}
.pub-item:last-child {
  border-bottom: none;
}
.pub-item h4 {
  color: var(--primary-color);
  font-size: 1rem;
  margin-bottom: 0.2rem;
}
.pub-item p {
  color: #666;
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}
.pub-type {
  display: inline-block;
  background: var(--gradient-accent);
  color: var(--white);
  font-size: 0.85rem;
  border-radius: 12px;
  padding: 0.2rem 0.7rem;
  margin-top: 0.2rem;
}

.achievements {
  margin-top: 2.5rem;
}
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.achievement-item {
  background: var(--white);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  padding: 1.5rem 1rem;
  text-align: center;
  border: 1px solid rgba(26,35,126,0.07);
  transition: var(--transition);
}
.achievement-icon {
  font-size: 2rem;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}
.achievement-item h4 {
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}
.achievement-item p {
  color: #666;
  font-size: 0.97rem;
}

/* --- Badges et détails formation --- */
.formation-details {
  margin-top: 0.7rem;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}
.detail-badge {
  background: var(--gradient-accent);
  color: var(--white);
  font-size: 0.85rem;
  border-radius: 12px;
  padding: 0.2rem 0.7rem;
  margin-bottom: 0.2rem;
}
.year {
  color: var(--accent-color);
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}

/* --- Sous-titres de section --- */
.section-subtitle {
  color: #666;
  font-size: 1.1rem;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
  font-style: italic;
  text-align: center;
}

@media (max-width: 900px) {
  .expertise-detailed, .publications-categories {
    flex-direction: column;
    gap: 1.5rem;
  }
  .jurisprudence-stats {
    flex-direction: column;
    gap: 1.2rem;
    align-items: center;
  }
}
@media (max-width: 600px) {
  .areas-grid, .achievements-grid {
    grid-template-columns: 1fr;
  }
  .expertise-detailed, .publications-categories {
    flex-direction: column;
    gap: 1rem;
  }
}