/* Typography utilities */
.script-text {
  font-family: var(--script-font);
  font-weight: 400;
}
.title-large {
  font-size: 4rem;
  line-height: 1.2;
}
.section-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mb-4 { margin-bottom: 1rem; }
.text-center { text-align: center; }
.text-sm { font-size: 0.875rem; }
.max-w-sm { max-width: 24rem; margin-left: auto; margin-right: auto; }
.text-lowercase { text-transform: lowercase; }

/* Buttons */
.btn-primary {
  background-color: var(--secondary-color);
  color: var(--primary-color);
  padding: 0.75rem 2rem;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}
.btn-primary:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}
.btn-secondary {
  display: inline-block;
  border: 1px solid var(--secondary-color);
  color: var(--secondary-color);
  padding: 0.5rem 1.5rem;
  border-radius: 4px;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.btn-social {
  display: inline-block;
  color: var(--secondary-color);
  text-decoration: underline;
  font-size: 0.9rem;
}

/* Background Utility */
.solid-bg {
  background-color: var(--primary-color);
  position: relative;
  z-index: 5;
}
.solid-bg-light {
  background-color: var(--secondary-color);
  color: var(--primary-color);
  position: relative;
  z-index: 5;
}

/* Quote Section */
.quote-section {
  /* Inherits flex centering from content-section and 100svh from main.css */
  margin-bottom: 20vh;
}

.wedding-logo {
  width: 220px;
  max-width: 90%;
  height: auto;
  margin-bottom: 2rem;
  /* Add a subtle drop shadow to make it pop against the background */
  filter: drop-shadow(0 4px 12px rgba(255, 255, 255, 0.3));
}

/* Custom cinematic logo reveal */
.logo-reveal {
  opacity: 0;
  transform: scale(1.2) translateY(20px);
  filter: blur(8px);
  transition: opacity 1.5s ease-out, transform 1.5s cubic-bezier(0.25, 1, 0.5, 1), filter 1.5s ease-out;
}

.logo-reveal.in-view {
  opacity: 1;
  transform: scale(1) translateY(0);
  filter: blur(0);
}

/* Profiles Full-Bleed */
.profile-section-full {
  position: relative;
  width: 100%;
  min-height: 100svh;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: flex-end; /* Align content to bottom */
  align-items: flex-end; /* Align content to right */
  padding: 3rem 2rem;
  z-index: 5;
}

/* Gradient overlay so white text is always readable against the photo */
.profile-overlay-gradient {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.5) 40%, rgba(0,0,0,0) 70%);
  pointer-events: none;
  z-index: 1;
}

.profile-info-side {
  position: relative;
  z-index: 2;
  text-align: right;
  color: #fff;
  max-width: 80%;
}

.profile-info-side .profile-title {
  font-size: 4rem;
  line-height: 1;
  margin-bottom: 0.5rem;
  font-family: var(--script-font);
  font-style: italic;
  font-weight: 400;
  /* Removed text-shadow to make it clean */
}

.profile-info-side .profile-name-bold {
  font-family: var(--heading-font);
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  font-weight: 600;
  letter-spacing: 1px;
}

.profile-info-side .profile-desc-side {
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: 1.5rem;
  font-family: var(--body-font);
  padding-right: 4px; /* Prevent italic 'i' from getting clipped on the right */
}

.btn-social-side {
  display: inline-block;
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,0.7);
  font-size: 0.9rem;
  text-decoration: none;
  opacity: 0.9;
  padding-bottom: 2px;
}

/* Story Slider */
.timeline-section {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 6rem; /* Added space between Bride and Our Story */
}

.story-slider {
  display: flex;
  width: calc(100% + 4rem);
  margin-left: -2rem;
  margin-right: -2rem;
  padding-left: 2rem;
  padding-right: 2rem;
  padding-top: 1rem;
  padding-bottom: 2rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 1.5rem;
  /* Hide scrollbar */
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.story-slider::-webkit-scrollbar {
  display: none;
}

.story-card {
  flex: 0 0 75%;
  max-width: 250px;
  scroll-snap-align: center;
  background-color: #f4f1eb; /* Creamy off-white */
  padding: 1.25rem;
  color: #1a1a1a;
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  text-align: left;
}

.story-photo-stamp {
  width: 70%;
  margin: 0 auto 1.5rem auto;
}

.story-photo-stamp img {
  width: 100%;
  height: auto;
  display: block;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 1s ease 0.2s, transform 1s cubic-bezier(0.25, 1, 0.5, 1) 0.2s;
  cursor: pointer; /* Indikasi bisa diklik */

  /* High-res 400x400 SVG to prevent blurriness, with 'fill' to ensure center is visible */
  -webkit-mask-box-image-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  -webkit-mask-box-image-slice: 100 fill;
  -webkit-mask-box-image-width: 10px;
  -webkit-mask-box-image-repeat: round;
  
  mask-border-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  mask-border-slice: 100 fill;
  mask-border-width: 10px;
  mask-border-repeat: round;
}

.story-slider.in-view .story-photo-stamp img {
  opacity: 1;
  transform: scale(1);
}

.story-year {
  font-family: var(--body-font);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  letter-spacing: 1px;
}

.story-content p {
  font-family: var(--body-font);
  font-size: 0.85rem;
  line-height: 1.5;
  opacity: 0.85;
}

/* Schedule Section */
.schedule-section {
  text-align: center;
  padding-left: 2rem;
  padding-right: 2rem;
}

.schedule-section .section-title {
  font-size: 3rem;
  letter-spacing: 4px;
  margin-bottom: 2.5rem;
  font-family: var(--heading-font);
}

.schedule-section .event-item {
  margin-bottom: 1.5rem;
}

.schedule-section .event-name {
  font-family: var(--heading-font);
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
  font-weight: 500;
  letter-spacing: 1px;
}

.schedule-section p {
  font-size: 1.05rem;
  line-height: 1.6;
  opacity: 0.9;
}

.schedule-section .location-box {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
}

.schedule-section .location-name {
  font-size: 1.15rem;
  letter-spacing: 1px;
  margin-bottom: 0.25rem;
}

.schedule-section .btn-secondary {
  margin-top: 1.5rem;
  font-size: 0.85rem;
  padding: 0.6rem 1.5rem;
  letter-spacing: 2px;
}

/* Countdown Section */
.countdown-section {
  text-align: center;
}

.countdown-title {
  font-family: var(--heading-font);
  font-size: 2.2rem;
  letter-spacing: 2px;
  line-height: 1.2;
  text-transform: uppercase;
}

.countdown-stamp {
  background-color: #f4f1eb;
  padding: 1.5rem;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
  
  /* Use the exact same stamp mask algorithm from story section */
  -webkit-mask-box-image-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  -webkit-mask-box-image-slice: 100 fill;
  -webkit-mask-box-image-width: 12px;
  -webkit-mask-box-image-repeat: round;
  
  mask-border-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  mask-border-slice: 100 fill;
  mask-border-width: 12px;
  mask-border-repeat: round;
}

.countdown-stamp img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  cursor: pointer; /* Indikasi bisa diklik */
}

.countdown-container {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.countdown-section .time-box {
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 6px;
  flex: 1;
  min-width: 0;
  padding: 1rem 0.2rem;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.05);
}

.countdown-section .time-val {
  font-size: 1.8rem;
  font-family: var(--body-font);
  font-weight: 400;
  display: block;
  margin-bottom: 0.25rem;
}

.countdown-section .time-label {
  font-size: 0.65rem;
  letter-spacing: 1px;
  opacity: 0.9;
  text-transform: uppercase;
}

.btn-ghost {
  display: inline-block;
  background: transparent;
  color: #fff;
  border: 1px solid #fff;
  padding: 1rem 2.5rem;
  font-family: var(--body-font);
  font-size: 0.9rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  transition: all var(--transition-fast);
}

.btn-ghost:hover {
  background: rgba(255,255,255,0.1);
}

/* Music Control */
.music-control {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 50;
  background-color: rgba(0, 0, 0, 0.4);
  color: white;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: opacity var(--transition-fast);
}

/* Toast */
.toast-container {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}
.toast {
  background-color: var(--secondary-color);
  color: var(--primary-color);
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  animation: fadeUp var(--transition-fast) forwards;
}

/* Story Lightbox */
.story-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.story-lightbox.active {
  pointer-events: auto;
  opacity: 1;
}

.story-lightbox-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.story-lightbox-content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 90vw;
  max-height: 90vh;
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.story-lightbox.active .story-lightbox-content {
  transform: scale(1);
}

.story-lightbox-close {
  background: transparent;
  border: none;
  color: white;
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  margin-bottom: 1rem;
  padding: 0;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
  transition: color 0.2s;
}

.story-lightbox-close:hover {
  color: #fca5a5;
}

.story-lightbox-frame {
  width: 320px;
  max-width: 85vw;
}

.story-lightbox-frame img {
  width: 100%;
  height: auto;
  display: block;
  /* Use the exact same stamp mask algorithm from story section */
  -webkit-mask-box-image-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  -webkit-mask-box-image-slice: 100 fill;
  -webkit-mask-box-image-width: 12px;
  -webkit-mask-box-image-repeat: round;
  
  mask-border-source: url("data:image/svg+xml,%3Csvg width='400' height='400' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cmask id='m'%3E%3Crect width='400' height='400' fill='white'/%3E%3Ccircle cx='0' cy='0' r='70' fill='black'/%3E%3Ccircle cx='200' cy='0' r='70' fill='black'/%3E%3Ccircle cx='400' cy='0' r='70' fill='black'/%3E%3Ccircle cx='0' cy='200' r='70' fill='black'/%3E%3Ccircle cx='400' cy='200' r='70' fill='black'/%3E%3Ccircle cx='0' cy='400' r='70' fill='black'/%3E%3Ccircle cx='200' cy='400' r='70' fill='black'/%3E%3Ccircle cx='400' cy='400' r='70' fill='black'/%3E%3C/mask%3E%3C/defs%3E%3Crect width='400' height='400' fill='black' mask='url(%23m)'/%3E%3C/svg%3E");
  mask-border-slice: 100 fill;
  mask-border-width: 12px;
  mask-border-repeat: round;
}

/* Modifikasi apabila sedang tidak ingin frame (contoh: untuk gallery) */
.story-lightbox.no-frame .story-lightbox-frame img {
  -webkit-mask-box-image-source: none !important;
  mask-border-source: none !important;
  border-radius: 8px; /* Tepi yang agak membulat sedikit agar lebih estetik */
}

/* Custom YouTube Pseudo-Fullscreen for Mobile */
.pseudo-fullscreen {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  max-width: 100% !important;
  margin: 0 !important;
  z-index: 99999 !important;
  border-radius: 0 !important;
  background: #000 !important;
}
.pseudo-fullscreen > div {
  padding-bottom: 0 !important;
  height: 100vh !important;
}

