/* ---------------------------------------------------------------------
   Tokens. Retune these five to your real brand values and the whole
   page follows — nothing below hardcodes a colour.
   --------------------------------------------------------------------- */
.reg-page {
    --ink:      #16202b;   /* headings, input text                      */
    --muted:    #667283;   /* secondary copy, helper notes              */
    --line:     #dde2e8;   /* borders, dividers                         */
    --canvas:   #f4f6f8;   /* the aside panel                           */
    --accent:   #483D8B;   /* brand purple, as the header (common-1.css); white on it 9:1 */

    --radius:   6px;
}

.reg-page {
    max-width: 940px;
    margin: 0 auto;
    padding: 44px 20px 72px;
    color: var(--ink);
    font-size: 14px;
    line-height: 1.55;
}

.reg-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
}

/* ---- the form column ------------------------------------------------ */

.reg-card { min-width: 0; }

.reg-title {
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.015em;
    line-height: 1.2;
    margin: 0 0 6px;
}

.reg-lede {
    color: var(--muted);
    margin: 0 0 24px;
    max-width: 46ch;
}

.reg-notice {
    padding: 10px 13px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    margin-bottom: 18px;
    font-size: 13px;
}
.reg-notice.is-hidden { display: none; }
.reg-notice.is-bad    { border-color: #e2c3c3; background: #fbf3f3; color: #8c2f2f; }
.reg-notice.is-good   { border-color: #bcd6c8; background: #f1f7f3; color: #1f6b4a; }

.reg-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 11px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
}
.reg-google:hover { background: var(--canvas); color: var(--ink); }
.reg-google-mark  { width: 18px; height: 18px; flex: none; }

.reg-or {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: var(--muted);
    font-size: 12px;
}
.reg-or::before,
.reg-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* the JS alert, distinct from the server-rendered notice above */
.reg-alert {
    display: none;
    padding: 9px 13px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    font-size: 13px;
    border: 1px solid #e2c3c3;
    background: #fbf3f3;
    color: #8c2f2f;
}
.reg-alert.show { display: block; }
.reg-alert.ok   { border-color: #bcd6c8; background: #f1f7f3; color: #1f6b4a; }

.reg-row { display: flex; gap: 12px; }
.reg-row .reg-field { flex: 1; min-width: 0; }

.reg-field { margin-bottom: 16px; }

.reg-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 5px;
}

.reg-field input {
    width: 100%;
    padding: 9px 11px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    font-size: 14px;
    color: var(--ink);
    background: #fff;
}
.reg-field input:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
    border-color: var(--accent);
}
.reg-field input.is-bad  { border-color: #d3a3a3; }
.reg-field input.is-good { border-color: #9dc2ac; }

.reg-note {
    font-size: 12px;
    color: var(--muted);
    margin-top: 5px;
    line-height: 1.45;
}
.reg-note.is-bad  { color: #8c2f2f; }
.reg-note.is-good { color: var(--accent); }

.reg-meter {
    height: 3px;
    background: var(--line);
    border-radius: 2px;
    margin-top: 8px;
    overflow: hidden;
}
.reg-meter span {
    display: block;
    height: 100%;
    width: 0;
    background: #c9553d;
    transition: width .18s ease, background .18s ease;
}

.reg-agree {
    display: flex;
    gap: 9px;
    align-items: flex-start;
    font-size: 13px;
    color: var(--muted);
    margin: 20px 0;
    line-height: 1.5;
}
.reg-agree input { margin-top: 3px; flex: none; }
.reg-agree a     { color: var(--accent); }

.reg-submit {
    width: 100%;
    padding: 11px;
    border: 0;
    border-radius: var(--radius);
    background: var(--accent);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}
.reg-submit:disabled { background: #8f89b8; cursor: not-allowed; }
.reg-submit:focus    { outline: 2px solid var(--ink); outline-offset: 2px; }

.reg-foot {
    font-size: 13px;
    color: var(--muted);
    margin: 18px 0 0;
}
.reg-foot a { color: var(--accent); font-weight: 500; }

/* ---- the aside ------------------------------------------------------ */

.reg-aside {
    background: var(--canvas);
    border-radius: 10px;
    padding: 28px 26px;
    min-width: 0;
}

.reg-aside h2 {
    font-size: 17px;
    font-weight: 600;
    line-height: 1.35;
    margin: 0 0 20px;
    max-width: 22ch;
}

.reg-mark { display: block; margin: 0 0 22px; }

.reg-points { margin: 0; padding: 0; list-style: none; }

.reg-points li {
    padding: 14px 0;
    border-top: 1px solid var(--line);
}
.reg-points li:last-child { padding-bottom: 0; }

.reg-points b {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 3px;
}

.reg-points span {
    color: var(--muted);
    font-size: 13px;
}

/* ---- closed state --------------------------------------------------- */

.reg-closed {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 32px 28px;
    max-width: 520px;
}
.reg-closed p { color: var(--muted); margin: 0 0 20px; }

.reg-back {
    display: inline-block;
    padding: 9px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    color: var(--ink);
    text-decoration: none;
    font-weight: 500;
    margin-right: 8px;
}
.reg-back:hover { background: var(--canvas); color: var(--ink); }

/* ---- narrow --------------------------------------------------------- */

@media (max-width: 860px) {
    .reg-grid        { grid-template-columns: 1fr; gap: 32px; }
    .reg-page        { padding: 28px 18px 56px; }
    .reg-title       { font-size: 22px; }
}

@media (max-width: 460px) {
    .reg-row { flex-direction: column; gap: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .reg-meter span { transition: none; }
}
