/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Full-screen layout */
html,
body {
  position: relative;
  margin: 0;
  padding: 0;
  width: 100vw;
  min-height: 100vh;
  margin: 0;
  overflow-y: auto;
  overflow-x: hidden;
  font-family: "Arial", sans-serif;
  background-size: cover;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #262626;
  scroll-behavior: smooth;
}

button {
  border: 1px solid transparent;
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-items: center;
  justify-content: center;
  gap: 4px;
}

h1 {
  color: #7a4e7a;
  font-family: "Galada", cursive;
  font-size: 32px;
  font-weight: 400;
}

p,
i {
  font-size: 14px;
  font-weight: 400;
  font-family: "Nunito Sans", sans-serif;
}

/* Bride and Groom */
#bridegroom {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 18px;
}

/* Event */
#event {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  background-color: #7a4e7a;
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  text-align: center;
  padding: 64px 18px;
}

#gift {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  background-color: #7a4e7a;
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  text-align: center;
  padding: 64px 18px;
}

/* Love Story */
#lovestory {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 18px;
}

#rsvp {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 18px;
}

#thanks {
  position: relative; /* Ensures flower stays inside */
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 18px;
}

/* Invitation (Hidden Initially) */
.container {
  width: 100%;
  min-height: 100vh;
  max-width: 480px;
  background: url("../bg/papper.jpeg") repeat center center;
  background-size: contain;
  text-align: center;
  overflow-y: auto;
  overflow-x: hidden;
}

.container-bridegroom {
  width: 100%;
  /* height: 100%; */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 16px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 4px 4px 0px #00000014;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 10;
}

.container-event {
  position: relative;
  width: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 20px;
  gap: 16px;
  background: url("../bg/papper.jpeg") repeat center center;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 0;
}

.container-event .flower-corner {
  opacity: 50%;
  width: 58px;
  height: 64px;
}

.container-event .flower-top-left,
.container-event .flower-top-right,
.container-event .flower-bottom-left,
.container-event .flower-bottom-right,
.card-gift .shape-top-right {
  border-top-right-radius: 25px;
  z-index: 0;
}

.card-lovestory {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start; /* Align items to the top */
  justify-items: center;
  height: 100%;
  width: 100%;
  text-align: center;
}

.card-lovestory img {
  width: 24px;
  height: 24px;
  background-color: #7a4e7a;
  border-radius: 100%;
  padding: 4px;
}

.card-message {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(6, 1fr); /* 5 equal columns */
  background-color: white;
  border: 1px solid #ebebeb;
  border-radius: 8px;
  padding: 10px 12px;
}

.carousel {
  position: relative;
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.carousel .image-wedding {
  position: absolute;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
}

.carousel .image-wedding.active {
  opacity: 1;
  position: relative;
}

.container-lovestories {
  width: 100%;
  /* height: 100%; */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 16px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 4px 4px 0px #00000014;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 10;
}

.container-lovestory {
  display: grid;
  grid-template-columns: repeat(8, 1fr); /* 8 equal columns */
  gap: 16px; /* Space between columns */
}

.container-wedding {
  display: flex;
  flex-direction: column;
}

.container-wedding p {
  font-size: 14px;
  font-weight: 400;
}

.container-wedding i {
  font-size: 8px;
  font-weight: 400;
  margin-top: 8px;
}

.content-bridegroom {
  width: 100%;
  font-size: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.container-moments {
  width: 100%;
  /* height: 100%; */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 16px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 4px 4px 0px #00000014;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 10;
}

.container-rsvp {
  width: 100%;
  /* height: 100%; */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 16px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 4px 4px 0px #00000014;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 10;
}

.container-thanks {
  width: 100%;
  /* height: 100%; */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 16px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 4px 4px 0px #00000014;
  border: 1px solid #ffffff;
  border-radius: 20px;
  z-index: 10;
}

.card-gift {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  background-color: white;
  text-align: left;
  justify-items: start;
  justify-content: start;
  gap: 8px;
  border-radius: 16px;
  margin-top: 16px;
  align-items: start; /* Align items to the start */
}

.content-countdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* 4 equal columns */
  gap: 5px; /* Space between columns */
  align-items: center;
  justify-items: center;
  margin-top: 16px;
}

.content-gift {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: start;
  padding: 24px;
}

.content-gift p,
.copy-gift p {
  color: #7a4e7a;
}

.content-lovestory {
  width: 100%;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  grid-column: span 7; /* Spans 7 columns */
  background-color: white;
  border: 1px solid #ebebeb;
  border-radius: 16px;
  padding: 20px 16px;
  gap: 16px;
  text-align: left;
}

.content-lovestory img {
  height: 156px;
  width: 100%;
  object-fit: contain; /* Crops while keeping the image centered */
  border-radius: 8px; /* Makes it fully rounded */
}

.container-messages {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 240px;
  overflow-y: auto;
}

.content-message {
  display: flex;
  flex-direction: column;
  grid-column: span 5; /* Spans 4 columns */
  justify-content: start;
  align-items: left;
  justify-items: right;
  text-align: left;
  gap: 8px;
}

.content-moments {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 equal columns */
  gap: 8px; /* Space between columns */
}

.copy-gift {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #e4dce4;
  padding: 16px 24px;
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
  font-size: 12px;
  font-weight: 600;
}

/* Cover Page */
.cover {
  position: fixed;
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  height: 100vh;
  background: url("../bg/papper.jpeg") repeat center center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 20;
}

/* Add CSS for the fade-out animation */
.fade-out {
  animation: fadeOut 1.2s forwards;
}

/* Add CSS for the fade-in animation */
.fade-in {
  opacity: 0;
  transition: opacity 0.8s ease-in;
}

.fade-in.visible {
  opacity: 0.8;
}

/* Footer */
.footer {
  position: relative; /* Ensures flower stays inside */
  width: 100%;
  max-width: 480px;
  background-color: #7a4e7a;
  color: white;
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  text-align: center;
  padding: 24px;
}

/* Footer Navigation */
.footer-nav {
  position: fixed;
  bottom: 0;
  margin-bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  max-width: 400px;
  width: auto;
  display: flex;
  justify-content: center;
  padding: 8px;
  gap: 6px;
  z-index: 10;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0px 0px 8px 0px #0000001f;
  border: 1px solid #ffffff;
  border-radius: 12px;
}

.form-rsvp {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* flower on Each Corner */
.flower-corner {
  position: absolute;
  width: 120px; /* Adjust flower size */
  height: 120px;
  background: url("../ornament/flower-corner.svg") no-repeat center center;
  background-size: contain;
  z-index: 0;
  /* animation: sway 3s infinite ease-in-out alternate; */
}

/* Positioning and Rotating flower */
.flower-top-left {
  top: 0;
  left: 0;
  transform-origin: left top;
  transform: rotate(0deg) translate(95%, 0%) scaleX(-1);
  animation: zoom-top-left 3s infinite ease-in-out alternate;
}

.flower-top-right {
  top: 0;
  right: 0;
  transform-origin: right top;
  transform: rotate(0deg) translate(5%, 0%);
  animation: zoom-top-right 3s infinite ease-in-out alternate;
}

.flower-bottom-left {
  bottom: 0;
  left: 0;
  transform-origin: left bottom;
  transform: rotate(180deg) translate(-95%, 100%);
  animation: zoom-bottom-left 3s infinite ease-in-out alternate;
}

.flower-bottom-right {
  bottom: 0;
  right: 0;
  transform-origin: right bottom;
  transform: rotate(180deg) translate(-5%, 100%) scaleX(-1);
  animation: zoom-bottom-right 3s infinite ease-in-out alternate;
}
/* Hide invitation initially */
.hidden {
  display: none;
}

.image-bridegroom {
  width: 157px;
  height: 190px;
  object-fit: cover; /* Crops while keeping the image centered */
  border: 5px solid #ffffff;
  box-shadow: 0px 0px 8px 2px #0000001a;
  border-radius: 78.5px;
}

.image-full {
  width: 100%;
  /* height: 222px; */
  object-fit: cover; /* Crops while keeping the image centered */
  border-radius: 8px; /* Makes it fully rounded */
  grid-column: span 2;
}

.image-gift {
  height: 16px;
  width: auto;
  object-fit: contain;
  margin-bottom: 24px;
}

.image-half {
  width: 100%;
  height: 230px;
  object-fit: cover; /* Crops while keeping the image centered */
  border-radius: 8px; /* Makes it fully rounded */
}

.image-wedding {
  width: 50%;
  aspect-ratio: 1 / 1; /* Ensures it's always a square */
  height: auto;
  object-fit: cover; /* Crops while keeping the image centered */
  border-radius: 50%; /* Makes it fully rounded */
  border: 4px solid #ffffff;
  box-shadow: 0px 4px 4px 0px #00000014;
}

.image-cover {
  height: 280px;
  width: 204px;
  border: 4px solid #7a4e7a;
  border-radius: 0;
  border-top-left-radius: 100px;
  border-top-right-radius: 100px;
}

.initial-profile {
  width: 32px;
  height: 32px;
  border-radius: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--random-color);
}

.initial-profile p {
  font-size: 14px;
  font-weight: 600;
  color: white;
}

/* Input field spans both columns */
.input {
  width: 100%;
  padding: 10px;
  font-size: 14px;
  border: 1px solid #e4dce4;
  background-color: transparent;
  color: #262626;
  border-radius: 5px;
  outline: none;
  box-shadow: none;
}

.invitation {
  position: relative; /* Ensures flower stays inside */
  width: 100%;
  max-width: 480px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.label-attendance {
  font-size: 10px;
  font-weight: 500;
  font-family: "Nunito Sans", sans-serif;
  color: #195e6a;
  background-color: #cbeef4;
  padding: 2px 6px;
  border-radius: 32px;
}

.moments {
  position: relative; /* Ensures flower stays inside */
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 18px;
}

/* Navigation Buttons */
.nav-button {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background-color: #7a4e7a;
  border: none;
  cursor: pointer;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Icons */
.nav-button img {
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease;
}

.nav-button:hover img {
  transform: scale(1.2);
}

.primary-button {
  margin-top: 16px;
  border-radius: 50px;
  padding: 4px 10px;
  color: white;
  background: #7a4e7a;
  font-size: 10px;
  font-weight: 500;
  font-family: "Nunito Sans", sans-serif;
  cursor: pointer;
  transition: 0.3s;
  gap: 8px;
}

.primary-button:hover {
  background: #7a4e7aa2;
  border: 1px solid #7a4e7a;
}

.progress-countdown {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-items: center;
  padding: 6px 16px;
  border-radius: 8px;
  background-color: #7a4e7a;
  color: white;
}

.progress-countdown p:first-child {
  font-size: 16px;
  font-weight: 700;
}

.progress-countdown p:last-child {
  font-size: 12px;
  font-weight: 400;
}

.progress-lovestory {
  width: 2px;
  height: 100%;
  background-color: #dafaf2;
  border-radius: 8px;
}

.quote {
  position: relative; /* Ensures flower stays inside */
  padding: 40px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: #7a4e7a;
}

.quote p {
  color: white;
}

.ring-wedding {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%); /* Center the ring over the cover */
  width: 50%; /* Adjust to match cover size */
  aspect-ratio: 1 / 1; /* Ensures it's always a square */
  height: auto;
  z-index: 2; /* Ensures the ring is on top */
}

.secondary-button {
  border-radius: 50px;
  padding: 4px 10px;
  border: 1px solid #7a4e7a;
  color: #7a4e7a;
  background: white;
  font-size: 10px;
  font-weight: 500;
  font-family: "Nunito Sans", sans-serif;
  cursor: pointer;
  transition: 0.3s;
  gap: 8px;
}

.secondary-button:hover {
  background: #7a4e7a51;
  border: 1px solid white;
}

.shape-top-right {
  position: absolute;
  width: 120px; /* Adjust flower size */
  height: 120px;
  background: url("../ornament/shape.svg") no-repeat center center;
  background-size: contain;
  z-index: 0;
  top: 0;
  right: 0;
  transform-origin: right top;
}

/* Add CSS for the slide-in animations */
.slide-in-right {
  opacity: 0;
  transition: transform 0.4s ease-in, opacity 0.8s ease-in;
  transform: translateX(100%);
}

.slide-in-right.visible {
  transform: translateX(0);
  opacity: 1;
}

.slide-in-left {
  opacity: 0;
  transition: transform 0.4s ease-in, opacity 0.8s ease-in;
  transform: translateX(-100%);
}

.slide-in-left.visible {
  transform: translateX(0);
  opacity: 1;
}

.slide-in-right-delayed {
  opacity: 0;
  transition: transform 0.4s ease-in, opacity 0.8s ease-in;
  transform: translateX(100%);
}

.slide-in-right-delayed.visible {
  transform: translateX(0);
  opacity: 1;
}

/* Add CSS for the slide-up animation */
.slide-up {
  animation: slideUp 1s forwards;
  z-index: 2;
  position: relative;
}

.social-media {
  display: flex;
  justify-items: center;
  align-items: center;
  gap: 4px;
}

.social-media img {
  width: 14px;
  height: 14px;
}

.text-wedding {
  font-family: "Nunito", sans-serif;
  color: #262626;
  font-size: 16px;
  font-weight: 600;
}

.wedding {
  margin: 24px 0 16px 0;
  position: relative;
  display: inline-block; /* Makes the container fit the images */
}

.white-button {
  border-radius: 50px;
  padding: 4px 10px;
  color: #7a4e7a;
  background: #ffffff;
  font-size: 10px;
  font-weight: 500;
  font-family: "Nunito Sans", sans-serif;
  cursor: pointer;
  transition: 0.3s;
  gap: 8px;
}

.white-button:hover {
  background: #e8cee8;
  border: 1px solid white;
}

.button-cover {
  padding: 6px 14px;
  font-size: 14px;
}

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

@keyframes slideUp {
  from {
    transform: translateY(50%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes zoom-top-left {
  0% {
    transform: rotate(0deg) translate(95%, 0%) scaleX(-1) scale(1);
  }
  50% {
    transform: rotate(0deg) translate(95%, 0%) scaleX(-1) scale(1.02);
  }
  100% {
    transform: rotate(0deg) translate(95%, 0%) scaleX(-1) scale(1);
  }
}

@keyframes zoom-top-right {
  0% {
    transform: rotate(0deg) translate(5%, 0%) scale(1);
  }
  50% {
    transform: rotate(0deg) translate(5%, 0%) scale(1.02);
  }
  100% {
    transform: rotate(0deg) translate(5%, 0%) scale(1);
  }
}

@keyframes zoom-bottom-left {
  0% {
    transform: rotate(180deg) translate(-95%, 100%) scale(1);
  }
  50% {
    transform: rotate(180deg) translate(-95%, 100%) scale(1.02);
  }
  100% {
    transform: rotate(180deg) translate(-95%, 100%) scale(1);
  }
}

@keyframes zoom-bottom-right {
  0% {
    transform: rotate(180deg) translate(-5%, 100%) scaleX(-1) scale(1);
  }
  50% {
    transform: rotate(180deg) translate(-5%, 100%) scaleX(-1) scale(1.02);
  }
  100% {
    transform: rotate(180deg) translate(-5%, 100%) scaleX(-1) scale(1);
  }
}

.font-raleway {
  font-family: "Raleway", sans-serif;
}

/* General Typography Styles */
.text-sm {
  font-size: 10px;
}

.text-md {
  font-size: 12px;
}

.text-base {
  font-size: 14px;
}

.text-lg {
  font-size: 16px;
}

.text-xl {
  font-size: 19px;
}

.text-2xl {
  font-size: 20px;
}

.font-light {
  font-weight: 300;
}

.font-normal {
  font-weight: 400;
}

.font-medium {
  font-weight: 500;
}

.font-semibold {
  font-weight: 600;
}

.font-bold {
  font-weight: 700;
}

.letter-spacing-5 {
  letter-spacing: 5%;
}

.text-white {
  color: white;
}

.text-gray {
  color: #757575;
}

.text-primary {
  color: #7a4e7a;
}

/* Margins and Spacing */
.mt-0 {
  margin-top: 0;
}

.mb-0 {
  margin-bottom: 0;
}

.mt-4 {
  margin-top: 4px;
}

.mb-4 {
  margin-bottom: 4px;
}

.mt-8 {
  margin-top: 8px;
}

.mb-8 {
  margin-bottom: 8px;
}

.mt-16 {
  margin-top: 16px;
}

.mb-16 {
  margin-bottom: 16px;
}

.mt-24 {
  margin-top: 24px;
}

.mb-24 {
  margin-bottom: 24px;
}

.m-24-0 {
  margin: 24px 0;
}

.w-full {
  width: 100%;
}

.w-90 {
  width: 90%;
}

.hidden {
  display: none;
}

/* Flex Layouts */
.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.gap-4 {
  gap: 4px;
}

.gap-8 {
  gap: 8px;
}

.gap-24 {
  gap: 24px;
}

.items-center {
  align-items: center;
}

.justify-center {
  justify-content: center;
}

.justify-items-center {
  justify-items: center;
}

/* Background Colors */
.bg-primary-light {
  background-color: #e4dce4;
}

/* Custom Elements */
.map-iframe {
  border: 1px solid #7a4e7a;
  border-radius: 10px;
  height: 172px;
}

.icon-small {
  width: 20px;
  height: 20px;
  margin-bottom: 0;
}

.gift-title {
  display: flex;
  justify-items: center;
  align-items: center;
  gap: 4px;
  margin-bottom: 16px;
}

/* Social Media */
.social-container {
  font-size: 14px;
  font-weight: 500;
  display: flex;
  gap: 24px;
  justify-items: center;
  align-items: center;
}

/* Quote Section */
.quote-text {
  font-size: 12px;
  font-weight: 400;
}

.quote-source {
  font-size: 14px;
  font-weight: 700;
}

/* Content Sections */
.bridegroom-intro {
  font-size: 12px;
  margin: 24px 0;
}

.location-title {
  color: #7a4e7a;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.location-address {
  font-size: 14px;
}

.gift-message {
  font-size: 14px;
  font-weight: 500;
  color: white;
}

.thanks-message {
  font-size: 16px;
  font-weight: 600;
}

.event-time {
  color: #7a4e7a;
  font-size: 16px;
}

.event-venue {
  font-size: 14px;
  font-weight: 700;
}

.event-address {
  font-size: 12px;
}

.rsvp-instruction {
  font-size: 14px;
  margin-bottom: 16px;
}

.message-name {
  font-size: 14px;
  font-weight: 700;
}

.message-content {
  font-size: 12px;
  font-weight: 500;
}

.message-date {
  font-size: 12px;
  color: #757575;
}

.success-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 4px;
}

.gift-subtitle {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 5%;
}

.gift-address {
  font-size: 10px;
}

.footer-brand {
  font-size: 16px;
  font-weight: 600;
}

.footer-contact {
  font-size: 14px;
  font-weight: 500;
}
