/* Signup + Google completion. Loaded after auth.css and auth-layout.css. */

/* ---------- Account type: two cards side by side, each a vertical stack ----------
   radio circle, then the account type as a heading, then the description.
   A stack holds up at phone widths (~140px per card) where a row inside each card would not. */
.account-type-options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.account-type-option {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
}

.account-type-option:focus-within {
    box-shadow: 0 0 0 3px rgba(15, 92, 86, 0.18);
}

/* Radios sit inside .form, where `appearance:none` strips their native look,
   so they are drawn explicitly here. */
.account-type-option input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    flex: none;
    width: 18px;
    height: 18px;
    margin: 0;
    padding: 0;
    border: 2px solid var(--color-border);
    border-radius: 50%;
    background: var(--color-surface);
}

.account-type-option input[type="radio"]:checked {
    border-color: var(--color-primary);
    background: radial-gradient(circle, var(--color-primary) 0 4px, var(--color-surface) 5px);
}

.account-type-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.account-type-copy strong { font-size: 1rem; line-height: 1.2; }
.account-type-copy small { font-size: 0.76rem; line-height: 1.4; }

/* ---------- Password visibility toggle ---------- */
.pw-field { position: relative; }
.pw-field .pw-input { padding-right: 48px; }

/* !important on position/transform: base.css lifts every button on hover and
   animation.js sets position:relative inline on click; both would move the icon. */
.pw-toggle {
    position: absolute !important;
    top: 50%;
    right: 8px;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--color-ink-soft);
    cursor: pointer;
}
.pw-toggle,
.pw-toggle:hover,
.pw-toggle:active { transform: translateY(-50%) !important; }
.pw-toggle:hover,
.pw-toggle:focus-visible { color: var(--color-primary); background: var(--color-bg); }

/* Hide Edge's built-in reveal button so there is only one eye icon. */
.pw-input::-ms-reveal { display: none; }

/* ---------- Errors ---------- */
/* auth.css gives .client-error display:block, which would defeat [hidden]. */
.client-error[hidden] { display: none; }

/* Space between the Google button and the divider line beneath it. */
.formgroup > .google-auth-option { margin-bottom: 28px; }

/* ---------- Phone input (intl-tel-input) ---------- */
.vc-iti { display: block; width: 100%; }
.vc-iti .iti__tel-input { width: 100%; }

/* base.css lifts every button on hover; the flag button must not move. */
.vc-iti button,
.vc-iti button:hover,
.vc-iti button:active { transform: none !important; }

/* ---------- Google completion form ---------- */
/* Same stacked card as the signup page, and still two across on phones
   (auth.css collapses these to one column below 560px). */
.google-completion fieldset { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.google-completion .google-role-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    min-height: 0;
    padding: 14px;
}
.google-completion .google-role-card strong { font-size: 1rem; }
.google-completion .google-role-card small { margin-top: 4px; font-size: 0.76rem; }

.google-completion input[type="text"],
.google-completion input[type="tel"]:not(.iti__tel-input) {
    display: block;
    width: 100%;
    margin: 0 0 16px;
    padding: 10px 14px;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-input);
    background: var(--color-bg);
    color: var(--color-ink);
    font: inherit;
    font-size: 0.95rem;
}

/* No padding-left here: the plugin sets it to clear the flag and dial code. */
.google-completion .iti__tel-input {
    width: 100%;
    padding-top: 10px;
    padding-bottom: 10px;
    padding-right: 14px;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-input);
    background: var(--color-bg);
    color: var(--color-ink);
    font: inherit;
    font-size: 0.95rem;
}

.google-completion input[type="text"]:focus,
.google-completion input[type="tel"]:focus {
    border-color: var(--color-primary);
    outline: 3px solid rgba(15, 92, 86, 0.12);
    background: var(--color-surface);
}

.google-completion .google-phone-field { margin: 0 0 16px; }
.google-completion .google-phone-field .client-error { margin-top: 6px; }

/* Breathing room between the terms checkbox and the submit button. */
[data-signup-form] .buttons { margin-top: 28px; }