/* login.css */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    background-image: url('assets/images/back1.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-color: rgba(255, 255, 255, 0.7);
    background-blend-mode: overlay;
}
/* Container Styles */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
    min-height: calc(100vh - 140px); /* Adjust based on header/footer height */
    display: flex;
    flex-direction: column;
    align-items: center;
}
/* lets add a header for all pages*/
header {
    background-color:rgb(21, 91, 161);
    color:rgb(223, 231, 238);
    text-align: center;
    padding: 15px;
}
/* Welcome Message Styles */
.welcome-message {
    text-align: center;
    padding: 2rem;
    margin: 2rem 0;
    width: 100%;
    max-width: 800px;
}

.welcome-message h1 {
    color: #2c3e50;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.welcome-message p {
    color: #7f8c8d;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    line-height: 1.6;
}

/* Login Dropdown Styles */
.login-dropdown {
    display: none;
    position: absolute;
    top: 70px;
    right: 20px;
    z-index: 1000;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    width: 100%;
    max-width: 400px;
}
.login-dropdown.show {
    display: block;
    animation: dropdownFade 0.3s ease;
}

/* Login Card Styles */
.login-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    width: 100%;
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header h1 {
    color: #2c3e50;
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.login-header p {
    color: #7f8c8d;
    font-size: 0.95rem;
}

/* Form Styles */
.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #95a5a6;
}

.form-group input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* CAPTCHA Container Styles */
.captcha-container {
    margin-bottom: 1.5rem;
    text-align: center;
}

.captcha-container img {
    border-radius: 8px;
    margin-bottom: 0.5rem;
    max-width: 100%;
    height: auto;
}

.refresh-captcha {
    background: none;
    border: none;
    color: #3498db;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.5rem auto;
    padding: 0.5rem;
    transition: color 0.3s ease;
}

.refresh-captcha:hover {
    color: #2980b9;
}

/* Submit Button Styles */
.submit-btn {
    width: 100%;
    padding: 12px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.3s ease;
}

.submit-btn:hover {
    background-color: #2980b9;
}

/* Error Message Styles */
.error-message {
    background-color: #ffebee;
    color: #c62828;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

/* Loading State Styles */
.submit-btn.loading {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

/* Animations */
@keyframes dropdownFade {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Styles */
@media screen and (max-width: 768px) {
    .welcome-message h1 {
        font-size: 2rem;
    }

    .login-dropdown {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        margin: 0 1rem;
        max-width: none;
    }

    .login-card {
        border-radius: 12px;
        margin: 0 auto;
    }
}

@media screen and (max-width: 480px) {
    .welcome-message {
        padding: 1rem;
    }

    .welcome-message h1 {
        font-size: 1.75rem;
    }

    .login-card {
        padding: 1.5rem;
    }

    .form-group input {
        padding: 10px 15px 10px 40px;
    }

    .submit-btn {
        padding: 10px;
    }
}

/* Focus States for Accessibility */
.form-group input:focus,
.refresh-captcha:focus,
.submit-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.4);
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .login-dropdown,
    .login-card {
        background: #2c3e50;
    }

    .login-header h1,
    .form-group input {
        color: #ecf0f1;
    }

    .form-group input {
        background: #34495e;
        border-color: #34495e;
    }

    .login-header p {
        color: #bdc3c7;
    }

    .error-message {
        background-color: rgba(198, 40, 40, 0.2);
        color: #ff8a80;
    }
}

/* Print Styles */
@media print {
    .login-dropdown,
    .submit-btn,
    .refresh-captcha {
        display: none !important;
    }
}