:root {
  --bg: #061329;
  --bg-deep: #091a3a;
  --bg-soft: #0e2a63;
  --royal: #4169e1;
  --royal-strong: #244ecf;
  --sky: #6ea8ff;
  --ice: #dcebff;
  --gold: #f3d78a;
  --text: #f8fbff;
  --text-soft: #c7d7f3;
  --line: rgba(255,255,255,.14);
  --surface: rgba(255,255,255,.08);
  --surface-strong: rgba(255,255,255,.12);
  --shadow: 0 30px 100px rgba(0,0,0,.36);
  --radius-lg: 30px;
  --radius-md: 22px;
  --radius-sm: 16px;
  --container: min(1180px, calc(100% - 34px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  font-family: 'Montserrat', sans-serif;
  background:
    radial-gradient(circle at 15% 10%, rgba(65,105,225,.26), transparent 34%),
    radial-gradient(circle at 82% 12%, rgba(110,168,255,.18), transparent 26%),
    linear-gradient(180deg, #071224 0%, #081a39 52%, #051226 100%);
  overflow-x: hidden;
}
body.modal-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
.container { width: var(--container); margin-inline: auto; }
.section { position: relative; padding: 110px 0; }

.bg-lights { position: fixed; inset: 0; pointer-events: none; z-index: -2; overflow: hidden; }
.light {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: .35;
  animation: drift 16s ease-in-out infinite alternate;
}
.light-1 { width: 360px; height: 360px; background: rgba(65,105,225,.45); left: -80px; top: 8%; }
.light-2 { width: 460px; height: 460px; background: rgba(110,168,255,.26); right: -140px; top: 20%; animation-duration: 22s; }
.light-3 { width: 340px; height: 340px; background: rgba(243,215,138,.16); left: 30%; bottom: -120px; animation-duration: 19s; }
@keyframes drift { to { transform: translate3d(70px, 55px, 0) scale(1.1); } }

.confetti-layer,
.sparkle-layer { position: fixed; inset: 0; pointer-events: none; overflow: hidden; }
.sparkle,
.confetti {
  position: absolute;
  will-change: transform, opacity;
}
.sparkle {
  color: rgba(255,255,255,.9);
  text-shadow: 0 0 14px rgba(255,255,255,.8);
  animation: sparkleFloat linear infinite;
}
.confetti {
  width: 8px;
  height: 14px;
  border-radius: 4px;
  opacity: .75;
  animation: confettiFall linear infinite;
}
@keyframes sparkleFloat {
  from { transform: translateY(110vh) rotate(0deg) scale(.7); opacity: 0; }
  15% { opacity: .9; }
  to { transform: translateY(-20vh) rotate(90deg) scale(1.2); opacity: 0; }
}
@keyframes confettiFall {
  from { transform: translateY(-20vh) rotate(0deg); opacity: 0; }
  10% { opacity: .8; }
  to { transform: translateY(120vh) rotate(360deg); opacity: 0; }
}

.hero {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(6,19,41,.34), rgba(6,19,41,.78)),
    radial-gradient(circle at 70% 30%, rgba(255,255,255,.05), transparent 24%);
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.5), transparent 92%);
}

.navbar {
  position: relative;
  z-index: 8;
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-badge {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-family: 'Playfair Display', serif;
  font-weight: 800;
  color: #102140;
  background: linear-gradient(135deg, #ffffff, #d9e6ff 45%, var(--gold));
  box-shadow: 0 0 26px rgba(243,215,138,.28);
}
.brand-text { font-weight: 700; letter-spacing: .06em; }
.nav-links { display: flex; align-items: center; gap: 28px; font-size: .92rem; font-weight: 600; }
.nav-links a { color: var(--text-soft); transition: .25s ease; }
.nav-links a:hover { color: #fff; }
.nav-button {
  color: #fff !important;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(14px);
}
.menu-toggle { display: none; background: none; border: 0; padding: 6px; }
.menu-toggle span { display: block; width: 26px; height: 2px; background: #fff; margin: 5px 0; }

.hero-content {
  position: relative;
  z-index: 2;
  min-height: calc(100svh - 92px);
  display: grid;
  grid-template-columns: 1.07fr .93fr;
  align-items: center;
  gap: 64px;
  padding-bottom: 88px;
}
.eyebrow,
.section-mini {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: .22em;
  font-size: .72rem;
  color: var(--gold);
  font-weight: 800;
}
.eyebrow::before,
.section-mini::before {
  content: '';
  width: 32px;
  height: 1px;
  background: currentColor;
}
.pretitle { margin: 24px 0 10px; font-size: 1.05rem; color: var(--text-soft); }
.hero h1 { margin: 0; line-height: .95; }
.script-title {
  display: block;
  font-family: 'Great Vibes', cursive;
  font-size: clamp(2.2rem, 4.4vw, 4rem);
  color: #eef4ff;
  margin-bottom: 10px;
}
.hero h1 strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-weight: 800;
  font-size: clamp(3.6rem, 8vw, 7.2rem);
  letter-spacing: -.05em;
  background: linear-gradient(135deg, #ffffff 0%, #d9e8ff 38%, #89b4ff 72%, var(--gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 10px 28px rgba(65,105,225,.22));
}
.hero-description {
  max-width: 680px;
  color: var(--text-soft);
  line-height: 1.9;
  margin: 28px 0 34px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 800;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.button:hover { transform: translateY(-3px); }
.button-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--royal), var(--sky));
  box-shadow: 0 18px 40px rgba(65,105,225,.32);
}
.button-secondary {
  color: #fff;
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.16);
  backdrop-filter: blur(14px);
}
.button-full { width: 100%; }

.hero-pills {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 999px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  color: #eef4ff;
  font-size: .9rem;
}
.hero-pill span { font-size: 1rem; }

.hero-visual { display: grid; place-items: center; }
.royal-frame {
  position: relative;
  width: min(460px, 86vw);
  aspect-ratio: 1 / 1.04;
  border-radius: 42px;
  padding: 18px;
  background: linear-gradient(160deg, rgba(255,255,255,.12), rgba(255,255,255,.03));
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  overflow: hidden;
}
.frame-glow {
  position: absolute;
  inset: 10%;
  border-radius: 30px;
  background: radial-gradient(circle at 50% 35%, rgba(255,255,255,.16), transparent 55%);
  filter: blur(20px);
}
.frame-inner {
  position: relative;
  z-index: 2;
  height: 100%;
  border-radius: 30px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 32px;
  background:
    linear-gradient(180deg, rgba(65,105,225,.16), rgba(255,255,255,.04)),
    radial-gradient(circle at 50% 20%, rgba(255,255,255,.12), transparent 35%);
  border: 1px solid rgba(255,255,255,.11);
}
.crown {
  font-size: 2.1rem;
  color: var(--gold);
  filter: drop-shadow(0 0 16px rgba(243,215,138,.45));
}
.age-number {
  font-family: 'Playfair Display', serif;
  font-size: clamp(6rem, 14vw, 10rem);
  font-weight: 800;
  line-height: .85;
  margin-top: 8px;
  background: linear-gradient(180deg, #fff, #b8d3ff 62%, var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.age-label {
  text-transform: uppercase;
  letter-spacing: .38em;
  color: var(--gold);
  font-weight: 800;
  margin-top: -4px;
}
.hero-monogram {
  margin-top: 16px;
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.16);
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  font-weight: 700;
}
.frame-inner p {
  max-width: 260px;
  margin: 18px 0 0;
  color: var(--text-soft);
  line-height: 1.7;
}
.floating-star {
  position: absolute;
  color: #fff;
  text-shadow: 0 0 22px rgba(255,255,255,.78);
  animation: pulseStar 2.4s ease-in-out infinite alternate;
}
.s1 { top: 12%; left: 8%; font-size: 1.4rem; }
.s2 { top: 18%; right: 10%; font-size: 1.2rem; animation-delay: .4s; }
.s3 { bottom: 18%; left: 12%; font-size: 1.3rem; animation-delay: .8s; }
.s4 { bottom: 14%; right: 15%; font-size: 1rem; animation-delay: .3s; }
@keyframes pulseStar { to { transform: scale(1.5) rotate(24deg); opacity: .45; } }

.scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  width: 30px;
  height: 48px;
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,.24);
  z-index: 5;
}
.scroll-indicator span {
  position: absolute;
  left: 50%;
  top: 10px;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  border-radius: 4px;
  background: #fff;
  animation: scrollDown 1.7s ease-in-out infinite;
}
@keyframes scrollDown { to { transform: translateY(16px); opacity: 0; } }

.countdown-section { position: relative; z-index: 3; margin-top: -36px; }
.countdown-card {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 26px;
  align-items: center;
  padding: 34px 38px;
  border-radius: var(--radius-lg);
  background: rgba(10,28,65,.86);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}
.countdown-copy h2,
.section-heading h2,
.invitation-copy h2,
.rsvp-copy h2 {
  margin: 12px 0 14px;
  line-height: 1.12;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3.8rem);
}
.countdown-copy p,
.section-heading p,
.invitation-copy p,
.rsvp-copy p { color: var(--text-soft); line-height: 1.85; }
.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.count-item {
  text-align: center;
  padding: 18px 12px;
  border-radius: 22px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
}
.count-item strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3.4rem);
}
.count-item span {
  display: block;
  margin-top: 4px;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .68rem;
}

.section-heading { max-width: 760px; margin: 0 auto 54px; }
.centered { text-align: center; }
.centered .section-mini { justify-content: center; }

.invitation-grid,
.rsvp-grid {
  display: grid;
  grid-template-columns: .92fr 1.08fr;
  align-items: center;
  gap: 72px;
}
.portrait-shell {
  position: relative;
  width: min(440px, 84vw);
  aspect-ratio: .82;
  margin-inline: auto;
  padding: 12px;
  border-radius: 220px 220px 36px 36px;
  background: linear-gradient(160deg, rgba(243,215,138,.95), rgba(110,168,255,.4), rgba(65,105,225,.62));
  box-shadow: var(--shadow);
}
.portrait-placeholder {
  height: 100%;
  border-radius: 210px 210px 28px 28px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 34px;
  background:
    radial-gradient(circle at 50% 20%, rgba(255,255,255,.16), transparent 35%),
    linear-gradient(180deg, rgba(255,255,255,.09), rgba(255,255,255,.03));
  border: 1px solid rgba(255,255,255,.16);
}
.portrait-placeholder span {
  text-transform: uppercase;
  letter-spacing: .45em;
  font-size: .78rem;
  color: var(--gold);
  font-weight: 800;
}
.portrait-placeholder strong {
  font-family: 'Playfair Display', serif;
  font-size: clamp(4rem, 9vw, 6rem);
  line-height: .9;
  background: linear-gradient(135deg, #fff, #cfe0ff, var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.portrait-placeholder small { max-width: 220px; color: var(--text-soft); line-height: 1.6; }

.portrait-photo-frame {
  position: relative;
  padding: 0 !important;
  display: block !important;
  place-items: unset !important;
  align-items: stretch !important;
  justify-items: stretch !important;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 18%, rgba(255,255,255,.10), transparent 30%),
    linear-gradient(160deg, rgba(65,105,225,.10), rgba(255,255,255,.02));
}
.portrait-photo {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  border-radius: 210px 210px 28px 28px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}
.invitation-copy blockquote {
  margin: 28px 0 16px;
  padding: 22px 24px;
  border-left: 3px solid var(--gold);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: rgba(255,255,255,.05);
  color: #eef5ff;
  font-style: italic;
  line-height: 1.8;
}
.signature {
  color: var(--gold);
  font-family: 'Great Vibes', cursive;
  font-size: clamp(2rem, 3vw, 2.8rem);
}

.details-section { background: linear-gradient(180deg, transparent, rgba(65,105,225,.08), transparent); }
.details-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.detail-card,
.gift-card {
  padding: 30px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.11);
  box-shadow: 0 24px 60px rgba(0,0,0,.18);
  backdrop-filter: blur(18px);
}
.detail-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(65,105,225,.45), rgba(110,168,255,.25));
  font-size: 1.4rem;
}
.detail-card span,
.gift-category {
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: .16em;
  font-size: .7rem;
  font-weight: 800;
}
.detail-card h3,
.gift-card h3,
.location-card h3,
.pix-box h3,
.modal-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  margin: 10px 0 12px;
}
.detail-card p,
.gift-card p,
.location-card p,
.pix-box p,
.modal-card p { color: var(--text-soft); line-height: 1.75; }
.location-card,
.pix-box {
  margin-top: 26px;
  padding: 28px 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.11);
  box-shadow: var(--shadow);
}

.gift-filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}
.filter-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  color: var(--text-soft);
  font-weight: 700;
}
.filter-button.active {
  color: #fff;
  background: linear-gradient(135deg, var(--royal), var(--sky));
}
.gifts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.gift-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(255,255,255,.12), rgba(255,255,255,.04));
  font-size: 1.3rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}
.gift-price {
  margin: 18px 0;
  color: #eef5ff;
  font-weight: 700;
}
.gift-card .button { width: 100%; }

.rsvp-points { display: grid; gap: 14px; margin-top: 24px; }
.rsvp-points div {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #eef4ff;
}
.rsvp-points span {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--royal), var(--sky));
  font-weight: 900;
}
.rsvp-form {
  padding: 34px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}
.form-header span {
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: .16em;
  font-weight: 800;
  font-size: .72rem;
}
.form-header h3 {
  margin: 12px 0 20px;
  font-size: 2rem;
  font-family: 'Playfair Display', serif;
}
.rsvp-form label,
.modal-card label {
  display: block;
  margin-bottom: 16px;
  font-weight: 600;
}
.rsvp-form input,
.rsvp-form select,
.rsvp-form textarea,
.modal-card input {
  width: 100%;
  margin-top: 8px;
  padding: 15px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(5,16,37,.48);
  color: #fff;
  outline: none;
}
.rsvp-form input::placeholder,
.rsvp-form textarea::placeholder,
.modal-card input::placeholder { color: #aabddb; }
.rsvp-form input:focus,
.rsvp-form select:focus,
.rsvp-form textarea:focus,
.modal-card input:focus { border-color: rgba(110,168,255,.7); box-shadow: 0 0 0 4px rgba(65,105,225,.15); }
.form-group > span { display: block; margin-bottom: 10px; font-weight: 600; }
.choice-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.choice-card {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 16px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
}
.choice-card input { width: auto; margin: 0; }
.form-feedback { min-height: 24px; margin: 14px 0 0; color: var(--gold); }

.footer {
  padding: 34px 0 44px;
  border-top: 1px solid rgba(255,255,255,.08);
}
.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.footer-content > div { display: flex; align-items: center; gap: 14px; }
.footer-badge {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #ffffff, #dbe7ff, var(--gold));
  color: #122247;
  font-family: 'Playfair Display', serif;
  font-weight: 800;
}
.footer p,
.footer a { color: var(--text-soft); }

.floating-rsvp {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--royal), var(--sky));
  color: #fff;
  box-shadow: 0 18px 34px rgba(65,105,225,.35);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  place-items: center;
  padding: 20px;
}
.modal.open { display: grid; }
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4,10,24,.84);
  backdrop-filter: blur(10px);
}
.modal-card {
  position: relative;
  width: min(560px, 100%);
  padding: 34px;
  border-radius: var(--radius-lg);
  background: #0b1c3d;
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: var(--shadow);
  animation: modalIn .25s ease;
}
@keyframes modalIn { from { opacity: 0; transform: translateY(18px) scale(.97); } }
.modal-close {
  position: absolute;
  right: 16px;
  top: 14px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 0;
  background: rgba(255,255,255,.08);
  color: #fff;
  font-size: 1.5rem;
}
.modal-actions { display: flex; gap: 10px; margin-top: 18px; }
.modal-actions .button { flex: 1; }
.toast {
  position: fixed;
  z-index: 150;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  padding: 14px 18px;
  border-radius: 999px;
  background: #fff;
  color: #102040;
  font-weight: 800;
  box-shadow: 0 18px 40px rgba(0,0,0,.24);
  opacity: 0;
  pointer-events: none;
  transition: .3s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s ease, transform .8s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal-delay-small { transition-delay: .1s; }
.reveal-delay { transition-delay: .18s; }

@media (max-width: 980px) {
  .nav-links {
    position: fixed;
    inset: 76px 18px auto;
    display: grid;
    gap: 0;
    padding: 16px;
    border-radius: 20px;
    background: rgba(8,20,44,.97);
    border: 1px solid rgba(255,255,255,.12);
    transform: translateY(-20px);
    opacity: 0;
    pointer-events: none;
    transition: .25s ease;
    box-shadow: var(--shadow);
  }
  .nav-links.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav-links a { padding: 14px; }
  .menu-toggle { display: block; }
  .hero-content,
  .invitation-grid,
  .rsvp-grid,
  .countdown-card {
    grid-template-columns: 1fr;
  }
  .hero-content { text-align: center; padding-top: 48px; gap: 48px; }
  .hero-description { margin-inline: auto; }
  .hero-actions,
  .hero-pills { justify-content: center; }
  .countdown-card { text-align: center; }
  .details-grid,
  .gifts-grid { grid-template-columns: repeat(2, 1fr); }
  .invitation-copy,
  .rsvp-copy { text-align: center; }
  .section-mini { justify-content: center; }
}

@media (max-width: 700px) {
  :root { --container: min(100% - 24px, 1180px); }
  .section { padding: 78px 0; }
  .navbar { min-height: 76px; }
  .brand-text { display: none; }
  .hero-content { min-height: calc(100svh - 76px); padding-bottom: 60px; }
  .pretitle { font-size: .95rem; }
  .hero-description { font-size: .95rem; line-height: 1.8; }
  .hero-actions { display: grid; }
  .hero-actions .button,
  .location-card .button,
  .pix-box .button { width: 100%; }
  .hero-pills { display: grid; }
  .royal-frame { width: min(360px, 88vw); }
  .countdown-section { margin-top: -16px; }
  .countdown-card { padding: 26px 18px; }
  .countdown-grid { gap: 10px; }
  .count-item { padding: 14px 8px; }
  .count-item span { font-size: .6rem; }
  .details-grid,
  .gifts-grid,
  .choice-grid { grid-template-columns: 1fr; }
  .location-card,
  .pix-box,
  .footer-content,
  .footer-content > div,
  .modal-actions { flex-direction: column; align-items: flex-start; }
  .footer-content { text-align: center; }
  .footer-content,
  .footer-content > div { align-items: center; }
  .rsvp-form,
  .modal-card { padding: 26px 18px; }
  .floating-rsvp strong { display: none; }
  .floating-rsvp { width: 54px; padding: 0; justify-content: center; }
}

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

/* ===== Ajustes V4: popup RSVP, música e card mobile ===== */
.nav-rsvp-button {
  font: inherit;
  cursor: pointer;
}

.music-control {
  position: fixed;
  left: 18px;
  bottom: 18px;
  z-index: 55;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 17px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 999px;
  color: #fff;
  background: rgba(8,28,66,.86);
  box-shadow: 0 18px 40px rgba(0,0,0,.26);
  backdrop-filter: blur(16px);
}
.music-control.playing {
  background: linear-gradient(135deg, var(--royal), var(--sky));
  box-shadow: 0 18px 42px rgba(65,105,225,.4);
}
.music-note {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  font-size: 1.05rem;
}
.music-control.playing .music-note { animation: musicPulse 1.1s ease-in-out infinite; }
@keyframes musicPulse { 50% { transform: scale(1.14) rotate(6deg); } }

.royal-frame {
  aspect-ratio: auto;
  min-height: 500px;
  overflow: visible;
}
.frame-inner {
  min-height: 464px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.crown { line-height: 1; margin-bottom: 2px; }
.age-number {
  font-size: clamp(6.5rem, 13vw, 9rem);
  line-height: .92;
  margin: 0;
}
.age-label {
  margin: -2px 0 8px;
  line-height: 1.2;
}
.hero-monogram { margin-top: 4px; flex: 0 0 auto; }
.frame-inner p { margin-top: 12px; margin-bottom: 0; }

.gift-list-note {
  max-width: 760px;
  margin: 0 auto 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 18px;
  text-align: center;
  border-radius: 18px;
  color: var(--text-soft);
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
}
.gift-list-note span { color: var(--gold); font-size: 1.2rem; }
.gift-list-note p { margin: 0; line-height: 1.65; }
.gift-list-note strong { color: #fff; }

.rsvp-cta-section { padding-top: 40px; }
.rsvp-cta-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  padding: 38px 42px;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(135deg, rgba(65,105,225,.26), rgba(110,168,255,.08)),
    rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: var(--shadow);
}
.rsvp-cta-card h2 {
  max-width: 760px;
  margin: 12px 0 12px;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.12;
}
.rsvp-cta-card p { max-width: 760px; margin: 0; color: var(--text-soft); line-height: 1.8; }
.rsvp-cta-card .button { flex: 0 0 auto; }

.rsvp-modal-card {
  width: min(720px, 100%);
  max-height: min(92vh, 900px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(110,168,255,.6) rgba(255,255,255,.05);
}
.rsvp-form-modal {
  padding: 0;
  margin-top: 22px;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}
.modal-intro { margin: 0; }
.rsvp-success {
  min-height: 430px;
  padding: 28px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.rsvp-success[hidden] { display: none; }
.rsvp-success .section-mini { justify-content: center; }
.rsvp-success h3 { font-size: clamp(2rem, 5vw, 3rem); }
.rsvp-success p { max-width: 460px; }
.success-ring {
  width: 110px;
  height: 110px;
  display: grid;
  place-items: center;
  margin-bottom: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--royal), var(--sky));
  box-shadow: 0 0 0 12px rgba(65,105,225,.13), 0 22px 55px rgba(65,105,225,.36);
  animation: successPop .65s cubic-bezier(.2,.9,.3,1.35);
}
.success-ring span {
  font-size: 3.2rem;
  font-weight: 900;
  color: #fff;
  animation: checkDraw .5s .2s both;
}
@keyframes successPop {
  from { transform: scale(.35) rotate(-20deg); opacity: 0; }
  to { transform: scale(1) rotate(0); opacity: 1; }
}
@keyframes checkDraw {
  from { transform: scale(.2); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.confirmation-burst {
  position: fixed;
  z-index: 160;
  width: 10px;
  height: 18px;
  border-radius: 4px;
  pointer-events: none;
  animation: burstConfetti 1.5s cubic-bezier(.15,.75,.2,1) forwards;
}
@keyframes burstConfetti {
  from { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  to { transform: translate(var(--tx), var(--ty)) rotate(var(--rot)); opacity: 0; }
}

@media (max-width: 980px) {
  .royal-frame { min-height: 470px; }
  .frame-inner { min-height: 434px; }
  .rsvp-cta-card { flex-direction: column; text-align: center; }
}

@media (max-width: 700px) {
  .royal-frame {
    width: min(350px, 90vw);
    min-height: 430px;
    padding: 14px;
    border-radius: 34px;
  }
  .frame-inner {
    min-height: 400px;
    border-radius: 25px;
    padding: 24px 20px;
  }
  .age-number { font-size: clamp(6rem, 31vw, 7.6rem); }
  .age-label { letter-spacing: .3em; margin-bottom: 6px; }
  .hero-monogram { width: 62px; height: 62px; }
  .frame-inner p { max-width: 240px; font-size: .94rem; line-height: 1.6; }
  .rsvp-cta-card { padding: 30px 20px; }
  .rsvp-cta-card .button { width: 100%; }
  .rsvp-modal-card { padding: 28px 18px 22px; max-height: 94vh; }
  .music-control strong { display: none; }
  .music-control { width: 54px; padding: 0; justify-content: center; }
  .music-note { background: transparent; }
  .gift-list-note { align-items: flex-start; text-align: left; }
}

/* ===== V7 — acabamento profissional, seletores customizados e correções mobile ===== */
.music-control { display: none !important; }

/* Card principal: número inteiro, sem recorte em nenhuma resolução */
.age-wrap {
  width: min(285px, 82%);
  display: grid;
  place-items: center;
  margin: 0 auto 4px;
}
.age-svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 18px 28px rgba(26, 61, 138, .22));
}
.age-svg text {
  font-family: 'Playfair Display', serif;
  font-size: 174px;
  font-weight: 800;
  letter-spacing: -11px;
}
.age-wrap .age-label {
  position: relative;
  z-index: 2;
  margin: -20px 0 7px;
  padding-left: .34em;
  line-height: 1.2;
  letter-spacing: .34em;
  color: var(--gold);
  text-shadow: 0 3px 16px rgba(0,0,0,.28);
}
.hero-name-seal {
  width: min(250px, 86%);
  min-height: 76px;
  margin-top: 7px;
  padding: 12px 18px;
  display: grid;
  place-items: center;
  gap: 1px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.18);
  background:
    linear-gradient(135deg, rgba(255,255,255,.1), rgba(255,255,255,.035)),
    rgba(31,67,143,.14);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.11), 0 14px 30px rgba(1,8,26,.2);
  backdrop-filter: blur(12px);
}
.hero-name-seal span,
.hero-name-seal strong {
  display: block;
  line-height: 1.1;
  text-align: center;
}
.hero-name-seal span {
  color: var(--gold);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .27em;
  padding-left: .27em;
}
.hero-name-seal strong {
  color: #fff;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1rem, 2.2vw, 1.28rem);
  letter-spacing: .06em;
}
.royal-ribbon {
  position: absolute;
  right: 22px;
  bottom: 18px;
  z-index: 4;
  padding: 8px 12px;
  border-radius: 999px;
  color: #10234e;
  background: linear-gradient(135deg, #fff7d1, var(--gold));
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .12em;
  box-shadow: 0 10px 24px rgba(0,0,0,.2);
}

/* Emblema da aniversariante sem iniciais */
.portrait-placeholder { gap: 14px; }
.portrait-kicker {
  color: var(--gold) !important;
  font-family: 'Great Vibes', cursive;
  font-size: clamp(1.8rem, 4vw, 2.7rem) !important;
  font-weight: 400 !important;
  letter-spacing: .02em !important;
  text-transform: none !important;
}
.portrait-name {
  display: grid;
  gap: 0;
  font-family: 'Playfair Display', serif !important;
  font-size: clamp(2.3rem, 7vw, 4.7rem) !important;
  line-height: .95 !important;
  letter-spacing: -.035em;
  text-align: center;
}
.portrait-name span {
  color: transparent;
  font-size: 1em !important;
  letter-spacing: inherit !important;
  text-transform: uppercase !important;
  background: linear-gradient(135deg, #fff, #cfe0ff 62%, var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
}
.portrait-placeholder small {
  padding: 9px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
}

/* Presentes em cartões retangulares, menores e elegantes */
.gifts-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.gift-card {
  min-height: 112px;
  padding: 16px 17px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  align-items: center;
  gap: 15px;
  border-radius: 19px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.075), rgba(255,255,255,.025)),
    rgba(11,35,80,.5);
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}
.gift-card:hover {
  transform: translateY(-3px);
  border-color: rgba(110,168,255,.34);
  background:
    linear-gradient(135deg, rgba(65,105,225,.16), rgba(255,255,255,.035)),
    rgba(11,35,80,.56);
}
.gift-icon {
  width: 52px;
  height: 52px;
  margin: 0;
  border-radius: 16px;
  font-size: 1.22rem;
  background: linear-gradient(135deg, rgba(65,105,225,.38), rgba(110,168,255,.15));
}
.gift-card-copy { min-width: 0; }
.gift-card h3 {
  margin: 0 0 5px;
  font-size: 1.08rem;
  line-height: 1.25;
}
.gift-card p {
  margin: 0;
  font-size: .84rem;
  line-height: 1.48;
}
.gift-select-button {
  min-width: 96px;
  min-height: 42px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  color: #fff;
  background: rgba(255,255,255,.055);
  font-weight: 800;
  transition: .25s ease;
}
.gift-select-button:hover {
  border-color: transparent;
  background: linear-gradient(135deg, var(--royal), var(--sky));
  box-shadow: 0 12px 25px rgba(65,105,225,.25);
}
.gift-select-button i { font-style: normal; transition: transform .25s ease; }
.gift-select-button:hover i { transform: translateX(3px); }

.pix-box {
  background:
    radial-gradient(circle at 90% 20%, rgba(243,215,138,.13), transparent 28%),
    linear-gradient(135deg, rgba(65,105,225,.16), rgba(255,255,255,.04));
}
.pix-key {
  width: fit-content;
  max-width: 100%;
  margin-top: 13px;
  padding: 11px 15px;
  border-radius: 14px;
  overflow-wrap: anywhere;
  color: #fff;
  background: rgba(5,18,44,.56);
  border: 1px dashed rgba(243,215,138,.45);
  font-weight: 700;
  letter-spacing: .02em;
}

/* Popup compacto, centralizado e compatível com tela pequena */
.modal {
  padding: clamp(10px, 2vw, 22px);
  background: transparent;
}
.rsvp-modal-card {
  width: min(650px, calc(100vw - 24px));
  max-height: min(90dvh, 760px);
  padding: 0;
  overflow: hidden;
  border-radius: 26px;
  background:
    radial-gradient(circle at 92% 2%, rgba(110,168,255,.17), transparent 27%),
    linear-gradient(180deg, #102b61 0%, #0a2049 36%, #081a3b 100%);
  border: 1px solid rgba(164,197,255,.2);
  box-shadow: 0 35px 110px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.07);
}
.rsvp-modal-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--gold), var(--sky), transparent 92%);
  opacity: .9;
}
.rsvp-modal-scroll {
  max-height: min(90dvh, 760px);
  padding: 27px 29px 25px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(110,168,255,.65) rgba(255,255,255,.04);
}
.rsvp-modal-scroll::-webkit-scrollbar { width: 7px; }
.rsvp-modal-scroll::-webkit-scrollbar-track { background: rgba(255,255,255,.035); }
.rsvp-modal-scroll::-webkit-scrollbar-thumb {
  border-radius: 99px;
  background: linear-gradient(180deg, var(--sky), var(--royal));
}
.modal-close {
  position: absolute;
  z-index: 20;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.11);
  background: rgba(255,255,255,.07);
  backdrop-filter: blur(12px);
  transition: .25s ease;
}
.modal-close:hover { transform: rotate(90deg); background: rgba(255,255,255,.13); }
.modal-heading { padding-right: 46px; }
.modal-heading .section-mini { font-size: .66rem; }
.modal-heading h3 {
  margin: 11px 0 8px;
  font-size: clamp(1.8rem, 4vw, 2.35rem);
}
.modal-intro { font-size: .92rem; line-height: 1.62 !important; }

.rsvp-form-modal { margin-top: 19px; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px 14px;
}
.field,
.form-group {
  position: relative;
  min-width: 0;
  margin: 0 !important;
}
.field-full { grid-column: 1 / -1; }
.field > span,
.field-label,
.form-group > span {
  display: block;
  margin: 0 0 7px;
  color: #f3f7ff;
  font-size: .85rem;
  font-weight: 700;
}
.rsvp-form input,
.rsvp-form textarea {
  min-height: 49px;
  margin: 0;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(174,201,255,.18);
  background: rgba(2,14,37,.42);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.025);
  font-size: .94rem;
  transition: .22s ease;
}
.rsvp-form input:hover,
.rsvp-form textarea:hover { border-color: rgba(174,201,255,.3); }
.rsvp-form input:focus,
.rsvp-form textarea:focus {
  border-color: rgba(110,168,255,.78);
  box-shadow: 0 0 0 4px rgba(65,105,225,.17), inset 0 1px 0 rgba(255,255,255,.04);
}
.rsvp-form input:-webkit-autofill,
.rsvp-form input:-webkit-autofill:hover,
.rsvp-form input:-webkit-autofill:focus {
  -webkit-text-fill-color: #fff;
  -webkit-box-shadow: 0 0 0 1000px #0b214b inset;
}

.choice-grid { gap: 10px; }
.choice-card {
  min-height: 58px;
  margin: 0 !important;
  padding: 10px 12px;
  border-radius: 15px;
  border: 1px solid rgba(174,201,255,.15);
  background: rgba(255,255,255,.045);
  cursor: pointer;
  transition: .22s ease;
}
.choice-card:hover { border-color: rgba(110,168,255,.45); background: rgba(65,105,225,.11); }
.choice-card input {
  position: relative;
  appearance: none;
  width: 20px;
  height: 20px;
  min-height: 20px;
  flex: 0 0 20px;
  padding: 0;
  border: 2px solid rgba(205,222,255,.55);
  border-radius: 50%;
  background: transparent;
}
.choice-card input::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), #fff1b8);
  transform: scale(0);
  transition: transform .18s ease;
}
.choice-card input:checked { border-color: var(--gold); }
.choice-card input:checked::after { transform: scale(1); }
.choice-card:has(input:checked) {
  border-color: rgba(243,215,138,.62);
  background: linear-gradient(135deg, rgba(243,215,138,.12), rgba(65,105,225,.11));
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
}
.choice-card > span { display: grid; gap: 2px; }
.choice-card strong { color: #fff; font-size: .9rem; }
.choice-card small { color: var(--text-soft); font-size: .73rem; line-height: 1.25; }

/* Select profissional — nenhum controle nativo aparente */
.custom-select { position: relative; width: 100%; }
.custom-select-trigger {
  width: 100%;
  min-height: 49px;
  padding: 0 13px 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(174,201,255,.18);
  border-radius: 14px;
  color: #fff;
  background: rgba(2,14,37,.42);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.025);
  text-align: left;
  font-size: .94rem;
  font-weight: 600;
  transition: .22s ease;
}
.custom-select-trigger:hover { border-color: rgba(174,201,255,.34); }
.custom-select.open .custom-select-trigger {
  border-color: rgba(110,168,255,.8);
  box-shadow: 0 0 0 4px rgba(65,105,225,.17);
}
.select-chevron {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-right: 2px solid #cfe0ff;
  border-bottom: 2px solid #cfe0ff;
  transform: rotate(45deg) translateY(-2px);
  transition: transform .22s ease;
}
.custom-select.open .select-chevron { transform: rotate(225deg) translate(-1px, -1px); }
.custom-select-menu {
  position: absolute;
  z-index: 80;
  top: calc(100% + 7px);
  left: 0;
  right: 0;
  max-height: 205px;
  padding: 6px;
  display: grid;
  gap: 3px;
  overflow-y: auto;
  border-radius: 15px;
  border: 1px solid rgba(174,201,255,.2);
  background: rgba(8,28,65,.98);
  box-shadow: 0 20px 45px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.04);
  backdrop-filter: blur(18px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-7px) scale(.985);
  transform-origin: top;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
  scrollbar-width: thin;
  scrollbar-color: rgba(110,168,255,.65) transparent;
}
.custom-select.open .custom-select-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.custom-select-menu [role="option"] {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  border: 0;
  border-radius: 10px;
  color: #eaf2ff;
  background: transparent;
  text-align: left;
  font-size: .9rem;
  font-weight: 600;
  transition: .16s ease;
}
.custom-select-menu [role="option"]:hover,
.custom-select-menu [role="option"]:focus {
  outline: 0;
  color: #fff;
  background: rgba(110,168,255,.14);
}
.custom-select-menu [role="option"][aria-selected="true"] {
  color: #10234e;
  background: linear-gradient(135deg, #fff5c8, var(--gold));
  font-weight: 800;
}

.submit-confirmation {
  min-height: 53px;
  margin-top: 17px;
  gap: 10px;
  box-shadow: 0 18px 36px rgba(65,105,225,.28);
}
.submit-confirmation i { font-style: normal; animation: submitStar 1.8s ease-in-out infinite; }
@keyframes submitStar { 50% { transform: rotate(45deg) scale(1.25); opacity: .65; } }
.form-feedback { min-height: 20px; margin: 9px 0 0; font-size: .84rem; }

/* Confirmação com mais acabamento */
.rsvp-success { position: relative; min-height: 470px; overflow: hidden; }
.rsvp-success::before,
.rsvp-success::after {
  content: '';
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .25;
  pointer-events: none;
}
.rsvp-success::before { left: -100px; top: -80px; background: var(--royal); }
.rsvp-success::after { right: -100px; bottom: -90px; background: var(--gold); }
.rsvp-success > * { position: relative; z-index: 2; }
.success-orbit {
  position: absolute;
  width: 190px;
  height: 190px;
  top: 83px;
  left: 50%;
  transform: translateX(-50%);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 50%;
  animation: orbitSpin 12s linear infinite;
}
.success-orbit span {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 15px rgba(243,215,138,.72);
}
.success-orbit span:nth-child(1) { top: 8px; left: 50%; }
.success-orbit span:nth-child(2) { right: 12px; bottom: 42px; background: #fff; }
.success-orbit span:nth-child(3) { left: 9px; bottom: 55px; background: var(--sky); }
@keyframes orbitSpin { to { transform: translateX(-50%) rotate(360deg); } }

@media (max-width: 980px) {
  .gifts-grid { grid-template-columns: 1fr; }
  .gift-card { min-height: 105px; }
}

@media (max-width: 700px) {
  .age-wrap { width: min(250px, 90%); }
  .age-svg text { font-size: 166px; }
  .age-wrap .age-label { margin-top: -18px; }
  .hero-name-seal { min-height: 70px; }
  .royal-ribbon { right: 17px; bottom: 14px; }

  .gift-card {
    min-height: 0;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 12px;
    padding: 14px;
  }
  .gift-icon { width: 48px; height: 48px; }
  .gift-select-button {
    grid-column: 1 / -1;
    width: 100%;
    min-height: 40px;
  }
  .gift-list-note { padding: 14px; }

  .rsvp-modal-card {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
    border-radius: 22px;
  }
  .rsvp-modal-scroll {
    max-height: calc(100dvh - 16px);
    padding: 22px 16px 19px;
  }
  .modal-close { top: 10px; right: 10px; }
  .modal-heading { padding-right: 40px; }
  .modal-heading h3 { font-size: 1.72rem; }
  .modal-intro { font-size: .86rem; }
  .form-grid { grid-template-columns: 1fr; gap: 12px; }
  .field-full { grid-column: auto; }
  .choice-grid { grid-template-columns: 1fr 1fr; }
  .choice-card { min-height: 57px; padding: 9px 10px; }
  .choice-card small { font-size: .68rem; }
  .custom-select-menu { max-height: 178px; }
  .rsvp-success { min-height: min(510px, calc(100dvh - 60px)); padding-inline: 8px; }
}

@media (max-width: 390px) {
  .choice-grid { grid-template-columns: 1fr; }
  .age-wrap { width: 225px; }
  .age-svg text { font-size: 158px; }
  .hero-name-seal strong { font-size: .94rem; }
}

/* Cartões de presente ainda mais compactos no celular */
@media (max-width: 700px) {
  .gift-card {
    grid-template-columns: 46px minmax(0, 1fr) 42px;
    min-height: 92px;
    padding: 13px 14px;
  }
  .gift-icon { width: 46px; height: 46px; }
  .gift-card h3 { font-size: 1rem; }
  .gift-card p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: .78rem;
  }
  .gift-select-button {
    grid-column: auto;
    width: 42px;
    min-width: 42px;
    min-height: 42px;
    padding: 0;
    border-radius: 50%;
  }
  .gift-select-button span { display: none; }
  .gift-select-button i { font-size: 1.08rem; }
}

/* =========================================================
   V8 — refinamentos finais do convite
   ========================================================= */
.navbar {
  justify-content: flex-start;
}
.brand {
  position: relative;
  z-index: 3;
}
.brand-badge-image {
  padding: 0;
  overflow: hidden;
  background: transparent;
  border: 0;
  box-shadow: 0 0 30px rgba(110,168,255,.28), 0 0 0 1px rgba(255,255,255,.13);
}
.brand-badge-image img,
.footer-badge-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: inherit;
}
.menu-toggle,
.nav-links {
  display: none !important;
}

/* Espaço da foto com efeitos decorativos ao redor */
.portrait-stage {
  position: relative;
  width: min(500px, 88vw);
  min-height: 610px;
  display: grid;
  place-items: center;
  margin-inline: auto;
  isolation: isolate;
}
.portrait-stage::before {
  content: '';
  position: absolute;
  inset: 5% 2%;
  z-index: -3;
  border-radius: 48% 48% 22% 22%;
  background:
    radial-gradient(circle at 50% 28%, rgba(255,255,255,.22), transparent 27%),
    radial-gradient(circle at 50% 50%, rgba(65,105,225,.34), transparent 62%);
  filter: blur(30px);
  animation: portraitAura 4.8s ease-in-out infinite alternate;
}
.portrait-stage::after {
  content: '';
  position: absolute;
  inset: 11% 7%;
  z-index: -2;
  border-radius: 50% 50% 25% 25%;
  border: 1px solid rgba(243,215,138,.28);
  box-shadow: 0 0 42px rgba(110,168,255,.2), inset 0 0 38px rgba(255,255,255,.05);
}
@keyframes portraitAura {
  to { transform: scale(1.045); opacity: .78; }
}
.portrait-stage .portrait-shell {
  width: min(430px, 82vw);
  margin: 0;
  position: relative;
  z-index: 2;
  box-shadow:
    0 36px 90px rgba(0,0,0,.38),
    0 0 0 1px rgba(255,255,255,.12),
    0 0 50px rgba(65,105,225,.18);
}
.portrait-stage .portrait-shell::before {
  content: '';
  position: absolute;
  inset: 10px;
  border-radius: 205px 205px 27px 27px;
  border: 1px solid rgba(255,255,255,.14);
  pointer-events: none;
}
.portrait-stage .portrait-placeholder {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 18%, rgba(255,255,255,.18), transparent 30%),
    linear-gradient(160deg, rgba(65,105,225,.18), rgba(255,255,255,.035));
}
.portrait-stage .portrait-placeholder::before {
  content: '';
  position: absolute;
  width: 170%;
  height: 34%;
  left: -35%;
  top: 15%;
  transform: rotate(-18deg);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.13), transparent);
  animation: portraitShine 5.8s ease-in-out infinite;
}
@keyframes portraitShine {
  0%, 45% { transform: translateX(-70%) rotate(-18deg); opacity: 0; }
  60% { opacity: 1; }
  100% { transform: translateX(70%) rotate(-18deg); opacity: 0; }
}
.portrait-orbit {
  position: absolute;
  z-index: 0;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.11);
  pointer-events: none;
}
.portrait-orbit::before {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 20px rgba(243,215,138,.75);
}
.orbit-one {
  width: 96%;
  aspect-ratio: 1;
  animation: portraitOrbit 22s linear infinite;
}
.orbit-one::before { top: 13%; left: 8%; }
.orbit-two {
  width: 82%;
  aspect-ratio: 1;
  border-style: dashed;
  animation: portraitOrbitReverse 28s linear infinite;
}
.orbit-two::before { right: 7%; bottom: 23%; background: var(--sky); }
@keyframes portraitOrbit { to { transform: rotate(360deg); } }
@keyframes portraitOrbitReverse { to { transform: rotate(-360deg); } }
.portrait-spark {
  position: absolute;
  z-index: 4;
  color: #fff;
  text-shadow: 0 0 20px rgba(255,255,255,.9);
  animation: portraitSpark 2.2s ease-in-out infinite alternate;
}
.portrait-spark-1 { left: 3%; top: 18%; font-size: 1.6rem; }
.portrait-spark-2 { right: 4%; top: 27%; font-size: 1.2rem; animation-delay: .5s; }
.portrait-spark-3 { left: 5%; bottom: 24%; font-size: 1.15rem; animation-delay: 1s; }
.portrait-spark-4 { right: 3%; bottom: 16%; font-size: 1.5rem; animation-delay: .25s; }
@keyframes portraitSpark {
  to { transform: scale(1.45) rotate(25deg); opacity: .42; }
}

.rsvp-cta-card p {
  max-width: 700px;
}

.footer-badge-image {
  padding: 0;
  overflow: hidden;
  background: transparent;
  box-shadow: 0 0 24px rgba(110,168,255,.22);
}

/* Confirmação com linguagem adequada ao convite */
.rsvp-success h3 {
  max-width: 540px;
  margin-inline: auto;
}

@media (max-width: 980px) {
  .navbar { justify-content: center; }
  .brand-text { display: inline; }
  .portrait-stage { min-height: 570px; }
}

@media (max-width: 700px) {
  .navbar {
    min-height: 76px;
    justify-content: flex-start;
  }
  .brand-text {
    display: inline;
    font-size: .76rem;
    letter-spacing: .045em;
  }
  .brand-badge { width: 46px; height: 46px; }
  .portrait-stage {
    width: min(100%, 390px);
    min-height: 500px;
  }
  .portrait-stage .portrait-shell {
    width: min(340px, 84vw);
  }
  .portrait-orbit.orbit-one { width: 100%; }
  .portrait-orbit.orbit-two { width: 88%; }
  .portrait-spark-1 { left: 0; }
  .portrait-spark-2 { right: 0; }
  .portrait-spark-3 { left: 1%; }
  .portrait-spark-4 { right: 0; }
}

/* =========================================================
   CORREÇÃO DEFINITIVA — FOTO ENCAIXADA NA MOLDURA
   ========================================================= */
#convite .portrait-stage {
  min-height: auto;
  padding: 34px 30px;
}

#convite .portrait-stage {
  filter: drop-shadow(0 24px 60px rgba(0, 0, 0, .22));
}

#convite .portrait-stage .portrait-shell {
  display: block;
  width: min(432px, 82vw);
  aspect-ratio: 0.82;
  padding: 4px;
  overflow: hidden;
  border-radius: 50% 50% 8% 8% / 34% 34% 8% 8%;
  background:
    linear-gradient(145deg, rgba(247,223,154,.96) 0%, rgba(255,255,255,.88) 20%, rgba(189,208,248,.94) 48%, rgba(87,122,221,.96) 80%, rgba(40,76,174,.98) 100%);
  box-shadow:
    0 28px 68px rgba(0,0,0,.34),
    0 0 0 1px rgba(255,255,255,.24),
    0 0 0 2px rgba(247,223,154,.18),
    0 0 28px rgba(110,168,255,.18);
}

#convite .portrait-stage .portrait-shell::before {
  inset: 4px;
  z-index: 4;
  border-radius: 50% 50% 7.2% 7.2% / 33.2% 33.2% 7.2% 7.2%;
  border: 1px solid rgba(255, 246, 220, .72);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.08),
    inset 0 0 20px rgba(255,255,255,.03);
}

#convite .portrait-stage .portrait-photo-frame {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 50% 50% 7.2% 7.2% / 33.2% 33.2% 7.2% 7.2% !important;
  background: linear-gradient(180deg, #10285f 0%, #0a1d43 100%) !important;
  isolation: isolate;
}

#convite .portrait-stage .portrait-photo-frame::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 2;
  width: auto;
  height: auto;
  left: 0;
  top: 0;
  transform: none;
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(255,255,255,.06), transparent 20%, transparent 82%, rgba(4,15,38,.10)),
    radial-gradient(circle at 50% 10%, rgba(255,255,255,.05), transparent 32%);
  animation: none;
  pointer-events: none;
}

#convite .portrait-stage .portrait-photo {
  position: absolute !important;
  inset: 0 !important;
  z-index: 1;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  object-fit: cover !important;
  object-position: 50% 38% !important;
  transform: scale(1.004);
  transform-origin: center;
  border-radius: inherit !important;
  box-shadow: none !important;
}

#convite .portrait-stage .portrait-spark {
  text-shadow: 0 0 16px rgba(255,255,255,.95), 0 0 28px rgba(247,223,154,.35);
}

#convite .portrait-stage .portrait-orbit {
  border-color: rgba(255,255,255,.12);
}

@media (max-width: 700px) {
  #convite .portrait-stage {
    width: min(100%, 390px);
    min-height: auto;
    padding: 28px 18px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(350px, 90vw);
    padding: 4px;
  }

  #convite .portrait-stage .portrait-shell::before {
    inset: 4px;
  }

  #convite .portrait-stage .portrait-photo {
    object-position: 50% 38% !important;
    transform: scale(1.01);
  }
}

/* =========================================================
   V9 — RESPONSIVIDADE COMPLETA E AJUSTES PARA TELAS PEQUENAS
   ========================================================= */
html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

main,
section,
.container,
.hero-copy,
.hero-visual,
.invitation-copy,
.invitation-photo,
.countdown-copy,
.countdown-grid,
.rsvp-cta-card,
.footer-content {
  min-width: 0;
  max-width: 100%;
}

.custom-select.drop-up .custom-select-menu {
  top: auto;
  bottom: calc(100% + 7px);
  transform-origin: bottom;
}

.custom-select.drop-up.open .custom-select-menu {
  transform: translateY(0) scale(1);
}

@media (max-width: 980px) {
  .hero-content,
  .invitation-grid,
  .countdown-card {
    width: 100%;
  }

  .invitation-grid {
    gap: 46px;
  }

  .invitation-copy {
    width: min(100%, 720px);
    margin-inline: auto;
    padding-inline: 8px;
  }

  .invitation-copy h2,
  .invitation-copy p,
  .invitation-copy blockquote,
  .signature {
    max-width: 100%;
  }
}

@media (max-width: 700px) {
  :root {
    --container: min(100% - 22px, 1180px);
  }

  .section {
    padding: 68px 0;
  }

  .hero-content {
    gap: 38px;
    padding-top: 28px;
    padding-bottom: 50px;
  }

  .hero h1 strong {
    max-width: 100%;
    font-size: clamp(3rem, 15.5vw, 5rem);
    line-height: .93;
    overflow-wrap: anywhere;
  }

  .script-title {
    font-size: clamp(2rem, 10vw, 3.1rem);
  }

  .hero-description {
    width: 100%;
    max-width: 100%;
    padding-inline: 2px;
    font-size: .93rem;
    line-height: 1.72;
    text-wrap: pretty;
  }

  .hero-pills {
    width: 100%;
    grid-template-columns: 1fr;
  }

  .hero-pill {
    width: 100%;
    min-width: 0;
    justify-content: center;
    padding: 12px 13px;
    text-align: center;
  }

  .hero-pill strong {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .countdown-card {
    gap: 20px;
  }

  .countdown-copy h2,
  .section-heading h2,
  .invitation-copy h2,
  .rsvp-cta-card h2 {
    font-size: clamp(2rem, 10.5vw, 3rem);
    line-height: 1.08;
    text-wrap: balance;
  }

  .countdown-copy p,
  .section-heading p,
  .invitation-copy p,
  .rsvp-cta-card p {
    font-size: .92rem;
    line-height: 1.72;
    overflow-wrap: anywhere;
    text-wrap: pretty;
  }

  .invitation-grid {
    gap: 36px;
  }

  .invitation-copy {
    width: 100%;
    padding-inline: 3px;
    text-align: center;
  }

  .invitation-copy blockquote {
    margin: 22px 0 14px;
    padding: 18px 16px;
    border-left-width: 2px;
    font-size: .9rem;
    line-height: 1.7;
  }

  .signature {
    font-size: clamp(1.9rem, 10vw, 2.7rem);
    line-height: 1.1;
    overflow-wrap: anywhere;
  }

  #convite .portrait-stage {
    width: 100%;
    max-width: 370px;
    padding: 22px 10px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(100%, 338px);
    max-width: 100%;
  }

  .gifts-grid {
    width: 100%;
  }

  .gift-card {
    width: 100%;
    min-width: 0;
  }

  .pix-box,
  .rsvp-cta-card {
    width: 100%;
    padding: 26px 17px;
  }

  .pix-key {
    width: 100%;
    text-align: center;
  }

  .rsvp-modal-card {
    width: calc(100vw - 10px);
    max-width: calc(100vw - 10px);
    max-height: calc(100dvh - 10px);
    border-radius: 18px;
  }

  .rsvp-modal-scroll {
    max-height: calc(100dvh - 10px);
    padding: 20px 14px 18px;
  }

  .modal-heading {
    padding-right: 38px;
  }

  .modal-heading .section-mini {
    font-size: .59rem;
    letter-spacing: .15em;
  }

  .modal-heading h3 {
    margin-top: 9px;
    font-size: clamp(1.55rem, 8vw, 2rem);
    line-height: 1.08;
  }

  .modal-intro {
    font-size: .82rem;
    line-height: 1.55 !important;
  }

  .form-grid {
    gap: 11px;
  }

  .field > span,
  .field-label,
  .form-group > span {
    font-size: .8rem;
  }

  .rsvp-form input,
  .rsvp-form textarea,
  .custom-select-trigger {
    min-height: 47px;
    font-size: .88rem;
  }

  .custom-select-menu {
    max-height: min(190px, 36dvh);
  }

  .custom-select-menu [role="option"] {
    min-height: 42px;
    font-size: .86rem;
  }

  .submit-confirmation {
    min-height: 50px;
  }

  .rsvp-success {
    min-height: min(450px, calc(100dvh - 44px));
    padding: 22px 5px;
  }

  .rsvp-success h3 {
    font-size: clamp(1.9rem, 9vw, 2.6rem);
  }

  .rsvp-success p {
    font-size: .9rem;
    line-height: 1.65;
  }

  .footer-content p {
    max-width: 290px;
    line-height: 1.6;
  }
}

@media (max-width: 420px) {
  .floating-rsvp {
    display: none;
  }

  .navbar {
    min-height: 70px;
  }

  .brand {
    max-width: 100%;
    gap: 9px;
  }

  .brand-badge {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
  }

  .brand-text {
    min-width: 0;
    font-size: .69rem;
    letter-spacing: .035em;
    white-space: normal;
  }

  .hero-actions {
    width: 100%;
  }

  .hero-actions .button {
    min-height: 50px;
  }

  .countdown-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .count-item {
    min-width: 0;
  }

  .choice-grid {
    grid-template-columns: 1fr;
  }

  .choice-card {
    min-height: 54px;
  }

  .modal-close {
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
  }

  .rsvp-modal-scroll {
    padding: 18px 11px 15px;
  }

  .gift-card {
    grid-template-columns: 42px minmax(0, 1fr) 40px;
    gap: 9px;
    padding: 11px;
  }

  .gift-icon {
    width: 42px;
    height: 42px;
  }

  .gift-select-button {
    width: 40px;
    min-width: 40px;
    min-height: 40px;
  }
}

@media (max-width: 350px) {
  :root {
    --container: min(100% - 16px, 1180px);
  }

  .section {
    padding: 58px 0;
  }

  .hero h1 strong {
    font-size: clamp(2.7rem, 15vw, 4rem);
  }

  .hero-description,
  .invitation-copy p,
  .rsvp-cta-card p {
    font-size: .86rem;
  }

  #convite .portrait-stage {
    padding-inline: 4px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(100%, 314px);
  }

  .countdown-card {
    padding: 22px 12px;
  }

  .count-item strong {
    font-size: 1.8rem;
  }

  .rsvp-modal-card {
    width: calc(100vw - 6px);
    max-width: calc(100vw - 6px);
    border-radius: 15px;
  }

  .rsvp-modal-scroll {
    padding-inline: 9px;
  }
}

/* ============================================================
   V10 — RETRATO LUXO: FOTO ORIGINAL, BORDA FINA E EFEITOS
   ============================================================ */
#convite .invitation-photo {
  position: relative;
  isolation: isolate;
}

#convite .portrait-stage {
  position: relative;
  width: min(520px, 92vw);
  min-height: 630px;
  padding: 34px 30px;
  overflow: visible;
  isolation: isolate;
  filter: drop-shadow(0 30px 72px rgba(0, 0, 0, .28));
}

#convite .portrait-stage::before {
  inset: 7% 3% 5%;
  border-radius: 48% 48% 18% 18% / 35% 35% 14% 14%;
  background:
    radial-gradient(circle at 50% 28%, rgba(255,255,255,.22), transparent 28%),
    radial-gradient(circle at 50% 48%, rgba(77,125,233,.34), transparent 58%),
    radial-gradient(circle at 50% 82%, rgba(243,215,138,.14), transparent 40%);
  filter: blur(34px);
  opacity: .9;
  animation: portraitAuraV10 5.4s ease-in-out infinite alternate;
}

#convite .portrait-stage::after {
  inset: 8% 3.5% 6%;
  border-radius: 50% 50% 18% 18% / 36% 36% 14% 14%;
  border: 1px solid rgba(242, 224, 169, .22);
  box-shadow:
    0 0 44px rgba(78, 128, 235, .16),
    inset 0 0 32px rgba(255,255,255,.035);
}

@keyframes portraitAuraV10 {
  from { transform: scale(.985); opacity: .68; }
  to { transform: scale(1.035); opacity: 1; }
}

#convite .portrait-stage .portrait-shell {
  position: relative;
  z-index: 4;
  display: block;
  width: min(432px, 82vw);
  aspect-ratio: .82;
  padding: 2px;
  overflow: visible;
  border-radius: 50% 50% 8% 8% / 34% 34% 8% 8%;
  background: linear-gradient(
    145deg,
    rgba(255,244,205,.98) 0%,
    rgba(255,255,255,.96) 20%,
    rgba(189,210,255,.92) 46%,
    rgba(92,132,232,.94) 72%,
    rgba(244,220,151,.88) 100%
  );
  box-shadow:
    0 32px 78px rgba(0,0,0,.34),
    0 0 0 1px rgba(255,255,255,.26),
    0 0 24px rgba(94,142,245,.18),
    0 0 38px rgba(243,215,138,.10);
}

#convite .portrait-stage .portrait-shell::before {
  content: '';
  position: absolute;
  inset: 5px;
  z-index: 6;
  border-radius: 50% 50% 7.4% 7.4% / 33.4% 33.4% 7.4% 7.4%;
  border: 1px solid rgba(255, 248, 220, .76);
  box-shadow:
    inset 0 0 0 1px rgba(108,151,247,.14),
    inset 0 0 24px rgba(255,255,255,.04);
  pointer-events: none;
}

#convite .portrait-stage .portrait-shell::after {
  content: '';
  position: absolute;
  inset: -7px;
  z-index: -1;
  border-radius: 50% 50% 9% 9% / 35% 35% 9% 9%;
  border: 1px solid rgba(243,215,138,.23);
  box-shadow: 0 0 18px rgba(243,215,138,.09);
  pointer-events: none;
}

#convite .portrait-stage .portrait-photo-frame {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 50% 50% 7.7% 7.7% / 33.7% 33.7% 7.7% 7.7% !important;
  background: #071a3d !important;
  isolation: isolate;
}

#convite .portrait-stage .portrait-photo-frame::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(255,255,255,.07), transparent 21%, transparent 78%, rgba(2,11,30,.10)),
    radial-gradient(circle at 50% 8%, rgba(255,255,255,.08), transparent 34%);
  pointer-events: none;
  animation: none;
}

#convite .portrait-stage .portrait-photo-frame::after {
  content: '';
  position: absolute;
  z-index: 4;
  inset: -35% -80%;
  transform: translateX(-55%) rotate(-17deg);
  background: linear-gradient(90deg, transparent 41%, rgba(255,255,255,.11) 49%, rgba(255,255,255,.04) 54%, transparent 62%);
  animation: portraitSweepV10 7.2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes portraitSweepV10 {
  0%, 55% { transform: translateX(-58%) rotate(-17deg); opacity: 0; }
  64% { opacity: .8; }
  86%, 100% { transform: translateX(58%) rotate(-17deg); opacity: 0; }
}

#convite .portrait-stage .portrait-photo {
  position: absolute !important;
  inset: 0 !important;
  z-index: 1;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  object-fit: cover !important;
  object-position: 50% 46% !important;
  transform: scale(1.006);
  transform-origin: center;
  border-radius: inherit !important;
  box-shadow: none !important;
}

#convite .portrait-halo {
  position: absolute;
  z-index: 0;
  pointer-events: none;
  border-radius: 50%;
}

#convite .halo-one {
  width: 92%;
  aspect-ratio: 1;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 0 32px rgba(98,146,249,.10);
  animation: haloPulseV10 4.6s ease-in-out infinite alternate;
}

#convite .halo-two {
  width: 78%;
  aspect-ratio: 1;
  border: 1px dashed rgba(243,215,138,.13);
  animation: portraitOrbitReverse 34s linear infinite;
}

@keyframes haloPulseV10 {
  to { transform: scale(1.045); opacity: .52; }
}

#convite .portrait-orbit {
  z-index: 1;
  border-color: rgba(255,255,255,.11);
}

#convite .orbit-one {
  width: 98%;
  border-color: rgba(203,221,255,.10);
}

#convite .orbit-two {
  width: 84%;
  border-color: rgba(243,215,138,.13);
}

#convite .portrait-jewel {
  position: absolute;
  z-index: 7;
  display: grid;
  place-items: center;
  color: #fff8d7;
  text-shadow:
    0 0 10px rgba(255,255,255,.92),
    0 0 24px rgba(243,215,138,.42);
  pointer-events: none;
  animation: jewelFloatV10 2.8s ease-in-out infinite alternate;
}

#convite .jewel-top { top: 4%; left: 50%; transform: translateX(-50%); font-size: .78rem; }
#convite .jewel-left { left: 2%; top: 43%; font-size: 1rem; animation-delay: .5s; }
#convite .jewel-right { right: 1%; top: 57%; font-size: .9rem; animation-delay: 1.1s; }
#convite .jewel-bottom { bottom: 3%; left: 50%; transform: translateX(-50%); font-size: .72rem; animation-delay: .7s; }

@keyframes jewelFloatV10 {
  to { margin-top: -5px; opacity: .55; filter: brightness(1.2); }
}

#convite .portrait-spark {
  z-index: 8;
  color: #fff;
  text-shadow:
    0 0 12px rgba(255,255,255,.95),
    0 0 28px rgba(110,168,255,.45),
    0 0 40px rgba(243,215,138,.14);
}

#convite .portrait-spark-1 { left: 1%; top: 18%; }
#convite .portrait-spark-2 { right: 1%; top: 29%; }
#convite .portrait-spark-3 { left: 2%; bottom: 21%; }
#convite .portrait-spark-4 { right: 1%; bottom: 14%; }

@media (max-width: 700px) {
  #convite .portrait-stage {
    width: min(100%, 402px);
    min-height: auto;
    padding: 30px 22px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(100%, 350px);
    padding: 2px;
  }

  #convite .portrait-stage .portrait-shell::before {
    inset: 4px;
  }

  #convite .portrait-stage .portrait-photo {
    object-position: 50% 46% !important;
    transform: scale(1.008);
  }

  #convite .jewel-left { left: 0; }
  #convite .jewel-right { right: 0; }
}

@media (max-width: 390px) {
  #convite .portrait-stage {
    padding-inline: 13px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(100%, 330px);
  }

  #convite .portrait-spark-1,
  #convite .portrait-spark-3 { left: 0; }

  #convite .portrait-spark-2,
  #convite .portrait-spark-4 { right: 0; }
}

@media (max-width: 340px) {
  #convite .portrait-stage {
    padding-inline: 6px;
  }

  #convite .portrait-stage .portrait-shell {
    width: min(100%, 306px);
  }

  #convite .portrait-jewel {
    transform: scale(.88);
  }
}


/* ============================================================
   V11 — RESPONSIVIDADE FINAL DO POPUP DE CONFIRMAÇÃO
   ============================================================ */
.rsvp-modal {
  padding:
    max(6px, env(safe-area-inset-top))
    max(6px, env(safe-area-inset-right))
    max(6px, env(safe-area-inset-bottom))
    max(6px, env(safe-area-inset-left));
  align-items: center;
  justify-items: center;
}

.rsvp-modal-card {
  width: min(650px, calc(100vw - 16px));
  max-width: calc(100vw - 16px);
  max-height: calc(100dvh - 16px);
  margin: auto;
}

.rsvp-modal-scroll {
  width: 100%;
  max-height: calc(100dvh - 16px);
  padding-bottom: max(20px, env(safe-area-inset-bottom));
  overflow-x: hidden;
  scroll-padding-top: 18px;
  scroll-padding-bottom: 22px;
}

.rsvp-form-modal,
.form-grid,
.field,
.form-group,
.choice-grid,
.choice-card,
.custom-select {
  min-width: 0;
  max-width: 100%;
}

.choice-card {
  display: flex;
  align-items: center;
  gap: 10px;
}

.choice-card input[type="radio"] {
  width: 19px !important;
  height: 19px !important;
  min-width: 19px !important;
  min-height: 19px !important;
  max-width: 19px !important;
  max-height: 19px !important;
  aspect-ratio: 1 / 1;
  flex: 0 0 19px;
  border-radius: 50% !important;
}

.custom-select-menu {
  max-width: 100%;
  overscroll-behavior: contain;
}

@media (max-width: 520px) {
  .rsvp-modal {
    align-items: flex-start;
    padding: 5px;
  }

  .rsvp-modal-card {
    width: calc(100vw - 10px);
    max-width: calc(100vw - 10px);
    max-height: calc(100dvh - 10px);
    border-radius: 18px;
  }

  .rsvp-modal-scroll {
    max-height: calc(100dvh - 10px);
    padding: 18px 13px max(18px, env(safe-area-inset-bottom));
  }

  .modal-close {
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    font-size: 1.25rem;
  }

  .modal-heading {
    padding-right: 42px;
  }

  .modal-heading .section-mini {
    max-width: calc(100% - 2px);
    font-size: .57rem;
    line-height: 1.4;
    letter-spacing: .13em;
  }

  .modal-heading h3 {
    margin: 8px 0 6px;
    font-size: clamp(1.55rem, 7.7vw, 1.95rem);
    line-height: 1.05;
  }

  .modal-intro {
    margin: 0;
    font-size: .79rem;
    line-height: 1.48 !important;
  }

  .rsvp-form-modal {
    margin-top: 14px;
  }

  .form-grid {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .field-full {
    grid-column: auto;
  }

  .field > span,
  .field-label,
  .form-group > span {
    margin-bottom: 5px;
    font-size: .76rem;
    line-height: 1.25;
  }

  .rsvp-form input,
  .rsvp-form textarea,
  .custom-select-trigger {
    width: 100%;
    min-height: 44px;
    padding-inline: 12px;
    border-radius: 12px;
    font-size: .84rem;
  }

  .choice-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .choice-card {
    min-height: 55px;
    padding: 8px 9px;
    border-radius: 13px;
    gap: 8px;
  }

  .choice-card strong {
    font-size: .82rem;
  }

  .choice-card small {
    font-size: .64rem;
    line-height: 1.15;
  }

  .choice-card input[type="radio"] {
    width: 17px !important;
    height: 17px !important;
    min-width: 17px !important;
    min-height: 17px !important;
    max-width: 17px !important;
    max-height: 17px !important;
    flex-basis: 17px;
  }

  .custom-select-menu {
    max-height: min(176px, 33dvh);
    padding: 5px;
    border-radius: 13px;
  }

  .custom-select-menu [role="option"] {
    min-height: 39px;
    padding-inline: 10px;
    font-size: .82rem;
  }

  .submit-confirmation {
    min-height: 48px;
    margin-top: 12px;
    border-radius: 14px;
    font-size: .9rem;
  }

  .form-feedback {
    min-height: 14px;
    margin-top: 6px;
    font-size: .76rem;
  }
}

@media (max-width: 350px) {
  .rsvp-modal {
    padding: 3px;
  }

  .rsvp-modal-card {
    width: calc(100vw - 6px);
    max-width: calc(100vw - 6px);
    max-height: calc(100dvh - 6px);
    border-radius: 14px;
  }

  .rsvp-modal-scroll {
    max-height: calc(100dvh - 6px);
    padding: 15px 9px max(14px, env(safe-area-inset-bottom));
  }

  .modal-heading .section-mini {
    font-size: .52rem;
    letter-spacing: .1em;
  }

  .modal-heading h3 {
    font-size: 1.45rem;
  }

  .modal-intro {
    font-size: .73rem;
  }

  .choice-grid {
    grid-template-columns: 1fr;
  }

  .choice-card {
    min-height: 48px;
  }

  .rsvp-form input,
  .custom-select-trigger {
    min-height: 42px;
  }
}

@media (max-height: 690px) and (max-width: 520px) {
  .rsvp-modal-scroll {
    padding-top: 14px;
  }

  .modal-heading .section-mini {
    display: none;
  }

  .modal-heading h3 {
    margin-top: 0;
    font-size: 1.5rem;
  }

  .modal-intro {
    font-size: .75rem;
    line-height: 1.42 !important;
  }

  .rsvp-form-modal {
    margin-top: 11px;
  }

  .form-grid {
    gap: 8px;
  }

  .field > span,
  .field-label,
  .form-group > span {
    font-size: .73rem;
  }

  .rsvp-form input,
  .custom-select-trigger {
    min-height: 41px;
  }

  .choice-card {
    min-height: 49px;
    padding-block: 6px;
  }

  .submit-confirmation {
    min-height: 45px;
    margin-top: 10px;
  }
}

@media (orientation: landscape) and (max-height: 540px) {
  .rsvp-modal {
    align-items: flex-start;
  }

  .rsvp-modal-card,
  .rsvp-modal-scroll {
    max-height: calc(100dvh - 8px);
  }

  .rsvp-modal-scroll {
    padding-top: 12px;
  }

  .modal-heading .section-mini,
  .modal-intro {
    display: none;
  }

  .modal-heading h3 {
    margin: 0 0 10px;
    font-size: 1.45rem;
  }

  .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 10px;
  }

  .field-full {
    grid-column: 1 / -1;
  }
}


/* V12 adjustments */
.choice-card input[type="radio"] {
  -webkit-appearance: none !important;
  appearance: none !important;
  display: inline-block !important;
  box-sizing: border-box !important;
  inline-size: 20px !important;
  block-size: 20px !important;
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  flex: 0 0 20px !important;
  border-radius: 50% !important;
  vertical-align: middle;
  margin: 0 !important;
}
.choice-card input[type="radio"]::after {
  inset: 3px !important;
  border-radius: 50% !important;
}
@media (max-width: 520px) {
  .choice-card input[type="radio"] {
    inline-size: 18px !important;
    block-size: 18px !important;
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    max-width: 18px !important;
    max-height: 18px !important;
    flex-basis: 18px !important;
  }
}
.custom-gift-field[hidden] { display: none !important; }


/* V13 — refinamento final de foto, assinatura, obrigatoriedade e seletores */
#convite .portrait-stage .portrait-photo {
  object-fit: cover !important;
  object-position: 50% 50% !important;
  transform: scale(1.001) !important;
}

.signature {
  display: grid;
  justify-items: start;
  gap: 2px;
  margin-top: 18px;
  color: var(--gold);
  font-family: 'Playfair Display', Georgia, serif !important;
  font-style: italic;
  line-height: 1.18 !important;
  letter-spacing: .015em;
  overflow-wrap: normal !important;
}
.signature span {
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  font-weight: 500;
}
.signature strong {
  font-size: clamp(1.45rem, 2.6vw, 2.05rem);
  font-weight: 700;
  letter-spacing: .035em;
}

.required-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 5px;
  border-radius: 50%;
  background: #ff4d5f;
  box-shadow: 0 0 0 3px rgba(255,77,95,.13), 0 0 10px rgba(255,77,95,.32);
  vertical-align: middle;
}

/* O menu deve abrir sempre para baixo. */
.custom-select.drop-up .custom-select-menu,
.custom-select .custom-select-menu {
  top: calc(100% + 7px) !important;
  bottom: auto !important;
  transform-origin: top !important;
}

@media (max-width: 700px) {
  .signature {
    justify-items: center;
    text-align: center;
    margin-inline: auto;
  }

  .custom-select-menu {
    max-height: min(190px, 34dvh) !important;
  }

  #convite .portrait-stage .portrait-photo {
    object-position: 50% 50% !important;
    transform: scale(1.001) !important;
  }
}


/* V13.1 mobile radio fix */
.rsvp-form .choice-card input[type="radio"] {
  -webkit-appearance: none !important;
  appearance: none !important;
  box-sizing: border-box !important;
  display: inline-block !important;
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  flex: 0 0 20px !important;
  padding: 0 !important;
  padding-inline: 0 !important;
  margin: 0 !important;
  border: 2px solid rgba(205,222,255,.55) !important;
  border-radius: 999px !important;
  background: transparent !important;
  box-shadow: none !important;
  line-height: 0 !important;
  transform: none !important;
  aspect-ratio: 1 / 1 !important;
  overflow: hidden !important;
  vertical-align: middle !important;
}
.rsvp-form .choice-card input[type="radio"]::after {
  content: '' !important;
  position: absolute !important;
  inset: 3px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, var(--gold), #fff1b8) !important;
  transform: scale(0) !important;
  transition: transform .18s ease !important;
}
.rsvp-form .choice-card input[type="radio"]:checked {
  border-color: var(--gold) !important;
}
.rsvp-form .choice-card input[type="radio"]:checked::after {
  transform: scale(1) !important;
}
@media (max-width: 520px) {
  .rsvp-form .choice-card input[type="radio"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    max-width: 18px !important;
    max-height: 18px !important;
    flex-basis: 18px !important;
  }
}


/* V14 — correção cirúrgica do rádio no mobile */
@media (max-width: 700px) {
  .rsvp-form .choice-card {
    position: relative;
  }

  .rsvp-form .choice-card input[type="radio"] {
    position: absolute !important;
    inline-size: 1px !important;
    block-size: 1px !important;
    width: 1px !important;
    height: 1px !important;
    min-width: 1px !important;
    min-height: 1px !important;
    max-width: 1px !important;
    max-height: 1px !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
  }

  .rsvp-form .choice-card > span {
    position: relative;
    display: grid;
    gap: 2px;
    width: 100%;
    min-width: 0;
    padding-left: 28px;
  }

  .rsvp-form .choice-card > span::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 18px;
    height: 18px;
    box-sizing: border-box;
    border: 2px solid rgba(205,222,255,.62);
    border-radius: 50%;
    background: transparent;
    transform: translateY(-50%);
    box-shadow: none;
  }

  .rsvp-form .choice-card > span::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 50%;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), #fff1b8);
    transform: translateY(-50%) scale(0);
    transition: transform .18s ease;
  }

  .rsvp-form .choice-card input[type="radio"]:checked + span::before {
    border-color: var(--gold);
  }

  .rsvp-form .choice-card input[type="radio"]:checked + span::after {
    transform: translateY(-50%) scale(1);
  }

  .rsvp-form .choice-card input[type="radio"]:focus-visible + span::before {
    outline: 2px solid rgba(110,168,255,.72);
    outline-offset: 3px;
  }
}
