body {
    font-family: Arial, sans-serif;
    background-color: #f0f2f5;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    height: 100vh;
    margin: 0;
}

.container {
    position: relative;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 300px;
    margin: 80px 0 20px 0;
}

.container h2 {
    text-align: center;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
}

.form-group input {
    width: 100%;
    padding: 10px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
    transition: border-color 0.3s, box-shadow 0.3s;
    outline: none;
}

.form-group input:focus {
    border-color: #007bff;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

.form-group .error {
    color: red;
    font-size: 12px;
    margin-top: 5px;
}

.form-group input[type="text"] {
    width: calc(100% - 110px);
    padding: 10px;
    box-sizing: border-box;
    display: inline-block;
}

.btn {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    display: block;
    width: 100%;
    padding: 10px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #0069d9;
}

.btn:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

.btn.loading {
    background-color: rgba(0, 123, 255, 0.5);
    color: #ffffff;
    cursor: not-allowed;
}

.link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
}

.link a {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    margin-left: auto;
    text-decoration: none;
    color: #888888;
}

.agreement {
    display: flex;
    align-items: center;
    margin-top: 20px;
}

.agreement input {
    margin-right: 10px;
}

.agreement label {
    font-size: 12px;
}

.agreement .error {
    display: block;
    margin-top: 5px;
    color: red;
    font-size: 12px;
}

.verification-button {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    display: inline-block;
    width: 100px;
    padding: 9.6px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    position: absolute;
    top: -1%;
    right: 0;
}

.verification-button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: #fefefe;
    margin: auto;
    padding: 20px;
    border: 1px solid #888;
    width: 300px;
    border-radius: 8px;
    text-align: left;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
}

.login-toggle {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    display: flex;
    justify-content: space-around;
    position: relative;
    margin: 40px 0;
}

.toggle-btn {
    background: none;
    border: none;
    font-size: 16px;
    padding: 10px;
    cursor: pointer;
    transition: color 0.3s ease;
    color: black;
}

.toggle-btn.active {
    color: #007bff;
}

.underline {
    position: absolute;
    bottom: 0;
    height: 2px;
    background-color: #007bff;
    width: 50%;
    transition: left 0.3s ease;
    left: 0;
}

.login-form {
    display: none;
}

.login-form.active {
    display: block;
}

.separator {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 20px 0;
}

.separator::before,
.separator::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #ddd;
    margin: 0 10px;
}

.separator span {
    font-size: 14px;
    color: #888;
}

.weixin-login {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.weixin-link, .qq-link {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    flex: 1;
    text-align: center;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
    padding: 10px;
    border: 2px solid;
    border-radius: 10px;
    transition: all 0.3s ease;
    background-color: white;
}

.weixin-link {
    color: #1AAD19;
    border-color: #A8D5A9;
}

.weixin-link:hover {
    background-color: #1AAD19;
    color: white;
}

.qq-link {
    color: #0052d9;
    border-color: #91a7c7;
}

.qq-link:hover {
    background-color: #0052d9;
    color: white;
}

.weixin-link.disabled, .qq-link.disabled {
    background-color: #f5f5f5 !important;
    border-color: #ddd !important;
    color: #999 !important;
    cursor: not-allowed !important;
}

.weixin-link.disabled:hover, .qq-link.disabled:hover {
    background-color: #f5f5f5 !important;
    color: #999 !important;
    transform: none !important;
}

.footer {
    background-color: #f9f9f9;
    color: #333;
    text-align: center;
    padding: 20px 0 20px 0;
    width: 100%;
    box-sizing: border-box;
}

.footer:after {
    content: '';
    display: block;
    width: 100%;
    position: absolute;
    bottom: 0;
}

.footer p {
    margin: 10px 0;
}

.footer a {
    color: #007bff;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

.register-btn {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    position: absolute;
    border-top-right-radius: 8px;
    top: 0;
    right: 0;
    background-color: transparent;
    color: white;
    padding: 10px;
    text-decoration: none;
    font-size: 14px;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.register-btn.disabled {
    filter: grayscale(1);
    opacity: 0.6;
    cursor: not-allowed;
}

.register-btn::before {
    content: '';
    position: absolute;
    border-top-right-radius: 8px;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-top: 70px solid #007bff;
    border-left: 70px solid transparent;
    z-index: -1;
}

#loader {
    border: 2px solid #555;
    border-top: 2px solid #f3f3f3;
    border-radius: 50%;
    width: 8px;
    height: 8px;
    display: inline-block;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@media (max-width: 768px) {
    body {
        font-family: Arial, sans-serif;
        background-color: #f0f2f5;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        align-items: center;
        height: 100vh;
        margin: 0;
    }

    .footer p {
        font-size: 10px;
    }

    .footer a {
        font-size: 10px;
    }
}

.wechat-login-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

body.wechat-modal-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
    height: 100%;
}

.wechat-login-tooltip {
    display: none;
    position: fixed;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    z-index: 1000;
    width: 280px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.wechat-login-tooltip-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.wechat-login-tooltip-icon {
    font-size: 48px;
    color: #1AAD19;
}

.wechat-login-tooltip-title {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.wechat-login-tooltip-message {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

.wechat-login-tooltip-actions {
    display: flex;
    gap: 10px;
    width: 100%;
}

.wechat-login-tooltip-btn {
    flex: 1;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.wechat-login-tooltip-btn-primary {
    background-color: #007bff;
    color: white;
}

.wechat-login-tooltip-btn-default {
    background-color: #f5f5f5;
    color: #333;
}

input[type="checkbox"]:checked {
    accent-color: #007bff;
}

.error {
    color: red;
    font-size: 13px;
    margin-top: 10px;
}