/* Estética copiada do sprintbaddies.com */
:root {
  --pink: #ff84fb;
  --pink-ink: #4a0f46;
  --white: #ffffff;
  --plum: #2a0f2e;
  --glass-strong: rgba(34, 10, 38, .86);
  --line: rgba(255, 245, 255, .18);
  --text: #ffffff;
  --text-soft: rgba(255, 245, 255, .82);
  --text-faint: rgba(255, 245, 255, .64);
  --error: #ffb3c7;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --font-display: "Gloock", "Cormorant Garamond", Georgia, serif;
  --font-ui: "Cormorant Garamond", Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { color-scheme: dark; }

body {
  min-height: 100dvh;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 17px;
  font-variant-numeric: lining-nums;
  color: var(--text);
  background: var(--plum);
  -webkit-font-smoothing: antialiased;
  display: grid;
  place-items: center;
  padding: 32px 16px;
}

::selection { background: var(--pink); color: var(--pink-ink); }
button, input, select, textarea { font: inherit; color: inherit; }
input, textarea { caret-color: var(--pink); }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }

/* Fundo */
.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(70% 60% at 100% 100%, rgba(255, 132, 251, .38) 0%, transparent 65%),
    radial-gradient(60% 55% at 0% 0%, #7a2a7f 0%, transparent 70%),
    radial-gradient(50% 45% at 85% 10%, rgba(176, 64, 170, .35) 0%, transparent 70%),
    radial-gradient(55% 50% at 10% 95%, rgba(98, 26, 104, .6) 0%, transparent 70%),
    linear-gradient(160deg, #3b1240 0%, var(--plum) 45%, #1c0820 100%);
}
/* Granulado leve, igual ao sprintbaddies */
.bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .12;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Cartão */
.card {
  position: relative;
  z-index: 1;
  width: min(480px, 100%);
  padding: 28px 24px 24px;
  border-radius: 20px;
  border: 1px solid rgba(255, 220, 252, .14);
  background: var(--glass-strong);
  box-shadow: rgba(10, 2, 12, .9) 0 30px 80px -20px;
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  animation: rise .5s var(--ease) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

.card__logo { width: 140px; height: auto; margin: 0 auto 14px; }
.card__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 26px;
  letter-spacing: -.01em;
  line-height: 1.15;
  text-align: center;
  text-wrap: balance;
}
.card__lead {
  margin: 6px 0 22px;
  text-align: center;
  font-size: 17px;
  line-height: 1.4;
  color: var(--text-soft);
  text-wrap: pretty;
}

.section {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 19px;
  margin: 26px 0 12px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

/* Campos */
fieldset { border: 0; padding: 0; min-width: 0; }
.group { margin-bottom: 14px; min-width: 0; }
.label {
  display: block;
  margin-bottom: 6px;
  padding: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-soft);
}
.opt, .limite { font-weight: 500; color: var(--text-faint); }
.limite { color: var(--pink); }

.input {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border-radius: 10px;
  background: rgba(255, 245, 255, .08);
  border: 1px solid var(--line);
  color: var(--white);
  font-size: 16px; /* 16px evita zoom no iPhone */
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.input::placeholder { color: var(--text-faint); }
.input:focus { outline: none; border-color: var(--pink); background: rgba(255, 245, 255, .11); }
.input[aria-invalid="true"] { border-color: var(--error); }
.input--area { height: auto; min-height: 88px; padding: 10px 12px; resize: vertical; line-height: 1.4; }

.select {
  appearance: none;
  cursor: pointer;
  padding-right: 38px;
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px auto;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff5ff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
.select option { background: var(--plum); color: var(--white); }

.row { display: flex; gap: 10px; align-items: flex-start; }
.row--cep { align-items: flex-end; }
.row > .group { flex: 1 1 0; }
.row > .group--num { flex: 0 0 96px; }
.row > .group--uf { flex: 0 0 96px; }
.row > .group--cep { flex: 0 0 140px; }
.hint { margin-top: 6px; font-size: 14px; line-height: 1.35; color: var(--text-faint); }
.hint--cep { flex: 1; margin: 0 0 24px; }
.hint--cep.is-ok { color: var(--pink); }
.hint--cep.is-bad { color: var(--error); }

.error { font-size: 14px; font-weight: 600; color: var(--error); margin-top: 5px; }
.error:empty { display: none; }
.error--form { text-align: center; margin-top: 12px; }

/* Escolha do evento */
.events { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.event { position: relative; display: block; cursor: pointer; }
.event input { position: absolute; opacity: 0; pointer-events: none; }
.event span {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  min-height: 68px;
  height: 100%;
  padding: 10px 12px;
  border-radius: 14px;
  background:
    radial-gradient(100% 100% at 50% 100%, rgba(255, 150, 245, .16), rgba(255, 150, 245, 0) 65%),
    rgba(255, 245, 255, .05);
  border: 1px solid rgba(255, 220, 252, .22);
  box-shadow: rgba(255, 170, 250, .12) 0 0 14px inset;
  font-weight: 700;
  font-size: 16px;
  line-height: 1.15;
  transition: transform .5s cubic-bezier(.22, 1, .36, 1), box-shadow .3s var(--ease), border-color .3s var(--ease), background .3s var(--ease);
}
.event small { font-weight: 500; font-size: 13.5px; color: var(--text-faint); }
.event:hover span { transform: translateY(-1px); border-color: rgba(255, 200, 252, .42); }
.event input:focus-visible + span { outline: 2px solid var(--pink); outline-offset: 2px; }
.event input:checked + span {
  background: radial-gradient(100% 100% at 50% 100%, rgba(255, 132, 251, .45), rgba(255, 132, 251, .12) 70%);
  border-color: rgba(255, 200, 252, .6);
  box-shadow: rgba(255, 190, 252, .3) 0 0 18px inset, rgba(255, 132, 251, .25) 0 0 22px;
}
.event input:checked + span small { color: var(--text-soft); }

/* Sim / Não */
.choices { display: flex; gap: 8px; }
.choice { cursor: pointer; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice span {
  display: inline-grid;
  place-items: center;
  min-width: 84px;
  height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 220, 252, .22);
  background: rgba(255, 245, 255, .05);
  font-weight: 700;
  transition: background .2s var(--ease), border-color .2s var(--ease);
}
.choice input:focus-visible + span { outline: 2px solid var(--pink); outline-offset: 2px; }
.choice input:checked + span { background: var(--pink); color: var(--pink-ink); border-color: var(--pink); }

/* Caixinha */
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: 15.5px; line-height: 1.35; color: var(--text-soft); }
.check input {
  flex: 0 0 auto;
  appearance: none;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  border-radius: 6px;
  border: 1px solid rgba(255, 220, 252, .4);
  background: rgba(255, 245, 255, .06);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.check input::after { content: ""; width: 10px; height: 6px; border: 2px solid var(--pink-ink); border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.check input:checked { background: var(--pink); border-color: var(--pink); }
.check input:checked::after { opacity: 1; }
.check input:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.check b { color: var(--white); }

/* Campo isca invisível */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.privacy { margin: 22px 0 14px; font-size: 14px; line-height: 1.4; color: var(--text-faint); text-align: center; }

/* Botões */
.cta {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  background: var(--pink);
  color: var(--pink-ink);
  font-weight: 700;
  font-size: 17px;
  cursor: pointer;
  transition: background-color .2s var(--ease), transform .15s var(--ease);
}
.cta:hover { background: #ff9ffc; }
.cta:active { transform: scale(.98); }
.cta:focus-visible { outline: 2px solid var(--white); outline-offset: 3px; }
.cta:disabled { opacity: .55; cursor: progress; }
.cta--ghost { background: rgba(255, 245, 255, .1); color: var(--white); margin-top: 20px; }
.cta--ghost:hover { background: rgba(255, 132, 251, .3); }

/* Confirmação */
#doneView:focus { outline: none; }
.summary {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 14px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 245, 255, .06);
  border: 1px solid var(--line);
  font-size: 15.5px;
  line-height: 1.35;
}
.summary dt { font-weight: 700; color: var(--text-faint); }
.summary dd { color: var(--white); overflow-wrap: anywhere; }
.demo { margin-top: 14px; font-size: 14px; color: var(--error); text-align: center; }

@media (max-width: 420px) {
  body { padding: 16px 12px; place-items: start center; }
  .card { padding: 22px 16px 18px; }
  .card__title { font-size: 23px; }
  .events { grid-template-columns: 1fr; }
  .event span { min-height: 56px; }
  .row > .group--cep { flex-basis: 130px; }
  .summary { grid-template-columns: 1fr; gap: 2px; }
  .summary dd { margin-bottom: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
