/* 道县沐知咨询服务有限公司 官网样式 */
:root {
  --primary: #1257a5;
  --primary-dark: #0d3f79;
  --primary-light: #e8f1fb;
  --accent: #e0a33e;
  --accent-dark: #c98b23;
  --text: #1f2937;
  --text-light: #6b7280;
  --border: #e5e7eb;
  --bg: #ffffff;
  --bg-soft: #f6f8fb;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(16, 45, 84, .08);
  --shadow-lg: 0 18px 45px rgba(16, 45, 84, .14);
  --maxw: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  font-size: 15px;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; cursor: pointer; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--text-light); }
.hide { display: none !important; }

/* ---------- 顶部 ---------- */
.topbar {
  background: var(--primary-dark);
  color: #cfe0f3;
  font-size: 13px;
}
.topbar .container {
  display: flex; justify-content: space-between; align-items: center; height: 38px; gap: 16px;
}
.topbar a:hover { color: #fff; }
.topbar span + span { margin-left: 18px; }

.header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header .container { display: flex; align-items: center; height: 74px; gap: 24px; }
.logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.logo-mark {
  width: 44px; height: 44px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), #2f8fd8);
  color: #fff; display: grid; place-items: center;
  font-size: 18px; font-weight: 700; letter-spacing: 1px;
  box-shadow: 0 6px 16px rgba(18, 87, 165, .28);
}
.logo-text b { display: block; font-size: 18px; letter-spacing: .5px; color: var(--primary-dark); }
.logo-text span { display: block; font-size: 11px; color: var(--text-light); letter-spacing: 2px; }

.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a {
  padding: 8px 14px; border-radius: 8px; font-size: 15px; color: var(--text);
  position: relative; transition: .2s; white-space: nowrap;
}
.nav a:hover { color: var(--primary); background: var(--primary-light); }
.nav a.active { color: var(--primary); font-weight: 600; }
.nav a.active::after {
  content: ''; position: absolute; left: 14px; right: 14px; bottom: 2px; height: 2px;
  background: var(--accent); border-radius: 2px;
}
.header-cta { display: flex; align-items: center; gap: 10px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 22px; border-radius: 8px; border: 1px solid transparent;
  font-size: 15px; transition: .2s; background: var(--primary); color: #fff;
}
.btn:hover { background: var(--primary-dark); transform: translateY(-1px); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-dark); }
.btn-ghost { background: transparent; border-color: var(--primary); color: var(--primary); }
.btn-ghost:hover { background: var(--primary); color: #fff; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.menu-toggle { display: none; margin-left: auto; background: none; border: none; font-size: 22px; }

/* ---------- 横幅 ---------- */
.hero {
  position: relative; min-height: 480px; display: grid; place-items: center;
  background: linear-gradient(135deg, #0d3f79 0%, #1257a5 55%, #2f8fd8 100%);
  color: #fff; overflow: hidden; text-align: center;
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(1000px 320px at 20% 10%, rgba(224, 163, 62, .28), transparent 60%),
              radial-gradient(700px 300px at 85% 80%, rgba(255, 255, 255, .12), transparent 60%);
}
.hero-inner { position: relative; z-index: 2; padding: 90px 20px 100px; max-width: 900px; }
.hero-tag {
  display: inline-block; padding: 5px 16px; border-radius: 999px; font-size: 13px;
  background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .3); margin-bottom: 22px;
}
.hero h1 { font-size: 44px; margin: 0 0 18px; font-weight: 700; letter-spacing: 1px; line-height: 1.3; }
.hero p { font-size: 18px; opacity: .92; margin: 0 0 32px; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero .btn { padding: 13px 32px; font-size: 16px; }
.hero .btn-outline { background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .55); }
.hero .btn-outline:hover { background: #fff; color: var(--primary-dark); }
.hero-dots { position: absolute; bottom: 26px; left: 0; right: 0; z-index: 3; display: flex; gap: 8px; justify-content: center; }
.hero-dots i { width: 26px; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .4); cursor: pointer; }
.hero-dots i.on { background: var(--accent); }

/* ---------- 通用区块 ---------- */
.section { padding: 72px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { text-align: center; margin-bottom: 44px; }
.section-head h2 { font-size: 30px; margin: 0 0 12px; color: var(--primary-dark); position: relative; }
.section-head h2::after {
  content: ''; display: block; width: 52px; height: 3px; background: var(--accent);
  margin: 14px auto 0; border-radius: 2px;
}
.section-head p { color: var(--text-light); margin: 0; }
.section-head.left { text-align: left; }
.section-head.left h2::after { margin-left: 0; }

/* 统计条 */
.stats { background: var(--primary-dark); color: #fff; padding: 34px 0; }
.stats .container { display: grid; grid-template-columns: repeat(4, 1fr); text-align: center; gap: 20px; }
.stat b { display: block; font-size: 30px; color: var(--accent); }
.stat span { font-size: 14px; opacity: .85; }

/* 服务卡片 */
.tabs { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 30px; }
.tab {
  padding: 8px 20px; border-radius: 999px; border: 1px solid var(--border);
  background: #fff; color: var(--text-light); font-size: 14px; transition: .2s;
}
.tab.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 24px; transition: .25s; position: relative; overflow: hidden;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #cfe0f3; }
.card .ico {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  background: var(--primary-light); color: var(--primary); font-size: 22px; margin-bottom: 16px;
}
.card h3 { margin: 0 0 10px; font-size: 17px; color: var(--primary-dark); }
.card p { margin: 0; color: var(--text-light); font-size: 14px; }
.card .more { display: inline-block; margin-top: 14px; color: var(--primary); font-size: 14px; }

/* 关于 */
.about-wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 46px; align-items: center; }
.about-text p { color: #4b5563; white-space: pre-wrap; }
.about-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.mini-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow);
}
.mini-card b { display: block; color: var(--primary-dark); margin-bottom: 6px; }
.mini-card span { color: var(--text-light); font-size: 14px; }

/* 流程 */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.step { text-align: center; padding: 26px 18px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); }
.step i {
  width: 46px; height: 46px; border-radius: 50%; background: var(--primary); color: #fff;
  display: grid; place-items: center; margin: 0 auto 14px; font-style: normal; font-weight: 700;
}
.step b { display: block; margin-bottom: 6px; }
.step span { color: var(--text-light); font-size: 14px; }

/* 新闻 / 案例 */
.news-item {
  display: grid; grid-template-columns: 120px 1fr; gap: 22px; align-items: center;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; transition: .25s;
}
.news-item:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.news-date {
  text-align: center; background: var(--primary-light); border-radius: 10px; padding: 12px 6px; color: var(--primary-dark);
}
.news-date b { display: block; font-size: 26px; line-height: 1.1; }
.news-date span { font-size: 12px; }
.news-item h3 { margin: 0 0 8px; font-size: 18px; }
.news-item p { margin: 0; color: var(--text-light); font-size: 14px; }
.meta { font-size: 13px; color: #9ca3af; margin-top: 8px; }

.case-card { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: #fff; transition: .25s; }
.case-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.case-cover { height: 150px; background: linear-gradient(135deg, var(--primary), #2f8fd8); display: grid; place-items: center; color: #fff; font-size: 20px; }
.case-body { padding: 18px 20px; }
.case-body h3 { margin: 0 0 8px; font-size: 17px; color: var(--primary-dark); }
.case-body p { margin: 0; font-size: 14px; color: var(--text-light); }

/* 联系表单 */
.contact-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.info-list li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px dashed var(--border); }
.info-list b { color: var(--primary-dark); min-width: 72px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; font-size: 14px; color: #374151; }
.form-group label i { color: #e0533d; font-style: normal; }
.form-control {
  width: 100%; padding: 11px 14px; border: 1px solid var(--border); border-radius: 8px;
  font-size: 15px; font-family: inherit; transition: .2s; background: #fff;
}
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(18, 87, 165, .1); }
textarea.form-control { min-height: 120px; resize: vertical; }

/* 页面头图 */
.page-hero {
  background: linear-gradient(135deg, #0d3f79, #1257a5); color: #fff; padding: 62px 0 56px; text-align: center;
}
.page-hero h1 { margin: 0 0 10px; font-size: 34px; }
.page-hero p { margin: 0; opacity: .85; }
.breadcrumb { padding: 14px 0; background: var(--bg-soft); font-size: 13px; color: var(--text-light); border-bottom: 1px solid var(--border); }
.breadcrumb a:hover { color: var(--primary); }

/* 分页 */
.pager { display: flex; justify-content: center; gap: 8px; margin-top: 34px; }
.pager button { border: 1px solid var(--border); background: #fff; padding: 7px 14px; border-radius: 8px; }
.pager button.on { background: var(--primary); color: #fff; border-color: var(--primary); }

/* CTA */
.cta-band { background: linear-gradient(120deg, var(--primary-dark), var(--primary)); color: #fff; padding: 54px 0; text-align: center; }
.cta-band h2 { margin: 0 0 10px; }
.cta-band p { margin: 0 0 24px; opacity: .9; }

/* 页脚 */
.footer { background: #0b2440; color: #b9c9dc; padding-top: 52px; font-size: 14px; }
.footer .container { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 34px; padding-bottom: 34px; }
.footer h4 { color: #fff; font-size: 16px; margin: 0 0 16px; }
.footer li { padding: 5px 0; }
.footer a:hover { color: var(--accent); }
.footer .logo-mark { background: linear-gradient(135deg, var(--accent), #f0c274); }
.footer .logo-text b { color: #fff; }
.footer .logo-text span { color: #8ba5c2; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 16px 0; text-align: center; font-size: 13px; color: #7f96b0; }

/* ---------- 客服悬浮组件 ---------- */
.cs-float { position: fixed; right: 22px; bottom: 26px; z-index: 200; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.cs-btn {
  width: 58px; height: 58px; border-radius: 50%; border: none;
  background: linear-gradient(135deg, var(--primary), #2f8fd8); color: #fff;
  box-shadow: 0 10px 26px rgba(18, 87, 165, .38); font-size: 24px;
  display: grid; place-items: center; transition: .25s; position: relative;
}
.cs-btn:hover { transform: scale(1.06); }
.cs-btn .dot {
  position: absolute; top: 6px; right: 6px; width: 10px; height: 10px; border-radius: 50%;
  background: #43d17c; border: 2px solid #fff;
}
.cs-btn .dot.off { background: #b9c2cc; }
.cs-quick {
  display: flex; flex-direction: column; gap: 8px; align-items: flex-end;
}
.cs-quick span {
  background: #fff; border: 1px solid var(--border); box-shadow: var(--shadow);
  padding: 8px 14px; border-radius: 999px; font-size: 13px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
}
.cs-quick span:hover { color: var(--primary); border-color: var(--primary); }
.cs-panel {
  position: fixed; right: 22px; bottom: 96px; width: 340px; max-width: calc(100vw - 32px);
  background: #fff; border-radius: 14px; box-shadow: var(--shadow-lg); z-index: 201;
  display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border);
}
.cs-panel-head {
  background: linear-gradient(120deg, var(--primary-dark), var(--primary)); color: #fff;
  padding: 14px 16px; display: flex; align-items: center; justify-content: space-between;
}
.cs-panel-head b { font-size: 15px; }
.cs-panel-head small { display: block; font-weight: 400; opacity: .8; font-size: 12px; }
.cs-close { background: none; border: none; color: #fff; font-size: 20px; line-height: 1; }
.cs-body { height: 300px; overflow-y: auto; padding: 14px; background: #f7f9fc; }
.cs-msg { display: flex; margin-bottom: 12px; gap: 8px; }
.cs-msg .avatar {
  width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0; display: grid; place-items: center;
  font-size: 12px; color: #fff; background: var(--primary);
}
.cs-msg.visitor { flex-direction: row-reverse; }
.cs-msg.visitor .avatar { background: var(--accent); }
.cs-msg .bubble {
  background: #fff; padding: 9px 13px; border-radius: 10px; font-size: 14px; max-width: 76%;
  box-shadow: 0 2px 8px rgba(16, 45, 84, .07); word-break: break-word; white-space: pre-wrap;
}
.cs-msg.visitor .bubble { background: var(--primary); color: #fff; }
.cs-msg .time { display: block; font-size: 11px; color: #9ca3af; margin-top: 4px; }
.cs-panel-foot { border-top: 1px solid var(--border); padding: 10px; display: flex; gap: 8px; background: #fff; }
.cs-panel-foot input {
  flex: 1; border: 1px solid var(--border); border-radius: 8px; padding: 9px 12px; font-size: 14px; font-family: inherit;
}
.cs-panel-foot input:focus { outline: none; border-color: var(--primary); }
.cs-panel-foot button { border: none; background: var(--primary); color: #fff; border-radius: 8px; padding: 0 16px; }
.cs-qrcode { text-align: center; padding: 8px 0 12px; }
.cs-qrcode img { width: 140px; height: 140px; object-fit: cover; border: 1px solid var(--border); border-radius: 8px; margin: 0 auto 6px; }

/* Toast */
.toast-wrap { position: fixed; top: 24px; left: 50%; transform: translateX(-50%); z-index: 999; display: flex; flex-direction: column; gap: 10px; }
.toast {
  background: #fff; border-left: 4px solid var(--primary); box-shadow: var(--shadow-lg);
  padding: 12px 22px; border-radius: 8px; font-size: 14px; animation: slideDown .25s ease;
}
.toast.ok { border-color: #22c55e; }
.toast.err { border-color: #ef4444; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }

/* 空状态 */
.empty { text-align: center; padding: 50px 20px; color: var(--text-light); }

/* 文章正文 */
.article { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 36px; }
.article h1 { margin: 0 0 10px; font-size: 28px; color: var(--primary-dark); }
.article .content { white-space: pre-wrap; color: #374151; margin-top: 20px; }
.article .tools { display: flex; justify-content: space-between; margin-top: 30px; padding-top: 18px; border-top: 1px solid var(--border); font-size: 14px; }

/* ---------- 响应式 ---------- */
@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .about-wrap, .contact-wrap { grid-template-columns: 1fr; gap: 28px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .footer .container { grid-template-columns: repeat(2, 1fr); }
  .stats .container { grid-template-columns: repeat(2, 1fr); gap: 26px 10px; }
}
@media (max-width: 768px) {
  .nav {
    display: none; position: absolute; top: 74px; left: 0; right: 0; flex-direction: column;
    background: #fff; padding: 10px 16px 18px; box-shadow: var(--shadow); border-top: 1px solid var(--border);
  }
  .nav.open { display: flex; }
  .menu-toggle { display: block; }
  .header-cta { display: none; }
  .hero h1 { font-size: 28px; }
  .hero p { font-size: 15px; }
  .grid-3, .grid-4, .grid-2, .steps { grid-template-columns: 1fr; }
  .section { padding: 48px 0; }
  .form-row { grid-template-columns: 1fr; }
  .news-item { grid-template-columns: 1fr; text-align: left; }
  .news-date { display: flex; gap: 8px; align-items: baseline; justify-content: center; width: 110px; }
  .cs-panel { right: 8px; left: 8px; width: auto; bottom: 88px; }
  .topbar .container { font-size: 12px; height: auto; padding: 6px 20px; flex-wrap: wrap; }
}
