/* Mẫu Phong Bì Matcha — theo video mẫu chủ shop gửi (đã xin phép). Màu đo từ video (đã trừ ám tím màn hình): phong bì #8a9457,
   băng/thẻ sự kiện xanh matcha #b0b46c, nền trắng, chữ xám nâu. Chữ in hoa có chân (EB Garamond), tiêu đề viết tay (Pinyon Script),
   monogram Great Vibes. Hoa tự vẽ SVG. Góc vuông. */

.t-phong-bi-matcha {
  --matcha: #b0b46c;
  --env: #8a9457;
  --env-deep: #737d45;
  --paper: #f4f1e6;
  --ink: #4b4a3f;
  --soft: #7a786a;
  --f-script: "Pinyon Script", cursive;
  --f-mono: "Great Vibes", cursive;
  --f-serif: "EB Garamond", Georgia, serif;
  --gate-bg: #8a9457;
  --gate-ink: #ffffff;
  color: var(--ink);
  font-family: var(--f-serif);
}
.t-phong-bi-matcha .thiepmai-frame { background: #fff; overflow-x: hidden; }
.t-phong-bi-matcha .thiepmai-frame > section { position: relative; }
.t-phong-bi-matcha p, .t-phong-bi-matcha h1, .t-phong-bi-matcha h2, .t-phong-bi-matcha figure { margin: 0; }
.t-phong-bi-matcha .ph { inset: 0; }
.t-phong-bi-matcha .pm-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* chữ dùng chung */
.t-phong-bi-matcha .pm-sec { padding: 40px 26px; text-align: center; }
.t-phong-bi-matcha .pm-caps { font: 500 13px/1.55 var(--f-serif); letter-spacing: .06em; text-transform: uppercase; color: var(--soft); }
.t-phong-bi-matcha .pm-script { font: 400 34px/1.2 var(--f-script); color: var(--ink); }
.t-phong-bi-matcha .pm-title { margin-bottom: 20px; }
.t-phong-bi-matcha .pm-btn {
  display: inline-block; margin-top: 16px; padding: 6px 30px; border: 1px solid rgba(255, 255, 255, .85); background: transparent; color: #fff;
  font: 500 12px var(--f-serif); letter-spacing: .12em; text-transform: uppercase; text-decoration: none; cursor: pointer;
}
.t-phong-bi-matcha .pm-btn--dark { width: 100%; margin-top: 6px; padding: 11px; border-color: #33352a; background: #33352a; }
.t-phong-bi-matcha .pm-bunch { position: absolute; display: block; pointer-events: none; }

/* ảnh polaroid: viền giấy ngà, đáy dày */
.t-phong-bi-matcha .pm-pola { position: absolute; padding: 9px 9px 30px; background: #f7f6f1; box-shadow: 0 6px 16px rgba(40, 40, 20, .18); }
.t-phong-bi-matcha .pm-pola__img { position: relative; height: 100%; background: #e8e8e0; }
.t-phong-bi-matcha .pm-pola figcaption { position: absolute; left: 0; right: 0; bottom: 4px; font-size: 18px; text-align: center; color: var(--soft); }

/* ---------- 1. bìa: phong bì ---------- */
.t-phong-bi-matcha .pm-cover { padding: 0 0 46px; text-align: center; overflow: hidden; }
.t-phong-bi-matcha .pm-cover__bunch-top { left: 28px; top: 34px; width: 150px; height: 172px; rotate: -8deg; }
.t-phong-bi-matcha .pm-env { position: relative; height: 560px; }
.t-phong-bi-matcha .pm-env__back { position: absolute; left: 22px; right: 22px; bottom: 0; height: 250px; background: var(--env-deep); }
.t-phong-bi-matcha .pm-env__flap {
  position: absolute; left: 22px; right: 22px; bottom: 250px; height: 120px; background: var(--env-deep);
  clip-path: polygon(0 100%, 50% 0, 100% 100%); transform-origin: bottom; opacity: .92;
}
.t-phong-bi-matcha .pm-env__inner { position: absolute; left: 22px; right: 22px; bottom: 60px; height: 440px; }
.t-phong-bi-matcha .pm-env__pola { width: 168px; height: 216px; }
.t-phong-bi-matcha .pm-env__pola--l { left: 16px; top: 120px; rotate: -6deg; }
.t-phong-bi-matcha .pm-env__pola--r { right: 6px; top: 70px; rotate: 5deg; width: 180px; height: 236px; }
.t-phong-bi-matcha .pm-ticket {
  position: absolute; padding: 22px 16px 18px 40px; background: var(--paper); box-shadow: 0 6px 14px rgba(40, 40, 20, .16); text-align: center;
  -webkit-mask: radial-gradient(circle 7px at 24px 0, #0000 98%, #000) top / 100% 51% no-repeat, radial-gradient(circle 7px at 24px 100%, #0000 98%, #000) bottom / 100% 51% no-repeat;
          mask: radial-gradient(circle 7px at 24px 0, #0000 98%, #000) top / 100% 51% no-repeat, radial-gradient(circle 7px at 24px 100%, #0000 98%, #000) bottom / 100% 51% no-repeat;
}
.t-phong-bi-matcha .pm-ticket::before { content: ""; position: absolute; left: 24px; top: 10px; bottom: 10px; border-left: 1px dashed #b9b5a2; }
.t-phong-bi-matcha .pm-env__ticket { left: 30px; top: 252px; width: 240px; rotate: -3deg; }
.t-phong-bi-matcha .pm-ticket__stub {
  position: absolute; left: 4px; top: 50%; translate: 0 -50%; writing-mode: vertical-rl; rotate: 180deg;
  font: 500 10px var(--f-serif); letter-spacing: .2em; color: var(--soft);
}
.t-phong-bi-matcha .pm-ticket__k { font-size: 15px; color: var(--ink); }
.t-phong-bi-matcha .pm-ticket__date { margin-top: 2px; font: 500 30px/1.15 var(--f-serif); letter-spacing: .06em; font-variant-numeric: lining-nums; }
.t-phong-bi-matcha .pm-ticket__s { margin-top: 2px; font-size: 19px; white-space: nowrap; color: var(--soft); }
.t-phong-bi-matcha .pm-env__front {
  position: absolute; left: 22px; right: 22px; bottom: 0; height: 190px; background: var(--env);
  clip-path: polygon(0 0, 50% 46%, 100% 0, 100% 100%, 0 100%); box-shadow: 0 -2px 0 rgba(0, 0, 0, .05);
}
.t-phong-bi-matcha .pm-env__front::before {
  content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(255, 255, 255, .08), rgba(0, 0, 0, .06));
}
.t-phong-bi-matcha .pm-mono { position: absolute; left: 0; right: 0; top: 98px; font: 400 34px/1 var(--f-mono); color: rgba(255, 255, 255, .92); }
.t-phong-bi-matcha .pm-mono i { font-style: normal; font-size: .6em; margin: 0 1px; }
.t-phong-bi-matcha .pm-env__bunch-r { right: 2px; top: 230px; width: 120px; height: 138px; rotate: 14deg; }
.t-phong-bi-matcha .pm-env__bunch-l { left: 0; bottom: -40px; width: 130px; height: 150px; rotate: -16deg; }
.t-phong-bi-matcha .pm-cover__names { margin-top: 30px; font: 500 21px var(--f-serif); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.t-phong-bi-matcha .pm-cover__date { margin-top: 4px; font: 400 16px var(--f-serif); letter-spacing: .14em; color: var(--soft); font-variant-numeric: lining-nums; }

/* thẻ và ảnh trượt lên khỏi phong bì */
.t-phong-bi-matcha [data-anim="pm-rise"].is-in { animation-name: pm-rise; animation-timing-function: cubic-bezier(.2, .7, .2, 1); }
@keyframes pm-rise { from { opacity: 0; transform: translate3d(0, 190px, 0); } 30% { opacity: 1; } to { opacity: 1; transform: none; } }

/* ---------- 2. băng xanh: polaroid + lịch ---------- */
.t-phong-bi-matcha .pm-band { display: grid; grid-template-columns: 150px 1fr; gap: 14px; align-items: center; padding: 26px 16px 26px 14px; background: var(--matcha); }
.t-phong-bi-matcha .pm-band__pola { position: relative; height: 200px; rotate: -2deg; }
.t-phong-bi-matcha .pm-cal { text-align: center; color: #fff; }
.t-phong-bi-matcha .pm-cal__title { font-size: 24px; color: #fff; margin-bottom: 6px; }
.t-phong-bi-matcha .pm-cal__row { display: grid; grid-template-columns: repeat(7, 1fr); }
.t-phong-bi-matcha .pm-cal__row span { position: relative; display: grid; place-items: center; height: 24px; font: 500 12px var(--f-serif); font-variant-numeric: lining-nums; color: #fff; }
.t-phong-bi-matcha .pm-cal__row--head span { height: 20px; font-size: 9px; letter-spacing: .04em; color: rgba(255, 255, 255, .85); }
.t-phong-bi-matcha .pm-cal__row span.is-day svg { position: absolute; width: 24px; height: 22px; }
.t-phong-bi-matcha .pm-cal__row span.is-day b { position: relative; font-weight: 700; color: var(--env-deep); }

/* ---------- 3. lời mời ---------- */
.t-phong-bi-matcha .pm-invite { padding-top: 46px; }
.t-phong-bi-matcha .pm-invite__lead { font-size: 12px; }
.t-phong-bi-matcha .pm-invite__names { display: grid; margin-top: 18px; font: 500 26px/1.15 var(--f-serif); letter-spacing: .06em; text-transform: uppercase; color: var(--ink); }
.t-phong-bi-matcha .pm-invite__names .pm-script { margin: -6px 0 -10px; font-size: 40px; color: #a7a98a; text-transform: none; }
.t-phong-bi-matcha .pm-invite__pics { position: relative; height: 330px; margin: 26px -26px 0; }
.t-phong-bi-matcha .pm-invite__pola { top: 20px; width: 200px; height: 262px; }
.t-phong-bi-matcha .pm-invite__pola--l { left: 18px; rotate: -3deg; }
.t-phong-bi-matcha .pm-invite__pola--r { right: 14px; top: 34px; width: 176px; height: 236px; rotate: 3deg; }
.t-phong-bi-matcha .pm-invite__bunch-r { right: -24px; top: -40px; width: 110px; height: 126px; rotate: -10deg; }
.t-phong-bi-matcha .pm-invite__bunch-l { left: -10px; bottom: -10px; width: 110px; height: 126px; rotate: 160deg; }
.t-phong-bi-matcha .pm-families { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.t-phong-bi-matcha .pm-families p { font: 400 15px/1.5 var(--f-serif); color: var(--ink); }
.t-phong-bi-matcha .pm-families b { display: block; color: var(--ink); font-size: 14px; }

/* ---------- 4. lễ & tiệc ---------- */
.t-phong-bi-matcha .pm-events { display: grid; gap: 18px; padding-top: 10px; }
.t-phong-bi-matcha .pm-event { padding: 26px 18px 28px; background: var(--matcha); color: #fff; box-shadow: 0 6px 16px rgba(60, 60, 20, .12); }
.t-phong-bi-matcha .pm-event .pm-caps { color: rgba(255, 255, 255, .92); }
.t-phong-bi-matcha .pm-event__title { font-size: 17px; font-weight: 600; color: #fff !important; }
.t-phong-bi-matcha .pm-event__at { margin-top: 2px; font-size: 12px; }
.t-phong-bi-matcha .pm-event__date { display: inline-block; margin-top: 12px; padding: 3px 14px; border-top: 1px solid rgba(255, 255, 255, .8); border-bottom: 1px solid rgba(255, 255, 255, .8);
  font: 600 22px var(--f-serif); letter-spacing: .1em; font-variant-numeric: lining-nums; }
.t-phong-bi-matcha .pm-event__lunar { margin-top: 6px; font: italic 400 13px var(--f-serif); color: rgba(255, 255, 255, .9); }
.t-phong-bi-matcha .pm-pin { display: block; width: 16px; height: 20px; margin: 16px auto 0; }
.t-phong-bi-matcha .pm-event__place { margin-top: 4px; font-size: 30px; color: #fff; }
.t-phong-bi-matcha .pm-event__addr { margin-top: 4px; font-size: 11px; }
.t-phong-bi-matcha .thiepmai-events { padding: 0 26px 10px; }
.t-phong-bi-matcha .thiepmai-event { background: var(--matcha); color: #fff; }

/* ---------- 5. lịch trình ---------- */
.t-phong-bi-matcha .pm-program__list { margin: 0; padding: 0; list-style: none; }
.t-phong-bi-matcha .pm-program__list li { display: grid; grid-template-columns: 70px 1fr; align-items: baseline; gap: 12px; padding: 10px 0; border-bottom: 1px dashed #cfd0b0; text-align: left; }
.t-phong-bi-matcha .pm-program__list b { font: 600 18px var(--f-serif); font-variant-numeric: lining-nums; color: var(--env-deep); }
.t-phong-bi-matcha .pm-program__list .pm-caps { color: var(--ink); }
.t-phong-bi-matcha .pm-program__list small { grid-column: 2; font: italic 400 14px var(--f-serif); color: var(--soft); }

/* ---------- 6. album: ảnh lớn xen 2 ảnh nhỏ ---------- */
.t-phong-bi-matcha .pm-album__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.t-phong-bi-matcha .pm-album__pic { position: relative; height: 230px; background: #eee; }
.t-phong-bi-matcha .pm-album__pic:nth-child(3n + 1) { grid-column: 1 / -1; height: 300px; }

/* ---------- 7. xác nhận ---------- */
.t-phong-bi-matcha .pm-rsvp__lead { font-size: 12px; }
.t-phong-bi-matcha .pm-form { display: grid; gap: 12px; margin-top: 18px; }
.t-phong-bi-matcha .pm-field { width: 100%; box-sizing: border-box; padding: 10px 16px; border: 1px solid #8f907c; border-radius: 0; background: #fff; color: var(--ink); font: 400 15px var(--f-serif); }
.t-phong-bi-matcha .pm-field::placeholder { color: #8f8d80; }
.t-phong-bi-matcha .pm-form__msg { min-height: 18px; font: 500 14px var(--f-serif); color: var(--env-deep); }

/* ---------- 8. mừng cưới ---------- */
.t-phong-bi-matcha .pm-gift { padding-top: 10px; }
.t-phong-bi-matcha .pm-gift__card { padding: 24px 22px; background: var(--matcha); }
.t-phong-bi-matcha .pm-gift__card .pm-caps { color: #fff; font-size: 12px; }

/* ---------- 9. cảm ơn ---------- */
.t-phong-bi-matcha .pm-thanks { height: 620px; margin-top: 20px; overflow: hidden; text-align: center; }
.t-phong-bi-matcha .pm-thanks__box { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; padding: 28px 30px 34px; background: rgba(156, 162, 96, .82); color: #fff; }
.t-phong-bi-matcha .pm-thanks__big { font-size: 46px; color: #fff; }
.t-phong-bi-matcha .pm-thanks__sub { margin-top: 6px; font: italic 400 15px/1.5 var(--f-serif); }

/* ---------- màn mở thiệp: cửa xanh phong bì ---------- */
.t-phong-bi-matcha .thiepmai-gate__door { background: var(--env); }
.t-phong-bi-matcha .thiepmai-gate__names { font-family: var(--f-script); font-size: 29px; line-height: 1.2; }
.t-phong-bi-matcha .thiepmai-gate__open { border-radius: 0; }
.t-phong-bi-matcha .thiepmai-credit { background: var(--env); }
.t-phong-bi-matcha .thiepmai-credit a { background: rgba(255, 255, 255, .9); }

/* ---------- đếm ngược ---------- */
.t-phong-bi-matcha .pm-cd { padding-bottom: 6px; }
.t-phong-bi-matcha .pm-cd__title { font: 400 30px/1.2 var(--f-script); color: var(--ink); }
.t-phong-bi-matcha .pm-cd__row { display: flex; justify-content: center; gap: 12px; margin-top: 14px; }
.t-phong-bi-matcha .pm-cd__row p { display: grid; gap: 2px; width: 64px; padding: 10px 0 8px; background: var(--paper); box-shadow: 0 4px 12px rgba(0, 0, 0, .08); }
.t-phong-bi-matcha .pm-cd__row b { font: 500 26px var(--f-serif); color: var(--env-deep); font-variant-numeric: lining-nums tabular-nums; }
.t-phong-bi-matcha .pm-cd__row span { font: 500 11px var(--f-serif); letter-spacing: .08em; text-transform: uppercase; color: var(--soft); }
