/* ============================================================
   SoeayCMS 官网公共样式：基础重置 / 按钮 / 头部 / 页脚 / 区块
   ============================================================ */

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    font-family: var(--font-sans);
    font-size: var(--fs-base);
    line-height: 1.75;
    color: var(--ink-700);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; transition: color .2s ease; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input { font-family: inherit; }

::selection { background: rgba(31, 139, 216, .18); }

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

/* ---------- 通用文字 ---------- */
.eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--brand-600);
    font-weight: 600;
}
.eyebrow::before {
    content: ""; width: 22px; height: 2px; border-radius: 2px;
    background: var(--grad-brand);
}
.eyebrow.on-dark { color: var(--brand-300); }

.section { padding: var(--sp-20) 0; }
.section-head { max-width: 720px; margin-bottom: var(--sp-12); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }
.section-title {
    font-family: var(--font-display);
    font-size: var(--fs-h2);
    font-weight: 700;
    color: var(--ink-900);
    line-height: 1.3;
    margin: 14px 0 12px;
    letter-spacing: -.01em;
}
.section-desc { font-size: var(--fs-lg); color: var(--ink-500); line-height: 1.8; }

/* ---------- 按钮 ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    height: 46px; padding: 0 26px;
    border-radius: var(--r-sm);
    font-size: 15px; font-weight: 600; letter-spacing: .01em;
    white-space: nowrap;
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
}
.btn .icon { width: 17px; height: 17px; }
.btn-primary { background: var(--grad-brand); color: #fff; box-shadow: var(--shadow-brand); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -8px rgba(12,112,189,.5); color:#fff; }
.btn-outline { border: 1.5px solid var(--line-strong); color: var(--ink-800); background: #fff; }
.btn-outline:hover { border-color: var(--brand-500); color: var(--brand-700); }
.btn-ghost-light { border: 1.5px solid rgba(255,255,255,.35); color: #fff; }
.btn-ghost-light:hover { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.6); color:#fff; }
.btn-lg { height: 52px; padding: 0 32px; font-size: 16px; }
.btn-sm { height: 38px; padding: 0 18px; font-size: 14px; }

/* ---------- 线性图标 ---------- */
.icon { width: 22px; height: 22px; stroke: currentColor; stroke-width: 1.7; fill: none; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.icon-lg { width: 28px; height: 28px; }

/* ============================================================
   顶部导航
   ============================================================ */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255, 255, 255, .88);
    backdrop-filter: saturate(180%) blur(14px);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--line);
}
.header-inner {
    height: var(--header-h);
    display: flex; align-items: center; gap: 36px;
}
.logo img { height: 34px; width: auto; }

.main-nav { margin-left: auto; }
.nav-list { display: flex; align-items: center; gap: 4px; }
.nav-item a {
    display: block; padding: 8px 14px;
    font-size: 16px; font-weight: 500; color: var(--ink-700);
    border-radius: var(--r-sm);
}
.nav-item a:hover { color: var(--brand-700); background: var(--brand-50); }
.nav-item.active a { color: var(--brand-700); font-weight: 600; }
.nav-item.active a { position: relative; }
.nav-item.active a::after {
    content: ""; position: absolute; left: 14px; right: 14px; bottom: 1px;
    height: 2px; border-radius: 2px; background: var(--brand-600);
}
.header-cta { display: flex; align-items: center; gap: 12px; }
.icon-btn {
    width: 40px; height: 40px; border-radius: var(--r-sm);
    display: inline-flex; align-items: center; justify-content: center;
    color: var(--ink-600); border: 1px solid var(--line); background: #fff;
}
.icon-btn:hover { color: var(--brand-700); border-color: var(--brand-300); }
.nav-toggle { display: none; }

/* ============================================================
   内页页头（面包屑横幅）
   ============================================================ */
.page-hero {
    background: var(--grad-navy);
    position: relative; overflow: hidden;
    padding: 56px 0 60px;
}
.page-hero::before {
    content: ""; position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: linear-gradient(90deg, transparent, #000 30%, #000 70%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%, #000 70%, transparent);
}
.page-hero::after {
    content: ""; position: absolute; top: -160px; right: -80px;
    width: 480px; height: 380px; border-radius: 50%;
    background: radial-gradient(circle, rgba(31,139,216,.35), transparent 68%);
    pointer-events: none;
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 {
    font-family: var(--font-display);
    font-size: var(--fs-h1); color: #fff; font-weight: 700;
    letter-spacing: -.01em; margin: 10px 0 12px;
}
.page-hero p { color: rgba(255,255,255,.72); font-size: var(--fs-lg); max-width: 680px; }
.crumb { font-size: var(--fs-sm); color: rgba(255,255,255,.55); display: flex; gap: 8px; align-items: center; }
.crumb a:hover { color: #fff; }
.crumb .sep { opacity: .5; }
.crumb .current { color: rgba(255,255,255,.85); }

/* ============================================================
   页脚
   ============================================================ */
.site-footer { background: #081f38; color: rgba(255,255,255,.62); }
.footer-top {
    display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 48px;
    padding: 64px 0 48px;
}
.footer-logo {
    display: inline-flex; align-items: center;
    background: #fff; border-radius: 9px;
    padding: 7px 13px; margin-bottom: 18px;
    box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
.footer-logo img { height: 26px; width: auto; }
.footer-brand p { font-size: var(--fs-sm); line-height: 1.9; max-width: 320px; }
.footer-col h4 { color: #fff; font-size: 15px; font-weight: 600; margin-bottom: 18px; }
.footer-col li { margin-bottom: 11px; font-size: var(--fs-sm); }
.footer-col a:hover { color: #fff; }
.footer-contact li { display: flex; gap: 10px; align-items: baseline; font-size: var(--fs-sm); margin-bottom: 11px; }
.footer-contact .k { color: rgba(255,255,255,.4); flex: none; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,.08);
    padding: 22px 0;
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    font-size: var(--fs-xs); color: rgba(255,255,255,.45);
    flex-wrap: wrap;
}
.footer-bottom .beian a { display: inline-flex; align-items: center; gap: 6px; margin-left: 18px; }
.footer-bottom .beian a:hover { color: #fff; }
.footer-bottom .icon { width: 14px; height: 14px; }

/* ============================================================
   通用卡片 / 标签
   ============================================================ */
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-xs);
}
.tag {
    display: inline-flex; align-items: center;
    height: 24px; padding: 0 10px;
    font-size: var(--fs-xs); font-weight: 600;
    border-radius: var(--r-pill);
}
.tag-free { background: var(--success-bg); color: var(--success); }
.tag-paid { background: #fdf1e7; color: #c2610c; }
.tag-blue { background: var(--brand-50); color: var(--brand-700); }

/* ============================================================
   404 / 错误页
   ============================================================ */
.error-page {
    text-align: center;
    padding: 104px 24px 120px;
}
.error-code {
    font-family: var(--font-display);
    font-size: clamp(96px, 18vw, 148px);
    font-weight: 800; line-height: 1; letter-spacing: .04em;
    background: var(--grad-brand);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.error-page h1 {
    font-family: var(--font-display);
    font-size: 26px; font-weight: 700; color: var(--ink-900);
    margin: 22px 0 12px;
}
.error-page p { color: var(--ink-500); font-size: var(--fs-lg); margin-bottom: 32px; }
.error-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   富文本正文（内容详情 / 单页共用）
   ============================================================ */
.prose { color: var(--ink-700); font-size: 15.5px; line-height: 1.9; }
.prose > *:first-child { margin-top: 0; }
.prose h2 { font-size: 21px; color: var(--ink-900); margin: 34px 0 14px; font-weight: 700; }
.prose h3 { font-size: 17px; color: var(--ink-900); margin: 26px 0 10px; font-weight: 600; }
.prose h4 { font-size: 15.5px; color: var(--ink-900); margin: 20px 0 8px; font-weight: 600; }
.prose p { margin: 0 0 16px; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 22px; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li { margin-bottom: 7px; }
.prose a { color: var(--brand-600); text-decoration: underline; text-underline-offset: 3px; }
.prose img { border-radius: var(--r-md); margin: 18px 0; border: 1px solid var(--line); max-width: 100%; height: auto; }
.prose blockquote {
    border-left: 3px solid var(--brand-400);
    background: var(--bg-soft);
    padding: 14px 20px; margin: 0 0 18px;
    border-radius: 0 var(--r-sm) var(--r-sm) 0;
    color: var(--ink-600);
}
.prose code {
    font-family: var(--font-mono); font-size: 13.5px;
    background: var(--bg-soft); border: 1px solid var(--line);
    border-radius: 5px; padding: 2px 7px; color: var(--brand-800);
}
.prose pre {
    background: var(--ink-900); color: #dcebf7;
    padding: 20px 22px; border-radius: var(--r-md);
    overflow-x: auto; margin: 0 0 18px; font-size: 13.5px; line-height: 1.7;
}
.prose pre code { background: none; border: none; padding: 0; color: inherit; }
/* 代码语法高亮（配色与首页代码窗一致：标签蓝 / 属性绿 / 字符串暖黄 / 注释蓝灰 / 字段粉） */
.prose pre .hl-tag { color: #6fc3ff; }
.prose pre .hl-attr { color: #9fd48f; }
.prose pre .hl-str { color: #e8c07d; }
.prose pre .hl-cmt { color: #5f7fa0; }
.prose pre .hl-fn { color: #e897c0; }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 18px; font-size: var(--fs-sm); display: block; overflow-x: auto; border: none; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 14px; text-align: left; }
.prose th { background: var(--bg-soft); color: var(--ink-800); font-weight: 600; }
.prose hr { border: none; border-top: 1px solid var(--line); margin: 28px 0; }

/* ============================================================
   通用分页（soeay-pagination）
   ============================================================ */
.soeay-pagination { margin-top: 44px; display: flex; justify-content: center; }
.pagination-list { display: flex; gap: 6px; flex-wrap: wrap; }
.page-item a, .page-item span {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 38px; height: 38px; padding: 0 12px;
    border: 1px solid var(--line); border-radius: var(--r-sm);
    background: #fff; font-size: var(--fs-sm); color: var(--ink-700);
}
.page-item a:hover { border-color: var(--brand-400); color: var(--brand-700); }
.page-item.active span { background: var(--grad-brand); border-color: transparent; color: #fff; font-weight: 600; }
.page-item.disabled span, .page-item.dots span { color: var(--ink-300); background: transparent; }

/* ============================================================
   通用营销组件：特性卡 / CTA 条（首页与内页共用）
   ============================================================ */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.feature-card {
    padding: 30px 28px;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--r-lg);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
    position: relative; overflow: hidden;
    /* 双列 grid：fc-icon 左列，h3 右列同行，p 横跨整宽在下方 */
    display: grid; grid-template-columns: auto 1fr; gap: 0 14px; align-items: start;
}
.feature-card::after {
    content: ""; position: absolute; right: -30px; top: -30px;
    width: 90px; height: 90px; border-radius: 50%;
    background: radial-gradient(circle, rgba(31,139,216,.1), transparent 70%);
    opacity: 0; transition: opacity .25s ease;
}
.feature-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--brand-200); }
.feature-card:hover::after { opacity: 1; }
.fc-icon {
    width: 50px; height: 50px; border-radius: 13px;
    background: linear-gradient(135deg, var(--brand-50), #e3f0fb);
    border: 1px solid var(--brand-100);
    color: var(--brand-600);
    display: flex; align-items: center; justify-content: center;
    /* 同行：去掉原来的 margin-bottom，与 h3 顶部对齐 */
}
.feature-card h3 { font-size: 17.5px; font-weight: 600; color: var(--ink-900); margin-bottom: 9px; }
.feature-card p { font-size: var(--fs-sm); color: var(--ink-500); line-height: 1.85; grid-column: 1 / -1; }
.feature-card code {
    font-family: var(--font-mono); font-size: 12px;
    background: var(--bg-soft); color: var(--brand-700);
    border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px;
}

.cta-band {
    margin: 0 24px;
    border-radius: var(--r-xl);
    background: var(--grad-brand);
    color: #fff;
    padding: 56px 64px;
    display: flex; align-items: center; justify-content: space-between; gap: 40px;
    position: relative; overflow: hidden;
}
.cta-band::before {
    content:""; position:absolute; inset:0;
    background-image: linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
    background-size: 36px 36px;
}
.cta-band > * { position: relative; }
.cta-band h2 { font-family: var(--font-display); font-size: 27px; font-weight: 700; margin-bottom: 8px; }
.cta-band p { color: rgba(255,255,255,.82); font-size: var(--fs-base); }
.cta-actions { display: flex; gap: 14px; flex: none; }
.cta-band .btn-white { background: #fff; color: var(--brand-700); font-weight: 600; }
.cta-band .btn-white:hover { transform: translateY(-2px); box-shadow: 0 12px 26px -10px rgba(0,0,0,.3); color: var(--brand-700); }

/* ---------- 动画：入场 ---------- */
@keyframes rise {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}
.rise { opacity: 0; animation: rise .7s cubic-bezier(.22,.61,.36,1) forwards; }
.rise-1 { animation-delay: .08s; } .rise-2 { animation-delay: .16s; }
.rise-3 { animation-delay: .24s; } .rise-4 { animation-delay: .32s; }
.rise-5 { animation-delay: .40s; } .rise-6 { animation-delay: .48s; }

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; scroll-behavior: auto; }
}

/* ============================================================
   响应式（公共部分）
   ============================================================ */
@media (max-width: 1024px) {
    .footer-top { grid-template-columns: 1fr 1fr; gap: 36px; }
    .feature-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .main-nav, .header-cta .btn { display: none; }
    .nav-toggle {
        display: inline-flex; margin-left: auto;
        width: 42px; height: 42px; align-items: center; justify-content: center;
        color: var(--ink-800);
    }
    .header-inner { gap: 12px; justify-content: space-between; }
    .main-nav.is-open {
        display: block; position: fixed; top: var(--header-h); left: 0; right: 0;
        background: #fff; border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md); padding: 12px 20px 20px;
    }
    .main-nav.is-open .nav-list { flex-direction: column; align-items: stretch; gap: 2px; }
    .nav-item.active a::after { display: none; }
    .footer-top {
        /* 移动端：footer-brand 单独占整行，三个 footer-col 一行 3 列 */
        grid-template-columns: 1fr 1fr 1fr;
        gap: 28px 16px; padding: 44px 0 32px;
    }
    .footer-top > .footer-brand { grid-column: 1 / -1; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
    .footer-bottom .beian a { margin-left: 0; margin-right: 16px; }
    .feature-grid { grid-template-columns: 1fr; }
    .cta-band { margin: 0 16px; flex-direction: column; align-items: flex-start; padding: 36px 28px; }
}

/* 极窄屏（≤375px）宽度不够时，隐藏"联系我们"标题让列内容更紧凑 */
@media (max-width: 375px) {
    .footer-col:last-child h4 { display: none; }
}
