/* Styles for the sign-in, forgot password and change password pages.
   Same look as the CREST login page (CREST Content/Login.css). */

:root {
    --navy: #003f87;
    --navy-hover: #00326b;
    --navy-dark: #02283a;
    --green: #008751;
    --text: #1f2937;
    --muted: #6b7280;
    --border: #d1d5db;
    --error: #b91c1c;
    font-family: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
    margin: 0;
}

body {
    /* Spotlight behind the card, fading to navy at the edges (same in the intranet's styles/Login.css) */
    background: radial-gradient(ellipse at 50% 35%, #ffffff 0%, #e8eef7 35%, #5b86b8 70%, var(--navy) 100%) fixed;
    color: var(--text);
}

.login-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.login-card {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-top: 4px solid var(--green);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(2, 40, 58, .18);
    padding: 32px 28px;
    text-align: center;
}

/* The stacked Vetted Credit logo is the page heading (h1 holding the image) */
.login-brand {
    position: relative;
    width: 220px;
    max-width: 100%;
    margin: 0 auto 12px;
}

/* Trademark mark beside the logo: placed outside the artwork, which must not be altered
   (top right of "VETTED" in the stacked logo, over its transparent background) */
.login-brand .tm-mark {
    position: absolute;
    left: 80%;
    top: 55%;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    color: var(--navy);
}

.login-logo {
    display: block;
    max-width: 100%;
    width: 220px;
    height: auto;
    margin: 0 auto;
}

.login-title {
    margin: 8px 0 4px;
    font-size: 1.75rem;
    letter-spacing: .08em;
    color: var(--navy-dark);
}

.login-subtitle {
    margin: 0 0 24px;
    color: var(--muted);
}

/* Change password sits inside MasterPage.master, below the menu, so it doesn't need the full window height */
.login-page.in-site {
    min-height: 0;
    padding-top: 48px;
}

.field-hint {
    display: block;
    margin-top: 4px;
    font-size: .8rem;
    color: var(--muted);
}

.btn-row {
    display: flex;
    gap: 10px;
}

.btn-secondary {
    background: #fff;
    color: var(--navy);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    border-color: var(--navy);
}

/* Form */
.form-group {
    text-align: left;
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: .9rem;
    font-weight: 600;
}

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.forgot-row {
    margin-top: 6px;
    text-align: right;
}

.field {
    width: 100%;
    padding: 11px 12px;
    font-family: inherit;
    font-size: 1rem;
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: border-color .15s, box-shadow .15s;
}

.field:focus-visible {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(0, 63, 135, .25);
}

.field-error {
    display: block;
    margin-top: 4px;
    font-size: .85rem;
    color: var(--error);
}

.remember {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    text-align: left;
    font-size: .9rem;
}

.remember label {
    margin: 0;
    font-weight: normal;
}

/* Button */
.btn {
    width: 100%;
    margin-top: 8px;
    padding: 12px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.btn-primary {
    background: var(--navy);
    color: #fff;
}

.btn-primary:hover {
    background: var(--navy-hover);
}

.btn-primary:active {
    background: var(--navy-dark);
}

.btn:focus-visible {
    outline: 3px solid rgba(0, 63, 135, .4);
    outline-offset: 2px;
}

.btn[disabled] {
    opacity: .7;
    cursor: wait;
}

/* Alerts */
.alert {
    display: block;
    margin-bottom: 16px;
    padding: 10px 12px;
    border: 1px solid #fecaca;
    border-radius: 6px;
    background: #fef2f2;
    color: var(--error);
    font-size: .9rem;
    text-align: left;
}

.alert:empty {
    display: none;
}

.alert-success {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #166534;
}

.back-link {
    margin: 16px 0 0;
}

/* Links */
a {
    color: var(--navy);
}

.link-small {
    font-size: .85rem;
    text-decoration: none;
}

.link-small:hover {
    text-decoration: underline;
}

.login-footer {
    margin-top: 20px;
    font-size: .9rem;
    color: #fff;
}

.login-footer a {
    color: #fff;
    font-weight: 600;
}
