/* =========================================================
   MERFORGE — style.css
   响应式 · 移动端优先 · 无外部依赖
   ========================================================= */

:root {
  --navy: #0e2a47;
  --steel: #14507f;
  --steel-lt: #1d6ba8;
  --accent: #f59e0b;
  --accent-dk: #d97706;
  --ink: #16202e;
  --muted: #5b6b7c;
  --line: #e3e9ef;
  --bg: #ffffff;
  --bg-alt: #f4f7fa;
  --ok: #16a34a;
  --err: #dc2626;
  --radius: 10px;
  --shadow: 0 2px 14px rgba(14, 42, 71, .08);
  --shadow-lg: 0 10px 34px rgba(14, 42, 71, .13);
  --max: 1160px;
}

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

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
}

img { max-width: 100%; display: block; height: auto; }
a { color: var(--steel); text-decoration: none; }
a:hover { color: var(--accent-dk); }

h1, h2, h3, h4 { line-height: 1.25; color: var(--navy); font-weight: 700; }
h1 { font-size: clamp(1.75rem, 4.6vw, 2.9rem); }
h2 { font-size: clamp(1.45rem, 3.2vw, 2.1rem); }
h3 { font-size: clamp(1.1rem, 2.2vw, 1.3rem); }

p { margin-bottom: 1rem; }
ul { list-style: none; }

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

.section { padding: 64px 0; }
.section--alt { background: var(--bg-alt); }

.section-head { max-width: 720px; margin: 0 auto 40px; text-align: center; }
.section-head p { color: var(--muted); margin-top: .6rem; }

.eyebrow {
  display: inline-block; font-size: .78rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-dk); margin-bottom: .5rem;
}

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: 13px 28px; border-radius: 8px; border: 2px solid transparent;
  font-weight: 700; font-size: .97rem; cursor: pointer;
  transition: transform .15s ease, background .2s ease, color .2s ease, border-color .2s ease;
  text-align: center;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--accent); color: #2b1a00; }
.btn--primary:hover { background: var(--accent-dk); color: #fff; }
.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--steel); color: #fff; }
.btn--ghost { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn--ghost:hover { background: var(--navy); color: #fff; }
.btn--ghost-light { border-color: rgba(255,255,255,.7); color: #fff; background: transparent; }
.btn--ghost-light:hover { background: #fff; color: var(--navy); }
.btn--wa { background: #25d366; color: #06330f; }
.btn--wa:hover { background: #1eb457; color: #fff; }
.btn--block { width: 100%; }

/* ---------------- 顶部导航 ---------------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 8px;
  background: var(--navy); color: var(--accent);
  display: grid; place-items: center;
  font-weight: 800; font-size: 1.15rem; letter-spacing: -.5px;
}
.brand-name { font-size: 1.22rem; font-weight: 800; color: var(--navy); letter-spacing: .3px; }
.brand-name span { color: var(--accent-dk); }
.brand-tag { display: block; font-size: .62rem; font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; color: var(--muted); }

.site-nav ul { display: flex; gap: 4px; }
.site-nav a {
  display: block; padding: 9px 14px; border-radius: 7px;
  font-size: .93rem; font-weight: 600; color: #33465a;
}
.site-nav a:hover { background: var(--bg-alt); color: var(--navy); }
.site-nav a.is-active { color: var(--accent-dk); background: #fff8ec; }
.nav-cta { margin-left: 12px; }
.nav-cta .btn { padding: 9px 20px; font-size: .9rem; }

.nav-toggle {
  display: none; width: 44px; height: 44px; border: none; background: transparent;
  cursor: pointer; position: relative; border-radius: 8px;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; left: 11px; width: 22px; height: 2.4px;
  background: var(--navy); border-radius: 2px; transition: .25s;
}
.nav-toggle span { top: 21px; }
.nav-toggle span::before { left: 0; top: -7px; }
.nav-toggle span::after { left: 0; top: 7px; }
.nav-toggle.is-active span { background: transparent; }
.nav-toggle.is-active span::before { top: 0; transform: rotate(45deg); }
.nav-toggle.is-active span::after { top: 0; transform: rotate(-45deg); }

/* ---------------- 首屏 Hero ---------------- */
.hero {
  position: relative; color: #fff;
  background: linear-gradient(100deg, rgba(9, 26, 45, .93) 0%,
              rgba(12, 38, 64, .82) 45%, rgba(14, 42, 71, .35) 100%),
              url("../img/hero-solar-steel-mounting.jpg") center/cover no-repeat;
  min-height: 560px; display: flex; align-items: center;
}
.hero-inner { padding: 96px 0 110px; max-width: 700px; }
.hero .eyebrow { color: var(--accent); }
.hero h1 { color: #fff; margin-bottom: 1.1rem; }
.hero p { font-size: clamp(1rem, 2vw, 1.16rem); color: #dbe6f1; max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.hero-badges {
  display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 40px;
  font-size: .86rem; color: #c8d6e4; font-weight: 600;
}
.hero-badges span::before { content: "✓"; color: var(--accent); margin-right: 7px; font-weight: 800; }

/* ---------------- 页面顶部标题条 ---------------- */
.page-hero {
  background: linear-gradient(115deg, var(--navy) 0%, var(--steel) 100%);
  color: #fff; padding: 62px 0 58px;
}
.page-hero h1 { color: #fff; font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
.page-hero p { color: #cfdfeb; max-width: 620px; margin-top: .7rem; }
.breadcrumb { font-size: .82rem; color: #a8c0d6; margin-bottom: 1rem; }
.breadcrumb a { color: #cfe0ef; }

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

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); transition: .22s;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-media { aspect-ratio: 16 / 10; overflow: hidden; background: #eef2f6; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin-bottom: .55rem; }
.card-body p { color: var(--muted); font-size: .94rem; flex: 1; }
.card-link {
  margin-top: 16px; font-weight: 700; font-size: .92rem; color: var(--accent-dk);
  display: inline-flex; align-items: center; gap: 6px;
}
.card-link::after { content: "→"; transition: transform .2s; }
.card:hover .card-link::after { transform: translateX(4px); }

/* 优势 */
.feature {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; box-shadow: var(--shadow);
}
.feature-ico {
  width: 46px; height: 46px; border-radius: 10px; margin-bottom: 16px;
  background: #fff8ec; color: var(--accent-dk);
  display: grid; place-items: center; font-size: 1.3rem;
}
.feature h3 { font-size: 1.06rem; margin-bottom: .5rem; }
.feature p { color: var(--muted); font-size: .93rem; margin: 0; }

/* ---------------- 询盘引导条 ---------------- */
.cta-band {
  background: linear-gradient(110deg, var(--navy), var(--steel));
  color: #fff; padding: 58px 0;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: #cfdfeb; margin-bottom: 1.6rem; max-width: 640px; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------------- 表单 ---------------- */
.inquiry-form { display: grid; gap: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: .87rem; font-weight: 700; color: #33465a; }
.field label .opt { font-weight: 500; color: var(--muted); font-size: .8rem; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid #cfd9e2; border-radius: 8px;
  font: inherit; font-size: .95rem; color: var(--ink); background: #fff;
  transition: border-color .18s, box-shadow .18s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--steel); box-shadow: 0 0 0 3px rgba(20, 80, 127, .12);
}
.field textarea { min-height: 120px; resize: vertical; }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; }

.form-message {
  display: none; padding: 14px 16px; border-radius: 8px;
  font-size: .94rem; font-weight: 600;
}
.form-message.is-ok { background: #e8f7ee; color: #10693a; border: 1px solid #b6e6c9; }
.form-message.is-err { background: #fdeaea; color: #a51f1f; border: 1px solid #f3c1c1; }

.form-note { font-size: .84rem; color: var(--muted); }
.form-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px; box-shadow: var(--shadow);
}

/* ---------------- 详情页 ---------------- */
.product-hero { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: start; }
.product-hero-media {
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: #fff; box-shadow: var(--shadow);
}
.product-hero-info .eyebrow { margin-bottom: .7rem; }
.product-hero-info h1 { font-size: clamp(1.5rem, 3.2vw, 2.2rem); margin-bottom: 1rem; }
.lead { color: var(--muted); font-size: 1.03rem; }
.quick-specs {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
  margin: 26px 0; padding: 20px; background: var(--bg-alt); border-radius: var(--radius);
}
.quick-specs div { font-size: .88rem; }
.quick-specs dt { font-weight: 700; color: var(--navy); }
.quick-specs dd { color: var(--muted); margin: 0; }
.product-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

.gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 22px; }
.gallery figure {
  margin: 0; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: #fff;
}
.gallery img { width: 100%; }
.gallery figcaption {
  padding: 9px 12px; font-size: .8rem; color: var(--muted);
  border-top: 1px solid var(--line); background: #fbfcfe;
}

/* 参数表 */
.spec-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table.spec {
  width: 100%; border-collapse: collapse; min-width: 560px; background: #fff;
  font-size: .93rem;
}
table.spec th, table.spec td {
  padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line);
  vertical-align: top;
}
table.spec thead th {
  background: var(--navy); color: #fff; font-size: .86rem;
  letter-spacing: .06em; text-transform: uppercase;
}
table.spec tbody tr:nth-child(even) { background: #f8fafc; }
table.spec tbody th { width: 34%; font-weight: 700; color: var(--navy); }
table.spec tbody tr:last-child th, table.spec tbody tr:last-child td { border-bottom: none; }

/* 通用列表 */
.tick-list li, .dash-list li { position: relative; padding-left: 30px; margin-bottom: 12px; color: #33465a; }
.tick-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  width: 21px; height: 21px; border-radius: 50%;
  background: #e8f7ee; color: var(--ok);
  font-size: .8rem; font-weight: 800; display: grid; place-items: center;
}
.dash-list li::before { content: "—"; position: absolute; left: 0; color: var(--accent-dk); font-weight: 700; }

/* 步骤 / 服务 */
.step { position: relative; padding-left: 54px; }
.step-num {
  position: absolute; left: 0; top: 0; width: 38px; height: 38px; border-radius: 50%;
  background: var(--navy); color: var(--accent); font-weight: 800;
  display: grid; place-items: center;
}

/* ---------------- 页脚 ---------------- */
.site-footer { background: #0a2036; color: #b9c9d8; padding: 56px 0 0; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 34px; padding-bottom: 40px; }
.footer-grid h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; letter-spacing: .04em; }
.footer-grid a, .footer-grid li { color: #b9c9d8; font-size: .91rem; }
.footer-grid li { margin-bottom: 9px; }
.footer-grid a:hover { color: var(--accent); }
.footer-about p { font-size: .91rem; margin-top: 12px; max-width: 300px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0;
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between;
  font-size: .84rem; color: #8ba3b8;
}

/* ---------------- 浮动 WhatsApp ---------------- */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 80;
  width: 58px; height: 58px; border-radius: 50%;
  background: #25d366; color: #fff; display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(0,0,0,.24); transition: transform .18s;
}
.wa-float:hover { transform: scale(1.08); color: #fff; }
.wa-float svg { width: 30px; height: 30px; fill: currentColor; }

/* ---------------- 徽标条 ---------------- */
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat-strip strong { display: block; font-size: clamp(1.5rem, 3vw, 2rem); color: var(--navy); }
.stat-strip span { font-size: .86rem; color: var(--muted); }

/* ===================== 响应式 ===================== */
@media (max-width: 960px) {
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .product-hero { grid-template-columns: 1fr; gap: 30px; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); row-gap: 30px; }
}

@media (max-width: 760px) {
  .section { padding: 46px 0; }
  .nav-toggle { display: block; }

  /* 移动端抽屉导航 */
  .site-nav {
    position: fixed; inset: 68px 0 auto 0; z-index: 55;
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    max-height: 0; overflow: hidden; transition: max-height .28s ease;
  }
  .site-nav.is-open { max-height: 420px; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 8px 16px 18px; }
  .site-nav a { padding: 13px 12px; border-radius: 8px; font-size: 1rem; }
  .site-nav a.is-active { background: #fff8ec; }
  .nav-cta { margin: 10px 12px 0; }
  .nav-cta .btn { width: 100%; }
  body.nav-locked { overflow: hidden; }

  .hero { min-height: 480px; }
  .hero-inner { padding: 70px 0 80px; }

  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .quick-specs { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .cta-actions .btn { width: 100%; }
  .product-actions .btn { width: 100%; }
  .form-card { padding: 22px 18px; }
}

@media (max-width: 420px) {
  body { font-size: 15px; }
  .container { padding: 0 16px; }
  .hero-badges { gap: 8px 18px; font-size: .82rem; }
}

/* ---------------- 品牌 Logo ---------------- */
img.brand-mark { object-fit: cover; }
.page-hero { position: relative; overflow: hidden; }
.page-hero-logo {
  position: absolute; right: max(28px, 4vw); top: 50%;
  transform: translateY(-50%);
  width: min(330px, 30vw); height: auto;
  border-radius: 12px;
  box-shadow: 0 16px 38px rgba(0, 0, 0, .38);
}
@media (max-width: 880px) { .page-hero-logo { display: none; } }
