/* Minimalist CSS with animations */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Merriweather', serif;
    line-height: 1.6;
    color: #fff;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    opacity: 0;
    animation: fadeIn 1s ease-in-out forwards, gradientShift 15s ease infinite;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 50%, rgba(102, 126, 234, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    transition: all 0.3s ease;
}

header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

nav h1 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
}

nav ul {
    display: flex;
    list-style: none;
}

nav li {
    margin-left: 2rem;
}

nav a {
    text-decoration: none;
    color: #333;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #667eea;
}

#hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 0 2rem;
    position: relative;
    overflow: hidden;
}

#hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.1) 0%, transparent 70%);
    animation: pulse 8s ease-in-out infinite;
    z-index: -1;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

#hero h2 {
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 300;
    margin-bottom: 1rem;
    animation: slideUp 1s ease-out 0.5s both, shimmer 3s infinite linear;
    background: linear-gradient(90deg, #fff 0%, #667eea 25%, #764ba2 50%, #667eea 75%, #fff 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(102, 126, 234, 0.3);
    position: relative;
    z-index: 1;
}

#hero p {
    font-size: clamp(1rem, 2vw, 1.5rem);
    animation: slideUp 1s ease-out 1s both;
    opacity: 0.9;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 300;
}

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

section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 1;
}

section.visible {
    opacity: 1;
    transform: translateY(0);
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, transparent, #667eea, transparent);
    opacity: 0;
    transition: opacity 0.8s ease;
}

section.visible::before {
    opacity: 1;
}

section h2 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 700;
    margin-bottom: 3rem;
    text-align: center;
    position: relative;
    display: inline-block;
    width: 100%;
    background: linear-gradient(135deg, #fff 0%, #667eea 50%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titleGlow 3s ease-in-out infinite;
}

@keyframes titleGlow {
    0%, 100% { filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.3)); }
    50% { filter: drop-shadow(0 0 20px rgba(102, 126, 234, 0.6)); }
}

#about h2 {
    background: linear-gradient(90deg, #fff 0%, #ccc 50%, #fff 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 2s infinite linear;
}

.profile-img {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    margin: 3rem auto;
    display: block;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border: 4px solid transparent;
    background: linear-gradient(135deg, #667eea, #764ba2) padding-box,
                linear-gradient(135deg, #667eea, #764ba2) border-box;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3),
                0 0 0 10px rgba(102, 126, 234, 0.1);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

.profile-img:hover {
    transform: scale(1.1) rotate(360deg);
    box-shadow: 0 15px 50px rgba(102, 126, 234, 0.5),
                0 0 0 15px rgba(102, 126, 234, 0.2);
}

.books-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    justify-items: center;
    padding: 2rem 0;
}

.book-item {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2),
                0 0 0 1px rgba(102, 126, 234, 0.1);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    max-width: 350px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.book-item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s;
    opacity: 0;
}

.book-item:hover::before {
    opacity: 1;
    animation: shine 1.5s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.book-item:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 50px rgba(102, 126, 234, 0.4),
                0 0 0 2px rgba(102, 126, 234, 0.3);
}

.book-image-wrapper {
    position: relative;
    width: 100%;
    margin-bottom: 1rem;
    overflow: hidden;
    border-radius: 4px;
}

.book-item img {
    width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.book-item:hover img {
    transform: scale(1.05);
    opacity: 0.9;
}

.book-summary {
    color: #333;
    margin-top: 1.5rem;
    padding: 0;
    text-align: left;
    animation: fadeInText 0.5s ease-in-out;
}

.book-summary h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #667eea;
    text-align: center;
    position: relative;
    padding-bottom: 0.5rem;
}

.book-summary h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

.book-summary p {
    color: #555;
    line-height: 1.8;
    font-size: 0.95rem;
    text-align: justify;
    margin: 0;
}

.book-details {
    display: none;
    color: #333;
    margin-top: 1rem;
    padding: 1rem;
    background-color: #f9f9f9;
    border-radius: 4px;
    animation: fadeInText 0.5s ease-in-out;
}

.book-details.active {
    display: block;
}


@keyframes fadeInText {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.book-details h3 {
    margin-bottom: 0.5rem;
}

.gallery-container {
    overflow: hidden;
    width: 100%;
    position: relative;
}

.gallery-track {
    display: flex;
    animation: scroll 30s linear infinite;
    gap: 1.5rem;
}

.gallery-track img {
    width: 350px;
    height: 250px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    filter: grayscale(30%);
    border: 3px solid transparent;
    background: linear-gradient(135deg, #667eea, #764ba2) padding-box;
}

.gallery-track img:hover {
    transform: scale(1.1) rotate(2deg);
    filter: grayscale(0%);
    box-shadow: 0 20px 50px rgba(102, 126, 234, 0.5);
    z-index: 10;
    position: relative;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-100%);
    }
}

form {
    display: flex;
    flex-direction: column;
    max-width: 500px;
    margin: 0 auto;
}

input, textarea {
    padding: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

input:focus, textarea:focus {
    outline: none;
    border-color: #667eea;
}

button {
    padding: 1rem;
    background-color: #667eea;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #5a67d8;
}

.contact-links {
    display: flex;
    gap: 2rem;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.contact-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: visible;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.contact-links a:hover {
    transform: translateY(-10px) scale(1.15);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
    background: rgba(255, 255, 255, 0.2);
}

.contact-links a svg {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.contact-links a:hover svg {
    transform: rotate(360deg) scale(1.2);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.5));
}

footer {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.9), rgba(15, 52, 96, 0.9));
    color: #fff;
    position: relative;
    overflow: hidden;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #667eea, #764ba2, transparent);
    animation: shimmer 3s infinite;
}

footer a {
    color: #667eea;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
    position: relative;
}

footer a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    transition: width 0.3s ease;
}

footer a:hover {
    color: #764ba2;
    transform: translateY(-2px);
}

footer a:hover::after {
    width: 100%;
}

/* Responsive design */
/* Custom cursor effect */
* {
    cursor: none;
}

body {
    cursor: none;
}

.custom-cursor {
    width: 20px;
    height: 20px;
    border: 2px solid #667eea;
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.2s ease, background 0.2s ease;
    transform: translate(-50%, -50%);
}

.custom-cursor.hover {
    transform: translate(-50%, -50%) scale(2);
    background: rgba(102, 126, 234, 0.2);
    border-color: #764ba2;
}

.custom-cursor-dot {
    width: 4px;
    height: 4px;
    background: #667eea;
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition: transform 0.1s ease;
}

@media (max-width: 768px) {
    * {
        cursor: auto;
    }
    
    .custom-cursor,
    .custom-cursor-dot {
        display: none;
    }
    
    nav {
        flex-direction: column;
        padding: 1rem;
    }

    nav ul {
        margin-top: 1rem;
        gap: 1rem;
    }

    nav li {
        margin-left: 0;
    }

    #hero h2 {
        font-size: 2rem;
    }

    section {
        padding: 4rem 1rem;
    }
    
    .books-container {
        grid-template-columns: 1fr;
    }

    .scintillant {
        color: #fff;
        text-shadow:
          0 0 10px #fff,
          0 0 20px #fff,
          0 0 30px #fff;
        animation: scintillement 1.2s infinite alternate;
      }
      
      @keyframes scintillement {
        0% {
          opacity: 1;
          text-shadow:
            0 0 10px #fff,
            0 0 20px #fff,
            0 0 30px #fff;
        }
        50% {
          opacity: 0.7;
          text-shadow:
            0 0 20px #fff,
            0 0 40px #fff,
            0 0 60px #fff;
        }
        100% {
          opacity: 1;
          text-shadow:
            0 0 10px #fff,
            0 0 20px #fff,
            0 0 30px #fff;
        }
      }
}
.navbar {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 64px; /* ou la hauteur de votre barre */
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    position: relative;
    z-index: 20;
}

.navbar ul {
    display: flex;
    gap: 32px; /* espace entre les liens */
    list-style: none;
    margin: 0;
    padding: 0;
}

.navbar li {
    display: flex;
    align-items: center;
}

.navbar a {
    text-decoration: none;
    color: #222;
    font-size: 1.1rem;
    font-weight: 500;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.navbar a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
}

.navbar a:hover::before,
.navbar a:focus::before {
    width: 80%;
}

.navbar a:hover,
.navbar a:focus {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    transform: translateY(-2px);
    color: #667eea;
}

/* Language switcher */
.lang-switcher {
    display: flex;
    gap: 8px;
    align-items: center;
    position: fixed;
    top: 18px; /* espace depuis le bord supérieur */
    right: 18px; /* aligné en haut à droite */
    z-index: 2200;
    padding: 6px;
    background: rgba(255,255,255,0.02);
    border-radius: 10px;
    backdrop-filter: blur(6px);
}
.lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    height: auto;
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.06);
    background: transparent;
    color: #222;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}
.lang-btn svg {
    display: block;
    width: 100%;
    height: auto;
}
.lang-btn img,
.flag-img {
    display: block;
    width: 100%;
    height: auto;
}
.lang-btn:hover {
    transform: translateY(-4px);
}
.lang-btn.active {
    box-shadow: 0 8px 30px rgba(0,0,0,0.25);
    transform: translateY(-2px) scale(1.02);
    background: linear-gradient(90deg, rgba(102,126,234,0.12), rgba(118,75,162,0.12));
}
