.auth-container, .auth-container * {
    box-sizing: border-box;
}

#auth-modal-overlay {
    display: none; 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background: rgba(0, 0, 0, 0.6); 
    z-index: 9999; 
    justify-content: center; 
    align-items: center;
    padding: 20px;
}

.auth-container {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    padding: 32px 32px 32px 32px;
    scrollbar-width: none; 
    -ms-overflow-style: none; 
}

.auth-container::-webkit-scrollbar {
    display: none;
}

#close-modal {
    position: absolute; 
    right: 18px; 
    top: 15px; 
    cursor: pointer; 
    font-size: 26px; 
    color: #999; 
    z-index: 10;
    transition: color 0.3s ease;
    line-height: 1;
}

#close-modal:hover {
    color: #333;
}

.auth-form {
    display: none;
    flex-direction: column;
    gap: 12px; 
}

.auth-form.active {
    display: flex;
}

.auth-form h2 {
    text-align: center;
    color: #333;
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 24px;
    font-weight: 700;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 4px; 
}

.input-group label {
    font-size: 14px;
    color: #555;
    font-weight: 600;
}

.password-wrapper {
    position: relative;
    width: 100%;
}

.toggle-password {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #999;
    font-size: 16px;
    z-index: 2;
}

.toggle-password:hover {
    color: #333;
}

.auth-container input {
    position: static !important;
    opacity: 1 !important;
    z-index: 1 !important;
    display: block !important;
    width: 100%;
    padding: 10px 40px 10px 14px !important;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
    background-color: #fff;
    color: #333;
}

.auth-container input:focus {
    outline: none;
    border-color: #4a90e2;
    box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.2);
}

.submit-btn {
    background-color: #2956A5;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 8px;
    width: 100%;
}

.submit-btn:hover {
    background-color: #1b4282;
}

.submit-btn:disabled {
    background-color: #a0b5d6;
    cursor: not-allowed;
}

.form-footer {
    margin-top: 12px;
    font-size: 14px;
    color: #666;
}

.footer-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-links.center {
    justify-content: center;
}

.form-footer a {
    color: #2956A5;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
}

.form-footer a:hover {
    text-decoration: underline;
}