/* ===== Fontes (hospedadas no site, subconjunto latin, eixo de peso variável) ===== */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("assets/fonts/cormorant-garamond-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 300 500;
  font-display: swap;
  src: url("assets/fonts/jost-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Pinyon Script";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/pinyon-script-latin.woff2") format("woff2");
}

/* ===== Base ===== */
:root {
  --cream: #faf7f0;
  --cream-alt: #f2efe4;
  --ink: #3d4a3a;
  --green: #7d8f69;
  --green-dark: #5c6e4d;
  --gold: #c2a878;
  --white: #fffdf8;
  --shadow: 0 10px 30px rgba(61, 74, 58, 0.12);
  --font-script: "Pinyon Script", cursive;
  --font-serif: "Cormorant Garamond", serif;
  --font-body: "Jost", sans-serif;
  /* grão de papel sutil (ruído SVG inline) para os fundos sólidos */
  --paper: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='320' height='320'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.28' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.30 0 0 0 0 0.33 0 0 0 0 0.24 0 0 0 0.11 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--ink);
  background: var(--cream);
  background-image: var(--paper);
  line-height: 1.7;
}

img { max-width: 100%; display: block; }

/* ===== Nav ===== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(250, 247, 240, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(125, 143, 105, 0.15);
}

.nav__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__brand {
  display: block;
  color: var(--ink);
  line-height: 0;
}

/* vetor "Juliana & Yan" extraído do convite */
.nav__brand-svg {
  width: 170px;
  height: auto;
  overflow: visible;
}

.nav__links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav__links a {
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.2s;
}

.nav__links a:hover { color: var(--green); }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.nav__toggle span {
  width: 24px; height: 2px;
  background: var(--green-dark);
  transition: transform 0.25s, opacity 0.25s;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: url("assets/hero.webp") center 65% / cover no-repeat;
}

/* celular: recorte em retrato, bem mais leve */
@media (max-width: 700px) {
  .hero { background-image: url("assets/hero-mobile.webp"); }
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(250, 247, 240, 0.55) 0%,
    rgba(250, 247, 240, 0.15) 40%,
    rgba(250, 247, 240, 0) 70%
  );
}

/* dissolve suave da grama para a seção seguinte */
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 38%;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(255, 253, 248, 0) 0%,
    rgba(255, 253, 248, 0.35) 45%,
    rgba(255, 253, 248, 0.8) 75%,
    var(--white) 100%
  );
}

.hero__content {
  position: relative;
  z-index: 1;
  padding: 0 1.5rem;
  transform: translateY(-10vh);
}

.hero__script {
  font-family: var(--font-script);
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--green-dark);
}

.hero__names {
  margin: 0.8rem auto 1.4rem;
  width: min(720px, 88vw);
  color: var(--ink);
  line-height: 0;
}

/* vetor "Juliana & Yan" extraído do convite (20260830_Invitations.pdf) */
.hero__names-svg {
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 0 10px rgba(255, 253, 248, 0.9)) drop-shadow(0 0 22px rgba(255, 253, 248, 0.7));
}

.hero__date {
  margin-top: 0.6rem;
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  font-weight: 500;
  letter-spacing: 0.5em;
  text-indent: 0.5em;
  color: var(--green-dark);
  text-shadow: 0 0 8px rgba(255, 253, 248, 0.95), 0 0 18px rgba(255, 253, 248, 0.9),
    0 0 32px rgba(255, 253, 248, 0.8);
}

/* ===== Countdown ===== */
.countdown-section {
  text-align: center;
  padding: 4.5rem 1.5rem;
  background: var(--white);
  background-image: var(--paper);
}

.section-script {
  font-family: var(--font-script);
  font-size: 2rem;
  color: var(--gold);
}

.countdown {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: clamp(0.6rem, 3vw, 1.8rem);
  margin: 1.8rem 0 2.2rem;
}

.countdown__item {
  display: flex;
  flex-direction: column;
  min-width: clamp(64px, 14vw, 110px);
  padding: 1rem 0.5rem;
  background: var(--cream);
  border: 1px solid rgba(125, 143, 105, 0.25);
  border-radius: 10px;
}

.countdown__item span {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 6vw, 3.2rem);
  font-weight: 500;
  color: var(--green-dark);
  line-height: 1.1;
}

.countdown__item small {
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
}

.countdown__sep {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  color: var(--gold);
  padding-top: 1rem;
}

.countdown-section__when {
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  font-weight: 600;
  color: var(--green-dark);
  letter-spacing: 0.02em;
}

.countdown-section__time {
  display: block;
  margin-top: 0.25rem;
  font-size: clamp(2.2rem, 5.5vw, 3.2rem);
  line-height: 1.1;
  color: var(--gold);
}

.countdown-section__hint {
  max-width: 520px;
  margin: 0.8rem auto 0;
  font-size: 0.95rem;
  color: rgba(61, 74, 58, 0.75);
}

/* ===== Buttons ===== */
.btn-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.8rem;
  margin-top: 1.6rem;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.8rem;
  background: var(--green);
  color: var(--white);
  border: 1px solid var(--green);
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, transform 0.15s;
}

.btn:hover { background: var(--green-dark); border-color: var(--green-dark); transform: translateY(-1px); }

.btn--ghost { background: transparent; color: var(--green-dark); }

.btn--ghost:hover { background: var(--green); color: var(--white); }

/* ===== Sections ===== */
.section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 1.5rem;
  text-align: center;
}

.section--alt {
  max-width: none;
  background: var(--cream-alt);
  background-image: var(--paper);
}

.section--alt > * { max-width: 1100px; margin-left: auto; margin-right: auto; }

.section-title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5vw, 3rem);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section-divider {
  width: 70px;
  height: 2px;
  margin: 1.2rem auto 2.8rem;
  background: var(--gold);
}

.section h3 {
  font-family: var(--font-serif);
  font-size: 1.7rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
}

/* ===== Local ===== */
.local__grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2.5rem;
  align-items: center;
  text-align: left;
}

.local__info .btn { margin-top: 1.4rem; }

.local__hint {
  margin-top: 1rem;
  font-size: 0.95rem;
  color: rgba(61, 74, 58, 0.75);
}

.local__map iframe {
  width: 100%;
  height: 340px;
  border: 0;
  border-radius: 14px;
  box-shadow: var(--shadow);
}

/* ===== Dress code ===== */
.dresscode__text {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.dresscode__lead {
  font-size: 1.15rem;
  color: var(--green-dark);
}

.casal__figure img {
  border-radius: 14px;
  box-shadow: var(--shadow);
  margin: 0 auto;
}

.dresscode__text p + p { margin-top: 1rem; }

.dresscode__note {
  font-style: italic;
  color: var(--green-dark);
}

/* ===== O casal ===== */
.casal__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  text-align: left;
}

.casal__figure img { max-height: 560px; width: auto; height: auto; }

.casal__text p + p { margin-top: 1rem; }

/* ===== RSVP ===== */
.rsvp__box {
  max-width: 560px;
  margin: 0 auto;
  padding: 2.5rem 2rem;
  background: var(--white);
  border: 1px solid rgba(125, 143, 105, 0.25);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.rsvp__soon {
  font-family: var(--font-script);
  font-size: 2.4rem;
  color: var(--green);
  margin-bottom: 0.6rem;
}

.rsvp__btn { margin-top: 1.4rem; }

/* ===== Presentes ===== */
.presentes__content {
  max-width: 640px;
  margin: 0 auto;
  font-size: 1.05rem;
}

.presentes__content p + p { margin-top: 1rem; }

.presentes__content h3 {
  margin: 2.8rem 0 0.6rem;
  font-family: var(--font-serif);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--green-dark);
}

.presentes__content .pix-card {
  max-width: 460px;
  margin: 1rem auto 0;
}

.link-fotos {
  margin-top: 0.8rem;
  padding: 0.2rem 0;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--gold);
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green-dark);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.link-fotos:hover { color: var(--gold); }

/* ===== Galeria (modal) ===== */
body.galeria-aberta { overflow: hidden; }

.galeria {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 3.8rem 4.5rem 3rem;
  border: 0;
  background: rgba(38, 46, 36, 0.95);
  color: var(--cream);
}

.galeria::backdrop { background: transparent; }

.galeria[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}

.galeria__titulo {
  position: absolute;
  top: 1.1rem;
  left: 4.5rem;
  right: 4.5rem;
  text-align: center;
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.3;
}

.galeria__figura {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.galeria__img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
  animation: galeria-fade 0.25s ease;
}

@keyframes galeria-fade { from { opacity: 0; } to { opacity: 1; } }

.galeria__fechar,
.galeria__nav {
  position: absolute;
  display: grid;
  place-items: center;
  width: 2.8rem;
  height: 2.8rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.14);
  color: var(--cream);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}

.galeria__fechar:hover,
.galeria__nav:hover { background: rgba(255, 253, 248, 0.3); }

.galeria__fechar:focus-visible,
.galeria__nav:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.galeria__fechar { top: 0.8rem; right: 0.8rem; }

.galeria__nav { top: 50%; transform: translateY(-50%); }
.galeria__nav--prev { left: 0.8rem; }
.galeria__nav--next { right: 0.8rem; }

.galeria__contador {
  position: absolute;
  bottom: 0.9rem;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.85rem;
  letter-spacing: 0.14em;
}

@media (max-width: 640px) {
  .galeria { padding: 3.8rem 0.5rem 4.5rem; }
  .galeria__titulo { font-size: 1.1rem; left: 3.8rem; right: 3.8rem; }
  .galeria__nav { top: auto; bottom: 0.6rem; transform: none; }
  .galeria__nav--prev { left: 1rem; }
  .galeria__nav--next { right: 1rem; }
  .galeria__contador { bottom: 1.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  .galeria__img { animation: none; }
}

.presentes__thanks {
  margin-top: 1.8rem;
  font-style: italic;
  color: var(--green-dark);
}

.pix-card {
  margin-top: 1.8rem;
  padding: 1.6rem;
  background: var(--white);
  border: 1px dashed var(--gold);
  border-radius: 14px;
  text-align: center;
}

.pix-card__qr {
  width: min(260px, 100%);
  height: auto;
  margin: 0 auto 0.4rem;
  border-radius: 8px;
}

.pix-card__hint {
  font-size: 0.85rem;
  margin-bottom: 1.2rem;
  color: rgba(61, 74, 58, 0.65);
}

.pix-card__label {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(61, 74, 58, 0.65);
}

.pix-card__key {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--green-dark);
  line-height: 1.3;
}

.pix-card__name { font-size: 0.95rem; margin-bottom: 1rem; }

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 3.5rem 1.5rem;
  background: var(--ink);
  color: rgba(255, 253, 248, 0.85);
  font-size: 0.9rem;
  letter-spacing: 0.08em;
}

.footer__names {
  margin: 0 auto 1rem;
  width: min(260px, 70vw);
  color: var(--white);
  line-height: 0;
}

.footer__names-svg { width: 100%; height: auto; overflow: visible; }

/* ===== Mobile ===== */
@media (max-width: 820px) {
  .nav__toggle { display: flex; }

  .nav__links {
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    align-items: center;
    gap: 0;
    background: rgba(250, 247, 240, 0.98);
    border-bottom: 1px solid rgba(125, 143, 105, 0.15);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .nav__links.open { max-height: 320px; }

  .nav__links li { width: 100%; text-align: center; }

  .nav__links a { display: block; padding: 0.9rem 0; }

  .nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle.open span:nth-child(2) { opacity: 0; }
  .nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .local__grid,
  .casal__grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }

  .local__grid { text-align: center; }

  .casal__figure img { max-height: 420px; }

  .section { padding: 3.5rem 1.25rem; }
}
