/* ==========================================================================
   Yagelong Hardware Co., Ltd. —— 全站公共样式表
   配色规范：品牌红 #b4282b / 炭黑 #2a2929 / 米白底 #f5f2ec
   ========================================================================== */

/* ---------- 全局变量与基础重置 ---------- */
:root {
  --primary: #b4282b;        /* 品牌红 */
  --primary-dark: #8f1f22;   /* 品牌红加深（hover） */
  --dark: #2a2929;           /* 炭黑主色 */
  --dark-soft: #3a3939;      /* 炭黑浅一档 */
  --bg: #f5f2ec;             /* 米白底色 */
  --white: #ffffff;
  --text: #333333;
  --text-light: #6b6b6b;
  --border: #e5e0d6;
  --shadow: 0 6px 24px rgba(42, 41, 41, .10);
  --radius: 6px;
  --transition: all .35s cubic-bezier(.25, .8, .35, 1);
  --header-h: 76px;
  --topbar-h: 36px;      /* 顶部信息条高度，用于轮播全屏高度计算 */
  /* 全站统一字体：Inter（英文为主）+ 系统中文字体兜底 */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               'Helvetica Neue', Arial, 'PingFang SC', 'Hiragino Sans GB',
               'Microsoft YaHei', sans-serif;
}

/* ---------- Inter 字体（本地自托管 fonts/ 目录，离线双击打开同样生效） ---------- */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/inter-latin-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/inter-latin-500-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/inter-latin-600-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/inter-latin-700-normal.woff2') format('woff2');
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul, ol { list-style: none; }
/* 表单控件默认不继承字体，需显式继承以统一使用 Inter */
button, input, select, textarea { font-family: inherit; }

/* ---------- 全站 SVG 线性图标基础样式（统一描边风格） ---------- */
.ico {
  width: 1em; height: 1em; vertical-align: -.15em;
  fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.topbar .ico { width: 15px; height: 15px; margin-right: 6px; color: var(--primary); }
.footer .ico { width: 15px; height: 15px; margin-right: 8px; color: var(--primary); vertical-align: -3px; }

.container { width: min(1200px, 92%); margin: 0 auto; }

/* 通用区块标题（英文小标 + 中文大标） */
.section { padding: 80px 0; }
.section-head { text-align: center; margin-bottom: 50px; }
.section-head .en {
  display: inline-block; font-size: 12px; letter-spacing: 4px; text-transform: uppercase;
  color: var(--primary); font-weight: 600; margin-bottom: 8px;
}
.section-head h2 {
  font-size: 32px; color: var(--dark); letter-spacing: 1px; font-weight: 700;
}
.section-head h2::after {
  content: ""; display: block; width: 56px; height: 3px;
  background: var(--primary); margin: 14px auto 0; border-radius: 2px;
}
.section-head p { color: var(--text-light); margin-top: 14px; max-width: 720px; margin-left: auto; margin-right: auto; }

/* 通用按钮 */
.btn {
  display: inline-block; padding: 13px 34px; font-size: 15px; font-weight: 600;
  letter-spacing: 1px; border-radius: var(--radius); cursor: pointer; border: none;
  transition: var(--transition); text-align: center;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(180, 40, 43, .35); }
.btn-dark { background: var(--dark); color: #fff; }
.btn-dark:hover { background: #141414; transform: translateY(-2px); }
.btn-outline { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.85); }
.btn-outline:hover { background: #fff; color: var(--dark); }
.btn-ghost { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-ghost:hover { background: var(--primary); color: #fff; }

/* ---------- 顶部信息条 ---------- */
.topbar { background: var(--dark); color: rgba(255,255,255,.75); font-size: 13px; }
.topbar .container { display: flex; justify-content: space-between; align-items: center; height: var(--topbar-h); }
.topbar a:hover { color: #fff; }
.topbar .tips span { margin-right: 22px; }

/* ---------- 导航栏（吸顶 + 首页透明态） ---------- */
.header {
  position: sticky; top: 0; left: 0; width: 100%; z-index: 999;
  background: var(--white); box-shadow: 0 2px 12px rgba(0,0,0,.06);
  transition: var(--transition);
  padding-top: env(safe-area-inset-top);
}
.header .container { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.logo { display: flex; align-items: center; gap: 12px; }
.logo img { height: 30px; width: auto; }
.logo .logo-text { line-height: 1.15;  display: none;}
.logo .logo-text b { display: block; font-size: 19px; color: var(--dark); letter-spacing: .5px; }
.logo .logo-text i { font-style: normal; font-size: 11px; color: var(--primary); letter-spacing: 2.5px; text-transform: uppercase; }

/* 首页专用：叠加在 banner 上时导航透明 */
.header.transparent { background: transparent; box-shadow: none; }
.header.transparent .logo-text b { color: #fff; }
.header.transparent .nav > li > a { color: rgba(255,255,255,.92); }
.header.transparent .nav > li > a.active, .header.transparent .nav > li > a:hover { color: #fff; }
.header.transparent .nav > li > a::after { background: #fff; }
.header.transparent .nav-cta { background: var(--primary); }
.header.transparent .hamburger span { background: #fff; }

/* 主导航 */
.nav { display: flex; align-items: center; gap: 34px; }
.nav > li > a {
  position: relative; display: block; padding: 8px 0; font-size: 15px; font-weight: 600;
  color: var(--dark); letter-spacing: .5px;
}
.nav > li > a::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 2px;
  background: var(--primary); transition: var(--transition);
}
.nav > li > a:hover::after, .nav > li > a.active::after { width: 100%; }
.nav > li > a.active, .nav > li > a:hover { color: var(--primary); }
.header.transparent .nav > li > a:hover, .header.transparent .nav > li > a.active { color: #fff; }

.nav-cta { margin-left: 8px; padding: 10px 24px !important; color: #fff !important; }
.nav-cta::after { display: none !important; }

/* 移动端汉堡按钮 */
.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 8px; }
.hamburger span { display: block; width: 26px; height: 3px; background: var(--dark); border-radius: 2px; transition: var(--transition); }
.hamburger.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- 首页轮播 Banner ---------- */
/* 轮播高度自适应全屏：视口高度 - 顶部信息条高度
   优先使用 dvh（移动端地址栏伸缩时仍精确铺满），不支持时回退 vh */
.banner {
  position: relative;
  height: calc(100vh - var(--topbar-h));
  min-height: 420px;
  overflow: hidden;
  margin-top: calc(-1 * var(--header-h));
}
@supports (height: 100dvh) {
  .banner { height: calc(100dvh - var(--topbar-h)); }
}
/* 单屏容器：负责整屏淡入淡出 */
.banner-slide {
  position: absolute; inset: 0; opacity: 0; overflow: hidden;
  transition: opacity 1.1s ease;
}
.banner-slide.active { opacity: 1; }

/* 背景图层：承载 Ken Burns 缓慢推拉 + 左侧擦入擦出 */
.banner-slide .slide-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  will-change: transform;
  /* infinite + alternate 保证来回推拉不跳帧；暂停态让每屏从各自进度继续 */
  animation: kenBurns 16s ease-in-out infinite alternate;
  animation-play-state: paused;
}
/* 激活屏：仅启动推拉动画，转场依靠整屏淡入淡出 */
.banner-slide.active .slide-bg {
  animation-play-state: running;
}
@keyframes kenBurns {
  from { transform: scale(1.04) translate3d(0, 0, 0); }
  to   { transform: scale(1.26) translate3d(-1.6%, -1.2%, 0); }
}

/* 暗色蒙版：改为 ::after，保证绘制顺序在背景图层之上（::before 会被背景层盖住） */
.banner-slide::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(105deg, rgba(26,25,25,.82) 0%, rgba(26,25,25,.45) 55%, rgba(180,40,43,.28) 100%);
  opacity: 0; transition: opacity 1.2s ease;
}
.banner-slide.active::after { opacity: 1; }

/* 文案逐条入场（激活时按序上浮淡入，切换回来会重新播放） */
.banner-inner > * { opacity: 0; transform: translateY(30px); }
.banner-slide.active .banner-inner > * {
  animation: bannerTextIn .85s cubic-bezier(.2, .7, .3, 1) forwards;
}
.banner-slide.active .banner-inner .tag     { animation-delay: .30s; }
.banner-slide.active .banner-inner h1       { animation-delay: .42s; }
.banner-slide.active .banner-inner p        { animation-delay: .56s; }
.banner-slide.active .banner-inner .banner-btns { animation-delay: .70s; }
@keyframes bannerTextIn {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
/* 标题左侧装饰竖线随文案一起展开 */
.banner-slide.active .banner-inner .tag::before {
  content: ""; display: inline-block; width: 26px; height: 1px;
  vertical-align: middle; margin-right: 10px; background: var(--primary);
  animation: tagLine .6s .5s cubic-bezier(.2, .7, .3, 1) both;
  transform-origin: left center;
}
@keyframes tagLine { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* 尊重系统「减少动态效果」设置 */
@media (prefers-reduced-motion: reduce) {
  .banner-slide .slide-bg { animation: none; transition: none; }
  .banner-inner > * { opacity: 1; transform: none; }
  .banner-slide.active .banner-inner > * { animation: none; }
  .banner-slide.active .banner-inner .tag::before { animation: none; }
  .banner-slide::after { opacity: 1; transition: none; }
}
.banner-inner {
  position: relative; z-index: 2; height: 100%;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  color: #fff; width: min(1200px, 92%); margin: 0 auto;
}
.banner-inner .tag {
  display: inline-block; padding: 6px 18px; border: 1px solid rgba(255,255,255,.5);
  font-size: 12px; letter-spacing: 3px; text-transform: uppercase; margin-bottom: 22px;
}
.banner-inner h1 { font-size: 50px; line-height: 1.25; letter-spacing: 1px; max-width: 780px; text-shadow: 0 4px 24px rgba(0,0,0,.4); }
.banner-inner p { margin: 20px 0 34px; font-size: 17px; color: rgba(255,255,255,.88); max-width: 640px; }
.banner-btns { display: flex; gap: 16px; flex-wrap: wrap; }
.banner-dots { position: absolute; bottom: calc(34px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); display: flex; gap: 12px; z-index: 3; }
.banner-dots button {
  width: 34px; height: 4px; border: none; border-radius: 2px; cursor: pointer;
  background: rgba(255,255,255,.4); transition: var(--transition);
}
.banner-dots button.active { background: var(--primary); width: 52px; }
.banner-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 48px; height: 48px; border: none; border-radius: 50%; cursor: pointer;
  background: rgba(255,255,255,.14); color: #fff; font-size: 20px; transition: var(--transition);
}
.banner-arrow:hover { background: var(--primary); }
.banner-arrow .ico { width: 20px; height: 20px; stroke-width: 2; }
.banner-arrow.prev { left: 26px; }
.banner-arrow.next { right: 26px; }

/* ---------- 页面通用内页头图 ---------- */
.page-hero {
  position: relative; padding: 130px 0 90px; text-align: center; color: #fff;
  background-size: cover; background-position: center;
}
.page-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(rgba(30,29,29,.78), rgba(30,29,29,.62)); }
.page-hero .container { position: relative; z-index: 2; }
.page-hero h1 { font-size: 40px; letter-spacing: 1px; margin-bottom: 12px; }
.page-hero .crumb { font-size: 14px; color: rgba(255,255,255,.8); }
.page-hero .crumb a:hover { color: var(--primary); }

/* ---------- 卡片通用 ---------- */
.card {
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 3px 14px rgba(42,41,41,.07); transition: var(--transition);
}
.card:hover { transform: translateY(-8px); box-shadow: var(--shadow); }

/* ---------- 产品卡片 ---------- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
/* 首页分类入口当前仅 2 类：固定一行两列铺满整行 */
#categoryEntry { grid-template-columns: repeat(2, 1fr); }
.product-card { position: relative; }
.product-card .pic { position: relative; overflow: hidden; aspect-ratio: 4 / 3.8; background: #eceae4; }
.product-card .pic img { width: 100%; height: auto; object-fit: cover; transition: transform .6s ease; }
.product-card:hover .pic img { transform: scale(1.08); }
.product-card .pic::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(42,41,41,.35), transparent 45%);
  opacity: 0; transition: var(--transition);
}
.product-card:hover .pic::after { opacity: 1; }
.product-card .badge {
  position: absolute; top: 12px; left: 12px; z-index: 2; padding: 4px 12px;
  background: var(--primary); color: #fff; font-size: 12px; letter-spacing: 1px; border-radius: 3px;
}
.product-card .info { padding: 18px 20px 22px; }
.product-card .info h3 { font-size: 16px; color: var(--dark); margin-bottom: 6px; }
.product-card .info .sku { font-size: 12px; color: var(--text-light); letter-spacing: 1px; margin-bottom: 10px; }
.product-card .info .meta { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.product-card .info .meta .moq { color: var(--primary); font-weight: 600; }
.product-card .info .meta a, .product-card .info .meta .go { color: var(--dark); font-weight: 600; }
.product-card .info .meta a:hover, .product-card:hover .info .meta .go { color: var(--primary); }

/* 分类筛选按钮 */
.filter-bar { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-bottom: 44px; }
.filter-bar button {
  padding: 10px 28px; background: var(--white); color: var(--dark); border: 1px solid var(--border);
  border-radius: 30px; font-size: 14px; font-weight: 600; cursor: pointer; transition: var(--transition);
}
.filter-bar button:hover { border-color: var(--primary); color: var(--primary); }
.filter-bar button.active { background: var(--primary); border-color: var(--primary); color: #fff; }

/* 简易分页 */
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 52px; }
.pagination button {
  min-width: 42px; height: 42px; padding: 0 14px; border: 1px solid var(--border); background: var(--white);
  color: var(--dark); font-size: 14px; font-weight: 600; cursor: pointer; border-radius: var(--radius); transition: var(--transition);
}
.pagination button:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.pagination button.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination button:disabled { opacity: .4; cursor: not-allowed; }

/* ---------- 优势 / 特性块 ---------- */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px; }

.feature { padding: 38px 30px; text-align: center; }
.feature .icon {
  width: 68px; height: 68px; margin: 0 auto 20px; border-radius: 50%;
  background: rgba(180,40,43,.08); color: var(--primary);
  display: flex; align-items: center; justify-content: center; transition: var(--transition);
}
.feature .icon .ico { width: 32px; height: 32px; }
.feature:hover .icon { background: var(--primary); color: #fff; transform: translateY(-5px); }
.feature h3 { font-size: 18px; color: var(--dark); margin-bottom: 10px; }
.feature p { font-size: 14px; color: var(--text-light); }

/* 数字统计 */
.stats { background: var(--dark); color: #fff; padding: 64px 0; }
.stats .grid-4 { gap: 20px; }
.stat { text-align: center; }
.stat b { display: block; font-size: 44px; color: var(--primary); line-height: 1.1; }
.stat b sup { font-size: 20px; }
.stat span { font-size: 14px; color: rgba(255,255,255,.72); letter-spacing: 1px; }

/* ---------- 图文混排板块 ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 54px; align-items: center; }
.split .pic { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.split .pic img { transition: transform .7s ease; }
.split .pic:hover img { transform: scale(1.05); }
.split .txt h2 { font-size: 30px; color: var(--dark); margin-bottom: 18px; }
.split .txt .en-sub { font-size: 12px; letter-spacing: 4px; text-transform: uppercase; color: var(--primary); font-weight: 600; margin-bottom: 10px; display: inline-block; }
.split .txt p { color: var(--text-light); margin-bottom: 14px; }
.check-list li { position: relative; padding-left: 30px; margin-bottom: 10px; color: var(--text); }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0; width: 20px; height: 20px;
  background: var(--primary); color: #fff; font-size: 12px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

/* ---------- 新闻卡片 ---------- */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.news-card { display: flex; flex-direction: column; }
.news-card .pic { aspect-ratio: 16 / 9; overflow: hidden; }
.news-card .pic img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.news-card:hover .pic img { transform: scale(1.07); }
.news-card .body { padding: 22px 24px 26px; flex: 1; display: flex; flex-direction: column; }
.news-card .date { font-size: 12px; color: var(--primary); font-weight: 600; letter-spacing: 1px; margin-bottom: 10px; }
.news-card h3 { font-size: 17px; color: var(--dark); line-height: 1.5; margin-bottom: 10px; }
.news-card h3 a:hover { color: var(--primary); }
.news-card p { font-size: 14px; color: var(--text-light); flex: 1; }
.news-card .more { margin-top: 16px; font-size: 13px; font-weight: 600; color: var(--primary); }
.news-card .more:hover { letter-spacing: 1px; }

/* ---------- 新闻详情 ---------- */
.article-wrap { max-width: 860px; margin: 0 auto; background: var(--white); border-radius: var(--radius); box-shadow: 0 3px 16px rgba(42,41,41,.07); padding: 50px 56px; }
.article-head { border-bottom: 1px solid var(--border); padding-bottom: 24px; margin-bottom: 30px; }
.article-head h1 { font-size: 28px; color: var(--dark); line-height: 1.5; margin-bottom: 14px; }
.article-head .meta { font-size: 13px; color: var(--text-light); display: flex; gap: 26px; }
.article-head .meta b { color: var(--primary); }
.article-body p { margin-bottom: 18px; color: #444; }
.article-body img { border-radius: var(--radius); margin: 10px 0 24px; }
.article-body h2 { font-size: 20px; color: var(--dark); margin: 28px 0 14px; padding-left: 12px; border-left: 4px solid var(--primary); }
.article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 40px; padding-top: 26px; border-top: 1px solid var(--border); }
.article-nav a {
  padding: 16px 20px; background: var(--bg); border-radius: var(--radius); font-size: 14px; color: var(--dark);
  border: 1px solid var(--border);
}
.article-nav a:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-3px); }
.article-nav a span { display: block; font-size: 12px; color: var(--text-light); margin-bottom: 4px; }

/* ---------- 产品详情页 ---------- */
.detail-top { display: grid; grid-template-columns: 1.05fr 1fr; gap: 50px; margin-bottom: 70px; }
.detail-gallery .main-pic { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 4/3.8; }
.detail-gallery .main-pic img { width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; transition: transform .5s ease; }
.detail-gallery .main-pic img:hover { transform: scale(1.6); }
.detail-info h1 { font-size: 28px; color: var(--dark); line-height: 1.4; margin-bottom: 8px; }
.detail-info .sku { font-size: 13px; color: var(--text-light); letter-spacing: 1px; margin-bottom: 20px; }
.detail-info .lead { color: var(--primary); font-weight: 600; margin-bottom: 18px; font-size: 15px; }
.param-table { width: 100%; border-collapse: collapse; margin-bottom: 24px; font-size: 14px; }
.param-table th, .param-table td { border: 1px solid var(--border); padding: 10px 14px; text-align: left; }
.param-table th { background: var(--bg); color: var(--dark); width: 180px; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 26px; }
.detail-tags span { padding: 5px 14px; background: rgba(180,40,43,.08); color: var(--primary); font-size: 12px; border-radius: 20px; font-weight: 600; }
.detail-btns { display: flex; flex-wrap: nowrap; gap: 10px; }
.detail-btns .btn { flex: 0 1 auto; min-width: 0; padding: 11px 15px; font-size: 13.5px; letter-spacing: .3px; white-space: nowrap; }
.detail-section { background: var(--white); border-radius: var(--radius); box-shadow: 0 3px 16px rgba(42,41,41,.07); padding: 46px 50px; margin-bottom: 40px; margin-top: 40px;}
.detail-section h2 { font-size: 22px; color: var(--dark); margin-bottom: 22px; padding-left: 14px; border-left: 4px solid var(--primary); }
.detail-section p { color: #555; margin-bottom: 14px; }
.detail-section img { border-radius: var(--radius); margin: 8px 0 18px; }
.detail-imgs { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* ---------- 表单 ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-item { display: flex; flex-direction: column; }
.form-item.full { grid-column: 1 / -1; }
.form-item label { font-size: 14px; font-weight: 600; color: var(--dark); margin-bottom: 8px; }
.form-item label i { color: var(--primary); font-style: normal; margin-left: 3px; }
.form-item input, .form-item select, .form-item textarea {
  padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 14px; font-family: inherit; background: var(--white); transition: var(--transition); color: var(--text);
}
.form-item input:focus, .form-item select:focus, .form-item textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(180,40,43,.12);
}
.form-item .err-msg { font-size: 12px; color: var(--primary); margin-top: 6px; display: none; }
.form-item.error input, .form-item.error select, .form-item.error textarea { border-color: var(--primary); }
.form-item.error .err-msg { display: block; }
.form-ok { display: none; margin-top: 18px; padding: 14px 18px; background: rgba(180,40,43,.08); border-left: 4px solid var(--primary); color: var(--dark); border-radius: var(--radius); font-size: 14px; }

/* ---------- 联系信息块 ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-bottom: 60px; }
.contact-item { padding: 32px 26px; text-align: center; }
.contact-item .icon { color: var(--primary); margin-bottom: 14px; }
.contact-item .icon .ico { width: 34px; height: 34px; }
.contact-item h3 { font-size: 16px; color: var(--dark); margin-bottom: 8px; }
.contact-item p { font-size: 14px; color: var(--text-light); word-break: break-all; }
.contact-item a:hover { color: var(--primary); }
.map-box { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); margin-top: 30px; position: relative; }
.map-box img { width: 100%; height: 320px; object-fit: cover; }
.map-box .mark {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -100%);
  width: 46px; height: 46px; color: var(--primary);
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .35));
}

/* ---------- 时间线（发展历程） ---------- */
.timeline { position: relative; max-width: 900px; margin: 0 auto; padding-left: 30px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--border); }
.timeline li { position: relative; padding: 0 0 34px 30px; }
.timeline li::before {
  content: ""; position: absolute; left: -30px; top: 6px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--white); border: 4px solid var(--primary); box-shadow: 0 0 0 4px rgba(180,40,43,.12);
}
.timeline li b { display: block; font-size: 20px; color: var(--primary); margin-bottom: 6px; }
.timeline li h3 { font-size: 17px; color: var(--dark); margin-bottom: 6px; }
.timeline li p { color: var(--text-light); font-size: 14px; }

/* ---------- 团队卡片 ---------- */
.team-card { text-align: center; padding-bottom: 24px; }
.team-card .pic { aspect-ratio: 1/1; overflow: hidden; }
.team-card .pic img { width: 100%; height: 100%; object-fit: cover; transition: var(--transition); }
.team-card:hover .pic img { transform: scale(1.06); }
.team-card h3 { margin-top: 18px; font-size: 17px; color: var(--dark); }
.team-card span { font-size: 13px; color: var(--primary); font-weight: 600; }

/* ---------- 页脚 ---------- */
.footer { background: var(--dark); color: rgba(255,255,255,.72); margin-top: 0; }
.footer-main { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding: 64px 0 50px; }
.footer h4 { color: #fff; font-size: 16px; letter-spacing: 1px; margin-bottom: 20px; position: relative; padding-bottom: 12px; }
.footer h4::after { content: ""; position: absolute; left: 0; bottom: 0; width: 28px; height: 2px; background: var(--primary); }
.footer p, .footer li { font-size: 14px; line-height: 2; }
.footer a:hover { color: var(--primary); padding-left: 4px; }
.footer .f-logo { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.footer .f-logo img { height: 30px; }
.footer .f-logo b { color: #fff; font-size: 17px; display: block; line-height: 1.2; }
.footer .f-logo i { font-style: normal; font-size: 10px; color: var(--primary); letter-spacing: 2px; text-transform: uppercase; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0; text-align: center; font-size: 13px; color: rgba(255,255,255,.45); }

/* ---------- 返回顶部 ---------- */
.back-top {
  position: fixed; right: 28px; bottom: 34px; z-index: 998; width: 48px; height: 48px;
  border: none; border-radius: 50%; background: var(--primary); color: #fff; font-size: 18px;
  cursor: pointer; box-shadow: 0 8px 20px rgba(180,40,43,.4);
  opacity: 0; visibility: hidden; transform: translateY(16px); transition: var(--transition);
}
.back-top .ico { width: 20px; height: 20px; stroke-width: 2; }
.back-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-top:hover { background: var(--primary-dark); transform: translateY(-4px); }

/* WhatsApp 悬浮入口 */
.float-whatsapp {
  position: fixed; right: 28px; bottom: 96px; z-index: 998; width: 48px; height: 48px; border-radius: 50%;
  background: #25d366; color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 20px rgba(37,211,102,.4); transition: var(--transition);
}
.float-whatsapp .ico { width: 24px; height: 24px; }
.float-whatsapp:hover { transform: translateY(-4px) scale(1.05); color: #fff; }

/* ---------- 动画 ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
.reveal { opacity: 0; }
.reveal.in { animation: fadeUp .8s ease forwards; }

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .product-grid, .grid-4, .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .news-grid, .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-main { grid-template-columns: 1fr 1fr; }
  .detail-top, .split { grid-template-columns: 1fr; }
  .banner-inner h1 { font-size: 38px; }
}

@media (max-width: 768px) {
  /* 顶部信息条在手机端隐藏，同时把高度变量归零，保证轮播仍能精确铺满全屏 */
  :root { --header-h: 64px; --topbar-h: 0px; }
  .topbar { display: none; }
  .section { padding: 56px 0; padding-top: 20PX}
  /* 移动端沿用 dvh 全屏高度，仅下调最小高度避免横屏挤压 */
  .banner { min-height: 380px; }
  .banner-arrow { display: none; }
  /* 手机端轮播只保留标题与按钮，减少文字对图片的遮挡 */
  .banner-inner .tag, .banner-inner p { display: none; }
  /* 移动端文案：标题靠上居中，按钮靠下居中（避开底部圆点） */
  .banner-inner {
    justify-content: space-between;
    align-items: center;
    padding: calc(var(--header-h) + env(safe-area-inset-top) + 100px) 0 72px;
  }
  .banner-inner h1 { font-size: 24px; line-height: 1.35; margin: 0; text-align: center; width: 100%; }
  /* 两个按钮一行排布，并整体缩小 */
  .banner-btns { flex-wrap: nowrap; gap: 8px; width: 100%; }
  .banner-btns .btn {
    flex: 1 1 0; min-width: 0; padding: 8px 6px;
    font-size: 11.5px; letter-spacing: 0;
  }
  .detail-info h1 {
    font-size: 18px;
  }
  /* 详情页按钮：窄屏缩小并允许换行，避免溢出 */
  .detail-btns { flex-wrap: wrap; gap: 8px; }
  .detail-btns .btn { padding: 10px 12px; font-size: 12.5px; letter-spacing: 0; }
  /* 分页按钮：窄屏缩小，多页时自动换行居中 */
  .pagination { gap: 7px; margin-top: 30px; }
  .pagination button { min-width: 34px; height: 34px; padding: 0 10px; font-size: 13px; }
  /* 移动端折叠菜单 */
  .hamburger { display: flex; }
  .nav {
    position: fixed; top: var(--header-h); left: 0; width: 100%; flex-direction: column;
    background: var(--white); gap: 0; padding: 10px 0 20px; box-shadow: 0 14px 24px rgba(0,0,0,.12);
    transform: translateY(-16px); opacity: 0; visibility: hidden; transition: var(--transition);
  }
  /* 移动端导航强制白底，保证深色 logo / 文字可读 */
  .header.transparent { background: var(--white); box-shadow: 0 2px 12px rgba(0,0,0,.06); }
  .header.transparent .hamburger span { background: var(--dark); }
  .header.transparent .nav { background: var(--white); }
  .header.transparent .nav > li > a { color: var(--dark); }
  .header.transparent .nav > li > a.active, .header.transparent .nav > li > a:hover { color: var(--primary); }
  .header.transparent .logo-text b { color: var(--dark); }
  .nav.open { transform: translateY(0); opacity: 1; visibility: visible; }
  .nav > li { width: 100%; text-align: center; }
  .nav > li > a { padding: 13px 0; font-size: 15px; }
  .product-grid, .grid-4, .grid-3, .news-grid, .contact-grid, .grid-2 { grid-template-columns: 1fr; }
  #categoryEntry { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .article-wrap, .detail-section { padding: 30px 22px; }
  .article-nav { grid-template-columns: 1fr; }
  .section-head h2 { font-size: 26px; }
  .page-hero h1 { font-size: 30px; }
  .detail-imgs { grid-template-columns: 1fr; }
  .footer-main { grid-template-columns: 1fr; gap: 30px; padding: 46px 0 36px; }
  .stat b { font-size: 34px; }
  .topbar .tips span:last-child { display: none; }
}


/* ==========================================================================
   语言切换器（导航内）
   ========================================================================== */
.lang-item { position: relative; }
.lang-switch { position: relative; display: flex; align-items: center; }
.lang-btn {
  display: flex; align-items: center; gap: 6px;
  background: none; border: none; cursor: pointer; padding: 8px 4px;
  font-size: 15px; font-weight: 600; letter-spacing: .5px;
  color: var(--dark); transition: var(--transition);
}
.lang-btn:hover { color: var(--primary); }
.header.transparent .lang-btn { color: rgba(255,255,255,.92); }
.header.transparent .lang-btn:hover { color: #fff; }
.lang-btn .lang-globe { display: flex; align-items: center; }
.lang-btn .lang-globe .ico { font-size: 16px; }
.lang-caret { font-size: 10px; transition: var(--transition); }
.lang-switch.open .lang-caret { transform: rotate(180deg); }
.lang-menu {
  position: absolute; top: calc(100% + 12px); left: 50%; transform: translateX(-50%);
  min-width: 132px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 6px; list-style: none; margin: 0; z-index: 1001;
  opacity: 0; visibility: hidden; pointer-events: none; transition: var(--transition);
}
.lang-switch.open .lang-menu {
  opacity: 1; visibility: visible; pointer-events: auto; transform: translateX(-50%) translateY(2px);
}
.lang-menu a {
  display: block; padding: 9px 14px; font-size: 14px; font-weight: 500;
  color: var(--text); border-radius: 4px; text-align: left;
}
.lang-menu a:hover { background: var(--bg); color: var(--primary); }
.lang-menu a.current { color: var(--primary); font-weight: 600; }
.lang-menu a.current::after { content: "\2713"; float: right; }
@media (max-width: 960px) {
  .lang-item { width: 100%; text-align: center; }
  .lang-switch { width: 100%; justify-content: center; }
  .lang-btn { width: 100%; justify-content: center; padding: 13px 0; }
  .lang-menu {
    position: static; transform: none; box-shadow: none; border: none;
    background: var(--bg); margin: 4px 14px; opacity: 1; visibility: hidden;
    height: 0; overflow: hidden; padding: 0;
  }
  .lang-switch.open .lang-menu { transform: none; visibility: visible; height: auto; padding: 6px; }
}

/* ---------- Cookie 同意横幅 ---------- */
.cookie-mask { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); z-index: 9998; display: none; }
.cookie-mask.show { display: block; }
.cookie-consent {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 9999;
  background: var(--white); border-top: 1px solid var(--border);
  box-shadow: 0 -4px 24px rgba(42, 41, 41, .15); padding: 20px 0;
  transform: translateY(110%); transition: transform .4s cubic-bezier(.4, 0, .2, 1);
}
.cookie-consent.show { transform: translateY(0); }
.cookie-consent .container { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.cookie-consent p { flex: 1; min-width: 260px; font-size: 13.5px; line-height: 1.7; color: var(--text-light); margin: 0; }
.cookie-consent p a { color: var(--primary); text-decoration: underline; }
.cookie-btns { display: flex; gap: 10px; flex-shrink: 0; }
.cookie-btns .cc-btn {
  min-width: 110px; text-align: center; font-size: 13px; padding: 9px 20px;
  border-radius: var(--radius); border: none; cursor: pointer; font-weight: 600;
  font-family: inherit; transition: all .2s;
}
.cookie-btns .cc-btn.accept { background: var(--primary); color: #fff; }
.cookie-btns .cc-btn.accept:hover { filter: brightness(1.1); }
.cookie-btns .cc-btn.decline { background: transparent; border: 1.5px solid var(--border); color: var(--text-light); }
.cookie-btns .cc-btn.decline:hover { border-color: var(--primary); color: var(--primary); }
@media (max-width: 768px) {
  .cookie-consent .container { flex-direction: column; align-items: stretch; }
  .cookie-btns { justify-content: stretch; }
  .cookie-btns .cc-btn { flex: 1; }
}


/* ---------- 产品详情相册缩略图 ---------- */
.detail-gallery .gallery-thumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.detail-gallery .gallery-thumbs .gp-thumb { width: 76px; height: 56px; object-fit: cover; border-radius: 8px; border: 2px solid transparent; cursor: pointer; transition: border-color .2s, opacity .2s; box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.detail-gallery .gallery-thumbs .gp-thumb:hover { opacity: .85; }
.detail-gallery .gallery-thumbs .gp-thumb.active { border-color: var(--primary); }
