/* --- Global Styles --- */
body {
    /* Using a modern, system-default font stack */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    /* Matching the admin panel background */
    background-color: #f4f7fa; 
}

/* --- Login Container --- */
.login-container {
    width: 100%;
    max-width: 400px;
    padding: 2.5rem;
    background-color: #ffffff;
    /* Soft, professional shadow */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    /* Primary color accent */
    border-top: 4px solid #0d6efd; 
}

/* --- Form Heading --- */
.login-form h2 {
    text-align: center;
    color: #333;
    margin-top: 0;
    margin-bottom: 2rem;
    font-weight: 600;
    font-size: 1.75rem;
}

/* Style for the "i-Pro" brand text */
.login-form h2 .brand-text {
    color: #0d6efd;
    font-weight: 700;
}

/* --- Form Groups & Inputs --- */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #555;
    font-weight: 500;
}

/* --- NEW: Wrapper for icon and input --- */
.input-wrapper {
    position: relative;
}

/* --- NEW: Icon styling --- */
.input-wrapper i {
    position: absolute;
    left: 1rem; /* 16px */
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d; /* Muted grey */
    transition: color 0.2s;
    pointer-events: none; /* Make icon non-clickable */
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box; /* Important for padding */
    transition: border-color 0.2s, box-shadow 0.2s;
    
    /* --- MODIFIED: Added left padding for icon --- */
    padding-left: 2.75rem; /* 1rem icon + 0.75rem space */
}

.form-group select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
}

/* Focus state for inputs */
.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
}

/* --- NEW: Change icon color when input is focused --- */
.input-wrapper:focus-within i {
    color: #0d6efd;
}

/* --- Button --- */
button {
    width: 100%;
    padding: 0.85rem;
    border: none;
    border-radius: 4px;
    /* Match Bootstrap primary blue */
    background-color: #0d6efd; 
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 1rem;
}

/* Button hover state */
button:hover {
    background-color: #0b5ed7;
}
/* --- Error Message Styling --- */
.error-message {
    width: 100%;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 1rem;
    min-height: 1.2em; /* Prevents layout jump when text appears */
}