:root {
  --wine: #6f173f;
  --wine-dark: #46102b;
  --pink: #e54e7f;
  --blush: #fff1ec;
  --cream: #fffaf2;
  --ink: #2b1921;
  --muted: #77656c;
  --line: #eadbd7;
  --green: #2f7d62;
  --shadow: 0 22px 60px rgba(89, 27, 51, 0.12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: radial-gradient(circle at 12% 18%, #ffe4d9 0 7%, transparent 24%), var(--cream);
  font-family: "DM Sans", sans-serif;
}
button, input, textarea { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.grain { position: fixed; inset: 0; opacity: .035; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.topbar { width: min(1180px, calc(100% - 40px)); margin: auto; padding: 28px 0; display: flex; align-items: center; justify-content: space-between; }
.brand { color: var(--wine); text-decoration: none; display: flex; gap: 10px; align-items: center; font-family: "Fraunces", serif; font-weight: 800; font-size: 20px; }
.brand-mark, .seal { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: var(--wine); color: #fff6d8; font: 800 13px/1 "Fraunces", serif; box-shadow: inset 0 0 0 2px rgba(255,255,255,.25); }
.pill, .step-tag, .eyebrow, .mini-label { letter-spacing: .12em; text-transform: uppercase; font-weight: 700; font-size: 12px; }
.pill { color: var(--wine); background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 9px 14px; }
main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.home-view { min-height: 690px; display: grid; grid-template-columns: 1fr 480px; align-items: center; gap: 76px; padding: 30px 0 70px; }
.hero-copy { position: relative; }
.eyebrow { color: var(--pink); }
h1, h2 { font-family: "Fraunces", serif; margin: 0; }
.hero-copy h1 { font-size: clamp(52px, 6.8vw, 86px); line-height: .98; letter-spacing: -.055em; margin: 20px 0 26px; }
.hero-copy h1 em { color: var(--wine); font-style: italic; }
.hero-text { font-size: 19px; line-height: 1.6; color: var(--muted); max-width: 570px; }
.benefits { list-style: none; padding: 0; margin: 30px 0 0; display: grid; gap: 13px; }
.benefits li { display: flex; gap: 11px; align-items: center; font-weight: 600; }
.benefits span { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: white; background: var(--green); font-size: 13px; }
.candy { position: absolute; font-size: 36px; filter: drop-shadow(0 8px 8px rgba(70,16,43,.16)); animation: float 4s ease-in-out infinite; }
.candy-one { right: 5%; top: -10%; transform: rotate(12deg); }
.candy-two { left: -8%; bottom: -20%; animation-delay: -1s; }
.candy-three { right: 2%; bottom: -22%; animation-delay: -2s; }
@keyframes float { 50% { translate: 0 -10px; rotate: 5deg; } }
.card { background: rgba(255,255,255,.9); border: 1px solid rgba(111,23,63,.11); border-radius: 24px; box-shadow: var(--shadow); }
.create-card { padding: 32px; }
.step-tag { display: inline-block; background: var(--blush); color: var(--wine); border-radius: 999px; padding: 7px 10px; }
.create-card h2 { font-size: 32px; margin: 16px 0 6px; }
.create-card > p { color: var(--muted); margin: 0 0 24px; }
label { display: block; font-weight: 700; font-size: 14px; margin: 18px 0 8px; }
label span { color: var(--muted); font-weight: 400; }
input, textarea { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 13px 14px; background: #fffdfa; color: var(--ink); outline: none; transition: .2s; resize: vertical; }
input:focus, textarea:focus { border-color: var(--pink); box-shadow: 0 0 0 4px rgba(229,78,127,.12); }
.field-meta { margin-top: 7px; display: flex; justify-content: space-between; color: var(--muted); font-size: 12px; }
.primary-button, .secondary-button, .ghost-button { border: 0; border-radius: 12px; font-weight: 700; transition: transform .18s, box-shadow .18s, background .18s; }
.primary-button { width: 100%; color: white; background: var(--wine); padding: 15px 18px; display: flex; justify-content: center; gap: 12px; margin-top: 22px; box-shadow: 0 10px 20px rgba(111,23,63,.2); }
.primary-button:hover { transform: translateY(-2px); box-shadow: 0 14px 24px rgba(111,23,63,.26); }
.primary-button:disabled { opacity: .65; cursor: wait; transform: none; }
.secondary-button { color: white; background: var(--wine); padding: 11px 15px; }
.ghost-button { background: white; color: var(--wine); border: 1px solid var(--line); padding: 11px 15px; }
.privacy-note, .quiet-note { text-align: center; color: var(--muted); font-size: 12px; margin: 14px 0 0 !important; }
.error { margin-top: 14px; color: #9b2444; background: #fff0f2; border: 1px solid #f4c7d1; padding: 11px 13px; border-radius: 10px; font-size: 14px; }
.dashboard-view { padding: 50px 0 90px; }
.dashboard-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 32px; }
.dashboard-heading h1 { font-size: clamp(40px, 6vw, 64px); margin-top: 8px; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 20px; }
.stat-card { border-radius: 18px; padding: 22px; background: white; border: 1px solid var(--line); }
.stat-card span { color: var(--muted); font-size: 13px; }
.stat-card strong { display: block; font: 700 30px/1.2 "Fraunces", serif; margin-top: 8px; }
.stat-card.accent { background: var(--wine); color: white; border-color: var(--wine); }
.stat-card.accent span { color: #ffd8e5; }
.participants-card { padding: 28px; }
.card-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.card-heading h2 { font-size: 28px; }
.card-heading p { color: var(--muted); margin: 6px 0 0; }
.participant-row { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 14px; padding: 17px 0; border-bottom: 1px solid var(--line); }
.participant-row:last-child { border: 0; }
.person { display: flex; align-items: center; gap: 12px; min-width: 0; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--blush); color: var(--wine); font-weight: 800; }
.person strong { display: block; }
.status { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.status.viewed { color: var(--green); }
.icon-button { border: 1px solid var(--line); background: #fff; color: var(--wine); border-radius: 10px; padding: 9px 12px; font-weight: 700; text-decoration: none; font-size: 13px; white-space: nowrap; }
.save-warning { margin-top: 18px; display: flex; gap: 14px; background: #fff3cd; border: 1px solid #efdda2; border-radius: 16px; padding: 18px; }
.save-warning p { margin: 4px 0 0; color: #6f5b23; font-size: 14px; }
.reveal-view { min-height: 700px; display: grid; place-items: center; padding: 50px 0 90px; }
.reveal-shell { width: min(560px, 100%); text-align: center; }
.reveal-shell h1 { font-size: clamp(44px, 8vw, 66px); margin: 15px 0; }
.reveal-shell > p { color: var(--muted); }
.sealed-card, .result-card { margin: 34px auto 0; min-height: 220px; border-radius: 24px; display: grid; place-items: center; padding: 32px; }
.sealed-card { color: white; background: linear-gradient(145deg, var(--wine), var(--wine-dark)); box-shadow: var(--shadow); position: relative; overflow: hidden; }
.sealed-card::before, .sealed-card::after { content: ""; position: absolute; width: 160px; height: 160px; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; }
.sealed-card::before { left: -60px; top: -80px; }.sealed-card::after { right: -70px; bottom: -80px; }
.sealed-card .seal { width: 64px; height: 64px; background: #fff0c9; color: var(--wine); font-size: 18px; margin: auto auto 18px; }
.sealed-card span { font-size: 13px; color: #f8cbd9; }.sealed-card strong { display: block; font: 700 26px/1.3 "Fraunces", serif; }
.reveal-button { max-width: 360px; margin: 22px auto 0; }
.result-card { background: white; border: 1px solid var(--line); box-shadow: var(--shadow); animation: appear .55s ease both; }
.result-card .mini-label { color: var(--pink); }.result-card strong { color: var(--wine); font: 800 clamp(42px, 9vw, 70px)/1 "Fraunces", serif; margin: 14px 0; overflow-wrap: anywhere; }.result-card p { color: var(--muted); margin: 0; }
@keyframes appear { from { opacity: 0; transform: translateY(12px) scale(.97); } }
.toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); background: var(--ink); color: white; padding: 12px 18px; border-radius: 999px; box-shadow: var(--shadow); z-index: 10; }
footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 24px 0 30px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; color: var(--muted); font-size: 12px; }
@media (max-width: 850px) {
  .home-view { grid-template-columns: 1fr; gap: 48px; padding-top: 55px; }
  .hero-copy { text-align: center; }.hero-text { margin-inline: auto; }.benefits { width: fit-content; margin-inline: auto; text-align: left; }
  .candy { display: none; }.create-card { width: min(520px, 100%); margin: auto; }
  .stats-grid { grid-template-columns: 1fr; }.dashboard-heading { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 560px) {
  .topbar, main, footer { width: min(100% - 28px, 1180px); }.pill { display: none; }.topbar { padding: 20px 0; }
  .home-view { padding-top: 28px; }.hero-copy h1 { font-size: 50px; }.hero-text { font-size: 17px; }.create-card { padding: 22px; }
  .card-heading { align-items: flex-start; flex-direction: column; }.secondary-button { width: 100%; }
  .participants-card { padding: 20px; }.participant-row { grid-template-columns: 1fr auto; }.participant-row .whatsapp { grid-column: 1 / -1; text-align: center; }
  footer { flex-direction: column; text-align: center; }.ghost-button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; scroll-behavior: auto !important; } }
