/* Registration page styles. Builds on privacy.css (header, wrap, box, footer) and tokens.css */

.state{display:none;}
.state.active{display:block;}
/* Loading skeleton: shown while the page asks whether registration is open */
.sk-sr{position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;}
.sk-wrap{opacity:0;transition:opacity .2s ease;padding:4px 0;}
#state-loading.revealed .sk-wrap{opacity:1;}
.sk{background:rgba(43,30,58,.08);border-radius:8px;animation:reg-pulse 1.4s ease-in-out infinite;}
.sk-line{height:14px;margin:0 0 10px;}
.sk-short{width:60%;margin-bottom:28px;}
.sk-label{height:12px;width:32%;margin:0 0 8px;}
.sk-field{height:44px;margin:0 0 20px;}
.sk-button{height:48px;width:55%;margin-top:8px;border-radius:999px;}
@keyframes reg-pulse{0%,100%{opacity:1;}50%{opacity:.45;}}
@media (prefers-reduced-motion:reduce){.sk{animation:none;}.sk-wrap{transition:none;}}

.intro{margin:0 0 22px;font-size:1.02rem;}

fieldset{
  border:0;
  margin:0 0 26px;
  padding:0;
  min-width:0;
}
legend{
  padding:0;
  margin:0 0 14px;
  font-size:1.2rem;
  font-weight:700;
  color:var(--magenta);
  letter-spacing:.02em;
}

.field{display:flex;flex-direction:column;gap:6px;margin-bottom:16px;}
.field label{font-size:.86rem;font-weight:700;}
.req{color:var(--magenta);}

/* 16px minimum so iOS does not zoom into the field */
.field input,
.field select,
.field textarea{
  font-family:var(--font-sans);
  font-size:1rem;
  color:var(--ink);
  background:#fff;
  border:1.5px solid rgba(43,30,58,.22);
  border-radius:10px;
  padding:11px 13px;
  width:100%;
  min-height:46px;
}
.field textarea{resize:vertical;min-height:84px;line-height:1.5;}
.field select{appearance:auto;}
.field input:focus,
.field select:focus,
.field textarea:focus{outline:2px solid var(--magenta);outline-offset:1px;}
.field .invalid,
.check.invalid{border-color:#B3003C;}
.field input.invalid,
.field select.invalid,
.field textarea.invalid{background:rgba(255,59,107,.05);}

.hint{font-size:.8rem;color:var(--muted);line-height:1.5;}
.counter{align-self:flex-end;font-size:.74rem;color:var(--muted);margin-top:-2px;}
.counter.warn{color:#B3003C;font-weight:600;}

/* checkboxes */
.check{
  display:flex;
  align-items:flex-start;
  gap:12px;
  background:#fff;
  border:1.5px solid rgba(43,30,58,.14);
  border-radius:12px;
  padding:13px 14px;
  margin:0 0 12px;
  font-size:.92rem;
  line-height:1.55;
  cursor:pointer;
}
.check input{
  flex:none;
  width:22px;
  height:22px;
  margin:1px 0 0;
  accent-color:var(--magenta);
  cursor:pointer;
}
.check-optional{background:transparent;}
.check.invalid{background:rgba(255,59,107,.05);}

.summary{margin:2px 0 12px;padding:16px 18px 4px;}
.summary p{font-size:.9rem;}

/* honeypot */
.hp{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden;}

/* buttons */
.btn-submit{
  width:100%;
  border:0;
  background:var(--magenta);
  color:#fff;
  font-family:var(--font-sans);
  font-weight:700;
  font-size:1rem;
  padding:15px 20px;
  min-height:52px;
  border-radius:999px;
  cursor:pointer;
  margin-top:6px;
}
.btn-submit:hover{background:#E8305F;}
.btn-submit:focus-visible,
.btn-secondary:focus-visible{outline:3px solid var(--ink);outline-offset:3px;}
.btn-submit:disabled{opacity:.6;cursor:default;}
.btn-secondary{
  border:1.5px solid var(--ink);
  background:transparent;
  color:var(--ink);
  font-family:var(--font-sans);
  font-weight:700;
  font-size:.95rem;
  padding:12px 22px;
  border-radius:999px;
  cursor:pointer;
  margin:4px 0 14px;
}
.btn-secondary:hover{background:rgba(43,30,58,.06);}
.submit-note{text-align:center;margin:12px 0 0;}

/* messages */
.form-error{
  margin:0 0 20px;
  font-size:.92rem;
  color:#B3003C;
  background:rgba(255,59,107,.08);
  border-radius:10px;
  padding:12px 14px;
}

.result{text-align:center;padding:12px 0;}
.result h2{margin:0 0 12px;color:var(--ink);font-size:1.5rem;}
.result h2:focus,
#fallback-title:focus{outline:none;}
.result-icon{
  width:56px;height:56px;border-radius:999px;
  background:rgba(13,148,136,.12);color:var(--teal);
  display:flex;align-items:center;justify-content:center;
  margin:0 auto 16px;
}
.result-icon svg{width:28px;height:28px;}

footer a{color:var(--muted);}
footer a:hover{color:var(--magenta);}

@media (prefers-reduced-motion:reduce){*{scroll-behavior:auto !important;}}

/* accommodation options (radio cards) */
.stay-note{font-size:.88rem;color:var(--muted);margin:0 0 14px;line-height:1.55;}
.option{
  display:flex;
  align-items:flex-start;
  gap:12px;
  background:#fff;
  border:1.5px solid rgba(43,30,58,.14);
  border-radius:12px;
  padding:14px 14px;
  margin:0 0 12px;
  cursor:pointer;
  line-height:1.55;
}
.option input{
  flex:none;
  width:22px;
  height:22px;
  margin:1px 0 0;
  accent-color:var(--magenta);
  cursor:pointer;
}
.option:has(input:checked){border-color:var(--magenta);box-shadow:0 0 0 1px var(--magenta) inset;}
.option:has(input:focus-visible){outline:3px solid var(--ink);outline-offset:2px;}
.option-body{display:flex;flex-direction:column;gap:5px;min-width:0;}
.option-title{font-weight:700;font-size:1rem;}
.option-line{font-size:.88rem;color:var(--ink);}
.option-line a{overflow-wrap:anywhere;}
.options.invalid .option{border-color:#B3003C;background:rgba(255,59,107,.05);}

/* Message under the email field when the address is already registered */
.field-error{
  margin:0;font-size:.86rem;line-height:1.5;color:#B3003C;
  background:rgba(255,59,107,.08);border-radius:10px;padding:10px 12px;
}
.field-error[hidden]{display:none;}
.link-btn{
  background:none;border:0;padding:0;font:inherit;font-weight:700;color:inherit;
  text-decoration:underline;text-underline-offset:3px;cursor:pointer;
}
.link-btn:hover{color:var(--magenta);}
.link-btn:focus-visible{outline:3px solid var(--ink);outline-offset:2px;border-radius:3px;}
.nowrap{white-space:nowrap;}

/* Shown above the form when all places are taken (registrations go on the waiting list) */
.waitlist-note{
  margin:0 0 20px;font-size:.92rem;line-height:1.5;
  background:rgba(255,208,0,.16);border-radius:12px;padding:12px 14px;
}
.waitlist-note[hidden]{display:none;}
