/* ========================================= */
/* 1. ШРИФТЫ (ONEST - TTF) */
/* ========================================= */

@font-face {
    font-family: 'Onest';
    src: url('fonts/Onest-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Onest';
    src: url('fonts/Onest-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Onest';
    src: url('fonts/Onest-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Onest';
    src: url('fonts/Onest-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ========================================= */
/* 2. ГЛОБАЛЬНЫЕ СТИЛИ */
/* ========================================= */

:root {
    --main-color: #1E1E1E;
    --font-color: #1E1E1E;
}

* {
    box-sizing: border-box;
    min-height: 0;
    min-width: 0;
}

body, html {
    width: 100%;
    min-height: 100%;
    margin: 0;
    padding: 0;
    position: relative;
    background: #FFF !important; /* Белый фон */
    color: #000 !important;
    font-family: "Onest", sans-serif;
    font-size: 18px;
    line-height: normal;
    overflow-x: hidden;
}

/* Блокировка прокрутки для модалок */
body.overflow {
    overflow: hidden !important;
}

form {
    margin: 0;
    padding: 0;
    outline: none;
}

a {
    text-decoration: none;
    transition: all 0.2s ease;
    color: #1E1E1E;
}

a:hover {
    text-decoration: none;
}

/* ========================================= */
/* 3. СТРАНИЦА ВХОДА (REFASHION LOGIN) */
/* ========================================= */

.refashion-login-wrapper {
    width: 100%;
    min-height: 100vh;
    background: #FFF !important;
    color: #000 !important;
    font-family: "Onest", sans-serif;
    position: relative;
    z-index: 10;
}

.refashion-login-container {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* --- ЛЕВАЯ КОЛОНКА (КАРТИНКА) --- */
.refashion-login-visual {
    flex: 0 0 32%;
    width: 45%;
    background-repeat: no-repeat;
    /* Чтобы лицо всегда было видно и картинка заполняла весь блок */
    background-size: cover !important;
    background-position: center center !important;
    min-height: 100vh;
    /* КАРТИНКА ДЛЯ ПК */
    background-image: url("/images/login-bg-new.png");
}

/* --- ПРАВАЯ КОЛОНКА (КОНТЕНТ) --- */
.refashion-login-body {
    flex: 1 1 auto;
    width: 55%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Отступы: верх 60, бока 80, низ 100 (место для футера) */
    padding: 60px 80px 100px 80px; 
    background: #FFF !important;
    position: relative; /* Чтобы футер позиционировался относительно этого блока */
    min-height: 100vh; /* Растягиваем на всю высоту экрана */
}

.refashion-login-content {
    max-width: 650px;
    width: 100%;
    position: relative;
    z-index: 2;
}

/* Типографика */
.rf-title {
    font-size: 32px !important;
    line-height: 1.2 !important;
    font-weight: 600 !important;
    color: #000 !important;
    margin-bottom: 30px !important;
    text-transform: none !important;
}

.rf-features {
    margin-bottom: 40px;
}

.rf-features__title {
    font-size: 16px;
    margin-bottom: 10px;
    color: #000;
}

.rf-features__list {
    margin: 0;
    padding-left: 20px;
    list-style-type: disc;
}

.rf-features__list li {
    font-size: 16px;
    line-height: 1.4;
    color: #000;
    margin-bottom: 5px;
}

.rf-cta {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 25px;
    color: #000;
    text-transform: lowercase;
}

/* Поля ввода (Линии) */
.rf-input-group {
    margin-bottom: 25px;
}

.rf-input-group label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #000;
    text-transform: lowercase;
}

.rf-input {
    width: 100%;
    border: none !important;
    border-bottom: 1px solid #000 !important; /* Черная линия */
    background: transparent !important;
   
    font-size: 18px !important;
    color: #000 !important;
    border-radius: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    padding: 10px;
    padding-left: 10px;
}

.rf-input::placeholder {
    color: #999;
    font-weight: 300;
}

.rf-input2 {
    margin-left: 7px;
    width: 100%;
    border: none !important;
    border-bottom: 1px solid #000 !important; /* Черная линия */
    background: transparent !important;
    padding: 10px 0 !important;
    font-size: 18px !important;
    color: #000 !important;
    border-radius: 0 !important;
    outline: none !important;
    box-shadow: none !important;
}

/* --- ИСПРАВЛЕНИЕ СИНЕГО ФОНА (AUTOFILL) --- */
input:-webkit-autofill,
input:-webkit-autofill:hover, 
input:-webkit-autofill:focus, 
input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px white inset !important; /* Заливаем белым */
    -webkit-text-fill-color: #000 !important;
    transition: background-color 5000s ease-in-out 0s;
}

.rf-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

/* Глаз пароля */
.pass-wrapper {
    position: relative;
}
.input__pass {
    position: absolute;
    right: 0;
    bottom: 10px;
    z-index: 5;
    cursor: pointer;
}
.input__pass svg path {
    stroke: #000;
}

/* Кнопки */
.rf-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 40px;
}

.rf-btn {
    width: 100%;
    max-width: 380px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    text-transform: lowercase;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
    -webkit-appearance: none;
    border-radius: 0;
}

.rf-btn-white {
    background: #FFF !important;
    color: #000 !important;
    border: 1px solid #000 !important;
    border-radius: 30px
}
.rf-btn-white:hover {
    background: #000 !important;
    color: #FFF !important;
    border-radius: 30px
}

.rf-btn-blue {
    background: #8ab4d0 !important;
    color: #000 !important;
    border: 1px solid #000 !important;
    border-radius: 30px
}
.rf-btn-blue:hover {
    opacity: 0.8;
    border-radius: 30px
}

/* Ошибки */
.form-login__error {
    color: #BE1818;
    font-size: 14px;
    margin-bottom: 15px;
    display: none;
}
.form-login__error .blue-not { color: #1065b6; font-weight: bold; }
.form-login__error .red-not { color: #BE1818; font-weight: bold; }

/* --- ФУТЕР (ПОДВАЛ) --- */
.rf-footer {
    position: absolute; /* Прибиваем к низу родителя */
    left: 0;
    bottom: 0; /* Самый низ */
    width: 100%;
    padding: 20px 80px; /* Отступы по бокам как у контента */
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    font-size: 10px;
    color: #666;
    z-index: 5;
}

.rf-footer__left a {
    color: #666;
    text-decoration: underline;
    font-size: 12px;
}

.rf-footer__right {
    display: flex;
    gap: 20px;
    text-align: right;
    text-transform: lowercase;
}

.rf-footer__right div {
    white-space: nowrap;
    color: #666;
    font-size: 10px;
    display: inline-block;
}
.rf-footer__right a {
    color: #666;
    text-decoration: none;
}

/* ========================================= */
/* 4. АДАПТАЦИЯ (MEDIA QUERIES) */
/* ========================================= */

/* --- Планшет / Ноутбук (до 1279px) --- */
@media (max-width: 1279px) {
    .refashion-login-visual {
        /* КАРТИНКА ДЛЯ ПЛАНШЕТА */
        background-image: url("/images/login-bg-new-tablet.png");
        flex: 0 0 40%;
        width: 40%;
        background-position: top center !important;
    }
    .refashion-login-body {
        width: 60%;
        padding: 40px 40px 80px 40px; /* Низ 80px для футера */
    }
    .rf-footer {
        padding: 20px 40px;
        flex-wrap: wrap; 
    }
}

/* --- Мобильная версия (до 991px) --- */
@media (max-width: 1024px) {
    .refashion-login-container {
        flex-direction: column;
    }

    .refashion-login-visual {
        background-image: url("/images/login-bg-new-tablet.png"); 
        width: 100%;
        height: 650px;
        min-height: auto;
        flex: none;
        background-position: top center !important;
    }

    .refashion-login-body {
        width: 100%;
        flex: auto;
        padding: 30px 20px;
        min-height: auto;
        justify-content: flex-start;
    }

    .rf-title {
        font-size: 24px !important;
        margin-top: 10px !important;
    }

    .rf-btn {
        max-width: 100%;
    }

    /* На мобильном футер отклеиваем от низа, он идет потоком */
    .rf-footer {
        position: relative;
        bottom: auto;
        left: auto;
        padding: 20px 0 0 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        margin-top: 40px;
    }

    .rf-footer__right {
        flex-wrap: wrap;
        text-align: left;
        justify-content: flex-start;
        gap: 10px;
    }
    
    .rf-footer__right div {
        width: 48%; 
        white-space: normal;
    }
}

/* --- Маленькие экраны (до 768px) --- */
@media (max-width: 768px) {
    .refashion-login-visual {
        /* КАРТИНКА ДЛЯ ТЕЛЕФОНА */
        background-image: url("/images/login-bg-new-mobile.png"); 
        height: 300px;
        background-size: cover !important;
        background-position: top center !important;
    }
    
    .rf-footer__right div {
        width: 100%; 
    }
}

/* ========================================= */
/* 5. СТИЛИ МОДАЛЬНОГО ОКНА */
/* ========================================= */

.modal {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 9990;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(4px);
    display: none;
}

.modal__shadow {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 9991;
    width: 100%;
    height: 100%;
    background: rgba(30, 30, 30, 0.50);
}

.modal__body {
    position: fixed;
    left: 50%;
    top: 50%;
    z-index: 9992;
    width: 100%;
    max-width: 500px;
    max-height: 96vh;
    overflow-y: auto;
    background: #FFF;
    transform: translate(-50%, -50%);
    padding: 40px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.modal__close {
    position: absolute;
    right: 16px;
    top: 16px;
    z-index: 2;
    cursor: pointer;
    width: 28px;
    height: 28px;
}

.modal__close svg path {
    stroke: #000;
    transition: all 0.2s ease;
}

.modal__close:hover svg path {
    stroke: #BE1818;
}

.modal__caption {
    color: #1E1E1E;
    font-size: 24px;
    line-height: 1.2;
    margin-bottom: 20px;
    text-align: center;
    font-weight: 600;
}

.modal__caption.mb-0 {
    margin-bottom: 0;
}

.modal__inner {
    font-size: 16px;
    text-align: center;
    color: #000;
}

@media (max-width: 768px) {
    .modal__body {
        width: 90%;
        padding: 30px 20px;
    }
    .modal__caption {
        font-size: 20px;
    }
}
