*{
margin:0;
padding:0;
box-sizing:border-box;
font-family:'Poppins',sans-serif;
scroll-behavior:smooth;
}

:root{
--bg:#fff5f7;
--text:#222;
--card:#ffffff;
--primary:#ff4d6d;
--secondary:#ff8fa3;
}

.dark{
--bg:#111827;
--text:#ffffff;
--card:#1f2937;
--primary:#ff758f;
--secondary:#ff4d6d;
}

body{
background:var(--bg);
color:var(--text);
overflow-x:hidden;
transition:.4s;
}

#loader{
position:fixed;
inset:0;
background:#000;
color:#fff;
display:flex;
flex-direction:column;
justify-content:center;
align-items:center;
z-index:9999;
}

.heart-loader{
font-size:70px;
animation:pulse 1s infinite;
}

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

header{
position:fixed;
top:0;
left:0;
width:100%;
z-index:999;
background:rgba(255,255,255,.15);
backdrop-filter:blur(10px);
}

nav{
display:flex;
justify-content:space-between;
align-items:center;
padding:15px 8%;
}

.logo{
font-size:1.3rem;
font-weight:700;
color:white;
}

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

nav a{
text-decoration:none;
color:white;
font-weight:500;
}

#themeBtn{
border:none;
padding:10px 14px;
border-radius:50%;
cursor:pointer;
}

.hero{
height:100vh;
position:relative;
overflow:hidden;
display:flex;
justify-content:center;
align-items:center;
text-align:center;
color:white;
}

#bgVideo{
position:absolute;
width:100%;
height:100%;
object-fit:cover;
z-index:-2;
}

.overlay{
position:absolute;
inset:0;
background:rgba(0,0,0,.45);
z-index:-1;
}

.hero-content{
max-width:900px;
padding:20px;
}

.hero h1{
font-size:4rem;
margin-bottom:20px;
}

.hero h2{
height:40px;
font-size:1.4rem;
font-weight:300;
margin-bottom:20px;
}

.btn{
display:inline-block;
padding:14px 30px;
background:var(--primary);
color:white;
border-radius:40px;
text-decoration:none;
transition:.3s;
}

.btn:hover{
transform:translateY(-5px);
}

.quote-slider{
margin:20px auto;
max-width:700px;
min-height:70px;
}

.quote{
display:none;
font-size:1.2rem;
}

.quote.active{
display:block;
animation:fade 1s;
}

@keyframes fade{
from{
opacity:0;
}
to{
opacity:1;
}
}

section{
padding:90px 10%;
}

section h2{
text-align:center;
margin-bottom:40px;
font-size:2.2rem;
color:var(--primary);
}

.counter-grid{
display:grid;
grid-template-columns:repeat(auto-fit,minmax(130px,1fr));
gap:20px;
}

.counter-grid div{
background:var(--card);
padding:30px;
border-radius:20px;
text-align:center;
box-shadow:0 5px 15px rgba(0,0,0,.1);
}

.counter-grid span{
font-size:2rem;
font-weight:700;
color:var(--primary);
}

.timeline{
display:flex;
flex-direction:column;
gap:20px;
}

.timeline-item{
width:100%;
max-width:350px;
padding:20px;
font-size:18px;
font-weight:600;
color:#333;
text-align:left;
cursor:pointer;
background:white;
border:none;
border-radius:20px;
margin:15px auto;
box-shadow:0 5px 15px rgba(0,0,0,.1);
}

.profile-grid{
display:grid;
grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
gap:30px;
}

.profile-card{
background:var(--card);
padding:20px;
border-radius:20px;
text-align:center;
box-shadow:0 5px 15px rgba(0,0,0,.1);
}

.profile-card img{
width:100%;
height:320px;
object-fit:cover;
border-radius:15px;
}

.gallery{
column-count:3;
column-gap:15px;
}

.gallery img{
width:100%;
margin-bottom:15px;
border-radius:15px;
cursor:pointer;
transition:.4s;
}

.gallery img:hover{
transform:scale(1.03);
}

#lightbox{
display:none;
position:fixed;
inset:0;
background:rgba(0,0,0,.9);
justify-content:center;
align-items:center;
z-index:9999;
}

#lightbox img{
max-width:90%;
max-height:90%;
border-radius:20px;
}

#closeLightbox{
position:absolute;
top:30px;
right:40px;
font-size:40px;
color:white;
cursor:pointer;
}

.envelope {
  max-width: 700px;
  margin: auto;
  background: var(--card);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0,0,0,0.2);
  cursor: pointer;
  position: relative;
  transform: scale(1);
  transition: 0.4s;
}

/* hover glow */
.envelope:hover {
  transform: scale(1.02);
  box-shadow: 0 20px 60px rgba(255, 77, 109, 0.3);
}

/* front */
.envelope-front {
  padding: 45px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  text-align: center;
  font-size: 1.4rem;
  font-weight: bold;
}

/* letter */
.letter-content {
  display: none;
  padding: 30px;
  line-height: 1.8;
  font-size: 16px;
  background: white;
  color: #333;
  position: relative;
  animation: openPaper 0.8s ease;
}

/* OPEN STATE */
.envelope.open {
  transform: scale(1.03);
}

/* reveal */
.envelope.open .letter-content {
  display: block;
}

/* hide front */
.envelope.open .envelope-front {
  display: none;
}

/* paper opening animation */
@keyframes openPaper {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

audio{
display:block;
margin:auto;
width:100%;
max-width:600px;
}

#loveNote{
max-width:700px;
margin:auto;
padding:25px;
background:var(--card);
border-radius:15px;
text-align:center;
box-shadow:0 5px 15px rgba(0,0,0,.1);
}

button{
display:block;
margin:20px auto;
padding:12px 25px;
border:none;
background:var(--primary);
color:white;
border-radius:30px;
cursor:pointer;
}

#secretPass,
#guestInput{
display:block;
margin:auto;
width:100%;
max-width:400px;
padding:12px;
border:1px solid #ccc;
border-radius:10px;
}

#secretContent{
display:none;
margin-top:20px;
text-align:center;
font-size:1.2rem;
}

iframe{
width:100%;
height:400px;
border:none;
border-radius:20px;
}

#bucket ul{
max-width:700px;
margin:auto;
}

#bucket li{
background:var(--card);
margin:10px 0;
padding:15px;
border-radius:15px;
list-style:none;
}

.badges{
display:flex;
justify-content:center;
flex-wrap:wrap;
gap:15px;
}

.badge{
padding:15px 25px;
background:var(--primary);
color:white;
border-radius:30px;
}

#guestList{
max-width:700px;
margin:auto;
margin-top:20px;
}

#guestList li{
background:var(--card);
padding:12px;
margin-bottom:10px;
border-radius:10px;
list-style:none;
}

footer{
background:var(--primary);
color:white;
text-align:center;
padding:30px;
}

.heart{
position:fixed;
font-size:24px;
animation:floatHeart 8s linear forwards;
pointer-events:none;
}

@keyframes floatHeart{
0%{
transform:translateY(100vh);
opacity:1;
}
100%{
transform:translateY(-120px);
opacity:0;
}
}

.petal{
position:fixed;
font-size:18px;
animation:fallPetal 10s linear infinite;
pointer-events:none;
}

@keyframes fallPetal{
0%{
transform:translateY(-50px) rotate(0);
}
100%{
transform:translateY(110vh) rotate(360deg);
}
}

@media(max-width:768px){

.hero h1{
font-size:2.2rem;
}

.gallery{
column-count:2;
}

nav ul{
display:none;
}

section{
padding:80px 20px;
}

}

@media(max-width:500px){

.gallery{
column-count:1;
}

.hero h1{
font-size:1.8rem;
}

.counter-grid{
grid-template-columns:repeat(2,1fr);
}

}


.modal{
display:none;
position:fixed;
top:0;
left:0;
width:100%;
height:100%;
background:rgba(0,0,0,.8);
justify-content:center;
align-items:center;
z-index:9999;
}

.modal-content{
background:white;
padding:30px;
border-radius:20px;
width:90%;
max-width:600px;
text-align:center;
}

.close{
font-size:35px;
cursor:pointer;
float:right;
}

#chat {
  max-width: 600px;
  margin: auto;
}

#chatBox {
  background: var(--card);
  padding: 15px;
  border-radius: 20px;
  min-height: 300px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* MESSAGE ROW */
.msg {
  padding: 10px 14px;
  border-radius: 18px;
  max-width: 75%;
  font-size: 15px;
  position: relative;
  animation: pop .2s ease;
  line-height: 1.4;
}

/* YOU (RIGHT SIDE - BLUE STYLE LIKE MESSENGER) */
.me {
  align-self: flex-end;
  background: linear-gradient(135deg, #ff4d6d, #ff758f);
  color: white;
  border-bottom-right-radius: 5px;
}

/* HER (LEFT SIDE - GREY STYLE) */
.her {
  align-self: flex-start;
  background: #e4e6eb;
  color: #111;
  border-bottom-left-radius: 5px;
}

/* POP ANIMATION */
@keyframes pop {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* BUTTON STYLE */
#chat button {
  margin-top: 15px;
  padding: 12px 20px;
  border: none;
  border-radius: 30px;
  background: var(--primary);
  color: white;
  cursor: pointer;
}

#secretContent {
  display: none;
  margin-top: 20px;
  padding: 20px;
  border-radius: 15px;
  background: var(--primary);
  color: white;
  animation: glow 1.5s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    box-shadow: 0 0 10px var(--primary);
  }
  to {
    box-shadow: 0 0 25px var(--secondary);
  }
}

