* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    background: #1A1A20;
    color: #D4D4D8;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 420px;
}

.login-box {
    background: #1E1E24;
    padding: 40px 36px;
    border-radius: 8px;
    border: 1px solid #3A3A42;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

h1 {
    color: #D4D4D8;
    font-size: 2em;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 8px;
    text-align: center;
}

.subtitle {
    color: #878894;
    font-size: 0.95em;
    text-align: center;
    margin-bottom: 32px;
    font-weight: 400;
}

#loginForm {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.input-group {
    width: 100%;
}

.input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #3A3A42;
    border-radius: 6px;
    font-size: 1em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    background: #22222A;
    color: #D4D4D8;
    transition: all 0.2s ease;
}

.input::placeholder {
    color: #878894;
}

.input:focus {
    outline: none;
    border-color: #de4a4a;
    background: #1C1C22;
    box-shadow: 0 0 0 3px rgba(222, 74, 74, 0.15);
}

.error-message {
    color: #FF5555;
    font-size: 0.9em;
    padding: 12px 14px;
    border-radius: 6px;
    background: rgba(255, 85, 85, 0.1);
    border: 1px solid rgba(255, 85, 85, 0.2);
    display: none;
    animation: slideIn 0.3s ease;
}

.error-message.show {
    display: block;
}

.attempts-info {
    color: #878894;
    font-size: 0.85em;
    text-align: center;
    display: none;
}

.attempts-info.show {
    display: block;
}

.attempts-info.warning {
    color: #FFAA55;
    font-weight: 500;
}

.btn-login {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 6px;
    font-size: 1em;
    font-weight: 600;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    background: #de4a4a;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 4px;
}

.btn-login:hover:not(:disabled) {
    background: #c43838;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(222, 74, 74, 0.4);
}

.btn-login:active:not(:disabled) {
    transform: translateY(0);
}

.btn-login:disabled {
    background: #3A3A42;
    color: #878894;
    cursor: not-allowed;
    opacity: 0.6;
}

.info-text {
    margin-top: 24px;
    text-align: center;
}

.info-text p {
    color: #878894;
    font-size: 0.8em;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-4px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(4px);
    }
}

.shake {
    animation: shake 0.4s ease;
}

/* Loading state */
.btn-login.loading::after {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-left: 8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 600px) {
    .login-box {
        padding: 32px 24px;
    }

    h1 {
        font-size: 1.75em;
    }

    .subtitle {
        font-size: 0.9em;
    }
}
