/* ============================================================
   Elise & Pedro Henrique — Renovação de Votos
   Paleta: marfim, verde-sálvia, dourado suave
   ============================================================ */

:root {
  --marfim: #f7f2ea;
  --marfim-2: #efe7da;
  --creme: #fffdf9;
  --verde: #4a5d4e;
  --verde-esc: #2b352d;
  --verde-claro: #6f8271;
  --dourado: #b08d57;
  --dourado-claro: #c9a978;
  --tinta: #2f322e;
  --tinta-suave: #5c5f58;
  --linha: #e2d8c7;
  --sombra: 0 18px 50px rgba(47, 50, 46, 0.10);
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Montserrat", -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  color: var(--tinta);
  background: var(--marfim);
  font-weight: 300;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.15; }
a { color: inherit; }
img { max-width: 100%; display: block; }
.container { width: min(1080px, 90vw); margin: 0 auto; }

/* ---------- Rótulos / títulos ---------- */
.rotulo {
  text-transform: uppercase; letter-spacing: 0.32em;
  font-size: 0.72rem; font-weight: 500; color: var(--dourado); margin-bottom: 0.9rem;
}
.rotulo--claro { color: var(--dourado-claro); }
.claro { color: #f3ede1 !important; }

.secao { padding: clamp(1.75rem, 3.5vw, 3rem) 0; }
.secao--alt { background: var(--creme); }
.secao--escura { background: var(--verde-esc); color: #eee7d8; }

.secao__cabeca { text-align: center; margin-bottom: 1.4rem; }
.secao__cabeca h2 { font-size: clamp(2.1rem, 5vw, 3.2rem); color: var(--verde); }

.ornamento { display: flex; align-items: center; justify-content: center; gap: 0.8rem; color: var(--dourado); margin: 1rem 0; }
.ornamento::before, .ornamento::after { content: ""; height: 1px; width: 54px; background: linear-gradient(90deg, transparent, var(--dourado-claro)); }
.ornamento::after { background: linear-gradient(270deg, transparent, var(--dourado-claro)); }
.ornamento--claro { color: var(--dourado-claro); }
.ornamento--claro::before { background: linear-gradient(90deg, transparent, var(--dourado-claro)); }
.ornamento--claro::after { background: linear-gradient(270deg, transparent, var(--dourado-claro)); }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-size: 0.78rem; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase;
  padding: 0.95rem 2rem; border-radius: 999px;
  border: 1px solid var(--verde); background: var(--verde); color: #fff;
  cursor: pointer; text-decoration: none; transition: all .25s ease;
}
.btn:hover { background: #3c4d40; transform: translateY(-2px); box-shadow: var(--sombra); }
.btn--linha { background: transparent; color: var(--verde); }
.btn--linha:hover { background: var(--verde); color: #fff; }
.btn--ouro { background: var(--dourado); border-color: var(--dourado); }
.btn--ouro:hover { background: #9a7a48; }
.btn--claro { background: #fff; color: var(--verde); border-color: #fff; }
.btn--claro:hover { background: var(--dourado); border-color: var(--dourado); color: #fff; }
.btn--fantasma { background: transparent; color: #fff; border-color: rgba(255,255,255,.75); }
.btn--fantasma:hover { background: rgba(255,255,255,.15); border-color: #fff; }
.btn--bloco { width: 100%; }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem clamp(1rem, 5vw, 3rem);
  transition: background .35s ease, box-shadow .35s ease;
}
.nav.solido { background: rgba(247,242,234,.94); backdrop-filter: blur(8px); box-shadow: 0 2px 20px rgba(0,0,0,.05); }
.nav__marca { font-family: var(--serif); font-size: 1.35rem; letter-spacing: .04em; text-decoration: none; color: #fff; transition: color .35s ease; }
.nav.solido .nav__marca { color: var(--verde); }
.nav__links { display: flex; gap: 1.8rem; }
.nav__links a { text-decoration: none; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: #fff; position: relative; padding: .2rem 0; transition: color .35s ease; }
.nav.solido .nav__links a { color: var(--tinta); }
.nav__links a::after { content: ""; position: absolute; left: 0; bottom: -2px; height: 1px; width: 0; background: var(--dourado); transition: width .3s ease; }
.nav__links a:hover::after { width: 100%; }
.nav__toggle { display: none; background: none; border: 0; cursor: pointer; font-size: 1.5rem; color: #fff; }
.nav.solido .nav__toggle { color: var(--verde); }

/* ============================================================
   HERO (foto de fundo)
   ============================================================ */
.hero {
  position: relative; min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 6rem 1.5rem 4rem; color: #fff; overflow: hidden;
}
.hero__img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 60%; background: var(--verde-esc);
}
.hero__scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(30,36,30,.45) 0%, rgba(30,36,30,.15) 35%, rgba(30,36,30,.35) 70%, rgba(30,36,30,.72) 100%);
}
.hero__conteudo { position: relative; z-index: 2; text-shadow: 0 2px 24px rgba(20,24,20,.45); }
.hero__topo { font-family: var(--serif); font-style: italic; font-size: clamp(1.2rem, 3vw, 1.8rem); letter-spacing: .01em; color: #f6efe1; margin-bottom: 1.1rem; text-shadow: 0 2px 20px rgba(20,24,20,.6); }
.hero__nomes { font-size: clamp(2.8rem, 10vw, 6.4rem); line-height: 1; font-weight: 500; }
.hero__nomes .e { font-style: italic; font-size: .45em; color: var(--dourado-claro); display: inline-block; margin: 0 .2em; vertical-align: middle; }
.hero__sub { font-family: var(--serif); font-style: italic; font-size: clamp(1.2rem, 3vw, 1.9rem); margin-top: .6rem; color: #f3ecde; }
.hero__linha { width: 60px; height: 1px; background: var(--dourado-claro); margin: 1.4rem auto; opacity: .9; }
.hero__data { font-size: .82rem; letter-spacing: .24em; text-transform: uppercase; }
.hero__ctas { margin-top: 2.4rem; display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.hero__ctas .btn { min-width: 260px; }
.hero__scroll { position: absolute; bottom: 1.4rem; left: 50%; transform: translateX(-50%); z-index: 2; font-size: 1.5rem; color: #fff; text-decoration: none; animation: flutua 2.2s ease-in-out infinite; }
@keyframes flutua { 0%,100%{ transform: translate(-50%,0);} 50%{ transform: translate(-50%,8px);} }

/* ---------- Contagem regressiva ---------- */
.contagem { display: flex; gap: 1.8rem; justify-content: center; margin-top: 2.2rem; }
.contagem__item { text-align: center; min-width: 52px; }
.contagem__num { font-family: var(--serif); font-size: clamp(1.8rem, 5vw, 2.8rem); line-height: 1; font-variant-numeric: tabular-nums; }
.contagem__rot { font-size: .6rem; letter-spacing: .2em; text-transform: uppercase; margin-top: .35rem; opacity: .85; }

/* ============================================================
   CARTA (história)
   ============================================================ */
.historia-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.historia-col { text-align: left; }
.historia-titulo { font-size: clamp(2.2rem, 4.5vw, 3.3rem); color: var(--verde); line-height: 1.08; margin: .3rem 0; }
.historia-titulo em { font-style: italic; color: var(--dourado); }
.historia-regua { width: 64px; height: 1px; background: var(--dourado-claro); margin: 1.1rem 0 1.7rem; }
.carta { position: relative; }
.carta__texto { columns: 1; }
.carta__texto p {
  font-family: var(--serif); font-size: clamp(1.06rem, 1.5vw, 1.26rem);
  line-height: 1.9; color: var(--tinta); margin-bottom: 1rem; text-align: left;
}
.carta__texto p:first-child::first-letter {
  font-size: 3.4em; float: left; line-height: .82; padding: .04em .14em 0 0;
  color: var(--dourado); font-weight: 600; font-family: var(--serif);
}
.carta__fecho { margin-top: 2rem; text-align: left; }
.carta__despedida { display: block; font-family: var(--serif); font-style: italic; font-size: 1.2rem; color: var(--tinta-suave); }
.carta__assinatura { display: block; font-family: var(--serif); font-style: italic; font-size: clamp(1.7rem, 4vw, 2.3rem); color: var(--verde); margin-top: .3rem; }

/* ============================================================
   MOMENTOS (vídeo quadrado autoplay)
   ============================================================ */
.momentos-video {
  position: relative; width: 100%; max-width: 460px; margin: 0 auto; aspect-ratio: 1;
  border-radius: 18px; overflow: hidden; background: #000;
  box-shadow: 0 26px 60px rgba(47,50,46,.2); border: 1px solid rgba(201,169,120,.5);
}
.momentos-video video { width: 100%; height: 100%; object-fit: cover; display: block; }
.momentos-som {
  position: absolute; bottom: .8rem; right: .8rem; z-index: 2;
  width: 42px; height: 42px; border-radius: 50%; cursor: pointer;
  background: rgba(20,24,20,.4); border: 1px solid rgba(255,255,255,.6);
  color: #fff; font-size: 1rem; backdrop-filter: blur(4px); transition: background .25s ease;
}
.momentos-som:hover { background: rgba(176,141,87,.9); border-color: var(--dourado); }

/* ============================================================
   GALERIA (masonry)
   ============================================================ */
.galeria { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.galeria__item {
  margin: 0; aspect-ratio: 1; border-radius: 10px; overflow: hidden;
  cursor: pointer; position: relative; background: var(--marfim-2);
  transition: box-shadow .4s ease;
}
.galeria__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease, filter .45s ease; }
.galeria__item::after {
  content: "⤢"; position: absolute; top: 10px; right: 12px; color: #fff; opacity: 0; z-index: 2;
  font-size: 1rem; text-shadow: 0 1px 6px rgba(0,0,0,.5); transition: opacity .3s ease;
}
.galeria__item:hover { box-shadow: 0 16px 36px rgba(47,50,46,.24); z-index: 3; }
.galeria__item:hover img { transform: scale(1.12); filter: brightness(1.05) saturate(1.08); }
.galeria__item:hover::after { opacity: .95; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 120; display: none; align-items: center; justify-content: center;
  background: rgba(20,22,19,.92); padding: 3rem 1rem;
}
.lightbox.aberto { display: flex; }
.lightbox__img { max-width: 92vw; max-height: 86vh; border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,.6); animation: sobe .3s ease; }
.lightbox__fechar { position: absolute; top: 1rem; right: 1.4rem; background: none; border: 0; color: #fff; font-size: 2.4rem; cursor: pointer; line-height: 1; }
.lightbox__nav {
  position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.3);
  color: #fff; width: 52px; height: 52px; border-radius: 50%; font-size: 1.8rem; cursor: pointer; transition: background .25s ease;
}
.lightbox__nav:hover { background: rgba(176,141,87,.85); }
.lightbox__nav--ant { left: 1.2rem; }
.lightbox__nav--prox { right: 1.2rem; }

/* ============================================================
   EVENTO
   ============================================================ */
.convite-painel {
  position: relative; display: grid; grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: stretch; gap: 0; background: #fff; border-radius: 18px;
  border: 1px solid var(--linha); box-shadow: var(--sombra);
  padding: clamp(1.6rem, 4vw, 2.8rem) clamp(1rem, 3vw, 2rem); overflow: hidden;
}
.convite-painel::before {
  content: ""; position: absolute; inset: 9px; border: 1px solid rgba(176,141,87,.32);
  border-radius: 11px; pointer-events: none; z-index: 0;
}
.convite-col { position: relative; z-index: 1; text-align: center; padding: .6rem 1.2rem; display: flex; flex-direction: column; align-items: center; }
.convite-icone { width: 40px; height: 40px; color: var(--dourado); margin-bottom: .9rem; }
.convite-rot { font-size: .68rem; letter-spacing: .26em; text-transform: uppercase; color: var(--dourado); margin-bottom: .5rem; }
.convite-val { font-family: var(--serif); font-size: clamp(1.25rem, 2.3vw, 1.55rem); color: var(--verde); line-height: 1.2; }
.convite-sub { font-size: .86rem; color: var(--tinta-suave); margin-top: .35rem; line-height: 1.5; }
.convite-div { width: 1px; align-self: stretch; margin: .4rem 0; background: linear-gradient(180deg, transparent, var(--linha) 20%, var(--linha) 80%, transparent); }
.convite-col--link { text-decoration: none; color: inherit; border-radius: 12px; transition: background .2s ease; }
.convite-col--link:hover { background: rgba(176,141,87,.08); }
.convite-agenda { margin-top: .8rem; font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--dourado); }
.convite-col--link:hover .convite-agenda { text-decoration: underline; text-underline-offset: 3px; }
.nowrap { white-space: nowrap; }
.convite-btn {
  display: inline-flex; align-items: center; justify-content: center;
  margin-top: auto; width: 210px; max-width: 100%; min-height: 40px; box-sizing: border-box;
  font-family: var(--sans); font-size: .64rem; font-weight: 500; letter-spacing: .14em; line-height: 1.2;
  text-transform: uppercase; text-decoration: none; text-align: center; white-space: nowrap;
  color: var(--dourado); background: transparent; border: 1px solid var(--dourado-claro); border-radius: 999px;
  padding: .5rem 1rem; cursor: pointer; -webkit-appearance: none; appearance: none; transition: all .25s ease;
}
.convite-btn:hover { background: var(--dourado); color: #fff; border-color: var(--dourado); }
.convite-sub { min-height: 2.7em; }
.convite-col { justify-content: flex-start; }
.detalhes__acoes { text-align: center; margin-top: 2.4rem; display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   PRESENTES
   ============================================================ */
.presentes-intro { max-width: 600px; margin: 0 auto 3rem; text-align: center; color: var(--tinta-suave); }
.presentes { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px,1fr)); gap: 1.4rem; }
.presente { background: #fff; border: 1px solid var(--linha); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; transition: all .25s ease; }
.presente:hover { transform: translateY(-4px); box-shadow: var(--sombra); border-color: var(--dourado-claro); }
.presente__foto { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; overflow: hidden; background: var(--marfim); border-bottom: 1px solid var(--linha); }
.presente__foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.presente:hover .presente__foto img { transform: scale(1.05); }
.presente__foto--vazia { background: linear-gradient(150deg, var(--marfim), var(--creme)); }
.presente__foto--vazia span { font-size: 3.4rem; opacity: .85; }
.presente__corpo { padding: 1.2rem 1.1rem 1.4rem; text-align: center; display: flex; flex-direction: column; align-items: center; gap: .5rem; flex: 1; }
.presente__nome { font-family: var(--serif); font-size: 1.18rem; color: var(--verde); line-height: 1.2; min-height: 2.3em; display: flex; align-items: center; }
.presente__preco { font-family: var(--serif); font-size: 1.4rem; color: var(--dourado); font-weight: 600; }
.presente__comprar { width: 100%; margin-top: auto; }

/* ---------- Modal PIX ---------- */
.modal { position: fixed; inset: 0; z-index: 130; display: none; align-items: center; justify-content: center; padding: 1.2rem; }
.modal.aberto { display: flex; }
.modal__fundo { position: absolute; inset: 0; background: rgba(47,50,46,.55); backdrop-filter: blur(4px); }
.modal__caixa { position: relative; background: var(--creme); border-radius: 20px; max-width: 420px; width: 100%; padding: 2.4rem 2rem; text-align: center; box-shadow: var(--sombra); max-height: 92vh; overflow-y: auto; animation: sobe .3s ease; }
@keyframes sobe { from { opacity: 0; transform: translateY(20px);} to { opacity:1; transform: translateY(0);} }
.modal__fechar { position: absolute; top: .8rem; right: 1rem; background: none; border: 0; font-size: 1.6rem; color: var(--tinta-suave); cursor: pointer; line-height: 1; }
.modal__icone { font-size: 2.6rem; }
.modal__titulo { font-size: 1.7rem; color: var(--verde); margin: .3rem 0; }
.modal__valor { font-family: var(--serif); font-size: 2rem; color: var(--dourado); font-weight: 600; margin-bottom: .4rem; }
.modal__passo { font-size: .82rem; color: var(--tinta-suave); margin-bottom: 1.2rem; }
.modal__qr { display: flex; justify-content: center; margin: 1rem auto 1.2rem; }
.modal__qr > div, .modal__qr canvas, .modal__qr img { border-radius: 12px; border: 1px solid var(--linha); padding: 10px; background:#fff; }
.modal__codigo { font-family: "Courier New", monospace; font-size: .68rem; word-break: break-all; background: var(--marfim); border: 1px dashed var(--dourado-claro); border-radius: 10px; padding: .8rem; color: var(--tinta-suave); margin-bottom: 1rem; max-height: 92px; overflow-y: auto; }
.modal__valor-input { display: none; margin-bottom: 1rem; }
.modal__valor-input label { font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--tinta-suave); display: block; margin-bottom: .4rem; }
.modal__valor-input input { width: 100%; font-family: var(--serif); font-size: 1.4rem; text-align: center; border: 1px solid var(--linha); border-radius: 10px; padding: .5rem; color: var(--verde); }
.modal__acoes { display: flex; flex-direction: column; gap: .6rem; }
.modal__aviso { font-size: .72rem; color: var(--tinta-suave); margin-top: 1rem; }
.modal__recado { display: block; margin-top: .6rem; font-size: .82rem; color: var(--verde); text-decoration: underline; text-underline-offset: 3px; }
.modal__recado:hover { color: var(--dourado); }

/* ============================================================
   RSVP
   ============================================================ */
.rsvp { text-align: center; }
.rsvp__titulo { color: var(--verde); font-size: clamp(2rem,5vw,3rem); }
.rsvp p { max-width: 520px; margin: 0 auto 1.6rem; color: var(--tinta-suave); }
.rsvp__prazo { font-family: var(--serif); font-style: italic; color: var(--dourado); }
.rsvp__passo2 {
  max-width: 480px; margin: 1.4rem auto 0; padding: 2rem 1.6rem;
  background: var(--creme); border: 1px solid var(--linha); border-radius: 16px;
  box-shadow: var(--sombra); animation: sobe .4s ease;
  display: flex; flex-direction: column; align-items: center; gap: 1rem;
}
.rsvp__ok { font-size: 2.4rem; }
.rsvp__ok-txt { margin: 0 !important; color: var(--tinta) !important; font-size: .98rem; }
.rsvp__link { font-size: .82rem; color: var(--tinta-suave); text-decoration: underline; text-underline-offset: 3px; }
.rsvp__link:hover { color: var(--verde); }

/* ============================================================
   RODAPÉ
   ============================================================ */
.rodape { background: var(--verde); color: #f0ebe0; text-align: center; padding: 3.5rem 1.5rem; }
.rodape__nomes { font-family: var(--serif); font-size: 2rem; margin-bottom: .4rem; }
.rodape__nomes .e { font-style: italic; color: var(--dourado-claro); }
.rodape__hash { font-size: .78rem; letter-spacing: .2em; text-transform: uppercase; color: var(--dourado-claro); margin: .6rem 0 1.4rem; }
.rodape small { font-size: .72rem; opacity: .7; letter-spacing: .08em; }

/* ---------- Toast ---------- */
.toast { position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%) translateY(120%); background: var(--verde); color: #fff; padding: .8rem 1.5rem; border-radius: 999px; font-size: .8rem; z-index: 200; transition: transform .35s ease; box-shadow: var(--sombra); }
.toast.mostra { transform: translateX(-50%) translateY(0); }

/* ---------- Revelar ao rolar ---------- */
.revelar { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.revelar.visivel { opacity: 1; transform: none; }
/* rede de segurança: força visibilidade se a animação não rodar */
.revelar.mostrar { opacity: 1 !important; transform: none !important; transition: none !important; }

/* ============================================================
   RESPONSIVO
   ============================================================ */
@media (max-width: 980px) {
  .galeria { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 760px) {
  .nav__links {
    position: fixed; inset: 0 0 0 auto; width: min(78vw, 300px);
    background: var(--creme); flex-direction: column; padding: 5rem 2rem; gap: 1.4rem;
    transform: translateX(100%); transition: transform .3s ease; box-shadow: var(--sombra);
  }
  .nav__links.aberto { transform: none; }
  .nav__links a { color: var(--tinta); }
  .nav__toggle { display: block; z-index: 60; }
  .contagem { gap: 1.1rem; }
  .galeria { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .lightbox__nav { width: 42px; height: 42px; }
  .historia-grid { grid-template-columns: 1fr; }
  .momentos-video { max-width: 380px; }
  .convite-painel { grid-template-columns: 1fr; padding: 1.8rem 1.4rem; }
  .convite-col { padding: 1.3rem .5rem; }
  .convite-div { width: auto; height: 1px; margin: 0 1.5rem; background: linear-gradient(90deg, transparent, var(--linha) 20%, var(--linha) 80%, transparent); }
}

@media (prefers-reduced-motion: reduce) {
  .hero__img { animation: none; }
  .hero__scroll { animation: none; }
  * { scroll-behavior: auto; }
}
