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

body {
    display: flex;
    position: relative;
    overflow: hidden;
    font-family: "Inter", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    background-color: var(--eld-white);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='89' height='89'%3E%3Crect x='0' y='0' width='2.7' height='2.7' fill='%234F71C2' opacity='0.8'/%3E%3C/svg%3E");
    background-size: 89.226px 89.226px;
    background-position: 32px 58px;
    color: var(--eld-dark);
}

body::before,
body::after {
    content: '';
    position: absolute;
    width: 523px;
    height: 523px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--color-primary-200) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

body::before {
    top: -200px;
    left: -200px;
}

body::after {
    bottom: -200px;
    right: -200px;
}

.glow-top-center {
    position: absolute;
    top: -300px;
    left: 50%;
    transform: translateX(-50%);
    width: 523px;
    height: 523px;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--eld-primary) 5%, transparent) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

h1 {
    font-size: clamp(1.75rem, 4vw, 2rem);
    font-weight: 600;
    margin: 0 0 0.5rem;
    text-align: center;
    color: var(--eld-dark);
}

h2 {
    font-size: clamp(0.875rem, 3vw, 1rem);
    font-weight: 400;
    margin: 0 0 2rem;
    text-align: center;
    line-height: 150%;
    color: color-mix(in srgb, var(--eld-dark) 70%, transparent);
}

a {
    color: var(--eld-dark);
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    gap: 0.5rem;
    width: 15rem;
    height: 3rem;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    color: var(--color-primary-50);
    background-color: var(--eld-primary);
    border-radius: 3rem;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.button:active {
    transform: scale(0.98);
}

.button:hover {
    filter: brightness(0.95);
}

.button:disabled {
    background-color: var(--eld-disabled);
    cursor: not-allowed;
    opacity: 0.7;
}

.container,
form.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(calc(100vw - 1.5rem), var(--container-width, 30.75rem));
    padding: 1rem 0;
    z-index: 1;
}

.logo {
    margin-bottom: 1rem;
}

.svg-icon {
    display: block;
    width: 18px;
    height: 16px;
    background-color: currentColor;
    mask-size: contain;
    mask-position: center;
    mask-repeat: no-repeat;
}

.arrow-next-icon {
    mask-image: url("../pictures/arrow-next.svg");
}

.arrow-back-icon {
    mask-image: url("../pictures/arrow-back.svg");
}

.eye-icon {
    cursor: pointer;
    mask-image: url("../pictures/eye.svg");
}

/* Form field: label + input wrapper + inline validation message */
.form-field {
    display: flex;
    position: relative;
    flex-direction: column;
    flex-grow: 1;
    width: 100%;
    max-width: 460px;
    margin-bottom: 1rem;
}

.form-field label {
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.75rem;
    color: var(--eld-dark);
}

.form-field .input-wrapper {
    display: flex;
    align-items: center;
    background-color: color-mix(in srgb, var(--eld-dark) 2%, transparent);
    border: 1px solid var(--color-primary-100);
    backdrop-filter: blur(50px);
    border-radius: 0.5rem;
    padding: 12px 14px;
    transition: border-color 0.3s ease-in-out;
}

.form-field input {
    flex-grow: 1;
    width: 100%;
    box-sizing: border-box;
    background: transparent;
    border: none;
    outline: none;
    padding: 0;
    color: var(--eld-dark);
    font-size: 1rem;
}

.form-field.error .input-wrapper {
    border-color: var(--eld-error-soft);
}

.form-field small {
    display: none;
    color: var(--eld-error);
    position: absolute;
    bottom: -1.4rem;
    left: 0.5rem;
}

.form-field.error small {
    display: block;
}

.validation-error {
    color: var(--eld-error);
    font-weight: 500;
    font-size: 14px;
    min-height: 20px;
    margin-top: 5px;
}

.alert-danger {
    width: 100%;
    box-sizing: border-box;
    color: var(--eld-white);
    background-color: var(--eld-error);
    padding: 1rem;
    border-radius: 0.5rem;
}

.alert-danger button {
    display: none;
}

/* Subtitle constraint shared by login and forgot-password */
.h2-class {
    max-width: 459px;
    text-align: center;
}

@media (max-width: 530px) {
    .h2-class {
        max-width: 335px;
    }
}

/* Back-to-corner link used on auth pages */
.fixed-corner {
    max-width: 100%;
    position: fixed;
    top: clamp(0.5rem, 2vw, 1.5rem);
    left: clamp(0.5rem, 2vw, 1.5rem);
    padding: 0.5rem 1rem;
    color: var(--eld-dark);
    z-index: 2;
    font-size: 1.125rem;
    line-height: 1.5rem;
    font-weight: 600;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.375rem;
}

.select-vehicles .vehicle-error {
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0;
}

input {
    background: transparent !important;
}

/* Suppress Chrome's yellow autofill background and keep brand text color */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-text-fill-color: var(--eld-dark) !important;
    caret-color: var(--eld-dark);
    transition: background-color 9999s ease-in-out 0s;
    box-shadow: none;
}
