/* Thiệp cưới: 3 mẫu dùng chung bố cục, khác nhau ở bảng màu, phông chữ và hoa văn.
   Thiệp có màu cố định như thiệp in, không đổi theo chế độ sáng/tối của máy. */
:root { color-scheme: light; }
.t-hong {
  --backdrop: #ecdad6; --paper: #fdf7f5; --paper2: #f8ebe8; --ink: #4e3238; --muted: #8a6b70;
  --accent: #a84a60; --accent2: #d79aa6; --line: #ead0d3; --on-accent: #ffffff; --field: #ffffff;
  --script: 'Great Vibes', 'Brush Script MT', cursive; --serif: 'Cormorant Garamond', Georgia, serif;
  --script-scale: 1.18; --script-style: normal; --body-size: 19px; --hero-tint: rgba(60, 22, 34, .62);
  --title: 'Cormorant Garamond', Georgia, serif; --title-style: italic; --title-weight: 500; --r: 999px; --seal: radial-gradient(circle at 35% 30%, #c76a80, #a84a60 55%, #7d3043);
}
.t-do {
  --backdrop: #4f0c0f; --paper: #8a1b1e; --paper2: #7a1619; --ink: #f8e8c4; --muted: #e8cd9e;
  --accent: #ecc874; --accent2: #c99b45; --line: rgba(236, 200, 116, .42); --on-accent: #6a1215; --field: rgba(255, 240, 210, .08);
  --script: 'Playfair Display', Georgia, serif; --serif: 'Playfair Display', Georgia, serif;
  --script-scale: .82; --script-style: italic; --body-size: 16.5px; --hero-tint: rgba(56, 4, 6, .7);
  --title: 'Playfair Display', Georgia, serif; --title-style: italic; --title-weight: 400; --r: 2px; --seal: radial-gradient(circle at 35% 30%, #fbe7b0, #ecc874 45%, #b48a3c);
  --foil: linear-gradient(100deg, #b8893d 0%, #f3d98f 30%, #fff1c9 45%, #e2bb68 60%, #b8893d 85%);
}
.t-la {
  --backdrop: #dfe7da; --paper: #f8faf5; --paper2: #eef3e9; --ink: #2b4434; --muted: #667d6c;
  --accent: #2f5c3f; --accent2: #8fb398; --line: #d3e0cd; --on-accent: #ffffff; --field: #ffffff;
  --script: 'Dancing Script', 'Brush Script MT', cursive; --serif: 'Lora', Georgia, serif;
  --script-scale: 1; --script-style: normal; --body-size: 16.5px; --hero-tint: rgba(16, 36, 24, .6);
  --title: 'Cormorant Garamond', Georgia, serif; --title-style: italic; --title-weight: 500; --r: 999px; --seal: radial-gradient(circle at 35% 30%, #4f8462, #2f5c3f 55%, #1e3d29);
}
.t-kim {
  --backdrop: #0b0a08; --paper: #13110e; --paper2: #1a1713; --ink: #efe6d3; --muted: #a99c84;
  --accent: #d6b46e; --accent2: #8f7442; --line: rgba(214, 180, 110, .28); --on-accent: #16120b; --field: rgba(255, 240, 210, .04);
  --script: 'Cormorant Garamond', Georgia, serif; --serif: 'Cormorant Garamond', Georgia, serif;
  --script-scale: 1.02; --script-style: italic; --body-size: 18.5px; --hero-tint: rgba(8, 6, 4, .78);
  --title: 'Cormorant Garamond', Georgia, serif; --title-style: italic; --title-weight: 400; --r: 2px; --seal: radial-gradient(circle at 35% 30%, #f6e3b4, #d6b46e 45%, #9a7a3f);
  --foil: linear-gradient(100deg, #9c7a3e 0%, #e7cd92 28%, #fff3d4 42%, #d2ad66 58%, #9c7a3e 82%);
  --env: #1f1b16; --env-flap: #2a241d; --env-in: #0e0c0a; --env-edge: #8f7442;
}
:root { --sans: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', sans-serif; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--backdrop, #ecdad6); color: var(--ink); font-family: var(--serif);
  font-size: var(--body-size); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.t-hong { background-image: radial-gradient(circle at 20% 20%, rgba(255,255,255,.45) 0 2px, transparent 3px), radial-gradient(circle at 70% 60%, rgba(168,74,96,.10) 0 2px, transparent 3px); background-size: 46px 46px, 64px 64px; }
body.t-do { background-image: repeating-linear-gradient(45deg, rgba(236,200,116,.06) 0 2px, transparent 2px 22px), repeating-linear-gradient(-45deg, rgba(236,200,116,.06) 0 2px, transparent 2px 22px); }
body.t-kim { background-image: radial-gradient(circle at 50% 0, rgba(214,180,110,.10), transparent 60%); }
body.t-la { background-image: radial-gradient(circle at 30% 30%, rgba(47,92,63,.08) 0 2px, transparent 3px); background-size: 38px 38px; }
body.locked { overflow: hidden; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }

.sheet { max-width: 480px; margin: 0 auto; background: var(--paper); position: relative; overflow: hidden; min-height: 100vh; }
@media (min-width: 560px) { .sheet { box-shadow: 0 30px 80px -30px rgba(30, 5, 12, .45); } }
@media (min-width: 960px) { .sheet { margin-block: 32px; border-radius: 28px; } }

/* ---------- chữ ---------- */
.kicker { font-family: var(--sans); font-size: 11.5px; font-weight: 600; letter-spacing: .32em; text-transform: uppercase; color: var(--accent); }
.script { font-family: var(--script); font-style: var(--script-style); font-weight: 400; line-height: 1.05; }
.sec-title { font-size: calc(48px * var(--script-scale)); color: var(--accent); }
.t-do .sec-title { font-weight: 500; }
.lead-text { max-width: 32ch; margin-inline: auto; color: var(--ink); }
.sec p, .event .addr, .invite-line { text-wrap: balance; }
.t-hong .script { word-spacing: .08em; }
.small { font-size: .86em; color: var(--muted); }
.orn { display: flex; justify-content: center; color: var(--accent2); }
.orn svg { width: 150px; height: auto; display: block; }

/* ---------- mở đầu: phong bì ---------- */
.envelope-screen {
  position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px;
  background: var(--backdrop); background-image: inherit; transition: opacity .8s ease .2s, visibility 0s linear 1s;
}
.t-hong .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #f8e6e3 0, #ecdad6 70%); }
.t-do .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #7a1619 0, #4f0c0f 75%); }
.t-la .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #f1f5ee 0, #dfe7da 70%); }
.t-kim .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #221d17 0, #0b0a08 72%); }
.envelope-screen.gone { opacity: 0; visibility: hidden; pointer-events: none; }
.env-wrap { display: grid; gap: 26px; justify-items: center; text-align: center; }
.env-to { display: grid; gap: 6px; color: var(--ink); }
.t-do .env-to { color: var(--ink); }
.env-to .guest { font-family: var(--script); font-style: var(--script-style); font-size: calc(40px * var(--script-scale)); color: var(--accent); line-height: 1.1; }
.envelope { position: relative; width: min(320px, 82vw); aspect-ratio: 16 / 11; perspective: 1200px; cursor: pointer; border: 0; padding: 0; background: none; }
.env-back, .env-front, .env-flap, .env-letter { position: absolute; left: 0; right: 0; }
.env-back { inset: 0; border-radius: 6px; background: var(--env-in, #e9c5c9); box-shadow: 0 28px 50px -22px rgba(40, 10, 20, .45); }
.t-hong { --env: #f5dcdf; --env-flap: #eecdd1; --env-in: #e2b3ba; --env-edge: #d9a8b0; }
.t-do { --env: #ac2428; --env-flap: #9c1d21; --env-in: #7d1417; --env-edge: #d4a14e; }
.t-la { --env: #e2ecdc; --env-flap: #d4e2cc; --env-in: #bdd1b3; --env-edge: #a9c09e; }
.env-letter {
  left: 7%; right: 7%; top: 8%; bottom: 6%; background: var(--paper); border-radius: 4px; z-index: 2;
  display: grid; place-items: center; align-content: center; gap: 4px; padding: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .12); transition: transform 1s cubic-bezier(.2, .8, .2, 1) .55s;
}
.env-letter .script { font-size: calc(30px * var(--script-scale)); color: var(--accent); }
.env-letter .kicker { font-size: 9px; }
.env-front {
  inset: 0; z-index: 3; border-radius: 6px; background: var(--env);
  clip-path: polygon(0 0, 50% 52%, 100% 0, 100% 100%, 0 100%);
  box-shadow: inset 0 -1px 0 var(--env-edge);
}
.env-front::before { content: ""; position: absolute; inset: 0; background: linear-gradient(to top right, transparent 49.6%, var(--env-edge) 50%, transparent 50.6%), linear-gradient(to top left, transparent 49.6%, var(--env-edge) 50%, transparent 50.6%); opacity: .7; }
.env-flap-wrap { position: absolute; inset: 0; z-index: 4; filter: drop-shadow(0 3px 3px rgba(40, 10, 20, .22)); pointer-events: none; transition: z-index 0s linear .35s; }
.envelope.open .env-flap-wrap { z-index: 1; }
.env-flap {
  top: 0; height: 58%; z-index: 4; background: var(--env-flap); transform-origin: top center;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transition: transform .7s cubic-bezier(.4, 0, .2, 1), z-index 0s linear .35s;
}
.env-seal {
  position: absolute; left: 50%; top: 58%; z-index: 5; width: 62px; height: 62px; margin: -31px 0 0 -31px; border-radius: 50%;
  display: grid; place-items: center; background: var(--accent); color: var(--on-accent);
  font-family: var(--script); font-style: var(--script-style); font-size: calc(21px * var(--script-scale)); letter-spacing: -.04em; white-space: nowrap;
  box-shadow: 0 3px 8px rgba(0, 0, 0, .25), inset 0 0 0 3px rgba(255, 255, 255, .18); transition: transform .4s, opacity .4s;
}
.t-do .env-seal { font-family: 'Songti SC', 'Noto Serif SC', 'SimSun', serif; font-style: normal; font-size: 30px; }
.envelope.open .env-flap { transform: rotateX(180deg); z-index: 1; }
.envelope.open .env-seal { transform: scale(.4); opacity: 0; }
.envelope.open .env-letter { transform: translateY(-46%); }
.env-hint { font-family: var(--sans); font-size: 13px; letter-spacing: .08em; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.env-hint i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.8); opacity: .35; } }

/* ---------- ảnh bìa ---------- */
.hero { position: relative; min-height: 600px; height: 100vh; height: 100svh; max-height: 920px; display: flex; align-items: flex-end; color: #fff; overflow: hidden; }
.hero-img { position: absolute; inset: -8% 0 0; background-size: cover; background-position: center; will-change: transform; transform: scale(1.06); }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.05) 30%, var(--hero-tint) 100%); }
.hero-inner { position: relative; z-index: 2; width: 100%; padding: 0 clamp(14px, 6vw, 28px) 72px; text-align: center; display: grid; gap: 14px; justify-items: center; }
.hero .kicker { color: rgba(255, 255, 255, .92); }
.hero-names { font-size: calc(clamp(30px, 10.4vw, 60px) * var(--script-scale)); max-width: 100%; overflow-wrap: anywhere; color: #fff; text-shadow: 0 2px 20px rgba(0, 0, 0, .25); display: grid; }
.t-do .hero-names { font-weight: 500; }
.hero-names .amp { font-size: .5em; opacity: .85; margin: -.1em 0; }
.hero-date { font-family: var(--sans); font-size: 14px; letter-spacing: .32em; font-weight: 500; }
.scroll-cue { position: absolute; z-index: 2; left: 50%; bottom: 18px; width: 1px; height: 40px; background: rgba(255,255,255,.4); overflow: hidden; }
.scroll-cue::after { content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: #fff; animation: cue 2s ease-in-out infinite; }
@keyframes cue { to { top: 100%; } }

.hero.art { color: var(--ink); background: var(--paper2); }
.hero.art::after { display: none; }
.hero.art .hero-inner { padding: 60px 40px 70px; align-self: center; }
.hero.art .kicker { color: var(--accent); }
.hero.art .hero-names { color: var(--accent); text-shadow: none; }
.hero.art .scroll-cue { background: var(--line); }
.hero.art .scroll-cue::after { background: var(--accent); }
.art-frame { position: absolute; inset: 22px; border: 1px solid var(--line); border-radius: 220px 220px 18px 18px; pointer-events: none; }
.t-do .art-frame { border-radius: 12px; border-color: var(--accent2); box-shadow: inset 0 0 0 6px var(--paper2), inset 0 0 0 7px var(--line); }
.art-hy { font-family: 'Songti SC', 'Noto Serif SC', 'SimSun', serif; font-size: 120px; line-height: 1; color: var(--accent); text-shadow: 0 3px 0 rgba(0,0,0,.25); }
.art-mono { width: 136px; height: 136px; border-radius: 50%; border: 1px solid var(--accent2); display: flex; align-items: center; justify-content: center; white-space: nowrap; font-family: var(--script); font-style: var(--script-style); font-size: calc(46px * var(--script-scale)); color: var(--accent); background: var(--paper); box-shadow: 0 0 0 6px var(--paper2), 0 0 0 7px var(--line); }
.art-wreath { position: relative; width: 230px; height: 230px; display: grid; place-items: center; }
.art-wreath .wreath { position: absolute; inset: 0; width: 100%; height: 100%; }
.art-wreath .art-mono { box-shadow: none; border-color: var(--line); }
.t-do .art-frame::before, .t-do .art-frame::after { content: ""; position: absolute; width: 58px; height: 58px; background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 60' fill='none' stroke='%23ecc874' stroke-width='1.6' stroke-linecap='round'%3E%3Cpath d='M4 56V18C4 10 10 4 18 4h38'/%3E%3Cpath d='M12 56V24c0-7 5-12 12-12h32'/%3E%3Cpath d='M20 30c0-6 4-10 10-10 5 0 8 3 8 7s-3 6-6 6-4-2-4-4'/%3E%3C/svg%3E"); }
.t-do .art-frame::before { top: 10px; left: 10px; }
.t-do .art-frame::after { bottom: 10px; right: 10px; transform: rotate(180deg); }
.t-do .hero.art .art-frame { position: absolute; }

/* ---------- các phần ---------- */
.sec { padding: 76px 26px; text-align: center; position: relative; display: grid; gap: 22px; justify-items: center; }
.sec.alt { background: var(--paper2); }
.sec > * { max-width: 100%; }

.parents { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; width: 100%; font-size: .92em; line-height: 1.45; }
.parents .kicker { display: block; margin-bottom: 6px; font-size: 10.5px; }
.parents .place { color: var(--muted); font-size: .88em; margin-top: 4px; }
.couple { display: grid; gap: 8px; width: 100%; }
.couple .person { display: grid; gap: 2px; }
.couple .script { font-size: calc(52px * var(--script-scale)); color: var(--accent); }
.couple .full { font-family: var(--sans); font-size: 12px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.couple .and { font-family: var(--script); font-style: var(--script-style); font-size: calc(34px * var(--script-scale)); color: var(--accent2); }
.invite-line { font-style: italic; color: var(--muted); }

.bigdate { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 14px; width: 100%; max-width: 360px; }
.bigdate .side { font-family: var(--sans); font-size: 12px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; padding-block: 10px; border-block: 1px solid var(--line); }
.bigdate .num { font-size: 76px; line-height: 1; color: var(--accent); font-weight: 500; font-variant-numeric: lining-nums; }
.year { font-family: var(--sans); letter-spacing: .4em; font-size: 14px; font-weight: 500; }
.lunar { font-style: italic; color: var(--muted); }

.cal { width: 100%; max-width: 330px; background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 18px 16px 14px; }
.sec:not(.alt) .cal { background: var(--paper2); }
.cal-head { font-family: var(--sans); font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 12px; color: var(--accent); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px 0; font-family: var(--sans); font-size: 13px; font-variant-numeric: tabular-nums; }
.cal-grid .dow { font-size: 10.5px; font-weight: 600; color: var(--muted); letter-spacing: .06em; padding-bottom: 4px; }
.cal-grid span { height: 34px; display: grid; place-items: center; position: relative; }
.cal-grid .hit { color: var(--on-accent); font-weight: 600; }
.cal-grid .hit::before { content: ""; position: absolute; width: 30px; height: 30px; z-index: -1; background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-7.5-4.6-9.6-9.2C.9 8.4 3 4.5 6.7 4.5c2.2 0 3.6 1.2 5.3 3.1 1.7-1.9 3.1-3.1 5.3-3.1 3.7 0 5.8 3.9 4.3 7.3C19.5 16.4 12 21 12 21z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-7.5-4.6-9.6-9.2C.9 8.4 3 4.5 6.7 4.5c2.2 0 3.6 1.2 5.3 3.1 1.7-1.9 3.1-3.1 5.3-3.1 3.7 0 5.8 3.9 4.3 7.3C19.5 16.4 12 21 12 21z'/%3E%3C/svg%3E") center / contain no-repeat;
          animation: beat 1.6s ease-in-out infinite; }
.cal-grid .hit { isolation: isolate; }
@keyframes beat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.15); } 30% { transform: scale(1); } 45% { transform: scale(1.1); } }

.countdown { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; width: 100%; max-width: 340px; }
.countdown div { border: 1px solid var(--line); border-radius: 14px; padding: 10px 4px 8px; display: grid; gap: 2px; background: var(--paper); }
.sec.alt .countdown div { background: var(--paper); }
.t-do .countdown div { background: rgba(0, 0, 0, .12); }
.countdown b { font-family: var(--sans); font-size: 24px; font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums; line-height: 1.2; }
.countdown small { font-family: var(--sans); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.count-done { font-family: var(--sans); font-weight: 600; color: var(--accent); }

.events { display: grid; gap: 16px; width: 100%; }
.event { border: 1px solid var(--line); border-radius: 20px; padding: 24px 20px; display: grid; gap: 8px; justify-items: center; background: var(--paper); position: relative; }
.sec.alt .event { background: var(--paper); }
.t-do .event { background: rgba(0, 0, 0, .1); }
.event h3 { font-family: var(--script); font-style: var(--script-style); font-weight: 400; font-size: calc(38px * var(--script-scale)); color: var(--accent); line-height: 1.1; }
.event .when { font-family: var(--sans); font-size: 13.5px; font-weight: 500; letter-spacing: .06em; }
.event .when b { font-size: 20px; color: var(--accent); margin-right: 6px; font-weight: 600; }
.event .venue { font-weight: 600; font-size: 1.05em; }
.event .addr { color: var(--muted); font-size: .92em; max-width: 30ch; }
.btn-line { display: inline-flex; align-items: center; gap: 8px; margin-top: 6px; padding: 10px 20px; border-radius: 999px; border: 1px solid var(--accent); color: var(--accent); background: transparent; text-decoration: none; font-family: var(--sans); font-size: 13px; font-weight: 600; cursor: pointer; }
.btn-line:hover { background: var(--accent); color: var(--on-accent); }
.btn-solid { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 26px; border-radius: 999px; border: 0; background: var(--accent); color: var(--on-accent); font-family: var(--sans); font-size: 14px; font-weight: 600; cursor: pointer; }
.btn-solid:hover { filter: brightness(1.07); }
.btn-solid:disabled { opacity: .6; cursor: wait; }
.btn-line svg, .btn-solid svg { width: 16px; height: 16px; }

.story { max-width: 34ch; text-align: left; }
.story::first-letter { font-family: var(--script); font-style: var(--script-style); float: left; font-size: 3.6em; line-height: .8; padding: 6px 8px 0 0; color: var(--accent); }

.album { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: calc(100% + 24px); margin-inline: -12px; }
.album button { border: 0; padding: 0; background: var(--line); border-radius: 12px; overflow: hidden; aspect-ratio: 1; cursor: zoom-in; }
.album button:first-child { grid-column: span 2; aspect-ratio: 4 / 5; }
.album img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
.album button:hover img { transform: scale(1.05); }
.lightbox { position: fixed; inset: 0; z-index: 60; background: rgba(12, 8, 10, .94); display: grid; grid-template-rows: auto 1fr auto; touch-action: pan-y; }
.lightbox[hidden] { display: none; }
.lb-top { display: flex; justify-content: space-between; align-items: center; padding: calc(env(safe-area-inset-top, 0px) + 12px) 16px 8px; color: #fff; font-family: var(--sans); font-size: 13px; }
.lb-img { display: grid; place-items: center; padding: 8px; min-height: 0; }
.lb-img img { max-height: 100%; max-width: 100%; object-fit: contain; border-radius: 6px; user-select: none; -webkit-user-drag: none; }
.lb-nav { display: flex; justify-content: center; gap: 16px; padding: 12px 16px calc(env(safe-area-inset-bottom, 0px) + 18px); }
.lb-btn { width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.08); color: #fff; display: grid; place-items: center; cursor: pointer; }
.lb-btn svg { width: 20px; height: 20px; }

.form { width: 100%; max-width: 360px; display: grid; gap: 14px; text-align: left; font-family: var(--sans); font-size: 14px; }
.form .lbl { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 6px; }
.form input[type=text], .form textarea, .form select { width: 100%; border: 1px solid var(--line); background: var(--field); border-radius: 12px; padding: 12px 14px; font-size: 15px; }
.form textarea { min-height: 96px; resize: vertical; }
.t-do .form input[type=text], .t-do .form textarea, .t-do .form select { color: var(--ink); }
.t-do .form select option { color: #222; }
.form input::placeholder, .form textarea::placeholder { color: var(--muted); opacity: .8; }
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.choice label { border: 1px solid var(--line); border-radius: 12px; padding: 11px 10px; text-align: center; cursor: pointer; font-weight: 500; background: var(--field); display: flex; align-items: center; justify-content: center; min-height: 48px; position: relative; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice input:checked + span { color: var(--accent); }
.choice label:has(input:checked) { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.choice input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 4px; }
.form .actions { display: flex; justify-content: center; padding-top: 4px; }
.form-msg { text-align: center; font-family: var(--sans); font-size: 14px; color: var(--accent); min-height: 1.2em; }
.done-card { width: 100%; max-width: 360px; border: 1px solid var(--line); border-radius: 18px; padding: 26px 20px; display: grid; gap: 8px; justify-items: center; }
.done-card .script { font-size: calc(40px * var(--script-scale)); color: var(--accent); }

.wish-list { width: 100%; max-width: 380px; max-height: 420px; overflow-y: auto; display: grid; gap: 10px; text-align: left; padding: 2px; }
.wish { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.t-do .wish { background: rgba(0, 0, 0, .12); }
.wish b { font-family: var(--sans); font-size: 13px; color: var(--accent); display: block; margin-bottom: 4px; }
.wish p { font-size: .95em; line-height: 1.5; overflow-wrap: anywhere; }
.wish time { font-family: var(--sans); font-size: 11.5px; color: var(--muted); }

.gift-box { width: 100%; max-width: 360px; display: grid; gap: 12px; }
.gift-box[hidden] { display: none; }
.account { border: 1px dashed var(--accent2); border-radius: 14px; padding: 14px 16px; display: grid; gap: 8px; text-align: left; }
.account .who { font-family: var(--sans); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.account .bank { font-family: var(--sans); font-size: 13px; color: var(--muted); }
.account .no { font-family: var(--sans); font-size: 21px; font-weight: 600; letter-spacing: .04em; color: var(--accent); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.account .holder { font-family: var(--sans); font-size: 12.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.account button { justify-self: start; border: 0; background: var(--accent); color: var(--on-accent); font-family: var(--sans); font-size: 12.5px; font-weight: 600; border-radius: 999px; padding: 7px 14px; cursor: pointer; }
.gift-qr { width: 220px; max-width: 100%; margin: 0 auto; border-radius: 14px; background: #fff; padding: 10px; }

.thanks { padding-bottom: 60px; }
.thanks-photo { width: 200px; height: 260px; border-radius: 120px 120px 16px 16px; overflow: hidden; border: 6px solid var(--paper); box-shadow: 0 0 0 1px var(--line); }
.thanks-photo img { width: 100%; height: 100%; object-fit: cover; }
.thanks .script.big { font-size: calc(64px * var(--script-scale)); color: var(--accent); }
.signoff { font-family: var(--sans); font-size: 12.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.made-by { padding: 26px 24px calc(env(safe-area-inset-bottom, 0px) + 84px); text-align: center; font-family: var(--sans); font-size: 12px; line-height: 1.6; color: var(--muted); border-top: 1px solid var(--line); display: grid; gap: 4px; justify-items: center; }
.made-by .mb-brand { font-size: 11px; letter-spacing: .32em; text-transform: uppercase; color: var(--ink); opacity: .8; margin-bottom: 2px; }
.made-by span { max-width: 300px; }
.made-by a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* ---------- nhạc ---------- */
.music-btn { position: fixed; z-index: 40; right: max(16px, calc(50% - 240px + 16px)); bottom: calc(env(safe-area-inset-bottom, 0px) + 18px); width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; cursor: pointer; box-shadow: 0 6px 20px -6px rgba(0, 0, 0, .45); }
.music-btn svg { width: 22px; height: 22px; }
.music-btn::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--accent); opacity: 0; }
.music-btn.on::before { animation: ring 2.2s ease-out infinite; }
@keyframes ring { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.7); opacity: 0; } }
.music-btn .eq { display: none; gap: 3px; align-items: flex-end; height: 18px; }
.music-btn.on .eq { display: flex; }
.music-btn.on .note { display: none; }
.music-btn .eq i { width: 3px; background: currentColor; border-radius: 2px; animation: eq 1s ease-in-out infinite; }
.music-btn .eq i:nth-child(2) { animation-delay: -.4s; } .music-btn .eq i:nth-child(3) { animation-delay: -.7s; } .music-btn .eq i:nth-child(4) { animation-delay: -.2s; }
@keyframes eq { 0%, 100% { height: 5px; } 50% { height: 18px; } }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 480px) { .music-btn { right: 16px; } }

.embed .music-btn, .embed .scroll-cue { display: none; }
.particles { position: fixed; inset: 0; pointer-events: none; z-index: 30; }

/* ---------- trạng thái ---------- */
.notice-screen { min-height: 100vh; display: grid; place-items: center; padding: 40px 24px; text-align: center; }
.notice-screen .box { display: grid; gap: 14px; justify-items: center; max-width: 340px; }
.notice-screen .script { font-size: calc(48px * var(--script-scale)); color: var(--accent); }
.preview-badge { position: fixed; z-index: 45; top: calc(env(safe-area-inset-top, 0px) + 10px); left: 50%; transform: translateX(-50%); background: rgba(20, 12, 16, .78); color: #fff; font-family: var(--sans); font-size: 12px; padding: 6px 12px; border-radius: 999px; white-space: nowrap; }

/* ---------- hiệu ứng khi cuộn ---------- */
.anim [data-r] { opacity: 0; transform: translateY(28px); transition: opacity 1s ease, transform 1.1s cubic-bezier(.2, .8, .2, 1); transition-delay: var(--d, 0s); }
.anim [data-r="zoom"] { transform: scale(.92); }
.anim [data-r="left"] { transform: translateX(-34px); }
.anim [data-r="right"] { transform: translateX(34px); }
.anim [data-r].in { opacity: 1; transform: none; }
.anim .write { clip-path: inset(-20% 100% -20% 0); transition: clip-path 2.2s cubic-bezier(.45, .05, .25, 1); transition-delay: var(--d, .2s); }
.anim .in .write, .anim .write.in { clip-path: inset(-20% -10% -20% 0); }
.anim .orn path { stroke-dasharray: 400; stroke-dashoffset: 400; transition: stroke-dashoffset 2.4s ease .2s; }
.anim .in .orn path, .anim .orn.in path { stroke-dashoffset: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* =====================================================================
   Lớp hoàn thiện cao cấp: vân giấy, nhũ vàng, khung ảnh bìa, album kiểu tạp chí,
   phông nền mờ từ ảnh bìa khi xem trên máy tính, con dấu sáp ở phong bì.
   ===================================================================== */
.sheet::after { content: ""; position: absolute; inset: 0; z-index: 6; pointer-events: none; opacity: .07; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .7 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.t-do .sheet::after, .t-kim .sheet::after { mix-blend-mode: overlay; opacity: .16; }

/* Phông nền mờ lấy từ ảnh bìa khi mở trên máy tính */
@media (min-width: 560px) {
  body.has-cover::before { content: ""; position: fixed; inset: -60px; z-index: -1; background: var(--cover) center / cover no-repeat; filter: blur(38px) saturate(1.05) brightness(.62); transform: scale(1.08); }
  body.has-cover { background: #0d0b0a; }
  .t-hong.has-cover::before, .t-la.has-cover::before { filter: blur(38px) saturate(1.05) brightness(.82); }
}

/* Tiêu đề mục: chữ có chân nghiêng thay cho chữ viết tay */
.sec-title.script { font-family: var(--title); font-style: var(--title-style); font-weight: var(--title-weight); font-size: 44px; line-height: 1.08; letter-spacing: -.005em; }
.t-kim .sec-title.script { font-size: 46px; }
.kicker { letter-spacing: .34em; }
.t-kim .kicker, .t-do .kicker { color: var(--accent); }

/* Nhũ vàng cho chữ ở mẫu Song Hỷ và Hoàng Kim */
.t-kim .hero-names .write, .t-do .hero-names .write, .t-kim .couple .script, .t-do .couple .script,
.t-kim .sec-title .write, .t-kim .bigdate .num, .t-kim .thanks .script.big, .t-kim .art-mono, .t-kim .event h3 {
  background: var(--foil); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none;
}
.t-kim .hero-names, .t-do .hero-names { filter: drop-shadow(0 3px 14px rgba(0, 0, 0, .45)); }
.t-kim .hero.art .hero-names, .t-do .hero.art .hero-names { filter: none; }
.anim .t-kim .hero-names .write, .t-kim .bigdate .num { animation: foilmove 8s ease-in-out infinite alternate; }
@keyframes foilmove { from { background-position: 0% 50%; } to { background-position: 100% 50%; } }

/* Ảnh bìa: khung chỉ mảnh, ngày cưới giữa hai đường kẻ */
.hero-frame { position: absolute; inset: 14px; z-index: 2; border: 1px solid rgba(255, 255, 255, .42); pointer-events: none; }
.hero-frame::before { content: ""; position: absolute; inset: 5px; border: 1px solid rgba(255, 255, 255, .18); }
.t-kim .hero-frame, .t-do .hero-frame { border-color: rgba(214, 180, 110, .6); }
.t-kim .hero-frame::before, .t-do .hero-frame::before { border-color: rgba(214, 180, 110, .25); }
.hero::after { background: linear-gradient(180deg, rgba(0, 0, 0, .18) 0%, rgba(0, 0, 0, 0) 28%, rgba(0, 0, 0, 0) 45%, var(--hero-tint) 100%); }
.hero-inner { padding-bottom: 84px; }
.hero-date { display: flex; align-items: center; gap: 14px; font-size: 13px; letter-spacing: .38em; }
.hero-date::before, .hero-date::after { content: ""; width: 34px; height: 1px; background: currentColor; opacity: .7; }
.hero .kicker { letter-spacing: .42em; }
.t-kim .hero-names { font-weight: 300; font-size: calc(clamp(36px, 12.2vw, 68px) * var(--script-scale)); line-height: .98; }
.t-kim .hero-names .amp { font-size: .42em; margin: .1em 0; }
.t-kim .hero:not(.art) .kicker, .t-kim .hero:not(.art) .hero-date { color: #ead7ab; }

/* Phong bì: con dấu sáp có vân nổi */
.env-seal { background: var(--seal, var(--accent)); box-shadow: 0 4px 10px rgba(0, 0, 0, .35), inset 0 0 0 4px rgba(255, 255, 255, .12), inset 0 -3px 6px rgba(0, 0, 0, .25), inset 0 3px 5px rgba(255, 255, 255, .25); text-shadow: 0 1px 0 rgba(0, 0, 0, .25); }
.env-seal::before { content: ""; position: absolute; inset: 7px; border-radius: 50%; border: 1px dashed rgba(255, 255, 255, .35); }
.t-kim .env-seal { color: #2a1f0e; text-shadow: 0 1px 0 rgba(255, 255, 255, .35); font-family: 'Cormorant Garamond', serif; font-style: italic; font-size: 26px; }
.t-kim .env-letter { background: #f4ecdc; color: #1b1611; }
.t-kim .env-letter .script { color: #7a5c2e; }
.t-kim .env-letter .kicker { color: #8a7a60; }
.t-kim .env-to .guest { background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent; }
.env-to .kicker { letter-spacing: .4em; }

/* Thẻ, nút: góc theo từng mẫu */
.t-kim .event, .t-do .event { border-radius: 2px; outline: 1px solid var(--line); outline-offset: -7px; padding: 30px 22px; }
.t-kim .event { background: rgba(255, 240, 210, .025); }
.t-kim .countdown div, .t-do .countdown div { border-radius: 2px; }
.t-kim .cal, .t-do .cal { border-radius: 2px; }
.t-kim .btn-line, .t-kim .btn-solid, .t-do .btn-line, .t-do .btn-solid { border-radius: 2px; letter-spacing: .16em; text-transform: uppercase; font-size: 12px; }
.t-kim .btn-solid { background: var(--foil); background-size: 180% 100%; color: #1d160c; }
.t-kim .account, .t-do .account { border-radius: 2px; border-style: solid; border-color: var(--line); }
.t-kim .wish, .t-kim .choice label, .t-kim .form input[type=text], .t-kim .form textarea, .t-kim .form select { border-radius: 2px; }
.t-kim .form input[type=text], .t-kim .form textarea, .t-kim .form select { color: var(--ink); }
.t-kim .form select option { color: #222; }
.t-kim .wish { background: rgba(255, 240, 210, .03); }
.t-kim .sec.alt { background: var(--paper2); }
.t-kim .sec:not(.alt) .cal { background: var(--paper2); }
.t-kim .thanks-photo { border-radius: 2px; border-color: var(--paper); box-shadow: 0 0 0 1px var(--accent2); }
.t-kim .made-by a { color: var(--accent); }

/* Album kiểu tạp chí: ảnh đầu dọc lớn, rồi xen kẽ cặp ảnh dọc và một ảnh ngang */
.album { gap: 6px; width: calc(100% + 40px); margin-inline: -20px; }
.album button { border-radius: 0; aspect-ratio: 3 / 4; }
.album button:first-child { grid-column: span 2; aspect-ratio: 4 / 5; }
.album button:nth-child(3n+4) { grid-column: span 2; aspect-ratio: 3 / 2; }
.album button:nth-child(3n+2):last-child { grid-column: span 2; aspect-ratio: 3 / 2; }

/* Mẫu Hoàng Kim không ảnh: chữ lồng trong khung art deco */
.art-deco { position: relative; width: 250px; height: 250px; display: grid; place-items: center; }
.art-deco svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.t-kim .art-frame { border-radius: 2px; border-color: var(--accent2); box-shadow: inset 0 0 0 6px var(--paper2), inset 0 0 0 7px var(--line); }
.t-kim .hero.art { background: radial-gradient(circle at 50% 38%, #221d16, var(--paper) 70%); }
.t-kim .art-mono { border-color: var(--accent2); box-shadow: 0 0 0 6px var(--paper), 0 0 0 7px var(--line); font-weight: 300; }
.t-kim .env-flap { background: linear-gradient(180deg, #2f2922, #231e18); }
.t-kim .env-flap-wrap { filter: drop-shadow(0 1px 0 rgba(214, 180, 110, .75)) drop-shadow(0 5px 8px rgba(0, 0, 0, .55)); }
.t-kim .env-back { box-shadow: 0 30px 60px -24px rgba(0, 0, 0, .8), 0 0 0 1px rgba(214, 180, 110, .25); }
.t-do .env-flap-wrap { filter: drop-shadow(0 1px 0 rgba(236, 200, 116, .7)) drop-shadow(0 4px 6px rgba(40, 0, 0, .4)); }
.t-kim .countdown b, .t-do .countdown b { font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1.1; }
.t-kim .event .when b, .t-do .event .when b { font-family: var(--serif); font-weight: 500; font-size: 24px; }
.t-hong .countdown b, .t-la .countdown b { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 500; font-size: 30px; line-height: 1.1; }
.countdown div { border-radius: 4px; }
.t-hong .event .when b, .t-la .event .when b { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 600; font-size: 25px; }

/* ================= Mẫu Xuân (Tết): đỏ son, hoa mai vàng rơi ================= */
.t-xuan {
  --backdrop: #5e0a0d; --paper: #a3191d; --paper2: #8e1418; --ink: #fff3d9; --muted: #f6d6a2;
  --accent: #ffd23f; --accent2: #e8a93a; --line: rgba(255, 210, 63, .4); --on-accent: #7d0f12; --field: rgba(255, 240, 210, .1);
  --script: 'Playfair Display', Georgia, serif; --serif: 'Lora', Georgia, serif;
  --script-scale: .86; --script-style: italic; --body-size: 17px; --hero-tint: rgba(80, 5, 8, .72);
  --title: 'Playfair Display', Georgia, serif; --title-style: italic; --title-weight: 500; --r: 2px;
  --seal: radial-gradient(circle at 35% 30%, #fff0b3, #ffd23f 45%, #c98f16);
  --foil: linear-gradient(100deg, #d99a1e 0%, #ffe27a 30%, #fff6cf 45%, #ffd23f 60%, #d99a1e 85%);
  --env: #c4262b; --env-flap: #b31f24; --env-in: #7d0f12; --env-edge: #ffd23f;
}
body.t-xuan { background-image: radial-gradient(circle at 25% 25%, rgba(255, 210, 63, .10) 0 1.5px, transparent 2.5px), radial-gradient(circle at 75% 75%, rgba(255, 210, 63, .07) 0 1.5px, transparent 2.5px); background-size: 34px 34px; }
.t-xuan .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #8e1418 0, #5e0a0d 75%); }
.t-xuan .env-seal { font-family: 'Songti SC', 'Noto Serif SC', 'SimSun', serif; font-style: normal; font-size: 28px; color: #7d0f12; }
.t-xuan .env-letter { background: #fff5dd; color: #7d0f12; }
.t-xuan .env-letter .script { color: #a3191d; }
.t-xuan .env-flap-wrap { filter: drop-shadow(0 1px 0 rgba(255, 210, 63, .75)) drop-shadow(0 4px 6px rgba(40, 0, 0, .4)); }
.t-xuan .hero.art { background: radial-gradient(circle at 50% 36%, #b71f24, var(--paper) 70%); }

/* ================= Mẫu Đông (Giáng sinh): xanh thông, vàng, tuyết rơi ================= */
.t-dong {
  --backdrop: #0a2019; --paper: #11342a; --paper2: #0d2b22; --ink: #f3efe6; --muted: #b9c8bd;
  --accent: #e8c77a; --accent2: #b0905a; --line: rgba(232, 199, 122, .3); --on-accent: #0d2b22; --field: rgba(255, 255, 255, .05);
  --script: 'Cormorant Garamond', Georgia, serif; --serif: 'Cormorant Garamond', Georgia, serif;
  --script-scale: 1.02; --script-style: italic; --body-size: 18.5px; --hero-tint: rgba(5, 20, 15, .75);
  --title: 'Cormorant Garamond', Georgia, serif; --title-style: italic; --title-weight: 400; --r: 2px;
  --seal: radial-gradient(circle at 35% 30%, #f8e4b0, #e8c77a 45%, #a8853f);
  --foil: linear-gradient(100deg, #a8853f 0%, #f0d699 28%, #fff6dc 42%, #e2c27c 58%, #a8853f 82%);
  --env: #1a4436; --env-flap: #1f4e3f; --env-in: #0b241c; --env-edge: #b0905a;
}
body.t-dong { background-image: radial-gradient(circle at 50% 0, rgba(232, 199, 122, .10), transparent 60%); }
.t-dong .envelope-screen { background-image: radial-gradient(circle at 50% 40%, #174033 0, #0a2019 72%); }
.t-dong .env-seal { color: #2a1f0e; font-family: 'Cormorant Garamond', serif; font-size: 26px; }
.t-dong .env-letter { background: #f6f1e4; color: #11342a; }
.t-dong .env-letter .script { color: #8a6a2e; }
.t-dong .env-flap-wrap { filter: drop-shadow(0 1px 0 rgba(232, 199, 122, .7)) drop-shadow(0 5px 8px rgba(0, 0, 0, .5)); }
.t-dong .hero.art { background: radial-gradient(circle at 50% 38%, #1b4a3b, var(--paper) 70%); }

/* Hai mẫu nền tối mới dùng chung cách trình bày với Song Hỷ và Hoàng Kim */
.t-xuan .kicker, .t-dong .kicker { color: var(--accent); }
.t-xuan .hero-names .write, .t-dong .hero-names .write, .t-xuan .sec-title .write, .t-dong .sec-title .write,
.t-xuan .bigdate .num, .t-dong .bigdate .num, .t-xuan .art-mono, .t-dong .art-mono, .t-xuan .ev-title .write, .t-dong .ev-title .write, .t-xuan .to .write, .t-dong .to .write {
  background: var(--foil); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
}
.anim .t-xuan .hero-names .write, .anim .t-dong .hero-names .write { animation: foilmove 8s ease-in-out infinite alternate; }
.t-xuan .hero-names, .t-dong .hero-names { filter: drop-shadow(0 3px 14px rgba(0, 0, 0, .45)); }
.t-xuan .hero.art .hero-names, .t-dong .hero.art .hero-names { filter: none; }
.t-xuan .hero-frame, .t-dong .hero-frame { border-color: rgba(232, 199, 122, .6); }
.t-xuan .hero-frame::before, .t-dong .hero-frame::before { border-color: rgba(232, 199, 122, .25); }
.t-xuan .sheet::after, .t-dong .sheet::after { mix-blend-mode: overlay; opacity: .16; }
.t-xuan .event, .t-dong .event { border-radius: 2px; outline: 1px solid var(--line); outline-offset: -7px; padding: 30px 22px; background: rgba(0, 0, 0, .1); }
.t-xuan .countdown div, .t-dong .countdown div { border-radius: 2px; background: rgba(0, 0, 0, .14); }
.t-xuan .countdown b, .t-dong .countdown b { font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1.1; }
.t-xuan .cal, .t-dong .cal { border-radius: 2px; }
.t-xuan .btn-line, .t-xuan .btn-solid, .t-dong .btn-line, .t-dong .btn-solid { border-radius: 2px; letter-spacing: .16em; text-transform: uppercase; font-size: 12px; }
.t-xuan .btn-solid, .t-dong .btn-solid { background: var(--foil); background-size: 180% 100%; color: #2a1a06; }
.t-xuan .wish, .t-dong .wish { background: rgba(0, 0, 0, .12); border-radius: 2px; }
.t-xuan .form input[type=text], .t-xuan .form textarea, .t-xuan .form select, .t-dong .form input[type=text], .t-dong .form textarea, .t-dong .form select { color: var(--ink); border-radius: 2px; }
.t-xuan .form select option, .t-dong .form select option { color: #222; }
.t-xuan .account, .t-dong .account { border-radius: 2px; border-style: solid; border-color: var(--line); }
.t-xuan .art-frame, .t-dong .art-frame { border-radius: 2px; border-color: var(--accent2); box-shadow: inset 0 0 0 6px var(--paper2), inset 0 0 0 7px var(--line); }
.t-xuan .art-mono, .t-dong .art-mono { border-color: var(--accent2); box-shadow: 0 0 0 6px var(--paper), 0 0 0 7px var(--line); font-weight: 400; }
.t-xuan .made-by a, .t-dong .made-by a { color: var(--accent); }

/* Cành mai quanh chữ lồng */
.art-xuan { position: relative; width: 250px; height: 250px; display: grid; place-items: center; }
.art-xuan svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.anim .art-xuan svg { animation: sway 7s ease-in-out infinite alternate; transform-origin: 50% 50%; }
@keyframes sway { from { transform: rotate(-2deg); } to { transform: rotate(2deg); } }
.t-xuan .art-mono { font-family: 'Songti SC', 'Noto Serif SC', 'SimSun', 'Playfair Display', serif; font-style: normal; }
.art-hy .art-mono.plain { width: auto; height: auto; border: 0; box-shadow: none; font-size: .7em; }

/* ================= Thiệp sự kiện và thiệp chúc ================= */
.hero-names.one { line-height: 1.08; }
.k-chuc .hero-names { font-size: calc(clamp(30px, 10vw, 56px) * var(--script-scale)); }
.host { font-family: var(--sans); font-size: 12px; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); max-width: 30ch; line-height: 1.7; }
.ev-title { font-size: calc(50px * var(--script-scale)); color: var(--accent); line-height: 1.1; }
.ev-of { font-style: italic; color: var(--muted); margin-top: -8px; }
.ev-name { font-family: var(--title, var(--serif)); font-style: var(--title-style, normal); font-weight: var(--title-weight, 500); font-size: 30px; line-height: 1.25; color: var(--ink); max-width: 20ch; }
.letter { gap: 26px; }
.letter .to { font-size: calc(40px * var(--script-scale)); color: var(--accent); line-height: 1.15; }
.letter-body { max-width: 32ch; display: grid; gap: 14px; text-align: center; font-size: 1.04em; line-height: 1.75; }
.letter-body p:first-child { font-family: var(--title, var(--serif)); font-style: var(--title-style, normal); font-size: 1.15em; color: var(--accent); }
.sign { display: grid; gap: 6px; justify-items: center; }
.sign .script { font-size: calc(34px * var(--script-scale)); color: var(--accent); }
.logo-mark { max-width: 140px; max-height: 70px; object-fit: contain; margin-top: 10px; }
.made-by.quiet { padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 84px); }
.k-chuc .hero-date::before, .k-chuc .hero-date::after { width: 22px; }
.k-chuc .hero-date { letter-spacing: .2em; text-transform: none; font-size: 13.5px; }

/* Nút chỉ đường và lưu vào lịch nằm cạnh nhau */
.ev-acts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 4px; }
.ev-acts .btn-line { margin: 0; }

/* Thiệp sự kiện, chúc mừng: tên ngày lễ nhiều dấu tiếng Việt và con số,
   chữ viết tay (Great Vibes, Dancing Script) làm dấu chồng lên nhau, khó đọc.
   Dùng chữ có chân nghiêng cùng bộ của mẫu (đã tải sẵn, không thêm font). */
.k-chuc.t-hong, .k-su-kien.t-hong { --script: 'Cormorant Garamond', Georgia, serif; --script-style: italic; --script-scale: 1.02; }
.k-chuc.t-la, .k-su-kien.t-la { --script: 'Lora', Georgia, serif; --script-style: italic; --script-scale: .8; }
.k-chuc.t-hong .script, .k-su-kien.t-hong .script, .k-chuc.t-hong .env-to .guest, .k-su-kien.t-hong .env-to .guest { font-weight: 500; }
.k-chuc .hero-names.one, .k-su-kien .hero-names.one { letter-spacing: -.01em; line-height: 1.12; }
.k-chuc.t-hong .script, .k-su-kien.t-hong .script { word-spacing: 0; }
.k-chuc .script, .k-su-kien .script { font-variant-numeric: lining-nums; }
