/* ========== 全局 ========== */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #eef2ff;
    --bg: #f6f7fb;
    --card-bg: #ffffff;
    --text: #1f2937;
    --text-muted: #6b7280;
    --border: #e5e7eb;
    --radius: 14px;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 8px 24px rgba(99, 102, 241, 0.12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
        "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    background: linear-gradient(180deg, var(--bg) 0%, var(--primary-light) 60%, var(--bg) 100%);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a { color: inherit; text-decoration: none; }

.link {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.link:hover { color: var(--primary-dark); }

.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========== 导航栏 ========== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.navbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 6px 16px;
    min-height: 64px;
    padding: 10px 0;
}

.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; letter-spacing: 0.5px; }

.brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: var(--primary);
    color: #fff;
    font-size: 18px;
}

.nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; list-style: none; }

.nav-links a {
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 15px;
    color: var(--text-muted);
    transition: all 0.2s;
    white-space: nowrap;
}

.nav-links a:hover { color: var(--primary-dark); background: var(--primary-light); }

.nav-links a.active {
    color: var(--primary-dark);
    background: var(--primary-light);
    font-weight: 600;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

/* ========== 导航下拉菜单（视频处理等） ========== */
.nav-dropdown { position: relative; }

.nav-dropdown > .drop-toggle::after {
    content: "▾";
    margin-left: 4px;
    font-size: 11px;
    display: inline-block;
    transition: transform 0.2s;
}

.nav-dropdown:hover > .drop-toggle::after { transform: rotate(180deg); }

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 150px;
    padding: 6px;
    list-style: none;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    z-index: 200;
    text-align: left;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(4px);
}

.dropdown-menu a {
    display: block;
    padding: 8px 14px;
    border-radius: 8px;
    white-space: nowrap;
    text-align: left;
}

.dropdown-menu a:hover { background: var(--primary-light); color: var(--primary-dark); }

.dropdown-menu a.active {
    color: var(--primary-dark);
    background: var(--primary-light);
    font-weight: 600;
}

@media (max-width: 640px) {
    .dropdown-menu { left: 0; transform: translateX(0) translateY(8px); }
    .nav-dropdown:hover .dropdown-menu,
    .nav-dropdown:focus-within .dropdown-menu { transform: translateX(0) translateY(4px); }
}

/* 中屏：链接换行到第二行并居中 */
@media (max-width: 1120px) {
    .nav-links { flex-basis: 100%; justify-content: center; gap: 4px; }
    .nav-links a { padding: 6px 10px; font-size: 14px; }
}

/* 小屏：进一步压缩链接间距与字号 */
@media (max-width: 640px) {
    .navbar { justify-content: center; }
    .nav-links a { padding: 5px 8px; font-size: 13px; }
}

/* ========== 右侧浮动联系我们 ========== */
.floating-contact {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 900;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 14px 7px;
    background: linear-gradient(180deg, #6366f1, #8b5cf6);
    color: #fff;
    border-radius: 14px 0 0 14px;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    text-decoration: none;
    writing-mode: vertical-rl;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 3px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, padding 0.25s ease;
}

.floating-contact:hover {
    transform: translateY(-50%) translateX(-3px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.45);
}

.floating-contact-icon {
    writing-mode: horizontal-tb;
    font-size: 20px;
    line-height: 1;
    animation: floatPulse 2.4s ease-in-out infinite;
}

@keyframes floatPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.18); }
}

@media (max-width: 640px) {
    .floating-contact { padding: 10px 5px; font-size: 12px; letter-spacing: 2px; gap: 4px; }
    .floating-contact-icon { font-size: 16px; }
}

/* ========== 联系页面 ========== */
.contact-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1280px;
    margin: 0 auto 32px;
    padding: 0 16px;
}

.contact-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 26px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.contact-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(99, 102, 241, 0.1);
}

.contact-card-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 18px;
}

.contact-qr-img {
    width: 190px;
    height: 190px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.contact-qr-text { margin-top: 14px; font-size: 14px; font-weight: 600; color: var(--text); }

.contact-qr-tip {
    margin-top: 6px;
    font-size: 12px;
    color: var(--primary-dark);
    background: var(--primary-light);
    padding: 4px 12px;
    border-radius: 999px;
}

.contact-service-list {
    list-style: none;
    text-align: left;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 14px;
    font-size: 14px;
    line-height: 1.6;
}

.contact-service-list li { padding: 10px 12px; border-radius: 10px; background: #f8fafc; border: 1px solid var(--border); }

.contact-flow {
    list-style: none;
    counter-reset: flow;
    text-align: left;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
    font-size: 14px;
    line-height: 1.6;
}

.contact-flow li {
    counter-increment: flow;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f8fafc;
    border: 1px solid var(--border);
}

.contact-flow li::before {
    content: counter(flow);
    flex: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-flow li span { font-weight: 700; color: var(--primary-dark); white-space: nowrap; }

.contact-note {
    max-width: 1280px;
    margin: 0 auto 40px;
    padding: 24px 28px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    text-align: center;
}

.contact-note h2 { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.contact-note p { font-size: 14px; color: var(--text-muted); line-height: 1.8; }

@media (max-width: 900px) {
    .contact-cards { grid-template-columns: 1fr; }
    .contact-qr-img { width: 170px; height: 170px; }
}

@media (max-width: 640px) {
    .contact-modal-box { max-width: 260px; padding: 24px 20px 20px; }
    .contact-modal-qr { width: 160px; height: 160px; }
}

/* ========== 主区域 ========== */
.main-content { flex: 1; padding: 40px 20px 60px; }

/* ========== Hero ========== */
.hero { text-align: center; padding: 48px 0 40px; }

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.hero-title { font-size: 42px; font-weight: 800; letter-spacing: -0.5px; }

.gradient-text {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle { margin-top: 14px; color: var(--text-muted); font-size: 17px; }

/* ========== 首页 SEO 简介区块 ========== */
.seo-section {
    margin-top: 40px;
    padding: 28px 32px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.seo-section h2 { font-size: 18px; margin-bottom: 12px; }

.seo-section p {
    font-size: 14px;
    line-height: 1.9;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.seo-section p:last-child { margin-bottom: 0; }

/* ========== 工具卡片 ========== */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.tool-card {
    position: relative;
    display: flex;
    gap: 18px;
    align-items: flex-start;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    transition: all 0.25s ease;
}

a.tool-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow-hover);
}

.tool-card-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    font-size: 24px;
    background: var(--primary-light);
}

.tool-card-body h3 { font-size: 17px; margin-bottom: 6px; }

.tool-card-body p { color: var(--text-muted); font-size: 14px; }

.tool-card-arrow {
    position: absolute;
    top: 50%;
    right: 18px;
    transform: translateY(-50%);
    color: var(--primary);
    font-size: 20px;
    opacity: 0;
    transition: opacity 0.2s;
}

a.tool-card:hover .tool-card-arrow { opacity: 1; }

.tool-card.coming-soon { opacity: 0.75; cursor: default; }

.tool-card-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #f3f4f6;
    color: var(--text-muted);
    font-size: 12px;
}

/* ========== 页面标题 ========== */
.page-head { text-align: center; padding: 16px 0 28px; }

.page-title { font-size: 30px; font-weight: 800; }

.page-subtitle { margin-top: 8px; color: var(--text-muted); }

/* ========== 工具布局 ========== */
.tool-layout {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 24px;
    align-items: start;
}

.panel {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
}

.panel-title { font-size: 17px; font-weight: 700; margin-bottom: 20px; }

/* ========== 表单 ========== */
.form-group { margin-bottom: 18px; }

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.req { color: #ef4444; }

textarea, select, input[type="color"] {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fafbfd;
    font-size: 14px;
    font-family: inherit;
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s;
}

textarea { padding: 12px 14px; resize: vertical; min-height: 96px; }
textarea:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
    background: #fff;
}

select {
    padding: 10px 12px;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    cursor: pointer;
}

input[type="color"] {
    height: 42px;
    padding: 4px;
    cursor: pointer;
    background: #fafbfd;
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.char-count { text-align: right; font-size: 12px; color: var(--text-muted); margin-top: 4px; }

.hint { font-size: 12px; color: var(--text-muted); padding-top: 10px; }

.chip-row { display: flex; gap: 8px; }

.chip {
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.chip:hover { border-color: var(--primary); color: var(--primary-dark); }

/* ========== 预览 ========== */
.preview-box {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 320px;
    border: 2px dashed var(--border);
    border-radius: 12px;
    background: #fafbfd;
    padding: 20px;
    overflow: hidden;
    transition: border-color 0.2s;
}

.preview-box.has-image { border-style: solid; border-color: var(--primary); background: #fff; }

.qr-img { max-width: 100%; max-height: 340px; image-rendering: pixelated; display: none; }

.preview-placeholder { color: var(--text-muted); font-size: 14px; }

/* ========== 按钮 ========== */
.actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 11px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #8b5cf6);
    color: #fff;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}
.btn-primary:not(:disabled):hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(99, 102, 241, 0.4); }

.btn-outline { background: #fff; color: var(--primary-dark); border: 1.5px solid var(--primary); }
.btn-outline:not(:disabled):hover { background: var(--primary-light); }

.btn-ghost { background: #f3f4f6; color: var(--text); }
.btn-ghost:not(:disabled):hover { background: #e5e7eb; }

.file-label { margin: 0; }

.tips { margin-top: 16px; font-size: 13px; color: var(--text-muted); }

/* ========== 页脚 ========== */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 20px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
    background: rgba(255, 255, 255, 0.6);
}

.site-footer p { margin-top: 8px; }

.footer-icp a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 12px;
    transition: color 0.2s ease;
}

.footer-icp a:hover { color: var(--primary-dark); }

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 18px;
    margin-top: 10px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--primary-dark); }

/* ========== 格式标签页（文档转 PDF） ========== */
.format-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
    background: #f3f4f6;
    border-radius: 12px;
    padding: 4px;
}

.format-tab {
    flex: 1;
    padding: 9px 12px;
    border: none;
    border-radius: 9px;
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
}

.format-tab:hover { color: var(--text); }

.format-tab.active {
    background: linear-gradient(135deg, var(--primary), #8b5cf6);
    color: #fff;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* ========== 上传区（Word 转 PDF） ========== */
.upload-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 220px;
    border: 2px dashed var(--border);
    border-radius: 12px;
    background: #fafbfd;
    cursor: pointer;
    text-align: center;
    padding: 24px;
    transition: all 0.2s;
    outline: none;
}

.upload-zone:hover, .upload-zone:focus, .upload-zone.dragover {
    border-color: var(--primary);
    background: var(--primary-light);
}

.upload-zone.dragover { transform: scale(1.02); }

.upload-zone.disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

.upload-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 28px;
}

.upload-main { font-size: 15px; font-weight: 600; }

.upload-sub { font-size: 13px; color: var(--text-muted); }

.file-info {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 16px;
    padding: 12px 16px;
    border: 1px solid var(--primary);
    border-radius: 12px;
    background: var(--primary-light);
}

.file-info-icon { font-size: 22px; }

.file-info-body { flex: 1; min-width: 0; }

.file-info-name {
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-info-meta { font-size: 12px; color: var(--text-muted); }

.file-info-remove {
    border: none;
    background: none;
    color: var(--text-muted);
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
}

.file-info-remove:hover { color: #ef4444; background: #fef2f2; }

.btn-block { width: 100%; }

/* ========== 模板风格选择（PDF 转 PPTX） ========== */
.style-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.style-item {
    position: relative;
    cursor: pointer;
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 8px 6px 6px;
    text-align: center;
    background: #fff;
    transition: border-color 0.2s, background 0.2s;
}

.style-item:hover { border-color: var(--primary); }

.style-item input { position: absolute; opacity: 0; pointer-events: none; }

.style-item:has(input:checked) { border-color: var(--primary); background: var(--primary-light); }

.style-swatch {
    display: block;
    width: 100%;
    height: 36px;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    margin-bottom: 6px;
}

.style-name { font-size: 12px; color: var(--text-muted); }

.progress-wrap { margin-top: 18px; }

.progress-bar {
    height: 8px;
    border-radius: 999px;
    background: #e5e7eb;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), #8b5cf6);
    transition: width 0.3s ease;
}

.progress-text { margin-top: 8px; font-size: 13px; color: var(--text-muted); text-align: center; }

.info-list { list-style: none; }

.info-list li {
    position: relative;
    padding-left: 22px;
    margin-bottom: 10px;
    font-size: 14px;
    color: var(--text);
}

.info-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--primary);
    font-weight: 700;
}

/* ========== 抖音解析 ========== */
.progress-fill-indeterminate {
    width: 40%;
    animation: slide 1.2s ease-in-out infinite;
}

@keyframes slide {
    0% { margin-left: -40%; }
    100% { margin-left: 100%; }
}

.notice-box {
    margin-top: 16px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    font-size: 13px;
    word-break: break-all;
}

.result-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 260px;
    border: 2px dashed var(--border);
    border-radius: 12px;
    color: var(--text-muted);
    font-size: 14px;
    background: #fafbfd;
}

.result-empty-icon { font-size: 40px; }

.video-cover-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111827;
    border-radius: 12px;
    overflow: hidden;
    max-height: 260px;
}

.video-cover { width: 100%; object-fit: contain; }

.video-meta { margin: 14px 0; }

.video-title {
    font-weight: 600;
    font-size: 15px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-author { margin-top: 4px; font-size: 13px; color: var(--text-muted); }

.video-player { width: 100%; border-radius: 12px; background: #000; margin-bottom: 4px; }

/* ========== Toast 提示 ========== */
.toast {
    position: fixed;
    left: 50%;
    bottom: 40px;
    transform: translateX(-50%) translateY(20px);
    background: #1f2937;
    color: #fff;
    padding: 12px 22px;
    border-radius: 10px;
    font-size: 14px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 999;
    max-width: 80vw;
    word-break: break-all;
}

.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.toast-error { background: #dc2626; }

/* ========== Excel 分析结果 ========== */
#resultArea { margin-top: 24px; display: grid; gap: 24px; }

#resultArea[hidden] { display: none; }

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 14px;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #fafbfd;
}

.stat-icon { font-size: 26px; }

.stat-value { font-size: 22px; font-weight: 800; color: var(--text); }

.stat-label { font-size: 12px; color: var(--text-muted); }

.sheet-hint { margin-top: 14px; font-size: 13px; color: var(--text-muted); }

/* ========== 关键数据分析 ========== */
.insight-list {
    list-style: none;
    display: grid;
    gap: 10px;
    margin-bottom: 6px;
}

.insight-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    background: #f8fafc;
    border: 1px solid var(--border);
}

.insight-item.insight-info { border-left: 3px solid var(--primary); }
.insight-item.insight-warn { border-left: 3px solid #f59e0b; background: #fffbeb; }
.insight-item.insight-danger { border-left: 3px solid #ef4444; background: #fef2f2; }
.insight-item.insight-success { border-left: 3px solid #10b981; background: #ecfdf5; }

.insight-icon { font-size: 18px; line-height: 1.5; flex-shrink: 0; }

.insight-body { min-width: 0; }

.insight-title { font-size: 14px; display: block; }

.insight-detail { font-size: 13px; color: var(--text-muted); margin-top: 2px; }

.key-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-top: 18px;
}

.key-grid[hidden] { display: none; }

.key-block { min-width: 0; }

.key-block-title { font-size: 14px; font-weight: 700; margin-bottom: 10px; }

.quality-list {
    list-style: none;
    display: grid;
    gap: 8px;
    margin-top: 10px;
}

.quality-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    border-radius: 10px;
    font-size: 13px;
    border: 1px solid var(--border);
    background: #f8fafc;
}

.quality-item .quality-tag {
    flex-shrink: 0;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

.quality-warn .quality-tag { background: #fef3c7; color: #b45309; }
.quality-danger .quality-tag { background: #fee2e2; color: #b91c1c; }
.quality-info .quality-tag { background: var(--primary-light); color: var(--primary-dark); }

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    white-space: nowrap;
}

.data-table th,
.data-table td {
    padding: 9px 14px;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

.data-table th {
    position: sticky;
    top: 0;
    background: #f3f4f6;
    font-weight: 600;
    color: var(--text);
    z-index: 1;
}

.data-table tbody tr:hover { background: var(--primary-light); }

.chart-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.chart-grid[hidden] { display: none; }

.chart-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
    box-shadow: var(--shadow);
}

.chart-card.half { grid-column: span 1; }

.chart-card.full { grid-column: 1 / -1; }

.chart-card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 8px; }

.chart-card-title { font-size: 15px; font-weight: 700; }

.chart-card-note { font-size: 12px; color: var(--text-muted); }

.chart-box { width: 100%; height: 320px; }

/* ========== 广告遮罩层 ========== */
body.ad-locked { overflow: hidden; }

.ad-overlay {
    position: fixed;
    inset: 0;
    z-index: 9990;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.ad-overlay[hidden] { display: none; }

.ad-box {
    position: relative;
    width: 100%;
    max-width: 360px;
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    animation: ad-pop 0.25s ease;
}

@keyframes ad-pop {
    from { transform: scale(0.92); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.ad-badge {
    position: absolute;
    top: 0;
    left: 0;
    padding: 3px 10px;
    border-radius: 16px 0 14px 0;
    background: #9ca3af;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

.ad-link { display: block; }

.ad-image {
    max-width: 100%;
    max-height: 240px;
    border-radius: 10px;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.ad-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 150px;
    border: 2px dashed var(--border);
    border-radius: 12px;
    background: #f9fafb;
    padding: 20px;
}

.ad-placeholder-main { font-size: 18px; font-weight: 700; color: var(--text); }

.ad-placeholder-sub { font-size: 13px; color: var(--text-muted); }

.ad-timer {
    margin: 16px 0 12px;
    font-size: 14px;
    color: var(--text-muted);
}

.ad-timer span {
    display: inline-block;
    min-width: 28px;
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}

/* ========== 首页广告位（横幅 + 右侧） ========== */
.ad-slot { position: relative; }

.ad-slot-badge {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    padding: 2px 9px;
    border-radius: 10px 0 10px 0;
    background: #9ca3af;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
}

/* 导航栏下方横幅广告位 */
.ad-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 90px;
    margin-bottom: 8px;
    border: 1px dashed var(--border);
    border-radius: 12px;
    background: #fafbfd;
    overflow: hidden;
}

/* 页面底部横幅广告位 */
.ad-bottom {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 90px;
    margin-top: 40px;
    border: 1px dashed var(--border);
    border-radius: 12px;
    background: #fafbfd;
    overflow: hidden;
}

.ad-banner-link { display: block; width: 100%; }

.ad-banner-image {
    display: block;
    width: 100%;
    max-height: 90px;
    object-fit: cover;
}

.ad-slot-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 16px;
    color: var(--text-muted);
    text-align: center;
}

.ad-slot-main { font-size: 15px; font-weight: 700; color: var(--text); }

.ad-slot-sub { font-size: 12px; }

/* ========== Excel 描述分析 ========== */
.desc-block { margin-top: 18px; }
.desc-label { font-size: 13px; font-weight: 600; color: var(--text); display: block; margin-bottom: 8px; }
.desc-opt { font-size: 12px; font-weight: 400; color: var(--text-muted); }
.desc-block textarea { min-height: 54px; font-size: 13px; }
.desc-chips { flex-wrap: wrap; margin-top: 8px; }
.desc-chips .chip { padding: 5px 11px; font-size: 12px; background: #f8fafc; }
.desc-chips .chip.active { background: linear-gradient(135deg, var(--primary), #8b5cf6); border-color: transparent; color: #fff; }

.dir-desc { font-size: 14px; font-weight: 600; margin: 0 0 6px; color: var(--primary-dark); }
.dir-badge { font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: 999px; vertical-align: 3px; background: var(--primary-light); color: var(--primary-dark); }
.dir-badge.llm { background: #d1fae5; color: #047857; }
.dir-summary { font-size: 13px; line-height: 1.7; color: var(--text); background: #f8fafc; border: 1px solid var(--border); padding: 10px 12px; border-radius: 8px; margin: 6px 0 0; }
.dir-hint { font-size: 13px; color: #b45309; background: #fffbeb; border: 1px solid #fde68a; padding: 10px 12px; border-radius: 8px; margin: 8px 0 0; }
.dir-chart { width: 100%; height: 320px; }
.desc-tip { font-size: 12px; color: var(--text-muted); line-height: 1.6; margin: 8px 0 0; }

/* ========== 响应式 ========== */
@media (max-width: 860px) {
    .tool-layout { grid-template-columns: 1fr; }
    .hero-title { font-size: 32px; }
    .tools-grid { grid-template-columns: 1fr; }
    .chart-grid { grid-template-columns: 1fr; }
    .chart-card.half { grid-column: 1 / -1; }
    .key-grid { grid-template-columns: 1fr; }
}
