* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #4A6D8C 0%, #5B85AC 50%, #6D9AC4 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    position: relative;
    overflow: hidden;
}

/* Анимированные декоративные элементы на фоне */
body::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: -250px;
    right: -250px;
    animation: float 20s infinite ease-in-out;
}

body::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    bottom: -150px;
    left: -150px;
    animation: float 15s infinite ease-in-out reverse;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(180deg);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.login-card {
    background: white;
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    max-width: 440px;
    width: 100%;
    position: relative;
    z-index: 10;
    animation: fadeInUp 0.6s ease-out;
}

.login-header {
    background: linear-gradient(135deg, #2C4A63 0%, #1E3A52 100%);
    color: white;
    padding: 3rem 2rem 2.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.login-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: pulse 4s infinite ease-in-out;
}

.login-header > * {
    position: relative;
    z-index: 2;
}

.login-header .icon-wrapper {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.login-header .icon-wrapper i {
    font-size: 2.5rem;
}

.login-header h3 {
    font-weight: 700;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.login-header p {
    font-size: 0.95rem;
    opacity: 0.9;
}

.login-body {
    padding: 2.5rem;
}

.form-label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.input-group {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.input-group:focus-within {
    border-color: #2C4A63;
    box-shadow: 0 0 0 4px rgba(44, 74, 99, 0.15);
    background: white;
}

.input-group-text {
    background: transparent;
    border: none;
    border-right: none;
    color: #6c757d;
    padding: 0 0.75rem 0 1rem;
}

.input-group:focus-within .input-group-text {
    color: #2C4A63;
}

.form-control {
    border: none;
    border-left: none;
    padding: 0.875rem 1rem;
    background: transparent;
    font-size: 0.95rem;
}

.form-control:focus {
    border: none;
    box-shadow: none;
    background: transparent;
}

.password-toggle {
    background: transparent;
    border: none;
    padding: 0 1rem 0 0.5rem;
    cursor: pointer;
    color: #6c757d;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: #2C4A63;
}

.btn-login {
    background: linear-gradient(135deg, #2C4A63 0%, #1E3A52 100%);
    border: none;
    border-radius: 12px;
    padding: 0.875rem 1.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(44, 74, 99, 0.5);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login .spinner-border {
    display: none;
    width: 1rem;
    height: 1rem;
    border-width: 2px;
}

.btn-login.loading .spinner-border {
    display: inline-block;
}

.btn-login.loading .btn-text {
    display: none;
}

.alert {
    border-radius: 12px;
    border: none;
    animation: fadeInUp 0.4s ease-out;
}

.alert-danger {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: white;
}

.footer-text {
    color: #6c757d;
    font-size: 0.85rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e9ecef;
}

/* Адаптивность */
@media (max-width: 576px) {
    .login-card {
        margin: 1rem;
    }

    .login-header {
        padding: 2rem 1.5rem;
    }

    .login-body {
        padding: 2rem 1.5rem;
    }
}

