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

body {
    font-family: 'Inter', sans-serif;
    background: #f4f6f9;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

/* Card */
.login-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 40px 32px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

/* Header */
.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-logo {
    width: 90px;
    height: 90px;
    margin: 0 auto 16px;
}

.login-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.login-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: #1e3a5f;
    margin-bottom: 4px;
}

.login-header p {
    font-size: 14px;
    color: #6c757d;
}

/* Form */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #2d2d2d;
    margin-bottom: 6px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper > i {
    position: absolute;
    left: 14px;
    color: #6c757d;
    font-size: 14px;
    pointer-events: none;
}

.input-wrapper input {
    width: 100%;
    padding: 12px 14px 12px 42px;
    border: 1px solid #dce1e8;
    border-radius: 8px;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    color: #2d2d2d;
    background: #f8f9fb;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.input-wrapper input:focus {
    border-color: #2e6da4;
    box-shadow: 0 0 0 3px rgba(46, 109, 164, 0.15);
    background: #ffffff;
}

.input-wrapper input::placeholder {
    color: #adb5bd;
}

/* Toggle password */
.toggle-password {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    padding: 4px;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password:hover {
    color: #2e6da4;
}

/* Forgot password */
.forgot-password {
    text-align: right;
    margin-bottom: 20px;
}

.forgot-password a {
    font-size: 13px;
    color: #2e6da4;
    text-decoration: none;
}

.forgot-password a:hover {
    text-decoration: underline;
    color: #1e3a5f;
}

/* Error */
.error-message {
    background: #fdf2f2;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #dc3545;
}

/* Button */
.btn-login {
    width: 100%;
    padding: 12px;
    background: #1e3a5f;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-login:hover {
    background: #2e6da4;
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 24px;
}

.login-footer p {
    font-size: 12px;
    color: #adb5bd;
}

/* ============ LOADING SCREEN ============ */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-content {
    text-align: center;
}

.loading-logo {
    width: 120px;
    height: 120px;
    object-fit: contain;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-text {
    margin-top: 20px;
    font-size: 16px;
    font-weight: 600;
    color: #1e3a5f;
}

.loading-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 12px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    background: #2e6da4;
    border-radius: 50%;
    animation: bounce 1.2s ease-in-out infinite;
}

.loading-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.loading-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
}

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); opacity: 0.4; }
    40% { transform: scale(1); opacity: 1; }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 480px) {
    .login-container {
        padding: 16px;
    }

    .login-card {
        padding: 32px 20px;
    }

    .login-header h1 {
        font-size: 22px;
    }
}
