/* ===== RESET & BASE ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Comfortaa', cursive;
    background: #fdf2f8;
    color: #5c4a5a;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ===== MESH GRADIENT BACKGROUND ===== */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background:
        radial-gradient(ellipse 80% 60% at 10% 20%, rgba(253, 185, 200, 0.5) 0%, transparent 60%),
        radial-gradient(ellipse 60% 80% at 90% 30%, rgba(196, 181, 253, 0.4) 0%, transparent 60%),
        radial-gradient(ellipse 70% 50% at 50% 80%, rgba(254, 215, 170, 0.4) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 30% 60%, rgba(251, 207, 232, 0.3) 0%, transparent 50%);
    background-color: #fdf2f8;
    animation: meshMove 20s ease-in-out infinite alternate;
}

@keyframes meshMove {
    0% {
        background:
            radial-gradient(ellipse 80% 60% at 10% 20%, rgba(253, 185, 200, 0.5) 0%, transparent 60%),
            radial-gradient(ellipse 60% 80% at 90% 30%, rgba(196, 181, 253, 0.4) 0%, transparent 60%),
            radial-gradient(ellipse 70% 50% at 50% 80%, rgba(254, 215, 170, 0.4) 0%, transparent 60%),
            radial-gradient(ellipse 50% 40% at 30% 60%, rgba(251, 207, 232, 0.3) 0%, transparent 50%);
        background-color: #fdf2f8;
    }
    50% {
        background:
            radial-gradient(ellipse 70% 70% at 30% 40%, rgba(253, 185, 200, 0.5) 0%, transparent 60%),
            radial-gradient(ellipse 80% 60% at 70% 20%, rgba(196, 181, 253, 0.45) 0%, transparent 60%),
            radial-gradient(ellipse 60% 60% at 20% 70%, rgba(254, 215, 170, 0.35) 0%, transparent 60%),
            radial-gradient(ellipse 60% 50% at 80% 80%, rgba(251, 207, 232, 0.35) 0%, transparent 50%);
        background-color: #fdf2f8;
    }
    100% {
        background:
            radial-gradient(ellipse 60% 80% at 50% 10%, rgba(253, 185, 200, 0.45) 0%, transparent 60%),
            radial-gradient(ellipse 70% 60% at 20% 50%, rgba(196, 181, 253, 0.5) 0%, transparent 60%),
            radial-gradient(ellipse 80% 40% at 80% 60%, rgba(254, 215, 170, 0.4) 0%, transparent 60%),
            radial-gradient(ellipse 50% 60% at 60% 90%, rgba(251, 207, 232, 0.3) 0%, transparent 50%);
        background-color: #fdf2f8;
    }
}

/* ===== FLOATING PETALS ===== */
.petals-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.floating-petal {
    position: absolute;
    width: 12px;
    height: 12px;
    border-radius: 50% 0 50% 50%;
    opacity: 0.35;
    pointer-events: none;
    animation: floatPetal linear infinite;
}

@keyframes floatPetal {
    0% {
        transform: translateY(0) translateX(0) rotate(0deg) scale(1);
        opacity: 0;
    }
    10% {
        opacity: 0.35;
    }
    90% {
        opacity: 0.35;
    }
    100% {
        transform: translateY(100vh) translateX(80px) rotate(360deg) scale(0.5);
        opacity: 0;
    }
}

/* ===== SECTIONS ===== */
.section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    padding: 40px 20px;
}

.section-inner {
    max-width: 600px;
    width: 100%;
    text-align: center;
}

/* ===== REVEAL ANIMATION ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease, transform 1s ease;
}

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

.reveal:nth-child(2) { transition-delay: 0.2s; }
.reveal:nth-child(3) { transition-delay: 0.4s; }
.reveal:nth-child(4) { transition-delay: 0.6s; }

/* ===== HERO SECTION ===== */
.hero {
    flex-direction: column;
    text-align: center;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.hero-title {
    font-size: clamp(1.8rem, 5vw, 3rem);
    font-weight: 600;
    color: #d14d72;
    letter-spacing: -0.5px;
    line-height: 1.3;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    font-weight: 300;
    color: #8b6f7e;
    max-width: 400px;
}

/* ===== FLOWER ANIMATION ===== */
.flower-wrapper {
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.flower {
    position: relative;
    width: 100px;
    height: 100px;
    animation: flowerPulse 4s ease-in-out infinite;
}

@keyframes flowerPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.06); }
}

.petal {
    position: absolute;
    width: 34px;
    height: 34px;
    border-radius: 50% 0 50% 50%;
    top: 50%;
    left: 50%;
    transform-origin: 0% 0%;
    animation: petalBloom 2s ease-out forwards;
    opacity: 0;
}

@keyframes petalBloom {
    0% {
        transform: rotate(var(--rot)) translateX(0) scale(0);
        opacity: 0;
    }
    100% {
        transform: rotate(var(--rot)) translateX(-28px) scale(1);
        opacity: 1;
    }
}

.petal-1 { --rot: 0deg;   background: rgba(244, 163, 184, 0.7); animation-delay: 0.1s; }
.petal-2 { --rot: 45deg;  background: rgba(221, 160, 221, 0.7); animation-delay: 0.2s; }
.petal-3 { --rot: 90deg;  background: rgba(255, 192, 203, 0.7); animation-delay: 0.3s; }
.petal-4 { --rot: 135deg; background: rgba(230, 170, 200, 0.7); animation-delay: 0.4s; }
.petal-5 { --rot: 180deg; background: rgba(244, 163, 184, 0.7); animation-delay: 0.5s; }
.petal-6 { --rot: 225deg; background: rgba(221, 160, 221, 0.7); animation-delay: 0.6s; }
.petal-7 { --rot: 270deg; background: rgba(255, 192, 203, 0.7); animation-delay: 0.7s; }
.petal-8 { --rot: 315deg; background: rgba(230, 170, 200, 0.7); animation-delay: 0.8s; }

.flower-center {
    position: absolute;
    width: 22px;
    height: 22px;
    background: radial-gradient(circle, #ffd6e0, #f8a4c0);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    box-shadow: 0 0 20px rgba(255, 166, 193, 0.5);
    animation: centerGlow 3s ease-in-out infinite alternate;
}

@keyframes centerGlow {
    0% { box-shadow: 0 0 15px rgba(255, 166, 193, 0.4); }
    100% { box-shadow: 0 0 30px rgba(255, 166, 193, 0.8); }
}

/* ===== SCROLL HINT ===== */
.scroll-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 30px;
    font-size: 0.85rem;
    color: #b8a0b0;
    font-weight: 300;
}

.scroll-arrow {
    width: 20px;
    height: 20px;
    border-right: 2px solid #d4a0b9;
    border-bottom: 2px solid #d4a0b9;
    transform: rotate(45deg);
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: rotate(45deg) translateY(0); }
    50% { transform: rotate(45deg) translateY(8px); }
}

/* ===== BUBBLES SECTION ===== */
.bubbles-section {
    min-height: 100vh;
}

.section-title {
    font-size: clamp(1.3rem, 3.5vw, 1.8rem);
    font-weight: 500;
    color: #9b6b8a;
    margin-bottom: 10px;
    line-height: 1.4;
}

.section-subtitle {
    font-size: clamp(0.95rem, 2.5vw, 1.15rem);
    font-weight: 300;
    color: #a8889a;
    margin-bottom: 30px;
}

.bubbles-area {
    position: relative;
    width: 100%;
    max-width: 500px;
    height: 350px;
    margin: 0 auto 20px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    overflow: hidden;
    cursor: pointer;
    touch-action: manipulation;
}

.bubble {
    position: absolute;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.1s ease;
    background: radial-gradient(circle at 30% 30%,
        rgba(255, 255, 255, 0.6),
        rgba(200, 180, 220, 0.2) 50%,
        rgba(255, 182, 210, 0.15) 100%);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow:
        inset 0 0 15px rgba(255, 255, 255, 0.3),
        0 4px 20px rgba(180, 140, 200, 0.15);
    animation: floatBubble ease-in-out infinite;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.bubble::before {
    content: '';
    position: absolute;
    width: 30%;
    height: 30%;
    top: 15%;
    left: 20%;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
}

.bubble:hover {
    transform: scale(1.1);
}

@keyframes floatBubble {
    0%, 100% {
        transform: translateY(0px) translateX(0px);
    }
    25% {
        transform: translateY(-15px) translateX(8px);
    }
    50% {
        transform: translateY(-5px) translateX(-5px);
    }
    75% {
        transform: translateY(-20px) translateX(5px);
    }
}

/* Bubble pop effect */
.bubble-pop {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    animation: popEffect 0.5s ease-out forwards;
}

@keyframes popEffect {
    0% {
        transform: scale(1);
        opacity: 0.6;
        box-shadow: 0 0 0 0 rgba(255, 182, 210, 0.4);
    }
    50% {
        transform: scale(1.8);
        opacity: 0.3;
        box-shadow: 0 0 30px 10px rgba(255, 182, 210, 0.2);
    }
    100% {
        transform: scale(2.5);
        opacity: 0;
        box-shadow: 0 0 0 0 rgba(255, 182, 210, 0);
    }
}

/* Pop sparkles */
.pop-sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    pointer-events: none;
    animation: sparkle 0.6s ease-out forwards;
}

@keyframes sparkle {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(var(--sx), var(--sy)) scale(0);
        opacity: 0;
    }
}

.bubbles-counter {
    font-size: 0.9rem;
    color: #b8a0b0;
    font-weight: 300;
}

.bubbles-counter span {
    font-weight: 600;
    color: #d14d72;
}

/* ===== MESSAGE SECTION ===== */
.message-section {
    min-height: 100vh;
    padding-bottom: 80px;
}

.glass-card {
    position: relative;
    max-width: 480px;
    margin: 0 auto 30px;
    padding: 40px 30px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow:
        0 8px 32px rgba(180, 140, 180, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    overflow: hidden;
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%,
        rgba(255, 182, 210, 0.08) 0%,
        transparent 50%);
    animation: glowRotate 10s linear infinite;
    pointer-events: none;
}

@keyframes glowRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.card-content {
    position: relative;
    z-index: 1;
}

.card-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    animation: heartbeat 2s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.15); }
    30% { transform: scale(1); }
    45% { transform: scale(1.1); }
    60% { transform: scale(1); }
}

.card-text {
    font-size: clamp(1rem, 2.5vw, 1.15rem);
    line-height: 1.8;
    font-weight: 300;
    color: #6b4f6b;
    margin-bottom: 16px;
}

.card-text:last-of-type {
    margin-bottom: 20px;
}

.card-heart {
    font-size: 1.8rem;
}

.footer-text {
    font-size: 0.9rem;
    color: #c4a0b8;
    font-weight: 300;
    letter-spacing: 0.5px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 480px) {
    .section {
        padding: 30px 16px;
    }

    .bubbles-area {
        height: 300px;
    }

    .glass-card {
        padding: 30px 22px;
    }

    .flower-wrapper {
        width: 100px;
        height: 100px;
    }

    .flower {
        width: 80px;
        height: 80px;
    }

    .petal {
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 360px) {
    .bubbles-area {
        height: 260px;
    }
}

/* ===== SMOOTH SCROLL SNAP (optional, subtle) ===== */
@media (min-height: 600px) {
    html {
        scroll-snap-type: y proximity;
    }

    .section {
        scroll-snap-align: start;
    }
}

/* ===== SELECTION COLOR ===== */
::selection {
    background: rgba(209, 77, 114, 0.2);
    color: #5c4a5a;
}
