/**
 * AAI Admin - Login Page Styles
 * GREEN PREMIUM THEME
 * Professional • Aviation • Trusted
 */

/* CSS Variables - AAI Green Theme */
:root {
    --primary-color: #07a85c;
    --primary-dark: #05964a;
    --primary-light: #09c46e;
    --accent-color: #07a85c;
    --accent-hover: #09c46e;
    --secondary-color: #054d32;
    --white: #ffffff;
    --light-gray: #f8f9fa;
    --dark-gray: #6c757d;
    --bg-dark: #052b1e;
    --glass-bg: rgba(5, 43, 30, 0.75);
    --glass-border: rgba(7, 168, 92, 0.3);
}

/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    min-height: 100vh;
    background: var(--bg-dark);
    overflow-x: hidden;
}

/* Background Container */
.login-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* Background Image with Dark Overlay */
.login-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(135deg, rgba(5, 77, 50, 0.9), rgba(7, 168, 92, 0.85)),
        url('https://images.unsplash.com/photo-1436491865332-7a61a109cc05?w=1920');
    background-size: cover;
    background-position: center;
    filter: blur(2px);
}

/* Animated Particles/Effect */
.login-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(7, 168, 92, 0.4) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(7, 168, 92, 0.15) 0%, transparent 40%);
    animation: pulseGlow 8s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Main Login Container */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* Login Card */
.login-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 0;
    width: 100%;
    max-width: 800px;
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(7, 168, 92, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: fadeInUp 0.6s ease-out;
    overflow: hidden;
}

.login-card .row {
    min-height: 500px;
}

/* Brand Section - Left Column */
.login-brand-section {
    background: linear-gradient(135deg, rgba(5, 77, 50, 0.9), rgba(7, 168, 92, 0.85));
    padding: 50px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.login-brand-section::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 1px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, rgba(7, 168, 92, 0.3), transparent);
}

.brand-content {
    position: relative;
    z-index: 1;
}

/* Logo in Brand Section */
.login-brand-logo {
    margin-bottom: 20px;
}

.brand-logo {
    max-width: 180px;
    height: auto;
    filter: brightness(0) invert(1);
    opacity: 0.95;
}

.brand-divider {
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    margin: 25px auto;
}

/* Form Section - Right Column */
.login-form-section {
    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Login Title */
.login-title {
    text-align: center;
    margin-bottom: 30px;
}

.login-title h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 8px;
}

.login-title p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Form Group */
.form-group {
    margin-bottom: 24px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 8px;
}

/* Input Wrapper */
.input-wrapper {
    position: relative;
    width: 100%;
}

/* Icon on the left - Fixed alignment */
.input-icon-left {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-color);
    font-size: 1.1rem;
    z-index: 1;
    transition: color 0.3s ease;
    pointer-events: none;
    line-height: 1;
}

/* Toggle icon on the right */
.password-toggle-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--accent-color);
    font-size: 1.1rem;
    z-index: 10;
    pointer-events: auto;
    transition: color 0.3s ease;
    padding: 4px;
    line-height: 1;
}

.password-toggle-icon:hover {
    color: var(--accent-hover);
}

.input-wrapper input:focus ~ .input-icon-left {
    color: var(--accent-hover);
}

.input-wrapper input {
    width: 100%;
    padding: 14px 44px 14px 44px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    color: var(--white);
    font-size: 1rem;
    transition: all 0.3s ease;
    outline: none;
}

.input-wrapper input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.input-wrapper input:focus {
    border-color: var(--accent-color);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 3px rgba(7, 168, 92, 0.15);
}

/* Login Button */
.btn-login {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--accent-color), #05964a);
    border: none;
    border-radius: 12px;
    color: var(--white);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 10px;
    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.3), transparent);
    transition: left 0.5s ease;
}

.btn-login:hover {
    background: linear-gradient(135deg, var(--accent-hover), var(--accent-color));
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(7, 168, 92, 0.3);
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:active {
    transform: translateY(0);
}

/* Error Message */
.alert-error {
    background: rgba(220, 53, 69, 0.15);
    border: 1px solid rgba(220, 53, 69, 0.3);
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 24px;
    color: #ff6b7a;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.alert-error i {
    font-size: 1.1rem;
}

/* Success Message */
.alert-success {
    background: rgba(25, 135, 84, 0.15);
    border: 1px solid rgba(25, 135, 84, 0.3);
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 24px;
    color: #75b798;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.8rem;
}

/* Responsive Design */
@media (max-width: 991px) {
    .login-card .row {
        min-height: auto;
    }
    
    .login-brand-section {
        padding: 40px 30px;
    }
    
    .login-form-section {
        padding: 40px 30px;
    }
}

@media (max-width: 576px) {
    .login-card {
        padding: 0;
    }
    
    .login-card .row {
        min-height: auto;
    }
    
    .login-brand-section {
        padding: 30px 20px;
    }
    
    .login-form-section {
        padding: 30px 20px;
    }
    
    .brand-logo {
        max-width: 150px;
    }
    
    .login-title h2 {
        font-size: 1.2rem;
    }
    
    .input-wrapper input {
        padding: 12px 40px 12px 44px;
        font-size: 0.95rem;
    }
    
    .password-toggle-icon {
        right: 12px;
        font-size: 1rem;
    }
    
    .btn-login {
        padding: 14px;
        font-size: 0.95rem;
    }
}

@media (max-width: 375px) {
    .login-card {
        padding: 30px 20px;
    }
    
    .form-group {
        margin-bottom: 20px;
    }
}

/* Focus Visible */
input:focus-visible {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* Selection */
::selection {
    background: var(--primary-color);
    color: white;
}
