/* style.css */
:root {
    --dark-blue: #111c72;
    --primary-blue: #1d4ed8;
    --navbar-blue: #1f2b8f;
    --purple: #6c4cff;
    --yellow: #ffd633;
    --white: #ffffff;
    --light-bg: #f5f7fb;
    --text-main: #222222;
    --text-muted: #666666;
    --error: #ef4444;
    --success: #10b981;
}

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

body, html {
    width: 100%;
    height: 100%;
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, var(--dark-blue), var(--navbar-blue), #302080);
    overflow: hidden; /* Prevent scrolling for full screen effect */
    color: var(--text-main);
}

/* Background Decorative Elements */
.bg-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: 1;
}

.glow-dot {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(108, 76, 255, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(40px);
    z-index: 0;
    animation: float 20s infinite alternate ease-in-out;
}

.dot-1 {
    top: -100px;
    left: -100px;
}

.dot-2 {
    bottom: -150px;
    right: -100px;
    animation-delay: -10s;
    background: radial-gradient(circle, rgba(29, 78, 216, 0.2) 0%, transparent 70%);
}

.circle {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 0;
}

.circle-1 {
    width: 600px;
    height: 600px;
    top: -200px;
    right: -100px;
}

.circle-2 {
    width: 400px;
    height: 400px;
    bottom: -100px;
    left: -50px;
}

@keyframes float {
    0% { transform: translate(0, 0); }
    50% { transform: translate(30px, 40px); }
    100% { transform: translate(-20px, 20px); }
}

/* Login Wrapper */
.login-wrapper {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    overflow-y: auto;
}

/* Login Card */
.login-card {
    background: var(--white);
    width: 100%;
    max-width: 420px;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.20);
    animation: slideUpFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}

@keyframes slideUpFade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

.logo {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 60px;
    height: 60px;
    background: var(--light-bg);
    border-radius: 16px;
    margin-bottom: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.logo img {
    width: 40px;
    height: auto;
}

.fallback-logo {
    width: 60px;
    height: 60px;
    background: var(--yellow);
    color: var(--dark-blue);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 800;
}

.login-header h2 {
    font-size: 16px;
    color: var(--primary-blue);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.login-header h3 {
    font-size: 24px;
    color: var(--dark-blue);
    font-weight: 800;
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-muted);
    font-size: 14px;
}

/* Validation Message */
.validation-message {
    font-size: 13px;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: none;
    text-align: center;
}

.validation-message.error {
    display: block;
    background: rgba(239, 68, 68, 0.1);
    color: var(--error);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.validation-message.success {
    display: block;
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

/* Forms */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--dark-blue);
    margin-bottom: 8px;
}

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

.input-icon {
    position: absolute;
    left: 15px;
    color: #94a3b8;
    font-size: 14px;
    transition: color 0.3s;
}

.input-wrapper input {
    width: 100%;
    padding: 12px 15px 12px 40px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    font-family: inherit;
    font-size: 14px;
    color: var(--text-main);
    background: var(--light-bg);
    transition: all 0.3s;
    outline: none;
}

.input-wrapper input:focus {
    background: var(--white);
    border-color: var(--purple);
    box-shadow: 0 0 0 3px rgba(108, 76, 255, 0.15);
}

.input-wrapper input:focus + .input-icon,
.input-wrapper input:focus ~ .input-icon {
    color: var(--purple);
}

.toggle-password {
    position: absolute;
    right: 15px;
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    transition: color 0.3s;
    padding: 5px;
}

.toggle-password:hover {
    color: var(--dark-blue);
}

/* Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    font-size: 13px;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--text-muted);
    font-weight: 500;
}

.remember-me input {
    display: none;
}

.checkmark {
    width: 16px;
    height: 16px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    margin-right: 8px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s;
    background: var(--white);
}

.remember-me input:checked + .checkmark {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
}

.remember-me input:checked + .checkmark::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: white;
    font-size: 10px;
}

.forgot-password {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.forgot-password:hover {
    color: var(--purple);
    text-decoration: underline;
}

/* Button */
.btn-submit {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary-blue), var(--purple));
    color: var(--white);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(29, 78, 216, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(29, 78, 216, 0.4);
}

.btn-submit:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(29, 78, 216, 0.3);
}

.btn-submit .btn-icon {
    transition: transform 0.3s ease;
}

.btn-submit:hover .btn-icon {
    transform: translateX(3px);
}

/* Loading State for Button */
.btn-submit.loading {
    opacity: 0.8;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-submit.loading .btn-icon {
    animation: rotate 1s linear infinite;
}

@keyframes rotate {
    to { transform: rotate(360deg); }
}

/* Security Indicator */
.security-indicator {
    text-align: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #f1f5f9;
}

.security-indicator p {
    font-size: 13px;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 2px;
}

.security-indicator span {
    font-size: 11px;
    color: #94a3b8;
}

/* Footer */
.login-footer {
    margin-top: 30px;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
}

/* Responsive */
@media (max-width: 480px) {
    .login-card {
        padding: 30px 20px;
        width: calc(100% - 32px);
        border-radius: 20px;
    }
    
    .login-header h3 {
        font-size: 20px;
    }
    
    .form-options {
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .btn-submit, .input-wrapper input {
        min-height: 44px; /* Touch target */
    }
}
