/* ===== QUI SUIS-JE - STYLE MODERNE & FLIP ===== */

/* Configuration */
:root {
    --primary-color: #CF8CD6;
    --text-dark: #333;
    --text-grey: #666;
    --bg-light: #f9fbfc;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #CF8CD6 0%, #9e6cbd 100%);
}

body {
    background-color: var(--bg-light);
}

.main-content {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* En-tête */
.page-header-container {
    text-align: center;
    margin-bottom: 5rem;
}

.page-title {
    font-size: 3rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.page-subtitle {
    color: var(--text-grey);
    font-size: 1.1rem;
}

.title-decoration {
    width: 60px;
    height: 4px;
    background: var(--gradient);
    margin: 1.5rem auto 0;
    border-radius: 2px;
}

/* --- SECTION INTRO --- */
.intro-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    align-items: center;
    margin-bottom: 6rem;
}

/* Visuel Personnage */
.intro-visual {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.visual-bg {
    position: absolute;
    width: 300px;
    height: 300px;
    background: var(--gradient);
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; /* Forme organique */
    opacity: 0.15;
    z-index: 0;
    animation: morph 8s ease-in-out infinite;
}

@keyframes morph {
    0%, 100% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; }
    50% { border-radius: 60% 40% 30% 70% / 50% 40% 50% 60%; }
}

.intro-img {
    width: 280px;
    height: auto;
    border-radius: 20px;
    border: 4px solid white;
    box-shadow: 0 15px 35px rgba(207, 140, 214, 0.2);
    z-index: 1;
    transform: rotate(-3deg);
    transition: transform 0.3s ease;
}

.intro-img:hover {
    transform: rotate(0deg) scale(1.02);
}

.credit-tag {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: #999;
    z-index: 1;
}

/* Texte Bio */
.intro-content h2 {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
}

.text-gradient {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lead-text {
    font-size: 1.2rem;
    color: var(--text-dark);
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.intro-content p {
    color: var(--text-grey);
    line-height: 1.8;
    margin-bottom: 2rem;
}

.personality-tags {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.personality-tags span {
    padding: 8px 16px;
    background: white;
    border: 1px solid #eee;
    border-radius: 50px;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

/* --- SECTION LOISIRS (FLIP CARDS) --- */
.hobbies-section {
    padding: 4rem 0;
}

.section-title-wrapper {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title-wrapper h2 {
    font-size: 2.2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.section-title-wrapper p {
    color: var(--text-grey);
}

/* Grille des cartes */
.hobbies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

/* CONFIGURATION FLIP CARD */
.flip-card {
    background-color: transparent;
    height: 380px; /* Hauteur fixe de la carte */
    perspective: 1000px; /* Effet 3D */
    cursor: pointer;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Flip fluide */
    transform-style: preserve-3d;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg); /* L'action de retournement */
}

/* Face Avant & Arrière */
.flip-card-front, .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden; /* Safari */
    backface-visibility: hidden;
    border-radius: 20px;
    overflow: hidden;
}

/* Style FACE AVANT */
.flip-card-front {
    background-color: white;
    color: var(--text-dark);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    border: 1px solid rgba(207, 140, 214, 0.1);
}

.icon-circle {
    width: 70px;
    height: 70px;
    background: #fdf5fe;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.flip-card:hover .icon-circle {
    transform: scale(1.1);
}

.flip-card-front h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.flip-card-front p {
    font-size: 0.95rem;
    color: var(--text-grey);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.flip-hint {
    font-size: 0.8rem;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: auto; /* Pousse en bas */
    opacity: 0.7;
}

/* Style FACE ARRIÈRE */
.flip-card-back {
    background-color: #333;
    color: white;
    transform: rotateY(180deg); /* Déjà retourné au départ */
}

.flip-card-back img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Remplit tout le cadre */
}

.back-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.back-overlay h3 {
    color: white;
    font-size: 1.2rem;
    margin: 0;
}

/* --- SECTION AVENIR --- */
.future-section {
    padding: 4rem 0 2rem;
    margin-top: 2rem;
    border-top: 1px solid #eee;
}

.title-decoration-small {
    width: 40px;
    height: 3px;
    background: var(--gradient);
    margin: 10px auto;
}

.goals-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.goal-card {
    background: white;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    border: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

/* Carte du milieu mise en avant */
.goal-card.highlight {
    border-color: rgba(207, 140, 214, 0.3);
    background: linear-gradient(to bottom, white, #fdfaff);
    transform: translateY(-10px);
}

.goal-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(207, 140, 214, 0.15);
}

.goal-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 1rem;
}

.goal-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
}

.goal-header h4 {
    font-size: 1.1rem;
    color: var(--text-dark);
}

.goal-card p {
    color: var(--text-grey);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* --- RESPONSIVE --- */
@media (max-width: 992px) {
    .intro-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .intro-visual {
        order: 1; /* Image d'abord sur tablette */
    }

    .personality-tags {
        justify-content: center;
    }

    .goals-grid {
        grid-template-columns: 1fr; /* Objectifs en colonne */
    }

    .goal-card.highlight {
        transform: none; /* Enlève le décalage sur mobile */
    }
}

@media (max-width: 768px) {
    .hobbies-grid {
        grid-template-columns: 1fr; /* Une seule carte par ligne */
    }

    .flip-card {
        height: 300px; /* Un peu moins haut sur mobile */
    }
}