/*!
 * 湖北华辕科技有限公司 · 浅色主题覆盖 (Light theme)
 * 必须在 css/styles.css 之后加载：styles.css 是 Grayscale v7.0.6 深色主题，
 * 本文件把深色区块、深色工具类与失效的背景图统一改写为浅色方案。
 */

:root {
  /* ==========================================================================
     配色规范 · 2026-10-23 定稿（唯一权威定义，其余文件一律引用这里的 --c-*）
     黑      #000000  只用于分割线（栏目的水平线 / 容器之间的竖线）
     深灰    #25282A  深色承载面：按钮底色、深色块、KV 底
     浅灰    #2C2F31  比深灰浅一档的承载面（KV 渐变收口、次级深色块）
     浅蓝    #507BBA  三条数据插条（插条 A / 插条 B / CTA）的底色
     深蓝    #476BAA  插条的上/下边线，以及蓝色系的深一档
     品牌橙  #E75301  全站唯一强调色：logo、图标、链接、按钮、数字
     ========================================================================== */
  --c-black: #000000;
  --c-gray-dark: #25282a;   /* 深灰 */
  --c-gray-light: #2c2f31;  /* 浅灰 */
  --c-blue-light: #507bba;  /* 浅蓝 */
  --c-blue-dark: #476baa;   /* 深蓝 */
  --c-brand: #e75301;       /* 品牌橙 */

  /* 语义别名（历史命名，保留兼容；新代码请直接用上面的 --c-*） */
  --brand: var(--c-brand);
  --brand-dark: var(--c-brand);
  --accent: #f97316;
  --ink: #1f2933;
  --ink-soft: #5c6b73;
  --line: #e5eaec;
  --surface: #ffffff;
  --surface-alt: #f6f9f9;
  --shadow: 0 1px 3px rgba(16, 24, 40, 0.06);

  /* ---------- 模板 --bs-* 颜色变量：全站重指到品牌色 ----------
     这些变量决定 Bootstrap 组件（按钮 hover/active、下拉、分页、进度条、
     表单焦点环、链接色…）的取色。只要有一个没被【全局】覆盖，就会回落到
     模板自带的青绿 —— 曾经把 brand 变量写在只给首页加载的 home-v2-amber.css
     （作用域 .v2-home）里，导致 8 个内页的图标块变成绿色。不要挪出 :root。 */
  --bs-teal: #e75301;                                     /* 模板 #64a19d */
  --bs-primary: #e75301;                                  /* 模板 #64a19d */
  --bs-primary-rgb: 231, 83, 1;                           /* 模板 100, 161, 157 */
  --bs-link-color: #e75301;                               /* 模板 #64a19d */
  --bs-btn-bg: #e75301;                                   /* 模板 #64a19d */
  --bs-btn-border-color: #e75301;                         /* 模板 #64a19d */
  --bs-btn-disabled-bg: #e75301;                          /* 模板 #64a19d */
  --bs-btn-disabled-border-color: #e75301;                /* 模板 #64a19d */
  --bs-btn-color: #e75301;                                /* 模板 #64a19d */
  --bs-btn-hover-bg: #e75301;                             /* 模板 #64a19d */
  --bs-btn-hover-border-color: #e75301;                   /* 模板 #64a19d */
  --bs-btn-focus-shadow-rgb: 231, 83, 1;                  /* 模板 100, 161, 157 */
  --bs-btn-active-bg: #e75301;                            /* 模板 #64a19d */
  --bs-btn-active-border-color: #e75301;                  /* 模板 #64a19d */
  --bs-btn-disabled-color: #e75301;                       /* 模板 #64a19d */
  --bs-dropdown-link-active-bg: #e75301;                  /* 模板 #64a19d */
  --bs-nav-pills-link-active-bg: #e75301;                 /* 模板 #64a19d */
  --bs-accordion-btn-focus-border-color: #f3a980;         /* 模板 #b2d0ce（青绿混白 50%）*/
  --bs-accordion-btn-focus-box-shadow: 0 0 0 0.25rem rgba(231, 83, 1, 0.25);
  --bs-pagination-focus-box-shadow: 0 0 0 0.25rem rgba(231, 83, 1, 0.25);
  --bs-pagination-active-bg: #e75301;                     /* 模板 #64a19d */
  --bs-pagination-active-border-color: #e75301;           /* 模板 #64a19d */
  --bs-progress-bar-bg: #e75301;                          /* 模板 #64a19d */
  --bs-list-group-active-bg: #e75301;                     /* 模板 #64a19d */
  --bs-list-group-active-border-color: #e75301;           /* 模板 #64a19d */
}

/* ---------- 全局 ---------- */
body {
  background-color: var(--surface);
  color: var(--ink);
}
a {
  color: var(--ink);
  text-decoration: none;
}
a:hover {
  color: var(--brand);
  text-decoration: none;
}
h1, h2, h3, h4, h5, h6 {
  color: var(--ink);
}
hr {
  border-color: var(--line);
  opacity: 1;
}

/* ---------- 深色工具类重映射（模板残留的 bg-black / text-white 等） ---------- */
.bg-black,
.bg-dark {
  background-color: var(--surface-alt) !important;
}
.bg-black.border,
.bg-dark.border {
  border-color: var(--line) !important;
}
.text-white {
  color: var(--ink) !important;
}
.text-white-50,
.text-black-50 {
  color: var(--ink-soft) !important;
}
.link-light {
  color: var(--ink-soft) !important;
}
.link-light:hover {
  color: var(--brand) !important;
}
.text-primary {
  color: var(--brand-dark) !important;
}

/* ---------- 顶部导航（7 个页面共用同一套：字距·内边距·字号一致，纯黑文字） ---------- */
.navbar.bg-white {
  background-color: rgba(255, 255, 255, 0.96) !important;
}
.navbar-brand {
  color: #000 !important;
}
/* 字号与字距显式写死：首页带 #mainNav（Grayscale 模板规则）、内页是 Bootstrap 默认，
   不写死会出现「首页导航更宽、滚动后又变一次」的不一致 */
.navbar-light .navbar-nav .nav-link,
#mainNav .nav-link,
#mainNav.navbar-shrink .nav-link {
  font-size: 1rem;
  letter-spacing: 0.0625em; /* 0.0625 × 16px = 1px，与 body 一致 */
  padding: 0.75rem 1rem !important;
  color: #000 !important;
  border-bottom: 0 !important; /* 清掉 Grayscale 滚动后加的 0.25rem 透明边框 */
  text-decoration: none;
}
.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link:focus,
#mainNav .nav-link:hover,
#mainNav .nav-link:focus,
#mainNav.navbar-shrink .nav-link:hover,
#mainNav.navbar-shrink .nav-link:focus {
  color: #000 !important;
  text-decoration: none; /* 导航条里只保留「当前页」那一条橙色下划线 */
}
/* 当前页：在文字下方 0.25em（= 0.25 倍字号，16px 字号约 4px）处画橙色下划线 */
.navbar-light .navbar-nav .nav-link.active,
#mainNav .nav-link.active,
#mainNav.navbar-shrink .nav-link.active {
  color: #000 !important;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.25em;
  text-decoration-skip-ink: none;
}
.navbar-light .navbar-toggler {
  border-color: var(--line);
}
.dropdown-menu {
  border-color: var(--line);
  box-shadow: 0 10px 30px rgba(16, 24, 40, 0.08);
}
.dropdown-item:active {
  background-color: var(--brand);
}

/* 新闻页内的栏目切换条（公司新闻 / 技术文档） */
.nav-pills .nav-link {
  color: var(--ink-soft);
}
.nav-pills .nav-link:hover {
  color: var(--brand-dark);
}
.nav-pills .nav-link.active {
  background-color: var(--brand);
  color: #ffffff;
}

/* Grayscale 的 #mainNav：去掉超高内边距，修掉滚动后变亮蓝的底色 */
#mainNav {
  padding-top: 0;
  padding-bottom: 0;
  box-shadow: 0 1px 0 var(--line);
}
#mainNav .navbar-brand {
  padding: 0.75rem 0;
}
#mainNav.navbar-shrink {
  background-color: rgba(255, 255, 255, 0.98) !important;
  box-shadow: 0 2px 12px rgba(16, 24, 40, 0.08);
}

/* ---------- 导航统一：首页（有 #mainNav）与内页（无 id）必须完全一致 ----------
   Grayscale 模板把 min-height、品牌区内边距、汉堡按钮尺寸只写在 #mainNav 上，
   内页于是比首页矮、右上角汉堡更大，展开后的下拉面板也跟着错位。
   这里用类选择器把这些值兜到所有 .navbar 上（首页由 #mainNav 规则接管，值相同不冲突）。 */
.navbar {
  min-height: 3.5rem;
  padding-top: 0;
  padding-bottom: 0;
}
.navbar-brand {
  padding: 0.75rem 0;
  font-weight: 700;
  margin-right: 0.5rem;   /* Bootstrap 默认 1rem，收一半给窄屏留余量 */
}
.navbar-toggler {
  font-size: 80%;
  padding: 0.75rem;
}
.navbar-toggler:focus {
  outline: none;
}
/* 窄屏展开时：面板与品牌区之间加一条分隔线，与容器左右内边距对齐 */
@media (max-width: 991.98px) {
  .navbar-collapse {
    margin-top: 0.5rem;
    border-top: 1px solid var(--line);
  }
  .navbar-collapse .navbar-nav {
    padding: 0.25rem 0 0.5rem;
  }
}

/* ---------- Grayscale 首页：深色区块 → 浅色 ---------- */
.masthead {
  background: linear-gradient(rgba(255, 255, 255, 0.88), rgba(255, 255, 255, 0.98)),
    url("../assets/img/bg-masthead.webp") center/cover no-repeat;
}
.masthead h1,
.masthead .h1 {
  background: linear-gradient(rgba(31, 41, 51, 0.95), rgba(31, 41, 51, 0.35));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  /* 原主题为英文标题设了 0.8rem 字距，中文下会散开，这里收紧 */
  letter-spacing: 0.1rem;
}
@media (min-width: 992px) {
  .masthead h1,
  .masthead .h1 {
    letter-spacing: 0.1rem;
  }
}
/* 图标方块（Modern Business 模板的 .feature，原主题 CSS 缺失） */
.feature {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 3rem;
  width: 3rem;
}
.about-section {
  background: linear-gradient(to bottom, #ffffff 0%, #f6f9f9 60%, #eef3f3 100%);
}
.projects-section {
  background-color: var(--surface);
}
.projects-section .featured-text {
  border-left-color: var(--brand);
}
.projects-section .project {
  box-shadow: var(--shadow);
}
.signup-section {
  /* 原主题引用的 ../assets/img/bg-signup.jpg 在项目中并不存在，改为纯浅色背景 */
  background: linear-gradient(rgba(255, 255, 255, 0.94), rgba(246, 249, 249, 0.98));
}
.contact-section {
  background-color: var(--surface-alt);
}
.contact-section .card {
  background-color: #ffffff;
  border: 1px solid var(--line);
  border-bottom: 0.25rem solid var(--brand);
  box-shadow: var(--shadow);
}
.contact-section .card h4 {
  color: var(--ink);
}
.footer {
  padding: 2.5rem 0;
  background-color: var(--surface-alt);
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
}
.footer a {
  color: var(--ink-soft);
}
.footer a:hover {
  color: var(--brand-dark);
}

/* ---------- 表单与按钮 ---------- */
.form-control,
.form-select {
  background-color: #ffffff;
  border-color: var(--line);
  color: var(--ink);
}
.form-control:focus,
.form-select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 0.2rem rgba(231, 83, 1, 0.18);   /* 原为模板的青绿焦点环 */
}
.form-control::placeholder {
  color: #9aa5ab;
}
.btn-primary {
  background-color: var(--brand);
  border-color: var(--brand);
  color: #111111;
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--brand) !important;
  border-color: var(--brand) !important;
  color: #111111 !important;
  filter: brightness(0.95);
}
.btn-outline-dark {
  color: var(--ink);
  border-color: #ced4da;
}
.btn-outline-dark:hover {
  background-color: var(--ink);
  border-color: var(--ink);
}
.btn-link {
  color: var(--brand-dark);
}

/* ---------- 卡片 / 徽标（Modern Business 模板页面） ---------- */
.card {
  background-color: #ffffff;
  border-color: var(--line);
}
.badge.bg-secondary {
  background-color: var(--surface-alt) !important;
  color: var(--ink-soft) !important;
  border: 1px solid var(--line);
}
.list-group-item {
  border-color: var(--line);
}
.blockquote {
  color: var(--ink-soft);
}

/* ---------- 联系卡片：清掉模板内写死的青绿（卡片底边 + 那条短线） ---------- */
/* 2026-10-23 按需求：三个卡片里的橙色短线（<hr>）直接去掉 */
.contact-section .card hr {
  display: none;
}

/* 2026-10-23 按需求：三卡标题与图标放大 */
.contact-section .card h4,
.contact-section .card .h4 {
  font-size: clamp(1.05rem, 1.35vw, 1.25rem);
  letter-spacing: 0.08rem;
}
.contact-section .card i {
  font-size: clamp(1.9rem, 2.6vw, 2.4rem);
  line-height: 1;
}
.contact-section .card .small {
  font-size: 0.95rem;
}
/* 短线去掉后，标题与内容之间补一点间距（原间距来自那条 hr 的 my-4） */
.contact-section .card h4,
.contact-section .card .h4 {
  margin-bottom: 0.85rem !important;
}

/* ---------- 导航 logo：左图案（矢量）+ 右文字（HTML），全站 13 页共用 ----------
   自适应 6 档（Bootstrap 断点）：图案按高度缩放（矢量，任意尺寸都清晰），
   中文/英文各分一档字号。≥1200px 那一档 = 原来的桌面尺寸，桌面端观感不变。 */
.v2-logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.v2-logo-mark {
  height: 28px;          /* 档 1：手机竖屏（<576px） */
  width: auto;
  display: block;
  flex: 0 0 auto;
}
.v2-logo-words {
  display: flex;
  flex-direction: column;
  line-height: 1.16;
  min-width: 0;
}
.v2-logo-cn {
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC", sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: var(--ink);
}
.v2-logo-en {
  font-family: Nunito, "Segoe UI", Arial, sans-serif;
  font-size: 0.44rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  white-space: nowrap;
  color: var(--ink);
}

/* 档 1b：极窄屏（<360px）—— 隐藏英文行，只留图案 + 中文，避免挤爆导航 */
@media (max-width: 359.98px) {
  .v2-logo-en { display: none; }
}

/* 档 2：≥576px（大屏手机横屏 / 小平板） */
@media (min-width: 576px) {
  .v2-logo { gap: 0.45rem; }
  .v2-logo-mark { height: 32px; }
  .v2-logo-cn { font-size: 0.98rem; }
  .v2-logo-en { font-size: 0.5rem; letter-spacing: 0.08em; }
}
/* 档 3：≥768px（平板竖屏） */
@media (min-width: 768px) {
  .v2-logo { gap: 0.5rem; }
  .v2-logo-mark { height: 37px; }
  .v2-logo-cn { font-size: 1.06rem; }
  .v2-logo-en { font-size: 0.54rem; letter-spacing: 0.1em; }
}
/* 档 4：≥992px（平板横屏 / 小笔记本） */
@media (min-width: 992px) {
  .v2-logo { gap: 0.55rem; }
  .v2-logo-mark { height: 42px; }
  .v2-logo-cn { font-size: 1.12rem; }
  .v2-logo-en { font-size: 0.57rem; letter-spacing: 0.12em; }
}
/* 档 5：≥1200px（桌面）—— 与改造前完全一致 */
@media (min-width: 1200px) {
  .v2-logo { gap: 0.6rem; }
  .v2-logo-mark { height: 46px; }
  .v2-logo-cn { font-size: 1.16rem; }
  .v2-logo-en { font-size: 0.6rem; letter-spacing: 0.13em; }
}
/* 档 6：≥1400px（大屏 / 宽屏） */
@media (min-width: 1400px) {
  .v2-logo { gap: 0.65rem; }
  .v2-logo-mark { height: 50px; }
  .v2-logo-cn { font-size: 1.21rem; }
  .v2-logo-en { font-size: 0.63rem; letter-spacing: 0.14em; }
}

/* ---------- 新闻卡配图：固定高度，与首页 .v2-news-media（165px）完全一致 ----------
   内页（news-home.html）用的是 Bootstrap 的 .card-img-top，高度会跟着图片比例变；
   挂上本类后两处都是「固定 165px + cover 裁切」，换图不会改变卡片高度。 */
.v2-news-img {
  display: block;
  width: 100%;
  height: 165px;
  object-fit: cover;
}

/* ============================================================================
   页脚区（联系我们三卡 + 版权行）：深灰底 + 纯黑分隔线 + 全白文字
   色板：黑 #000000（只作分隔线）· 深灰 #25282A（页脚底）· 浅灰 #2C2F31（备用）
   要求：小容器紧贴、中间不留白，只用黑线；竖线必须顶到上下横线 → 去掉上下内边距
   ============================================================================ */
.contact-section {
  background: #25282a !important;
  color: #ffffff !important;
  border-top: 1px solid #000000 !important;
  /* 模板给了 padding-top:5rem，会让卡片悬空、竖线接不到横线 */
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
.contact-section .row {
  --bs-gutter-x: 0;
  margin-top: 0;
  margin-bottom: 0;
}
.contact-section [class*="col-md-"] {
  margin-bottom: 0 !important;
  padding-left: 0;
  padding-right: 0;
}
/* 卡片变成透明容器：没有边框、圆角、阴影、白底 */
.contact-section .card {
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.contact-section .card-body {
  padding: 1.75rem 1.25rem;
}
/* 文字全部纯白（原来是 82% 白，看不清） */
.contact-section h4,
.contact-section .h4,
.contact-section .small,
.contact-section .text-muted,
.contact-section a,
.contact-section .link-dark,
.contact-section p,
.contact-section div {
  color: #ffffff !important;
}
.contact-section hr {
  border-color: rgba(255, 255, 255, 0.25);
}
/* 竖线：每格左右各一条；相邻处只画一条，不叠成 2px */
@media (min-width: 768px) {
  .contact-section .row > [class*="col-"] {
    border-left: 1px solid #000000;
  }
  .contact-section .row > [class*="col-"]:last-child {
    border-right: 1px solid #000000;
  }
}
/* 手机竖排：容器之间用横线 */
@media (max-width: 767.98px) {
  .contact-section .row > [class*="col-"] + [class*="col-"] {
    border-top: 1px solid #000000;
  }
}

/* 版权行 */
.footer {
  background: #25282a !important;
  color: #ffffff !important;
  border-top: 1px solid #000000 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
.footer .row {
  --bs-gutter-x: 0;
  margin-left: 0;
  margin-right: 0;
  align-items: stretch !important;
}
.footer .col-auto {
  padding: 1rem 1.25rem;
  border-top: 1px solid #000000;
}
.footer .col-auto:first-child {
  border-top: 0;
}
.footer .small,
.footer .text-muted,
.footer a,
.footer .link-dark,
.footer div {
  color: #ffffff !important;
}
@media (min-width: 576px) {
  /* 版权格占满剩余宽度，链接格按内容收窄 → 中间那条竖线右移、紧贴链接组 */
  .footer .row {
    justify-content: stretch !important;
  }
  .footer .col-auto {
    flex: 1 1 0;
    border-top: 0;
    border-left: 1px solid #000000;
  }
  .footer .col-auto:first-child {
    flex: 1 1 auto;
    border-left: 0;
  }
  .footer .col-auto:last-child {
    flex: 0 0 auto;
  }
}

/* navbar 底部：纯黑 1px（覆盖 Bootstrap 的 .border-bottom 浅灰） */
.navbar {
  border-bottom: 1px solid var(--c-black, #000000) !important;
}

/* ============================================================================
   2026-10-23 v12
   ① 联系三卡：电话 / 邮箱这两块内容下移，并在下方剩余空间里垂直居中
      （企业微信卡里有二维码比另两张高，用 flex + 自动外边距把内容推到剩余空间正中）
   ② 页脚区（联系我们三卡 + 版权行）的黑色分隔线 → 白色
   ============================================================================ */

/* ① 卡片内容纵向布局 */
.contact-section .card,
.contact-section .card-body {
  height: 100%;
}
.contact-section .card-body {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center; /* 二维码图片等子元素左右居中（flex 默认 stretch 会让图片贴左） */
}
.contact-section .card-body img {
  display: block;
  margin-left: auto;
  margin-right: auto;
}
/* 末尾那块（电话 / 邮箱 + QQ / 点击添加）在剩余空间里居中 */
.contact-section .card-body > .small:last-child {
  margin-top: auto;
  margin-bottom: auto;
}

/* ② 分隔线改白 */
.contact-section {
  border-top: 1px solid #ffffff !important;
}
.contact-section .row > [class*="col-"] {
  border-left-color: #ffffff;
}
.contact-section .row > [class*="col-"]:last-child {
  border-right-color: #ffffff;
}
@media (max-width: 767.98px) {
  .contact-section .row > [class*="col-"] + [class*="col-"] {
    border-top-color: #ffffff;
  }
}
/* 版权行：上方白线恢复；竖线右移贴着右侧链接组 */
.footer {
  border-top: 1px solid #ffffff !important;
}
.footer .row > [class*="col-"]:last-child {
  text-align: right;
}
.footer .col-auto {
  border-top-color: #ffffff;
}
@media (min-width: 576px) {
  .footer .col-auto {
    border-left-color: #ffffff;
  }
}
