/* ========================================
   Ultimate Member — Login / Registration
======================================== */

body.um-page-login,
body.um-page-register {
    --auth-primary: #4f6bff;
    --auth-violet: #7a61ff;
    --auth-text: #182238;
    --auth-muted: #8c94ab;
    --auth-border: #e3e7f2;
    --auth-surface: #ffffff;
    --auth-field: #f9faff;
    --auth-background: #f5f7fc;

    background:
        linear-gradient(135deg,
            rgb(79 107 255 / 4%),
            transparent 45%),
        var(--auth-background);
}

/* Картка */

body.um-page-login .um,
body.um-page-register .um {
    position: relative;

    width: calc(100% - 32px);
    max-width: 600px !important;
    margin: 48px auto !important;
    padding: 46px 48px 40px !important;

    overflow: hidden;

    border: 1px solid var(--auth-border);
    border-radius: 20px;
    background: var(--auth-surface);

    box-shadow: 0 16px 45px rgb(16 34 73 / 8%);
}

/* Верхня градієнтна лінія */

body.um-page-login .um::before,
body.um-page-register .um::before {
    content: "";

    position: absolute;
    z-index: 1;
    top: 0;
    right: 0;
    left: 0;

    height: 5px;

    background: linear-gradient(90deg,
            var(--auth-primary),
            var(--auth-violet));
}

/* Частина декоративного круга */

body.um-page-login .um::after,
body.um-page-register .um::after {
    content: "";

    position: absolute;
    top: -72px;
    right: -72px;

    width: 160px;
    height: 160px;

    border-radius: 50%;
    background: linear-gradient(135deg,
            rgb(79 107 255 / 7%),
            rgb(180 74 255 / 12%));

    pointer-events: none;
}

/* Форма поверх декору */

body.um-page-login .um-form,
body.um-page-register .um-form {
    position: relative;
    z-index: 2;

    margin: 0 !important;
}

/* Відступи між полями */

body.um-page-login .um-field,
body.um-page-register .um-field {
    margin-bottom: 22px !important;
}

/* Назви полів */

body.um-page-login .um-field-label,
body.um-page-register .um-field-label {
    margin-bottom: 8px !important;
}

body.um-page-login .um-field-label label,
body.um-page-register .um-field-label label {
    color: var(--auth-text) !important;

    font-family: inherit !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
}

body.um-page-login .um-required,
body.um-page-register .um-required {
    color: var(--auth-violet) !important;
}

/* Поля */

body.um-page-login .um-form input[type="text"],
body.um-page-login .um-form input[type="email"],
body.um-page-login .um-form input[type="password"],
body.um-page-login .um-form input[type="tel"],
body.um-page-register .um-form input[type="text"],
body.um-page-register .um-form input[type="email"],
body.um-page-register .um-form input[type="password"],
body.um-page-register .um-form input[type="tel"],
body.um-page-register .um-form select,
body.um-page-register .um-form textarea {
    width: 100% !important;
    min-height: 50px !important;
    padding: 0 15px !important;

    border: 1px solid var(--auth-border) !important;
    border-radius: 10px !important;
    outline: none !important;
    background: var(--auth-field) !important;

    color: var(--auth-text) !important;

    font-family: inherit !important;
    font-size: 15px !important;
    line-height: 1.5 !important;

    box-shadow: none !important;

    transition:
        border-color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

body.um-page-login .um-form input:hover,
body.um-page-register .um-form input:hover,
body.um-page-register .um-form select:hover,
body.um-page-register .um-form textarea:hover {
    border-color: #cfd5e6 !important;
    background: #ffffff !important;
}

body.um-page-login .um-form input:focus,
body.um-page-register .um-form input:focus,
body.um-page-register .um-form select:focus,
body.um-page-register .um-form textarea:focus {
    border-color: var(--auth-primary) !important;
    background: #ffffff !important;

    box-shadow: 0 0 0 4px rgb(79 107 255 / 10%) !important;
}

body.um-page-login .um-form input::placeholder,
body.um-page-register .um-form input::placeholder,
body.um-page-register .um-form textarea::placeholder {
    color: var(--auth-muted) !important;
    opacity: 1;
}

/* Показ пароля */

body.um-page-login .um-toggle-password,
body.um-page-register .um-toggle-password {
    color: var(--auth-muted) !important;
}

body.um-page-login .um-toggle-password:hover,
body.um-page-register .um-toggle-password:hover {
    color: var(--auth-primary) !important;
}

/* Checkbox */

body.um-page-login .um-field-checkbox,
body.um-page-register .um-field-checkbox {
    display: flex !important;
    align-items: center !important;
    gap: 9px !important;

    width: fit-content;
    margin: 0 !important;

    cursor: pointer;
}

body.um-page-login .um-field-checkbox-state,
body.um-page-register .um-field-checkbox-state {
    position: static !important;

    display: flex !important;
    flex: 0 0 20px;
    align-items: center;
    justify-content: center;

    width: 20px !important;
    height: 20px !important;
    margin: 0 !important;
}

body.um-page-login .um-field-checkbox-state i,
body.um-page-register .um-field-checkbox-state i {
    position: static !important;

    margin: 0 !important;

    color: var(--auth-primary) !important;

    font-size: 20px !important;
    line-height: 1 !important;
}

body.um-page-login .um-field-checkbox-option,
body.um-page-register .um-field-checkbox-option {
    position: static !important;

    margin: 0 !important;
    padding: 0 !important;

    color: #667085 !important;

    font-size: 14px !important;
    line-height: 1.4 !important;
}

/* Блок кнопок */

body.um-page-login .um-col-alt,
body.um-page-register .um-col-alt {
    margin-top: 10px !important;
}

body.um-page-login .um-col-alt::after,
body.um-page-register .um-col-alt::after {
    content: "";
    display: block;
    clear: both;
}

/* Спільний стиль кнопок */

body.um-page-login .um-button,
body.um-page-register .um-button {
    min-height: 50px !important;
    padding: 12px 18px !important;

    border-radius: 10px !important;

    font-family: inherit !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;

    text-shadow: none !important;
    text-transform: none !important;

    opacity: 1 !important;
    cursor: pointer;

    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

/* Головна кнопка */

body.um-page-login input[type="submit"].um-button,
body.um-page-register input[type="submit"].um-button {
    border: 0 !important;

    background: linear-gradient(90deg,
            var(--auth-primary),
            var(--auth-violet)) !important;

    color: #ffffff !important;

    box-shadow: 0 8px 18px rgb(79 107 255 / 18%) !important;
}

body.um-page-login input[type="submit"].um-button:hover,
body.um-page-register input[type="submit"].um-button:hover {
    color: #ffffff !important;

    box-shadow: 0 11px 22px rgb(79 107 255 / 24%) !important;

    transform: translateY(-1px);
}

/* Друга кнопка */

body.um-page-login .um-button.um-alt,
body.um-page-register .um-button.um-alt {
    border: 1px solid #dfe3f1 !important;
    background: #f7f8ff !important;

    color: var(--auth-primary) !important;

    box-shadow: none !important;
}

body.um-page-login .um-button.um-alt:hover,
body.um-page-register .um-button.um-alt:hover {
    border-color: #cfd5f4 !important;
    background: #f0f2ff !important;

    color: var(--auth-violet) !important;

    transform: translateY(-1px);
}

/* Забули пароль */

body.um-page-login .um-col-alt-b,
body.um-page-register .um-col-alt-b {
    margin-top: 22px !important;
    padding-top: 20px;

    border-top: 1px solid var(--auth-border);

    text-align: center;
}

/* Посилання */

body.um-page-login .um a,
body.um-page-register .um a {
    color: var(--auth-primary) !important;

    font-weight: 500;
    text-decoration: none !important;
}

body.um-page-login .um a:hover,
body.um-page-register .um a:hover {
    color: var(--auth-violet) !important;
}

/* Помилки */

body.um-page-login .um-error,
body.um-page-register .um-error {
    margin-bottom: 20px !important;
    padding: 12px 14px !important;

    border: 1px solid #ffd5dc !important;
    border-radius: 10px !important;
    background: #fff5f7 !important;

    color: #bd334b !important;

    font-size: 14px !important;
    line-height: 1.5 !important;

    box-shadow: none !important;
}

body.um-page-login .um-error::before,
body.um-page-register .um-error::before {
    display: none !important;
}

body.um-page-login .um-field-error,
body.um-page-register .um-field-error {
    margin-top: 7px !important;
    padding: 7px 9px !important;

    border-radius: 7px !important;
    background: #fff5f7 !important;

    color: #bd334b !important;

    font-size: 13px !important;
}

/* Автозаповнення */

body.um-page-login input:-webkit-autofill,
body.um-page-register input:-webkit-autofill {
    -webkit-text-fill-color: var(--auth-text) !important;

    box-shadow: 0 0 0 1000px var(--auth-field) inset !important;
}

/* Мобільна версія */

@media (max-width: 600px) {

    body.um-page-login .um,
    body.um-page-register .um {
        width: calc(100% - 24px);
        margin: 24px auto !important;
        padding: 38px 20px 28px !important;

        border-radius: 16px;
    }

    body.um-page-login .um::after,
    body.um-page-register .um::after {
        top: -60px;
        right: -60px;

        width: 130px;
        height: 130px;
    }

    body.um-page-login .um-form input,
    body.um-page-register .um-form input {
        font-size: 16px !important;
    }

    body.um-page-login .um-left,
    body.um-page-login .um-right,
    body.um-page-register .um-left,
    body.um-page-register .um-right {
        float: none !important;

        width: 100% !important;
        margin-bottom: 10px;
    }
}

body.um-page-login .entry-title,
body.um-page-register .entry-title,
body.um-page-password-reset .entry-title {
    display: none;
}

.custom-auth-heading {
    position: relative;
    z-index: 2;

    margin: 0 0 30px;
}

.custom-auth-heading h1 {
    margin: 0 0 8px !important;

    color: var(--auth-text) !important;

    font-family: inherit !important;
    font-size: 30px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
}

.custom-auth-heading__description {
    max-width: 470px;
    margin: 0 !important;

    color: var(--auth-muted) !important;

    font-family: inherit !important;
    font-size: 15px !important;
    font-weight: 400 !important;
    line-height: 1.6 !important;
}

@media (max-width: 768px) {
    .custom-auth-heading {
        max-width: 420px;
        margin-bottom: 26px;
    }

    .custom-auth-heading__title {
        font-size: 28px !important;
    }

    .custom-auth-heading__description {
        font-size: 15px !important;
    }
}

/* Телефон */

@media (max-width: 600px) {
    .custom-auth-heading {
        max-width: calc(100% - 50px);
        margin-bottom: 24px;
    }

    .custom-auth-heading__title {
        margin-bottom: 8px !important;

        font-size: 25px !important;
        line-height: 1.2 !important;
    }

    .custom-auth-heading__description {
        font-size: 14px !important;
        line-height: 1.55 !important;
    }
}

/* Дуже вузькі екрани */

@media (max-width: 380px) {
    .custom-auth-heading {
        max-width: calc(100% - 32px);
    }

    .custom-auth-heading__title {
        font-size: 23px !important;
    }

    .custom-auth-heading__description {
        font-size: 13px !important;
    }
}