/* ==========================================
   MEMORY WISHES V2 ULTIMATE
   STYLE.CSS
   PART 3A
========================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Dancing+Script:wght@700&display=swap');

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

:root{

    --bg1:#fdeff4;
    --bg2:#f8e8ff;
    --bg3:#eef8ff;

    --card:rgba(255,255,255,.45);

    --text:#5a4563;
    --accent:#ff77aa;
    --accent2:#b58cff;

    --shadow:0 20px 50px rgba(0,0,0,.12);

}

html{

    scroll-behavior:smooth;

}

body{

    font-family:'Poppins',sans-serif;

    color:var(--text);

    overflow:hidden;

    background:
    linear-gradient(
    135deg,
    var(--bg1),
    var(--bg2),
    var(--bg3));

    min-height:100vh;

}

/* =========================
   BACKGROUND
========================= */

#hearts,
#confetti,
#balloons,
#fireworks,
#sky{

    position:fixed;

    inset:0;

    pointer-events:none;

}

#moon{

    position:absolute;

    top:60px;

    right:70px;

    width:90px;

    height:90px;

    border-radius:50%;

    background:#fffdf3;

    box-shadow:
    0 0 25px #fff,
    0 0 60px #fff7b3;

}

.star{

    position:absolute;

    width:4px;

    height:4px;

    background:white;

    border-radius:50%;

    animation:twinkle 2.5s infinite;

}

.star:nth-child(2){top:12%;left:15%;}
.star:nth-child(3){top:22%;left:65%;}
.star:nth-child(4){top:35%;left:35%;}
.star:nth-child(5){top:10%;left:82%;}
.star:nth-child(6){top:42%;left:90%;}
.star:nth-child(7){top:18%;left:48%;}
.star:nth-child(8){top:30%;left:75%;}
.star:nth-child(9){top:25%;left:8%;}

@keyframes twinkle{

    0%,100%{

        opacity:.3;
        transform:scale(.8);

    }

    50%{

        opacity:1;
        transform:scale(1.5);

    }

}

/* =========================
   PAGES
========================= */

.page{

    position:absolute;

    inset:0;

    display:none;

    justify-content:center;

    align-items:center;

    flex-direction:column;

    padding:30px;

    text-align:center;

    overflow-y: auto;
-webkit-overflow-scrolling: touch;

}

.page.active{

    display:flex;

    animation:fadePage .8s ease;

}

@keyframes fadePage{

    from{

        opacity:0;
        transform:translateY(25px);

    }

    to{

        opacity:1;
        transform:translateY(0);

    }

}

/* =========================
   GLASS CARD
========================= */

.welcome-box,
#typingText,
#letterContent,
#duaContent{

    width:min(92%,850px);

    background:var(--card);

    backdrop-filter:blur(18px);

    border-radius:28px;

    padding:35px;

    box-shadow:var(--shadow);

    border:1px solid rgba(255,255,255,.6);

}

.welcome-box h1{

    font-family:'Dancing Script',cursive;

    font-size:4rem;

    color:var(--accent);

    margin-bottom:15px;

}

.welcome-box p{

    font-size:1.1rem;

    line-height:1.8;

    margin-bottom:30px;

}
/* ==========================================
   STYLE.CSS
   PART 3B
========================================== */

/* =========================
   BUTTONS
========================= */

button{

    border:none;

    outline:none;

    cursor:pointer;

    font-family:'Poppins',sans-serif;

    font-size:1rem;

    padding:14px 34px;

    border-radius:50px;

    background:linear-gradient(135deg,var(--accent),var(--accent2));

    color:#fff;

    box-shadow:0 10px 25px rgba(181,140,255,.35);

    transition:.3s;

}

button:hover{

    transform:translateY(-4px) scale(1.03);

}

.nextBtn{

    margin-top:30px;

}

/* =========================
   GALLERY
========================= */

.gallery-container{

    width:100%;

    max-width:1100px;

    display:flex;

    justify-content:center;

    align-items:center;

    gap:25px;

    margin-top:30px;

}

.gallery-container button{

    width:60px;

    height:60px;

    padding:0;

    border-radius:50%;

    font-size:1.6rem;

    flex-shrink:0;

}

/* =========================
   PHOTO
========================= */

#memoryPhoto{

    width:min(90vw,650px);

    height:min(70vh,650px);

    object-fit:contain;      /* Face cut ஆகாது */

    object-position:center;

    background:#ffffff;

    border-radius:28px;

    padding:10px;

    box-shadow:0 20px 50px rgba(0,0,0,.15);

    transition:.4s;

    cursor:pointer;


}

#memoryPhoto:hover{

    transform:scale(1.02);

}

/* =========================
   PROGRESS BAR
========================= */

.progress{

    width:min(500px,90%);

    height:10px;

    background:rgba(255,255,255,.5);

    border-radius:20px;

    overflow:hidden;

    margin-top:25px;

}

#progressFill{

    width:0%;

    height:100%;

    border-radius:20px;

    background:linear-gradient(90deg,var(--accent),var(--accent2));

    transition:.4s;

}

/* =========================
   POPUP
========================= */

#popup{

    position:fixed;

    inset:0;

    background:rgba(0,0,0,.88);

    display:none;

    justify-content:center;

    align-items:center;

    z-index:9999;

}

#popup.active{

    display:flex;

}

#popup img{

    width:95%;

    height:95%;

    object-fit:contain;

}

#popup span{

    position:absolute;

    top:20px;

    right:25px;

    font-size:2rem;

    color:#fff;

    cursor:pointer;

}

/* =========================
   MUSIC BUTTON
========================= */

#musicBtn{

    position:fixed;

    top:20px;

    right:20px;

    width:55px;

    height:55px;

    padding:0;

    border-radius:50%;

    z-index:999;

}
/* ==========================================
   STYLE.CSS
   PART 3C
========================================== */

/* =========================
   POEM / LETTER / DUA
========================= */

#typingText,
#letterContent,
#duaContent{

    font-size:1.15rem;

    line-height:2;

    white-space:pre-wrap;

    text-align:left;

    max-height:65vh;

    overflow-y:auto;

}

#typingText{

    text-align:center;

    font-size:1.35rem;

    font-weight:500;

}

/* =========================
   CAKE
========================= */

#cakePage h2{

    font-family:'Dancing Script',cursive;

    font-size:3.5rem;

    color:var(--accent);

    margin-bottom:25px;

}

#cakeImage{

    width:min(420px,85vw);

    filter:drop-shadow(0 20px 35px rgba(0,0,0,.18));

    animation:floatCake 3s ease-in-out infinite;

}

@keyframes floatCake{

    0%,100%{

        transform:translateY(0);

    }

    50%{

        transform:translateY(-12px);

    }

}
/* ==========================================
   VOICE PAGE
========================================== */

#voicePage{

    background: linear-gradient(180deg,#0d0d0d,#1a0015);

}

.voice-box{

    max-width:700px;
    animation:fadePage 1s ease;

}

.voice-box h1{

    font-size:90px;
    margin-bottom:20px;

}

.voice-box h2{

    font-size:42px;
    color:#ffffff;
    margin-bottom:15px;

}

.voice-box p{

    font-size:22px;
    color:#ffd6e7;
    line-height:1.8;

}


/* =========================
   CELEBRATION
========================= */

#celebrationPage h1{

    font-family:'Dancing Script',cursive;

    font-size:4rem;

    color:var(--accent);

    margin-bottom:20px;

}

#celebrationPage p{

    max-width:700px;

    line-height:2;

    font-size:1.2rem;

}

/* =========================
   HEARTS
========================= */

.heart{

    position:absolute;

    bottom:-60px;

    animation:heartFloat linear forwards;

    opacity:.9;

}

@keyframes heartFloat{

    from{

        transform:translateY(0) rotate(0deg);

        opacity:1;

    }

    to{

        transform:translateY(-120vh) rotate(360deg);

        opacity:0;

    }

}

/* ---------- BALLOONS CONTAINER ---------- */

#balloons{

    position:fixed;

    inset:0;

    overflow:hidden;

    pointer-events:none;

    z-index:1;

}

/* =========================
   BALLOONS
========================= */


.balloon{

    position:absolute;

    bottom:-140px;

    width:70px;

    height:90px;

    border-radius:50%;

    animation:balloonUp 16s linear infinite;

    z-index:1;
    pointer-events:none;

}

.balloon::after{

    content:"";

    position:absolute;

    width:2px;

    height:80px;

    background:#999;

    left:50%;

    top:90px;

}

.balloon1{

    left:8%;

    background:#ffb3d9;

}

.balloon2{

    left:28%;

    background:#b8d8ff;

    animation-delay:2s;

}

.balloon3{

    left:48%;

    background:#e5c7ff;

    animation-delay:4s;

}

.balloon4{

    left:68%;

    background:#ffe7a3;

    animation-delay:6s;

}

.balloon5{

    left:88%;

    background:#c6ffd4;

    animation-delay:8s;

}

@keyframes balloonUp{

    from{

        transform:translateY(0);

    }

    to{

        transform:translateY(-130vh);

    }

}

/* =========================
   SCROLLBAR
========================= */

::-webkit-scrollbar{

    width:8px;

}

::-webkit-scrollbar-thumb{

    background:var(--accent);

    border-radius:10px;

}

/* =========================
   RESPONSIVE
========================= */

@media(max-width:768px){

    .welcome-box h1{

        font-size:2.8rem;

    }

    .gallery-container{

        gap:12px;

    }

    .gallery-container button{

        width:48px;

        height:48px;

        font-size:1.2rem;

    }

    #memoryPhoto{

        width:95vw;

        height:60vh;

    }

    #typingText,
    #letterContent,
    #duaContent{

        font-size:1rem;

        padding:24px;

    }

    #cakeImage{

        width:300px;

    }

    #celebrationPage h1{

        font-size:2.8rem;

    }

}

.welcome-box,
.gallery-container,
.poem-box,
.letter-box,
.dua-box,
.voice-box,
.celebration-box{

    position: relative;
    z-index: 10;

}
.content-box{

    position: relative;
    z-index: 10;

    width: 100%;
    max-width: 900px;

    margin: auto;

}
/* ==========================================
   END OF STYLE.CSS
========================================== */