:root {
    --sand: #c7a879;
    --paper: #efe1c9;
    --green: #596348;
    --green-dark: #394229;
    --header-height: 110px;
}

* { box-sizing: border-box; }
html { scroll-padding-top: var(--header-height); }
.home-anchor { position: absolute; top: 0; left: 0; width: 1px; height: 1px; pointer-events: none; scroll-margin-top: 0; }
body { margin: 0; background: var(--paper); color: var(--green-dark); font-family: Georgia, 'Times New Roman', serif; }
img { display: block; width: 100%; height: auto; }
.gift-image-link { display: block; line-height: 0; }
button, input, select, textarea { font: inherit; }

.site-header { height: var(--header-height); background: var(--sand); display: flex; align-items: center; justify-content: center; position: sticky; top: 0; z-index: 1000; box-shadow: 0 1px 0 rgba(0,0,0,.04); }
.main-menu { width: min(100%, 1040px); display: flex; justify-content: center; align-items: center; gap: 28px; flex-wrap: nowrap; padding: 0 20px; }
.main-menu a { color: var(--green-dark); text-decoration: none; text-transform: uppercase; letter-spacing: .04em; font-size: 18px; line-height: 1; white-space: nowrap; transition: opacity .2s ease; }
.main-menu a:hover { opacity: .65; }
.menu-toggle { display: none; }

main { width: min(100%, 1056px); margin: 0 auto; overflow: hidden; background: var(--paper); }
.art-section { position: relative; line-height: 0; }
.anchor-section { scroll-margin-top: 1px; }
.cover-section { margin-top: calc(var(--header-height) * -1); padding-top: var(--header-height); overflow: hidden; }
.cover-section img { margin-top: calc(var(--header-height) * -1); }

/* Contagem real posicionada dentro do cartão da arte */
.countdown { position: absolute; top: 45.6%; left: 35%; width: 30%; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1%; text-align: center; color: #3d422f; line-height: 1.05; pointer-events: none; }
.countdown div { min-width: 0; }
.countdown strong { display: block; font-size: clamp(11px, 2.25vw, 25px); font-weight: 400; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.countdown span { display: block; margin-top: .55em; font-size: clamp(5px, .82vw, 10px); text-transform: uppercase; letter-spacing: .08em; }

/* RSVP construído em HTML sobre o fundo original limpo */
.rsvp-section { position: relative; min-height: 0; aspect-ratio: 1004 / 1536; background: #596348 url('../images/rsvp-fundo.png') center / 100% 100% no-repeat; color: #eadbc4; line-height: 1.2; }
.rsvp-content { position: absolute; inset: 0; padding: 6.5% 7.8% 5%; }
.rsvp-content > h2, .gifts h2 { margin: 0; text-align: center; text-transform: uppercase; font-weight: 400; letter-spacing: .19em; color: #eadbc4; }
.rsvp-content > h2 { font-size: clamp(25px, 5.1vw, 53px); }
.rsvp-form { margin-top: 8.5%; }
.rsvp-form .field { margin-bottom: 6.4%; }
.rsvp-form label { display: block; margin-bottom: 2.2%; font-size: clamp(10px, 2.55vw, 27px); font-weight: 400; letter-spacing: .08em; text-transform: uppercase; }
.rsvp-form input, .rsvp-form select, .rsvp-form textarea { display: block; width: 100%; border: 2px solid rgba(239,225,201,.92); border-radius: 0; background: rgba(64,72,50,.08); color: #fff4df; outline: none; padding: 1.4% 1.8%; transition: background .2s ease, box-shadow .2s ease; }
.rsvp-form input, .rsvp-form select { height: clamp(38px, 7.5vw, 79px); }
.rsvp-form textarea { height: clamp(85px, 16.4vw, 174px); resize: none; }
.lgpd-consent { display: flex !important; align-items: flex-start; gap: 1.2%; margin: -2.5% 0 3.2%; text-transform: none !important; letter-spacing: .015em !important; font-size: clamp(8px, 1.45vw, 15px) !important; line-height: 1.35; cursor: pointer; }
.lgpd-consent input { flex: 0 0 auto; width: clamp(14px, 1.9vw, 20px) !important; height: clamp(14px, 1.9vw, 20px) !important; margin: .15em 0 0; padding: 0; accent-color: #e7d2b5; }
.lgpd-consent span { display: block; text-align: left; }
.rsvp-form input:focus, .rsvp-form select:focus, .rsvp-form textarea:focus { background: rgba(64,72,50,.32); box-shadow: 0 0 0 2px rgba(239,225,201,.17); }
.rsvp-form option { color: #333; background: #f2e6d2; }
.submit-rsvp { width: 100%; height: clamp(44px, 7.5vw, 80px); margin-top: 0; border: 0; background: #e7d2b5; color: #465038; text-transform: uppercase; letter-spacing: .08em; font-size: clamp(16px, 3vw, 31px); cursor: pointer; transition: filter .2s ease; }
.submit-rsvp:hover { filter: brightness(.96); }
.gifts { margin-top: 12%; text-align: center; }
.gifts h2 { font-size: clamp(24px, 5vw, 52px); }
.gift-link { display: inline-block; margin-top: 7%; color: #eadbc4; font-size: clamp(11px, 2.55vw, 27px); letter-spacing: .06em; line-height: 1.25; text-underline-offset: .18em; }
.honeypot { position: absolute !important; left: -9999px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }

/* Modal de retorno */
.confirmation-modal { position: fixed; inset: 0; z-index: 3000; display: none; place-items: center; padding: 20px; }
.confirmation-modal.is-open { display: grid; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(31,38,24,.72); backdrop-filter: blur(3px); }
.modal-card { position: relative; z-index: 1; width: min(92vw, 470px); padding: 48px 42px 38px; background: #efe1c9; color: #394229; text-align: center; box-shadow: 0 22px 70px rgba(0,0,0,.32); border: 1px solid rgba(89,99,72,.25); }
.modal-card.error { border-top: 5px solid #8a493f; }
.modal-monogram { font-size: 38px; font-style: italic; letter-spacing: .05em; }
.modal-monogram span { font-size: .65em; margin: 0 .2em; }
.modal-card h2 { margin: 20px 0 12px; font-size: 30px; font-weight: 400; }
.modal-card p { margin: 0; font: 17px/1.6 Georgia, serif; }
.modal-button { margin-top: 26px; min-width: 150px; padding: 12px 24px; border: 0; background: #596348; color: #f2e6d2; text-transform: uppercase; letter-spacing: .1em; cursor: pointer; }
.modal-close { position: absolute; top: 8px; right: 13px; border: 0; background: transparent; color: #596348; font-size: 30px; cursor: pointer; }

@media (max-width: 700px) {
    :root { --header-height: 68px; }
    .site-header { justify-content: flex-end; padding: 0 18px; }
    .menu-toggle { display: flex; width: 42px; height: 42px; border: 0; background: transparent; flex-direction: column; justify-content: center; gap: 5px; cursor: pointer; }
    .menu-toggle span { width: 27px; height: 2px; margin-left: auto; background: var(--green-dark); transition: .2s ease; }
    .menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
    .menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
    .main-menu { position: absolute; top: 100%; left: 0; right: 0; display: none; flex-direction: column; align-items: stretch; padding: 8px 20px 20px; background: var(--sand); box-shadow: 0 12px 18px rgba(0,0,0,.12); }
    .main-menu.open { display: flex; }
    .main-menu a { text-align: center; padding: 13px; font-size: 15px; border-top: 1px solid rgba(57,66,41,.15); }
    .countdown { left: 34%; width: 32%; }
    .countdown strong { font-size: clamp(8px, 2.25vw, 15px); }
    .countdown span { font-size: clamp(4px, .82vw, 7px); }
    .rsvp-section { aspect-ratio: auto; height: auto; min-height: 0; background-size: cover; }
    .rsvp-content { position: relative; inset: auto; padding-bottom: 9%; }
    .gifts { margin-top: 6%; padding-bottom: 2%; }
    .rsvp-form input, .rsvp-form select, .rsvp-form textarea { border-width: 1px; }
    .modal-card { padding: 42px 25px 32px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
}
