
/* Login Page Styles */
:root {
    --gradient-start: var(--primary-color);
    --gradient-end: var(--primary-dark);
}

[data-bs-theme="dark"] {
    --bs-body-bg: #121212;
    --bs-body-color: #ffffff;
    --bs-border-color: #444;
}

body {
  /* Set the background image and linear gradient */
  background: 
    /* The linear gradient is on the bottom layer */
    linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
  
  /* Set other body properties */
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 2rem 0;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  
  /* Required for the ::before pseudo-element to work correctly */
  position: relative;
}

body::before {
  /* Create the pseudo-element to hold the image */
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  
  /* Set the background image properties */
  background-image: url('../images/eaglesbg.png');
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  
  /* Set the opacity of the image */
  opacity: 0.2;
  
  /* Place the pseudo-element behind the body content */
  z-index: -1;
}

.login-card {
    background: var(--bs-body-bg);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--bs-border-color);
    padding: 2.5rem;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
}

/* Brand Section */
.brand-section {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--bs-border-color);
}

.brand-logo {
    max-height: 80px;
    max-width: 200px;
    margin-bottom: 1rem;
    object-fit: contain;
}

.brand-title {
    font-weight: 700;
    color: var(--bs-body-color);
    margin-bottom: 0.5rem;
    font-size: 1.75rem;
}

.brand-subtitle {
    color: var(--bs-secondary-color);
    margin: 0;
    font-size: 0.9rem;
}

/* Form Styles */
.login-form .form-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--bs-body-color);
}

.form-control {
    border-radius: 8px;
    padding: 0.75rem 1rem;
    border: 2px solid var(--bs-border-color);
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(var(--primary-color-rgb), 0.25);
}

/* Password Input Group */
.password-input-group {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--bs-secondary-color);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 4px;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: var(--primary-color);
    background-color: rgba(var(--primary-color-rgb), 0.1);
}

/* Button Styles */
.btn-login {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border: none;
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Alert Styles */
.alert {
    border-radius: 8px;
    border: none;
    border-left: 4px solid;
    margin-bottom: 1.5rem;
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.1);
    border-left-color: #dc3545;
    color: #dc3545;
}

/* Footer Links */
.login-footer {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--bs-border-color);
    margin-top: .5rem;
}

.back-to-website {
    color: var(--bs-secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.back-to-website:hover {
    color: var(--primary-color);
}

/* Security Notice */
.security-notice {
    text-align: center;
    margin-top: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    .login-card {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }
    
    .brand-logo {
        max-height: 60px;
    }
    
    .brand-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    .login-card {
        padding: 1.5rem 1rem;
    }
    
    .brand-section {
        margin-bottom: 1.5rem;
    }
}

/* Animation for form elements */
.login-form .form-control {
    animation: slideUp 0.5s ease-out;
}

.login-form .mb-3 {
    animation: slideUp 0.5s ease-out;
}

.login-form .mb-3:nth-child(1) { animation-delay: 0.1s; }
.login-form .mb-3:nth-child(2) { animation-delay: 0.2s; }
.login-form .btn-login { animation-delay: 0.3s; }

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading state for button */
.btn-login.loading {
    position: relative;
    color: transparent;
}

.btn-login.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-right-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}