/* ==========================================================================
   智驱科技 · ZhiDrive — 无刷直流电机控制器企业官网
   设计系统 / Design System
   ========================================================================== */

:root {
  --primary: #1677ff;
  --primary-600: #0e5fd8;
  --primary-700: #0a4bb0;
  --cyan: #06b6d4;
  --teal: #14b8a6;
  --navy: #0b1e3a;
  --navy-800: #10294d;
  --ink: #1f2d3d;
  --muted: #6b7280;
  --line: #e6e9ef;
  --bg: #f5f7fa;
  --card: #ffffff;
  --green: #10b981;
  --amber: #f59e0b;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 3px rgba(15, 23, 42, .08);
  --shadow-md: 0 6px 20px rgba(15, 23, 42, .10);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, .16);
  --font: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Segoe UI", system-ui, -apple-system, sans-serif;
}

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

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

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

.container { width: min(1180px, 92%); margin: 0 auto; }

.section { padding: 84px 0; }
.section--alt { background: #fff; }
.section--navy { background: var(--navy); color: #cbd5e1; }

/* ---------- Section header ---------- */
.sec-head { max-width: 720px; margin: 0 auto 52px; text-align: center; }
.sec-head.left { text-align: left; margin-left: 0; }
.sec-kicker {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; letter-spacing: .16em;
  color: var(--primary); text-transform: uppercase;
}
.sec-kicker::before { content: ""; width: 22px; height: 2px; background: var(--primary); border-radius: 2px; }
.sec-head.left .sec-kicker::before { display: none; }
.sec-title { font-size: clamp(26px, 3.6vw, 38px); font-weight: 800; color: var(--navy); line-height: 1.25; margin-top: 12px; }
.sec-desc { margin-top: 16px; color: var(--muted); font-size: 16.5px; }
.section--navy .sec-title { color: #fff; }
.section--navy .sec-desc { color: #94a3b8; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 26px; border-radius: 9px; font-size: 15.5px; font-weight: 600;
  border: 1px solid transparent; cursor: pointer; transition: all .22s ease;
  white-space: nowrap;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 8px 20px rgba(22, 119, 255, .28); }
.btn--primary:hover { background: var(--primary-600); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn--ghost:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }
.btn--outline { background: #fff; color: var(--primary); border-color: var(--primary); }
.btn--outline:hover { background: var(--primary); color: #fff; }
.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--navy-800); }

/* ---------- Navbar ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  transition: background .3s ease, box-shadow .3s ease, padding .3s ease;
  padding: 20px 0; background: transparent;
}
.nav.scrolled { background: rgba(11, 30, 58, .96); box-shadow: 0 4px 24px rgba(0,0,0,.28); padding: 12px 0; backdrop-filter: blur(8px); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; color: #fff; }
.brand__logo { width: 40px; height: 40px; flex: none; }
.brand__name { font-size: 20px; font-weight: 800; letter-spacing: .02em; }
.brand__name small { display: block; font-size: 10.5px; font-weight: 500; letter-spacing: .2em; color: #93c5fd; text-transform: uppercase; }
.nav__links { display: flex; align-items: center; gap: 6px; }
.nav__links a {
  color: #dbe7f6; font-size: 15px; font-weight: 500; padding: 9px 14px; border-radius: 8px; transition: all .2s;
}
.nav__links a:hover { color: #fff; background: rgba(255, 255, 255, .1); }
.nav__links a.active { color: #fff; background: var(--primary); }
.nav__cta { display: inline-flex; }
.nav__toggle { display: none; background: none; border: 0; cursor: pointer; color: #fff; width: 44px; height: 44px; }
.nav__toggle svg { width: 26px; height: 26px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  background: radial-gradient(1200px 600px at 80% -10%, rgba(6,182,212,.28), transparent 60%),
              radial-gradient(900px 500px at -10% 110%, rgba(22,119,255,.35), transparent 55%),
              linear-gradient(135deg, #08152c 0%, #0b1e3a 45%, #0d2a52 100%);
  color: #fff; overflow: hidden; padding: 140px 0 90px;
}
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: .5; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 26px 26px;
}
.hero__grid { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; }
.hero__badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 15px; border-radius: 999px;
  background: rgba(22,119,255,.15); border: 1px solid rgba(22,119,255,.4); color: #bcd7ff; font-size: 13.5px; font-weight: 600;
}
.hero__badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 4px rgba(6,182,212,.25); }
.hero h1 { font-size: clamp(34px, 5.2vw, 58px); font-weight: 900; line-height: 1.12; margin: 22px 0 18px; letter-spacing: -.01em; }
.hero h1 .grad { background: linear-gradient(90deg, #4cc9ff, #06b6d4); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__lead { font-size: 18px; color: #b7c7de; max-width: 560px; }
.hero__actions { display: flex; gap: 16px; margin-top: 34px; flex-wrap: wrap; }
.hero__stats { display: flex; gap: 42px; margin-top: 48px; flex-wrap: wrap; }
.hero__stat .num { font-size: 34px; font-weight: 800; color: #fff; }
.hero__stat .num span { color: var(--cyan); }
.hero__stat .lbl { font-size: 13.5px; color: #8aa3c2; margin-top: 2px; }
.hero__visual { position: relative; }
.hero__visual img { width: 100%; border-radius: 18px; box-shadow: var(--shadow-lg); border: 1px solid rgba(255,255,255,.12); }
.hero__chip {
  position: absolute; padding: 14px 18px; border-radius: 12px; background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.16); backdrop-filter: blur(8px); box-shadow: var(--shadow-lg); font-size: 13.5px;
}
.hero__chip b { display: block; font-size: 22px; }
.hero__chip--a { top: -18px; right: -10px; }
.hero__chip--b { bottom: -16px; left: -12px; }

/* ---------- Feature cards ---------- */
.grid { display: grid; gap: 24px; }
.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: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 28px; box-shadow: var(--shadow-sm); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  position: relative; overflow: hidden;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: #cfe0ff; }
.card__icon {
  width: 58px; height: 58px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 20px;
  background: linear-gradient(135deg, #e8f1ff, #d6e7ff); color: var(--primary);
}
.card__icon svg { width: 30px; height: 30px; }
.card h3 { font-size: 19px; font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.card p { color: var(--muted); font-size: 15px; }

/* ---------- Product cards ---------- */
.product-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform .25s, box-shadow .25s;
}
.product-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.product-card__img { background: #0f2747; aspect-ratio: 4/3; overflow: hidden; position: relative; }
.product-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-card__img img { transform: scale(1.05); }
.product-card__tag {
  position: absolute; top: 14px; left: 14px; padding: 5px 12px; border-radius: 999px;
  background: rgba(22,119,255,.92); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .04em;
}
.product-card__body { padding: 22px 24px 24px; }
.product-card__body h3 { font-size: 18.5px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.product-card__body p { color: var(--muted); font-size: 14.5px; }
.product-card__specs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.product-card__specs span {
  font-size: 12.5px; padding: 5px 11px; border-radius: 7px; background: #f1f5fb; color: #45618b; font-weight: 600;
}
.product-card__link { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; color: var(--primary); font-weight: 600; font-size: 14.5px; }
.product-card__link:hover { gap: 10px; }

/* ---------- Split / feature rows ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split__img img { border-radius: 16px; box-shadow: var(--shadow-md); }
.split h3 { font-size: 26px; font-weight: 800; color: var(--navy); margin-bottom: 16px; }
.split p { color: var(--muted); margin-bottom: 14px; }
.checklist { display: grid; gap: 12px; margin-top: 22px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; color: #33455e; }
.checklist li svg { width: 22px; height: 22px; flex: none; color: var(--green); margin-top: 2px; }

/* ---------- Stats band ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.stat-box { padding: 30px 16px; border-radius: var(--radius); background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); }
.stat-box .num { font-size: 42px; font-weight: 800; color: #fff; line-height: 1; }
.stat-box .num span { color: var(--cyan); font-size: 26px; }
.stat-box .lbl { margin-top: 10px; color: #8aa3c2; font-size: 14.5px; }

/* ---------- Steps / timeline ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: step; }
.step { position: relative; padding: 26px 22px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: -16px; left: 22px; width: 34px; height: 34px; border-radius: 10px;
  background: var(--primary); color: #fff; font-weight: 800; display: grid; place-items: center; font-size: 16px;
}
.step h4 { font-size: 17px; font-weight: 700; color: var(--navy); margin: 10px 0 8px; }
.step p { color: var(--muted); font-size: 14.5px; }

/* ---------- News ---------- */
.news-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); transition: .25s; }
.news-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.news-card__date { padding: 16px 22px 0; font-size: 13px; color: var(--primary); font-weight: 600; }
.news-card h4 { padding: 6px 22px 14px; font-size: 16.5px; font-weight: 700; color: var(--navy); line-height: 1.5; }
.news-card p { padding: 0 22px 22px; color: var(--muted); font-size: 14.5px; }

/* ---------- Breadcrumb / page hero ---------- */
.page-hero { background: linear-gradient(135deg, #08152c, #0d2a52); color: #fff; padding: 150px 0 70px; position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; opacity: .4; background-image: radial-gradient(rgba(255,255,255,.06) 1px, transparent 1px); background-size: 24px 24px; }
.page-hero .container { position: relative; }
.page-hero h1 { font-size: clamp(30px, 4.5vw, 46px); font-weight: 900; }
.page-hero p { color: #b7c7de; max-width: 640px; margin-top: 14px; font-size: 17px; }
.breadcrumb { display: flex; gap: 8px; color: #8aa3c2; font-size: 13.5px; margin-bottom: 18px; }
.breadcrumb a:hover { color: #fff; }

/* ---------- Filter pills ---------- */
.pills { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 44px; }
.pill {
  padding: 9px 20px; border-radius: 999px; border: 1px solid var(--line); background: #fff; cursor: pointer;
  font-size: 14.5px; font-weight: 600; color: #45618b; transition: .2s;
}
.pill:hover { border-color: var(--primary); color: var(--primary); }
.pill.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; }
.contact-info { display: grid; gap: 16px; }
.contact-item { display: flex; gap: 16px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-sm); }
.contact-item__icon { width: 48px; height: 48px; border-radius: 12px; background: linear-gradient(135deg,#e8f1ff,#d6e7ff); color: var(--primary); display: grid; place-items: center; flex: none; }
.contact-item__icon svg { width: 24px; height: 24px; }
.contact-item h4 { font-size: 16px; font-weight: 700; color: var(--navy); }
.contact-item p { color: var(--muted); font-size: 14.5px; }
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 34px; box-shadow: var(--shadow-md); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 14px; font-weight: 600; color: var(--navy); margin-bottom: 7px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 9px; font-size: 15px; font-family: inherit;
  background: #fafbfd; transition: .2s; color: var(--ink);
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--primary); background: #fff; box-shadow: 0 0 0 3px rgba(22,119,255,.14); }
.map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); background: linear-gradient(135deg,#eef2f7,#dbe6f4); min-height: 280px; display: grid; place-items: center; color: var(--muted); font-size: 14px; }

/* ---------- Footer ---------- */
.footer { background: #08152c; color: #9fb3cd; padding: 70px 0 30px; font-size: 14.5px; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; }
.footer h5 { color: #fff; font-size: 15px; font-weight: 700; margin-bottom: 18px; }
.footer .brand { color: #fff; margin-bottom: 16px; }
.footer p { line-height: 1.8; }
.footer a { display: block; padding: 4px 0; color: #9fb3cd; transition: .2s; }
.footer a:hover { color: #fff; transform: translateX(3px); }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.08); margin-top: 48px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; color: #7b90ad; }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed; right: 26px; bottom: 26px; width: 48px; height: 48px; border-radius: 12px; border: 0; cursor: pointer;
  background: var(--primary); color: #fff; box-shadow: var(--shadow-md); display: grid; place-items: center;
  opacity: 0; visibility: hidden; transition: .3s; z-index: 900;
}
.to-top.show { opacity: 1; visibility: visible; }
.to-top:hover { background: var(--primary-600); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid--4, .steps { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .hero__grid, .split, .contact-grid { grid-template-columns: 1fr; }
  .hero__visual { order: -1; }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .nav__links {
    position: fixed; top: 0; right: -280px; height: 100vh; width: 280px; flex-direction: column;
    background: #0b1e3a; padding: 90px 24px 30px; gap: 6px; transition: right .3s ease; align-items: stretch;
  }
  .nav__links.open { right: 0; }
  .nav__links a { padding: 14px 16px; }
  .nav__cta { display: none; }
  .nav__toggle { display: block; z-index: 1001; }
}
@media (max-width: 600px) {
  .section { padding: 60px 0; }
  .grid--2, .grid--3, .grid--4, .steps, .stats { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero__stats { gap: 26px; }
  .footer__grid { grid-template-columns: 1fr; }
  .hero__chip--a { right: 0; }
  .hero__chip--b { left: 0; }
}
