:root {
    --background-color: #f5f5f5;
    --text-color: #333;
    --sidebar-bg-color: #e4dcef;
    --sidebar-text-color: #333;
    --sidebar-hover-bg-color: rgba(156, 136, 255, 0.2);
    --topnav-bg-color: #e4dcef;
    --link-hover-color: #a082f7;
    --button-bg-color: #e4dcef;
    --button-text-color: #333;
    --login-body-bg-color: #ffffff;
}

@media (prefers-color-scheme: dark) {
    :root {
        --background-color: #333333;
        --text-color: #e0e0e0;
        --sidebar-bg-color: #42375a;
        --sidebar-text-color: #c5bedd;
        --sidebar-hover-bg-color: rgba(156, 136, 255, 0.1);
        --topnav-bg-color: #42375a;
        --link-hover-color: #c7a2ff;
        --button-bg-color: #42375a;
        --button-text-color: #c5bedd;
        --login-body-bg-color: #2c2c2c;
    }
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.login-container {
    background-color: var(--sidebar-bg-color);
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    overflow: hidden;
}

.login-header {
    background-color: var(--topnav-bg-color);
    padding: 1.5rem;
    text-align: center;
}

.login-header h2 {
    color: var(--sidebar-text-color);
    margin: 0;
}

.login-body {
    background-color: var(--login-body-bg-color);
    padding: 2rem;
}

.form-group {
    margin-bottom: 1rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

input[type="password"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--sidebar-text-color);
    border-radius: 4px;
    background-color: var(--background-color);
    color: var(--text-color);
}

input[type="text"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--sidebar-text-color);
    border-radius: 4px;
    background-color: var(--background-color);
    color: var(--text-color);
}

.password-input-wrapper {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
}

.toggle-password:focus {
    outline: none;
}

.material-icons {
    font-size: 20px;
}

.password-container {
    display: flex;
    align-items: center;
    border: 1px solid var(--sidebar-text-color);
    border-radius: 4px;
    background-color: var(--background-color);
    overflow: hidden;
}

.password-container input[type="password"],
.password-container input[type="text"] {
    flex-grow: 1;
    border: none;
    border-radius: 0;
    padding: 0.5rem;
    background-color: transparent;
}

.password-container .divider {
    width: 1px;
    height: 20px;
    background-color: var(--sidebar-text-color);
    margin: 0;
}

.toggle-password {
    position: static;
    transform: none;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.password-container:focus-within {
    outline: 2px solid var(--link-hover-color);
    outline-offset: -2px;
}

.password-container input:focus {
    outline: none;
}

.btn {
    display: inline-block;
    background-color: var(--button-bg-color);
    color: var(--button-text-color);
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    width: 100%;
    margin-bottom: 10px;
}

.btn:hover {
    background-color: var(--link-hover-color);
    color: var(--sidebar-text-color);
}

.divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1rem 0;
    color: var(--text-color);
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--sidebar-text-color);
}

.divider span {
    padding: 0 10px;
}

.alert {
    padding: 0.75rem;
    margin-bottom: 1rem;
    border-radius: 4px;
    color: var(--sidebar-text-color);
}

.alert-error {
    background-color: rgba(231, 76, 60, 0.7);
}

.alert-success {
    background-color: rgba(46, 204, 113, 0.7);
}

@media (max-width: 480px) {
    .login-body {
        padding: 1rem;
    }
}