/* ===== 辉腾化工官网 基础样式（浅色专业风） ===== */
:root {
  --primary: #0f766e;        /* 主色：化工绿松石 */
  --primary-dark: #0b5a53;
  --accent: #f59e0b;         /* 点缀：琥珀 */
  --ink: #1f2937;            /* 正文深灰 */
  --muted: #6b7280;          /* 次要文字 */
  --bg: #ffffff;
  --bg-alt: #f6f8f8;
  --border: #e5e7eb;
  --radius: 10px;
  --maxw: 1140px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.container.narrow { max-width: 720px; }
.center { text-align: center; }
.lead { font-size: 17px; color: var(--muted); }
.lead.center { text-align: center; max-width: 760px; margin: 0 auto 28px; }

/* 按钮 */
.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: .15s;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); text-decoration: none; }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.btn-ghost:hover { background: rgba(255,255,255,.12); text-decoration: none; }

/* 顶部导航 */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.95);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(6px);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { font-size: 20px; font-weight: 800; color: var(--primary); letter-spacing: .5px; }
.nav-links { display: flex; gap: 26px; }
.nav-links a { color: var(--ink); font-weight: 500; }
.nav-links a:hover { color: var(--primary); text-decoration: none; }
.nav-toggle { display: none; background: none; border: none; font-size: 26px; color: var(--ink); cursor: pointer; }

/* 首屏 */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  padding: 84px 0;
  text-align: center;
}
.hero-small { padding: 54px 0; }
.hero h1 { font-size: 38px; margin: 0 0 14px; line-height: 1.25; }
.hero-sub { font-size: 18px; opacity: .92; margin: 0 0 26px; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* 区块 */
.section { padding: 64px 0; }
.section-alt { background: var(--bg-alt); }
.section-title {
  font-size: 28px; text-align: center; margin: 0 0 34px; position: relative;
}
.section-title::after {
  content: ""; display: block; width: 48px; height: 4px;
  background: var(--accent); margin: 12px auto 0; border-radius: 2px;
}

/* 网格 */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* 卡片 */
.card, .product-card, .product-item {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; transition: .18s;
}
.card:hover, .product-card:hover, .product-item:hover {
  box-shadow: 0 8px 24px rgba(15,118,110,.12); transform: translateY(-2px);
  border-color: var(--primary);
}
.card-icon {
  width: 42px; height: 42px; border-radius: 10px;
  background: var(--primary); color: #fff; display: flex; align-items: center;
  justify-content: center; font-size: 22px; font-weight: 700; margin-bottom: 12px;
}
.card h3, .product-card h3, .product-item h3 { margin: 0 0 8px; font-size: 18px; }
.card p, .product-item p { margin: 0; color: var(--muted); font-size: 14px; }
.product-card { display: block; color: var(--ink); }
.product-card:hover { text-decoration: none; }

.link-ask {
  display: inline-block; margin-top: 12px; font-weight: 600; font-size: 14px;
  color: var(--primary);
}

/* 产品分类间距 */
.product-cat { margin-bottom: 46px; }

/* 数据 */
.stats { text-align: center; }
.stat-num { font-size: 38px; font-weight: 800; color: var(--primary); }
.stat-num span { font-size: 22px; }
.stat-label { color: var(--muted); font-size: 14px; margin-top: 4px; }

/* 表单 */
.contact-form {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; max-width: 640px; margin: 0 auto;
}
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 14px; }
.req { color: #dc2626; }
.field input, .field select, .field textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--border);
  border-radius: 8px; font-size: 15px; font-family: inherit; background: #fff;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15,118,110,.12);
}
.field textarea { resize: vertical; }
.hp-field {
  position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden;
}
.form-msg { margin: 12px 0 0; font-size: 14px; min-height: 18px; }
.form-msg.ok { color: #047857; }
.form-msg.err { color: #dc2626; }
#submitBtn[disabled] { opacity: .6; cursor: not-allowed; }

/* 联系信息 */
.contact-info {
  margin-top: 34px; padding: 22px; background: var(--bg-alt);
  border-radius: var(--radius); border: 1px solid var(--border);
}
.contact-info h3 { margin-top: 0; }
.contact-info .tip { color: var(--muted); font-size: 13px; }

/* 页脚 */
.site-footer { background: #0f172a; color: #cbd5e1; padding: 44px 0 22px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 26px; }
.site-footer .brand { color: #fff; font-size: 20px; }
.site-footer h4 { color: #fff; margin: 0 0 10px; }
.site-footer a { color: #93c5b1; }
.site-footer p { margin: 4px 0; font-size: 14px; }
.copyright { text-align: center; color: #64748b; font-size: 13px; border-top: 1px solid #1e293b; margin-top: 26px; padding-top: 16px; }

/* 响应式 */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .hero h1 { font-size: 28px; }
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--border);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 14px 20px; border-top: 1px solid var(--border); }
  .grid-4, .grid-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .section { padding: 44px 0; }
}

/* ===== 静态站补充样式 ===== */
.home-contact {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 22px;
}

.draft-box {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f7f9fc;
}
.draft-box[hidden] { display: none; }

.draft-tip {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--text);
}

.draft-text {
  width: 100%;
  padding: 12px;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  resize: vertical;
}

.draft-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

@media (max-width: 640px) {
  .home-contact .btn { width: 100%; }
  .draft-actions .btn { width: 100%; }
}
