/* 登录弹窗样式 */
.auth-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.auth-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.auth-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    width: 90%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--border);
}

.auth-modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.auth-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s;
}

.auth-modal-close:hover {
    background: var(--bg-soft);
    color: var(--text);
}

.auth-modal-body {
    padding: 24px;
}

.auth-form-group {
    margin-bottom: 20px;
}

.auth-form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
}

.auth-form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.auth-form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.auth-code-input {
    display: flex;
    gap: 8px;
}

.auth-code-input input {
    flex: 1;
}

.auth-send-code {
    padding: 12px 20px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 14px;
    color: var(--text);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
}

.auth-send-code:hover:not(:disabled) {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.auth-send-code:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.auth-submit-btn:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.auth-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-message {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 14px;
    text-align: center;
}

.auth-message.success {
    background: #d1fae5;
    color: #065f46;
}

.auth-message.error {
    background: #fee2e2;
    color: #991b1b;
}

.auth-tips {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.auth-tips p {
    margin: 8px 0;
    font-size: 13px;
    color: var(--text-muted);
}

/* 用户信息显示 */
.user-info-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    background: var(--bg-soft);
    border-radius: 8px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
}

.user-info-text {
    flex: 1;
}

.user-nickname {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
}

.user-level {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}

.user-level-badge {
    display: inline-block;
    padding: 2px 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.user-actions {
    display: flex;
    gap: 8px;
}

.user-action-btn {
    padding: 6px 12px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 13px;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s;
}

.user-action-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* 价格显示样式 */
.product-price-box {
    margin-top: 12px;
    padding: 12px;
    background: var(--bg-soft);
    border-radius: 8px;
}

.product-price-main {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}

.product-price-label {
    font-size: 12px;
    color: var(--text-muted);
}

.product-price-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
}

.product-price-market {
    font-size: 13px;
    color: var(--text-muted);
    text-decoration: line-through;
}

.product-price-login-tip {
    font-size: 12px;
    color: var(--primary);
    cursor: pointer;
    margin-top: 4px;
}

.product-price-login-tip:hover {
    text-decoration: underline;
}

/* 响应式 */
@media (max-width: 768px) {
    .auth-modal-content {
        width: 95%;
        margin: 0 10px;
    }
}


/* 验证码输入组 */
.auth-captcha-input {
    display: flex;
    gap: 10px;
    align-items: center;
}

.auth-captcha-input input {
    flex: 1;
}

.captcha-image {
    width: 120px;
    height: 40px;
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.captcha-image:hover {
    opacity: 0.8;
}
