/* --- Reset & Variables --- */
:root {
    /* Matching the Dashboard Color Palette */
    --primary-color: #4f46e5; /* The Indigo used in Sidebar Active state */
    --primary-hover: #4338ca;
    --secondary-color: #6366f1; /* Lighter Indigo */
    --success-color: #22c55e;
    --success-hover: #16a34a;
    --text-dark: #1f2937;
    --text-muted: #6b7280;
    --border-color: #e2e8f0;
    --input-bg: #ffffff;
    
    /* Login Page Specific Background */
    --bg-gradient: linear-gradient(135deg, #e0e7ff 0%, #f3f4f6 100%);
    --card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-gradient);
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-dark);
}

/* --- Layout --- */
.login-wrapper {
    width: 100%;
    padding: 1rem;
    display: flex;
    justify-content: center;
}

.login-card {
    background: white;
    width: 100%;
    max-width: 480px;
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
}

/* --- Header --- */
.card-header { text-align: center; margin-bottom: 2rem; }
.card-header h2 { color: var(--primary-color); font-size: 1.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.card-header p { font-size: 0.9rem; color: var(--text-muted); }

/* --- Forms --- */
.form-group { margin-bottom: 1.25rem; }
label { display: block; font-size: 0.85rem; font-weight: 500; margin-bottom: 0.5rem; color: var(--text-dark); }
.required { color: #ef4444; }

input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.95rem;
    color: var(--text-dark);
    transition: all 0.2s;
    outline: none;
    font-family: inherit;
}

input:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1); }
input:disabled { background-color: #f8fafc; color: #94a3b8; cursor: not-allowed; }

.input-row { display: flex; gap: 0.75rem; }
.input-row input { flex: 1; }

/* --- Buttons --- */
.btn {
    padding: 0.75rem 1.25rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.2s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-secondary { background-color: var(--secondary-color); color: white; }
.btn-secondary:hover { background-color: var(--primary-color); }

.btn-success { background-color: var(--success-color); color: white; }
.btn-success:hover { background-color: var(--success-hover); }

.btn-primary { background-color: var(--primary-color); color: white; }
.btn-primary:hover { background-color: var(--primary-hover); }

.btn-block { width: 100%; margin-top: 1rem; padding: 1rem; font-size: 1rem; }

.btn-disabled, .btn:disabled { background-color: #94a3b8; color: white; cursor: not-allowed; }

/* --- Alerts --- */
.alert {
    padding: 1rem;
    border-radius: 8px;
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    margin-bottom: 1.25rem;
    font-size: 0.9rem;
}

.alert i { font-size: 1.2rem; margin-top: 2px; }
.alert-info { background-color: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }
.alert-success { background-color: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; align-items: center; }

.font-bold { font-weight: 600; }

/* --- Footer --- */
.card-footer { text-align: center; margin-top: 2rem; font-size: 0.75rem; color: #94a3b8; }

/* --- Utilities --- */
.hidden { display: none !important; }
.fade-in { animation: fadeIn 0.4s ease-in-out; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .login-card { padding: 1.5rem; }
    .btn { padding: 0.6rem 1rem; font-size: 0.85rem; }
}