/* ══════════════════════════════════════
   VARIABLES & RESET
══════════════════════════════════════ */
:root {
  --burgundy:       #6B1D2A;
  --burgundy-light: #8B2535;
  --dusty-pink:     #E7B6BB;
  --ivory:          #FAF6F1;
  --gold:           #D4AF37;
  --gold-light:     #E8C94A;
  --text-dark:      #3a2020;
  --text-mid:       #5c3d3d;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  height: 100%;
  overflow: hidden;
}

body {
  font-family: 'Poppins', sans-serif;
  background: var(--burgundy);
  color: var(--text-dark);
  height: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

img   { max-width: 100%; display: block; }
a     { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
.hidden { display: none !important; }

/* ══════════════════════════════════════
   APP FRAME — keeps the e-kad portrait
   regardless of viewport; extra space on
   wide (desktop) screens is filled burgundy
══════════════════════════════════════ */
#app-frame {
  position: relative;
  width: min(100vw, calc(100dvh * 9 / 16));
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: var(--ivory);
  box-shadow: 0 0 60px rgba(0,0,0,0.45);
  container-type: inline-size;
}

/* ══════════════════════════════════════
   LOADING SCREEN
══════════════════════════════════════ */
#loading-screen {
  position: absolute; inset: 0;
  background: var(--ivory);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
#loading-screen.fade-out { opacity: 0; visibility: hidden; }

.loading-inner { text-align: center; position: relative; z-index: 2; }

.monogram {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 8cqw, 4rem);
  color: var(--burgundy); letter-spacing: 4px; margin-bottom: 0.5rem;
  animation: fadeInUp 0.8s ease;
}
.monogram .divider { color: var(--gold); margin: 0 8px; }
.loading-text { font-size: 0.85rem; color: var(--text-mid); letter-spacing: 2px; margin-bottom: 1rem; }
.loading-bar  { width: 180px; height: 3px; background: var(--dusty-pink); border-radius: 99px; margin: 0 auto; overflow: hidden; }
.loading-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--burgundy), var(--gold)); border-radius: 99px; animation: loadFill 2s ease forwards; }
@keyframes loadFill { to { width: 100%; } }

.load-flower { position: absolute; width: clamp(140px, 22cqw, 260px); opacity: 0.75; pointer-events: none; }
.load-flower.tl { top: 0; left: 0; }
.load-flower.tr { top: 0; right: 0; transform: scaleX(-1); }
.load-flower.bl { bottom: 0; left: 0; transform: scaleY(-1); }
.load-flower.br { bottom: 0; right: 0; transform: scale(-1); }

/* ══════════════════════════════════════
   MUSIC BUTTON
══════════════════════════════════════ */
#music-btn {
  position: absolute; bottom: 24px; right: 24px;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--burgundy); color: white; font-size: 1.15rem;
  display: flex; align-items: center; justify-content: center;
  z-index: 1000; box-shadow: 0 4px 16px rgba(107,29,42,0.35);
  transition: transform 0.2s, background 0.2s;
}
#music-btn:hover { transform: scale(1.1); background: var(--burgundy-light); }
#music-btn.muted { background: #999; }

/* ══════════════════════════════════════
   COVER SCREEN
══════════════════════════════════════ */
.cover-screen {
  position: absolute; inset: 0; z-index: 800;
  background: #1a0a0a;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.door-closed { position: relative; width: 100%; height: 100%; display: flex; }
.door-panel  { flex: 1; position: relative; background: linear-gradient(160deg, #3d1520 0%, #1e0a0f 60%, #2a1015 100%); transition: transform 1.2s cubic-bezier(0.77,0,0.175,1); }
.door-panel.left-panel  { border-right: 2px solid var(--gold); transform-origin: left center; }
.door-panel.right-panel { border-left:  2px solid var(--gold); transform-origin: right center; }
.door-panel::before { content:''; position:absolute; inset:20px; border:1px solid rgba(212,175,55,0.3); }
.door-panel::after  { content:''; position:absolute; inset:35px; border:1px solid rgba(212,175,55,0.15); }
.door-handle { position:absolute; top:65%; width:8px; height:36px; background:var(--gold); border-radius:4px; transform:translateY(-50%); box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.right-handle { right:14px; } .left-handle { left:14px; }

.cover-overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  z-index: 2; pointer-events: none;
  padding-bottom: 20%;
}
.cover-greeting { font-family:'Great Vibes',cursive; font-size:clamp(2rem,6cqw,3.5rem); color:var(--dusty-pink); text-shadow:0 2px 8px rgba(0,0,0,0.5); animation:fadeInUp 1s ease 0.3s both; }
.cover-invited  { font-family:'Playfair Display',serif; font-size:clamp(1rem,3cqw,1.5rem); color:rgba(255,255,255,0.85); letter-spacing:4px; margin:0.5rem 0 2rem; animation:fadeInUp 1s ease 0.5s both; }
.btn-buka { pointer-events:all; background:var(--burgundy); color:white; padding:0.75rem 2.5rem; border-radius:99px; font-size:0.95rem; font-weight:500; letter-spacing:1px; border:2px solid var(--gold); transition:background 0.3s,transform 0.2s; animation:fadeInUp 1s ease 0.7s both; box-shadow:0 4px 20px rgba(0,0,0,0.4); }
.btn-buka:hover { background:var(--burgundy-light); transform:scale(1.04); }

.cover-flower { position: absolute; pointer-events: none; }
.cover-flower.tl { top:-10px; left:-10px;  width:clamp(180px,30cqw,380px); opacity:0.90; }
.cover-flower.tr { top:-10px; right:-10px; width:clamp(180px,28cqw,360px); opacity:0.85; transform:scaleX(-1); }
.cover-flower.bl { bottom:-10px; left:-10px;  width:clamp(160px,26cqw,340px); opacity:0.82; transform:scaleY(-1); }
.cover-flower.br { bottom:-10px; right:-10px; width:clamp(160px,26cqw,340px); opacity:0.78; transform:scale(-1); }
.cover-flower.ml { top:50%; left:-10px;  width:clamp(70px,10cqw,130px); opacity:0.5; transform:translateY(-50%); }
.cover-flower.mr { top:50%; right:-10px; width:clamp(70px,10cqw,130px); opacity:0.5; transform:translateY(-50%) scaleX(-1); }

/* ══════════════════════════════════════
   DOOR ANIMATION
══════════════════════════════════════ */
.door-animation  { position:absolute; inset:0; z-index:700; pointer-events:none; display:flex; }
.door-left,.door-right { flex:1; background:linear-gradient(160deg,#3d1520 0%,#1e0a0f 60%,#2a1015 100%); transition:transform 1.2s cubic-bezier(0.77,0,0.175,1); }
.door-left  { transform-origin:left center;  border-right:2px solid var(--gold); }
.door-right { transform-origin:right center; border-left: 2px solid var(--gold); }
.door-light { position:absolute; inset:0; background:radial-gradient(ellipse at center,rgba(250,246,241,0.95) 0%,transparent 70%); opacity:0; transition:opacity 0.8s ease 0.6s; }
.door-animation.opening .door-left  { transform:perspective(1200px) rotateY(-90deg); }
.door-animation.opening .door-right { transform:perspective(1200px) rotateY(90deg); }
.door-animation.opening .door-light { opacity:1; }
.door-animation.done { display:none; }

/* ══════════════════════════════════════
   SCROLL SNAP — MAIN CONTAINER
══════════════════════════════════════ */
.main-content {
  position: relative; z-index: 1;
  height: 100%;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
}
.main-content.hidden  { visibility: hidden; }
.main-content.visible { visibility: visible; }

/* Every section = 1 screen */
.snap-section {
  scroll-snap-align: start;
  scroll-snap-stop: always;
  height: 100dvh;
  min-height: 100dvh;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Fade-in on scroll */
.fade-section { opacity: 0; transform: translateY(20px); transition: opacity 0.45s ease, transform 0.45s ease; }
.fade-section.in-view { opacity: 1; transform: translateY(0); }

/* ══════════════════════════════════════
   PF — PAGE FLOWERS FRAME SYSTEM
   Consistent floral border for all sections
══════════════════════════════════════ */
.pf {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}

/* Corner bouquets */
.pf-tl, .pf-tr, .pf-bl, .pf-br {
  position: absolute;
  width: clamp(160px, 24cqw, 320px);
  opacity: 0.88;
}
.pf-tl { top: -5%;  left: -5%; }
.pf-tr { top: -5%;  right: -5%; transform: scaleX(-1); }
.pf-bl { bottom: -5%; left: -5%;  transform: scaleY(-1); }
.pf-br { bottom: -5%; right: -5%; transform: scale(-1); }

/* Floral strips top & bottom */
.pf-strip-t, .pf-strip-b {
  position: absolute;
  left: 0; width: 100%;
  height: clamp(50px, 7cqw, 85px);
  object-fit: cover;
  object-position: center;
}
.pf-strip-t { top: 0; }
.pf-strip-b { bottom: 0; transform: scaleY(-1); }

/* Side accent mid */
.pf-side {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: clamp(70px, 9cqw, 130px);
  opacity: 0.5;
}
.pf-side.left  { left: 0; }
.pf-side.right { right: 0; transform: translateY(-50%) scaleX(-1); }

/* Small accent mid */
.pf-accent {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: clamp(50px, 7cqw, 90px);
  opacity: 0.45;
}
.pf-accent.left  { left: 1%; }
.pf-accent.right { right: 1%; transform: translateY(-50%) scaleX(-1); }

/* Dark section — dimmer flowers */
.pf-dark .pf-tl,
.pf-dark .pf-tr,
.pf-dark .pf-bl,
.pf-dark .pf-br { opacity: 0.35; }

/* Light section — slightly less opaque corners */
.pf-light .pf-tl,
.pf-light .pf-tr,
.pf-light .pf-bl,
.pf-light .pf-br { opacity: 0.75; }

/* Dim strip for dark bg */
.pf-dim { opacity: 0.4; filter: brightness(0.7); }

/* Parallax flower base */
.parallax-flower { will-change: transform; }

/* Section inner content — sits above flowers */
.section-inner {
  position: relative;
  z-index: 4;
  width: 100%;
  max-width: 860px;
  padding: 0 clamp(20px, 5cqw, 60px);
  margin: 0 auto;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.4rem, 4cqw, 2.2rem);
  text-align: center;
  color: var(--burgundy);
  margin-bottom: 1.5rem;
}
.section-title.ivory { color: var(--ivory); }

/* ══════════════════════════════════════
   HERO SECTION
══════════════════════════════════════ */
.section-hero {
  background: linear-gradient(160deg, #fdf0f2 0%, var(--ivory) 50%, #fdf0f2 100%);
}

.hero-bg-full {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* Gold frame card */
.hero-frame {
  position: relative; z-index: 4;
  width: min(420px, 78cqw);
  border: 1.5px solid var(--gold);
  background: rgba(255,255,255,0.55);
  backdrop-filter: blur(6px);
  border-radius: 6px;
  padding: clamp(22px, 5cqw, 40px) clamp(18px, 4cqw, 36px);
}

.hero-inner { text-align: center; }
.hero-walimatul { font-size: 0.7rem; letter-spacing: 3px; color: var(--burgundy); text-transform: uppercase; margin-bottom: 0.9rem; }

.hero-names {
  font-family: 'Great Vibes', cursive;
  font-size: clamp(2.4rem, 9cqw, 3.4rem);
  color: var(--burgundy);
  line-height: 1.15;
  margin-bottom: 1rem;
}
.hero-amp {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.2rem, 4cqw, 1.6rem);
  color: var(--gold);
  margin: 0.1rem 0;
}

.hero-date-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--gold);
  border-radius: 99px;
  padding: 0.45rem 1.4rem;
  font-family: 'Playfair Display', serif;
  font-size: clamp(0.78rem, 2cqw, 0.92rem);
  color: var(--text-dark);
  letter-spacing: 0.5px;
  margin-bottom: 1.1rem;
}
.hero-date-pill .hdp-sep { color: var(--gold); }

.hero-invite { font-size: clamp(0.72rem, 1.6cqw, 0.85rem); color: var(--text-mid); line-height: 1.7; margin-bottom: 0.8rem; }

.scroll-down-hint { display: inline-block; font-size: 1.3rem; color: var(--gold); animation: bounce 2s infinite; }
@keyframes bounce { 0%,100%{transform:translateY(0);} 50%{transform:translateY(8px);} }

#petals-canvas { position:absolute; inset:0; pointer-events:none; overflow:hidden; z-index:50; height:100%; }
.petal { position:absolute; border-radius:50% 50% 50% 50%/30% 30% 70% 70%; opacity:0; animation:petalFall linear infinite; }
@keyframes petalFall { 0%{opacity:0;transform:translateY(-20px) rotate(0deg);} 10%{opacity:0.7;} 90%{opacity:0.5;} 100%{opacity:0;transform:translateY(100vh) rotate(360deg) translateX(60px);} }

/* ══════════════════════════════════════
   BUTIRAN MAJLIS + COUNTDOWN (combined)
══════════════════════════════════════ */
.section-details {
  background: linear-gradient(180deg, #f9eff1 0%, #faf4f0 55%, #f9eff1 100%);
  flex-direction: column;
  gap: 0;
  padding: 0;
}

/* Smaller, more delicate corner flowers so they don't overlap the title/card */
.section-details .pf-tl,
.section-details .pf-tr,
.section-details .pf-bl,
.section-details .pf-br { width: clamp(100px, 18cqw, 170px); opacity: 0.85; }

.details-combined {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  max-width: 100%;
  padding: 0;
  gap: 0;
}

/* Top half — light, card */
.details-top {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(14px,4cqw,32px) clamp(16px,5cqw,40px) clamp(10px,2cqw,20px);
  position: relative; z-index: 4;
}

/* Heading above event card */
.details-heading { text-align: center; margin-bottom: clamp(14px,2.5vh,22px); }
.details-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 5cqw, 2.1rem);
  color: var(--burgundy);
  line-height: 1.25;
  margin-bottom: clamp(8px,1.5vh,14px);
}
.details-date-row { display:flex; align-items:center; justify-content:center; gap:8px; }
.details-date { font-family:'Playfair Display',serif; font-size:clamp(0.85rem,2.2cqw,1rem); color:var(--text-mid); letter-spacing:1px; }
.details-heart { color: var(--gold); font-size: 0.8rem; }

/* Event card */
.majlis-single {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(212,175,55,0.45);
  border-radius: 20px;
  padding: clamp(14px,2.5cqw,26px) clamp(20px,4cqw,44px);
  box-shadow: 0 8px 36px rgba(107,29,42,0.13), inset 0 1px 0 rgba(255,255,255,0.9);
  position: relative;
  width: 100%;
  max-width: 460px;
}
.majlis-single::before { content:''; position:absolute; top:10px; left:10px; width:18px; height:18px; border-top:2px solid rgba(212,175,55,0.5); border-left:2px solid rgba(212,175,55,0.5); }
.majlis-single::after  { content:''; position:absolute; bottom:10px; right:10px; width:18px; height:18px; border-bottom:2px solid rgba(212,175,55,0.5); border-right:2px solid rgba(212,175,55,0.5); }

.majlis-list { list-style:none; display:flex; flex-direction:column; gap:clamp(6px,1.2cqw,11px); }
.majlis-list li { display:flex; align-items:center; gap:10px; padding-bottom:clamp(6px,1.2cqw,11px); border-bottom:1px solid rgba(212,175,55,0.10); }
.majlis-list li:last-child { border-bottom:none; padding-bottom:0; }
.ml-icon  { font-size:0.9rem; width:30px; height:30px; background:linear-gradient(135deg,#fdf0f2,#f5dde0); border:1px solid rgba(212,175,55,0.3); border-radius:50%; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.ml-text  { display:flex; flex-direction:column; gap:1px; }
.ml-label { display:block; font-size:0.56rem; letter-spacing:1.5px; text-transform:uppercase; color:var(--gold); font-weight:700; }
.ml-text span:not(.ml-label) { font-size:clamp(0.8rem,2cqw,0.88rem); color:var(--text-dark); font-weight:500; }

/* Bottom half — dark panel for countdown */
.countdown-block {
  background: linear-gradient(135deg, var(--burgundy) 0%, #3d1015 100%);
  text-align: center;
  padding: clamp(28px,5cqw,40px) clamp(16px,5cqw,40px) clamp(16px,3cqw,24px);
  position: relative; z-index: 4;
}

/* Curved wave divider between light card area and dark countdown panel */
.details-divider {
  position: relative;
  height: clamp(28px, 6cqw, 44px);
  background: linear-gradient(135deg, var(--burgundy) 0%, #3d1015 100%);
  z-index: 4;
  overflow: hidden;
}
.details-divider::before {
  content: '';
  position: absolute;
  top: 0; left: -8%; right: -8%;
  height: 100%;
  background: #f9eff1;
  border-radius: 0 0 50% 50%;
}
.details-divider span { display: none; }

.cd-label {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1rem,3cqw,1.3rem);
  letter-spacing: 1px;
  color: var(--gold-light);
  margin-bottom: clamp(12px,2.5cqw,18px);
}

.countdown-wrap { display:flex; align-items:center; justify-content:center; gap:clamp(6px,2cqw,14px); margin:0 0 clamp(10px,2cqw,16px); }
.countdown-unit { text-align:center; }
.countdown-unit span { display:block; font-family:'Playfair Display',serif; font-weight:700; font-size:clamp(1.6rem,5.5cqw,2.6rem); color:var(--burgundy); line-height:1; background:#fff; border-radius:12px; padding:8px 14px; min-width:58px; box-shadow: 0 4px 14px rgba(0,0,0,0.18); }
.countdown-unit label { display:block; font-size:0.58rem; letter-spacing:2px; color:var(--gold-light); text-transform:uppercase; font-weight:600; margin-top:6px; }
.countdown-sep { font-size:1.5rem; color:var(--gold); font-weight:bold; margin-top:-14px; }

.lokasi-btns { display:flex; flex-wrap:wrap; gap:8px; justify-content:center; }
.btn-lokasi  { display:inline-flex; align-items:center; gap:5px; padding:0.5rem 1.2rem; border-radius:99px; font-size:0.74rem; font-family:'Poppins',sans-serif; font-weight:600; letter-spacing:0.5px; text-transform:uppercase; background:var(--gold); color:var(--text-dark); transition:transform 0.2s; border:2px solid var(--gold); cursor:pointer; }
.btn-lokasi.outline { background:var(--gold); color:var(--text-dark); border-color:var(--gold); }
.btn-lokasi:hover { transform:scale(1.04); }
.btn-lokasi.outline:hover { background:var(--gold-light); }

/* ══════════════════════════════════════
   SALAM KAUT
══════════════════════════════════════ */
.section-salam {
  background: linear-gradient(160deg, #fdf5f6 0%, #faf0f2 50%, #f5e8eb 100%);
  align-items: stretch;
  flex-direction: column;
  padding: 0;
}

/* Richer, denser floral framing to match Tanda Kasih reference */
.section-salam .pf-strip-t,
.section-salam .pf-strip-b { height: clamp(110px, 18cqw, 190px); opacity: 0.95; }
.section-salam .pf-tl,
.section-salam .pf-tr,
.section-salam .pf-bl,
.section-salam .pf-br { width: clamp(220px, 36cqw, 420px); opacity: 0.95; }

.section-salam .section-inner {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px,4vh,36px) clamp(20px,5cqw,48px);
}

/* Double-border card frame wrapping whole Tanda Kasih content */
.salam-card-frame {
  width: 100%;
  max-width: 460px;
  display: flex;
  flex-direction: column;
  gap: clamp(10px,2vh,16px);
  background: rgba(255,255,255,0.93);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(107,29,42,0.3);
  border-radius: 18px;
  padding: clamp(14px,3vh,22px) clamp(14px,3.5cqw,22px);
  box-shadow: 0 8px 32px rgba(107,29,42,0.14);
  position: relative;
}
.salam-card-frame::before {
  content: '';
  position: absolute;
  inset: 7px;
  border: 1px dashed rgba(212,175,55,0.55);
  border-radius: 12px;
  pointer-events: none;
}

.salam-header { text-align:center; }
.salam-title-top { font-size:0.75rem; color:var(--text-mid); letter-spacing:3px; font-style:italic; margin-bottom:0.2rem; }
.salam-header .section-title { margin-bottom:0.2rem; }
.salam-sub { color:var(--text-mid); font-size:0.82rem; line-height:1.7; margin:0; }

/* Ornamental dividers (used above title and between QR block and verse) */
.salam-divider {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; margin-bottom: 0.5rem;
}
.salam-divider span:first-child,
.salam-divider span:last-child { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--gold), transparent); max-width: 70px; }
.salam-divider-icon { color: var(--gold); font-size: 0.7rem; flex: none; }
.salam-divider-sm { margin: 0; }

/* Single salam card — bigger, centred */
.salam-single {
  display: flex;
  align-items: center;
  gap: clamp(18px, 5cqw, 40px);
  background: white;
  border: 1px solid rgba(212,175,55,0.42);
  border-radius: 22px;
  padding: clamp(18px,3.5cqw,32px) clamp(20px,5cqw,40px);
  box-shadow: 0 8px 40px rgba(107,29,42,0.11), inset 0 1px 0 rgba(255,255,255,0.9);
  max-width: 500px;
  margin: 0 auto;
  position: relative;
  width: 100%;
}
.salam-single::before { content:''; position:absolute; top:12px; left:12px; width:20px; height:20px; border-top:1.5px solid rgba(212,175,55,0.5); border-left:1.5px solid rgba(212,175,55,0.5); }
.salam-single::after  { content:''; position:absolute; bottom:12px; right:12px; width:20px; height:20px; border-bottom:1.5px solid rgba(212,175,55,0.5); border-right:1.5px solid rgba(212,175,55,0.5); }

/* QR big — tappable, larger */
.qr-wrap-big {
  position: relative;
  flex-shrink: 0;
  width: clamp(120px, 32cqw, 180px);
  height: clamp(120px, 32cqw, 180px);
  cursor: pointer;
  border-radius: 16px;
  border: 2.5px solid var(--gold);
  background: white;
  padding: 7px;
  box-shadow: 0 4px 20px rgba(107,29,42,0.14);
  transition: transform 0.2s, box-shadow 0.2s;
}
.qr-wrap-big:hover  { transform: scale(1.04); box-shadow: 0 8px 28px rgba(107,29,42,0.20); }
.qr-wrap-big:active { transform: scale(0.97); }
.qr-img-big { width:100%; height:100%; object-fit:contain; border-radius:10px; display:block; }
.qr-wrap-big.qr-placeholder .qr-img-big { display:none; }
.qr-fallback-big { display:none; width:100%; height:100%; align-items:center; justify-content:center; flex-direction:column; gap:4px; }
.qr-wrap-big.qr-placeholder .qr-fallback-big { display:flex; }
.qr-fallback-big span { font-size:2rem; }
.qr-fallback-big p { font-size:0.7rem; color:var(--text-mid); text-align:center; }
.qr-tap-hint {
  position: absolute; bottom:-22px; left:50%; transform:translateX(-50%);
  font-size:0.6rem; color:var(--text-mid); white-space:nowrap; letter-spacing:0.3px;
}

/* Bank info — bigger text */
.salam-info { flex:1; }
.salam-name-big { font-family:'Playfair Display',serif; font-size:clamp(1.1rem,3.5cqw,1.5rem); color:var(--burgundy); font-weight:600; margin-bottom:3px; }
.salam-bank-name { font-size:0.82rem; color:var(--text-mid); margin-bottom:clamp(12px,2.5cqw,20px); }

.acc-row { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.acc-num { font-family:'Playfair Display',serif; font-size:clamp(1.2rem,4cqw,1.7rem); font-weight:700; color:var(--text-dark); letter-spacing:1.5px; }
.btn-copy-acc {
  display:inline-flex; align-items:center; gap:5px;
  background:var(--burgundy); color:white;
  padding:7px 14px; border-radius:99px;
  font-size:0.76rem; font-weight:500;
  transition:background 0.2s,transform 0.2s;
  flex-shrink:0;
}
.btn-copy-acc:hover  { background:var(--burgundy-light); transform:scale(1.04); }
.btn-copy-acc.copied { background:#2d9e5f; }
.btn-copy-acc svg { flex-shrink:0; }

/* Verse box at bottom */
.salam-verse {
  text-align: center;
  background: rgba(107,29,42,0.06);
  border: 1px solid rgba(212,175,55,0.28);
  border-radius: 14px;
  padding: clamp(10px,2cqw,16px) clamp(16px,4cqw,28px);
  max-width: 500px;
  margin: 0 auto;
  width: 100%;
}
.salam-verse-ar { font-size:clamp(1rem,3cqw,1.3rem); color:var(--burgundy); margin-bottom:4px; font-family:'Playfair Display',serif; direction:rtl; }
.salam-verse-tr { font-size:clamp(0.68rem,1.8cqw,0.78rem); color:var(--text-mid); font-style:italic; line-height:1.6; }

.salam-note { text-align:center; font-size:0.78rem; color:var(--text-mid); font-style:italic; }

/* QR Modal — full screen lightbox */
.qr-modal {
  display: none;
  position: absolute; inset: 0; z-index: 9000;
  background: rgba(0,0,0,0.85);
  align-items: center; justify-content: center;
  animation: fadeInModal 0.25s ease;
}
.qr-modal.open { display:flex; }
@keyframes fadeInModal { from{opacity:0;} to{opacity:1;} }
.qr-modal-inner {
  background: white; border-radius: 20px;
  padding: 24px 24px 20px;
  text-align: center; max-width: min(90%, 380px);
  animation: scaleIn 0.25s cubic-bezier(0.34,1.56,0.64,1);
}
@keyframes scaleIn { from{transform:scale(0.8);opacity:0;} to{transform:scale(1);opacity:1;} }
.qr-modal-inner img { width: min(300px, 70cqw); height: min(300px, 70cqw); object-fit:contain; border:3px solid var(--gold); border-radius:14px; padding:8px; margin-bottom:12px; }
.qr-modal-inner p { font-family:'Playfair Display',serif; color:var(--burgundy); font-size:0.95rem; margin-bottom:14px; }
.qr-modal-inner button { background:var(--burgundy); color:white; padding:8px 24px; border-radius:99px; font-size:0.84rem; font-weight:500; }

/* ══════════════════════════════════════
   GALLERY
══════════════════════════════════════ */
.section-gallery {
  background: linear-gradient(160deg, #fdf5f6 0%, #fdf0f2 100%);
  overflow: hidden;
}
.section-gallery .section-inner {
  display: flex;
  flex-direction: column;
  align-self: stretch;
  padding-top: clamp(16px, 5vh, 40px);
  padding-bottom: clamp(16px, 5vh, 40px);
  overflow: hidden;
}
.section-gallery .section-title { margin-bottom: 0.8rem; }
.section-gallery .doa-wrap { margin-bottom: 0; }

/* ══════════════════════════════════════
   DOA & UCAPAN SECTION
══════════════════════════════════════ */
.section-ucapan {
  background: linear-gradient(160deg, #fdf5f6 0%, #fdf0f2 100%);
  overflow: hidden;
}
.section-ucapan .ucapan-section-inner {
  display: flex;
  flex-direction: column;
  align-self: stretch;
  padding-top: clamp(16px, 5vh, 36px);
  padding-bottom: clamp(16px, 5vh, 36px);
  overflow: hidden;
  height: 100%;
}
.ucapan-header-card {
  text-align: center;
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212,175,55,0.25);
  border-radius: 16px;
  padding: 16px 18px;
  margin-bottom: 0.8rem;
  flex-shrink: 0;
}
.ucapan-header-card .section-title { margin-bottom: 0.4rem; }
.ucapan-desc {
  font-size: clamp(0.74rem, 1.8cqw, 0.85rem);
  color: var(--text-mid);
  line-height: 1.6;
  max-width: 480px;
  margin: 0 auto;
}
.section-ucapan .ucapan-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}
.section-ucapan .ucapan-list-wrap {
  flex: 1;
  min-height: 0;
  display: flex;
}
.section-ucapan .ucapan-list {
  flex: 1;
  min-height: 0;
  max-height: none;
  margin-bottom: 0;
}

.gallery-slider { position:relative; max-width:600px; margin:0 auto 1.2rem; overflow:hidden; border-radius:14px; box-shadow:0 4px 20px rgba(107,29,42,0.12); }
.gallery-track  { display:flex; transition:transform 0.5s cubic-bezier(0.77,0,0.175,1); }
.gallery-slide  { min-width:100%; height:clamp(160px,28vh,260px); overflow:hidden; }
.gallery-slide img { width:100%; height:100%; object-fit:cover; }
.gallery-placeholder { width:100%; height:100%; background:linear-gradient(135deg,#f0d8db,#e8c4c9); display:flex; flex-direction:column; align-items:center; justify-content:center; font-size:1.8rem; color:var(--burgundy); gap:6px; }
.gallery-placeholder small { font-family:'Poppins',sans-serif; font-size:0.75rem; color:var(--text-mid); }

.gallery-btn { position:absolute; top:50%; transform:translateY(-50%); width:36px; height:36px; border-radius:50%; background:rgba(107,29,42,0.75); color:white; font-size:1.3rem; display:flex; align-items:center; justify-content:center; z-index:5; transition:background 0.2s; }
.gallery-btn:hover { background:var(--burgundy); }
.gallery-btn.prev { left:8px; } .gallery-btn.next { right:8px; }
.gallery-dots { display:flex; justify-content:center; gap:5px; padding:8px 0 2px; background:rgba(255,255,255,0.5); }
.gallery-dot  { width:7px; height:7px; border-radius:50%; background:var(--dusty-pink); transition:background 0.3s,transform 0.3s; cursor:pointer; }
.gallery-dot.active { background:var(--burgundy); transform:scale(1.3); }

.doa-wrap { text-align:center; max-width:500px; margin:0 auto 1rem; padding:1rem 1.5rem; background:rgba(255,255,255,0.7); backdrop-filter:blur(8px); border:1px solid rgba(212,175,55,0.28); border-radius:12px; }
.doa-quote { font-family:'Playfair Display',serif; font-style:italic; font-size:clamp(0.8rem,2cqw,0.95rem); color:var(--text-mid); line-height:1.8; }
.doa-quote::before { content:'\201C'; color:var(--gold); font-size:1.6rem; line-height:0.5; vertical-align:-0.4rem; margin-right:3px; }
.doa-quote::after  { content:'\201D'; color:var(--gold); font-size:1.6rem; line-height:0.5; vertical-align:-0.4rem; margin-left:3px; }

.ucapan-section { text-align:center; }

.btn-ucapan {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding: 0.65rem 1.6rem;
  background: linear-gradient(135deg, var(--burgundy), #9b2d3f);
  color: white;
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  box-shadow: 0 3px 12px rgba(107,29,42,0.3);
  transition: all 0.2s;
}
.btn-ucapan:hover { transform: translateY(-1px); box-shadow: 0 5px 16px rgba(107,29,42,0.4); }

.ucapan-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  margin-top: 0.7rem;
  margin-left: auto;
  margin-right: auto;
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212,175,55,0.25);
  border-radius: 16px;
  padding: 14px;
  animation: fadeInUp 0.35s ease;
}
.ucapan-form input,
.ucapan-form textarea {
  padding: 10px 14px;
  border: 1.5px solid rgba(107,29,42,0.15);
  border-radius: 10px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.83rem;
  background: rgba(255,255,255,0.9);
  color: var(--text-dark);
  resize: none;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.ucapan-form input::placeholder,
.ucapan-form textarea::placeholder { color: #b5909a; }
.ucapan-form input:focus,
.ucapan-form textarea:focus {
  border-color: var(--burgundy);
  box-shadow: 0 0 0 3px rgba(107,29,42,0.08);
}
.btn-submit {
  padding: 0.6rem;
  background: linear-gradient(135deg, var(--gold), #c9a227);
  color: var(--text-dark);
  border-radius: 10px;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  box-shadow: 0 2px 8px rgba(212,175,55,0.35);
  transition: all 0.2s;
}
.btn-submit:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(212,175,55,0.5); }
.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* Ucapan list — bordered card with asymmetric corner flowers */
.ucapan-list-wrap {
  position: relative;
  margin-top: 0.8rem;
  padding: 30px 16px 42px;
}
.ucapan-corner {
  position: absolute;
  height: auto;
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;
}
.ucapan-corner-tl {
  top: -10px; left: -10px;
  width: clamp(44px, 11cqw, 60px);
  transform: rotate(-10deg);
}
.ucapan-corner-br {
  bottom: -16px; right: -14px;
  width: clamp(80px, 22cqw, 130px);
  transform: rotate(176deg);
}
.ucapan-list {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--dusty-pink) transparent;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(10px);
  border: 1.5px solid rgba(212,175,55,0.4);
  border-radius: 16px;
  padding: 16px 20px;
  box-shadow: 0 4px 18px rgba(107,29,42,0.1);
}
.ucapan-item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 4px;
  animation: fadeInUp 0.3s ease;
  text-align: left;
  border-bottom: 1px dashed rgba(212,175,55,0.4);
}
.ucapan-item:last-child { border-bottom: none; }
.ucapan-item-head { display: flex; align-items: center; gap: 9px; }
.ucapan-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--burgundy), #c0415a);
  color: white;
  font-size: 0.78rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.ucapan-body { min-width: 0; }
.ucapan-body strong { display: block; font-size: 0.82rem; color: var(--burgundy); font-weight: 700; }
.ucapan-item p { font-size: 0.78rem; color: #5a2535; line-height: 1.6; margin: 0 0 0 39px; word-break: break-word; }
.ucapan-time {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.62rem;
  color: var(--gold);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-left: 39px;
}
.ucapan-time::before { content: '📅'; font-size: 0.6rem; }

/* ══════════════════════════════════════
   RSVP
══════════════════════════════════════ */
.section-rsvp {
  background: linear-gradient(160deg, var(--burgundy) 0%, #2a0810 100%);
}

.rsvp-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 4cqw, 48px);
  align-items: center;
  max-width: 100%;
}

.rsvp-box, .rsvp-right { position: relative; z-index: 4; }

.rsvp-form { display:flex; flex-direction:column; gap:10px; }
.rsvp-row  { display:grid; grid-template-columns:2fr 1fr; gap:10px; }
.form-group { display:flex; flex-direction:column; gap:4px; }
.form-group label { font-size:0.75rem; color:var(--dusty-pink); letter-spacing:0.5px; }
.form-group input,
.form-group select { padding:9px 12px; border:1px solid rgba(255,255,255,0.2); border-radius:9px; background:rgba(255,255,255,0.1); color:white; font-family:'Poppins',sans-serif; font-size:0.84rem; outline:none; transition:border-color 0.2s; }
.form-group input:focus,
.form-group select:focus { border-color:var(--gold); }
.form-group select option { background:var(--burgundy); color:white; }
.btn-rsvp { padding:0.8rem; background:var(--gold); color:var(--text-dark); border-radius:99px; font-size:0.9rem; font-weight:600; font-family:'Poppins',sans-serif; transition:background 0.2s,transform 0.2s; }
.btn-rsvp:hover { background:var(--gold-light); transform:scale(1.02); }
.rsvp-success { text-align:center; color:white; padding:0.8rem; background:rgba(255,255,255,0.1); border-radius:10px; margin-top:0.8rem; font-size:0.88rem; }

.contact-box { background:rgba(255,255,255,0.07); backdrop-filter:blur(10px); border:1px solid rgba(212,175,55,0.25); border-radius:16px; padding:clamp(16px,2.5cqw,24px); margin-bottom:1.2rem; }
.contact-title { font-family:'Playfair Display',serif; font-size:1.1rem; color:var(--dusty-pink); margin-bottom:0.8rem; }
.btn-contact { display:flex; align-items:center; gap:8px; width:100%; padding:10px 14px; border-radius:10px; font-size:0.82rem; font-weight:500; margin-bottom:8px; transition:transform 0.2s,opacity 0.2s; color:white; }
.btn-contact:last-of-type { margin-bottom:0; }
.btn-contact:hover { transform:scale(1.02); opacity:0.9; }
.btn-contact.whatsapp { background:#25D366; }
.btn-contact.phone,
.btn-contact.email    { background:rgba(255,255,255,0.14); border:1px solid rgba(255,255,255,0.25); }

/* Footer mini dalam RSVP section */
.footer-mini { text-align:center; padding-top:0.5rem; }
.footer-names { font-family:'Great Vibes',cursive; font-size:clamp(1.6rem,4cqw,2.4rem); color:var(--dusty-pink); }
.footer-thanks { color:rgba(255,255,255,0.65); font-size:0.78rem; line-height:1.8; margin:0.2rem 0; }
.footer-date   { font-family:'Playfair Display',serif; color:var(--gold); letter-spacing:3px; font-size:0.82rem; }

/* ══════════════════════════════════════
   ANIMATIONS
══════════════════════════════════════ */
@keyframes fadeInUp { from{opacity:0;transform:translateY(20px);} to{opacity:1;transform:translateY(0);} }

/* ══════════════════════════════════════
   RESPONSIVE — keyed off the actual
   #app-frame width (container query), not
   the raw browser viewport. This makes the
   "mobile" layout apply consistently
   whenever the frame itself is phone-narrow
   — whether that's a real phone, or the
   portrait letterboxed frame on desktop.
══════════════════════════════════════ */
@container (max-width: 640px) {
  .snap-section { height: 100svh; min-height: 100svh; }

  /* Hero */
  .hero-frame { width: 88cqw; padding: 14px 16px; }

  /* Combined details section */
  .details-top { padding: 12px 16px 10px; }
  .majlis-single { padding: 12px 16px; }
  .countdown-block { padding: 12px 16px 14px; }
  .countdown-unit span { min-width: 48px; padding: 6px 10px; font-size: 1.5rem; }
  .countdown-sep { font-size: 1.2rem; margin-top: -10px; }

  /* Salam — tighter on mobile */
  .section-salam .section-inner { padding: 14px 18px; gap: 12px; }
  .salam-single { padding: 14px 16px; gap: 14px; }
  .qr-wrap-big { width: 105px; height: 105px; }
  .acc-num { font-size: 1.15rem; }
  .salam-verse { padding: 10px 14px; }

  /* RSVP */
  .rsvp-inner { grid-template-columns: 1fr; gap: 14px; overflow-y: auto; }
  .rsvp-row   { grid-template-columns: 2fr 1fr; }

  /* PF corners — smaller on mobile */
  .pf-tl, .pf-tr, .pf-bl, .pf-br { width: clamp(110px, 30cqw, 160px); }
}

/* ══════════════════════════════════════
   RESPONSIVE — frame wider than phone
   (desktop browser with burgundy letterbox)
══════════════════════════════════════ */
@container (min-width: 481px) {
  /* Clear the taller floral top strip so titles don't render behind it */
  .section-gallery .section-inner,
  .section-ucapan .ucapan-section-inner {
    padding-top: 70px;
    justify-content: center;
  }
}

@container (max-width: 380px) {
  .salam-single { flex-direction: column; align-items: center; text-align: center; }
  .acc-row { justify-content: center; }
  .qr-wrap-big { width: 130px; height: 130px; }
  .qr-tap-hint { bottom: -20px; }
}
