/* ============================================================
   悟安官网样式 - 简约大气 · 深蓝科技风
   ============================================================ */
:root {
    --navy: #0b1f3a;
    --navy-2: #122b4e;
    --blue: #1e5eff;
    --blue-dark: #1546c8;
    --cyan: #35c8e8;
    --text: #1f2937;
    --text-2: #64748b;
    --line: #e5eaf2;
    --bg-soft: #f5f8fc;
    --white: #ffffff;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(11, 31, 58, .08);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    color: var(--text);
    background: var(--white);
    line-height: 1.7;
    font-size: 16px;
}
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
a { color: inherit; text-decoration: none; transition: color .2s; }
img { max-width: 100%; display: block; }

/* ---------- 顶部导航 ---------- */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo img { height: 52px; width: auto; }
.nav { display: flex; gap: 8px; }
.nav a {
    padding: 8px 18px; font-size: 15px; color: var(--text);
    border-radius: 8px; font-weight: 500;
}
.nav a:hover { color: var(--blue); background: var(--bg-soft); }
.nav a.active { color: var(--blue); font-weight: 600; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.header-phone { color: var(--navy); font-weight: 700; font-size: 15px; }
.nav-toggle { display: none; background: none; border: none; font-size: 24px; cursor: pointer; color: var(--navy); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(1200px 500px at 80% -10%, rgba(53,200,232,.25), transparent 60%),
        radial-gradient(900px 500px at 10% 110%, rgba(30,94,255,.35), transparent 60%),
        linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 60%, #16335f 100%);
    color: var(--white);
    padding: 120px 0 130px;
    text-align: center;
}
/* 细网格“防线”打底 */
.hero-grid {
    position: absolute; inset: 0; pointer-events: none;
    background-image:
        linear-gradient(rgba(133,183,235,.10) 1px, transparent 1px),
        linear-gradient(90deg, rgba(133,183,235,.10) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(120% 100% at 50% 40%, #000 40%, transparent 100%);
    mask-image: radial-gradient(120% 100% at 50% 40%, #000 40%, transparent 100%);
}
/* 右侧盾牌符号 */
.hero-shield {
    position: absolute; right: 5%; top: 50%;
    transform: translateY(-50%);
    width: 240px; opacity: .9; pointer-events: none;
}
.hero-eyebrow {
    display: flex; align-items: center; justify-content: center; gap: 14px;
    color: #85b7eb; font-size: 13px; letter-spacing: 6px; margin-bottom: 22px;
}
.hero-eyebrow span { width: 36px; height: 1px; background: rgba(133,183,235,.7); display: inline-block; }
.hero h1 { font-size: 46px; font-weight: 800; letter-spacing: 8px; line-height: 1.3; margin-bottom: 12px; }
.hero h1 .accent { color: var(--cyan); }
.hero-sub {
    font-size: 20px; color: var(--cyan); font-weight: 600;
    letter-spacing: 14px; text-indent: 14px;  /* text-indent 抵消末字间距，保持视觉居中 */
}
.hero-pills { margin-top: 30px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.hero-pills span {
    border: 1px solid rgba(133,183,235,.55); color: #b5d4f4;
    font-size: 14px; letter-spacing: 2px; padding: 6px 18px; border-radius: 999px;
}
.hero p { margin-top: 18px; font-size: 18px; color: rgba(255,255,255,.75); letter-spacing: 1px; }
.hero-btns { margin-top: 40px; display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
@media (max-width: 960px) {
    .hero-shield { display: none; }
    .hero h1 { letter-spacing: 4px; }
    .hero-sub { letter-spacing: 6px; text-indent: 6px; }
}
.btn {
    display: inline-block; padding: 13px 34px; border-radius: 999px;
    font-size: 15px; font-weight: 600; cursor: pointer; border: none;
    transition: transform .2s, box-shadow .2s, background .2s;
}
.btn-primary { background: var(--blue); color: var(--white); box-shadow: 0 8px 24px rgba(30,94,255,.35); }
.btn-primary:hover { background: var(--blue-dark); transform: translateY(-2px); }
.btn-ghost { border: 1px solid rgba(255,255,255,.4); color: var(--white); background: transparent; }
.btn-ghost:hover { background: rgba(255,255,255,.1); transform: translateY(-2px); }
.btn-outline { border: 1px solid var(--blue); color: var(--blue); background: transparent; }
.btn-outline:hover { background: var(--blue); color: var(--white); }

/* ---------- 区块 ---------- */
.section { padding: 90px 0; }
.section.soft { background: var(--bg-soft); }
.section-head { text-align: center; margin-bottom: 56px; }
.section-head .eyebrow {
    display: inline-block; font-size: 13px; color: var(--blue);
    letter-spacing: 4px; font-weight: 600; margin-bottom: 12px;
}
.section-head h2 { font-size: 34px; color: var(--navy); font-weight: 800; letter-spacing: 1px; }
.section-head p { margin-top: 14px; color: var(--text-2); max-width: 640px; margin-left: auto; margin-right: auto; }
.section-more { text-align: center; margin-top: 44px; }

/* ---------- 网格卡片 ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }

/* ---------- 客户案例 LOGO 滚动墙（三行独立循环，杜绝同屏重复） ---------- */
.logo-wall { padding: 10px 0; overflow: hidden; }
/* 鼠标悬停在案例区时暂停滚动，方便查看单个案例；移开后继续 */
.logo-wall:hover .logo-track { animation-play-state: paused; }
.logo-wall .logo-track + .logo-track { margin-top: 16px; }
.logo-track {
    display: flex; width: max-content;
    animation: logo-scroll var(--dur, 120s) linear infinite;
    will-change: transform;
}
/* 两段内容完全相同的序列；每段自带右内边距(=间距)，translateX(-50%) 恰好落在副本起点，无缝衔接 */
.logo-seq { display: flex; gap: 16px; padding-right: 16px; }
@keyframes logo-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
    .logo-track { animation: none; }
}
.logo-item {
    flex: 0 0 auto;
    /* 每行卡数 --per（PHP 按该行实际卡数传入，最多 10）正好铺满一屏，再加 48px 余量
       使序列恒宽于视口——同名卡片的重复周期(序列宽)大于视口宽度，
       视口内任何时刻同名只出现一次 */
    width: calc((100vw - 80px) / var(--per, 10) + 48px);
    min-width: 130px;
    height: 88px;
    background: var(--white); border: 1px solid var(--line); border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    padding: 12px 18px; transition: border-color .2s, box-shadow .2s;
    overflow: hidden;
}
.logo-item:hover { border-color: var(--blue); box-shadow: 0 6px 18px rgba(15,23,42,.08); }
.logo-item span {
    font-weight: 700; font-size: 15px; color: #64748b; letter-spacing: 1px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.logo-item img { max-width: 100%; max-height: 60px; object-fit: contain; }
/* 窄屏：每行改为一屏 3 张，卡片收窄 */
@media (max-width: 560px) {
    .logo-seq { gap: 10px; padding-right: 10px; }
    .logo-item { width: calc((100vw - 40px) / var(--per, 3) + 24px); min-width: 110px; height: 72px; padding: 8px 12px; }
}

/* ---------- 关于我们 ---------- */
.about-hero { padding: 90px 0 80px; }
.about-hero h1 { font-size: 44px; }

/* ---------- 公司资质（一行四列图片） ---------- */
.cert-item {
    background: var(--white); border: 1px solid var(--line); border-radius: 12px;
    padding: 14px; text-align: center;
    transition: transform .2s, box-shadow .2s;
}
.cert-item:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(15,23,42,.08); }
.cert-img {
    position: relative; width: 100%; aspect-ratio: 4 / 3;
    background: #f8fafc; border: 1px dashed #cbd5e1; border-radius: 8px;
    overflow: hidden; display: flex; align-items: center; justify-content: center;
}
.cert-ph { font-size: 14px; color: #94a3b8; letter-spacing: 2px; }
/* 资质证书正常清晰显示（防下载由 cert-image.php 会话授权 + uploads/certs/ 目录保护实现） */
.cert-img img {
    position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: contain; background: #fff; z-index: 1; padding: 6px;
    -webkit-user-select: none; user-select: none;
    -webkit-touch-callout: none;
    -webkit-user-drag: none;
}
.cert-title { margin-top: 12px; font-size: 14px; font-weight: 600; color: var(--text); line-height: 1.5; }

/* 平滑滚动锚点偏移（避免被固定导航遮挡） */
#business, #solutions, #cases, #news { scroll-margin-top: 80px; }


.card {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 34px 28px;
    transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card .icon {
    width: 56px; height: 56px; border-radius: 14px;
    background: linear-gradient(135deg, rgba(30,94,255,.1), rgba(53,200,232,.15));
    display: flex; align-items: center; justify-content: center;
    font-size: 26px; margin-bottom: 20px;
}
.card h3 { font-size: 19px; color: var(--navy); margin-bottom: 10px; }
.card p { font-size: 14px; color: var(--text-2); }
.card .tag {
    display: inline-block; margin-top: 16px; padding: 4px 12px;
    background: rgba(30,94,255,.08); color: var(--blue);
    font-size: 12px; border-radius: 999px;
}
/* 首页解决方案卡片：整卡可点击跳详情 */
a.card { display: block; text-decoration: none; color: inherit; }
a.card p { margin-bottom: 14px; }
a.card .more { display: inline-block; color: var(--blue); font-size: 14px; font-weight: 600; }
a.card:hover .more { text-decoration: underline; }

/* ---------- 数字亮点 ---------- */
.stats {
    background: linear-gradient(135deg, var(--navy), var(--navy-2));
    color: var(--white); padding: 70px 0;
}
.stats .grid-4 { gap: 20px; }
.stat { text-align: center; }
.stat .num { font-size: 42px; font-weight: 800; color: var(--cyan); }
.stat .num span { font-size: 18px; font-weight: 600; }
.stat .label { margin-top: 6px; color: rgba(255,255,255,.65); font-size: 14px; }

/* ---------- 列表卡片（新闻/案例） ---------- */
.item-card {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--radius); overflow: hidden;
    transition: transform .25s, box-shadow .25s;
    display: flex; flex-direction: column;
}
.item-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.item-card .thumb {
    height: 180px;
    background: linear-gradient(135deg, #16335f, #1e5eff);
    display: flex; align-items: center; justify-content: center;
    color: rgba(255,255,255,.85); font-size: 40px;
}
.item-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.item-card .body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.item-card h3 { font-size: 17px; color: var(--navy); line-height: 1.5; margin-bottom: 10px; }
.item-card .meta { font-size: 13px; color: var(--text-2); margin-top: auto; display: flex; gap: 14px; }
.item-card .meta .cat { color: var(--blue); font-weight: 600; }
.text-thumb { padding: 20px 24px 0; }

/* ---------- 文章详情 ---------- */
.article {
    max-width: 860px; margin: 0 auto; background: var(--white);
    border: 1px solid var(--line); border-radius: var(--radius);
    padding: 48px 54px;
}
.article h1 { font-size: 28px; color: var(--navy); line-height: 1.5; margin-bottom: 16px; }
.article .article-meta { color: var(--text-2); font-size: 14px; padding-bottom: 24px; border-bottom: 1px solid var(--line); margin-bottom: 28px; }
.article .content { font-size: 16px; }
.article .content p { margin: 0 0 18px; line-height: 1.9; }
.article .content h2 { font-size: 20px; color: var(--navy); margin: 32px 0 16px; line-height: 1.5; }
.article .content h3 { font-size: 17px; color: var(--navy); margin: 24px 0 12px; line-height: 1.5; }
.article .content ul, .article .content ol { margin: 0 0 18px; padding-left: 22px; }
.article .content li { margin-bottom: 10px; line-height: 1.9; }
.article .content img { max-width: 100%; width: auto; max-height: 520px; height: auto; border-radius: 8px; margin: 12px auto; display: block; }
.article .content img { margin: 16px auto; border-radius: 8px; }
/* 首页案例卡片为可点击链接（跳转 cases.php），保持原卡片外观 */
a.logo-item { text-decoration: none; color: inherit; }
.back-link { display: inline-block; margin-bottom: 20px; color: var(--blue); font-size: 14px; }

/* ---------- 页头横幅（内页） ---------- */
.page-hero {
    background: linear-gradient(135deg, var(--navy), #16335f);
    color: var(--white); text-align: center; padding: 72px 0;
}
.page-hero h1 { font-size: 36px; letter-spacing: 2px; }
.page-hero p { margin-top: 12px; color: rgba(255,255,255,.65); }

/* ---------- 分类筛选 ---------- */
.filter-bar { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-bottom: 40px; }
.filter-bar a {
    padding: 8px 22px; border-radius: 999px; font-size: 14px;
    border: 1px solid var(--line); color: var(--text-2); background: var(--white);
}
.filter-bar a.active, .filter-bar a:hover { background: var(--blue); border-color: var(--blue); color: var(--white); }

/* ---------- 留言表单 ---------- */
.contact-wrap { display: grid; grid-template-columns: 1fr 1.2fr; gap: 50px; align-items: start; }
.contact-info h3 { font-size: 22px; color: var(--navy); margin-bottom: 16px; }
.contact-info p { color: var(--text-2); margin-bottom: 10px; }
.contact-form { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 34px; }
.contact-form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.contact-form .field { display: flex; flex-direction: column; min-width: 0; }
.contact-form label { font-size: 13px; color: var(--text); margin-bottom: 6px; font-weight: 600; }
.contact-form .req { color: #e02020; }
.contact-form input, .contact-form select, .contact-form textarea {
    width: 100%; padding: 12px 16px; border: 1px solid var(--line);
    border-radius: 10px; font-size: 14px; font-family: inherit; outline: none;
    transition: border .2s;
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus { border-color: var(--blue); }
.contact-form textarea { min-height: 110px; resize: vertical; }
.contact-form select { appearance: auto; background: var(--white); color: var(--text); cursor: pointer; }
.form-msg { margin-top: 12px; font-size: 14px; color: #16a34a; }
.form-msg.err { color: #dc2626; }

/* ---------- 关于我们 ---------- */
.about-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 50px; align-items: center; }
.about-visual {
    background: linear-gradient(135deg, var(--navy), var(--blue));
    border-radius: var(--radius); color: var(--white);
    padding: 60px 40px; text-align: center;
}
.about-visual .big { font-size: 60px; font-weight: 800; letter-spacing: 6px; }
.about-visual p { color: rgba(255,255,255,.7); margin-top: 10px; letter-spacing: 2px; }
.qual-list { list-style: none; margin-top: 24px; }
.qual-list li {
    padding: 14px 18px; margin-bottom: 12px;
    background: var(--bg-soft); border-radius: 10px;
    font-size: 14px; color: var(--text);
    border-left: 3px solid var(--blue);
}

/* ---------- 流程步骤 ---------- */
.steps { counter-reset: step; }
.step { display: flex; gap: 20px; padding: 22px 0; border-bottom: 1px dashed var(--line); }
.step:last-child { border-bottom: none; }
.step .no {
    flex: none; width: 44px; height: 44px; border-radius: 50%;
    background: var(--blue); color: var(--white); font-weight: 700;
    display: flex; align-items: center; justify-content: center;
}
.step h4 { color: var(--navy); font-size: 16px; }
.step p { color: var(--text-2); font-size: 14px; margin-top: 4px; }

/* ---------- 分页 ---------- */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 50px; }
.pagination a, .pagination span {
    padding: 8px 16px; border: 1px solid var(--line); border-radius: 8px;
    font-size: 14px; color: var(--text-2);
}
.pagination .cur { background: var(--blue); border-color: var(--blue); color: var(--white); }

/* ---------- CTA 横条 ---------- */
.cta-band {
    background: linear-gradient(120deg, var(--navy), var(--blue-dark));
    color: var(--white); padding: 64px 0; text-align: center;
}
.cta-band h2 { font-size: 28px; letter-spacing: 1px; }
.cta-band p { color: rgba(255,255,255,.7); margin: 12px 0 28px; }

/* ---------- 页脚 ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,.7); padding: 64px 0 0; }
.footer-inner { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.8fr; gap: 40px; padding-bottom: 44px; }
.footer-biz { padding-left: 36px; } /* 业务板块整体右移 */
.site-footer .logo { display: inline-flex; }
.site-footer .logo img { height: 44px; }
.site-footer h4 { color: var(--white); font-size: 15px; margin-bottom: 16px; letter-spacing: 1px; }
.site-footer a, .site-footer p { display: block; font-size: 14px; color: rgba(255,255,255,.6); margin-bottom: 10px; }
.site-footer a:hover { color: var(--cyan); }
.footer-contact, .footer-addr { font-size: 12px; }
.footer-contact { white-space: nowrap; }
.footer-addr { white-space: nowrap; }
#business .card { scroll-margin-top: 96px; }
#contact { scroll-margin-top: 96px; }
.footer-qr { margin-top: 20px; display: flex; gap: 44px; justify-content: center; align-items: flex-start; flex-wrap: wrap; }
.qr-item { display: flex; flex-direction: column; align-items: center; }
.qr-item img { display: block; width: 92px; height: 92px; }
.qr-item span { display: block; color: rgba(255,255,255,.7); font-size: 12px; margin-top: 8px; white-space: nowrap; }
.site-footer .footer-company { display: block; color: var(--white); font-weight: 700; font-size: 15px; margin-bottom: 16px; cursor: default; }
.site-footer .footer-contact-title { color: rgba(255,255,255,.6); font-weight: 400; font-size: 14px; margin-top: 6px; margin-bottom: 10px; }
.site-footer .footer-contact { margin-bottom: 6px; }
.copyright {
    border-top: 1px solid rgba(255,255,255,.1);
    text-align: center; padding: 20px; font-size: 13px; color: rgba(255,255,255,.4);
    display: flex; flex-wrap: nowrap; justify-content: center; align-items: center; gap: 0 18px;
}
/* 版权、ICP 备案号、公安备案号（含徽标）同排显示且垂直居中 */
.copyright .cp-item { display: inline-flex; align-items: center; white-space: nowrap; line-height: 1.4; font-size: inherit; }
.copyright a { color: inherit; text-decoration: none; }
.copyright a:hover { color: rgba(255,255,255,.75); text-decoration: underline; }
.copyright .beian-icon { height: 20px; width: auto; display: block; margin-right: 6px; flex: none; }
/* 窄屏保持同一行：整体缩小，避免破版换行 */
@media (max-width: 720px) {
    .copyright { gap: 0 10px; font-size: 11px; padding: 16px 10px; }
    .copyright .beian-icon { height: 16px; margin-right: 4px; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-5 { grid-template-columns: repeat(2, 1fr); }
    .contact-wrap, .about-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .footer-biz { padding-left: 0; }
    .footer-addr { white-space: normal; }
    .hero h1 { font-size: 34px; }
    .hero { padding: 80px 0 90px; }
}
@media (max-width: 640px) {
    .grid-2, .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr; }
    .nav {
        display: none; position: absolute; top: 72px; left: 0; right: 0;
        background: var(--white); flex-direction: column; padding: 12px 20px 20px;
        border-bottom: 1px solid var(--line); gap: 4px;
    }
    .nav.open { display: flex; }
    .nav-toggle { display: block; }
    .header-phone { display: none; }
    .logo img { height: 40px; }
    .article { padding: 30px 22px; }
    .contact-form .row { grid-template-columns: 1fr; }
    .about-hero h1 { font-size: 28px; }
    .about-hero { padding: 70px 0 60px; }
    .sub-nav a { padding: 12px 16px; font-size: 14px; }
    .section { padding: 60px 0; }
    .hero h1 { font-size: 28px; }
}
