/* ==========================================================================
   渊联落地页共享样式
   两个站点共用本文件，仅通过 :root 上的 data-theme 区分主色。
   约束：不引用任何外部资源（字体/图片/CDN），确保备案核查时零外链依赖。
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB",
    "Source Han Sans SC", "Noto Sans CJK SC", system-ui, -apple-system,
    "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--brand-2);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--brand-2);
  outline-offset: 3px;
  border-radius: 4px;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

/* ---------- 主题变量 ---------- */

:root {
  --bg: #0a0f1c;
  --panel: #111a2e;
  --panel-2: #16223b;
  --border: rgba(255, 255, 255, 0.09);
  --text: #e8edf7;
  --muted: #93a1bd;
  --brand: #2b6cff;
  --brand-2: #4dc9ff;
  --max: 1160px;
}

/* 消防产品线：暖色调，与边缘云形成区分 */
:root[data-theme="fire"] {
  --brand: #ff5a2b;
  --brand-2: #ffa64d;
}

/* ---------- 通用容器 ---------- */

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

.section {
  padding: 72px 0;
  border-top: 1px solid var(--border);
}

.section-head {
  margin-bottom: 40px;
}

.section-head h2 {
  font-size: 28px;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.section-head p {
  margin-top: 12px;
  color: var(--muted);
  max-width: 760px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  padding: 4px 12px;
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--brand-2);
  background: color-mix(in srgb, var(--brand) 16%, transparent);
  border: 1px solid color-mix(in srgb, var(--brand) 34%, transparent);
  border-radius: 999px;
}

/* ---------- 顶部导航 ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(10, 15, 28, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
}

.brand:hover {
  text-decoration: none;
}

.brand svg {
  flex: none;
  width: 28px;
  height: 28px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 15px;
}

.nav a {
  color: var(--muted);
}

.nav a:hover {
  color: var(--text);
  text-decoration: none;
}

/* ---------- 首屏 ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 88px 0 80px;
}

/* 纯 CSS 网格背景，避免外部图片依赖 */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 40%, transparent 100%);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  top: -180px;
  left: 50%;
  width: 720px;
  height: 460px;
  transform: translateX(-50%);
  background: radial-gradient(
    ellipse at center,
    color-mix(in srgb, var(--brand) 34%, transparent),
    transparent 70%
  );
  filter: blur(20px);
  pointer-events: none;
}

.hero .wrap {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 44px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.hero .subtitle {
  margin-top: 16px;
  font-size: 20px;
  color: var(--brand-2);
}

.hero .lede {
  margin-top: 24px;
  max-width: 780px;
  font-size: 17px;
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 36px;
}

.btn {
  display: inline-block;
  padding: 11px 26px;
  font-size: 15px;
  border-radius: 6px;
  border: 1px solid transparent;
  transition: opacity 0.15s ease, background-color 0.15s ease;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  color: #fff;
  background: var(--brand);
}

.btn-primary:hover {
  opacity: 0.88;
}

.btn-ghost {
  color: var(--text);
  border-color: var(--border);
  background: transparent;
}

.btn-ghost:hover {
  background: var(--panel);
}

/* ---------- 卡片网格 ---------- */

.grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(4, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  padding: 28px 24px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 10px;
}

.card p {
  font-size: 15px;
  color: var(--muted);
}

.card .num {
  display: block;
  margin-bottom: 14px;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--brand-2);
}

/* ---------- 关于 / 联系 ---------- */

.about p + p {
  margin-top: 16px;
}

.about p {
  max-width: 860px;
  color: var(--muted);
}

.contact-list {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 8px;
}

.contact-list div {
  padding: 22px 24px;
  background: var(--panel-2);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.contact-list dt {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 6px;
}

.contact-list dd {
  margin: 0;
  font-size: 16px;
  color: var(--text);
}

/* ---------- 页脚 ---------- */

.site-footer {
  padding: 40px 0 48px;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--muted);
}

.site-footer p + p {
  margin-top: 8px;
}

.site-footer a {
  color: var(--muted);
}

.site-footer a:hover {
  color: var(--text);
}

.beian {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-top: 12px;
}

/* ---------- 响应式 ---------- */

@media (max-width: 960px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-3,
  .contact-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .wrap {
    padding: 0 20px;
  }

  .nav {
    display: none;
  }

  .hero {
    padding: 56px 0 48px;
  }

  .hero h1 {
    font-size: 30px;
  }

  .hero .subtitle {
    font-size: 17px;
  }

  .section {
    padding: 52px 0;
  }

  .section-head h2 {
    font-size: 23px;
  }

  .grid {
    grid-template-columns: 1fr;
  }
}
