/* =========================================================
   TEMPLATES BRIDAL CREATIVE · base comum
   Só o que funciona igual nos 5 templates (formulário, foto
   ampliada, aviso, botão de música). As cores e fontes vêm das
   variáveis que cada style.css define em :root:
   --ink --bg --accent --on-accent --line --f-serif --f-script
   ========================================================= */

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
/* site travado nas laterais: flores e ramos que saem da tela são cortados
   e a página não escorrega para os lados no celular (iPhone incluído) */
html, body { overflow-x: hidden; overflow-x: clip; overscroll-behavior-x: none; max-width: 100%; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; position: relative; -webkit-font-smoothing: antialiased; }
main, section, footer, header { max-width: 100vw; }
main > section, footer { overflow-x: clip; }
body.is-locked, body.menu-open { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p, figure, blockquote, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* revelar ao rolar (cada template pode trocar o movimento) */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity 1s cubic-bezier(.22,.7,.2,1) var(--d, 0s), transform 1.1s cubic-bezier(.22,.7,.2,1) var(--d, 0s); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- formulário ---------- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; text-align: left; }
.field label, .field legend { font-size: .78em; letter-spacing: .16em; text-transform: uppercase; opacity: .8; }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 14px; border: 1px solid var(--line); border-radius: var(--radius, 0);
  background: rgba(255,255,255,.65); font-size: 16px; line-height: 1.4; color: var(--ink);
  transition: border-color .2s, box-shadow .2s; -webkit-appearance: none; appearance: none;
}
.field select { background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 20px) 55%, calc(100% - 15px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 40px; }
.field textarea { resize: vertical; min-height: 96px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
.field .is-invalid, .field input.is-invalid { border-color: #b3261e; box-shadow: 0 0 0 3px rgba(179,38,30,.12); }
.field--sub { margin-left: 14px; padding-left: 14px; border-left: 1px solid var(--line); }
.field__count { font-size: .75em; opacity: .6; text-align: right; }
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; border: 0; padding: 0; margin: 0 0 18px; }
.choice legend { grid-column: 1 / -1; margin-bottom: 8px; font-size: .78em; letter-spacing: .16em; text-transform: uppercase; opacity: .8; }
.choice label { position: relative; display: flex; align-items: center; justify-content: center; min-height: 48px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius, 0); cursor: pointer; text-align: center; line-height: 1.25; transition: background .2s, color .2s, border-color .2s; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice input:checked + span { font-weight: 600; }
.choice label:has(input:checked) { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.choice label:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.form__error { min-height: 1.2em; margin: 0 0 12px; color: #b3261e; font-size: .9em; text-align: center; }
.btn.is-loading { pointer-events: none; opacity: .75; }
.btn.is-loading span::after { content: ''; display: inline-block; width: .9em; height: .9em; margin-left: .6em; vertical-align: -.12em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: girar .8s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }

/* ---------- mural: recadinhos (como nos sites da Yasmin e da Gi) ----------
   Cartõezinhos de papel com um selo no topo, levemente tortos, passando
   sozinhos para o lado. Sem barra de rolagem aparente.
   Cada template pode trocar a cor do selo com --selo e o papel com --recado. */
.notes {
  display: flex; gap: 18px; min-width: 0;
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-behavior: smooth;
  padding: 24px 6px 26px; scrollbar-width: none; -ms-overflow-style: none;
}
.notes::-webkit-scrollbar { display: none; }
.notes__empty { flex: 1 0 100%; padding: 40px 0; opacity: .7; font-style: italic; text-align: center; }
.note {
  position: relative; flex: 0 0 clamp(190px, 58vw, 230px); scroll-snap-align: start;
  margin: 0; padding: 30px 18px 16px;
  background: var(--recado, #FFFDF8); border: 1px solid var(--line);
  box-shadow: 0 10px 24px -16px rgba(0, 0, 0, .45);
  transform: rotate(var(--r, 0deg)); text-align: center;
}
.note::before {
  content: ''; position: absolute; left: 50%; top: -13px; width: 28px; height: 28px; margin-left: -14px;
  border-radius: 48% 52% 50% 50%;
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--selo, var(--accent)) 60%, #fff) 0%, var(--selo, var(--accent)) 48%, color-mix(in srgb, var(--selo, var(--accent)) 60%, #000) 100%);
  box-shadow: 0 2px 4px rgba(0, 0, 0, .35), inset 0 -2px 3px rgba(0, 0, 0, .3), inset 0 2px 2px rgba(255, 255, 255, .25);
}
.note blockquote { margin: 0; font-size: .9em; line-height: 1.6; overflow-wrap: anywhere; }
.note figcaption { margin-top: 10px; line-height: 1.3; }
.note.is-new { animation: recadoNovo .8s cubic-bezier(.22,.7,.2,1); }
@keyframes recadoNovo { from { opacity: 0; transform: translateY(-14px) rotate(0); } }
/* computador: 6 recados por vez (2 linhas × 3 colunas), passando coluna a coluna */
@media (min-width: 900px) {
  .notes { display: grid; grid-template-rows: repeat(2, auto); grid-auto-flow: column; grid-auto-columns: calc((100% - 2 * 18px) / 3); gap: 30px 18px; align-items: start; }
  .notes__empty { grid-column: span 3; grid-row: span 2; }
}

/* ---------- foto ampliada ---------- */
.lightbox { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 56px 12px; background: rgba(12, 10, 10, .92); }
.lightbox figure { max-width: min(1100px, 100%); max-height: 100%; }
.lightbox img { max-height: calc(var(--app-h, 100vh) - 120px); width: auto; margin: auto; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.lightbox button { position: absolute; display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; font-size: 26px; line-height: 1; cursor: pointer; }
.lightbox button:hover { background: rgba(255,255,255,.22); }
.lightbox__close { top: 12px; right: 12px; }
.lightbox__nav--prev { left: 10px; top: 50%; transform: translateY(-50%); }
.lightbox__nav--next { right: 10px; top: 50%; transform: translateY(-50%); }

/* ---------- aviso ---------- */
.toast { position: fixed; left: 50%; bottom: 92px; z-index: 210; transform: translateX(-50%); max-width: calc(100% - 32px); padding: 12px 20px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 14px; text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,.25); animation: toastIn .35s ease; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 10px); } }

/* ---------- música ---------- */
[data-divisor].is-solto { display: none !important; }
.music { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 150; display: grid; place-items: center; width: 50px; height: 50px; border: 1px solid color-mix(in srgb, var(--on-accent) 35%, transparent); border-radius: 50%; background: var(--accent); color: var(--on-accent); cursor: pointer; box-shadow: 0 8px 22px rgba(0,0,0,.22); opacity: 0; pointer-events: none; transition: opacity .6s, transform .2s; }
.is-revealed .music { opacity: 1; pointer-events: auto; }
.music:hover { transform: scale(1.06); }
.music svg { width: 22px; height: 22px; }
.music__bars { display: none; align-items: flex-end; gap: 3px; height: 18px; }
.music__bars i { width: 3px; height: 40%; background: currentColor; border-radius: 2px; animation: barra 1s ease-in-out infinite; }
.music__bars i:nth-child(2) { animation-delay: -.3s; } .music__bars i:nth-child(3) { animation-delay: -.6s; } .music__bars i:nth-child(4) { animation-delay: -.15s; }
.music.is-playing svg { display: none; }
.music.is-playing .music__bars { display: flex; }
@keyframes barra { 0%, 100% { height: 30%; } 50% { height: 100%; } }
.yt { position: fixed; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; left: -10px; bottom: 0; }

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

/* ---------- lista de presentes no site (cartões + janela do Pix com o valor) ----------
   Cartões em papel claro, com as cores da coleção (--ink, --accent, --recado, --line).
   --pl-raio-btn: arredondado do botão (cada style.css pode trocar). */
/* fica dentro da caixa estreita da seção e sai dela para os lados (centralizada na caixa) */
.presentes-lista { position: relative; z-index: 2; align-self: flex-start; width: min(1060px, calc(100vw - 32px)); margin: clamp(30px, 4vw, 48px) 0 8px 50%; transform: translateX(-50%); text-align: center; }
.presentes-lista__aviso { margin: 0 auto 18px; font-size: 14px; font-style: italic; opacity: .85; }
.presentes-lista__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: clamp(14px, 2vw, 22px); text-align: left; }
.pl-card { position: relative; display: flex; flex-direction: column; overflow: hidden; background: var(--recado, #fff); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius, 0); box-shadow: 0 14px 34px -22px rgba(0, 0, 0, .45); }
.pl-tag { position: absolute; top: 10px; left: 10px; z-index: 1; padding: 3px 10px; border-radius: 999px; background: var(--ink); color: var(--recado, #fff); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; }
.pl-foto { aspect-ratio: 4 / 3; display: grid; place-items: center; overflow: hidden; background: color-mix(in srgb, var(--accent, var(--ink)) 7%, var(--recado, #fff)); border-bottom: 1px solid var(--line); }
.pl-foto img { width: 100%; height: 100%; object-fit: cover; }
.pl-foto img.pl-mono { width: 46%; height: auto; max-height: 70%; object-fit: contain; opacity: .55; }
.pl-corpo { display: flex; flex-direction: column; flex: 1; gap: 6px; padding: 16px 18px 18px; }
.pl-nome { font-family: var(--serif, var(--f-serif, inherit)); font-size: 19px; font-weight: 500; line-height: 1.25; letter-spacing: 0; text-transform: none; color: var(--ink); }
.pl-texto { font-size: 14px; line-height: 1.5; opacity: .8; }
.pl-valor { margin-top: auto; padding-top: 6px; font-family: var(--serif, var(--f-serif, inherit)); font-size: 21px; color: var(--accent, var(--ink)); }
.pl-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; margin-top: 8px; padding: 11px 20px; border: 1px solid var(--accent, var(--ink)); border-radius: var(--pl-raio-btn, 0); background: var(--accent, var(--ink)); color: var(--on-accent, #fff); font-size: 11.5px; font-weight: 600; line-height: 1.2; letter-spacing: .18em; text-transform: uppercase; cursor: pointer; transition: background .25s, color .25s, transform .25s; }
.pl-btn:hover { background: transparent; color: var(--accent, var(--ink)); }
.pl-btn:active { transform: scale(.98); }

.pl-modal { position: fixed; inset: 0; z-index: 205; display: grid; place-items: center; padding: 16px; overflow-y: auto; background: rgba(12, 10, 10, .72); animation: plFundo .3s ease; }
.pl-caixa { position: relative; width: min(420px, 100%); margin: auto; padding: 34px clamp(20px, 5vw, 34px) 28px; background: var(--recado, #fff); color: var(--ink); border-radius: var(--radius, 0); text-align: center; box-shadow: 0 30px 80px rgba(0, 0, 0, .4); animation: plCaixa .4s cubic-bezier(.22, .7, .2, 1); }
.pl-fechar { position: absolute; top: 8px; right: 8px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent; color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; }
.pl-fechar:hover { background: color-mix(in srgb, var(--ink) 8%, transparent); }
.pl-kicker { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; opacity: .75; }
.pl-titulo { margin-top: 10px; font-family: var(--serif, var(--f-serif, inherit)); font-size: clamp(22px, 5vw, 26px); font-weight: 500; line-height: 1.2; color: var(--ink); }
.pl-caixa .pl-valor { margin: 6px 0 14px; padding: 0; font-size: 26px; }
.pl-btn--copiar { width: 100%; margin: 0; }
.pl-qr { display: grid; place-items: center; width: min(220px, 70%); aspect-ratio: 1; margin: 18px auto 6px; padding: 8px; background: #fff; border: 1px solid var(--line); }
.pl-qr svg { width: 100%; height: 100%; display: block; }
.pl-qr__carregando { font-size: 13px; opacity: .7; }
.pl-passos { margin: 14px 0 0; padding: 0; counter-reset: pl; text-align: left; font-size: 14px; line-height: 1.5; }
.pl-passos li { position: relative; padding-left: 28px; counter-increment: pl; }
.pl-passos li + li { margin-top: 6px; }
.pl-passos li::before { content: counter(pl); position: absolute; left: 0; top: 1px; display: grid; place-items: center; width: 19px; height: 19px; border-radius: 50%; background: var(--accent, var(--ink)); color: var(--on-accent, #fff); font-size: 11px; font-weight: 600; }
.pl-nota { margin-top: 14px; font-size: 13px; opacity: .75; }
.pl-recado { display: inline-block; margin-top: 12px; font-size: 14px; color: var(--accent, var(--ink)); text-underline-offset: 3px; }
@keyframes plFundo { from { opacity: 0; } }
@keyframes plCaixa { from { opacity: 0; transform: translateY(18px) scale(.98); } }
/* no computador o QR vem primeiro (lê com o celular); no celular, o copiar */
@media (min-width: 900px) { .pl-caixa { display: flex; flex-direction: column; } .pl-qr { order: 3; } .pl-btn--copiar { order: 4; } .pl-passos { order: 5; } .pl-nota { order: 6; } .pl-recado { order: 7; align-self: center; } .pl-qr { margin-top: 4px; margin-bottom: 16px; } }
@media (max-width: 520px) { .presentes-lista__grid { grid-template-columns: 1fr 1fr; gap: 12px; } .pl-corpo { padding: 12px 12px 14px; } .pl-nome { font-size: 16px; } .pl-texto { display: none; } .pl-valor { font-size: 18px; } .pl-btn { padding: 10px 8px; letter-spacing: .12em; font-size: 10.5px; } }
@media (prefers-reduced-motion: reduce) { .pl-modal, .pl-caixa { animation: none; } }
/* formulário do presente pago pelo app (Asaas): nome, CPF, recado e forma de pagamento */
.pl-form { display: grid; gap: 10px; margin-top: 4px; text-align: left; }
.pl-campo { display: grid; gap: 4px; font-size: 13px; }
.pl-campo small { opacity: .65; font-size: 11.5px; }
.pl-campo input, .pl-campo textarea, .pl-campo select { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius, 0); background: #fff; color: var(--ink); font-size: 15px; }
.pl-campo textarea { resize: vertical; min-height: 56px; }
.pl-formas { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 2px 0 0; padding: 0; border: 0; font-size: 14px; }
.pl-formas legend { width: 100%; margin-bottom: 6px; padding: 0; font-size: 13px; }
.pl-formas label { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.pl-formas input { accent-color: var(--accent, var(--ink)); width: 17px; height: 17px; }
.pl-erro { padding: 8px 10px; background: #fdecec; color: #8a1c1c; font-size: 13px; border-radius: var(--radius, 0); }
.pl-form .pl-nota { margin-top: 2px; text-align: center; }
.pl-qr img { width: 100%; height: 100%; object-fit: contain; }
.pl-aguardando { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 14px; font-size: 13px; opacity: .8; }
.pl-pulso { width: 9px; height: 9px; border-radius: 50%; background: var(--accent, var(--ink)); animation: plPulso 1.2s ease-in-out infinite; }
@keyframes plPulso { 50% { opacity: .25; transform: scale(.7); } }
/* página Presentes (presentes.html): filtros por categoria e a categoria no cartão */
.presentes-pg__intro { max-width: 560px; margin: 4px auto 0; text-align: center; }
.presentes-pg .presentes-lista { margin-top: clamp(22px, 3vw, 34px); }
.presentes-pg__pix { max-width: 420px; margin: clamp(28px, 4vw, 44px) auto 0; text-align: center; }
.pl-filtros { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 auto clamp(18px, 2.5vw, 28px); }
.pl-filtro { padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--recado, #fff); color: var(--ink); font-size: 13px; line-height: 1.2; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.pl-filtro:hover { border-color: var(--accent, var(--ink)); }
.pl-filtro.is-ativo { background: var(--accent, var(--ink)); border-color: var(--accent, var(--ink)); color: var(--on-accent, #fff); }
.pl-cat { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; opacity: .6; }
.presentes__loja { display: inline-block; margin-top: 10px; font-size: 14px; text-underline-offset: 3px; }
@media (max-width: 520px) { .pl-filtros { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; margin-left: -4px; margin-right: -4px; padding: 0 4px 4px; scrollbar-width: none; } .pl-filtro { flex: none; } .pl-cat { font-size: 9.5px; } }
/* janela do presente: laterais travadas (nada arrasta para os lados, nem a página atrás no iPhone) */
.pl-modal { overflow-x: hidden; overscroll-behavior: contain; }
.pl-caixa { max-width: 100%; overflow-wrap: anywhere; }
html:has(body.menu-open) { overflow: hidden; }
.presentes-pg .titulo, .presentes-pg .head { max-width: 100%; overflow-wrap: anywhere; }
/* cartões de presente mais compactos (pedido da Fer): mais por linha, foto e textos menores */
.presentes-lista { width: min(980px, calc(100vw - 32px)); }
.presentes-lista__grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 176px), 1fr)); gap: 14px; }
.pl-foto { aspect-ratio: 1 / 1; }
.pl-foto img.pl-mono { width: 42%; }
.pl-corpo { gap: 4px; padding: 11px 12px 13px; }
.pl-nome { font-size: 15.5px; line-height: 1.25; }
.pl-texto { font-size: 12.5px; line-height: 1.4; }
.pl-valor { padding-top: 4px; font-size: 16.5px; }
.pl-btn { min-height: 36px; margin-top: 6px; padding: 8px 12px; font-size: 10.5px; letter-spacing: .16em; }
.pl-cat { font-size: 9.5px; }
.pl-tag { top: 8px; left: 8px; padding: 2px 8px; font-size: 9.5px; }
@media (max-width: 520px) { .presentes-lista__grid { gap: 10px; } .pl-corpo { padding: 9px 10px 11px; } .pl-nome { font-size: 14px; } .pl-valor { font-size: 15px; } .pl-btn { min-height: 34px; padding: 8px 6px; font-size: 10px; letter-spacing: .1em; } }

/* selo do Asaas na janela de pagamento (modelo BaaS: o convidado vê quem processa o pagamento) */
.pl-selo { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 11px; line-height: 1.45; opacity: .85; text-align: center; }
.pl-selo img { display: inline-block; width: 120px; height: auto; }
