/* =========================================================
   东海县和创硅材料有限公司 — 官网样式
   ========================================================= */

:root {
  --brand: #0d5c7e;
  --brand-dark: #083f57;
  --brand-light: #e8f1f6;
  --accent: #f5821f;
  --accent-dark: #d96a0b;
  --ink: #12232e;
  --text: #2b3a44;
  --muted: #6a7b86;
  --bg: #f5f7f9;
  --card: #ffffff;
  --line: #e2e8ed;
  --ok: #1f8a54;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 2px 10px rgba(18, 35, 46, .06);
  --shadow-lg: 0 8px 28px rgba(18, 35, 46, .12);
  --maxw: 1200px;
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.8;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--accent-dark); }

h1, h2, h3, h4 { color: var(--ink); line-height: 1.35; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: 2.4rem; }
h2 { font-size: 1.9rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }
p { margin: 0 0 1.1em; }

ul { padding-left: 1.2em; }
li { margin-bottom: .45em; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- 顶部工具条 ---------- */
.topbar {
  background: var(--ink);
  color: #cfdae2;
  font-size: 13px;
}
.topbar .wrap {
  display: flex; gap: 22px; flex-wrap: wrap; align-items: center;
  min-height: 38px; justify-content: flex-end;
}
.topbar a { color: #cfdae2; }
.topbar a:hover { color: #fff; }
.topbar .tag { margin-right: auto; color: #8fa3b0; letter-spacing: .02em; }

/* ---------- 导航 ---------- */
.nav {
  background: #fff;
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
  box-shadow: 0 1px 4px rgba(18,35,46,.04);
}
.nav .wrap { display: flex; align-items: center; gap: 18px; min-height: 72px; }
.logo { display: flex; align-items: center; gap: 12px; flex: none; }
.logo svg { width: 42px; height: 42px; }
.logo .cn { font-size: 20px; font-weight: 800; color: var(--ink); letter-spacing: .04em; line-height: 1.1; }
.logo .en { display: block; font-size: 11px; color: var(--muted); letter-spacing: .06em; font-weight: 500; }

.nav ul.menu { display: flex; list-style: none; margin: 0 0 0 auto; padding: 0; gap: 4px; flex-wrap: wrap; }
.nav ul.menu li { margin: 0; }
.nav ul.menu a {
  display: block; padding: 8px 13px; border-radius: 6px;
  color: var(--text); font-size: 15px; font-weight: 500;
}
.nav ul.menu a:hover { background: var(--brand-light); color: var(--brand); }
.nav ul.menu a.active { color: var(--brand); background: var(--brand-light); font-weight: 700; }
.nav .cta {
  background: var(--accent); color: #fff; padding: 9px 18px; border-radius: 6px;
  font-weight: 700; font-size: 14px; white-space: nowrap;
}
.nav .cta:hover { background: var(--accent-dark); color: #fff; }

.navtoggle { display: none; background: none; border: 0; font-size: 26px; cursor: pointer; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; color: #fff;
  background-color: #0d5c7e;
  background-image: linear-gradient(135deg, #083f57 0%, #0d5c7e 60%, #10718f 100%);
  overflow: hidden;
  min-height: 620px;
}
/* 有背景图时：整幅铺满、居中，不裁掉主体 */
.hero.hasimg {
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
}
/* 背景图铺满整个 hero，可点击放大（灯箱会自动接管） */
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 45%;
  filter: brightness(.82) saturate(1.04);
}
/* 无图或图未加载时的兜底底色 */
.hero.hasimg::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(135deg, #083f57 0%, #0d5c7e 60%, #10718f 100%);
}
/* 左侧文字区深、右侧放开露出车间全景 */
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg,
    rgba(8,50,70,.95) 0%,
    rgba(8,50,70,.86) 30%,
    rgba(8,50,70,.55) 55%,
    rgba(8,50,70,.26) 80%,
    rgba(8,50,70,.18) 100%);
}
.hero .wrap { position: relative; z-index: 2; padding-top: 76px; padding-bottom: 76px; }
.hero h1 { color: #fff; font-size: 2.7rem; margin-bottom: .4em; max-width: 20em; }
.hero .lead { font-size: 1.12rem; color: #d8e6ee; max-width: 44em; margin-bottom: 1.6em; }
.hero .eyebrow {
  display: inline-block; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.3);
  color: #fff; padding: 4px 14px; border-radius: 100px; font-size: 13px; margin-bottom: 18px; letter-spacing: .05em;
}
.btn {
  display: inline-block; background: var(--accent); color: #fff;
  padding: 13px 26px; border-radius: 6px; font-weight: 700;
}
.btn:hover { background: var(--accent-dark); color: #fff; }
.btn.ghost {
  background: transparent; border: 1.5px solid rgba(255,255,255,.6); color: #fff; margin-left: 10px;
}
.btn.ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn.dark { background: var(--brand); }
.btn.dark:hover { background: var(--brand-dark); color: #fff; }

/* ---------- 数据条 ---------- */
.stats {
  position: relative; z-index: 2; background: rgba(0,0,0,.28); border-top: 1px solid rgba(255,255,255,.14);
}
.stats .wrap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding-top: 26px; padding-bottom: 26px; }
.stat b { display: block; font-size: 1.85rem; color: #fff; line-height: 1.2; }
.stat span { font-size: 13px; color: #b9cedb; }

/* ---------- 通用区块 ---------- */
section { padding: 68px 0; }
section.alt { background: #fff; }
section.tint { background: var(--brand-light); }
.sec-head { max-width: 46em; margin-bottom: 40px; }
.sec-head .kicker {
  display: inline-block; color: var(--accent-dark); font-weight: 700; font-size: 13px;
  letter-spacing: .12em; text-transform: uppercase; margin-bottom: 10px;
}
.sec-head p.lead { color: var(--muted); font-size: 1.05rem; }

.grid { display: grid; gap: 24px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.card h3 { margin-bottom: .5em; }
.card .icon {
  width: 44px; height: 44px; border-radius: 10px; background: var(--brand-light);
  display: flex; align-items: center; justify-content: center; font-size: 22px; margin-bottom: 14px;
}
.card ul { padding-left: 1.1em; margin-bottom: 0; }
.card li { font-size: 15px; }

.problem { border-left: 4px solid var(--accent); }
.problem .fix { border-left: 4px solid var(--ok); padding-left: 14px; margin-top: 12px; }
.label { font-weight: 700; color: var(--ink); }

/* ---------- 产品卡 ---------- */
.pcard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.pcard img { width: 100%; height: 190px; object-fit: cover; }
.pcard .body { padding: 22px; }
.pcard .spec { list-style: none; padding: 0; margin: 12px 0 0; font-size: 14.5px; }
.pcard .spec li { padding: 5px 0; border-bottom: 1px dashed var(--line); }
.pcard .spec li:last-child { border-bottom: 0; }

/* ---------- 表格 ---------- */
.tablewrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: #fff; font-size: 15px; }
table th, table td { padding: 13px 15px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table thead th { background: var(--brand); color: #fff; font-weight: 600; }
table tbody tr:nth-child(even) { background: #fafbfc; }
table .num { font-weight: 700; color: var(--brand); white-space: nowrap; }
.tag-ok { display: inline-block; background: #e6f6ec; color: var(--ok); font-size: 12px; padding: 2px 8px; border-radius: 4px; font-weight: 700; }

/* ---------- 流程步骤 ---------- */
.steps { counter-reset: s; display: grid; gap: 22px; grid-template-columns: repeat(3, 1fr); }
.step { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; position: relative; }
.step::before {
  counter-increment: s; content: counter(s);
  position: absolute; top: -14px; left: 20px;
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--brand); color: #fff; font-weight: 800;
  display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.step h3 { margin-top: 12px; }

/* ---------- 图集 ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; height: 170px; object-fit: cover; border-radius: 8px; }
.gallery figcaption { font-size: 13px; color: var(--muted); padding-top: 6px; line-height: 1.5; }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); background: #fff; padding: 4px 0; }
.faq summary { cursor: pointer; padding: 16px 8px; font-weight: 700; color: var(--ink); font-size: 16px; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "+"; color: var(--accent); font-weight: 800; margin-right: 10px; }
.faq details[open] summary::before { content: "−"; }
.faq .answer { padding: 0 8px 18px 28px; color: var(--text); font-size: 15px; }

/* ---------- 引用/提示 ---------- */
.callout {
  background: var(--brand-light); border-left: 4px solid var(--brand);
  padding: 18px 22px; border-radius: 0 var(--radius) var(--radius) 0; font-size: 15px;
}
.note {
  background: #fff8ef; border-left: 4px solid var(--accent);
  padding: 16px 20px; border-radius: 0 var(--radius) var(--radius) 0; font-size: 15px;
}

/* ---------- 面包屑 ---------- */
.crumbs { font-size: 13px; color: var(--muted); padding: 16px 0; }
.crumbs a { color: var(--muted); }
.crumbs span { margin: 0 6px; }

/* ---------- 页头（内页） ---------- */
.pagehead {
  background: linear-gradient(135deg, #083f57, #0d5c7e); color: #fff; padding: 52px 0;
}
.pagehead h1 { color: #fff; font-size: 2.1rem; margin-bottom: .3em; }
.pagehead p { color: #cfe0ea; margin: 0; max-width: 46em; }

/* ---------- 联系区 ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; }
.contact-box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; }
.contact-box .big { font-size: 1.6rem; font-weight: 800; color: var(--brand); line-height: 1.4; }
.kv { display: grid; grid-template-columns: 92px 1fr; gap: 10px 14px; font-size: 15px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; color: var(--ink); font-weight: 600; }

form label { display: block; font-size: 14px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
form input, form select, form textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 6px;
  font-family: inherit; font-size: 15px; background: #fff; color: var(--text);
}
form input:focus, form select:focus, form textarea:focus { outline: 2px solid var(--brand-light); border-color: var(--brand); }
.field { margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
form button { border: 0; cursor: pointer; font-family: inherit; }

/* ---------- 页脚 ---------- */
footer { background: var(--ink); color: #a9bcc8; padding: 56px 0 0; font-size: 14.5px; }
footer h4 { color: #fff; font-size: 15px; margin-bottom: 14px; letter-spacing: .04em; }
footer a { color: #a9bcc8; }
footer a:hover { color: #fff; }
footer ul { list-style: none; padding: 0; margin: 0; }
footer li { margin-bottom: 8px; }
footer .fsub { display: block; font-size: 12px; color: #7e94a3; line-height: 1.55; margin: -4px 0 6px; }
.fgrid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 30px; }
.fbrand .cn { color: #fff; font-size: 18px; font-weight: 800; }
.fbrand .en { display: block; font-size: 12px; color: #7e94a3; margin-bottom: 14px; }
.fbottom {
  margin-top: 40px; border-top: 1px solid rgba(255,255,255,.1);
  padding: 20px 0; font-size: 13px; color: #7e94a3;
  display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap;
}

/* ---------- 浮动工具条（移动端） ---------- */
.floatbar { display: none; }

/* ---------- 网站地图页 ---------- */
.sitemap-group { margin-bottom: 34px; }
.sitemap-group h3 { border-bottom: 2px solid var(--brand); padding-bottom: 8px; }
.sitemap-group ul { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 24px; }
.sitemap-group li { padding: 7px 0; border-bottom: 1px dashed var(--line); }
.sitemap-group li span { color: var(--muted); font-size: 13px; }

/* ---------- 文章 ---------- */
.article { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 34px; }
.article h2 { margin-top: 1.4em; font-size: 1.5rem; }
.article h3 { margin-top: 1.2em; }
.article ul, .article ol { margin-bottom: 1.2em; }
.news-item { display: grid; grid-template-columns: 170px 1fr; gap: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 18px; }
.news-item img { width: 100%; height: 100%; min-height: 130px; object-fit: cover; }
.news-item .body { padding: 20px 22px; }
.news-item .meta { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.article-cover { margin: 0 0 24px; }
.article-cover img { width: 100%; max-height: 420px; object-fit: cover; border-radius: 10px; }

/* ---------- 图片灯箱（点击放大） ---------- */
img.zoomable {
  cursor: zoom-in;
  transition: transform .18s ease, box-shadow .18s ease;
}
img.zoomable:hover { transform: scale(1.015); box-shadow: var(--shadow-lg); }
img.zoomable:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.gallery figure img.zoomable:hover { transform: scale(1.03); }

.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(8, 22, 30, .94);
  display: none; align-items: center; justify-content: center;
  padding: 6vh 6vw;
}
.lightbox.open { display: flex; }
.lightbox .lb-figure {
  margin: 0; display: flex; flex-direction: column; align-items: center;
  max-width: 92vw; max-height: 88vh;
}
.lightbox .lb-figure img {
  max-width: 88vw; max-height: 78vh; width: auto; height: auto;
  object-fit: contain; border-radius: 6px; background: #fff;
}
.lightbox .lb-cap {
  color: #dbe7ee; font-size: 14.5px; text-align: center; padding-top: 14px; max-width: 70ch;
}
.lightbox .lb-close {
  position: absolute; top: 12px; right: 18px;
  background: none; border: 0; color: #fff; font-size: 38px; line-height: 1;
  cursor: pointer; padding: 4px 10px;
}
.lightbox .lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 48px; height: 66px; border: 0; border-radius: 6px; cursor: pointer;
  background: rgba(255, 255, 255, .14); color: #fff; font-size: 24px;
}
.lightbox .lb-nav:hover { background: rgba(255, 255, 255, .26); }
.lightbox .lb-prev { left: 16px; }
.lightbox .lb-next { right: 16px; }
.lightbox .lb-count {
  position: absolute; bottom: 16px; left: 0; right: 0;
  text-align: center; color: #9fb4c2; font-size: 13px;
}
@media (max-width: 760px) {
  .lightbox { padding: 8vh 4vw; }
  .lightbox .lb-nav { width: 40px; height: 56px; font-size: 20px; }
  .lightbox .lb-prev { left: 4px; }
  .lightbox .lb-next { right: 4px; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .g4 { grid-template-columns: repeat(2, 1fr); }
  .g3 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .fgrid { grid-template-columns: 1fr 1fr; }
  .stats .wrap { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.5rem; }
  .hero h1 { font-size: 1.9rem; }
  .hero { min-height: 480px; }
  .hero .wrap { padding-top: 48px; padding-bottom: 48px; }
  .nav ul.menu { display: none; }
  .nav ul.menu.open {
    display: flex; position: absolute; top: 72px; left: 0; right: 0;
    background: #fff; flex-direction: column; padding: 12px;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
  }
  .navtoggle { display: block; margin-left: auto; }
  .nav .cta { display: none; }
  .g2, .g3, .g4, .steps { grid-template-columns: 1fr; }
  .fgrid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .news-item { grid-template-columns: 1fr; }
  .news-item img { height: 170px; }
  .sitemap-group ul { grid-template-columns: 1fr; }
  section { padding: 46px 0; }
  .floatbar {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 60;
    background: #fff; border-top: 1px solid var(--line);
  }
  .floatbar a { flex: 1; text-align: center; padding: 12px 4px; font-size: 14px; font-weight: 700; color: var(--brand); }
  .floatbar a + a { border-left: 1px solid var(--line); }
  .floatbar a:last-child { background: var(--accent); color: #fff; }
  body { padding-bottom: 52px; }
}
