/* ==========================================================================
   发稿大师 - 全站公共样式
   设计原则:
   - 企业级科技蓝主调（专业/可信）
   - 琥珀橙强调色（价格优势/转化）
   - 大留白,模块化,卡片化
   - 字号体系: 14 / 16 / 18 / 22 / 28 / 36 / 48 / 56

   色板基准：参考 https://qian.tencent.com/ 的 design token（TDesign 体系）
     主色 #0052D9 / 深 #0034B5 / 浅底 #ECF2FE
     强调 #F19500（参考站活动橙）/ 成功 #00A870 / 警示 #ED9A1F
     中性 #1A1A1A · #666 · #8C8C8C · 描边 #E7E7E7 · 浅面 #F5F5F5
   ⚠ 改色请改本文件的 :root，再跑 tools/_retheme.py 下发到各 CSS 里的硬编码点
   ========================================================================== */

:root {
    --c-primary: #0052D9;
    --c-primary-dark: #0034B5;
    --c-primary-light: #ECF2FE;
    /* 文章封面未上传图片时的纯色背景 */
    --c-cover-fallback: #0052D9;
    --c-accent: #F19500;
    --c-accent-dark: #D97F00;
    --c-accent-light: #FFF6E6;
    --c-success: #00A870;
    --c-warning: #ED9A1F;
    --c-text: #1A1A1A;
    --c-text-sub: #666666;
    --c-text-mute: #8C8C8C;
    --c-line: #E7E7E7;
    --c-bg: #FFFFFF;
    --c-bg-soft: #F5F5F5;
    /* ---- 深色区块调色板（2026-09-12 二次换版 · 依据用户提供的参考截图） ----
       深底统一走「深海军蓝 → 宝蓝」渐变，前景一律纯蓝白，**深底上不再出现橙色**。
       ⚠ 改深色只改这里的令牌；硬编码兜底点由 tools/_retheme.py 下发。核验 tools/_verify_dark.py */
    --c-dark-1: #101F4F;            /* 渐变起点 · 深海军蓝 */
    --c-dark-2: #253EA0;            /* 渐变终点 · 宝蓝 */
    --c-dark-grad: linear-gradient(135deg, var(--c-dark-1) 0%, var(--c-dark-2) 100%);
    --c-dark-deep: #0B1740;         /* 页脚 / GEO 深底 · 渐变起点（压深一档） */
    --c-dark-deep-2: #1B357F;       /* 页脚 / GEO 深底 · 渐变终点 */
    --c-dark-on: #E4EBFF;           /* 深底主文字 / 数字（淡蓝白） */
    --c-dark-on-sub: #C3CCE0;       /* 深底次要文字（冷灰蓝） */
    --c-dark-on-hi: #A9C6FF;        /* 深底强调（淡蓝） */
    --c-dark-line: rgba(255,255,255,.14);
    --c-dark-glow: rgba(108,152,255,.42);
    --c-bg-dark: #101F4F;
    --shadow-sm: 0 2px 8px rgba(10,30,76, 0.06);
    --shadow-md: 0 8px 24px rgba(10,30,76, 0.08);
    --shadow-lg: 0 16px 40px rgba(10,30,76, 0.12);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --container: 1200px;
}

/* 重置 */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--c-text);
    background: var(--c-bg);
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; transition: color .2s; }
a:hover { color: var(--c-primary); }
img { max-width: 100%; display: block; }
button, input, textarea, select { font: inherit; color: inherit; outline: none; border: none; background: none; }
ul, ol { list-style: none; }

/* 无障碍跳转链接（skip link）
   必须脱离文档流：否则会在页首占据一行高度，把 topbar 顶下去并留下空白条。
   默认移出视口（保持可聚焦，键盘 Tab 仍能到达），仅聚焦时滑入显示。 */
.skip-to-content {
    position: fixed;
    top: 0;
    left: 24px;
    z-index: 99999;
    display: inline-block;
    padding: 10px 20px;
    background: var(--c-primary);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    box-shadow: var(--shadow-md);
    transform: translateY(-120%);
    transition: transform .2s ease;
}
.skip-to-content:hover { color: #fff; background: var(--c-primary-dark); }
.skip-to-content:focus {
    transform: translateY(0);
    outline: 2px solid #fff;
    outline-offset: -4px;
}

/* 锚点跳转时避开 sticky 头部遮挡 */
:target { scroll-margin-top: 96px; }

/* 容器 */
.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* 通用按钮 */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    height: 44px; padding: 0 24px; border-radius: 22px;
    font-size: 15px; font-weight: 600; cursor: pointer; transition: all .25s;
    border: 1px solid transparent; white-space: nowrap;
}
.btn-primary { background: var(--c-primary); color: #fff; }
.btn-primary:hover { background: var(--c-primary-dark); color: #fff; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0,82,217,.3); }
.btn-accent { background: var(--c-accent); color: #fff; }
.btn-accent:hover { background: var(--c-accent-dark); color: #fff; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(241,149,0,.35); }
.btn-outline { background: transparent; color: var(--c-primary); border-color: var(--c-primary); }
.btn-outline:hover { background: var(--c-primary); color: #fff; }
.btn-ghost { background: rgba(255,255,255,.15); color: #fff; backdrop-filter: blur(8px); border-color: rgba(255,255,255,.3); }
.btn-ghost:hover { background: rgba(255,255,255,.25); color: #fff; }
.btn-sm { height: 36px; padding: 0 16px; font-size: 14px; }
.btn-lg { height: 52px; padding: 0 32px; font-size: 17px; border-radius: 26px; }

/* ========= 顶部导航 ========= */
.topbar {
    background: var(--c-bg-dark);
    color: rgba(255,255,255,.7);
    font-size: 13px;
    height: 36px;
    display: flex;
    align-items: center;
}
.topbar .container { display: flex; justify-content: space-between; align-items: center; }
.topbar a { color: rgba(255,255,255,.7); }
.topbar a:hover { color: #fff; }
.topbar-info span { margin-right: 16px; }
.topbar-info i { color: var(--c-dark-on-hi); margin-right: 4px; }
/* 顶栏图标：原「✆」是老式符号字形，13px 下会被字体回退成「圆圈+斜杠」（像禁止符号），
   已统一换成填充式话筒 SVG（fill:currentColor → 跟随 --c-dark-on-hi） */
.topbar-info i svg { width: 13px; height: 13px; vertical-align: -2px; display: inline-block; }
.topbar-links a { margin-left: 16px; }

/* ========= 主导航 ========= */
.header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--c-line);
}
.header .container { display: flex; align-items: center; height: 72px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 22px; color: var(--c-text); }
.logo-mark {
    width: 36px; height: 36px; border-radius: 8px;
    background: linear-gradient(135deg, var(--c-primary), #266FE8);
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 18px; box-shadow: 0 4px 12px rgba(0,82,217,.3);
}
.logo small { font-size: 12px; color: var(--c-text-mute); font-weight: 400; display: block; margin-top: 2px; line-height: 1; }
.logo-text { font-size: 20px; letter-spacing: -0.5px; }
.nav { margin-left: 56px; display: flex; gap: 4px; }
/* 汉堡按钮默认隐藏：仅 ≤768px（移动端导航折叠）才由 media 内规则显示。
   桌面端显式 display:none，确保一级导航始终平铺、不被折叠按钮挤压。 */
.nav-toggle { display: none; }
.nav a {
    position: relative;
    padding: 24px 16px;
    font-size: 15px; font-weight: 500; color: var(--c-text);
}
.nav a:hover, .nav a.active { color: var(--c-primary); }
.nav a.active::after, .nav a:hover::after {
    content: ""; position: absolute; left: 16px; right: 16px; bottom: 18px; height: 3px;
    background: var(--c-primary); border-radius: 2px;
}
.header-right { margin-left: auto; display: flex; align-items: center; gap: 16px; }
/* 页头电话：图标是内联 SVG，fill=currentColor 继承本行的 --c-accent。
   原为彩色 emoji「📞」——自带红橙 3D 字形且**不吃 color**，和旁边的橙色号码
   形成「两种橙」。字号 18px 时图标取 22px，视觉重量才与粗体数字持平。
   ⚠ 改图标只改 tools/_apply_data.py 的 PHONE / HEADER_PHONE_RE，别逐页手改 */
.header-phone {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 18px; font-weight: 700; color: var(--c-accent); letter-spacing: -.5px;
}
.header-phone svg { width: 22px; height: 22px; flex: none; display: block; }

/* ========= 页脚 ========= */
.footer {
    /* 深色区块：与 Hero 同色系，压深一档，避免与 hero 抢视觉 */
    background: linear-gradient(160deg, var(--c-dark-deep) 0%, var(--c-dark-deep-2) 100%);
    color: var(--c-dark-on-sub);
    padding: 64px 0 0;
}
.footer h4 { color: #fff; font-size: 16px; font-weight: 600; margin-bottom: 20px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr 1.2fr; gap: 40px; }
.footer ul li { margin-bottom: 12px; font-size: 14px; }
.footer ul li a:hover { color: #fff; }
.footer-about { font-size: 13px; line-height: 1.8; color: rgba(255,255,255,.55); }
.footer-contact { font-size: 14px; }
.footer-contact .phone { font-size: 24px; color: var(--c-dark-on); font-weight: 700; margin: 4px 0 8px; }
.qrcode {
    width: 110px; height: 110px; border-radius: 8px;
    background: linear-gradient(135deg, #fff 49%, var(--c-primary) 49% 51%, #fff 51%);
    padding: 8px; display: flex; align-items: center; justify-content: center;
    font-size: 11px; color: var(--c-text-sub); border: 1px solid #fff;
}
/* 页脚客服微信二维码 */
.footer-qr { background: #fff; flex: 0 0 auto; }
.footer-qr img { width: 100%; height: 100%; object-fit: contain; display: block; border-radius: 4px; }
.copyright {
    margin-top: 48px; padding: 24px 0;
    border-top: 1px solid rgba(255,255,255,.1);
    font-size: 13px; text-align: center; color: rgba(255,255,255,.45);
}
.copyright a { color: rgba(255,255,255,.45); }
.copyright a:hover { color: rgba(255,255,255,.7); }

/* ========= 通用区块 ========= */
.section { padding: 96px 0; }
.section-tight { padding: 64px 0; }
.section-head { text-align: center; margin-bottom: 56px; }
.section-head .eyebrow {
    display: inline-block; font-size: 14px; font-weight: 600; color: var(--c-primary);
    padding: 4px 14px; border-radius: 12px; background: var(--c-primary-light); margin-bottom: 16px;
}
.section-head h2 {
    font-size: 36px; font-weight: 800; color: var(--c-text);
    letter-spacing: -0.5px; line-height: 1.3; margin-bottom: 16px;
}
.section-head h2 .accent { color: var(--c-accent); }
.section-head p { font-size: 16px; color: var(--c-text-sub); max-width: 640px; margin: 0 auto; }

/* 面包屑 */
.breadcrumb {
    background: var(--c-bg-soft);
    padding: 18px 0;
    border-bottom: 1px solid var(--c-line);
}
.breadcrumb .container { display: flex; align-items: center; font-size: 14px; color: var(--c-text-mute); }
.breadcrumb a:hover { color: var(--c-primary); }
.breadcrumb .sep { margin: 0 10px; color: var(--c-text-mute); }
.breadcrumb .current { color: var(--c-text); font-weight: 500; }

/* banner 上方的小标签（Hero / 子页 banner 共用，2026-09-12 收口）
   ⚠ 原先只定义在 home.css，而 faq.html 是全站唯一**不引 home.css** 的页面 →
     FAQ 的 banner 一旦用它就完全丢样式（与 .cta-section 当年的坑同类）。
     现在统一放本文件，home.css 只留一条指向这里的注释。 */
.hero-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 16px; border-radius: 16px;
    background: rgba(255,255,255,.10); border: 1px solid var(--c-dark-line);
    color: var(--c-dark-on); font-size: 13px; font-weight: 600;
    margin-bottom: 24px;
}
.hero-eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--c-dark-on-hi); box-shadow: 0 0 8px rgba(169,198,255,.8); }

/* 子页 banner */
.page-banner {
    padding: 80px 0 64px;
    background: var(--c-dark-grad);
    color: #fff;
    position: relative;
    overflow: hidden;
}
.page-banner::after {
    content: ""; position: absolute; right: -120px; top: -120px; width: 480px; height: 480px;
    background: radial-gradient(circle, var(--c-dark-glow), transparent 70%);
}
.page-banner::before {
    content: ""; position: absolute; left: -100px; bottom: -160px; width: 360px; height: 360px;
    background: radial-gradient(circle, rgba(88,132,255,.35), transparent 70%);
}
.page-banner .container { position: relative; z-index: 1; }
.page-banner h1 { font-size: 44px; font-weight: 800; letter-spacing: -1px; line-height: 1.2; }
.page-banner h1 .accent { color: var(--c-dark-on-hi); }
.page-banner p { margin-top: 16px; font-size: 18px; color: var(--c-dark-on-sub); max-width: 720px; }

/* 底部咨询 CTA —— 全站唯一真源
   使用页：index / cases / cases/case-1..65 / news / news-detail / resources / geo
   ⚠ 该组件原先只定义在 home.css，而 65 个案例详情页（见 tools/_seo_cases.py）
     只加载 common.css + case-detail.css，导致 CTA 区块完全丢失样式（无底色/无居中/无内距）。
     现统一收口到 common.css；home.css 只保留一条指向本处的注释。
   2026-09-12：底色由橙金改为与 Hero 同源的深蓝渐变（用户选定「深色区块统一换装」），
   深底上不再出现橙色，主按钮改白底蓝字以保证对比度。 */
.cta-section {
    background: var(--c-dark-grad);
    color: #fff; text-align: center; padding: 80px 0; position: relative; overflow: hidden;
}
.cta-section::before {
    content: ""; position: absolute; inset: 0;
    background-image: radial-gradient(circle at 20% 50%, rgba(255,255,255,.14), transparent 50%);
}
.cta-section .container { position: relative; }

/* 深色区块内的按钮 —— 深底上不出现橙色，一律「白底蓝字」；
   橙色按钮（.btn-accent）仍保留在白底区块（顶栏 / 卡片 / 报价表）作强调色。
   新增深色区块时，把容器类名补进下面两组选择器即可。 */
.hero .btn-accent,
.hero .btn-primary,
.page-banner .btn-accent,
.page-banner .btn-primary,
.case-detail-hero .btn-accent,
.case-detail-hero .btn-primary,
.cta-section .btn-accent,
.cta-section .btn-primary { background: #fff; color: var(--c-primary); }
.hero .btn-accent:hover,
.hero .btn-primary:hover,
.page-banner .btn-accent:hover,
.page-banner .btn-primary:hover,
.case-detail-hero .btn-accent:hover,
.case-detail-hero .btn-primary:hover,
.cta-section .btn-accent:hover,
.cta-section .btn-primary:hover { background: #EDF2FF; color: var(--c-primary-dark); box-shadow: 0 8px 20px rgba(8,20,40,.35); }
.cta-section h2 { font-size: 36px; font-weight: 800; margin-bottom: 16px; }
.cta-section p { font-size: 18px; opacity: .9; margin-bottom: 32px; }

/* 表单通用 */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 14px; color: var(--c-text-sub); margin-bottom: 8px; font-weight: 500; }
.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 12px 14px; border: 1px solid var(--c-line); border-radius: var(--radius-md);
    font-size: 15px; background: #fff; transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    border-color: var(--c-primary); box-shadow: 0 0 0 3px rgba(0,82,217,.12);
}
.form-group textarea { resize: vertical; min-height: 100px; }

/* 旧分页器 —— 现仅 resources.html 使用。
   ⚠ 该页分页是与上方 tab 计数（网络媒体 58,400 / 共 128 页）配套的「大目录」静态占位，
   按钮目前无行为，待产品确认口径后再决定「改成真实分页」还是「整块移除」。
   新页面请用下方 .pagination。 */
/* 旧 .pager 静态占位已废弃：统一用上面的 .pagination 组件 */

/* 分页器（唯一真源）—— news.html / cases.html 共用；
   按钮由各页 JS 按真实条目数渲染，见 assets/js/common.js 的 renderPager() */
.pagination {
    display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px;
    margin: 48px 0 24px;
}
.pagination button {
    min-width: 38px; height: 38px; padding: 0 12px; border: 1px solid var(--c-line); border-radius: 8px;
    background: #fff; color: var(--c-text-sub); font-size: 14px; font-weight: 500;
    font-family: inherit; line-height: 1; cursor: pointer; transition: all .2s;
}
.pagination button:hover:not(:disabled) { border-color: var(--c-primary); color: var(--c-primary); }
.pagination button.active { background: var(--c-primary); color: #fff; border-color: var(--c-primary); }
.pagination button:disabled { opacity: .45; cursor: not-allowed; }
.pagination button:focus-visible { outline: 2px solid var(--c-primary); outline-offset: 2px; }
.pagination .gap { min-width: 24px; text-align: center; font-size: 14px; color: var(--c-text-mute); }
.pagination .info { font-size: 14px; color: var(--c-text-mute); margin: 0 12px; }

/* 响应式 */
/* 导航共 7 项，中等宽度下先收窄间距，避免换行/挤压 */
@media (max-width: 1180px) {
    .nav { margin-left: 20px; gap: 0; }
    .nav a { padding: 24px 10px; font-size: 14px; }
    .nav a.active::after, .nav a:hover::after { left: 10px; right: 10px; }
    .header-right { gap: 12px; }
    .header-phone { font-size: 16px; }
    .header-phone svg { width: 20px; height: 20px; }
}
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
    .footer-about { grid-column: 1 / -1; }
}
@media (max-width: 980px) {
    .nav { margin-left: 12px; }
    .nav a { padding: 24px 8px; font-size: 13px; }
    .header-phone { display: none; }
}
@media (max-width: 768px) {
    .topbar, .header-phone { display: none; }

    /* 移动端导航：汉堡按钮 + 下拉抽屉（按钮由 common.js 注入） */
    .header .container { height: 60px; }
    .nav-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        width: 42px; height: 42px;
        margin-left: auto;
        padding: 10px;
        border: none;
        border-radius: 8px;
        background: transparent;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }
    .nav-toggle:focus-visible { outline: 2px solid var(--c-primary); outline-offset: 2px; }
    .nav-toggle span {
        display: block;
        width: 100%; height: 2px;
        border-radius: 2px;
        background: var(--c-text);
        transition: transform .25s ease, opacity .25s ease;
    }
    .nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav-toggle.is-open span:nth-child(2) { opacity: 0; }
    .nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .nav {
        display: none;
        position: fixed;
        top: 60px; left: 0; right: 0;
        flex-direction: column;
        gap: 0;
        margin: 0;
        padding: 8px 0;
        background: #fff;
        border-bottom: 1px solid var(--c-line);
        box-shadow: 0 12px 24px rgba(10,30,76,.10);
        z-index: 99;
    }
    .nav.is-open { display: flex; }
    .nav a {
        display: block;
        padding: 14px 24px;
        font-size: 16px;
        border-left: 3px solid transparent;
    }
    .nav a.active, .nav a:hover { color: var(--c-primary); background: rgba(38,111,232,.06); border-left-color: var(--c-primary); }
    .nav a.active::after, .nav a:hover::after { display: none; }

    .section { padding: 64px 0; }
    .section-head h2 { font-size: 26px; }
    .page-banner h1 { font-size: 30px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .cta-section { padding: 56px 0; }
    .cta-section h2 { font-size: 24px; margin-bottom: 12px; }
    .cta-section p { font-size: 15px; margin-bottom: 24px; }
}

/* ==========================================================================
   小屏手机精细适配（≤480px，375px / 414px 主流机型）
   ========================================================================== */
@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .section { padding: 48px 0; }
    .section-head h2 { font-size: 22px; }
    .page-banner { padding: 40px 0; }
    .page-banner h1 { font-size: 26px; }
    .page-banner p { font-size: 14px; }

    .footer-grid { grid-template-columns: 1fr; gap: 28px; }

    .cta-section h2 { font-size: 24px; }
    .cta-section .btn { width: 100%; justify-content: center; }

    /* 按钮触控目标：满足移动端 ≥44px 建议 */
    .btn { min-height: 44px; }
}

/* 蜜罐字段（联系表单 / 资讯页留资表单共用）：对真实用户不可见，但仍在 DOM 中供机器人填写 */
.hp-field {
    position: absolute; left: -9999px; width: 1px; height: 1px;
    overflow: hidden; opacity: 0; pointer-events: none;
}
