/* Membership application: the public form, the code page and the status page.
   Uses the colour and spacing tokens defined in css/site.css. */

.req { color: #dc3545; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* --- the three steps ------------------------------------------------------------------------ */
.steps { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.steps li { display: flex; gap: .9rem; align-items: flex-start; padding: 1rem 1.15rem; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.steps__n { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--brand), var(--navy-900)); }
.steps strong { display: block; color: var(--ink); }
.steps small { color: var(--muted); font-weight: 500; font-size: .87rem; }
@media (max-width: 767.98px) { .steps { grid-template-columns: 1fr; } }

/* --- the form -------------------------------------------------------------------------------- */
.apply-card { background: #fff; border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow-md); padding: 2rem 2.25rem; }
.apply-card__title { display: flex; align-items: center; gap: .7rem; font-size: 1.1rem; margin: 1.75rem 0 1rem; }
.apply-card__title:first-of-type { margin-top: 0; }
.apply-card__title span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font-size: .85rem; color: var(--brand); background: var(--brand-50); }
.apply-card .form-control, .apply-card .form-select { border-radius: 14px; border: 1.5px solid var(--line); background-color: var(--bg); }
.apply-card .form-control:focus, .apply-card .form-select:focus { background-color: #fff; border-color: var(--brand); box-shadow: 0 0 0 .25rem rgba(36, 87, 245, .15); }
.apply-card .is-invalid { border-color: #dc3545; background-image: none; }
.apply-card .form-check-input { width: 1.25rem; height: 1.25rem; margin-top: .15rem; }
.apply-card .form-check-label { font-weight: 600; color: var(--ink-soft); }
.apply-card .form-text { font-size: .85rem; }
.apply-alert { display: flex; gap: .8rem; padding: .9rem 1.1rem; margin-bottom: 1.5rem; border-radius: var(--radius-sm); background: #fdecea; color: #8a1c13; font-weight: 600; }
.apply-alert p { margin: 0; }
.apply-alert i { margin-top: .15rem; }
@media (max-width: 575.98px) { .apply-card { padding: 1.4rem 1.2rem; border-radius: 18px; } }

.choice-cards { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.choice-card { position: relative; display: block; cursor: pointer; margin: 0; }
.choice-card input { position: absolute; opacity: 0; inset: 0; }
.choice-card__body { display: flex; flex-direction: column; padding: .95rem 1.1rem; border: 1.5px solid var(--line); border-radius: 14px; background: var(--bg); transition: border-color .15s, background .15s, box-shadow .15s; }
.choice-card__body strong { font-size: 1.15rem; color: var(--ink); }
.choice-card__body small { color: var(--muted); font-weight: 600; }
.choice-card:hover .choice-card__body { border-color: color-mix(in srgb, var(--brand) 45%, white); }
.choice-card input:checked + .choice-card__body { border-color: var(--brand); background: var(--brand-50); box-shadow: 0 0 0 .2rem rgba(36, 87, 245, .12); }
.choice-card input:checked + .choice-card__body strong { color: var(--brand); }
.choice-card input:focus-visible + .choice-card__body { outline: 3px solid color-mix(in srgb, var(--brand) 55%, white); outline-offset: 2px; }
@media (max-width: 420px) { .choice-cards { grid-template-columns: 1fr; } }

.side-card { padding: 1.4rem 1.5rem; margin-bottom: 1.25rem; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); }
.side-card h2 { display: flex; align-items: center; gap: .55rem; font-size: 1.05rem; margin-bottom: .6rem; }
.side-card h2 i { color: var(--brand); }
.side-card p { color: var(--muted); }
.side-card--flush { margin-bottom: 0; height: 100%; background: #fff; }

/* --- the code ---------------------------------------------------------------------------------- */
.code-card {
  max-width: 640px; margin: 0 auto; text-align: center; padding: 2.5rem 2rem; border-radius: 28px; color: #fff;
  background: radial-gradient(420px 220px at 100% 0, rgba(255, 122, 26, .45), transparent 70%), linear-gradient(135deg, var(--navy-900), var(--brand));
  box-shadow: var(--shadow-lg);
}
.code-card__label { display: block; font-size: .8rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .75); }
.code-card__code { display: block; margin: .6rem 0; font-size: clamp(2.6rem, 11vw, 4.6rem); font-weight: 800; letter-spacing: .12em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.code-card__hint { margin: 0 0 1.4rem; color: rgba(255, 255, 255, .8); }
.code-card__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: .75rem; }
.code-card .btn-brand { background: #fff; color: var(--navy-900); box-shadow: none; }
.code-card .btn-outline-brand { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .5); }
.code-card .btn-outline-brand:hover { background: rgba(255, 255, 255, .15); border-color: #fff; color: #fff; }
.next-steps { padding-left: 1.2rem; margin: 0; color: var(--ink-soft); }
.next-steps li + li { margin-top: .6rem; }
.contact-list { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: .6rem; font-weight: 600; }
.contact-list i { color: var(--brand); margin-right: .6rem; }
.btn-ghost-dark { color: var(--ink-soft); border: 1.5px solid var(--line); background: #fff; }
.btn-ghost-dark:hover { border-color: var(--ink); color: var(--ink); }

/* --- the answer ---------------------------------------------------------------------------------- */
.result-card { display: flex; gap: 1.25rem; padding: 1.75rem; background: #fff; border: 1px solid var(--line); border-left: 6px solid var(--accent); border-radius: var(--radius); box-shadow: var(--shadow-md); }
.result-card--accepted { border-left-color: #16a34a; }
.result-card--rejected { border-left-color: #94a3b8; }
.result-card__icon { flex: none; font-size: 2.4rem; line-height: 1; color: var(--accent-600); }
.result-card--accepted .result-card__icon { color: #16a34a; }
.result-card--rejected .result-card__icon { color: #64748b; }
.result-card__code { font-size: .78rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.result-card h2 { font-size: 1.4rem; margin: .2rem 0 .6rem; }
.result-card p { color: var(--ink-soft); }
.result-card__note { margin: 1rem 0; padding: .8rem 1rem; border-radius: var(--radius-sm); background: var(--bg); color: var(--ink); font-weight: 600; }
.result-card__note small { display: block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 800; }

@media print {
  .site-nav, .site-footer, .page-hero, .code-card__actions, .side-card .btn, .news-ticker, .demo-banner { display: none !important; }
  .code-card { box-shadow: none; color: #000; background: #fff; border: 2px solid #000; }
  .code-card__label, .code-card__hint { color: #000; }
}
