/* Body styling */
body {
    margin: 0;
    padding: 0;
    font-family: 'Arial', sans-serif;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #FF8C00, #FF4500); /* Orange gradient */
}

/* Container for the login form */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 0 20px; /* Add padding to prevent touching sides */
    width: 100%; /* Ensure full width of container */
    box-sizing: border-box; /* Include padding in the width */
}

/* Card style */
.login-card {
    background: #fff;
    padding: 30px 40px;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    text-align: center;
    max-width: 400px; /* Set a max width */
    width: 100%; /* Full width for smaller screens */
    box-sizing: border-box; /* Include padding in the width */
}

/* Form heading */
.login-card h2 {
    margin-bottom: 20px;
    font-size: 24px;
    color: #333;
}

/* Input field styling */
.login-card .form-group {
    margin-bottom: 15px;
}

.login-card .form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    transition: border-color 0.3s;
    box-sizing: border-box; /* Include padding in the width */
}

.login-card .form-group input:focus {
    border-color: #FF8C00;
}

/* Login button */
.btn-login {
    width: 100%; /* Ensure button matches the width of input fields */
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #FF8C00, #FF4500); /* Orange gradient */
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
    box-sizing: border-box; /* Include padding in the width */
}

.btn-login:hover {
    background: linear-gradient(135deg, #FF4500, #FF8C00); /* Reverse gradient on hover */
}

/* Extra links below the form */
.extra-links {
    margin-top: 20px;
    color: #666;
    font-size: 14px;
}

.extra-links a {
    color: #FF8C00; /* Matching orange color for links */
    text-decoration: none;
    margin-left: 5px;
}

.extra-links a:hover {
    text-decoration: underline;
}

/* Style the labels for username and password */
.form-group label {
    text-align: left;
    display: block; /* Ensure the label takes up the full width */
}

/* Style for error messages */
.error-message {
    color: #D8000C; /* Red text color */
    background-color: #FFD2D2; /* Light red background */
    padding: 10px; /* Padding around the text */
    margin: 10px 0; /* Margin above and below the message */
    border: 1px solid #D8000C; /* Red border */
    border-radius: 5px; /* Rounded corners */
    font-weight: bold; /* Bold text */
    text-align: left; /* Left-aligned text */
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .login-card {
        padding: 20px; /* Reduce padding on smaller screens */
    }

    h2 {
        font-size: 20px; /* Reduce heading size */
    }

    .login-card .form-group input, 
    .btn-login {
        padding: 10px; /* Reduce padding on smaller screens */
        font-size: 14px; /* Reduce font size */
    }

    .extra-links {
        font-size: 13px; /* Reduce font size */
    }
}

@media (max-width: 576px) {
    .login-card {
        padding: 15px; /* Further reduce padding */
    }

    h2 {
        font-size: 18px; /* Further reduce heading size */
    }

    .login-card .form-group input, 
    .btn-login {
        padding: 8px; /* Further reduce padding */
        font-size: 13px; /* Further reduce font size */
    }

    .extra-links {
        font-size: 12px; /* Further reduce font size */
    }
}
