@import url('https://fonts.googleapis.com/css2?family=Inter:wght@200;300;400;500;600;700&display=swap');
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 300;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 50%, #cbd5e1 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #1e293b;
    position: relative;
}
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('{{ url_for("static", filename="css/images/Arts to GoGo Gradient.png") }}');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.08;
    z-index: 0;
    pointer-events: none;
}
body > * {
    position: relative;
    z-index: 1;
}
.login-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(226, 232, 240, 0.8);
    padding: 60px 50px;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.08);
    max-width: 500px;
    width: 90%;
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.close-btn {
    position: absolute;
    top: 24px;
    right: 24px;
    background: rgba(107, 114, 128, 0.1);
    border: 1px solid rgba(107, 114, 128, 0.2);
    font-size: 1.5rem;
    color: #6b7280;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 12px;
    transition: all 0.3s ease;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.close-btn:hover {
    background: rgba(107, 114, 128, 0.15);
    color: #374151;
    transform: translateY(-2px);
}
.login-header {
    text-align: center;
    margin-bottom: 32px;
}
.security-badge {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    padding: 10px 20px;
    border-radius: 16px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 28px;
    display: inline-block;
    letter-spacing: 0.02em;
    box-shadow: 0 4px 12px -2px rgba(239, 68, 68, 0.3);
}
.login-header h2 {
    color: #0f172a;
    font-size: 2.25rem;
    font-weight: 200;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}
.login-header p {
    color: #475569;
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.6;
    opacity: 0.9;
}
.logo-section {
    margin-bottom: 20px;
    animation: fadeInDown 0.6s ease-out;
}
.police-logo {
    max-width: 140px;
    height: auto;
    filter: drop-shadow(0 4px 12px rgba(239, 68, 68, 0.2));
}
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.access-level-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    color: #dc2626;
    font-size: 0.9rem;
    font-weight: 400;
}
.form-group {
    margin-bottom: 28px;
}
.form-group label {
    color: #374151;
    display: block;
    margin-bottom: 10px;
    font-weight: 400;
    font-size: 1rem;
    letter-spacing: 0.01em;
}
.form-group input {
    width: 100%;
    padding: 18px 24px;
    border: 1px solid rgba(203, 213, 225, 0.6);
    border-radius: 16px;
    background: rgba(248, 250, 252, 0.8);
    color: #1e293b;
    font-size: 1.1rem;
    font-weight: 300;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.01em;
}
.form-group input:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
}
.form-group input::placeholder {
    color: #94a3b8;
    font-weight: 300;
}
.login-btn {
    width: 100%;
    background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
    color: white;
    border: none;
    padding: 18px 32px;
    border-radius: 16px;
    font-size: 1.1rem;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 12px;
    letter-spacing: 0.01em;
    position: relative;
    overflow: hidden;
}
.login-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-3px);
    box-shadow: 0 20px 40px -12px rgba(59, 130, 246, 0.4);
}
.login-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}
.loading-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin-right: 8px;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 16px;
    text-align: center;
    font-weight: 400;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}
.error-message {
    background: rgba(254, 242, 242, 0.9);
    border: 1px solid rgba(252, 165, 165, 0.6);
    color: #dc2626;
    animation: shake 0.5s ease-in-out;
}
.success-message {
    background: rgba(240, 253, 244, 0.9);
    border: 1px solid rgba(167, 243, 208, 0.6);
    color: #059669;
}
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}
.demo-credentials {
    background: rgba(248, 250, 252, 0.8);
    border: 1px solid rgba(226, 232, 240, 0.6);
    border-radius: 12px;
    padding: 16px;
    margin-top: 24px;
    color: #64748b;
    font-size: 0.85rem;
    line-height: 1.5;
}
.demo-credentials strong {
    color: #334155;
    font-weight: 500;
}
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.login-container {
    animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Responsive Design */
@media (max-width: 768px) {
    .login-container {
        padding: 40px 30px;
        margin: 20px;
    }
    .login-header h2 {
        font-size: 1.75rem;
    }
    .police-logo {
        max-width: 120px;
    }
    .close-btn {
        top: 16px;
        right: 16px;
        width: 36px;
        height: 36px;
        font-size: 1.25rem;
    }
}
@media (max-width: 480px) {
    .login-container {
        padding: 32px 20px;
        margin: 12px;
    }
    .login-header h2 {
        font-size: 1.5rem;
    }
    .police-logo {
        max-width: 100px;
    }
    .form-group input {
        padding: 14px 18px;
        font-size: 1rem;
    }
    .login-btn {
        padding: 16px 24px;
        font-size: 1rem;
    }
    .close-btn {
        top: 12px;
        right: 12px;
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
    }
    .security-badge {
        font-size: 0.75rem;
        padding: 8px 16px;
    }
}
@media (max-width: 320px) {
    .login-container {
        padding: 24px 16px;
        margin: 8px;
    }
    .login-header h2 {
        font-size: 1.25rem;
    }
    .police-logo {
        max-width: 80px;
    }
}
/* Prevent horizontal overflow */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}