/* ==========================================================
   Thiệp cưới Anh Nguyên & Lan Anh
   Tông màu: đỏ son – vàng kim – giấy dó
   ========================================================== */
:root {
  --red: #8f1d1d;
  --red-deep: #5e0f12;
  --red-bright: #c0392b;
  --gold: #c9a24a;
  --gold-light: #ecd28b;
  --paper: #fbf3e4;
  --ink: #3a2418;
  --muted: #8a6f5c;
  --font-script: 'Dancing Script', cursive;
  --font-serif: 'Playfair Display', serif;
  --font-body: 'Be Vietnam Pro', system-ui, sans-serif;
  --radius: 14px;
  --shadow: 0 18px 40px -18px rgba(94, 15, 18, .45);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  overflow-x: hidden;
}
body.locked { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }

.container { width: min(1100px, 100% - 32px); margin-inline: auto; }
.container--narrow { width: min(720px, 100% - 32px); }
.center { text-align: center; }
.muted { color: var(--muted); font-size: .92em; }
.light { color: #f8e9d0; }

/* ---------- Nút ---------- */
.btn {
  border: 0; cursor: pointer; font: 600 1rem var(--font-body);
  padding: .85em 2.2em; border-radius: 999px; letter-spacing: .04em;
  transition: transform .25s, box-shadow .25s;
}
.btn:hover { transform: translateY(-2px); }
.btn--gold {
  color: var(--red-deep);
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  box-shadow: 0 8px 24px -8px rgba(201, 162, 74, .8);
}
.btn--red { color: #fff; background: var(--red); }

/* ---------- Dấu Song Hỷ ---------- */
.seal {
  width: 92px; height: 92px; margin: 1rem auto;
  display: grid; place-items: center;
  font-size: 3rem; color: var(--gold-light);
  background: radial-gradient(circle at 30% 30%, var(--red-bright), var(--red-deep));
  border: 3px solid var(--gold); border-radius: 50%;
  box-shadow: 0 0 0 6px rgba(201, 162, 74, .25), var(--shadow);
}
.seal--small { width: 60px; height: 60px; font-size: 2rem; }

/* ==========================================================
   Màn mở thiệp
   ========================================================== */
.envelope {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center; padding: 16px;
  background:
    radial-gradient(circle at 50% 40%, rgba(201,162,74,.18), transparent 60%),
    var(--red-deep);
  transition: opacity 1s ease, visibility 1s;
}
.envelope.is-open { opacity: 0; visibility: hidden; }
.envelope__card {
  position: relative; width: min(380px, 100%);
  perspective: 1200px;
}
.envelope__flap {
  position: absolute; inset: 0 0 auto 0; height: 26%; z-index: 2;
  background: linear-gradient(160deg, var(--red-bright), var(--red));
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: top; transition: transform 1s cubic-bezier(.6,0,.3,1);
  border-radius: var(--radius) var(--radius) 0 0;
}
.envelope.is-opening .envelope__flap { transform: rotateX(180deg); }
.envelope__body {
  text-align: center; padding: 8.5rem 2rem 2.5rem;
  background: linear-gradient(180deg, var(--red), var(--red-deep));
  border: 2px solid var(--gold); border-radius: var(--radius);
  color: var(--gold-light); box-shadow: var(--shadow);
}
.envelope__to { margin: 0; letter-spacing: .3em; text-transform: uppercase; font-size: .75rem; }
.envelope__guest { font: 700 2rem var(--font-script); margin: .2rem 0; }
.envelope__names { font: italic 500 1.2rem var(--font-serif); margin: .5rem 0 1.5rem; }
.envelope .seal { animation: pulse 2.4s ease-in-out infinite; }

/* ==========================================================
   Điều hướng
   ========================================================== */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: .8rem 24px; transition: background .4s, box-shadow .4s;
}
.nav.is-solid { background: rgba(94, 15, 18, .92); backdrop-filter: blur(8px); box-shadow: var(--shadow); }
.nav__logo { font: 700 1.6rem var(--font-script); color: var(--gold-light); text-decoration: none; }
.nav__logo span { color: var(--red-bright); }
.nav__links { display: flex; gap: 1.4rem; list-style: none; margin: 0; padding: 0; }
.nav__links a {
  color: #f8e9d0; text-decoration: none; font-size: .9rem; letter-spacing: .03em;
  position: relative;
}
.nav__links a::after {
  content: ''; position: absolute; left: 0; bottom: -4px; height: 1px; width: 100%;
  background: var(--gold); transform: scaleX(0); transition: transform .3s;
}
.nav__links a:hover::after { transform: scaleX(1); }
.nav__toggle { display: none; background: none; border: 0; color: var(--gold-light); font-size: 1.6rem; cursor: pointer; }

@media (max-width: 860px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; background: rgba(94, 15, 18, .97);
    max-height: 0; overflow: hidden; transition: max-height .4s;
  }
  .nav__links.is-open { max-height: 420px; }
  .nav__links a { display: block; padding: .8rem 24px; }
}

/* ==========================================================
   Hero
   ========================================================== */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: grid; place-items: center; text-align: center;
  color: #fff; overflow: hidden; padding: 6rem 16px 4rem;
  background: radial-gradient(ellipse at 50% 30%, #7a1518 0%, #3d070a 70%, #22040600 100%), #22040a;
}
#bg3d { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__content { position: relative; z-index: 1; }
.hero__eyebrow {
  letter-spacing: .5em; text-transform: uppercase; font-size: .8rem;
  color: var(--gold-light); margin: 0 0 1rem;
}
.hero__names {
  /* line-height + padding đủ rộng để đuôi chữ g, y không bị background-clip cắt mất */
  font: 700 clamp(3rem, 9vw, 6.5rem)/1.3 var(--font-script);
  margin: 0; padding: 0 .15em .15em; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0 .35em;
  background: linear-gradient(180deg, #fff6d6, var(--gold) 70%, #a37a2c);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 18px rgba(0,0,0,.45));
}
.hero__names .amp { font-size: .6em; }
.hero__date { font: italic 500 clamp(1.1rem, 2.6vw, 1.5rem) var(--font-serif); margin: 1.2rem 0 .2rem; }
.hero__lunar { margin: 0; color: #f0d9b5; font-size: .9rem; }
.hero__scroll {
  position: absolute; bottom: 1.2rem; left: 50%; translate: -50% 0; z-index: 1;
  color: var(--gold-light); font-size: 2rem; text-decoration: none;
  animation: bob 2s ease-in-out infinite;
}

.countdown { display: flex; justify-content: center; gap: clamp(.5rem, 2vw, 1.2rem); margin-top: 2rem; }
.countdown div {
  min-width: 72px; padding: .7rem .5rem;
  border: 1px solid rgba(236, 210, 139, .5); border-radius: 12px;
  background: rgba(94, 15, 18, .45); backdrop-filter: blur(4px);
}
.countdown span { display: block; font: 700 clamp(1.5rem, 4vw, 2.2rem) var(--font-serif); color: var(--gold-light); }
.countdown small { font-size: .7rem; letter-spacing: .15em; text-transform: uppercase; }

/* ==========================================================
   Section chung
   ========================================================== */
.section { padding: clamp(4rem, 9vw, 7rem) 0; position: relative; }
.section--paper {
  background:
    radial-gradient(circle at 0 0, rgba(201,162,74,.12), transparent 40%),
    radial-gradient(circle at 100% 100%, rgba(143,29,29,.08), transparent 40%),
    var(--paper);
}
.section--red {
  color: #f8e9d0;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cpath d='M40 0 L80 40 L40 80 L0 40Z' fill='none' stroke='%23c9a24a' stroke-opacity='.08'/%3E%3C/svg%3E"),
    linear-gradient(180deg, var(--red), var(--red-deep));
}
.section__title {
  font: 700 clamp(2.2rem, 5vw, 3.2rem) var(--font-script);
  color: var(--red); text-align: center; margin: 0 0 2.5rem;
}
.section__title::after {
  content: '❖'; display: block; font-size: .9rem; color: var(--gold); margin-top: .3rem;
}
.section__title--light { color: var(--gold-light); }

/* ---------- Lời mời ---------- */
.ornament { text-align: center; font-size: 3.5rem; color: var(--red); line-height: 1; }
.families { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin: 2rem 0 3rem; text-align: center; }
.family h3 {
  font: 600 1rem var(--font-body); letter-spacing: .3em; text-transform: uppercase;
  color: var(--red); margin: 0 0 .6rem;
}
.family p { margin: .15rem 0; }
.invite-lead { text-align: center; letter-spacing: .08em; text-transform: uppercase; font-size: .85rem; color: var(--muted); }
.invite-names {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; text-align: center;
  font: 700 clamp(2.4rem, 6vw, 4rem)/1.1 var(--font-script); color: var(--red); margin: 1rem 0 2rem;
}
.invite-names span:nth-of-type(1) { grid-column: 1; grid-row: 1; }
.invite-names small:nth-of-type(1) { grid-column: 1; grid-row: 2; }
.invite-names .amp { grid-column: 2; grid-row: 1 / 3; color: var(--gold); padding: 0 1rem; }
.invite-names span:nth-of-type(3) { grid-column: 3; grid-row: 1; }
.invite-names small:nth-of-type(2) { grid-column: 3; grid-row: 2; }
.invite-names small { font: 400 .8rem var(--font-body); color: var(--muted); letter-spacing: .2em; text-transform: uppercase; }
.poem {
  text-align: center; font: italic 500 1.15rem var(--font-serif); color: var(--ink);
  margin: 0 auto 1.5rem; max-width: 520px;
}
.poem cite { display: block; font: normal .8rem var(--font-body); color: var(--muted); margin-top: .4rem; }
.invite-text { text-align: center; max-width: 620px; margin: 0 auto; }

@media (max-width: 560px) {
  .families { grid-template-columns: 1fr; }
}

/* ---------- Ảnh placeholder ---------- */
.photo {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, #f1dfc0, #e6c9a0);
  background-size: cover; background-position: center;
}
.photo:not([style*="background-image"])::after {
  content: attr(data-label); position: absolute; inset: 0; display: grid; place-items: center;
  color: var(--muted); font-size: .85rem; letter-spacing: .1em;
}
.photo--round {
  width: 220px; aspect-ratio: 1; border-radius: 50%; margin: 0 auto 1.2rem;
  border: 4px solid #fff; outline: 2px solid var(--gold); outline-offset: 6px; box-shadow: var(--shadow);
}
.photo--qr { width: 180px; aspect-ratio: 1; border-radius: 12px; margin: 1rem auto; border: 2px dashed var(--gold); }

/* ---------- Cô dâu & chú rể ---------- */
.couple { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 2rem; }
.person { text-align: center; }
.person h3 { font: 700 2.4rem var(--font-script); color: var(--red); margin: 0; }
.person .role { margin: 0 0 .8rem; color: var(--gold); letter-spacing: .3em; text-transform: uppercase; font-size: .75rem; }
.couple__heart { font-size: 3rem; color: var(--red-bright); animation: beat 1.4s ease-in-out infinite; }
@media (max-width: 760px) { .couple { grid-template-columns: 1fr; } }

/* ---------- Timeline ---------- */
.timeline { list-style: none; padding: 0; margin: 0 auto; max-width: 820px; position: relative; }
.timeline::before {
  content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px;
  background: linear-gradient(var(--gold), var(--red), var(--gold));
}
.timeline li {
  position: relative; width: 50%; padding: 0 2.5rem 2.5rem;
}
.timeline li:nth-child(odd) { text-align: right; }
.timeline li:nth-child(even) { margin-left: 50%; }
.timeline li::before {
  content: '♥'; position: absolute; top: 0; width: 34px; height: 34px;
  display: grid; place-items: center; font-size: .9rem; color: #fff;
  background: var(--red); border: 2px solid var(--gold); border-radius: 50%;
}
.timeline li:nth-child(odd)::before { right: -17px; }
.timeline li:nth-child(even)::before { left: -17px; }
.timeline__date { color: var(--gold); font-weight: 600; font-size: .85rem; letter-spacing: .1em; }
.timeline h4 { font: 700 1.3rem var(--font-serif); color: var(--red); margin: .2rem 0; }
.timeline p { margin: 0; }
@media (max-width: 680px) {
  .timeline::before { left: 17px; }
  .timeline li, .timeline li:nth-child(even) { width: 100%; margin-left: 0; text-align: left; padding: 0 0 2rem 3.2rem; }
  .timeline li:nth-child(odd)::before, .timeline li:nth-child(even)::before { left: 0; right: auto; }
}

/* ---------- Sự kiện ---------- */
.events { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; }
.event {
  flex: 1 1 300px; max-width: 340px; display: flex; flex-direction: column; text-align: center; padding: 2rem 1.5rem; border-radius: var(--radius);
  background: rgba(251, 243, 228, .06); border: 1px solid rgba(236, 210, 139, .35);
  transition: transform .4s, background .4s;
}
.event:hover { transform: translateY(-6px); background: rgba(251, 243, 228, .12); }
.event__icon { font-size: 2.2rem; color: var(--gold-light); }
.event h3 { font: 700 1.9rem var(--font-script); color: var(--gold-light); margin: .3rem 0; }
.event__time { font: 600 1.05rem var(--font-serif); margin: 0; }
.event__date { margin: 0 0 .8rem; font-size: .9rem; opacity: .85; }
.event__place { font-weight: 600; margin: 0; }
.event__addr { font-size: .88rem; opacity: .8; margin: 0 0 1.2rem; }
.event__actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; }
.event__actions a {
  font-size: .8rem; padding: .45em 1.1em; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--gold); color: var(--gold-light); transition: background .3s, color .3s;
}
.event__actions a:hover { background: var(--gold); color: var(--red-deep); }

/* ---------- Lịch trình ---------- */
.schedule { list-style: none; margin: 0; padding: 0; }
.schedule li {
  display: grid; grid-template-columns: 90px 1fr; gap: 1.2rem; align-items: start;
  padding: 1rem 0; border-bottom: 1px dashed rgba(201, 162, 74, .5);
}
.schedule time { font: 700 1.3rem var(--font-serif); color: var(--red); }
.schedule h4 { margin: 0; font-size: 1.05rem; }
.schedule p { margin: 0; color: var(--muted); font-size: .92rem; }

/* ---------- Album ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 220px; gap: 12px; }
.gallery .photo { border-radius: 10px; cursor: zoom-in; transition: transform .5s; }
.gallery .photo:hover { transform: scale(1.03); }
.gallery .photo:nth-child(6n + 1) { grid-row: span 2; }
.gallery .photo:nth-child(6n + 4), .gallery .photo:nth-child(6n) { grid-column: span 2; }
@media (max-width: 640px) {
  .gallery { grid-template-columns: 1fr 1fr; grid-auto-rows: 160px; }
  .gallery .photo:nth-child(6n + 4) { grid-column: span 1; }
  .gallery .photo:nth-child(6n) { grid-column: 1 / -1; }
}
.gallery .photo:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.photo--more::before {
  content: ''; position: absolute; inset: 0;
  background: rgba(94, 15, 18, .55); transition: background .3s;
}
.photo--more:hover::before { background: rgba(94, 15, 18, .4); }
.photo__more {
  position: absolute; inset: 0; display: grid; place-items: center;
  font: 700 clamp(2rem, 5vw, 3rem) var(--font-serif); color: var(--gold-light);
  text-shadow: 0 2px 12px rgba(0, 0, 0, .4);
}

/* ---------- Trình xem album ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 120;
  display: grid; grid-template-columns: 64px minmax(0, 1fr) 64px; grid-template-rows: auto minmax(0, 1fr) auto;
  background: rgba(20, 4, 6, .95); animation: fadeUp .3s ease;
}
.lightbox[hidden] { display: none; }
.lightbox__bar {
  grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px; color: var(--gold-light); font-size: .9rem; letter-spacing: .1em;
}
.lightbox__close, .lightbox__nav {
  background: none; border: 0; color: #fff; cursor: pointer; transition: color .2s, background .2s;
}
.lightbox__close { font-size: 1.6rem; width: 44px; height: 44px; border-radius: 50%; }
.lightbox__nav--prev { grid-column: 1; grid-row: 2; }
.lightbox__nav--next { grid-column: 3; grid-row: 2; }
.lightbox__nav { font-size: 3rem; line-height: 1; align-self: center; height: 72px; border-radius: 12px; }
.lightbox__close:hover, .lightbox__nav:hover { color: var(--gold-light); background: rgba(255, 255, 255, .08); }
.lightbox__stage {
  grid-column: 2; grid-row: 2; margin: 0; min-height: 0; min-width: 0; padding: 0 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .6rem;
}
.lightbox__stage img {
  max-width: 100%; max-height: calc(100vh - 220px); max-height: calc(100svh - 220px); object-fit: contain;
  border-radius: 8px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
  opacity: 0; transform: scale(.97); transition: opacity .35s, transform .35s;
}
.lightbox__stage img.is-loaded { opacity: 1; transform: none; }
.lightbox__stage figcaption { color: #f0d9b5; font: italic 1rem var(--font-serif); }
.lightbox__thumbs {
  grid-column: 1 / -1; display: flex; gap: 8px; padding: 12px 16px 16px;
  overflow-x: auto; scrollbar-width: thin; justify-content: safe center;
}
.lightbox__thumbs button {
  flex: none; width: 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 8px;
  overflow: hidden; cursor: pointer; opacity: .5; background: #000; transition: opacity .2s, border-color .2s;
}
.lightbox__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.lightbox__thumbs button:hover { opacity: .85; }
.lightbox__thumbs button.is-active { opacity: 1; border-color: var(--gold); }
@media (max-width: 640px) {
  .lightbox { grid-template-columns: 0 minmax(0, 1fr) 0; }
  .lightbox__nav {
    position: absolute; top: 50%; translate: 0 -50%; z-index: 1;
    width: 44px; height: 44px; font-size: 2rem; border-radius: 50%; background: rgba(0, 0, 0, .35);
  }
  .lightbox__nav--prev { left: 8px; }
  .lightbox__nav--next { right: 8px; }
  .lightbox__thumbs button { width: 52px; height: 52px; }
}

/* ---------- Dress code ---------- */
.swatches { display: flex; justify-content: center; gap: 1rem; margin: 1.5rem 0; }
.swatches span {
  width: 54px; height: 54px; border-radius: 50%; background: var(--c);
  border: 3px solid #fff; box-shadow: 0 0 0 1px var(--gold), var(--shadow);
}

/* ---------- Form ---------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 1.2rem; margin-top: 2rem; }
.form label { display: flex; flex-direction: column; gap: .35rem; font-size: .88rem; letter-spacing: .03em; }
.form .full { grid-column: 1 / -1; }
.form input, .form select, .form textarea, .guestbook__form input, .guestbook__form textarea {
  font: inherit; padding: .75em 1em; border-radius: 10px; width: 100%;
  border: 1px solid rgba(236, 210, 139, .5); background: rgba(255, 255, 255, .08); color: inherit;
}
.form select option { color: var(--ink); }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--gold); }
.form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form button:disabled { opacity: .6; cursor: wait; transform: none; }
.form__status { text-align: center; min-height: 1.5em; margin: 0; color: var(--gold-light); }
@media (max-width: 560px) { .form { grid-template-columns: 1fr; } }

/* ---------- Mừng cưới ---------- */
.gifts { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; max-width: 760px; margin: 2rem auto 0; }
.gift {
  text-align: center; padding: 2rem; background: #fff; border-radius: var(--radius);
  border-top: 4px solid var(--red); box-shadow: var(--shadow);
}
.gift h4 { font: 700 1.6rem var(--font-script); color: var(--red); margin: 0; }
.gift p { margin: .1rem 0; }
.copy {
  margin-top: .6rem; font: 600 1rem var(--font-body); cursor: pointer;
  padding: .5em 1.2em; border-radius: 8px; border: 1px dashed var(--gold);
  background: var(--paper); color: var(--red);
}

/* ---------- Sổ lưu bút ---------- */
.guestbook__form { display: grid; gap: .8rem; }
.guestbook__form input, .guestbook__form textarea { border-color: rgba(201, 162, 74, .6); background: #fff; }
.guestbook__form .btn { justify-self: center; }
.wishes { list-style: none; padding: 0; margin: 2rem 0 0; display: grid; gap: .8rem; max-height: 420px; overflow-y: auto; }
.wishes li {
  padding: 1rem 1.2rem; background: #fff; border-radius: 12px;
  border-left: 4px solid var(--gold); box-shadow: 0 6px 16px -10px rgba(94, 15, 18, .35);
  animation: fadeUp .5s ease;
}
.wishes strong { color: var(--red); }
.wishes p { margin: .2rem 0 0; }

/* ---------- Footer ---------- */
.footer { text-align: center; padding: 3rem 16px; color: #f8e9d0; background: var(--red-deep); }
.footer__names { font: 700 2.4rem var(--font-script); color: var(--gold-light); margin: 0; }

/* ---------- Nút nhạc, toast ---------- */
.music {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  width: 48px; height: 48px; border-radius: 50%; cursor: pointer;
  font-size: 1.3rem; color: var(--red-deep); border: 2px solid #fff;
  background: linear-gradient(135deg, var(--gold-light), var(--gold)); box-shadow: var(--shadow);
}
.music.is-playing { animation: spin 4s linear infinite; }
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 130; translate: -50% calc(100% + 40px); visibility: hidden;
  padding: .7em 1.4em; border-radius: 999px; background: var(--ink); color: #fff;
  transition: translate .4s, visibility .4s; font-size: .9rem;
}
.toast.is-show { translate: -50% 0; visibility: visible; }

/* ==========================================================
   Hoa đào rơi
   ========================================================== */
.petals { position: fixed; inset: 0; pointer-events: none; z-index: 40; overflow: hidden; }
.petal {
  position: absolute; top: -40px; width: 14px; height: 12px;
  background: radial-gradient(circle at 30% 30%, #ffd6df, #f28aa6);
  border-radius: 12px 0 12px 0; opacity: .85;
  animation: fall linear forwards, sway ease-in-out infinite alternate;
}

/* ==========================================================
   Hiệu ứng xuất hiện khi cuộn
   ========================================================== */
.reveal { opacity: 0; transform: translateY(40px); transition: opacity .9s ease, transform .9s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@keyframes pulse { 50% { transform: scale(1.07); } }
@keyframes beat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.25); } 30% { transform: scale(1); } 45% { transform: scale(1.15); } }
@keyframes bob { 50% { transform: translateY(8px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } }
@keyframes zoomIn { from { opacity: 0; transform: scale(.92); } }
@keyframes fall { to { transform: translateY(110vh) rotate(540deg); } }
@keyframes sway { from { margin-left: -30px; } to { margin-left: 30px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
  .petals { display: none; }
}
