:root {
  --paper: #fffdf8;
  --ink: #28342d;
  --muted: #6c756f;
  --green: #123e2e;
  --green-2: #1f5a43;
  --gold: #b58a48;
  --line: #ded8cd;
  --danger: #b23c32;
  --ease: cubic-bezier(.22,.78,.22,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--ink);
  background: linear-gradient(145deg, #eef3ee 0%, #f7f4ed 50%, #edf1ec 100%);
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }

.page-shell { min-height: 100vh; }
.intro {
  min-height: 100vh;
  padding: 24px 24px 56px;
  display: flex;
  flex-direction: column;
}
.brand-row {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 14px;
}
.brand-mark {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 14px;
  background: var(--green);
  color: #fff;
  font-size: 27px;
  font-weight: 700;
  box-shadow: 0 10px 26px rgba(18,62,46,.22);
}
.eyebrow, .brand-subtitle, .letter-company, .modal-kicker { margin: 0; }
.eyebrow { color: var(--green); font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.brand-subtitle { margin-top: 5px; color: var(--muted); font-size: 14px; }

.hero-copy {
  text-align: center;
  margin: clamp(36px, 7vh, 72px) auto 18px;
  max-width: 760px;
  transition: opacity .45s ease, transform .45s ease;
}
.hero-kicker { margin: 0 0 13px; color: var(--gold); font-size: 12px; font-weight: 700; letter-spacing: .2em; }
.hero-copy h1 { margin: 0; color: var(--green); font-size: clamp(32px, 5vw, 54px); line-height: 1.12; letter-spacing: -.03em; font-weight: 700; }
.hero-copy p:last-child { margin: 18px 0 0; color: var(--muted); font-size: 16px; }
.intro.is-opening .hero-copy { opacity: 0; transform: translateY(-12px); }

.envelope-stage {
  flex: 1;
  min-height: 430px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  perspective: 1400px;
}
.envelope {
  position: relative;
  width: min(620px, 88vw);
  aspect-ratio: 1.55 / 1;
  padding: 0;
  border: 0;
  background: transparent;
  transform-style: preserve-3d;
  transition: transform .45s var(--ease), opacity .55s ease;
}
.envelope:hover { transform: translateY(-6px); }
.envelope:focus-visible { outline: 3px solid rgba(31,90,67,.34); outline-offset: 12px; border-radius: 22px; }
.envelope-back,
.envelope-front,
.envelope-flap,
.letter-sheet {
  position: absolute;
  inset: 0;
  border-radius: 20px;
}
.envelope-back {
  z-index: 1;
  background: linear-gradient(145deg, #ecd8b1, #d8bb83);
  box-shadow: 0 28px 65px rgba(45,58,50,.2);
}
.letter-sheet {
  z-index: 2;
  left: 8%;
  right: 8%;
  top: 8%;
  bottom: 8%;
  inset: 8% 8%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #fffdf8;
  border: 1px solid rgba(181,138,72,.24);
  box-shadow: 0 10px 24px rgba(70,48,18,.12);
  transition: transform 1s var(--ease), opacity .45s ease;
}
.sheet-logo { color: var(--green); font-size: 13px; font-weight: 700; letter-spacing: .14em; }
.sheet-line { width: 42px; height: 2px; margin: 18px 0; background: var(--gold); }
.sheet-title { color: var(--green); font-size: clamp(20px, 3vw, 31px); font-weight: 700; letter-spacing: .04em; }
.sheet-subtitle { margin-top: 10px; color: var(--muted); font-size: clamp(13px, 1.8vw, 17px); }
.envelope-front {
  z-index: 4;
  overflow: hidden;
  background: linear-gradient(180deg, #e6ca95 0%, #d6b678 100%);
  clip-path: polygon(0 31%, 50% 76%, 100% 31%, 100% 100%, 0 100%);
}
.envelope-front::before,
.envelope-front::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.envelope-front::before { background: linear-gradient(33deg, transparent 49.6%, rgba(115,78,28,.13) 50%, transparent 50.8%); }
.envelope-front::after { background: linear-gradient(-33deg, transparent 49.6%, rgba(115,78,28,.13) 50%, transparent 50.8%); }
.envelope-flap {
  z-index: 5;
  background: linear-gradient(180deg, #f1dfbd 0%, #dfc18a 100%);
  clip-path: polygon(0 0, 100% 0, 50% 60%);
  transform-origin: top center;
  backface-visibility: hidden;
  transition: transform .9s var(--ease), z-index 0s .45s;
}
.seal {
  position: absolute;
  z-index: 6;
  left: 50%;
  top: 47%;
  width: 66px;
  height: 66px;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #d8b36d, #9b6b29 72%);
  color: #fffaf0;
  border: 3px double rgba(255,255,255,.58);
  font-size: 27px;
  font-weight: 700;
  box-shadow: 0 9px 20px rgba(78,47,8,.28);
  transition: opacity .3s ease, transform .4s var(--ease);
}
.open-hint {
  border: 0;
  background: transparent;
  color: var(--green);
  font-size: 15px;
  font-weight: 700;
}
.open-hint span { display: inline-block; margin-left: 8px; animation: bounce 1.4s ease-in-out infinite; }

.envelope-stage.opened .envelope-flap { transform: rotateX(180deg); z-index: 0; }
.envelope-stage.opened .seal { opacity: 0; transform: translate(-50%, -62%) scale(.55); }
.envelope-stage.opened .letter-sheet { transform: translateY(-60%); }
.envelope-stage.fly-away .envelope { opacity: 0; transform: translateY(-28px) scale(.96); }
.envelope-stage.fly-away .open-hint { opacity: 0; }

.letter-section {
  display: none;
  padding: 64px 22px 100px;
  opacity: 0;
  transform: translateY(56px);
  transition: opacity .75s ease, transform .75s var(--ease);
}
.letter-section.visible { display: block; }
.letter-section.revealed { opacity: 1; transform: translateY(0); }
.letter-card {
  width: min(920px, 100%);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid rgba(181,138,72,.34);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: 0 30px 80px rgba(38,55,45,.18);
}
.letter-topline { height: 7px; background: linear-gradient(90deg, var(--green), var(--gold), var(--green)); }
.letter-header { padding: 42px 58px 30px; border-bottom: 1px solid var(--line); }
.letter-logo-wrap { display: flex; align-items: center; gap: 14px; }
.letter-brand-mark { width: 43px; height: 43px; font-size: 22px; }
.letter-company { color: var(--green); font-size: 13px; font-weight: 700; letter-spacing: .08em; }
.letter-website { display: inline-block; margin-top: 4px; color: var(--green-2); font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }
.letter-heading { margin-top: 38px; text-align: center; }
.letter-label { margin: 0 0 12px; color: var(--green); font-size: 22px; font-weight: 700; letter-spacing: .12em; }
.letter-heading h2 { margin: 0 auto; max-width: 700px; color: #2f3933; font-size: clamp(21px, 3vw, 30px); line-height: 1.42; font-weight: 700; }
.letter-body {
  padding: 42px 64px 12px;
  font-family: "Times New Roman", Times, serif;
  font-size: 18px;
  line-height: 1.82;
  color: #2f3732;
}
.letter-body p { margin: 0 0 22px; text-align: justify; }
.letter-body strong { font-weight: 700; }
.letter-body a { color: var(--green-2); text-decoration: underline; text-underline-offset: 3px; font-weight: 700; }
.signature-block { margin-top: 36px; padding: 26px 28px; border-left: 4px solid var(--gold); background: rgba(18,62,46,.045); }
.signature-block p { margin-bottom: 7px; text-align: left; }
.signature-name { margin-top: 18px !important; color: var(--green); font-size: 21px; font-weight: 700; }
.response-prompt { padding: 38px 30px 10px; text-align: center; }
.response-line { display: block; width: 46px; height: 2px; margin: 0 auto 18px; background: var(--gold); }
.response-prompt p { margin: 0; color: var(--gold); font-size: 12px; font-weight: 700; letter-spacing: .14em; }
.response-prompt h3 { margin: 9px 0 0; color: var(--green); font-size: clamp(22px, 3vw, 28px); font-weight: 700; }
.letter-actions { padding: 24px 56px 52px; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px; }
.primary-btn, .secondary-btn, .submit-btn {
  border: 1px solid transparent;
  border-radius: 14px;
  font-weight: 700;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.primary-btn, .secondary-btn { min-height: 74px; padding: 14px 20px; display: flex; align-items: center; justify-content: center; gap: 13px; text-align: left; }
.primary-btn { color: #fff; background: var(--green); box-shadow: 0 12px 26px rgba(18,62,46,.2); }
.secondary-btn { color: var(--green); background: #fff; border-color: rgba(18,62,46,.18); }
.primary-btn:hover, .secondary-btn:hover, .submit-btn:hover { transform: translateY(-2px); }
.btn-icon { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: rgba(255,255,255,.13); font-size: 18px; font-weight: 700; }
.secondary-btn .btn-icon { background: rgba(18,62,46,.08); }
.primary-btn strong, .secondary-btn strong { display: block; font-size: 15px; font-weight: 700; }
.primary-btn small, .secondary-btn small { display: block; margin-top: 3px; opacity: .72; font-size: 12px; font-weight: 400; }

.modal { position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal.open { display: flex; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(8,22,15,.68); backdrop-filter: blur(8px); animation: fadeIn .25s ease forwards; }
.modal-panel {
  position: relative;
  z-index: 2;
  width: min(760px, 100%);
  max-height: min(92vh, 900px);
  overflow-y: auto;
  padding: 40px;
  border: 1px solid rgba(181,138,72,.24);
  border-radius: 22px;
  background: #fffdf9;
  box-shadow: 0 28px 90px rgba(0,0,0,.26);
  animation: modalIn .38s var(--ease) forwards;
}
.modal-close { position: absolute; top: 15px; right: 16px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: #edf1ed; color: var(--green); font-size: 25px; font-weight: 700; }
.modal-header { padding-right: 44px; }
.modal-kicker { color: var(--gold); font-size: 12px; font-weight: 700; letter-spacing: .13em; }
.modal-header h2, .decline-panel h2 { margin: 10px 0; color: var(--green); font-size: clamp(25px, 4vw, 34px); line-height: 1.2; font-weight: 700; }
.modal-header p, .decline-panel > p:not(.modal-kicker) { margin: 0; color: var(--muted); line-height: 1.65; }
.form-grid { margin-top: 28px; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field-full { grid-column: 1 / -1; }
.field > span { color: #314138; font-size: 14px; font-weight: 700; }
.field input, .field select, .field textarea { width: 100%; border: 1px solid #d4dad4; border-radius: 11px; background: #fff; color: var(--ink); outline: none; }
.field input, .field select { height: 50px; padding: 0 14px; }
.field textarea { padding: 14px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--green-2); box-shadow: 0 0 0 4px rgba(31,90,67,.1); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--danger); }
.error-text { min-height: 15px; color: var(--danger); font-size: 12px; }
.form-footer { margin-top: 22px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.form-note { margin: 0; max-width: 410px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.submit-btn { min-width: 168px; min-height: 52px; padding: 0 24px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; color: #fff; background: var(--green); }
.spinner { display: none; width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.submit-btn.loading .spinner { display: inline-block; }
.success-state { padding: 26px 5px 8px; text-align: center; }
.success-icon { width: 76px; height: 76px; margin: 0 auto 20px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--green); font-size: 34px; font-weight: 700; }
.success-state h3 { margin: 10px 0 12px; color: var(--green); font-size: 28px; font-weight: 700; }
.success-state > p:not(.modal-kicker) { margin: 0 auto 24px; max-width: 540px; color: var(--muted); line-height: 1.7; }
.compact-btn { min-height: 50px; display: inline-flex; padding: 0 24px; }

.decline-panel { width: min(590px,100%); padding: 44px 42px 40px; text-align: center; }
.decline-symbol { width: 86px; height: 86px; margin: 0 auto 22px; display: grid; place-items: center; border-radius: 50%; background: rgba(181,138,72,.14); font-size: 39px; }
.decline-panel > p:not(.modal-kicker) { margin: 10px auto 0; max-width: 490px; }
.decline-signature { margin: 24px auto 25px; padding: 18px; display: flex; flex-direction: column; gap: 4px; border-radius: 13px; color: var(--green); background: rgba(18,62,46,.055); }
.decline-signature strong { font-size: 17px; font-weight: 700; }
.decline-signature span { color: var(--muted); font-size: 13px; }

@keyframes bounce { 0%,100% { transform: translateY(-2px); } 50% { transform: translateY(4px); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalIn { from { opacity: 0; transform: translateY(24px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 760px) {
  .intro { padding: 18px 14px 38px; }
  .brand-mark { width: 44px; height: 44px; font-size: 23px; }
  .brand-subtitle { display: none; }
  .hero-copy { margin-top: 42px; }
  .hero-copy p:last-child { font-size: 14px; }
  .envelope-stage { min-height: 390px; }
  .envelope { width: 94vw; }
  .seal { width: 56px; height: 56px; font-size: 22px; }
  .sheet-title { font-size: 19px; }
  .letter-section { padding: 34px 8px 70px; }
  .letter-header { padding: 28px 21px 23px; }
  .letter-heading { margin-top: 28px; }
  .letter-label { font-size: 19px; }
  .letter-body { padding: 29px 23px 8px; font-size: 17px; line-height: 1.72; }
  .letter-body p { text-align: left; }
  .signature-block { padding: 21px; }
  .letter-actions { grid-template-columns: 1fr; padding: 22px 18px 38px; }
  .modal { align-items: flex-end; padding: 0; }
  .modal-panel { max-height: 94vh; padding: 34px 20px 23px; border-radius: 22px 22px 0 0; }
  .form-grid { grid-template-columns: 1fr; }
  .field-full { grid-column: auto; }
  .form-footer { flex-direction: column; align-items: stretch; }
  .submit-btn { width: 100%; }
  .decline-panel { padding: 36px 22px 28px; }
}

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

/* ===== Premium envelope hero v4 ===== */
.brand-row-centered {
  justify-content: center;
  padding-top: 4px;
}
.xspace-wordmark {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  color: var(--green);
}
.wordmark-x {
  position: relative;
  display: grid;
  place-items: center;
  width: 64px;
  height: 58px;
  font-size: 54px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -.12em;
  background: linear-gradient(135deg, var(--green) 0 52%, #c8a260 52% 68%, var(--green) 68% 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.wordmark-copy { display: flex; flex-direction: column; line-height: 1; }
.wordmark-copy strong { font-size: 32px; letter-spacing: .11em; font-weight: 700; }
.wordmark-copy small { margin-top: 8px; color: var(--gold); font-size: 12px; letter-spacing: .34em; font-weight: 700; text-align: center; }

.hero-copy-refined { margin: 22px auto 14px; }
.hero-copy-refined h1 {
  font-family: "Times New Roman", Times, serif;
  font-size: clamp(44px, 6vw, 70px);
  font-weight: 700;
  letter-spacing: -.025em;
}
.hero-copy-refined p { margin-top: 9px !important; font-size: 17px !important; }
.hero-copy-refined p strong { color: var(--green); font-weight: 700; }

.invitation-layout {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 230px;
  align-items: center;
  gap: 36px;
}
.envelope-stage { min-height: 520px; gap: 14px; }
.envelope-premium {
  width: min(800px, 73vw);
  aspect-ratio: 1.67 / 1;
  filter: drop-shadow(0 24px 28px rgba(36, 53, 44, .20));
}
.envelope-premium .envelope-back,
.envelope-premium .envelope-front,
.envelope-premium .envelope-flap,
.envelope-premium .letter-sheet { border-radius: 18px; }
.envelope-premium .envelope-back {
  background: linear-gradient(145deg, #eed7ad 0%, #d8b676 100%);
  box-shadow: none;
}
.envelope-premium .letter-sheet {
  inset: 11% 6.5% 12%;
  justify-content: flex-start;
  overflow: hidden;
  background: linear-gradient(180deg, #fffdfa, #f8f3e9);
  border: 1px solid rgba(181,138,72,.28);
}
.paper-watermark {
  position: absolute;
  top: 18%; left: 50%; transform: translateX(-50%);
  color: rgba(181,138,72,.11);
  font-size: 96px;
  font-weight: 700;
}
.paper-corner { position: absolute; top: 18px; width: 46px; height: 46px; opacity: .35; }
.paper-corner::before, .paper-corner::after { content: ""; position: absolute; border: 1px solid var(--gold); }
.paper-corner::before { inset: 0 18px 18px 0; border-right: 0; border-bottom: 0; }
.paper-corner::after { inset: 8px 26px 26px 8px; border-right: 0; border-bottom: 0; }
.paper-corner-left { left: 18px; }
.paper-corner-right { right: 18px; transform: scaleX(-1); }
.architecture-lines {
  position: absolute;
  left: 10%; right: 10%; bottom: 4%; height: 35%;
  opacity: .13;
  background:
    linear-gradient(90deg, transparent 0 10%, #66746c 10% 10.4%, transparent 10.4% 28%, #66746c 28% 28.4%, transparent 28.4% 48%, #66746c 48% 48.4%, transparent 48.4% 70%, #66746c 70% 70.4%, transparent 70.4%),
    linear-gradient(0deg, transparent 0 18%, #66746c 18% 18.8%, transparent 18.8% 48%, #66746c 48% 48.8%, transparent 48.8% 78%, #66746c 78% 78.8%, transparent 78.8%);
  clip-path: polygon(0 66%, 17% 40%, 35% 55%, 55% 18%, 76% 43%, 100% 25%, 100% 100%, 0 100%);
}
.envelope-premium .envelope-front {
  background: linear-gradient(180deg, #e4c285 0%, #d6af68 100%);
  clip-path: polygon(0 43%, 50% 78%, 100% 43%, 100% 100%, 0 100%);
}
.envelope-premium .envelope-flap {
  background: linear-gradient(160deg, #f2dcb3 0%, #e2bf80 100%);
  clip-path: polygon(0 0, 100% 0, 50% 64%);
}
.flap-watermark {
  position: absolute;
  left: 50%; top: 31%; transform: translate(-50%, -50%);
  color: rgba(124,87,36,.12);
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 700;
  letter-spacing: .14em;
}
.seal-green {
  top: 60%;
  width: 76px;
  height: 76px;
  
  border: 4px double rgba(224,192,127,.72);
  color: rgba(255,255,255,.24);
  box-shadow: 0 10px 22px rgba(15,42,31,.38);
}
.front-invitation-label {
  position: absolute;
  z-index: 7;
  left: 50%;
  bottom: 2%;
  width: 58%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--green);
  pointer-events: none;
  transition: opacity .3s ease, transform .45s var(--ease);
}
.front-invitation-label strong {
  font-family: "Times New Roman", Times, serif;
  font-size: clamp(24px, 3vw, 38px);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: .025em;
  white-space: nowrap;
}
.front-invitation-label small {
  margin-top: 7px;
  color: #5e594f;
  font-family: "Times New Roman", Times, serif;
  font-size: clamp(14px, 1.5vw, 18px);
}
.label-rule { width: 100%; height: 1px; margin-bottom: 10px;  }
.label-ornament { margin-top: 5px; color: var(--gold); font-size: 10px; }
.open-hint { font-size: 16px; }
.envelope-stage.opened .front-invitation-label { opacity: 0; transform: translateX(-50%) translateY(14px); }
.envelope-stage.opened .letter-sheet { transform: translateY(-56%); }

.invitation-benefits { display: flex; flex-direction: column; gap: 0; }
.benefit-item {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 15px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 1px solid rgba(18,62,46,.12);
}
.benefit-item:last-child { border-bottom: 0; }
.benefit-icon {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: #d6b56f;
  background: var(--green);
  font-size: 24px;
  font-weight: 700;
}
.benefit-item div { display: flex; flex-direction: column; }
.benefit-item strong { color: var(--green); font-size: 16px; font-weight: 700; }
.benefit-item small { margin-top: 5px; color: var(--muted); font-size: 13px; line-height: 1.45; }

.intro-contact-bar {
  width: calc(100% + 48px);
  margin: 12px -24px -56px;
  min-height: 58px;
  padding: 12px 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px 24px;
  color: #f7edd8;
  background: var(--green);
  font-size: 13px;
}
.intro-contact-bar > * { display: inline-flex; align-items: center; gap: 7px; text-decoration: none; }
.intro-contact-bar a:hover { text-decoration: underline; }

@media (max-width: 980px) {
  .invitation-layout { grid-template-columns: 1fr; }
  .invitation-benefits { display: none; }
  .envelope-premium { width: min(800px, 92vw); }
}
@media (max-width: 760px) {
  .wordmark-x { width: 48px; height: 45px; font-size: 43px; }
  .wordmark-copy strong { font-size: 24px; }
  .wordmark-copy small { font-size: 9px; }
  .hero-copy-refined { margin-top: 18px; }
  .hero-copy-refined h1 { font-size: 40px; }
  .hero-copy-refined p { font-size: 14px !important; padding: 0 14px; }
  .envelope-stage { min-height: 360px; }
  .front-invitation-label { bottom: 5.2%; width: 70%; }
  .front-invitation-label strong { font-size: clamp(18px, 5vw, 25px); }
  .front-invitation-label small { font-size: 13px; margin-top: 3px; }
  .label-rule { margin-bottom: 6px; }
  .seal-green { width: 54px; height: 54px; top: 60%; }
  .intro-contact-bar { width: calc(100% + 28px); margin-left: -14px; margin-right: -14px; margin-bottom: -38px; padding: 14px 18px; gap: 9px 16px; }
  .intro-contact-bar > span { display: none; }
}


/* ===== XSPACE dark refinement v5 ===== */
:root {
  --night: #060807;
  --night-2: #0b100d;
  --night-green: #071c15;
  --cream: #f7f0e4;
  --gold-bright: #d3a954;
}
body {
  background:
    radial-gradient(circle at 50% 18%, rgba(243, 79, 30, .08), transparent 27%),
    radial-gradient(circle at 20% 45%, rgba(20, 85, 61, .22), transparent 38%),
    linear-gradient(145deg, #020403 0%, #07120e 52%, #030504 100%);
}
.intro {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  color: var(--cream);
  background:
    linear-gradient(rgba(255,255,255,.017) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.017) 1px, transparent 1px),
    radial-gradient(circle at 50% 38%, rgba(18, 62, 46, .45), transparent 48%),
    linear-gradient(145deg, #050707 0%, #071d16 48%, #020403 100%);
  background-size: 72px 72px, 72px 72px, auto, auto;
}
.intro::before,
.intro::after {
  content: "";
  position: absolute;
  pointer-events: none;
  opacity: .16;
}
.intro::before {
  left: -6%; bottom: 4%; width: 42%; height: 28%;
  border: 1px solid rgba(211,169,84,.22);
  clip-path: polygon(0 100%, 10% 56%, 23% 69%, 42% 24%, 66% 47%, 100% 14%, 100% 100%);
}
.intro::after {
  right: -10%; top: 7%; width: 44%; height: 52%;
  background: radial-gradient(circle, rgba(211,169,84,.18), transparent 62%);
  filter: blur(14px);
}
.brand-row-centered { position: relative; z-index: 2; padding-top: 12px; }
.xspace-real-logo {
  display: block;
  width: min(360px, 58vw);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 16px 34px rgba(0,0,0,.28));
}
.hero-copy-refined { position: relative; z-index: 2; }
.hero-copy-refined h1 { color: #f8f1e6; text-shadow: 0 8px 30px rgba(0,0,0,.34); }
.hero-copy-refined p { color: rgba(248,241,230,.78) !important; }
.hero-copy-refined p strong { color: var(--gold-bright); }
.invitation-layout { position: relative; z-index: 2; }
.envelope-premium { filter: drop-shadow(0 28px 38px rgba(0,0,0,.48)); }
.open-hint { color: #f7ead4; }
.benefit-item { border-bottom-color: rgba(211,169,84,.18); }
.benefit-icon { color: #1b2a22; background: linear-gradient(145deg, #efcf8a, #b88635); box-shadow: 0 8px 22px rgba(0,0,0,.24); }
.benefit-item strong { color: #e5bc67; }
.benefit-item small { color: rgba(255,255,255,.72); }
.intro-contact-bar { display: none !important; }
.intro.is-opening { pointer-events: none; }
.intro.is-opening .brand-row,
.intro.is-opening .invitation-benefits {
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity .5s ease, transform .5s ease;
}
.letter-section {
  min-height: 100vh;
  padding: 42px 20px 84px;
  background:
    radial-gradient(circle at 72% 15%, rgba(181,138,72,.10), transparent 28%),
    linear-gradient(150deg, #050706 0%, #0b0e0c 56%, #020303 100%);
}
.letter-card {
  border-color: rgba(211,169,84,.32);
  background: linear-gradient(180deg, rgba(16,19,17,.98), rgba(7,9,8,.99));
  box-shadow: 0 36px 100px rgba(0,0,0,.56);
}
.letter-header { border-bottom-color: rgba(211,169,84,.25); }
.letter-company, .letter-label, .signature-name, .response-prompt h3 { color: #e2b85f; }
.letter-website, .letter-body a { color: #d9ae54; }
.letter-heading h2, .letter-body { color: #f2ede5; }
.letter-body { font-family: "Times New Roman", Times, serif; }
.signature-block { border-left-color: #c89c48; background: rgba(211,169,84,.07); }
.response-prompt p { color: #d3a954; }
.secondary-btn { color: #f3eee6; background: rgba(255,255,255,.03); border-color: rgba(211,169,84,.34); }
.primary-btn { background: linear-gradient(135deg, #b98534, #d8ad58); color: #17110a; box-shadow: 0 14px 30px rgba(181,138,72,.23); }
.secondary-btn .btn-icon { background: rgba(211,169,84,.12); }
@media (max-width: 760px) {
  .xspace-real-logo { width: min(300px, 76vw); }
  .letter-section { padding: 12px 8px 54px; }
}

/* ===== Compact aligned intro + real sub-logo v6 ===== */
.intro-topline {
  position: relative;
  z-index: 3;
  width: min(1180px, 100%);
  margin: 0 auto 8px;
  display: grid;
  grid-template-columns: minmax(210px, 320px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
}
.brand-row-compact {
  width: auto;
  margin: 0;
  justify-content: flex-start;
}
.brand-row-compact .xspace-real-logo {
  width: min(300px, 100%);
  max-height: 150px;
  object-fit: contain;
  object-position: left center;
}
.hero-copy-inline {
  margin: 0;
  margin-bottom: 20px;
  max-width: none;
  text-align: left;
}
.hero-copy-inline h1 {
  margin: 0;
  color: #f8f1e6;
  font-family: "Times New Roman", Times, serif;
  font-size: clamp(42px, 5vw, 68px);
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -.025em;
  text-shadow: 0 8px 30px rgba(0,0,0,.34);
}
.hero-copy-inline p {
  margin: 12px 0 0;
  color: rgba(248,241,230,.78);
  font-size: clamp(15px, 1.35vw, 18px);
  line-height: 1.55;
}
.hero-copy-inline p strong { color: var(--gold-bright); font-weight: 700; }
.intro.is-opening .intro-topline {
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity .5s ease, transform .5s ease;
}
.letter-logo-wrap {
  align-items: center;
  gap: 16px;
}
.letter-sub-logo {
  width: 86px;
  height: 62px;
  flex: 0 0 auto;
  object-fit: contain;
  object-position: center;
  padding: 6px 8px;
  border: 1px solid rgba(211,169,84,.26);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
  filter: drop-shadow(0 8px 18px rgba(0,0,0,.22));
}
.letter-company {
  font-size: 14px;
  line-height: 1.35;
}
.letter-heading { margin-top: 26px; }

@media (max-width: 900px) {
  .intro-topline {
    grid-template-columns: 220px minmax(0,1fr);
    gap: 24px;
  }
  .brand-row-compact .xspace-real-logo { width: 220px; }
  .hero-copy-inline h1 { font-size: clamp(38px, 6vw, 54px); }
}
@media (max-width: 680px) {
  .intro-topline {
    grid-template-columns: 1fr;
    gap: 12px;
    text-align: center;
  }
  .brand-row-compact { justify-content: center; }
  .brand-row-compact .xspace-real-logo {
    width: min(230px, 72vw);
    max-height: 112px;
    object-position: center;
  }
  .hero-copy-inline { text-align: center; }
  .hero-copy-inline h1 { font-size: 38px; }
  .hero-copy-inline p { font-size: 14px; padding: 0 8px; }
  .letter-sub-logo { width: 72px; height: 54px; }
}

/* ===== Compact scale + favicon identity v7 ===== */
.intro {
  padding: 18px 24px 34px;
}
.intro-topline {
  grid-template-columns: 230px minmax(0, 1fr);
  gap: clamp(24px, 4vw, 54px);
  margin-bottom: 2px;
}
.brand-row-compact .xspace-real-logo {
  width: 218px;
  max-height: 112px;
}
.hero-copy-inline h1 {
  font-size: clamp(38px, 4.25vw, 58px);
}
.hero-copy-inline p {
  margin-top: 8px;
  font-size: clamp(14px, 1.12vw, 16px);
}
.invitation-layout {
  grid-template-columns: minmax(0, 1fr) 205px;
  gap: 28px;
}
.envelope-stage {
  min-height: 430px;
  gap: 8px;
}
.envelope-premium {
  width: min(690px, 67vw);
}
.front-invitation-label strong {
  font-size: clamp(22px, 2.45vw, 32px);
}
.front-invitation-label small {
  font-size: clamp(13px, 1.25vw, 16px);
}
.seal-green {
  width: 64px;
  height: 64px;
  padding: 9px;
}
.seal-green img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: .8;
}
.benefit-item {
  grid-template-columns: 46px 1fr;
  gap: 12px;
  padding: 17px 0;
}
.benefit-icon {
  width: 42px;
  height: 42px;
  font-size: 20px;
}
.benefit-item strong { font-size: 15px; }
.benefit-item small { font-size: 12px; }
.open-hint { font-size: 14px; }

.letter-header {
  padding: 30px 46px 24px;
}
.letter-logo-wrap { gap: 12px; }
.letter-sub-logo {
  width: 54px;
  height: 54px;
  padding: 7px;
  border-radius: 10px;
  object-fit: contain;
}
.letter-company { font-size: 13px; }
.letter-heading { margin-top: 20px; }
.letter-label { font-size: 20px; }
.letter-heading h2 { font-size: clamp(20px, 2.4vw, 27px); }

@media (max-width: 980px) {
  .envelope-premium { width: min(690px, 88vw); }
}
@media (max-width: 760px) {
  .intro { padding: 14px 12px 28px; }
  .intro-topline { gap: 8px; }
  .brand-row-compact .xspace-real-logo {
    width: min(190px, 58vw);
    max-height: 88px;
  }
  .hero-copy-inline h1 { font-size: 34px; }
  .hero-copy-inline p { font-size: 13px; }
  .envelope-stage { min-height: 315px; }
  .envelope-premium { width: 94vw; }
  .seal-green { width: 50px; height: 50px; padding: 7px; }
  .letter-header { padding: 24px 20px 20px; }
  .letter-sub-logo { width: 48px; height: 48px; }
}

/* ===== Mobile alignment hotfix v8 ===== */
@media (max-width: 680px) {
  body {
    min-width: 0;
  }

  .intro {
    min-height: 100svh;
    padding: 16px 14px 30px;
    overflow: hidden;
  }

  .intro-topline {
    width: 100%;
    margin: 0 auto 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
  }

  .brand-row-compact {
    width: 100%;
    justify-content: center;
  }

  .brand-row-compact .xspace-real-logo {
    display: block;
    width: min(176px, 52vw);
    height: auto;
    max-height: 78px;
    margin: 0 auto;
    object-fit: contain;
    object-position: center;
  }

  .hero-copy-inline {
    width: 100%;
    margin: 0 auto;
    padding: 0 8px;
    text-align: center;
  }

  .hero-copy-inline h1 {
    font-size: clamp(30px, 9vw, 38px);
    line-height: 1.05;
  }

  .hero-copy-inline p {
    max-width: 330px;
    margin: 8px auto 0;
    padding: 0;
    font-size: 13px;
    line-height: 1.45;
  }

  .invitation-layout {
    width: 100%;
    margin: 0 auto;
    display: block;
  }

  .invitation-benefits {
    display: none !important;
  }

  .envelope-stage {
    width: 100%;
    min-height: 0;
    padding: 8px 0 0;
    gap: 10px;
    overflow: visible;
  }

  .envelope-premium,
  .envelope {
    width: min(100%, 404px);
    max-width: calc(100vw - 28px);
    margin: 0 auto;
    aspect-ratio: 1.67 / 1;
  }

  .front-invitation-label {
    width: 78%;
    bottom: 5%;
  }

  .front-invitation-label strong {
    font-size: clamp(17px, 5vw, 22px);
    white-space: normal;
    text-align: center;
  }

  .front-invitation-label small {
    margin-top: 3px;
    font-size: 12px;
  }

  .seal-green {
    width: 48px;
    height: 48px;
    padding: 7px;
  }

  .open-hint {
    margin-top: 2px;
    font-size: 13px;
  }

  .letter-section {
    padding: 10px 8px 48px;
  }

  .letter-card {
    width: 100%;
    border-radius: 8px;
  }

  .letter-logo-wrap {
    align-items: center;
  }

  .letter-sub-logo {
    width: 44px;
    height: 44px;
    padding: 5px;
  }

  .letter-company {
    font-size: 11px;
  }

  .letter-website {
    font-size: 11px;
  }
}


/* ===== Envelope-only centered landing v9 ===== */
.intro {
  min-height: 100svh;
  padding: 24px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.invitation-layout {
  width: 100%;
  min-height: calc(100svh - 48px);
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
}

.envelope-stage {
  width: 100%;
  min-height: 0;
  padding: 0;
  gap: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.envelope-premium,
.envelope {
  width: min(720px, calc(100vw - 48px));
  max-width: 100%;
  margin: 0 auto;
}

.open-hint {
  margin: 0;
  color: #f7ead4;
}

.intro-contact-bar,
.intro-topline,
.invitation-benefits,
.brand-row,
.hero-copy {
  display: none !important;
}

.intro.is-opening {
  opacity: 1;
}

.intro.is-opening .invitation-layout {
  opacity: 1;
}

@media (max-width: 680px) {
  .intro {
    padding: 14px;
  }

  .invitation-layout {
    min-height: calc(100svh - 28px);
  }

  .envelope-stage {
    gap: 14px;
  }

  .envelope-premium,
  .envelope {
    width: min(100%, 430px);
    max-width: calc(100vw - 28px);
  }

  .open-hint {
    font-size: 13px;
  }
}


/* ===== Kien Truc Hoa Lac green palette v10 ===== */
:root {
  --green: #075b35;
  --green-2: #0d7a45;
  --gold: #169653;
  --gold-bright: #27b666;
  --line: rgba(75, 142, 105, .28);
  --night-green: #052d1d;
}

body {
  background:
    radial-gradient(circle at 50% 18%, rgba(25, 150, 83, .10), transparent 28%),
    radial-gradient(circle at 20% 45%, rgba(16, 119, 68, .24), transparent 38%),
    linear-gradient(145deg, #020705 0%, #073522 52%, #020604 100%);
}

.intro {
  background:
    linear-gradient(rgba(255,255,255,.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.015) 1px, transparent 1px),
    radial-gradient(circle at 50% 38%, rgba(15, 122, 70, .44), transparent 48%),
    linear-gradient(145deg, #03120b 0%, #075b35 50%, #021009 100%);
  background-size: 72px 72px, 72px 72px, auto, auto;
}

.intro::before {
  border-color: rgba(39, 182, 102, .22);
}

.intro::after {
  background: radial-gradient(circle, rgba(39, 182, 102, .18), transparent 62%);
}

.envelope-premium .envelope-back {
  background: linear-gradient(145deg, #8fd6ad 0%, #3fa56f 100%);
}

.envelope-premium .envelope-front {
  background: linear-gradient(180deg, #56b681 0%, #17864e 100%);
}

.envelope-premium .envelope-flap {
  background: linear-gradient(160deg, #a6dfbb 0%, #4fb47c 100%);
}

.envelope-back {
  background: linear-gradient(145deg, #8fd6ad, #3fa56f);
}

.envelope-front {
  background: linear-gradient(180deg, #56b681 0%, #17864e 100%);
}

.envelope-flap {
  background: linear-gradient(180deg, #a6dfbb 0%, #4fb47c 100%);
}

.letter-sheet,
.envelope-premium .letter-sheet {
  background: linear-gradient(180deg, #fbfffc, #edf8f1);
  border-color: rgba(7, 91, 53, .24);
}

.paper-watermark,
.flap-watermark {
  color: rgba(7, 91, 53, .12);
}

.paper-corner::before,
.paper-corner::after {
  border-color: #169653;
}

.seal,
.seal-green {
  background: radial-gradient(circle at 32% 26%, #1ca85d, #064f2e 74%);
  border-color: rgba(222, 255, 234, .72);
  box-shadow: 0 10px 22px rgba(3, 50, 29, .42);
}

.front-invitation-label {
  color: #064f2e;
}

.front-invitation-label small {
  color: #194d35;
}

.label-rule {
  background: linear-gradient(90deg, transparent, rgba(7,91,53,.52), transparent);
}

.label-ornament,
.open-hint,
.letter-company,
.letter-label,
.signature-name,
.response-prompt h3,
.modal-kicker {
  color: #20a95f;
}

.letter-section {
  background:
    radial-gradient(circle at 72% 15%, rgba(25,150,83,.12), transparent 28%),
    linear-gradient(150deg, #03100a 0%, #07150f 56%, #020504 100%);
}

.letter-card {
  border-color: rgba(31, 169, 95, .34);
  background: linear-gradient(180deg, rgba(9,29,19,.98), rgba(4,15,10,.99));
}

.letter-header {
  border-bottom-color: rgba(31,169,95,.24);
}

.letter-website,
.letter-body a,
.response-prompt p {
  color: #29b76a;
}

.signature-block {
  border-left-color: #169653;
  background: rgba(25,150,83,.08);
}

.primary-btn,
.submit-btn {
  background: linear-gradient(135deg, #0d7a45, #1ca85d);
  color: #ffffff;
  box-shadow: 0 14px 30px rgba(7,91,53,.28);
}

.secondary-btn {
  border-color: rgba(39,182,102,.34);
}

.secondary-btn .btn-icon,
.decline-symbol {
  background: rgba(25,150,83,.12);
}

.modal-panel {
  border-color: rgba(25,150,83,.22);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: #0d7a45;
  box-shadow: 0 0 0 4px rgba(13,122,69,.10);
}
.flap-watermark {
  position: absolute;
  left: 50%;
  top: 31%;
  transform: translate(-50%, -50%);
  width: 210px;
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.18;
}

.flap-watermark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.flap-watermark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(27%) sepia(19%) saturate(1225%)
    hue-rotate(103deg) brightness(85%) contrast(94%);
  opacity: 0.55;
}
.front-invitation-label {
  color: #ffffff;
}

.front-invitation-label strong {
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.front-invitation-label small {
  color: rgba(255, 255, 255, 0.88);
}

.label-ornament {
  color: #b8f0c9;
}

.open-hint {
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

/* ===== FIX LOGO ONLY - keep current green palette/layout ===== */

/* Giữ logo trên nắp phong bì nằm đúng trong khung */
.flap-watermark {
  position: absolute;
  left: 50%;
  top: 31%;
  width: 210px;
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
  opacity: 1;
  overflow: hidden;
  pointer-events: none;
}

.flap-watermark > img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: 210px !important;
  max-height: 90px !important;
  margin: 0 !important;
  object-fit: contain;
  object-position: center;
  filter: brightness(0) invert(1);
  opacity: .82;
}

/* Con dấu chỉ dùng favicon, không cho ảnh tràn khỏi hình tròn */
.seal-green {
  overflow: hidden;
}

.seal-green > img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain;
  object-position: center;
  filter: none !important;
  opacity: 1;
}
/* ===== ORANGE XSPACE LOGO + DARKER GREEN ENVELOPE ===== */

/* Giữ nguyên màu cam thật của logo, không ép sang trắng */
.flap-watermark {
  position: absolute;
  left: 50%;
  top: 31%;
  width: 210px;
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
  opacity: 1;
  overflow: hidden;
  pointer-events: none;
}

.flap-watermark > img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: 210px !important;
  max-height: 90px !important;
  margin: 0 !important;
  object-fit: contain;
  object-position: center;
  filter: none !important;
  opacity: 1;
  mix-blend-mode: normal;
  drop-shadow: 0 3px 10px rgba(0, 0, 0, .22);
}

/* Phong bì xanh đậm hơn để logo cam nổi rõ */
.envelope-premium .envelope-back,
.envelope-back {
  background: linear-gradient(145deg, #0f7a48 0%, #075b35 100%);
}

.envelope-premium .envelope-front,
.envelope-front {
  background: linear-gradient(180deg, #168a50 0%, #075b35 100%);
}

.envelope-premium .envelope-flap,
.envelope-flap {
  background: linear-gradient(160deg, #43ad73 0%, #168a50 54%, #0d6d40 100%);
}

/* Giấy phía trong giữ sáng để tạo tương phản */
.letter-sheet,
.envelope-premium .letter-sheet {
  background: linear-gradient(180deg, #fbfffc 0%, #edf8f1 100%);
}

/* Con dấu đậm hơn */
.seal,
.seal-green {
  background: radial-gradient(circle at 32% 26%, #0f7a48, #064f2e 74%);
  border: 3px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 10px 24px rgba(2, 43, 24, 0.48);
}

/* Favicon trong con dấu chuyển sang màu cam XSPACE */
.seal-green > img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain;
  object-position: center;
  filter: brightness(0) saturate(100%)
    invert(35%) sepia(99%) saturate(2860%)
    hue-rotate(352deg) brightness(103%) contrast(101%) !important;
  opacity: 1 !important;
}

/* Chữ mặt trước giữ trắng, dễ đọc trên nền xanh đậm */
.front-invitation-label,
.front-invitation-label strong {
  color: #ffffff;
}

.front-invitation-label strong {
  text-shadow: 0 2px 8px rgba(0, 0, 0, .38);
}

.front-invitation-label small {
  color: rgba(255, 255, 255, .9);
  text-shadow: 0 1px 5px rgba(0, 0, 0, .32);
}

.label-rule {
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, .48),
    transparent
  );
}

.open-hint {
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .4);
}

/* Mobile */
@media (max-width: 680px) {
  .flap-watermark {
    top: 30%;
    width: 150px;
    height: 64px;
  }

  .flap-watermark > img {
    max-width: 150px !important;
    max-height: 64px !important;
  }
}

/* ===== FINAL SEAL ORANGE OVERRIDE ===== */
.envelope .seal-green > img,
.envelope-premium .seal-green > img,
.seal.seal-green > img {
  filter: brightness(0) saturate(100%)
    invert(35%) sepia(99%) saturate(2860%)
    hue-rotate(352deg) brightness(103%) contrast(101%) !important;
  opacity: 1 !important;
}
