:root {
  /* Paleta do brasão J&S (vinho #5E0C10). Os nomes das variáveis foram mantidos
     para não mexer no resto do código. */
  --sage: #a8676a;
  --sage-dark: #5e0c10;
  --cream: #fbf9f3;
  --cream-dark: #efeae0;
  --ink: #3a3a32;
  --font-script: 'Alex Brush', cursive;
  --font-heading: 'Cormorant Garamond', serif;
  --font-body: 'Jost', sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  min-height: 100%;
}

#app { width: 100%; }

.script { font-family: var(--font-script); }

.section-title {
  display: block;
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 600;
  color: var(--sage-dark);
  margin-bottom: 0.5rem;
}

.section-subtitle {
  display: block;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
  color: var(--ink);
  font-size: 0.98rem;
}

.edit-field {
  width: 100%;
  background: #fff;
  border: 1.5px dashed var(--sage);
  border-radius: 6px;
  padding: 8px 10px;
  font-family: inherit;
  color: inherit;
  font-size: inherit;
  outline: none;
}
.edit-field:focus { border-style: solid; }

.wedding-section { padding: 4.5rem 1.25rem; }
@media (min-width: 768px) { .wedding-section { padding: 6rem 2rem; } }

.card {
  background: #fff;
  border: 1px solid var(--cream-dark);
  border-radius: 10px;
}

.btn-primary {
  background: var(--sage-dark);
  color: #fff;
  border-radius: 999px;
  padding: 0.7rem 1.6rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: opacity 0.15s;
  border: none;
  cursor: pointer;
}
.btn-primary:hover { opacity: 0.85; }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-outline {
  border: 1.5px solid var(--sage);
  color: var(--sage-dark);
  border-radius: 999px;
  padding: 0.65rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  background: transparent;
  cursor: pointer;
  display: inline-block;
  text-decoration: none;
}
.btn-outline:disabled { opacity: 0.5; cursor: not-allowed; }

input.plain, select.plain, textarea.plain {
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.92rem;
  background: #fff;
  outline: none;
}
input.plain:focus, textarea.plain:focus { border-color: var(--sage); }

.image-slot {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  cursor: pointer;
  background: var(--cream-dark);
}
.image-slot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.image-slot .placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; border: 1px dashed var(--sage);
}
.image-slot .placeholder span {
  font-size: 0.75rem; padding: 0 1rem; text-align: center; color: var(--sage-dark);
  font-family: var(--font-body);
}
.image-slot .overlay {
  position: absolute; inset: 0; display: flex; align-items: flex-end; justify-content: center;
  padding-bottom: 12px; transition: opacity 0.15s;
}
.image-slot .overlay .pill {
  display: flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  font-size: 0.75rem; background: var(--sage-dark); color: #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}
.image-slot:hover .overlay { opacity: 1; }

.aspect-4-5 { aspect-ratio: 4 / 5; }
.aspect-square { aspect-ratio: 1 / 1; }
.aspect-16-6 { aspect-ratio: 16 / 6; }

.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,249,243,0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--cream-dark);
}

.eyebrow-line { height: 1px; width: 2rem; background: var(--sage); }

.countdown-box {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 64px; height: 64px; border-radius: 8px;
}
@media (min-width: 768px) { .countdown-box { width: 80px; height: 80px; } }

.hero-upload-btn {
  position: absolute; top: 12px; right: 12px; z-index: 20;
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px; font-size: 0.75rem;
  color: #fff; border: none; cursor: pointer; box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  font-family: var(--font-body);
}

.color-swatch {
  width: 36px; height: 36px; border-radius: 999px; border: 1px solid var(--cream-dark);
  display: inline-block;
}

.fade-in { animation: fadeIn .4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px);} to { opacity: 1; transform: translateY(0);} }

[data-lucide] { display: inline-block; vertical-align: middle; }

.music-panel {
  border-top: 1px dashed var(--cream-dark);
  background: rgba(94,12,16,0.05);
}

.login-overlay {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(58,58,50,0.55);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.login-modal {
  position: relative;
  background: var(--cream);
  border-radius: 14px;
  padding: 2rem 1.75rem;
  max-width: 360px;
  width: 100%;
  box-shadow: 0 10px 40px rgba(0,0,0,0.25);
}
.login-close {
  position: absolute; top: 10px; right: 10px;
  background: none; border: none; cursor: pointer; color: var(--sage-dark);
  padding: 4px;
}

.brasao-hero { width: 170px; height: 170px; object-fit: contain; display: block; margin: 0 auto; }
@media (min-width: 768px) { .brasao-hero { width: 210px; height: 210px; } }
.brasao-topbar { width: 34px; height: 34px; object-fit: contain; display: block; }
.nomes-hero { width: min(82vw, 440px); height: auto; display: block; margin: 0 auto; }
@media (min-width: 768px) { .nomes-hero { width: 520px; } }

/* ---------- Enviar convite (painel do administrador) ---------- */
.invite-modal {
  width: min(94vw, 680px);
  max-width: none;
  max-height: 90vh;
  overflow-y: auto;
  text-align: left;
}
.inv-block { padding: 14px 0; border-top: 1px solid var(--cream-dark); }
.inv-h { font-family: var(--font-heading); font-size: 1.15rem; font-weight: 600; color: var(--sage-dark); margin: 0 0 4px; }
.inv-help { font-size: .8rem; opacity: .75; margin: 0 0 10px; line-height: 1.45; }
.inv-btn { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; padding: .45rem .9rem; white-space: nowrap; text-decoration: none; }
.inv-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.inv-row {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between;
  padding: 12px; border: 1px solid var(--cream-dark); border-radius: 12px; background: #fff;
}
.inv-row-info { min-width: 11rem; flex: 1 1 12rem; }
.inv-name { font-weight: 500; margin: 0; color: var(--ink); }
.inv-meta { font-size: .78rem; opacity: .7; margin: 2px 0 6px; }
.inv-chip { display: inline-block; font-size: .7rem; padding: 2px 9px; border-radius: 999px; background: var(--cream-dark); color: var(--ink); }
.inv-chip-sent { background: rgba(168, 103, 106, .16); color: var(--sage-dark); }
.inv-chip-open { background: var(--sage-dark); color: #fff; }
.inv-row-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.inv-remove { background: none; border: none; cursor: pointer; color: var(--sage-dark); opacity: .6; padding: 6px; border-radius: 8px; }
.inv-remove:hover, .inv-remove:focus-visible { opacity: 1; background: var(--cream-dark); }
.inv-notice { font-size: .8rem; text-align: center; padding: 8px 12px; border-radius: 10px; background: rgba(94, 12, 16, .07); color: var(--sage-dark); margin: 0 0 6px; }
.inv-notice-err { background: #fdecec; color: #9b1c1c; }
