/*
Theme Name: 鑫通达远汽修主题 (XTDY Theme)
Theme URI: https://www.xtdyauto.com
Author: Peter Wu
Author URI: https://www.xtdyauto.com
Description: 北京鑫通达远汽车修理厂定制主题，含 SEO/GEO 结构化数据、微信浮动栏、免费百度地图。适配文章发布（汽车维修保养类内容）。
Version: 1.0
License: Private
Text Domain: xtdy
*/

/* ==========================================================
   鑫通达远汽车修理厂 - 全站样式
   主色：车间蓝 #14539A / 强调红 #D93025 / 微信绿 #07C160
   ========================================================== */
:root {
  --blue: #14539A;
  --blue-dark: #0E3C73;
  --blue-light: #E8F0FA;
  --red: #D93025;
  --wechat: #07C160;
  --wechat-dark: #06AD56;
  --text: #222;
  --text-gray: #666;
  --bg: #F7F9FC;
  --white: #fff;
  --radius: 12px;
  --shadow: 0 4px 18px rgba(20, 83, 154, .10);
  --max: 1120px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  padding-bottom: 70px; /* 给底部浮动微信栏留空间 */
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---------- 顶部通栏（电话+微信） ---------- */
.topbar {
  background: var(--blue-dark);
  color: #cfe0f5;
  font-size: 13px;
}
.topbar .container {
  display: flex; justify-content: space-between; align-items: center;
  height: 36px;
}
.topbar a { color: #fff; }
.topbar .wechat-link {
  display: inline-flex; align-items: center; gap: 5px;
  color: #7FE8AC; cursor: pointer;
}

/* ---------- 主导航 ---------- */
.header {
  background: var(--white);
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
  position: sticky; top: 0; z-index: 100;
}
.header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-badge {
  width: 44px; height: 44px; border-radius: 10px;
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  color: #fff; font-weight: 700; font-size: 22px;
  display: flex; align-items: center; justify-content: center;
}
.logo-text { font-size: 20px; font-weight: 700; color: var(--blue-dark); }
.logo-text small { display: block; font-size: 11px; color: var(--text-gray); font-weight: 400; letter-spacing: 1px; }
.nav { display: flex; align-items: center; gap: 6px; }
/* WP 菜单 li 兼容：去掉默认列表样式，让 li 不打断 a 的布局 */
.nav li { list-style: none; display: flex; align-items: center; margin: 0; padding: 0; }
.nav ul { display: flex; align-items: center; gap: 6px; margin: 0; padding: 0; }
.nav a {
  padding: 8px 18px; border-radius: 8px;
  font-size: 16px; font-weight: 500; color: var(--text);
  transition: all .2s;
}
.nav a:hover { background: var(--blue-light); color: var(--blue); }
.nav a.active { background: var(--blue); color: #fff; }
.nav li.current-menu-item > a,
.nav li.current_page_item > a { background: var(--blue); color: #fff; }
.nav .nav-wechat { color: var(--wechat); font-weight: 600; }
.nav .nav-wechat:hover { background: #E8FAF0; color: var(--wechat-dark); }
.nav-toggle { display: none; background: none; border: none; font-size: 26px; color: var(--blue-dark); cursor: pointer; }

/* ---------- 微信图标（内联 SVG 用 currentColor） ---------- */
.wechat-ico { width: 1.15em; height: 1.15em; vertical-align: -0.2em; fill: currentColor; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 460px;
  background: url("images/hero-facade.jpg") center/cover no-repeat;
  display: flex; align-items: center;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(10,40,80,.82) 0%, rgba(10,40,80,.55) 55%, rgba(10,40,80,.25) 100%);
}
.hero .container { position: relative; color: #fff; padding-top: 70px; padding-bottom: 70px; }
.hero h1 { font-size: 40px; line-height: 1.3; margin-bottom: 14px; text-shadow: 0 2px 8px rgba(0,0,0,.3); }
.hero h1 span { color: #6EC1FF; }
.hero p.sub { font-size: 19px; opacity: .95; margin-bottom: 28px; }
.hero .tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.hero .tags span {
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.35);
  padding: 5px 14px; border-radius: 999px; font-size: 14px;
}
.btn {
  display: inline-block; padding: 12px 30px; border-radius: 8px;
  font-size: 16px; font-weight: 600; transition: all .2s;
}
.btn-wechat { background: var(--wechat); color: #fff; }
.btn-wechat:hover { background: var(--wechat-dark); }
.btn-ghost { border: 1.5px solid rgba(255,255,255,.7); color: #fff; margin-left: 12px; }
.btn-ghost:hover { background: rgba(255,255,255,.15); }

/* ---------- 通用区块 ---------- */
.section { padding: 64px 0; }
.section.alt { background: var(--white); }
.section-head { text-align: center; margin-bottom: 44px; }
.section-head h2 { font-size: 30px; color: var(--blue-dark); }
.section-head h2 em { font-style: normal; color: var(--red); }
.section-head p { color: var(--text-gray); margin-top: 8px; }
.section-head .bar {
  width: 52px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--blue), var(--wechat));
  margin: 14px auto 0;
}

/* ---------- 服务卡片 ---------- */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 30px 26px;
  transition: transform .2s;
}
.card:hover { transform: translateY(-4px); }
.card .ico {
  width: 54px; height: 54px; border-radius: 12px;
  background: var(--blue-light); color: var(--blue);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin-bottom: 16px;
}
.card h3 { font-size: 19px; color: var(--blue-dark); margin-bottom: 8px; }
.card p { font-size: 14.5px; color: var(--text-gray); }

/* ---------- 特色服务（底盘） ---------- */
.feature-band { background: linear-gradient(160deg, #0E3C73, #14539A); color: #fff; }
.feature-band .section-head h2 { color: #fff; }
.feature-band .section-head p { color: #B9D4F2; }
.feature-card {
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column;
}
.feature-card img { height: 240px; width: 100%; object-fit: cover; }
.feature-card .fc-body { padding: 26px; flex: 1; }
.feature-card .fc-tag {
  display: inline-block; background: var(--red); color: #fff;
  font-size: 12.5px; padding: 3px 12px; border-radius: 999px; margin-bottom: 12px;
}
.feature-card h3 { font-size: 21px; margin-bottom: 12px; }
.feature-card p { font-size: 15px; color: #D8E6F7; margin-bottom: 8px; }

/* ---------- FAQ ---------- */
.faq-item {
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); margin-bottom: 16px; overflow: hidden;
}
.faq-item summary {
  padding: 18px 22px; cursor: pointer; font-weight: 600;
  font-size: 16.5px; color: var(--blue-dark);
  list-style: none; display: flex; justify-content: space-between; align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 22px; color: var(--wechat); }
.faq-item[open] summary::after { content: "−"; }
.faq-item .faq-a { padding: 0 22px 20px; color: var(--text-gray); font-size: 15px; }

/* ---------- 关于我们 ---------- */
.about-imgs { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; margin-bottom: 36px; }
.about-imgs img { border-radius: var(--radius); height: 300px; width: 100%; object-fit: cover; box-shadow: var(--shadow); }
.about-text p { margin-bottom: 14px; color: #444; }
.point-list li { padding: 6px 0 6px 26px; position: relative; color: #444; }
.point-list li::before {
  content: "✓"; position: absolute; left: 0; color: var(--wechat); font-weight: 700;
}

/* ---------- 联系方式 ---------- */
.contact-wrap { display: grid; grid-template-columns: 1.2fr .8fr; gap: 32px; align-items: start; }
.contact-info { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 34px; }
.contact-info h3 { color: var(--blue-dark); font-size: 20px; margin-bottom: 18px; }
.contact-info li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px dashed #E4EAF2; font-size: 15.5px; }
.contact-info li:last-child { border-bottom: none; }
.contact-info .ci-ico { color: var(--blue); font-size: 18px; }
.qr-card {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 30px; text-align: center;
}
.qr-card img { width: 240px; margin: 0 auto 14px; border-radius: 8px; }
.qr-card h4 { color: var(--wechat-dark); font-size: 17px; }
.qr-card p { font-size: 13.5px; color: var(--text-gray); }

/* ---------- 页脚 ---------- */
.footer { background: #0E2A4E; color: #B7C8DE; padding: 48px 0 0; font-size: 14px; }
.footer .container { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 32px; padding-bottom: 34px; }
.footer h4 { color: #fff; font-size: 16px; margin-bottom: 14px; }
.footer a:hover { color: #fff; }
.footer .footer-wechat { color: #7FE8AC; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.footer-wechat img { width: 110px; border-radius: 6px; margin-top: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  text-align: center; padding: 16px 0; font-size: 13px; color: #8FA5C2;
}

/* ---------- 浮动微信栏（底部） ---------- */
.float-wechat {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 200;
  background: var(--wechat); color: #fff;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  height: 56px; font-size: 16.5px; font-weight: 600;
  cursor: pointer; box-shadow: 0 -3px 14px rgba(7,193,96,.35);
  transition: background .2s;
}
.float-wechat:hover { background: var(--wechat-dark); }
.float-wechat .wechat-ico { width: 26px; height: 26px; }

/* ---------- 微信二维码弹窗 ---------- */
.qr-modal {
  display: none; position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,.55);
  align-items: center; justify-content: center;
}
.qr-modal.open { display: flex; }
.qr-modal .qr-box {
  background: #fff; border-radius: 14px; padding: 34px 38px;
  text-align: center; position: relative; max-width: 90vw;
}
.qr-modal img { width: 280px; margin: 18px auto 10px; }
.qr-modal h3 { color: var(--wechat-dark); }
.qr-modal p { color: var(--text-gray); font-size: 14px; }
.qr-modal .close {
  position: absolute; top: 10px; right: 16px; font-size: 26px;
  color: #999; cursor: pointer; line-height: 1;
}

/* ---------- 移动端 ---------- */
@media (max-width: 860px) {
  .nav {
    display: none; position: absolute; top: 68px; left: 0; right: 0;
    background: #fff; flex-direction: column; padding: 12px 20px 18px;
    box-shadow: 0 8px 16px rgba(0,0,0,.1);
  }
  .nav.open { display: flex; }
  .nav ul { flex-direction: column; align-items: stretch; gap: 0; width: 100%; }
  .nav li { display: block; width: 100%; }
  .nav a { width: 100%; padding: 12px 10px; }
  .nav-toggle { display: block; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .about-imgs { grid-template-columns: 1fr; }
  .contact-wrap { grid-template-columns: 1fr; }
  .footer .container { grid-template-columns: 1fr; }
  .hero h1 { font-size: 28px; }
  .hero .container { padding-top: 48px; padding-bottom: 48px; }
  .section { padding: 44px 0; }
  .topbar .hours { display: none; }
}
