* {
    box-sizing: border-box;
}

:root {
    --login-background: #ffffff;
    --login-primary: #00ab91;
    --login-primary-border: #009675;
    --login-secondary-border: #ced7d6;
    --login-field-border: #c2cfd3;
    --login-placeholder: #677a80;
    --login-text: #2d3939;
    --login-error: #b42318;
    --login-radius: 6px;
}

body.login-page {
    min-height: 100vh;
    margin: 0;
    color: var(--login-text);
    background: var(--login-background);
    font-family: "Manrope", Arial, sans-serif;
    font-size: 12px;
}

.login-shell {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 32px 16px 110px;
}

.login-panel {
    display: flex;
    flex-direction: column;
    gap: 36px;
    width: min(100%, 360px);
}

.login-brand {
    display: flex;
    align-items: center;
    width: 128px;
    height: 32px;
}

.login-brand img {
    width: 128px;
    height: auto;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-fields,
.login-actions {
    display: flex;
    flex-direction: column;
}

.login-fields {
    gap: 8px;
}

.login-actions {
    gap: 12px;
}

.login-field {
    display: flex;
    flex-direction: column;
    min-height: 80px;
    border: 1px solid var(--login-field-border);
    border-radius: var(--login-radius);
    background: #ffffff;
    overflow: hidden;
}

.login-field__label {
    display: flex;
    align-items: center;
    min-height: 38px;
    padding: 8px 12px 0;
    color: var(--login-text);
    font-size: 12px;
    font-weight: 700;
    line-height: 18px;
    white-space: nowrap;
}

.login-field__control {
    display: flex;
    align-items: center;
    min-height: 40px;
    padding: 0 12px;
}

.login-form input[type="email"],
.login-form input[type="password"],
.login-form input[type="text"] {
    width: 100%;
    height: 38px;
    padding: 8px 0;
    border: 0;
    outline: 0;
    color: var(--login-text);
    background: transparent;
    font-family: "Manrope", Arial, sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 20px;
}

.login-form input::placeholder {
    color: var(--login-placeholder);
    opacity: 1;
}

.login-form input:focus {
    outline: 0;
}

.login-field:focus-within {
    border-color: var(--login-primary);
    box-shadow: 0 0 0 2px rgba(0, 171, 145, 0.1);
}

.login-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 40px;
    padding: 0 24px;
    border-radius: var(--login-radius);
    font-size: 12px;
    font-weight: 700;
    line-height: 18px;
    text-decoration: none;
    cursor: pointer;
}

.login-button--primary {
    border: 1px solid var(--login-primary-border);
    background: var(--login-primary);
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
    color: #ffffff;
}

.login-button--secondary {
    border: 1px solid var(--login-secondary-border);
    background: #ffffff;
    color: var(--login-text);
}

.login-button:hover,
.login-button:focus-visible {
    filter: brightness(0.98);
}

.login-forgot-link {
    align-self: center;
    border: 0;
    background: transparent;
    color: var(--login-primary);
    font-family: "Manrope", Arial, sans-serif;
    font-size: 12px;
    font-weight: 800;
    line-height: 18px;
    cursor: pointer;
}

.login-validation,
.login-field-error {
    color: var(--login-error);
    font-size: 12px;
    font-weight: 600;
    line-height: 18px;
}

.login-validation ul {
    margin: 0;
    padding-left: 18px;
}

.reset-password-intro,
.reset-password-result {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.reset-password-intro h1,
.reset-password-result h1 {
    margin: 0;
    color: var(--login-text);
    font-size: 20px;
    font-weight: 700;
    line-height: 28px;
}

.reset-password-intro p,
.reset-password-result p,
.reset-password-help {
    margin: 0;
    color: #557272;
    font-size: 12px;
    font-weight: 600;
    line-height: 18px;
}

.reset-password-result {
    padding: 16px;
    border: 1px solid rgba(0, 171, 145, 0.22);
    border-radius: var(--login-radius);
    background: rgba(0, 171, 145, 0.06);
}

.login-field-error:empty,
.login-validation:empty {
    display: none;
}

.forgot-password-modal-backdrop {
    position: fixed;
    z-index: 1000;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(22, 35, 35, 0.38);
}

.forgot-password-modal-backdrop[hidden] {
    display: none;
}

.forgot-password-modal {
    width: min(360px, 100%);
    border: 1px solid #e7eaeb;
    border-radius: var(--login-radius);
    background: #fff;
    box-shadow: 0 1px 16px rgba(0, 0, 0, 0.08);
}

.forgot-password-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
}

.forgot-password-modal__header h2 {
    margin: 0;
    font-size: 16px;
    line-height: 22px;
}

.forgot-password-modal__close {
    position: relative;
    width: 28px;
    height: 28px;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.forgot-password-modal__close::before,
.forgot-password-modal__close::after {
    content: "";
    position: absolute;
    left: 7px;
    top: 13px;
    width: 14px;
    height: 2px;
    border-radius: 2px;
    background: #557272;
}

.forgot-password-modal__close::before {
    transform: rotate(45deg);
}

.forgot-password-modal__close::after {
    transform: rotate(-45deg);
}

.forgot-password-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 20px 20px;
}

.forgot-password-form .login-field,
.forgot-password-form .login-field:focus-within {
    border-color: transparent;
    box-shadow: none;
}

.forgot-password-form .login-field__control input {
    border: 0;
    outline: 0;
    box-shadow: none;
    appearance: none;
}

.forgot-password-modal__copy,
.forgot-password-modal__status {
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    line-height: 18px;
}

.forgot-password-modal__copy {
    color: #557272;
}

.forgot-password-modal__status {
    color: var(--login-error);
}

.forgot-password-modal__status--success {
    color: var(--login-primary);
}

.forgot-password-modal__footer {
    display: flex;
    gap: 8px;
}

.forgot-password-modal__footer .login-button {
    flex: 1;
}

.forgot-password-modal__footer .login-button:disabled {
    opacity: 0.55;
    cursor: wait;
}

@media (max-width: 520px) {
    .login-shell {
        align-items: flex-start;
        padding-top: 180px;
        padding-bottom: 48px;
    }
}
