* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; background: #f5f5f7; color: #1d1d1f; line-height: 1.6; }
.container { max-width: 860px; margin: 0 auto; padding: 40px 20px; }
.header { display: flex; justify-content: space-between; align-items: center; background: #fff; padding: 16px 20px; border-radius: 12px; margin-bottom: 20px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); flex-wrap: wrap; gap: 12px; }
.balance-section { font-size: 18px; color: #666; }
.balance-section strong { font-size: 24px; font-weight: 600; color: #0071e3; }
.header-right { display: flex; gap: 12px; align-items: center; }
#userSection { display: none; align-items: center; gap: 12px; }
#userSection.show { display: flex !important; }
#userSection span { color: #666; }
.tabs { display: flex; gap: 4px; margin-bottom: 16px; background: #fff; border-radius: 12px; padding: 6px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); overflow-x: auto; }
.tab { padding: 10px 20px; border-radius: 8px; cursor: pointer; font-size: 14px; font-weight: 500; color: #6e6e73; border: none; background: transparent; white-space: nowrap; transition: all 0.2s; }
.tab:hover:not(.active) { background: #f0f0f5; }
.tab.active { background: #0071e3; color: #fff; }
.main-card { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); margin-bottom: 16px; }
.tab-content { display: none; }
.tab-content.active { display: block; }
.style-row { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
textarea { width: 100%; height: 200px; border: 1px solid #d2d2d7; border-radius: 8px; padding: 16px; font-size: 16px; resize: none; outline: none; font-family: inherit; }
textarea:focus { border-color: #0071e3; }
select { padding: 10px 12px; border: 1px solid #d2d2d7; border-radius: 8px; font-size: 14px; }
.info-row { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; color: #86868b; font-size: 14px; flex-wrap: wrap; gap: 8px; }
.btn { padding: 12px 24px; border: none; border-radius: 8px; font-size: 15px; font-weight: 500; cursor: pointer; transition: all 0.2s; }
.btn-primary { background: #0071e3; color: #fff; }
.btn-primary:hover { background: #0077ed; }
.btn-primary:disabled { background: #a8a8a8; cursor: not-allowed; }
.btn-secondary { background: #f5f5f7; color: #1d1d1f; border: 1px solid #d2d2d7; }
.btn-danger { background: #ff3b30; color: #fff; }
.btn-warning { background: #ffc107; color: #000; }
.btn-success { background: #28a745; color: #fff; }
.btn-outline { background: transparent; color: #0071e3; border: 1px solid #0071e3; }
.btn-block { width: 100%; }
.btn-row { display: flex; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.result-box { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); margin-bottom: 16px; display: none; }
.result-text { background: #f9f9f9; border-radius: 8px; padding: 16px; font-size: 16px; line-height: 1.8; white-space: pre-wrap; min-height: 100px; }
.result-actions { display: flex; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.queue-panel { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); margin-bottom: 16px; display: none; }
.progress-bar { height: 8px; background: #e9ecef; border-radius: 4px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, #0071e3, #28a745); width: 0%; transition: width 1s; }
.queue-info { display: flex; justify-content: space-between; margin-top: 12px; font-size: 14px; color: #666; }
.boost-section { margin-top: 20px; padding-top: 20px; border-top: 1px solid #eee; }
#boostButtons { display: flex; gap: 12px; flex-wrap: wrap; }
.balance-tip { margin-top: 16px; padding: 16px; background: #fff3cd; border-radius: 8px; display: none; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.balance-tip span { color: #dc3545; font-weight: 600; }
.detect-result { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); margin-bottom: 16px; display: none; }
.score-display { display: flex; align-items: center; gap: 20px; margin-bottom: 16px; }
.score-circle { width: 100px; height: 100px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff; font-weight: 700; }
.score-circle span:first-child { font-size: 28px; }
.level-badge { padding: 8px 16px; border-radius: 20px; color: #fff; font-weight: 600; }
.disclaimer { color: #999; font-size: 12px; margin: 12px 0; }
.report-content { background: #f9f9f9; padding: 16px; border-radius: 8px; white-space: pre-wrap; line-height: 1.8; margin-bottom: 16px; }
.guide-buttons { display: flex; gap: 12px; flex-wrap: wrap; }
.guide-buttons button { padding: 10px 16px; background: #e7f3ff; border: 1px solid #0071e3; border-radius: 8px; color: #0071e3; cursor: pointer; }
.modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 1000; display: none; align-items: center; justify-content: center; } .modal.show { display: flex; }
.modal-content { background: #fff; border-radius: 12px; max-width: 500px; width: 90%; max-height: 90vh; overflow-y: auto; padding: 30px; position: relative; }
.modal-lg { max-width: 700px; }
.close { position: absolute; right: 20px; top: 15px; font-size: 28px; cursor: pointer; color: #999; }
.modal h2 { text-align: center; margin-bottom: 24px; }
.price-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 20px; }
.price-btn { padding: 16px; border: 2px solid #ddd; border-radius: 8px; background: #fff; cursor: pointer; display: flex; flex-direction: column; align-items: center; }
.price-btn.selected { border-color: #0071e3; background: #e7f3ff; }
.price-btn .words { font-size: 20px; font-weight: 700; }
.price-btn .price { color: #666; font-size: 14px; }
.pay-types { display: flex; gap: 12px; margin-bottom: 20px; }
.paytype-btn { flex: 1; padding: 16px; border: 2px solid #ddd; border-radius: 8px; background: #fff; cursor: pointer; text-align: center; }
.paytype-btn.active { border-color: #0071e3; background: #e7f3ff; }
.order-summary { background: #f8f9fa; padding: 16px; border-radius: 8px; margin-bottom: 20px; }
.order-summary div { display: flex; justify-content: space-between; margin-bottom: 8px; }
.order-summary div:last-child { margin-bottom: 0; font-weight: 600; color: #0071e3; }
.tip { text-align: center; color: #999; font-size: 12px; margin-top: 12px; }
input[type=email], input[type=text] { width: 100%; padding: 12px; border: 1px solid #d2d2d7; border-radius: 8px; font-size: 16px; margin-bottom: 12px; outline: none; box-sizing: border-box; }
.code-row { display: flex; gap: 12px; margin-bottom: 12px; }
.code-row input { flex: 1; margin-bottom: 0; }
.code-row button { padding: 12px 16px; background: #0071e3; color: #fff; border: none; border-radius: 8px; cursor: pointer; }
.login-links { text-align: center; margin-top: 16px; }
.login-links a { color: #0071e3; text-decoration: none; }
.login-tip { text-align: center; color: #28a745; margin-top: 12px; font-size: 14px; }
.user-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 24px; }
.stat-card { background: #f8f9fa; padding: 20px; border-radius: 12px; text-align: center; }
.stat-value { font-size: 28px; font-weight: 700; color: #0071e3; display: block; }
.stat-label { font-size: 12px; color: #666; }
.invite-section, .usage-section, .task-section { margin-bottom: 24px; }
.invite-section h3, .usage-section h3, .task-section h3 { margin-bottom: 12px; font-size: 16px; }
.invite-code { background: #e7f3ff; padding: 16px; border-radius: 8px; font-size: 20px; font-weight: 700; text-align: center; letter-spacing: 4px; margin: 12px 0; }
.invite-stats { display: flex; gap: 20px; font-size: 14px; color: #666; margin-top: 12px; }
.history-item, .task-item { display: flex; justify-content: space-between; padding: 12px; background: #f8f9fa; border-radius: 8px; margin-bottom: 8px; font-size: 14px; flex-wrap: wrap; gap: 8px; }
.empty { color: #999; text-align: center; padding: 20px; }
.streak-info { text-align: center; font-size: 18px; margin: 20px 0; }
.streak-info strong { color: #28a745; font-size: 32px; }
#checkinMsg { text-align: center; margin-top: 12px; color: #28a745; }
.toast { position: fixed; top: 20px; right: 20px; padding: 16px 24px; border-radius: 8px; color: #fff; font-weight: 500; z-index: 9999; display: none; animation: slideIn 0.3s; max-width: 300px; }
.toast-success { background: #28a745; }
.toast-error { background: #dc3545; }
.toast-warning { background: #ffc107; color: #000; }
.toast-info { background: #0071e3; }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.demo-section { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); margin-bottom: 16px; }
.demo-sample { background: #f9f9f9; border-radius: 8px; padding: 16px; font-size: 14px; line-height: 1.8; cursor: pointer; margin-bottom: 12px; }
.demo-sample:hover { background: #f0f0f5; }
.demo-sample em { color: #86868b; font-size: 12px; display: block; margin-top: 8px; }
footer { text-align: center; padding: 24px 0; color: #86868b; font-size: 13px; margin-top: 20px; }
footer nav { margin-top: 12px; }
footer a { color: #0071e3; text-decoration: none; margin: 0 12px; }
@media (max-width: 600px) { .container { padding: 20px 12px; } .price-options { grid-template-columns: repeat(2, 1fr); } }
/* ===== 增强响应式布局 ===== */
@media (max-width: 600px) {
    .container { padding: 16px 12px; }
    .price-options { grid-template-columns: repeat(2, 1fr); }
    .header { padding: 12px 16px; }
    .tabs { padding: 4px; gap: 2px; }
    .tab { padding: 8px 12px; font-size: 13px; }
    .main-card { padding: 16px; }
    .modal-content { padding: 20px; width: 95%; }
    .user-stats { grid-template-columns: 1fr; }
    .score-display { flex-direction: column; text-align: center; }
    .queue-info { flex-direction: column; gap: 8px; align-items: center; }
    .btn-row { flex-direction: column; }
    .btn-row .btn { width: 100%; }
}

/* ===== 标签栏样式优化 ===== */
.tabs {
    scrollbar-width: thin;
    scrollbar-color: #d2d2d7 transparent;
}
.tabs::-webkit-scrollbar {
    height: 4px;
}
.tabs::-webkit-scrollbar-track {
    background: transparent;
}
.tabs::-webkit-scrollbar-thumb {
    background: #d2d2d7;
    border-radius: 2px;
}

/* ===== 弹窗样式优化 ===== */
.modal-content {
    animation: modalFadeIn 0.2s ease-out;
}
@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.modal-content input[type=email],
.modal-content input[type=text],
.modal-content input[type=password] {
    font-size: 15px;
}

/* ===== 主卡片样式优化 ===== */
.main-card {
    transition: box-shadow 0.2s;
}
.main-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

/* ===== 按钮悬停效果 ===== */
.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.btn:active {
    transform: translateY(0);
}

/* ===== 加速按钮样式 ===== */
.boost-section {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}
.boost-section .btn {
    flex: 1;
    min-width: 120px;
}
.boost-result {
    margin-top: 12px;
    padding: 12px;
    background: #e8f5e9;
    border-radius: 8px;
    text-align: center;
    color: #2e7d32;
}
