/* Modern Hero Section Styles */
.hero-section {
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
    padding: 6rem 0;
    box-sizing: border-box;
    display: flex;           /* Pour permettre le flex enfant */
    flex-direction: column;  /* Organisation verticale */
}

/* Ensure images and media never overflow */
img, video, iframe {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Animated Background */
.animated-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.gradient-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
}

.circle-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1), rgba(147, 51, 234, 0.05));
    top: -100px;
    right: -100px;
    animation: float 20s infinite alternate ease-in-out;
}

.circle-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.1), rgba(59, 130, 246, 0.05));
    bottom: -50px;
    left: -50px;
    animation: float 15s infinite alternate-reverse ease-in-out;
}

.geometric-shapes .shape {
    position: absolute;
    opacity: 0.1;
}

.shape-1 {
    border-radius: 2rem;
    width: 100px;
    height: 100px;
    border: 2px solid #3b82f6;
    top: 20%;
    left: 10%;
    animation: rotate 20s linear infinite;
}

.shape-2 {
    width: 80px;
    height: 80px;
    border: 2px solid #8b5cf6;
    transform: rotate(45deg);
    top: 40%;
    right: 15%;
    animation: float 15s infinite alternate ease-in-out;
}

.shape-3 {
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, #3b82f6, #8b5cf6);
    border-radius: 1rem;
    bottom: 20%;
    left: 20%;
    animation: rotate 25s linear infinite;
}

/* Profile Card */
.profile-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 1.5rem;
    padding: 2rem;
    box-shadow:
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease;
    max-width: 350px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center; 
    height: 100%; /* S'étire si le parent le permet */
    box-sizing: border-box;
}

.profile-card:hover {
    transform: translateY(-5px);
}

.profile-photo-wrapper {
    position: relative;
    width: 240px;
    height: 260px;
    margin: 0 auto 2rem;
    border-radius: 1rem;
    overflow: hidden;
}

.profile-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.profile-card:hover .profile-photo {
    transform: scale(1.02);
}

.photo-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(0, 0, 0, 0.1) 100%
    );
}


.profile-name {
    font-size: 1.8rem;
    font-weight: 700;
    text-align: center;
    background: linear-gradient(to right, #1a365d, #2563eb);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.profile-title {
    font-size: 1.2rem;
    color: #4b5563;
    text-align: center;
    margin-bottom: 1rem;
}

.profile-location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.profile-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.profile-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.75rem;
    background: white;
    color: #4b5563;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.profile-link:hover {
    transform: translateY(-2px);
}

.profile-link.email:hover { background: #ea4335; color: white; }
.profile-link.linkedin:hover { background: #0077b5; color: white; }
.profile-link.github:hover { background: #333; color: white; }
.profile-link.scholar:hover { background: #4285f4; color: white; }

/* Content Section (Hero Content) */
.hero-content {
    flex: 1; /* Permet de prendre toute la hauteur restante dans hero-section */
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4rem;
    align-items: stretch;  /* Les éléments s'étirent verticalement */
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
    padding: 0 1rem;
}

/* Intro Card : même hauteur que hero-section */
.intro-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 1.5rem;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%; /* S'étire sur la hauteur disponible */
    box-sizing: border-box;
}

.card-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.expertise-badge,
.experience-badge {
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
}

.expertise-badge {
    background: #dbeafe;
    color: #1e40af;
}

.experience-badge {
    background: #ede9fe;
    color: #5b21b6;
}

.highlight-text {
    font-size: 1.5rem;
    font-weight: 500;
    color: #1e293b;
    line-height: 1.4;
    margin-bottom: 2rem;
}

.education-info {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: white;
    border-radius: 1rem;
    flex-wrap: wrap;
}

.education-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f9ff;
    border-radius: 1rem;
    color: #0284c7;
    flex-shrink: 0;
}

.education-details h3 {
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 0.5rem;
}

.education-details p {
    color: #64748b;
}

.supervisor {
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.supervisor a {
    color: #2563eb;
    text-decoration: none;
}

.supervisor a:hover {
    text-decoration: underline;
}

.research-focus {
    margin-bottom: 2rem;
}

.research-focus h3 {
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 1rem;
}

.focus-areas {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.focus-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: white;
    border-radius: 0.75rem;
    transition: transform 0.3s ease;
}

.focus-item:hover {
    transform: translateY(-2px);
}

.focus-item i {
    color: #2563eb;
}

.quick-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 1rem;
    text-align: center;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #2563eb;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #64748b;
    font-size: 0.875rem;
}

/* Animations */
@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(0, 20px); }
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Responsive Design */

/* Large tablets and small desktops */
@media (max-width: 1024px) {
    .hero-content {
        gap: 2rem;
    }
    
    .profile-card {
        max-width: 300px;
    }
}

/* Tablets and small screens */
@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .profile-card {
        max-width: 100%;
        margin-bottom: 2rem;
    }

    .profile-photo-wrapper {
        width: 180px;
        height: 180px;
    }

    .quick-stats {
        grid-template-columns: 1fr;
    }

    .focus-areas {
        grid-template-columns: 1fr;
    }

    .stat-card {
        padding: 1.25rem;
    }

    .highlight-text {
        font-size: 1.25rem;
    }

    .intro-card {
        padding: 1.5rem;
    }
}

/* Smartphones (petits écrans) */
@media (max-width: 480px) {
    .hero-section {
        padding: 4rem 1rem;
    }

    .hero-content {
        gap: 1.5rem;
        padding: 1rem;
    }

    .profile-card {
        padding: 1.5rem;
        max-width: 100%;
    }

    .profile-photo-wrapper {
        width: 150px;
        height: 150px;
    }

    .profile-name {
        font-size: 1.4rem;
    }

    .highlight-text {
        font-size: 1.1rem;
        margin-bottom: 1.5rem;
    }

    .intro-card {
        padding: 1.5rem;
    }

    .education-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .focus-item {
        padding: 0.75rem;
    }

    .stat-number {
        font-size: 1.5rem;
    }

    .profile-title {
        font-size: 1rem;
    }

    .profile-links {
        gap: 0.5rem;
    }

    .research-focus h3 {
        font-size: 1rem;
    }
}

/* Très petits écrans (ex: téléphones anciens) */
@media (max-width: 360px) {
    .hero-section {
        padding: 3rem 0.5rem;
    }

    .hero-content {
        padding: 0.5rem;
        gap: 1rem;
    }

    .profile-card {
        padding: 1rem;
    }

    .profile-name {
        font-size: 1.2rem;
    }

    .highlight-text {
        font-size: 1rem;
    }

    .profile-title {
        font-size: 0.9rem;
    }

    .education-info {
        padding: 1rem;
        gap: 0.75rem;
    }
}

/* Dark Mode Styles */
@media (prefers-color-scheme: dark) {
    .hero-section {
        background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
    }

    .profile-card,
    .intro-card {
        background: rgba(30, 41, 59, 0.8);
    }

    .profile-name {
        background: linear-gradient(to right, #60a5fa, #a78bfa);
        -webkit-background-clip: text;
    }

    .profile-title {
        color: #e2e8f0;
    }

    .profile-location {
        color: #94a3b8;
    }

    .profile-link {
        background: #1e293b;
        color: #e2e8f0;
    }

    .expertise-badge {
        background: rgba(59, 130, 246, 0.2);
        color: #60a5fa;
    }

    .experience-badge {
        background: rgba(139, 92, 246, 0.2);
        color: #a78bfa;
    }

    .highlight-text {
        color: #e2e8f0;
    }

    .education-info {
        background: #1e293b;
    }

    .education-icon {
        background: rgba(59, 130, 246, 0.2);
        color: #60a5fa;
    }

    .education-details h3 {
        color: #e2e8f0;
    }

    .education-details p {
        color: #94a3b8;
    }

    .focus-item {
        background: #1e293b;
        color: #e2e8f0;
    }

    .focus-item i {
        color: #60a5fa;
    }

    .stat-card {
        background: #1e293b;
    }

    .stat-number {
        color: #60a5fa;
    }

    .stat-label {
        color: #94a3b8;
    }
}

/* Enhanced Animations */
.profile-card {
    animation: fadeInScale 0.6s ease-out;
}

.intro-card {
    animation: slideInRight 0.6s ease-out;
}

.stat-card {
    animation: fadeInUp 0.6s ease-out;
    animation-fill-mode: both;
}

.stat-card:nth-child(1) { animation-delay: 0.2s; }
.stat-card:nth-child(2) { animation-delay: 0.4s; }
.stat-card:nth-child(3) { animation-delay: 0.6s; }

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hover Effects */
.focus-item {
    cursor: pointer;
    transition: all 0.3s ease;
}

.focus-item:hover {
    background: linear-gradient(to right, #3b82f6, #6366f1);
    color: white;
}

.focus-item:hover i {
    color: white;
    transform: scale(1.1);
}

/* Loading States */
.profile-card.loading .profile-photo {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

/* Scroll Animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.scroll-reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Glass Morphism Effects */
.glass-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
}

/* Print Styles */
@media print {
    .hero-section {
        background: none;
        padding: 0;
        min-height: auto;
    }

    .animated-bg,
    .profile-links,
    .quick-stats {
        display: none;
    }

    .profile-card,
    .intro-card {
        box-shadow: none;
        background: none;
    }
}
