@import url('https://fonts.googleapis.com/css2?family=Poppins&display=swap');

* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

/* Применяем шрифт только к тексту, но не к иконкам */
body, input, button, a, p, h1, h2, h3, span, label {
    font-family: 'Poppins', sans-serif;
}

/* Гарантируем, что иконки используют свой шрифт */
i {
    font-family: 'boxicons' !important;
}

input:-internal-autofill-selected {
    background-color: transparent !important;
    
}
/* === НАСТРОЙКА ПОЗИЦИОНИРОВАНИЯ === */
body {
    display: flex;
    /* По умолчанию выравниваем по вертикали (центр) и горизонтали (конец) */
    align-items: center;
    justify-content: flex-end;
    min-height: 100vh;
    background-size: cover;
    background-position: center;
}

/* Карточка входа */
.wrapper {
    width: 420px;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, .2);
    backdrop-filter: blur(20px);
    box-shadow: 0 0 10px rgba(0, 0, 0, .2);
    color: #fff;
    border-radius: 10px;
    padding: 30px 40px;
    /* ОТСТУП СПРАВА (25% от экрана) */
    margin-right: 15%;
    /* Анимация появления (опционально) */
    animation: fadeInRight 1s ease;
}

/* === АДАПТИВНОСТЬ (МОБИЛЬНЫЕ) === */
@media (max-width: 992px) {
    body {
        /* На планшетах и телефонах — строго по центру */
        justify-content: center;
    }

    .wrapper {
        /* Убираем отступ справа */
        margin-right: 0;
        /* Можно немного уменьшить ширину для телефонов */
        width: 90%;
        max-width: 420px;
    }
}

/* === ВИДЕО ФОН === */
.video-background {
    position: fixed;
    right: 0;
    bottom: 0;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -1000;
    overflow: hidden;
}

#myVideo {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -1000;
    transform: translateX(-50%) translateY(-50%);
}

/* === СТИЛИ ЛОГОТИПА === */
.login-logo {
    text-align: center;
    margin-bottom: 20px; /* Отступ до заголовка "Вход" */
}

    .login-logo img {
        max-width: 150px; /* Максимальная ширина логотипа */
        height: auto;
        /* Если логотип черный, можно инвертировать цвет фильтром, 
       или лучше сразу загрузить белый PNG */
        /* filter: invert(1); */
    }

/* === ВНУТРЕННОСТИ ФОРМЫ === */
.wrapper h1 {
    font-size: 36px;
    text-align: center;
    margin-bottom: 20px; /* Немного отступа снизу заголовка */
}

.wrapper .input-box {
    position: relative;
    width: 100%;
    height: 50px;
    margin: 30px 0;
}

.input-box input {
    width: 100%;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    border: 2px solid rgba(255, 255, 255, .2);
    border-radius: 40px;
    font-size: 16px;
    color: #fff;
    padding: 20px 45px 20px 20px;
}

    .input-box input::placeholder {
        color: #e0e0e0; /* Чуть светлее */
    }

.input-box i {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
}

.wrapper .remember-forgot {
    display: flex;
    justify-content: space-between;
    font-size: 14.5px;
    margin: -15px 0 15px;
}

.remember-forgot label input {
    accent-color: #fff;
    margin-right: 3px;
}

.remember-forgot a {
    color: #fff;
    text-decoration: none;
}

    .remember-forgot a:hover {
        text-decoration: underline;
    }

.wrapper .btn {
    width: 100%;
    height: 45px;
    border-radius: 40px;
    border: none;
    outline: none;
    background: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, .1);
    cursor: pointer;
    font-size: 16px;
    color: #333;
    font-weight: 600;
    transition: .3s;
}

    .wrapper .btn:hover {
        background: #f0f0f0;
    }

/* Анимация входа справа (для красоты) */
@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* === КНОПКИ ДЕЙСТВИЙ (Восстановить + Назад) === */
.action-buttons {
    display: flex; /* Выстраиваем в ряд */
    align-items: center; /* Центрируем по вертикали */
    gap: 15px; /* Расстояние между кнопками */
    margin-top: 20px;
}

    /* Основная кнопка (Восстановить) */
    .action-buttons .btn {
        flex-grow: 1; /* Занимает всё доступное место */
        margin: 0; /* Убираем лишние отступы */
    }

/* Кнопка Назад (Кружок) */
.btn-back {
    display: flex;
    justify-content: center;
    align-items: center;
    /* Фиксируем размеры, чтобы был идеальный круг */
    width: 45px;
    height: 45px;
    min-width: 45px; /* Чтобы не сжималась */

    background: rgba(255, 255, 255, 0.1); /* Полупрозрачный белый фон */
    border: 1px solid rgba(255, 255, 255, 0.5); /* Более заметная рамка */
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    font-size: 24px;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

    .btn-back:hover {
        background: #fff; /* При наведении становится белой */
        color: #333; /* Стрелка становится темной */
        border-color: #fff;
        transform: translateX(3px); /* Легкий сдвиг вправо или scale(1.1) */
        box-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
    }

/* === ИСПРАВЛЕНИЕ АВТОЗАПОЛНЕНИЯ (AUTOFILL) === */

/* Таргетируем все состояния автозаполнения */
.input-box input:-webkit-autofill,
.input-box input:-webkit-autofill:hover,
.input-box input:-webkit-autofill:focus,
.input-box input:-webkit-autofill:active {
    /* 1. Меняем цвет текста на белый */
    -webkit-text-fill-color: #fff !important;
    /* 2. Магия для прозрачного фона: 
       Мы ставим задержку смены фона на 5000 секунд.
       В итоге пользователь видит ваш оригинальный прозрачный фон. */
    transition: background-color 5000s ease-in-out 0s;
    /* 3. Цвет каретки (мигающего курсора) тоже делаем белым */
    caret-color: #fff;
    /* На всякий случай сохраняем размер и бордеры */
    border: 2px solid rgba(255, 255, 255, .2) !important;
}