@import url("https://fonts.googleapis.com/css2?family=Bilbo+Swash+Caps&family=Poppins:wght@900&display=swap");

*,
*:after,
*:before {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-transition: all 100ms ease-in;
  transition: all 100ms ease-in;
}

body {
  background-color: #000;
  overflow: hidden;
  height: 100vh;
}

.msg {
  width: 100%;
  font-family: "Bilbo Swash Caps", cursive;
  font-size: 100px;
  font-weight: bolder;
  color: #ff00c3;
  text-align: center;
  position: absolute;
  top: 50%;
  opacity: 0;
  animation: message 2s ease-in-out 6s forwards;
}

@keyframes message { 
  0% {
    opacity: 0;
    margin-top: 0;
  }
  100% {
    opacity: 1;
    margin-top: -200px;
  }
}

.y1 {
  color: #fff;
  animation: y1colorful 2s ease-in-out 5.75s forwards;
}
.y2 {
  color: #fff;
  animation: y2colorful 2s ease-in-out 5.75s forwards;
}
.y3 {
  color: #fff;
  animation: y3colorful 2s ease-in-out 5.75s forwards;
}
.y4 {
  color: #fff;
  animation: y4colorful 2s ease-in-out 5.75s forwards;
}

@keyframes y1colorful {
    0% {
        color: #fff;
    }
    100% {
        color: orange;
    }
}
@keyframes y2colorful {
    0% {
        color: #fff;
    }
    100% {
        color: #4cdde2;
    }
}
@keyframes y3colorful {
    0% {
        color: #fff;
    }
    100% {
        color: #ff94a6;
    }
}
@keyframes y4colorful {
    0% {
        color: #fff;
    }
    100% {
        color: yellow;
    }
}

.old {
  color: #fff;
  position: absolute;
  top: 0%;
  animation: old_animation 2.5s ease-in-out 4s forwards;
  margin-left: -80px;
}

@keyframes old_animation {
  0% {
    top: 0%;
  }
  100% {
    top: -250%;
  }
}

.year {
  position: absolute;
  top: 300px;
  width: 100%;
  text-align: center;
  align-items: center;
  justify-content: center;
}

.year > span {
  font-size: 175px;
  font-weight: 700;
  font-family: "Poppins", sans-serif;
  letter-spacing: -12px;
}

.first_year {
  margin-right: 100px;
}

.new {
  position: absolute;
  right: -100px;
  animation: new_animation 5s ease-in-out 1.5s forwards;
}

@keyframes new_animation {
  0% {
    right: -100px;
  }
  40% {
    right: 335px;
  }
  
  100% {
    right: 730px;
    color: yellow;
  }
}

.balloon {
  width: 100px;
  height: 120px;
  border-radius: 50%;
  background-color: red;
  position: absolute;
  top: 50%;
  right: -100px;
  margin-top: -285px;
  animation: balloon_animation 5s ease-in-out 1.5s forwards;
}

.balloon::after {
  content: "";
  width: 4px;
  height: 100px;
  background-color: #fff;
  position: absolute;
  left: 50%;
  margin-left: -2px;
  bottom: -100px;
}

.balloon::before {
  content: "";
  border-style: solid;
  border-width: 0 10px 20px 10px;
  border-color: transparent transparent #fd3553 transparent;
  position: absolute;
  left: 50%;
  bottom: -10px;
  margin-left: -10px;
}

/* @keyframes balloon_animation {
  0% {
    right: -100px;
  }
  40% {
    right: 335px;
  }
  50% {
    right: 735px;
    top: 50%;
  }
  100% {
    right: 35px;
    top: -200%;
  } */


.firework {
    position: relative;
    opacity: 0;
    animation: show_fireworks 2s ease-in-out 5s forwards;
}

@keyframes show_fireworks {
    0% {
        opacity: 0;
    }
    99% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

.cracker {
    position: absolute;
    width: 4px;
    height: 80px;
    transform-origin: 50% 100%;
    overflow: hidden;
}

.cracker::before {
    content: '';
    background-color: gold;
    height: 40px;
    position: absolute;
    left: 0;
    right: 0;
    animation: fire 2s ease-in-out infinite;
}

@keyframes fire {
    0% {
        top: 100%;
    }
    25% {
        top: 50%;
    }
    50% {
        top: -25%;
    }
    75% {
        top: -50%;
    }
    100% {
        top: -50%;
    }
}

.cracker:nth-child(1) {
    transform: rotate(0deg) translateY(-15px);
}
.cracker:nth-child(2) {
    transform: rotate(30deg) translateY(-15px);
}
.cracker:nth-child(3) {
    transform: rotate(60deg) translateY(-15px);
}
.cracker:nth-child(4) {
    transform: rotate(90deg) translateY(-15px);
}
.cracker:nth-child(5) {
    transform: rotate(120deg) translateY(-15px);
}
.cracker:nth-child(6) {
    transform: rotate(150deg) translateY(-15px);
}
.cracker:nth-child(7) {
    transform: rotate(180deg) translateY(-15px);
}
.cracker:nth-child(8) {
    transform: rotate(210deg) translateY(-15px);
}
.cracker:nth-child(9) {
    transform: rotate(240deg) translateY(-15px);
}
.cracker:nth-child(10) {
    transform: rotate(270deg) translateY(-15px);
}
.cracker:nth-child(11) {
    transform: rotate(300deg) translateY(-15px);
}
.cracker:nth-child(12) {
    transform: rotate(330deg) translateY(-15px);
}

#firework1 {
    left: 25%;
    top: 50%;
    transform: scale(1);
}

#firework2 {
    left: 50%;
    top: 75%;
    transform: scale(0.5);
}

#firework3 {
    left: 80%;
    top: 15%;
    transform: scale(1.5);
}

/* Memories Slideshow */
.memories-slideshow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.memories-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/assets/newyear/bg-2.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -2;
}

.memories-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: -1;
}

.memories-title {
    font-family: "Bilbo Swash Caps", cursive;
    font-size: 48px;
    color: #ff00c3;
    text-align: center;
    margin-bottom: 30px;
    z-index: 1;
    animation: fadeInDown 1s ease-out;
}

.memories-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 0, 195, 0.5);
    border: 2px solid #ff00c3;
    color: #fff;
    font-size: 40px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    line-height: 1;
}

.memories-close:hover {
    background: rgba(255, 0, 195, 0.8);
    transform: scale(1.1);
}

.memories-prev,
.memories-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 0, 195, 0.5);
    border: 2px solid #ff00c3;
    color: #fff;
    font-size: 50px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    line-height: 1;
    border: none;
}

.memories-prev {
    left: 20px;
}

.memories-next {
    right: 20px;
}

.memories-prev:hover,
.memories-next:hover {
    background: rgba(255, 0, 195, 0.8);
    transform: translateY(-50%) scale(1.1);
}

.memories-container {
    width: 100%;
    max-width: 100%;
    height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    overflow: hidden;
    z-index: 1;
    padding: 0;
    position: relative;
    touch-action: pan-y pinch-zoom;
}

.memories-container::-webkit-scrollbar {
    height: 8px;
}

.memories-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.memories-container::-webkit-scrollbar-thumb {
    background: rgba(255, 0, 195, 0.5);
    border-radius: 10px;
}

.memory-image-wrapper {
    flex: 0 0 auto;
    width: 100%;
    height: 100%;
    cursor: pointer;
    transition: transform 0.3s ease, opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin: 0 auto;
}

.memory-image-wrapper:hover {
    transform: scale(1.02);
}

.memory-image-wrapper img {
    width: auto;
    height: auto;
    max-width: 95vw;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(255, 0, 195, 0.3);
    transition: all 0.3s ease;
    display: block;
    margin: 0 auto;
}

.memory-image-wrapper:hover img {
    box-shadow: 0 15px 50px rgba(255, 0, 195, 0.5);
}

.memories-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    font-family: "Poppins", sans-serif;
    font-size: 18px;
    color: #fff;
    background: rgba(255, 0, 195, 0.3);
    padding: 10px 20px;
    border-radius: 20px;
    z-index: 1;
}

@keyframes fadeInDown {
    0% {
        opacity: 0;
        transform: translateY(-30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Lightbox Modal */
.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.95);
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid #fff;
    color: #fff;
    font-size: 40px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    line-height: 1;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid #fff;
    color: #fff;
    font-size: 50px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    line-height: 1;
    border: none;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-container {
    width: 90%;
    max-width: 1400px;
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(255, 0, 195, 0.5);
    animation: fadeIn 0.3s ease;
}

.lightbox-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    font-family: "Poppins", sans-serif;
    font-size: 18px;
    color: #fff;
    background: rgba(255, 0, 195, 0.5);
    padding: 10px 20px;
    border-radius: 20px;
    z-index: 20001;
}

@keyframes fadeIn {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .memories-title {
        font-size: 32px;
        margin-bottom: 20px;
    }
    
    .memories-container {
        height: 60vh;
        width: 95%;
        gap: 15px;
    }
    
    .memory-image-wrapper {
        width: calc(50% - 8px);
        min-width: 250px;
    }
    
    .memories-counter {
        font-size: 14px;
        padding: 8px 16px;
        bottom: 20px;
    }
    
    .memories-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 30px;
    }
    
    .lightbox-prev,
    .lightbox-next {
        width: 50px;
        height: 50px;
        font-size: 40px;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 30px;
    }
}