/* ============================================
   Sumly.cn GEO 优化平台 - 全站公共样式
   版本: 20260611
   涵盖页面: 首页、定价、技术说明、知识中心、
             控制面板、免费计划升级引导页
   ============================================ */

/* ---------- Reset & Base ---------- */
* { box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #f8fafc;
    margin: 0;
    color: #1e293b;
}

/* ---------- Page Header (pricing/tech/sites 通用) ---------- */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 70px 20px 50px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.page-header::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -15%;
    width: 500px;
    height: 500px;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
}
.page-header h1 {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 10px;
    color: #fff;
}
.page-header p {
    opacity: 0.88;
    font-size: 1.05rem;
    max-width: 520px;
    margin: 0 auto;
}

/* ============================================
   Pricing Page (pricing.php)
   ============================================ */
.pricing-section {
    max-width: 1140px;
    margin: -30px auto 0;
    padding: 0 15px 60px;
    position: relative;
    z-index: 2;
}
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}
.plan-card {
    background: #fff;
    border-radius: 16px;
    padding: 32px 28px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.04);
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
}
.plan-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.plan-card.featured {
    border: 2px solid #667eea;
    transform: scale(1.02);
}
.plan-card.featured:hover {
    transform: scale(1.02) translateY(-4px);
}
.plan-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 6px 14px;
    border-bottom-left-radius: 12px;
}
.plan-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 6px;
}
.plan-desc {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 18px;
}
.plan-price {
    margin-bottom: 20px;
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.plan-price .currency {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
}
.plan-price .amount {
    font-size: 2.6rem;
    font-weight: 800;
    color: #1e293b;
    line-height: 1;
}
.plan-price .period {
    font-size: 0.95rem;
    color: #64748b;
}
.plan-price .plan-save {
    font-size: 0.8rem;
    color: #ef4444;
    font-weight: 600;
    margin-left: 6px;
    background: #fef2f2;
    padding: 2px 8px;
    border-radius: 4px;
}
.plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
}
.plan-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 0.9rem;
    color: #334155;
    border-bottom: 1px solid #f1f5f9;
}
.plan-features li:last-child { border-bottom: none; }
.plan-features li i.bi-check-circle-fill { color: #10b981; font-size: 1rem; }
.plan-features li i.bi-x-circle-fill { color: #cbd5e1; font-size: 1rem; }
.plan-features li .limited { color: #94a3b8; text-decoration: line-through; }
.btn-plan {
    display: block;
    width: 100%;
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}
.btn-plan-default {
    background: #f1f5f9;
    color: #475569;
}
.btn-plan-default:hover { background: #e2e8f0; }
.btn-plan-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
}
.btn-plan-primary:hover {
    background: linear-gradient(135deg, #5a6fd6, #6a4190);
    transform: translateY(-1px);
}
.btn-plan-outline {
    background: #fff;
    color: #667eea;
    border: 2px solid #667eea;
}
.btn-plan-outline:hover {
    background: #667eea;
    color: #fff;
}

/* ---------- FAQ ---------- */
.faq-section {
    max-width: 800px;
    margin: 0 auto 60px;
    padding: 0 15px;
}
.faq-section h2 {
    text-align: center;
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 32px;
    color: #1e293b;
}
.faq-item {
    background: #fff;
    border-radius: 12px;
    padding: 24px 28px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.faq-item h3 {
    font-size: 1.05rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 10px;
}
.faq-item p {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.7;
    margin: 0;
}

/* ============================================
   Tech Page (tech.php)
   ============================================ */
.tech-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 15px 60px;
}
.tech-intro {
    background: #fff;
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 40px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.tech-intro h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 16px;
}
.tech-intro p {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.8;
    margin-bottom: 12px;
}
.tech-intro p:last-child { margin-bottom: 0; }

.flow-section {
    margin-bottom: 40px;
}
.flow-section > h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}
.flow-section > p {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 24px;
}
.flow-steps {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.flow-step {
    display: flex;
    gap: 20px;
    background: #fff;
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    align-items: flex-start;
}
.step-num {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.3rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.step-body h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}
.step-body p {
    font-size: 0.9rem;
    color: #475569;
    line-height: 1.7;
    margin-bottom: 14px;
}
.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.tech-tag {
    background: #f1f5f9;
    color: #475569;
    font-size: 0.8rem;
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 500;
}

.principle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}
.principle-card {
    background: #fff;
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    text-align: center;
    transition: transform 0.2s;
}
.principle-card:hover {
    transform: translateY(-4px);
}
.pc-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    color: #fff;
    font-size: 1.5rem;
}
.principle-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}
.principle-card p {
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.6;
    margin: 0;
}

/* ---------- Shared CTA Section ---------- */
.cta-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    text-align: center;
    padding: 56px 32px;
    margin-top: 48px;
    position: relative;
    overflow: hidden;
}
.cta-section::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -15%;
    width: 500px;
    height: 500px;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
}
.cta-section h2 {
    font-size: 1.8rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 12px;
    position: relative;
    z-index: 1;
}
.cta-section p {
    font-size: 1rem;
    color: #fff;
    opacity: .85;
    max-width: 500px;
    margin: 0 auto 28px;
    position: relative;
    z-index: 1;
}
.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    color: #667eea;
    padding: 14px 32px;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    color: #5a6fd6;
}
.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}
.btn-cta-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 12px;
    background: #fff;
    color: #667eea;
    font-size: 1rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform .15s, box-shadow .15s;
}
.btn-cta-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    color: #667eea;
}
.btn-cta-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 12px;
    border: 2px solid rgba(255,255,255,0.5);
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s, transform .15s;
}
.btn-cta-outline:hover {
    background: rgba(255,255,255,0.12);
    transform: translateY(-2px);
    color: #fff;
}

/* ============================================
   Home Dashboard (manage/home.php)
   控制面板 - 新手引导
   ============================================ */

/* Onboarding Banner */
.onboarding-banner {
    background: linear-gradient(135deg, #f8f9ff 0%, #fff 100%);
    border: 1.5px solid #e0e7ff;
    border-radius: 14px;
    padding: 20px 24px;
    position: relative;
}
.onboarding-step {
    background: #fff;
    border: 1.5px solid #e9ecef;
    border-radius: 12px;
    padding: 18px 16px 14px;
    height: 100%;
    position: relative;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.onboarding-step.active-step {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}
.step-badge {
    position: absolute;
    top: -12px;
    left: 16px;
    background: #667eea;
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.onboarding-step:not(.active-step) .step-badge {
    background: #dee2e6;
    color: #6c757d;
}
.step-icon {
    font-size: 1.8rem;
    margin-bottom: 8px;
    color: #667eea;
}
.step-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #1a1a2e;
}
.step-desc {
    font-size: 0.8rem;
    color: #6c757d;
    line-height: 1.5;
    margin-bottom: 0;
}
.onboarding-tip {
    background: #fffbf0;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 0.82rem;
    color: #666;
}

/* ============================================
   Free Plan Upgrade Page (site_router.php)
   免费计划独立子域名升级引导页
   ============================================ */
.upgrade-wrapper { margin: 0; padding: 0; }

.upgrade-body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.upgrade-container {
    max-width: 900px;
    width: 100%;
    padding: 24px;
}
.upgrade-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    overflow: hidden;
}
.upgrade-card-header {
    background: linear-gradient(135deg, #ff6a00, #ee0979);
    padding: 40px 32px 32px;
    text-align: center;
    color: #fff;
}
.upgrade-card-header .icon {
    font-size: 48px;
    margin-bottom: 12px;
}
.upgrade-card-header h1 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 8px;
}
.upgrade-card-header p {
    font-size: 14px;
    opacity: 0.9;
}
.upgrade-card-body {
    padding: 32px;
}

.upgrade-notice {
    background: #fff8e1;
    border-left: 3px solid #ffc107;
    border-radius: 0 8px 8px 0;
    padding: 14px 18px;
    margin-bottom: 28px;
    font-size: 14px;
    color: #666;
    line-height: 1.7;
}
.upgrade-notice strong {
    color: #e65100;
}

.billing-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
    font-size: 14px;
    color: #666;
}
.billing-toggle label {
    cursor: pointer;
    user-select: none;
}
.billing-toggle input[type="radio"] {
    accent-color: #ff6a00;
    margin-right: 4px;
}
.billing-toggle .save-tag {
    background: #ff6a00;
    color: #fff;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 4px;
}

.upgrade-pricing-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.upgrade-pricing-card {
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    padding: 28px 24px;
    text-align: center;
    position: relative;
    transition: all 0.3s;
    cursor: pointer;
}
.upgrade-pricing-card:hover {
    border-color: #ff6a00;
    box-shadow: 0 8px 24px rgba(255,106,0,0.12);
    transform: translateY(-2px);
}
.upgrade-pricing-card.popular {
    border-color: #ff6a00;
    background: #fff9f5;
}
.upgrade-pricing-card .badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #ff6a00;
    color: #fff;
    font-size: 12px;
    padding: 3px 16px;
    border-radius: 12px;
    white-space: nowrap;
    font-weight: 600;
}

.upgrade-pricing-card .plan-name {
    font-size: 17px;
    font-weight: 700;
    color: #333;
    margin-bottom: 4px;
}
.upgrade-pricing-card .plan-desc {
    font-size: 12px;
    color: #999;
    margin-bottom: 20px;
}
.upgrade-pricing-card .price {
    margin-bottom: 20px;
}
.upgrade-pricing-card .price .currency {
    font-size: 20px;
    font-weight: 600;
    color: #ff6a00;
    vertical-align: top;
    line-height: 2;
}
.upgrade-pricing-card .price .amount {
    font-size: 42px;
    font-weight: 700;
    color: #ff6a00;
    line-height: 1;
}
.upgrade-pricing-card .price .period {
    font-size: 13px;
    color: #999;
}
.upgrade-pricing-card .save-badge {
    display: inline-block;
    background: #fff0e6;
    color: #ff6a00;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 10px;
    margin-bottom: 16px;
    font-weight: 600;
}

.upgrade-pricing-card .features {
    list-style: none;
    text-align: left;
    margin-bottom: 24px;
}
.upgrade-pricing-card .features li {
    font-size: 13px;
    color: #555;
    padding: 6px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.upgrade-pricing-card .features li .check {
    color: #22c55e;
    font-weight: bold;
    flex-shrink: 0;
}
.upgrade-pricing-card .features li .cross {
    color: #ccc;
    flex-shrink: 0;
}

.btn-upgrade {
    display: inline-block;
    width: 100%;
    padding: 12px 0;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}
.btn-upgrade.primary {
    background: #ff6a00;
    color: #fff;
}
.btn-upgrade.primary:hover {
    background: #e55d00;
}
.btn-upgrade.outline {
    background: #fff;
    color: #ff6a00;
    border: 2px solid #ff6a00;
}
.btn-upgrade.outline:hover {
    background: #fff5ee;
}

.upgrade-footer {
    text-align: center;
    margin-top: 24px;
    font-size: 12px;
    color: #bbb;
}
.upgrade-footer a {
    color: #999;
    text-decoration: none;
}
.upgrade-footer a:hover {
    color: #ff6a00;
}

@media (max-width: 600px) {
    .upgrade-pricing-cards {
        grid-template-columns: 1fr;
    }
    .upgrade-card-body {
        padding: 20px;
    }
    .upgrade-card-header {
        padding: 28px 20px 24px;
    }
}

/* ============================================
   Responsive - Homepage
   ============================================ */
@media (max-width: 768px) {
    .geo-hero h1 { font-size: 1.8rem; }
    .geo-hero .hero-subtitle { font-size: 0.95rem; }
    .stats-row { gap: 10px; }
    .stat-item { min-width: 100px; padding: 14px 16px; }
    .stat-value { font-size: 1.3rem; }
    .analysis-section { margin: 16px auto 0; }
    .crawler-grid { grid-template-columns: 1fr; }
    .crawler-card { min-height: auto; }
    .pie-chart-wrap { flex-direction: column; gap: 12px; align-items: center; }
    .geo-score-header { flex-direction: column; text-align: center; }
    .dim-grid { grid-template-columns: 1fr 1fr; }
    .input-group-custom { flex-direction: column; }
    .input-group-custom input { height: 58px; font-size: 1.05rem; }
    .btn-analyze { height: 58px; font-size: 1.05rem; width: 100%; justify-content: center; }
    .lb-grid { grid-template-columns: 1fr 1fr; }
    .cta-section { margin-left: 12px; margin-right: 12px; border-radius: 16px; }
    .cta-section h2 { font-size: 1.3rem; }
    .cta-buttons { flex-direction: column; gap: 12px; }
    .cta-buttons .btn-cta-outline { color: #fff; width: 100%; display: block; text-align: center; }
    .cta-buttons .btn-cta-primary { color: #667eea; width: 100%; display: block; text-align: center; }
    .site-footer { padding-left: 16px; padding-right: 16px; }
}

@media (max-width: 480px) {
    .geo-hero { padding: 40px 16px 32px; }
    .geo-hero h1 { font-size: 1.5rem; }
    .geo-hero .hero-subtitle { font-size: 0.88rem; margin-bottom: 24px; }
    .stats-row { gap: 8px; }
    .stat-item { min-width: 72px; padding: 10px 8px; }
    .stat-value { font-size: 1.1rem; }
    .stat-label { font-size: 0.65rem; }
    .analysis-section { margin: 20px auto 0; }
    .analysis-card { padding: 20px 16px; }
    .input-group-custom input { height: 58px; font-size: 1rem; }
    .btn-analyze { height: 58px; }
    .dim-grid { grid-template-columns: 1fr; }
    .lb-grid { grid-template-columns: 1fr; }
    .leaderboard-section, .crawler-section, .features { margin-left: 10px; margin-right: 10px; padding-left: 12px; padding-right: 12px; }
    .crawler-card { padding: 16px; min-height: auto; }
    .pie-chart { width: 100px; height: 100px; }
    .discovery-list { max-height: 260px; }
}

/* ============================================
   Homepage (index.php)
   首页 - Hero / 分析 / 排行榜 / 爬虫动态 / CTA
   ============================================ */

/* --- Hero Banner --- */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 80px 0 60px;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
}
.hero h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.2;
    color: #fff;
}
.hero p {
    font-size: 1.15rem;
    opacity: 0.9;
    max-width: 600px;
}
.hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Geo Hero (new design) --- */
.geo-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    text-align: center;
    padding: 72px 16px 64px;
    position: relative;
    overflow: hidden;
}
.geo-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -15%;
    width: 600px;
    height: 600px;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
}
.geo-hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: rgba(255,255,255,0.03);
    border-radius: 50%;
}
.geo-hero .badge-free {
    display: inline-block;
    background: rgba(255,255,255,0.18);
    border: 1px solid rgba(255,255,255,0.35);
    border-radius: 20px;
    padding: 5px 20px;
    font-size: 13px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}
.geo-hero h1 {
    font-size: 2.8rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 12px;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 1;
    word-break: break-word;
}
.geo-hero .hero-subtitle {
    color: rgba(255,255,255,0.85);
    font-size: 1.15rem;
    opacity: .88;
    max-width: 640px;
    margin: 0 auto 32px;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* Stats Row */
.stats-row {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}
.stat-item {
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 16px;
    padding: 20px 28px;
    min-width: 140px;
    text-align: center;
    transition: transform 0.2s;
}
.stat-item:hover { transform: translateY(-4px); }
.stat-value {
    color: #fff;
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.1;
}
.stat-label {
    font-size: 0.8rem;
    opacity: .75;
    margin-top: 4px;
    white-space: nowrap;
}

/* --- Features Grid --- */
.features {
    padding: 80px 20px;
    max-width: 1100px;
    margin: 0 auto;
}
.features h2 {
    text-align: center;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 12px;
}
.features > p {
    text-align: center;
    color: #64748b;
    margin-bottom: 48px;
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}
.feature-card {
    background: #fff;
    border-radius: 14px;
    padding: 28px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    transition: transform 0.2s, box-shadow 0.2s;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.1);
}
.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fff !important;
    margin-bottom: 16px;
}
.feature-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: #64748b; font-size: 0.92rem; line-height: 1.6; }

/* --- Analysis Section --- */
.analysis-section {
    width: 100%;
    max-width: 780px;
    margin: -32px auto 0;
    position: relative;
    z-index: 10;
    padding: 0 16px;
    box-sizing: border-box;
}
.analysis-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.1);
    padding: 36px;
    border: 1px solid #f0f0f0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}
.analysis-card h2 {
    text-align: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 4px;
}
.analysis-card .subtitle {
    text-align: center;
    color: #94a3b8;
    font-size: 0.9rem;
    margin: 0 0 24px;
}
.input-group-custom {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}
.input-group-custom input {
    flex: 1;
    height: 52px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 10px 18px;
    font-size: 1rem;
    outline: none;
    transition: border .2s, box-shadow .2s;
}
.input-group-custom input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.12);
}
.btn-analyze {
    height: 52px;
    padding: 0 28px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: opacity .2s, transform .15s;
}
.btn-analyze:hover { opacity: .92; transform: translateY(-1px); }
.btn-analyze:disabled { opacity: .6; cursor: not-allowed; transform: none; }

.result-placeholder {
    text-align: center;
    color: #cbd5e1;
    padding: 36px 0;
}
.result-placeholder i { font-size: 44px; display: block; margin-bottom: 12px; }
.result-placeholder p { font-size: 0.9rem; }

/* Score */
.geo-score-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 24px;
}
.score-ring {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 32px;
    font-weight: 800;
    color: #fff;
}
.score-summary h3 { font-size: 1.1rem; margin: 0 0 6px; font-weight: 700; }
.score-summary p { color: #64748b; font-size: 0.9rem; margin: 0; line-height: 1.6; }
.score-tag {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 14px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    margin-top: 8px;
}

/* Dimension Grid */
.dim-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}
.dim-card {
    background: #f8fafc;
    border-radius: 14px;
    padding: 16px;
    border: 1px solid #f0f0f0;
    position: relative;
    transition: transform .15s, box-shadow .15s;
}
.dim-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.dim-card.dim-pro { opacity: .55; }
.dim-card.dim-pro .dim-lock {
    position: absolute;
    top: 10px;
    right: 10px;
    color: #94a3b8;
    font-size: 14px;
}
.dim-label { font-size: 0.82rem; color: #64748b; margin-bottom: 8px; }
.dim-bar {
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 6px;
}
.dim-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width .6s ease;
}
.dim-score { font-size: 1.25rem; font-weight: 700; }
.dim-weight { font-size: 0.7rem; color: #94a3b8; }

/* Report */
.report-section { margin-top: 16px; }
.report-section h4 {
    font-size: 0.95rem;
    margin: 0 0 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}
.issue-item {
    display: flex;
    gap: 10px;
    padding: 10px 14px;
    background: #fff;
    border: 1px solid #f0f0f0;
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 0.85rem;
}
.issue-item.issue-high { border-left: 4px solid #ef4444; }
.issue-item.issue-medium { border-left: 4px solid #f59e0b; }
.issue-item.issue-low { border-left: 4px solid #3b82f6; }
.issue-item .issue-title { font-weight: 700; color: #1e293b; margin-bottom: 2px; }
.issue-item .issue-desc { color: #64748b; line-height: 1.5; }

.suggestion-item {
    padding: 10px 14px;
    background: #f8fafc;
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 0.85rem;
}
.suggestion-item .sg-title { font-weight: 700; color: #1e293b; margin-bottom: 2px; }
.suggestion-item .sg-desc { color: #64748b; line-height: 1.5; margin-bottom: 4px; }
.suggestion-item .sg-impact { color: #764ba2; font-size: 0.8rem; font-weight: 500; }

.barrier-list {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 12px;
    padding: 18px;
    margin-bottom: 16px;
}
.barrier-list ul { margin: 0; padding-left: 18px; }
.barrier-list li { font-size: 0.85rem; color: #92400e; line-height: 1.9; }

/* GEO CTA in result */
.geo-cta {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border-radius: 14px;
    text-decoration: none;
    color: #fff;
    margin-top: 24px;
    transition: transform .15s;
}
.geo-cta:hover { transform: translateY(-2px); color: #fff; }
.geo-cta.geo-cta-pro { background: linear-gradient(135deg, #667eea, #764ba2); }
.geo-cta.geo-cta-free { background: linear-gradient(135deg, #22c55e, #16a34a); }
.geo-cta-icon { font-size: 28px; }
.geo-cta-body { flex: 1; }
.geo-cta-body h4 { font-size: 0.95rem; margin: 0 0 4px; font-weight: 700; color: #fff; }
.geo-cta-body p { font-size: 0.82rem; opacity: .9; margin: 0; line-height: 1.4; color: #fff; }
.geo-cta .btn-cta {
    padding: 8px 20px;
    border-radius: 10px;
    background: rgba(255,255,255,0.25);
    font-size: 0.85rem;
    color: #fff !important;
    font-weight: 600;
    white-space: nowrap;
}

/* Collapse toggle */
.collapse-toggle .bi-chevron-down { transition: transform .2s; }
.collapse-toggle.open .bi-chevron-down { transform: rotate(180deg); }

/* --- Leaderboard --- */
.leaderboard-section {
    max-width: 1200px;
    margin: 48px auto 0;
    padding: 0 16px;
}
.section-header {
    text-align: center;
    margin-bottom: 32px;
}
.section-header h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 6px;
}
.section-header p {
    color: #94a3b8;
    font-size: 0.95rem;
}
.lb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}
.lb-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px 20px;
    text-align: center;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    position: relative;
    transition: transform .2s, box-shadow .2s;
}
.lb-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.lb-card.top-1 { border-color: #fbbf24; }
.lb-card.top-2 { border-color: #cbd5e1; }
.lb-card.top-3 { border-color: #d97706; }
.lb-rank {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 800;
    color: #fff;
}
.lb-rank.r-1 { background: linear-gradient(135deg, #f59e0b, #d97706); }
.lb-rank.r-2 { background: linear-gradient(135deg, #94a3b8, #64748b); }
.lb-rank.r-3 { background: linear-gradient(135deg, #d97706, #92400e); }
.lb-rank.r-other { background: #94a3b8; }
.lb-domain {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1e293b;
    margin: 12px 0 8px;
    word-break: break-all;
}
.lb-score {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 8px;
}
.lb-meta {
    display: flex;
    justify-content: center;
    gap: 16px;
    font-size: 0.78rem;
    color: #94a3b8;
}
.lb-meta span { display: flex; align-items: center; gap: 4px; }

/* --- AI Crawler Dynamics --- */
.crawler-section {
    max-width: 100%;
    margin: 48px auto 0;
    padding: 0 16px;
}
.crawler-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.crawler-card {
    background: #fff;
    border-radius: 16px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    padding: 24px;
    min-height: 280px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}
.crawler-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Pie Chart */
.pie-chart-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin-top: 8px;
}
.pie-chart {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    flex-shrink: 0;
}
.pie-legend {
    font-size: 0.8rem;
    color: #64748b;
    line-height: 1.8;
    max-width: 100%;
    word-break: break-word;
}
.pie-legend .dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 3px;
    margin-right: 6px;
    vertical-align: middle;
}
.crawler-summary {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-around;
    text-align: center;
}
.crawler-summary .cs-val {
    font-size: 1.4rem;
    font-weight: 800;
    color: #1e293b;
}
.crawler-summary .cs-label {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-top: 2px;
}

/* Discovery Timeline */
.discovery-list {
    max-height: 340px;
    overflow-y: auto;
}
.discovery-item {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #f8fafc;
    font-size: 0.85rem;
}
.discovery-item:last-child { border: none; }
.discovery-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-top: 6px;
    flex-shrink: 0;
}
.discovery-dot.type-crawl { background: #3b82f6; }
.discovery-dot.type-analyze { background: #8b5cf6; }
.discovery-dot.type-push { background: #22c55e; }
.discovery-dot.type-default { background: #94a3b8; }
.discovery-info { flex: 1; min-width: 0; }
.discovery-domain {
    font-weight: 600;
    color: #1e293b;
    word-break: break-all;
    max-width: 100%;
    overflow: hidden;
}
.discovery-detail {
    color: #94a3b8;
    font-size: 0.78rem;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 2px;
    max-width: 100%;
}
.discovery-meta {
    font-size: 0.72rem;
    color: #cbd5e1;
    margin-top: 2px;
    display: flex;
    gap: 8px;
}

/* Trend */
.trend-mini {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}
.trend-mini .trend-label {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-bottom: 6px;
}
.trend-bars {
    display: flex;
    align-items: flex-end;
    gap: 3px;
}
.trend-bar {
    width: 100%;
    align-self: stretch;
    border-radius: 3px 3px 0 0;
    background: linear-gradient(180deg, #667eea, #764ba2);
    transition: height .4s ease;
    position: relative;
    min-height: 2px;
}
.trend-bar:hover { background: linear-gradient(180deg, #818cf8, #a78bfa); }
.trend-date {
    font-size: 0.6rem;
    color: #cbd5e1;
    text-align: center;
    margin-top: 3px;
}

/* --- Loading & Skeleton --- */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: sumly-spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}
@keyframes sumly-spin { to { transform: rotate(360deg); } }

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 37%, #f0f0f0 63%);
    background-size: 400% 100%;
    animation: skeleton-loading 1.4s ease infinite;
    border-radius: 8px;
}
@keyframes skeleton-loading {
    0% { background-position: 100% 50%; }
    100% { background-position: 0 50%; }
}
.skeleton-text { height: 14px; margin-bottom: 8px; }
.skeleton-text.short { width: 60%; }
.skeleton-title { height: 20px; width: 40%; margin-bottom: 16px; }
.loading-indicator {
    text-align: center;
    padding: 40px;
    color: #94a3b8;
    font-size: 0.9rem;
}
.ds-spinner {
    display: inline-block;
    width: 28px;
    height: 28px;
    border: 3px solid #e5e7eb;
    border-top-color: #667eea;
    border-radius: 50%;
    animation: sumly-spin .7s linear infinite;
    margin-bottom: 10px;
}

/* --- Base Mobile Compatibility --- */
img { max-width: 100%; height: auto; }
table { width: 100%; overflow-x: auto; display: block; }
*, *::before, *::after { box-sizing: border-box; }
body { overflow-x: hidden; }
html, body { max-width: 100vw; overflow-x: hidden; padding-bottom: 70px; }
img, table, pre, iframe, video, embed, object { max-width: 100%; height: auto; }
h1, h2, h3, h4, p, div, span, a, li, td, th { word-wrap: break-word; overflow-wrap: break-word; }
/* ============================================
   footer.php - Site Footer + Bottom Navigation
   ============================================ */
.site-footer {
    text-align: center;
    padding: 24px 15px 90px;
    color: #9ca3af;
    font-size: 13px;
    background: transparent;
    margin-top: 20px;
}
.site-footer a {
    color: #9ca3af;
    text-decoration: none;
}
.site-footer a:hover {
    color: #667eea;
    text-decoration: none;
}
.footer-beian {
    margin-top: 6px;
}

/* Bottom Navigation - Mobile: fixed at bottom, Desktop: hide */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1040;
    background: #fff;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 6px 0 env(safe-area-inset-bottom, 8px);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.06);
}
.bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-decoration: none;
    color: #6b7280;
    font-size: 11px;
    padding: 4px 12px;
    transition: color .15s;
}
.bottom-nav a i { font-size: 20px; }
.bottom-nav a.active, .bottom-nav a:hover { color: #667eea; }
.footer-links{
    margin-bottom: 10px;
}
/* Mobile Force Fit: prevent horizontal scroll, add bottom padding for fixed nav */
@media (max-width: 767px) {
    html, body { max-width: 100vw !important; overflow-x: hidden !important; padding-bottom: 70px !important; }
    img, table, iframe, object, embed { max-width: 100% !important; height: auto !important; }
    .container, .container-fluid { max-width: 100% !important; padding-left: 15px !important; padding-right: 15px !important; }
}

@media (min-width: 768px) {
    .site-footer { padding-bottom: 24px; }
    .bottom-nav { display: none !important; }
    html, body { padding-bottom: 0 !important; }
}

/* ============================================
   header.php - Navigation Bar
   ============================================ */
.navbar .nav-link { color: #555; border-radius: 6px; transition: all 0.2s; }
.navbar .nav-link:hover, .navbar .nav-link.active { color: #0052D9; background: #f0f5ff; }
.navbar-toggler:focus { box-shadow: none; }
@media (max-width: 991.98px) {
    .navbar-collapse { padding-top: 12px; border-top: 1px solid #f0f0f0; margin-top: 8px; }
    .navbar-nav { text-align: center; width: 100%; margin: 0 !important; gap: 4px !important; }
    .navbar-nav .nav-item { width: 100%; }
    .navbar-nav .nav-link { padding: 10px 16px !important; font-size: 15px; border-radius: 8px; margin-bottom: 2px; }
    .navbar-btn-group { width: 100%; flex-direction: column; gap: 8px !important; margin-top: 12px; padding-top: 12px; border-top: 1px solid #f0f0f0; }
    .navbar-btn-group .btn { width: 100%; justify-content: center; padding: 10px 16px !important; font-size: 15px; border-radius: 8px; }
    .navbar-brand img { height: 28px !important; }
}

.site-logo {
    height: 27px;
    width: auto;
}
