/* =========================================================================
   Classic Minang — Wedding Invitation (clean rebuild)
   index.html + css/style.css + js/script.js + assets/
   ========================================================================= */

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Maigre";
  src: url("../assets/fonts/maigre.ttf") format("truetype");
  font-weight: 100 400; font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../assets/fonts/cormorant-garamond.ttf") format("truetype");
  font-weight: 400; font-display: swap;
}
@font-face {
  font-family: "Tangerine";
  src: url("../assets/fonts/tangerine-regular.woff2") format("woff2");
  font-weight: 400; font-display: swap;
}
@font-face {
  font-family: "Tangerine";
  src: url("../assets/fonts/tangerine-bold.woff2") format("woff2");
  font-weight: 700; font-display: swap;
}
@font-face {
  font-family: "Caudex";
  src: url("../assets/fonts/caudex-regular.woff2") format("woff2");
  font-weight: 400; font-display: swap;
}
@font-face {
  font-family: "Caudex";
  src: url("../assets/fonts/caudex-bold.woff2") format("woff2");
  font-weight: 700; font-display: swap;
}
@font-face {
  font-family: "Amethysta";
  src: url("../assets/fonts/amethysta-regular.woff2") format("woff2");
  font-weight: 400; font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --maroon: #5d0505;
  --maroon-soft: #a85f5f;
  --gold: #bb8e4b;
  --gold-light: #d8c278;
  --cream: #fff6df;
  --cream-2: #f2eade;
  --paper: #fffdf4;
  --ink: #21242a;

  --canvas: 480px;

  --f-title: "Maigre", serif;     /* section titles */
  --f-script: "Tangerine", cursive;/* couple names   */
  --f-caps: "Caudex", serif;       /* small caps     */
  --f-serif: "Cormorant Garamond", serif; /* cover names + body */
  --f-body: "Amethysta", serif;    /* paragraph body */

  --shadow-card: 0 10px 30px rgba(93, 5, 5, .12);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: clip; }
body {
  font-family: var(--f-body);
  color: var(--ink);
  background: var(--maroon);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
body.no-scroll { overflow: hidden; height: 100vh; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
button { font: inherit; cursor: pointer; }
a { text-decoration: none; color: inherit; }

/* ---------- Shared type ---------- */
.caps {
  font-family: var(--f-caps);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 13px;
  margin: 0;
}
.script {
  font-family: var(--f-script);
  font-weight: 700;
  color: var(--maroon);
  line-height: 1;
  margin: 0;
}
.title {
  font-family: var(--f-title);
  font-weight: 400;
  color: var(--maroon);
  font-size: 30px;
  letter-spacing: .5px;
  margin: 0;
}
.title--light { color: #fff; }
.title--gold { color: var(--gold); }

.divider {
  display: block;
  width: min(78%, 320px);
  height: 2px;
  margin: 14px auto;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

/* =========================================================================
   Layout: desktop split + invitation canvas
   ========================================================================= */
.stage-side { display: none; }

.invite {
  position: relative;
  width: 100%;
  max-width: var(--canvas);
  margin: 0 auto;
  background:
    linear-gradient(rgba(255, 253, 244, .55), rgba(255, 253, 244, .55)),
    url("../assets/img/paper-texture.jpg");
  background-size: cover;
  background-attachment: scroll;
  box-shadow: 0 0 40px rgba(0, 0, 0, .35);
  overflow: hidden;
}

/* =========================================================================
   Reveal animation
   ========================================================================= */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .9s ease, transform .9s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* =========================================================================
   Buttons
   ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 40px;
  padding: 14px 34px;
  font-family: var(--f-caps);
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 14px;
}
.btn--sm { padding: 11px 26px; font-size: 13px; }
.btn--solid {
  color: #fff;
  background: linear-gradient(100deg, #4a0404 0%, #7c1414 50%, #a85f5f 100%);
  box-shadow: 0 8px 20px rgba(93, 5, 5, .35);
}
.btn--solid:active { transform: translateY(1px); }
.btn--outline {
  color: #fff;
  background: transparent;
  border: 1.5px solid #fff;
  border-radius: 14px;
  text-transform: none;
  font-size: 17px;
  letter-spacing: .5px;
  padding: 13px 30px;
}

/* ---------- Inline icons (CSS masks where possible) ---------- */
[class^="ico-"] { display: inline-block; width: 1em; height: 1em; }
.ico-envelope { background: url("../assets/img/amplop-logo.png") center / contain no-repeat; filter: brightness(0) invert(1); }
.ico-ig { background: url("../assets/img/instagram-logo.svg") center / contain no-repeat; }
.ico-map { background: url("../assets/img/maps-logo.png") center / contain no-repeat; }
.ico-play::before { content: "\25B6"; }
.ico-copy { background: url("../assets/img/copy-logo.png") center / contain no-repeat; filter: brightness(0) invert(1); }
.ico-gift { color: var(--gold); font-size: 30px; }
.ico-gift::before { content: "\1F381"; }

/* =========================================================================
   Photo oval (shared)
   ========================================================================= */
.photo-oval {
  border-radius: 50% / 50%;
  overflow: hidden;
  border: 3px solid var(--maroon);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .3);
}
.photo-oval img { width: 100%; height: 100%; object-fit: cover; }

/* =========================================================================
   Scene wrapper (Minang composite background sections)
   ========================================================================= */
.scene {
  position: relative;
  background:
    linear-gradient(rgba(255, 250, 238, .72), rgba(255, 250, 238, .72)),
    url("../assets/img/minang-scene.jpg") center top / cover no-repeat;
}
.scene__paper {
  position: relative;
  padding: 48px 26px 56px;
  text-align: center;
}

/* =========================================================================
   1. COVER
   ========================================================================= */
.cover {
  position: fixed;
  inset: 0;
  z-index: 60;
  max-width: var(--canvas);
  margin: 0 auto;
  background: var(--cream) url("../assets/img/cover-minang.jpg") center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: opacity .9s ease, visibility .9s ease, transform .9s ease;
}
.cover.is-open {
  opacity: 0;
  visibility: hidden;
  transform: scale(1.06);
  pointer-events: none;
}
.cover__inner {
  padding: 0 30px;
  width: 100%;
  transition: opacity .45s ease, transform .45s ease;
}
.cover.is-exiting .cover__inner { opacity: 0; transform: translateY(-16px); }
.cover__photo {
  width: 64%;
  max-width: 290px;
  aspect-ratio: 3 / 4;
  margin: 0 auto 22px;
  border-width: 4px;
}
.cover__label { color: var(--maroon); letter-spacing: 4px; font-size: 15px; }
.cover__names {
  font-family: var(--f-serif);
  font-weight: 400;
  color: var(--maroon);
  font-size: 42px;
  margin: 8px 0 18px;
  line-height: 1;
}
.cover__to { color: #000; letter-spacing: 1px; margin-bottom: 4px; }
.cover__guest {
  font-family: var(--f-caps);
  font-weight: 700;
  font-size: 17px;
  margin: 0 0 26px;
  color: #000;
}

/* =========================================================================
   2. OPENING (video)
   ========================================================================= */
.opening {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: url("../assets/img/opening-fallback.jpg") center / cover no-repeat;
}
.opening__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
body.opened .opening__video { animation: kenburns 20s ease-out both; }
@keyframes kenburns { from { transform: scale(1.14); } to { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .opening__video { animation: none !important; }
}
.opening__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(rgba(255, 246, 223, .35), rgba(93, 5, 5, .15) 60%, rgba(255, 246, 223, .45));
}
.opening__content { position: relative; text-align: center; padding: 0 24px; }
.opening__photo {
  width: 54%;
  max-width: 230px;
  aspect-ratio: 3 / 4;
  margin: 0 auto 22px;
  border-width: 4px;
}
.opening__content .caps { color: var(--maroon); letter-spacing: 3px; text-shadow: 0 1px 6px rgba(255, 246, 223, .8); }
.opening__content .script { font-size: 64px; margin: 6px 0; text-shadow: 0 2px 10px rgba(255, 246, 223, .7); }
.opening__date { color: var(--maroon); font-size: 16px; letter-spacing: 4px; text-shadow: 0 1px 6px rgba(255, 246, 223, .8); }

/* =========================================================================
   3. VERSE
   ========================================================================= */
.verse__photo {
  width: 60%;
  max-width: 260px;
  aspect-ratio: 3 / 4;
  margin: 0 auto 26px;
}
.verse__ayat {
  font-family: var(--f-serif);
  font-size: 19px;
  line-height: 1.8;
  color: var(--maroon);
  max-width: 380px;
  margin: 0 auto 16px;
}
.verse__ref { color: var(--maroon); letter-spacing: 1px; }

/* =========================================================================
   4. COUPLE
   ========================================================================= */
.couple__greet { color: var(--maroon); letter-spacing: 2px; font-size: 14px; margin-bottom: 14px; }
.couple__intro {
  font-family: var(--f-serif);
  font-size: 18px;
  color: #2a1a1a;
  max-width: 380px;
  margin: 0 auto 30px;
}
.person { margin: 22px 0; }
.person__photo {
  width: 62%;
  max-width: 240px;
  aspect-ratio: 4 / 5;
  margin: 0 auto 16px;
}
.person__name { font-size: 46px; margin-bottom: 10px; }
.person__role {
  font-family: var(--f-caps);
  font-weight: 700;
  margin: 0 0 2px;
  font-size: 16px;
}
.person__parents {
  font-family: var(--f-serif);
  font-size: 19px;
  margin: 0 0 16px;
  color: #2a1a1a;
}
.person__parents span { color: var(--maroon); }
.couple__amp {
  font-family: var(--f-serif);
  font-size: 40px;
  color: var(--maroon);
  margin: 6px 0;
}
.couple__bunga { width: 120px; margin: 0 auto -10px; opacity: .95; }
.couple__amp span { display: block; }

/* =========================================================================
   5. COUNTDOWN
   ========================================================================= */
.countdown__quote {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 19px;
  color: var(--maroon);
  max-width: 360px;
  margin: 4px auto 28px;
}
.countdown__grid {
  display: flex;
  justify-content: center;
  gap: 12px;
}
.cd-box {
  min-width: 66px;
  padding: 14px 6px;
  border-radius: 12px;
  background: linear-gradient(160deg, #6b0a0a, #3d0303);
  color: #fff;
  box-shadow: var(--shadow-card);
}
.cd-num {
  display: block;
  font-family: var(--f-title);
  font-size: 30px;
  line-height: 1;
  color: var(--gold-light);
}
.cd-lbl {
  display: block;
  margin-top: 6px;
  font-family: var(--f-caps);
  font-size: 12px;
  letter-spacing: 1px;
}

/* =========================================================================
   6. SAVE THE DATE
   ========================================================================= */
.event__eyebrow {
  font-family: var(--f-title);
  text-transform: none;
  letter-spacing: .5px;
  font-size: 30px;
  color: var(--maroon);
}
.title--script-top { margin-bottom: 30px; }
.card {
  background: linear-gradient(180deg, #fffdf8, #f6ecdc);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  padding: 30px 24px 34px;
  margin: 0 auto 26px;
  max-width: 420px;
}
.card .divider { margin: 12px auto 20px; }
.card__date { font-family: var(--f-serif); font-size: 21px; margin: 0 0 4px; color: #2a1a1a; }
.card__time { font-family: var(--f-serif); font-size: 20px; margin: 0 0 18px; color: #2a1a1a; }
.card__place { font-family: var(--f-serif); font-size: 19px; margin: 0 0 22px; color: #2a1a1a; line-height: 1.5; }
.card__place strong { font-weight: 700; }

/* =========================================================================
   7. GALLERY
   ========================================================================= */
.gallery {
  background: var(--maroon);
  padding: 48px 14px 54px;
  text-align: center;
}
.gallery .title { margin-bottom: 24px; }
.gallery__video { max-width: 440px; margin: 0 auto 18px; }
.yt {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  background: #2a0303 radial-gradient(circle at center, #3d0303, #1a0202);
}
.yt img, .yt iframe { width: 100%; height: 100%; border: 0; object-fit: cover; display: block; }
.yt__play {
  position: absolute; inset: 0;
  margin: auto;
  width: 68px; height: 48px;
  border: none; border-radius: 12px;
  background: rgba(220, 30, 30, .92);
}
.yt__play::before {
  content: ""; position: absolute; inset: 0; margin: auto;
  width: 0; height: 0;
  border-style: solid;
  border-width: 11px 0 11px 18px;
  border-color: transparent transparent transparent #fff;
}
.gallery__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  max-width: 460px;
  margin: 0 auto;
}
.gallery__item {
  display: block;
  overflow: hidden;
  border-radius: 2px;
}
.gallery__item img {
  width: 100%; height: 100%;
  object-fit: cover;
  aspect-ratio: 3 / 4;
  transition: transform .5s ease;
}
.gallery__item:hover img { transform: scale(1.06); }
/* a little rhythm: make some items span/taller */
.gallery__item:nth-child(2) { grid-column: span 1; }
.gallery__item:nth-child(1) img { aspect-ratio: 3 / 4; }
.gallery__item:nth-child(3),
.gallery__item:nth-child(4) { grid-row: span 1; }
.gallery__item:nth-child(3) img,
.gallery__item:nth-child(4) img { aspect-ratio: 3 / 4.4; }

/* =========================================================================
   8. LOVE STORY
   ========================================================================= */
.story .divider { margin-bottom: 28px; }
.story__item { max-width: 400px; margin: 0 auto 26px; }
.story__h { font-size: 24px; margin-bottom: 8px; }
.story__item p {
  font-family: var(--f-serif);
  font-size: 18px;
  color: #2a1a1a;
  margin: 0;
}

/* =========================================================================
   9. WEDDING GIFT
   ========================================================================= */
.gift { padding: 0; }
.gift__frame {
  position: relative;
  margin: 40px 18px 46px;
  padding: 38px 22px 42px;
  text-align: center;
  background: var(--cream);
  border-radius: 16px;
  outline: 2px solid var(--gold);
  outline-offset: -10px;
  box-shadow: var(--shadow-card);
}
.gift__intro {
  font-family: var(--f-serif);
  font-size: 19px;
  color: #2a1a1a;
  max-width: 360px;
  margin: 18px auto 30px;
}
.gift__card {
  position: relative;
  text-align: left;
  color: #fff;
  border-radius: 14px;
  padding: 22px 22px 24px 92px;
  margin: 0 auto 20px;
  min-height: 150px;
  max-width: 420px;
  background: #5d0505 url("../assets/img/songket-card.jpg") left top / 92px auto repeat-y;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
}
.gift__bank { margin-left: auto; height: 34px; width: auto; }
img.gift__bank { object-fit: contain; }
.gift__line { display: block; height: 1px; background: rgba(216, 194, 120, .5); margin: 14px 0 16px; }
.gift__row { display: flex; flex-direction: column-reverse; gap: 12px; }
.gift__copy {
  display: inline-flex; align-items: center; gap: 6px;
  align-self: flex-start;
  background: none; border: none; color: #fff;
  font-family: var(--f-caps); font-size: 15px;
}
.gift__acc { text-align: right; min-width: 0; width: 100%; }
.gift__no { display: block; font-family: var(--f-caps); font-size: 22px; letter-spacing: 1px; overflow-wrap: anywhere; }
@media (max-width: 480px) {
  .gift__no { font-size: 16px; letter-spacing: .5px; }
  .gift__no--addr { font-size: 15px; }
}
.gift__no--addr { font-size: 16px; line-height: 1.25; }
.gift__name { display: block; font-family: var(--f-serif); font-size: 18px; margin-top: 6px; }

/* =========================================================================
   10. BEST WISH
   ========================================================================= */
.wishes {
  background:
    linear-gradient(rgba(74, 4, 4, .9), rgba(74, 4, 4, .96)),
    url("../assets/img/cover-minang.jpg") center top / cover;
  padding: 46px 22px 50px;
  text-align: center;
}
.wishes__sub {
  font-family: var(--f-serif);
  font-style: italic;
  color: #fff;
  font-size: 19px;
  margin: 8px 0 24px;
}
.wishes__form { display: flex; flex-direction: column; gap: 14px; max-width: 440px; margin: 0 auto 30px; }
.wishes__form input,
.wishes__form textarea {
  font-family: var(--f-title);
  font-size: 18px;
  border: none;
  border-radius: 12px;
  padding: 16px 18px;
  background: #fff;
  color: #333;
  resize: vertical;
}
.wishes__form .btn { align-self: flex-start; }
.wishes__list { max-width: 440px; margin: 0 auto; max-height: 360px; overflow-y: auto; padding-right: 4px; }
.wish {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
  text-align: left;
}
.wish__avatar {
  flex: 0 0 52px;
  width: 52px; height: 52px;
  border-radius: 50%;
  border: 2px solid var(--gold);
  background: url("../assets/img/minang-scene.jpg") center / 180px;
}
.wish__bubble {
  background: #fff;
  border-radius: 14px;
  padding: 12px 16px;
  flex: 1;
}
.wish__name { font-family: var(--f-caps); font-weight: 700; font-size: 15px; color: #2a1a1a; }
.wish__msg { font-family: var(--f-serif); font-size: 18px; color: #333; margin-top: 2px; }

/* =========================================================================
   11. RSVP
   ========================================================================= */
.rsvp {
  background: var(--maroon);
  padding: 40px 22px 56px;
  text-align: center;
}
.rsvp__form { display: flex; flex-direction: column; gap: 16px; max-width: 440px; margin: 24px auto 0; text-align: left; }
.rsvp__form label { font-family: var(--f-title); color: #fff; font-size: 22px; display: flex; flex-direction: column; gap: 8px; }
.rsvp__form input,
.rsvp__form select {
  font-family: var(--f-serif);
  font-size: 18px;
  border: none;
  border-radius: 30px;
  padding: 14px 20px;
  background: #fff;
  color: #333;
}
.rsvp__form select {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 8'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%23333' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 20px center;
  background-size: 14px 8px;
}
.rsvp__attend { border: none; padding: 0; margin: 0; text-align: left; }
.rsvp__attend legend { font-family: var(--f-title); color: #fff; font-size: 22px; margin-bottom: 12px; }
.rsvp__form .radio {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-family: var(--f-serif);
  font-size: 18px;
  margin-bottom: 10px;
}
.radio input { accent-color: var(--gold); width: 18px; height: 18px; }
.rsvp__form .btn { align-self: stretch; }
.rsvp__done { color: var(--gold-light); font-family: var(--f-caps); margin-top: 18px; letter-spacing: 1px; }

/* =========================================================================
   12. CLOSING
   ========================================================================= */
.closing__photo {
  width: 60%;
  max-width: 250px;
  aspect-ratio: 3 / 4;
  margin: 0 auto 26px;
  border-width: 4px;
}
.closing__text {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 19px;
  color: var(--maroon);
  max-width: 380px;
  margin: 0 auto 26px;
}
.closing__names { font-size: 58px; }

/* =========================================================================
   MUSIC TOGGLE
   ========================================================================= */
.music {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 70;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(160deg, var(--gold-light), var(--gold));
  box-shadow: 0 6px 16px rgba(0, 0, 0, .35);
  display: grid;
  place-items: center;
}
.music__disc {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--maroon);
  box-shadow: inset 0 0 0 5px var(--gold-light), inset 0 0 0 7px var(--maroon);
}
.music.is-playing { animation: spin 3.5s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* =========================================================================
   LIGHTBOX
   ========================================================================= */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(20, 2, 2, .94);
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 90vw; max-height: 84vh; border-radius: 6px; box-shadow: 0 10px 40px rgba(0, 0, 0, .6); }
.lightbox__close {
  position: absolute; top: 18px; right: 22px;
  background: none; border: none; color: #fff; font-size: 40px; line-height: 1;
}
.lightbox__nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255, 255, 255, .12); border: none; color: #fff;
  font-size: 40px; width: 54px; height: 70px; border-radius: 8px;
}
.lightbox__nav--prev { left: 12px; }
.lightbox__nav--next { right: 12px; }

/* =========================================================================
   DESKTOP SPLIT LAYOUT (>= 992px)
   ========================================================================= */
@media (min-width: 992px) {
  body { background: #1a0303; }

  .stage-side {
    display: block;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    right: var(--canvas);
    background: url("../assets/img/Foto Bersama.png") center / cover no-repeat;
  }
  .stage-side__overlay {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(20, 2, 2, .55) 0%, rgba(20, 2, 2, .68) 50%, rgba(20, 2, 2, .9) 100%);
  }
  .stage-side__text {
    position: absolute;
    left: 0; right: 0; bottom: 11%;
    text-align: center;
    color: #fff;
    padding: 0 8%;
  }
  .stage-side__text .caps { color: #fff; letter-spacing: 3px; }
  .side-names {
    font-family: var(--f-serif);
    font-weight: 400;
    font-size: 64px;
    margin: 10px 0;
    line-height: 1;
  }
  .side-date { font-size: 14px; }

  .invite {
    margin: 0 0 0 auto;
    box-shadow: -10px 0 50px rgba(0, 0, 0, .55);
  }
  .cover { left: auto; right: 0; width: var(--canvas); margin: 0; }
  .music { right: calc((100vw - var(--canvas)) / 2 - 23px); }
  @media (max-width: 1100px) { .music { right: 16px; } }
}
