/* 纯黑背景登录注册页面 - 居中设计 */

/* 纯黑色背景 */
body {
    background: #000000;
}

/* ====== 页面布局样式 ====== */
/* 登录注册页面容器宽度调整并实现上下居中 */
.page-container:has(.auth-container) {
    max-width: 480px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;
}


/* ====== 通用样式（兼容其他页面） ====== */
/* 通用卡片样式 */
.card {
    background: #000000;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 24px 20px 28px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3),
                0 4px 16px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
}

/* 通用消息样式 */
.error {
    margin-bottom: 16px;
    padding: 12px 16px;
    border-radius: 12px;
    background-color: rgba(220, 38, 38, 0.15);
    color: #fca5a5;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(220, 38, 38, 0.3);
}

.success {
    margin-bottom: 16px;
    padding: 12px 16px;
    border-radius: 12px;
    background-color: rgba(34, 197, 94, 0.15);
    color: #86efac;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.info {
    margin-top: 12px;
    font-size: 13px;
    color: #9ca3af;
    text-align: center;
    font-weight: 400;
}

/* 退出登录按钮 */
.logout-btn {
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    text-decoration: none;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
    transition: all 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.logout-btn:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.5);
    transform: translateY(-2px);
}

.logout-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
}

/* ====== 登录注册专用样式 ====== */

/* 主容器 - 居中设计 */
.auth-container {
    max-width: 460px;
    width: 100%;
    margin: 0 auto;
    background: #000000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    padding: 40px 35px;
    box-sizing: border-box;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Logo/名称 */
.auth-logo {
    text-align: center;
    margin-bottom: 30px;
}

.auth-logo-img {
    max-width: 90px;
    height: auto;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 0 5px rgba(42, 219, 92, 0.3));
}

/* 标题 */
.auth-title {
    margin: 0 0 30px 0;
    font-size: 24px;
    font-weight: 600;
    color: #ffffff;
    text-align: center;
}

/* 表单字段 */
.auth-field {
    margin-bottom: 16px;
}

.auth-field label {
    display: none;
}

.auth-field input[type="text"],
.auth-field input[type="password"] {
    width: 100%;
    padding: 14px 16px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-sizing: border-box;
    font-size: 14px;
    background-color: rgba(0, 0, 0, 0.3);
    color: #ffffff;
    transition: all 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.auth-field input[type="text"]::placeholder,
.auth-field input[type="password"]::placeholder {
    color: #999999;
}

.auth-field input[type="text"]:focus,
.auth-field input[type="password"]:focus {
    outline: none;
    border-color: rgba(52, 211, 153, 0.5);
    background-color: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.1);
}

/* 记住我复选框 */
.auth-remember {
    display: flex;
    align-items: center;
    gap: 6px;
}

.auth-remember input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
    accent-color: #34d399;
}

.auth-remember label {
    display: inline;
    margin: 0;
    font-size: 13px;
    font-weight: 400;
    color: #999999;
    cursor: pointer;
}

/* 底部操作区 */
.auth-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
}

.auth-footer-center {
    justify-content: center;
    display: flex;
    width: 100%;
}

.auth-link {
    font-size: 13px;
    color: #999999;
    text-decoration: none;
    transition: color 0.3s ease;
}

.auth-link.register-link {
    color: #2adb5c;
    font-weight: bold;
}

/* 免责声明和隐私政策样式 */
.auth-terms {
    margin: 20px 0;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-terms-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.auth-terms-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
    accent-color: #2adb5c;
}

.auth-terms-row label {
    color: #cccccc;
    font-size: 13px;
    font-weight: 400;
    cursor: pointer;
    margin: 0;
}

.auth-terms-row span {
    color: #999999;
    font-size: 13px;
}

.auth-terms-link {
    color: #2adb5c;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 13px;
}

.auth-terms-link:hover {
    color: #2adb5c;
    text-decoration: underline;
}

.auth-link:hover {
    color: #2adb5c;
}

/* 提交按钮 */
.auth-submit-btn {
    width: 100%;
    padding: 14px 20px;
    border-radius: 8px;
    border: none;
    background: #2adb5c;
    color: #000000;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(42, 219, 92, 0.5);
    letter-spacing: 0.5px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin-bottom: 10px;
}

.auth-submit-btn:hover {
    background: #1fa74d;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(42, 219, 92, 0.6);
}

.auth-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 12px rgba(42, 219, 92, 0.4);
}

/* 消息提示 */
.auth-message {
    margin-bottom: 20px;
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    animation: slideDown 0.3s ease;
}

.auth-message.error {
    background-color: #fff5f5;
    color: #e74c3c;
    border: 1px solid #ffc9c9;
}

.auth-message.success {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.auth-info {
    margin-top: 20px;
    font-size: 13px;
    color: #6c757d;
    text-align: center;
    line-height: 1.5;
}

/* 已登录状态样式 */
.auth-logged-in {
    text-align: center;
}

.auth-logged-in h1 {
    font-size: 32px;
    font-weight: 700;
    color: #212529;
    margin: 0 0 20px 0;
}

.auth-logout-btn {
    display: inline-block;
    padding: 14px 32px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    text-decoration: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    box-shadow: 0 6px 20px rgba(245, 87, 108, 0.3);
    transition: all 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin-top: 20px;
}

.auth-logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(245, 87, 108, 0.4);
}

.auth-logout-btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 15px rgba(245, 87, 108, 0.3);
}

/* 动画 */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 响应式设计 */
/* 平板设备适配 */
@media (max-width: 768px) {
    .auth-container {
        max-width: 95%;
        padding: 30px 25px;
        border-radius: 12px;
    }
    
    .auth-title {
        font-size: 20px;
        margin-bottom: 25px;
    }
    
    .auth-logo-text {
        font-size: 22px;
    }
    
    .auth-field input[type="text"],
    .auth-field input[type="password"] {
        padding: 12px 14px;
        font-size: 14px;
    }
    
    .auth-submit-btn {
        padding: 12px 18px;
        font-size: 14px;
    }
    
    .auth-terms {
        padding: 12px;
        margin: 15px 0;
    }
}

/* 小屏幕手机适配 */
@media (max-width: 480px) {
    body:has(.auth-container) {
        padding-bottom: 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .page-container:has(.auth-container) {
        max-width: 100%;
        padding: 16px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-height: 100vh;
        margin: 0;
    }
    
    .auth-container {
        max-width: 100%;
        padding: 20px 16px;
        border-radius: 8px;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    }
    
    .auth-logo {
        margin-bottom: 20px;
    }
    
    .auth-logo-text {
        font-size: 18px;
    }
    
    .auth-title {
        font-size: 18px;
        margin-bottom: 20px;
    }
    
    .auth-field {
        margin-bottom: 12px;
    }
    
    .auth-field input[type="text"],
    .auth-field input[type="password"] {
        padding: 11px 13px;
        font-size: 14px;
        border-radius: 6px;
    }
    
    .auth-submit-btn {
        padding: 11px 16px;
        font-size: 14px;
        border-radius: 6px;
        margin-bottom: 8px;
    }
    
    /* 登录页面：记住我和立即注册保持同一行 */
    .auth-footer {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
        margin-top: 12px;
        flex-wrap: nowrap;
    }
    
    /* 注册页面底部居中 */
    .auth-footer-center {
        flex-direction: row;
        justify-content: center;
        align-items: center;
    }
    
    .auth-remember {
        flex-shrink: 0;
    }
    
    .auth-link {
        font-size: 13px;
        text-align: center;
        flex-shrink: 0;
    }
    
    /* 注册页面：同意条款保持同一行 */
    .auth-terms {
        padding: 10px;
        margin: 12px 0;
        border-radius: 6px;
    }
    
    .auth-terms-row {
        flex-wrap: nowrap;
        justify-content: center;
        gap: 6px;
        font-size: 12px;
    }
    
    .auth-terms-row label {
        font-size: 12px;
    }
    
    .auth-terms-row span {
        font-size: 12px;
    }
    
    .auth-terms-link {
        font-size: 12px;
    }
    
    .auth-message {
        padding: 10px 12px;
        font-size: 12px;
        border-radius: 6px;
    }
}

/* 超小屏幕适配（320px宽度） */
@media (max-width: 360px) {
    .auth-container {
        padding: 16px 12px;
    }
    
    .auth-logo-text {
        font-size: 16px;
    }
    
    .auth-title {
        font-size: 16px;
    }
    
    .auth-field input[type="text"],
    .auth-field input[type="password"] {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .auth-submit-btn {
        padding: 10px 14px;
        font-size: 13px;
    }
    
    .auth-link {
        font-size: 12px;
    }
    
    .auth-terms {
        padding: 8px;
    }
    
    .auth-terms-row {
        gap: 4px;
        font-size: 11px;
    }
    
    .auth-terms-row label,
    .auth-terms-row span,
    .auth-terms-link {
        font-size: 11px;
    }
}
