/*
    Современный дизайн страницы входа с анимацией
*/

/* Базовые стили */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* Анимированный фон */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.bg-bubble {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 20s infinite ease-in-out;
}

.bubble-1 {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
    animation-duration: 25s;
}

.bubble-2 {
    width: 120px;
    height: 120px;
    top: 60%;
    left: 80%;
    animation-delay: 2s;
    animation-duration: 30s;
}

.bubble-3 {
    width: 60px;
    height: 60px;
    top: 80%;
    left: 20%;
    animation-delay: 4s;
    animation-duration: 20s;
}

.bubble-4 {
    width: 100px;
    height: 100px;
    top: 10%;
    left: 60%;
    animation-delay: 1s;
    animation-duration: 35s;
}

.bubble-5 {
    width: 140px;
    height: 140px;
    top: 40%;
    left: 40%;
    animation-delay: 3s;
    animation-duration: 28s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) translateX(0) scale(1);
        opacity: 0.1;
    }
    25% {
        transform: translateY(-20px) translateX(10px) scale(1.05);
        opacity: 0.15;
    }
    50% {
        transform: translateY(10px) translateX(-10px) scale(0.95);
        opacity: 0.1;
    }
    75% {
        transform: translateY(-10px) translateX(15px) scale(1.02);
        opacity: 0.12;
    }
}

/* Контейнер для уведомлений */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 380px;
}

.notification {
    background: white;
    border-radius: 16px;
    padding: 18px 22px;
    margin-bottom: 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    transform: translateX(120%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-left: 4px solid #667eea;
    backdrop-filter: blur(10px);
}

.notification-show {
    transform: translateX(0);
}

.notification-icon {
    margin-right: 16px;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-message {
    font-size: 15px;
    color: #333;
    line-height: 1.5;
    font-weight: 500;
}

.notification-close {
    margin-left: 16px;
    cursor: pointer;
    color: #999;
    transition: all 0.2s;
    font-size: 14px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.notification-close:hover {
    color: #666;
    background: #f5f5f5;
    transform: scale(1.1);
}

.notification-info {
    border-left-color: #667eea;
}

.notification-info .notification-icon {
    background: #f0f4ff;
    color: #667eea;
}

.notification-success {
    border-left-color: #10b981;
}

.notification-success .notification-icon {
    background: #ecfdf5;
    color: #10b981;
}

.notification-warning {
    border-left-color: #f59e0b;
}

.notification-warning .notification-icon {
    background: #fffbeb;
    color: #f59e0b;
}

.notification-error {
    border-left-color: #ef4444;
}

.notification-error .notification-icon {
    background: #fef2f2;
    color: #ef4444;
}

/* Основной контейнер */
.login-wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

/* Карточка входа */
.login-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 30px !important;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateY(30px) scale(0.95);
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.login-card.animate-in {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* Заголовок */
.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-title {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    margin: 0 0 12px;
    letter-spacing: -0.5px;
}

.login-subtitle {
    font-size: 16px;
    color: #666;
    margin: 0;
    font-weight: 400;
}

/* Поля формы */
.form-field {
    margin-bottom: 28px;
}

.field-label {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
    transition: all 0.3s;
}

.label-focused {
    color: #667eea;
    transform: translateY(-2px);
}

.field-input {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 10px !important;
    font-size: 16px;
    transition: all 0.3s;
    background: white;
    color: #333;
    font-weight: 500;
}

.field-input:focus {
    border-color: #667eea;
    outline: none;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
}

.input-focused {
    transform: translateY(-2px);
/* Дополнительные стили для обеспечения скруглений */
input[type="text"].field-input,
input[type="password"].field-input {
    border-radius: 30px !important;
    -webkit-border-radius: 30px !important;
    -moz-border-radius: 30px !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

}

/* Опции формы */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 36px;
    padding: 0 4px;
}

.checkbox-container {
    display: flex;
    align-items: center;
}

.checkbox-input {
    width: 22px;
    height: 22px;
    margin-right: 12px;
    accent-color: #667eea;
    cursor: pointer;
    border-radius: 6px;
}

.checkbox-label {
    font-size: 15px;
    color: #666;
    cursor: pointer;
    user-select: none;
    font-weight: 500;
}

.forgot-link {
    font-size: 15px;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    padding: 8px 12px;
    border-radius: 12px;
}

.forgot-link:hover {
    color: #5a67d8;
    transform: translateY(-1px);
    background: rgba(102, 126, 234, 0.05);
}

/* Кнопка входа */
.login-button {
    width: 100%;
    padding: 20px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 30px !important;
    color: white;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.login-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.4);
}

.login-button:active {
    transform: translateY(-1px);
}

.button-text {
    transition: all 0.3s;
}

.button-loader {
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    margin-left: 10px;
    transition: all 0.3s;
}

.button-loading .button-text {
    opacity: 0.7;
}

.button-loading .button-loader {
    width: 20px;
    height: 20px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.8);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.4;
    }
    100% {
        transform: scale(0.8);
        opacity: 0.8;
    }
}

/* Подвал карточки */
.login-footer {
    margin-top: 36px;
    text-align: center;
    padding: 0 4px;
}

.browser-info {
    font-size: 13px;
    color: #999;
    margin: 0;
}

/* Адаптивность */
@media (max-width: 768px) {
    .login-wrapper {
        padding: 16px;
    }
    
    .login-card {
        padding: 30px 24px;
        border-radius: 20px;
    }
    
    .login-title {
        font-size: 28px;
    }
    
    .field-input {
        padding: 16px 18px;
        font-size: 15px;
    }
    
    .notification-container {
        left: 16px;
        right: 16px;
        max-width: none;
    }
}

/* Стили для старых браузеров */
.lt-ie10 .login-card,
.no-js .login-card {
    opacity: 1;
    transform: none;
}

.lt-ie10 .notification,
.no-js .notification {
    transform: none;
    display: block;
}