/* Reset et styles de base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --pink-light: #ffcce0;
    --pink-medium: #ffb3d9;
    --pink-dark: #ff99cc;
    --white-soft: #fffafc;
    --gray-soft: #f4f4f4;
    --lavender: #e6d5ff;
    --gold: #ffd700;
}

body {
    font-family: 'Quicksand', sans-serif;
    color: #333;
    background: linear-gradient(135deg, #ff8fab, #f56991, #e05780, #c9184a, #ff758f);
    background-size: 400% 400%;
    background-attachment: fixed;
    animation: gradientShift 18s ease infinite;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* Voile lumineux radial par-dessus le dégradé */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(255,183,197,0.4), transparent 45%),
        radial-gradient(circle at 80% 75%, rgba(201,24,74,0.35), transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* Sections */
.section {
    min-height: 100vh;
    padding: 20px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.full-screen {
    height: 100vh;
}

/* Page d'accueil */
#home {
    background: rgba(255, 255, 255, 0.12);
    overflow: hidden;
}

.hero-content {
    text-align: center;
    z-index: 10;
    animation: fadeInUp 1.5s ease-out;
}

.hero-title {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 40px;
    padding: 0 20px;
    line-height: 1.4;
}

/* Indicateur de scroll */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    font-size: 0.9rem;
}

.arrow-down {
    animation: bounce 2s infinite;
    margin-top: 10px;
    font-size: 1.5rem;
}

/* Cœurs flottants */
.floating-hearts {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.floating-hearts::before,
.floating-hearts::after {
    content: '💕';
    position: absolute;
    font-size: 20px;
    animation: float 15s infinite;
}

.floating-hearts::before {
    left: 10%;
    animation-delay: 0s;
}

.floating-hearts::after {
    left: 80%;
    animation-delay: 7s;
}

/* Nuages */
.clouds {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.cloud {
    position: absolute;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 100px;
    opacity: 0.8;
}

.cloud::before {
    content: '';
    position: absolute;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 100px;
}

.cloud-1 {
    width: 100px;
    height: 40px;
    top: 20%;
    animation: drift 20s infinite;
}

.cloud-1::before {
    width: 50px;
    height: 50px;
    top: -25px;
    left: 10px;
}

.cloud-2 {
    width: 80px;
    height: 35px;
    top: 60%;
    animation: drift 25s infinite;
    animation-delay: 5s;
}

.cloud-2::before {
    width: 60px;
    height: 40px;
    top: -20px;
    right: 15px;
}

.cloud-3 {
    width: 120px;
    height: 45px;
    top: 40%;
    animation: drift 30s infinite;
    animation-delay: 10s;
}

/* Section Souvenirs */
#memories {
    background-color: rgba(255, 255, 255, 0.12);
    padding-top: 60px;
}

.section-title {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    color: #ffffff;
    margin-bottom: 40px;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.memories-container {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 20px 0;
    width: 100%;
    max-width: 100vw;
}

.memory-card {
    flex: 0 0 250px;
    scroll-snap-align: center;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
}

.memory-image {
    width: 100%;
    height: 300px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.memory-image:active {
    transform: scale(0.95);
}

.memory-emoji {
    font-size: 4rem;
}

.memory-caption {
    margin-top: 15px;
    font-weight: 600;
    color: #666;
    font-size: 0.95rem;
}

/* Section Pourquoi tu me plais */
#reasons {
    background: rgba(255, 255, 255, 0.12);
    padding-top: 60px;
}

.reasons-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 600px;
}

.reason-card {
    height: 200px;
    perspective: 1000px;
    cursor: pointer;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.reason-card.flipped .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.card-front {
    background: linear-gradient(135deg, var(--pink-light), var(--pink-medium));
    color: #fff;
}

.card-back {
    background: linear-gradient(135deg, var(--lavender), var(--pink-light));
    color: #333;
    transform: rotateY(180deg);
}

.card-emoji {
    font-size: 3rem;
    margin-bottom: 10px;
}

.card-front h3 {
    font-family: 'Dancing Script', cursive;
    font-size: 1.5rem;
}

.card-back p {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Footer */
.footer {
    background-color: transparent;
    padding: 40px 20px;
    text-align: center;
}

.quote p {
    font-family: 'Dancing Script', cursive;
    font-size: 1.3rem;
    color: #ffffff;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.initials {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    color: var(--pink-medium);
    position: relative;
    display: inline-block;
}

.initials::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, var(--gold) 0%, transparent 70%);
    opacity: 0.3;
    animation: sparkle 3s infinite;
}

/* Chat Mascotte */
.cat-mascot {
    position: fixed;
    bottom: 20px;
    right: 20px;
    cursor: pointer;
    z-index: 1000;
    transition: transform 0.3s ease;
}

.cat-mascot:active {
    transform: scale(0.9);
}

.cat-mascot svg {
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.2));
    animation: float-cat 3s ease-in-out infinite;
}

.speech-bubble {
    position: absolute;
    bottom: 70px;
    right: 0;
    background: #fff;
    border-radius: 20px;
    padding: 10px 15px;
    font-size: 0.9rem;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.speech-bubble::after {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 10px solid #fff;
}

.cat-mascot.speaking .speech-bubble {
    opacity: 1;
    transform: scale(1);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes float {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) rotate(360deg);
        opacity: 0;
    }
}

@keyframes drift {
    from {
        transform: translateX(-100px);
    }
    to {
        transform: translateX(calc(100vw + 100px));
    }
}

@keyframes float-cat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes sparkle {
    0%, 100% {
        transform: scale(0.8);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.6;
    }
}

/* Media Queries pour optimisation mobile */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .memory-card {
        flex: 0 0 200px;
    }
    
    .memory-image {
        height: 250px;
    }
}

/* Désactiver le scroll horizontal sur le body */
body {
    overflow-x: hidden;
}

/* Amélioration du scroll des souvenirs */
.memories-container::-webkit-scrollbar {
    height: 5px;
}

.memories-container::-webkit-scrollbar-track {
    background: var(--gray-soft);
    border-radius: 10px;
}

.memories-container::-webkit-scrollbar-thumb {
    background: var(--pink-medium);
    border-radius: 10px;
}

/* Feuille de papier pour texte personnalisé */
.paper-note {
    background: #fffafc;
    border-radius: 32px;
    box-shadow: 0 12px 40px rgba(255,179,217,0.18), 0 2px 0 #ffd4e5 inset;
    padding: 50px 32px;
    max-width: 800px;
    min-width: 320px;
    margin: 40px auto 0 auto;
    position: relative;
    border: 2.5px dashed #ffcce0;
    display: flex;
    flex-direction: column;
    min-height: 350px;
    height: 100%;
}

.paper-note textarea {
    width: 100%;
    min-height: 220px;
    border: none;
    background: transparent;
    font-family: 'Dancing Script', cursive;
    font-size: 1.5rem;
    color: #e06fa7;
    resize: vertical;
    outline: none;
    padding: 0;
    line-height: 1.8;
    box-shadow: none;
}

.paper-note textarea::placeholder {
    color: #ffb3d9;
    opacity: 0.7;
    font-style: italic;
}

.note-text {
    font-family: 'Dancing Script', cursive;
    font-size: 1.7rem;
    color: #e06fa7;
    line-height: 1.9;
    white-space: pre-line;
    text-align: left;
    min-height: 180px;
    flex: 1 1 auto;
}

/* Indicateur swipe vers le bas sous la vidéo */
.swipe-down-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 18px 0 0 0;
    color: #ffffff;
    font-family: 'Quicksand', sans-serif;
    font-size: 1.1rem;
    user-select: none;
    pointer-events: none;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.swipe-arrow {
    font-size: 2.2rem;
    margin-top: 2px;
    animation: bounce 1.7s infinite;
    color: #ffffff;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.3);
}

.question-retenter {
    font-family: 'Quicksand', sans-serif;
    font-size: 1.3rem;
    color: #e06fa7;
    text-align: center;
    margin-bottom: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-top: 48px;
}

.reponse-btns {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 0;
    margin-bottom: 0;
    margin-top: 8px;
}

.reponse-btns .btn-non, .reponse-btns .btn-oui {
    font-family: 'Quicksand', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    border: none;
    border-radius: 24px;
    padding: 14px 38px;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.07);
    transition: transform 0.1s, box-shadow 0.2s;
}

.reponse-btns .btn-non {
    background: linear-gradient(135deg, #ff6b6b, #ff3b3b);
    color: #fff;
}

.reponse-btns .btn-oui {
    background: linear-gradient(135deg, #4be37a, #1ec96b);
    color: #fff;
}

.reponse-btns .btn-non:active, .reponse-btns .btn-oui:active {
    transform: scale(0.96);
    box-shadow: 0 1px 4px rgba(0,0,0,0.10);
} 
.fullscreen-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: black;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

#fullscreen-video-no {
    background: #FDF9FA;
}

.fullscreen-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fullscreen-video img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transform: scale(1.15);
}

@media (min-width: 769px) {
    #fullscreen-video-no img {
        width: auto;
        height: 80vh;
        max-width: 90vw;
        border-radius: 20px;
        box-shadow: 0 5px 30px rgba(0,0,0,0.2);
        transform: scale(1);
    }
}

.hidden {
    display: none;
}

/* Overlay tableau noir */
.blackboard-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #1a1a1a;
    background-image: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(255,255,255,0.03) 2px,
            rgba(255,255,255,0.03) 4px
        );
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.blackboard-text {
    font-family: 'Dancing Script', cursive;
    font-size: 5rem;
    color: #ffffff;
    text-shadow: 
        0 0 8px rgba(255,255,255,0.8),
        0 0 15px rgba(255,255,255,0.5);
    opacity: 0.9;
    transform: rotate(-2deg);
    animation: chalkWrite 2s ease-out;
}

@keyframes chalkWrite {
    0% {
        opacity: 0;
        transform: rotate(-2deg) scale(0.8);
    }
    100% {
        opacity: 0.9;
        transform: rotate(-2deg) scale(1);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .blackboard-text {
        font-size: 3rem;
    }
}

/* Clowns flottants */
.floating-clown {
    position: absolute;
    font-size: 3rem;
    animation: float 20s infinite ease-in-out;
    opacity: 0.8;
    z-index: 10000;
}

.floating-clown img {
    width: 60px;
    height: 60px;
    display: block;
    object-fit: contain;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(100px, -50px) rotate(180deg);
    }
    50% {
        transform: translate(-150px, 100px) rotate(360deg);
    }
    75% {
        transform: translate(200px, 150px) rotate(540deg);
    }
}

.clown-1 {
    top: 10%;
    left: 10%;
    animation-duration: 15s;
    animation-delay: 0s;
}

.clown-2 {
    top: 20%;
    right: 15%;
    animation-duration: 18s;
    animation-delay: 2s;
    animation-direction: reverse;
}

.clown-3 {
    bottom: 30%;
    left: 20%;
    animation-duration: 22s;
    animation-delay: 1s;
}

.clown-4 {
    top: 40%;
    right: 10%;
    animation-duration: 16s;
    animation-delay: 3s;
    font-size: 4rem;
}

.clown-4 img {
    width: 80px;
    height: 80px;
}

.clown-5 {
    bottom: 20%;
    right: 25%;
    animation-duration: 19s;
    animation-delay: 0.5s;
    animation-direction: reverse;
}

.clown-6 {
    top: 60%;
    left: 5%;
    animation-duration: 17s;
    animation-delay: 1.5s;
    font-size: 2.5rem;
}

.clown-6 img {
    width: 50px;
    height: 50px;
}

.clown-7 {
    top: 15%;
    left: 50%;
    animation-duration: 21s;
    animation-delay: 2.5s;
}

.clown-8 {
    bottom: 10%;
    left: 40%;
    animation-duration: 14s;
    animation-delay: 0s;
    animation-direction: reverse;
    font-size: 3.5rem;
}

.clown-8 img {
    width: 70px;
    height: 70px;
}

/* Animation supplémentaire pour certains clowns */
.clown-2, .clown-5, .clown-8 {
    animation-name: floatComplex;
}

@keyframes floatComplex {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
    }
    20% {
        transform: translate(-100px, -100px) rotate(120deg) scale(1.2);
    }
    40% {
        transform: translate(150px, -50px) rotate(240deg) scale(0.8);
    }
    60% {
        transform: translate(-200px, 100px) rotate(360deg) scale(1.1);
    }
    80% {
        transform: translate(100px, 150px) rotate(480deg) scale(0.9);
    }
}

/* Responsive pour les clowns */
@media (max-width: 768px) {
    .floating-clown {
        font-size: 2rem;
    }
    .floating-clown img {
        width: 40px;
        height: 40px;
    }
    .clown-4 {
        font-size: 2.5rem;
    }
    .clown-4 img {
        width: 50px;
        height: 50px;
    }
    .clown-8 {
        font-size: 2.2rem;
    }
    .clown-8 img {
        width: 45px;
        height: 45px;
    }
}

/* Section Vidéo */
#video {
    background: rgba(255, 255, 255, 0.12);
}

/* Section bottom */
#bottom {
    background: rgba(255, 255, 255, 0.12);
}

/* Éléments flottants globaux */
.global-floating-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 5;
    overflow: hidden;
}

/* Cœurs globaux */
.global-hearts {
    position: absolute;
    width: 100%;
    height: 100%;
}

.global-hearts::before,
.global-hearts::after {
    content: '💕';
    position: absolute;
    font-size: 25px;
    animation: floatGlobalHeart 12s infinite ease-in-out;
    opacity: 0;
}

.global-hearts::before {
    left: 15%;
    top: -50px;
    animation-delay: 0s;
}

.global-hearts::after {
    left: 75%;
    top: -50px;
    animation-delay: 6s;
}

@keyframes floatGlobalHeart {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 0;
    }
    5% {
        opacity: 0.8;
    }
    95% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(110vh) rotate(360deg);
        opacity: 0;
    }
}

/* Nuages globaux */
.global-clouds {
    position: absolute;
    width: 100%;
    height: 100%;
}

.global-cloud {
    position: absolute;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 100px;
    opacity: 0.7;
    animation: driftGlobal 25s infinite linear;
}

.global-cloud::before {
    content: '';
    position: absolute;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 100px;
}

.gc-1 {
    width: 120px;
    height: 50px;
    top: 15%;
    left: -150px;
    animation-duration: 30s;
    animation-delay: 0s;
}

.gc-1::before {
    width: 60px;
    height: 60px;
    top: -30px;
    left: 20px;
}

.gc-2 {
    width: 90px;
    height: 40px;
    top: 40%;
    left: -150px;
    animation-duration: 35s;
    animation-delay: 5s;
}

.gc-2::before {
    width: 70px;
    height: 50px;
    top: -25px;
    right: 15px;
}

.gc-3 {
    width: 110px;
    height: 45px;
    top: 65%;
    left: -150px;
    animation-duration: 28s;
    animation-delay: 10s;
}

.gc-3::before {
    width: 55px;
    height: 55px;
    top: -28px;
    left: 25px;
}

.gc-4 {
    width: 100px;
    height: 42px;
    top: 25%;
    left: -150px;
    animation-duration: 32s;
    animation-delay: 15s;
}

.gc-4::before {
    width: 65px;
    height: 45px;
    top: -22px;
    right: 20px;
}

.gc-5 {
    width: 95px;
    height: 38px;
    top: 80%;
    left: -150px;
    animation-duration: 27s;
    animation-delay: 8s;
}

.gc-5::before {
    width: 50px;
    height: 50px;
    top: -26px;
    left: 15px;
}

@keyframes driftGlobal {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(calc(100vw + 200px));
    }
}

/* Responsive pour éléments globaux */
@media (max-width: 768px) {
    .global-hearts::before,
    .global-hearts::after {
        font-size: 20px;
    }
    
    .global-cloud {
        opacity: 0.5;
    }
    
    .gc-1, .gc-2, .gc-3, .gc-4, .gc-5 {
        transform: scale(0.7);
    }
}
