/* Styling for the Account pages' native <InputText>/<InputCheckbox> elements.
   These pages run static SSR (no Blazor circuit) so SignInManager can write the auth
   cookie - MudBlazor's form fields require an active circuit and don't render the
   name= attributes ASP.NET Core's [SupplyParameterFromForm] binding needs, so native
   Blazor form components are used here instead, hand-styled to match the MudBlazor
   look used everywhere else in the app. */

.account-field {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    margin-bottom: 4px;
    border: 1px solid var(--mud-palette-lines-inputs, rgba(0, 0, 0, 0.23));
    border-radius: var(--mud-default-borderradius, 4px);
    font-family: var(--mud-typography-default-family, Roboto, sans-serif);
    font-size: 1rem;
    background: var(--mud-palette-surface, #fff);
    color: var(--mud-palette-text-primary, rgba(0, 0, 0, 0.87));
}

.account-field:focus {
    outline: none;
    border-color: var(--mud-palette-primary, #594AE2);
    border-width: 2px;
    padding: 9px 11px;
}

.account-field-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 4px;
    color: var(--mud-palette-text-secondary, rgba(0, 0, 0, 0.6));
}

.account-field-group {
    margin-bottom: 1rem;
}

.account-submit-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 10px 16px;
    border: none;
    border-radius: var(--m3-shape-full, 9999px);
    background: var(--mud-palette-primary, #594AE2);
    color: var(--mud-palette-primary-text, #fff);
    font-family: var(--mud-typography-default-family, Roboto, sans-serif);
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    cursor: pointer;
}

.account-submit-button:hover {
    filter: brightness(0.92);
}

/* Non-full-width variant - the Manage/Profile page's Save/Upload buttons don't want to
   span the whole panel like Login/Register's do. */
.account-submit-button--auto {
    width: auto;
    padding-left: 2rem;
    padding-right: 2rem;
}

.account-panel {
    border-radius: var(--m3-shape-lg);
    box-shadow: var(--m3-elevation-1);
}

/* "Request an account" form: a field no person sees (robots tend to fill every input), small optional hints, and a city/state/zip row. */
.account-hp {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.account-field-optional {
    font-weight: 400;
    color: var(--sa-ink-3);
    text-transform: none;
    letter-spacing: 0;
}

.account-field-row {
    display: grid;
    grid-template-columns: 2fr 1.5fr 1fr;
    gap: 0 12px;
}

@media (max-width: 560px) {
    .account-field-row { grid-template-columns: 1fr; }
}

/* Free-trial offer box at the top of the "Request an account" form */

.account-trial-offer {
    margin-bottom: 20px;
    padding: 16px 18px;
    border-radius: 12px;
    border: 1px solid rgba(255, 194, 75, 0.55);
    background: rgba(255, 194, 75, 0.1);
}

.account-trial-offer__title {
    font-weight: 800;
    font-size: 1.05rem;
    color: var(--sa-amber);
}

.account-trial-offer p {
    margin: 6px 0 12px;
    line-height: 1.55;
    font-size: 0.93rem;
}

.account-trial-offer__check {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    cursor: pointer;
}

.account-trial-offer__check input {
    width: 18px;
    height: 18px;
    accent-color: var(--sa-amber);
}

/* Missing / wrong fields: a red border (and a faint red wash) on the control itself, plus a red message under it. Blazor adds the "invalid" class
   to a field once the form has been submitted and that field fails its rule. */

.account-field.invalid {
    border-color: #ff5d5d;
    box-shadow: 0 0 0 1px #ff5d5d;
    background-color: rgba(255, 93, 93, 0.08);
}

.account-field.invalid:focus {
    border-color: #ff5d5d;
}

.validation-message {
    margin: 2px 0 0;
    color: #ff8a8a;
    font-size: 0.8rem;
    font-weight: 500;
}

/* The list at the top of the form ("Please enter ...") */
.account-validation-summary {
    margin-bottom: 16px;
}

.account-validation-summary ul {
    margin: 0;
    padding: 10px 14px 10px 30px;
    border-radius: 8px;
    border: 1px solid rgba(255, 93, 93, 0.55);
    background: rgba(255, 93, 93, 0.1);
    color: #ffb1b1;
    font-size: 0.9rem;
}

/* The state dropdown: same look as the text boxes, and a dark list when opened */
select.account-field {
    color-scheme: dark;
    cursor: pointer;
}
