/* ==========================================================================
   大理蔚蓝科技 · 官网模板  layout.css
   Header / 导航 / 抽屉 / Footer / Hero / 面包屑 / 侧边栏 / 悬浮工具
   ========================================================================== */

/* ============================ Header ============================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: box-shadow var(--t), border-color var(--t), background var(--t);
}
.site-header.is-stuck {
  box-shadow: 0 4px 20px rgba(15, 23, 42, .08);
  border-bottom-color: var(--c-line);
}

.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 24px;
}

/* Logo */
.logo { display: flex; align-items: center; gap: 12px; flex: none; }
.logo__mark {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--grad-main);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 18px;
  box-shadow: var(--sh-blue);
  flex: none;
}
.logo__mark img { width: 40px; height: 40px; border-radius: 10px; }
.logo__text { display: flex; flex-direction: column; line-height: 1.2; }
.logo__name { font-size: 17px; font-weight: 700; color: var(--c-ink); letter-spacing: .01em; }
.logo__slogan { font-size: 11px; color: var(--c-sub); letter-spacing: .12em; text-transform: uppercase; }
.logo__img { display: block; height: 44px; width: auto; }

/* 主导航 */
.nav { display: flex; align-items: center; gap: 4px; flex: 1; }
.nav__item { position: relative; }
.nav__link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--c-ink);
  border-radius: var(--r-sm);
  transition: color var(--t), background var(--t);
  white-space: nowrap;
}
.nav__link:hover { color: var(--c-primary-2); background: var(--c-bg); }
.nav__link.is-active { color: var(--c-primary); font-weight: 600; }
.nav__link.is-active::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px; bottom: 2px;
  height: 2px; background: var(--grad-main); border-radius: 2px;
}
.nav__caret { width: 12px; height: 12px; transition: transform var(--t); }
.nav__item:hover .nav__caret { transform: rotate(180deg); }

/* 二级下拉 */
.nav__sub {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--r);
  box-shadow: var(--sh-2);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all var(--t);
}
/* 悬停桥：覆盖导航项与面板之间的 8px 空隙，防止鼠标下移时 :hover 断开 */
.nav__sub::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -8px;
  height: 8px;
}
.nav__item:hover .nav__sub { opacity: 1; visibility: visible; transform: none; }
.nav__sub a {
  display: block;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  font-size: 14px;
  color: var(--c-text);
}
.nav__sub a:hover { background: var(--c-bg); color: var(--c-primary-2); }
.nav__sub a small { display: block; color: var(--c-sub); font-size: 12px; line-height: 1.5; }

/* 右侧操作 */
.header-actions { display: flex; align-items: center; gap: 10px; flex: none; margin-left: auto; }
.hamburger {
  display: none;
  width: 40px; height: 40px;
  border-radius: var(--r-sm);
  align-items: center; justify-content: center;
  color: var(--c-ink);
}
.hamburger span {
  display: block; width: 20px; height: 2px; background: currentColor;
  position: relative; transition: all var(--t);
}
.hamburger span::before, .hamburger span::after {
  content: ""; position: absolute; left: 0; width: 20px; height: 2px; background: currentColor;
  transition: all var(--t);
}
.hamburger span::before { top: -6px; }
.hamburger span::after { top: 6px; }
.hamburger.is-open span { background: transparent; }
.hamburger.is-open span::before { top: 0; transform: rotate(45deg); }
.hamburger.is-open span::after { top: 0; transform: rotate(-45deg); }

/* ---------- Header 响应式：折叠为汉堡菜单 ---------- */
@media (max-width: 1279px) {
  .nav__link { padding: 10px 9px; font-size: 14px; }
  .logo__slogan { display: none; }
  .header-actions .btn--outline { display: none; }
}
@media (max-width: 1023px) {
  .nav { display: none; }
  .hamburger { display: flex; }
}
@media (max-width: 575px) {
  .header-actions .btn { display: none; }
  .logo__name { font-size: 16px; }
  .logo__mark, .logo__mark img { width: 34px; height: 34px; }
  .logo__img { height: 30px; }
}

/* ============================ 移动端抽屉 ============================ */
.drawer {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(8, 42, 99, .45);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t), visibility var(--t);
}
.drawer.is-open { opacity: 1; visibility: visible; }
.drawer__panel {
  position: absolute;
  top: 0; right: 0;
  width: min(86vw, 380px);
  height: 100%;
  background: #fff;
  padding: 20px;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform .32s var(--ease);
  display: flex;
  flex-direction: column;
}
.drawer.is-open .drawer__panel { transform: none; }
.drawer__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.drawer__close { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; color: var(--c-muted); font-size: 24px; }
.drawer__group { border-bottom: 1px solid var(--c-line); padding: 6px 0; }
.drawer__link {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 4px; font-size: 16px; font-weight: 500; color: var(--c-ink);
}
.drawer__toggle { font-size: 20px; color: var(--c-sub); transition: transform var(--t); }
.drawer__toggle.is-open { transform: rotate(45deg); }
.drawer__sub { display: none; padding: 0 0 10px 12px; }
.drawer__sub.is-open { display: block; }
.drawer__sub a { display: block; padding: 10px 4px; font-size: 14px; color: var(--c-muted); }
.drawer__cta { margin-top: auto; padding-top: 20px; display: grid; gap: 10px; }

/* ============================ Hero ============================ */
.hero {
  position: relative;
  padding: 112px 0 96px;
  overflow: hidden;
  background: linear-gradient(160deg, #06122e 0%, #0a1f4e 42%, #0d2a6b 72%, #123a8f 100%);
  color: #eaf1ff;
  isolation: isolate;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(1000px 420px at 85% 0%, rgba(0, 169, 196, .22), transparent 62%),
    radial-gradient(760px 380px at 8% 108%, rgba(122, 92, 255, .20), transparent 62%);
  z-index: 0;
}

/* ---------- 特效层 ---------- */
.hero__fx { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hero__neural { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .8; }
.hero__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(64px);
  opacity: .55;
  mix-blend-mode: screen;
  animation: hero-orb 16s ease-in-out infinite alternate;
}
.hero__orb--a {
  width: 560px; height: 560px;
  top: -180px; right: -120px;
  background: radial-gradient(circle, rgba(26, 86, 219, .85), rgba(26, 86, 219, 0) 68%);
}
.hero__orb--b {
  width: 460px; height: 460px;
  bottom: -220px; left: -140px;
  background: radial-gradient(circle, rgba(0, 169, 196, .7), rgba(0, 169, 196, 0) 68%);
  animation-delay: -6s;
}
.hero__orb--c {
  width: 380px; height: 380px;
  top: 30%; left: 42%;
  background: radial-gradient(circle, rgba(124, 92, 255, .5), rgba(124, 92, 255, 0) 68%);
  animation-delay: -11s;
}
@keyframes hero-orb {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  50%  { transform: translate3d(40px, -30px, 0) scale(1.12); }
  100% { transform: translate3d(-30px, 24px, 0) scale(.94); }
}
/* 透视科技网格 */
.hero__mesh {
  position: absolute;
  left: -20%; right: -20%; bottom: -6%;
  height: 46%;
  background-image:
    linear-gradient(rgba(102, 161, 255, .16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(102, 161, 255, .16) 1px, transparent 1px);
  background-size: 46px 46px;
  transform: perspective(640px) rotateX(58deg);
  transform-origin: bottom center;
  -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,.9), transparent 88%);
          mask-image: linear-gradient(to top, rgba(0,0,0,.9), transparent 88%);
  animation: hero-mesh 22s linear infinite;
}
@keyframes hero-mesh {
  from { background-position: 0 0, 0 0; }
  to   { background-position: 0 46px, 46px 0; }
}

.hero > .container { position: relative; z-index: 2; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero__badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px 7px 8px;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(126, 166, 255, .35);
  border-radius: var(--r-pill);
  box-shadow: 0 0 24px rgba(26, 86, 219, .35), inset 0 0 12px rgba(102, 161, 255, .12);
  backdrop-filter: blur(6px);
  font-size: 13px; color: #cfe0ff;
  margin-bottom: 24px;
}
.hero__badge b {
  background: linear-gradient(135deg, #00a9c4 0%, #7c5cff 100%);
  color: #fff;
  padding: 2px 10px; border-radius: var(--r-pill); font-size: 12px; font-weight: 600;
  box-shadow: 0 0 14px rgba(0, 169, 196, .55);
}
.hero__title {
  font-size: clamp(32px, 4.6vw, 58px); line-height: 1.18; margin-bottom: 20px;
  color: #fff;
  text-shadow: 0 0 32px rgba(26, 86, 219, .55);
}
.hero__title em {
  font-style: normal;
  background: linear-gradient(90deg, #38bdf8 0%, #66a3ff 30%, #a78bfa 60%, #38bdf8 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  animation: hero-shine 5s linear infinite;
}
@keyframes hero-shine {
  from { background-position: 220% 0; }
  to   { background-position: -20% 0; }
}
.hero__desc { font-size: 18px; color: #aebfe3; max-width: 620px; margin-bottom: 32px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 40px; }
.hero__actions .btn--primary {
  box-shadow: 0 10px 32px rgba(26, 86, 219, .55), 0 0 0 1px rgba(140, 180, 255, .25);
}
.hero__actions .btn--outline {
  border-color: rgba(140, 180, 255, .45);
  color: #dce7ff;
  background: rgba(255, 255, 255, .05);
}
.hero__actions .btn--outline:hover {
  border-color: #9cc0ff; color: #fff;
  background: rgba(102, 161, 255, .14);
}
.hero__stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding-top: 32px; border-top: 1px solid rgba(140, 180, 255, .25); }
.hero__stat b { display: block; font-size: 28px; font-weight: 700; color: #fff; line-height: 1.2; }
.hero__stat b i { font-style: normal; background: linear-gradient(90deg, #38bdf8, #8fb5ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__stat span { font-size: 13px; color: #8fa5cf; }

.hero__visual { position: relative; }
.hero__visual .ph { box-shadow: var(--sh-3); border-style: solid; border-color: #fff; background: #fff; }
/* 首屏主视觉真实图片（替代占位图） */
.hero__shot {
  margin: 0;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: #fff;
  position: relative;
  box-shadow: 0 24px 64px rgba(2, 10, 34, .6), 0 0 0 1px rgba(126, 166, 255, .35);
  animation: hero-float 7s ease-in-out infinite;
}
.hero__shot::before {
  content: "";
  position: absolute;
  inset: -2px;
  z-index: 1;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(120deg, rgba(56, 189, 248, .9), rgba(124, 92, 255, .7), rgba(56, 189, 248, .2), rgba(124, 92, 255, .9));
  background-size: 300% 300%;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  animation: hero-border 6s linear infinite;
}
.hero__shot::after {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 34%;
  background: linear-gradient(180deg, rgba(140, 190, 255, .28), transparent);
  pointer-events: none;
  animation: hero-scan 4.5s ease-in-out infinite;
}
.hero__shot img { width: 100%; height: auto; display: block; position: relative; z-index: 1; }
@keyframes hero-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}
@keyframes hero-border {
  from { background-position: 0 0; }
  to   { background-position: 300% 0; }
}
@keyframes hero-scan {
  0%, 100% { transform: translateY(-40%); opacity: 0; }
  35%      { opacity: 1; }
  60%      { transform: translateY(180%); opacity: .6; }
  70%      { opacity: 0; }
}

/* 悬浮 AI 能力芯片 */
.hero__chip {
  position: absolute;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  font-size: 13px;
  font-weight: 600;
  color: #eaf3ff;
  background: rgba(10, 24, 60, .72);
  border: 1px solid rgba(126, 166, 255, .4);
  border-radius: var(--r-pill);
  box-shadow: 0 10px 28px rgba(2, 10, 34, .5), inset 0 0 14px rgba(102, 161, 255, .14);
  backdrop-filter: blur(8px);
  white-space: nowrap;
  animation: hero-chip 6s ease-in-out infinite;
}
.hero__chip i {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #38f5c8;
  box-shadow: 0 0 10px #38f5c8;
  animation: hero-pulse 2s ease-in-out infinite;
}
.hero__chip--1 { top: -14px; left: -22px; animation-delay: 0s; }
.hero__chip--2 { bottom: 26%; right: -30px; animation-delay: -2s; }
.hero__chip--2 i { background: #7c9bff; box-shadow: 0 0 10px #7c9bff; }
.hero__chip--3 { bottom: -18px; left: 12%; animation-delay: -4s; }
.hero__chip--3 i { background: #c084fc; box-shadow: 0 0 10px #c084fc; }
@keyframes hero-chip {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}
@keyframes hero-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: .45; transform: scale(.7); }
}

@media (prefers-reduced-motion: reduce) {
  .hero__orb, .hero__mesh, .hero__shot, .hero__shot::before, .hero__shot::after,
  .hero__chip, .hero__chip i, .hero__title em {
    animation: none;
  }
}

@media (max-width: 1023px) {
  .hero__grid { grid-template-columns: 1fr; gap: 48px; }
  .hero { padding: 72px 0 72px; }
  .hero__desc { font-size: 16px; }
}
@media (max-width: 767px) {
  .hero__stats { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .hero__actions .btn { width: 100%; justify-content: center; }
  .hero__chip--1 { left: -6px; }
  .hero__chip--2 { right: -6px; }
  .hero__chip--3 { left: 4%; }
}

/* ============================ 面包屑 + 页头 ============================ */
.page-head {
  position: relative;
  padding: 56px 0 48px;
  background: var(--grad-main);
  color: #cbd5e1;
  overflow: hidden;
}
.page-head::after {
  content: "";
  position: absolute; right: -80px; top: -120px;
  width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(255, 255, 255, .14), transparent 70%);
}
.page-head > .container { position: relative; z-index: 2; }
.page-head h1 { color: #fff; margin-bottom: 12px; font-size: clamp(26px, 3.2vw, 40px); }
.page-head p { color: rgba(255, 255, 255, .82); max-width: 720px; margin: 0; font-size: 16px; }

.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; margin-bottom: 18px; }
.crumbs a { color: rgba(255, 255, 255, .78); }
.crumbs a:hover { color: #fff; }
.crumbs span { color: rgba(255, 255, 255, .5); }
.crumbs .is-cur { color: #fff; }

.crumbs--light { margin-bottom: 0; }
.crumbs--light a, .crumbs--light span { color: var(--c-sub); }
.crumbs--light a:hover { color: var(--c-primary-2); }
.crumbs--light .is-cur { color: var(--c-ink); }

@media (max-width: 767px) {
  .page-head { padding: 36px 0 32px; }
}

/* ============================ 侧边栏（锚点导航） ============================ */
.side-nav { position: sticky; top: calc(var(--header-h) + 24px); }
.side-nav__title {
  font-size: 13px; font-weight: 600; color: var(--c-sub);
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: 14px;
}
.side-nav__list { border-left: 2px solid var(--c-line); }
.side-nav__list a {
  display: block;
  padding: 9px 16px;
  font-size: 14px;
  color: var(--c-muted);
  border-left: 2px solid transparent;
  margin-left: -2px;
  transition: all var(--t);
}
.side-nav__list a:hover { color: var(--c-primary-2); }
.side-nav__list a.is-active {
  color: var(--c-primary);
  font-weight: 600;
  border-left-color: var(--c-primary);
  background: var(--c-bg);
}
.side-card {
  margin-top: 20px;
  padding: 20px;
  background: var(--c-bg);
  border-radius: var(--r);
  border: 1px solid var(--c-line);
}
@media (max-width: 1023px) {
  .side-nav { position: static; }
  .side-nav__list { display: flex; gap: 8px; overflow-x: auto; border-left: 0; padding-bottom: 6px; }
  .side-nav__list a { border-left: 0; border-bottom: 2px solid transparent; margin: 0; white-space: nowrap; }
  .side-nav__list a.is-active { border-bottom-color: var(--c-primary); background: none; }
}

/* ============================ Footer ============================ */
.site-footer { background: #0b1526; color: #94a3b8; font-size: 14px; }
.footer-top { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 40px; padding: 64px 0 48px; }
.footer-brand .logo__name { color: #fff; }
.footer-brand p { margin: 18px 0 20px; color: #94a3b8; max-width: 320px; }
/* 页脚 Logo：logo.png 为白底横版图，不能反色（整块会变白），
   改为白色圆角衬底展示原图，并限定尺寸 */
.footer-brand .logo {
  display: inline-flex;
  align-items: center;
  background: #fff;
  padding: 8px 14px;
  border-radius: 10px;
}
.footer-brand .logo__img { height: 36px; width: auto; max-width: 180px; object-fit: contain; }
.footer-contact li { display: flex; gap: 10px; margin-bottom: 10px; color: #cbd5e1; }
.footer-col h5 { color: #fff; font-size: 15px; margin-bottom: 18px; font-weight: 600; }
.footer-col a { display: block; padding: 6px 0; color: #94a3b8; }
.footer-col a:hover { color: #fff; }
.footer-qr { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 20px; }
.footer-qr .ph { width: 96px; background: #16233a; border-color: #263349; }
.footer-qr .ph::after { color: #64748b; font-size: 11px; }
/* 真实二维码/小程序码（来自「站点信息 → 公司信息」配置） */
.footer-qr figure { width: 96px; margin: 0; }
.footer-qr figure img { display: block; width: 96px; height: 96px; object-fit: contain; background: #fff; border-radius: 10px; padding: 4px; }
.footer-qr figure img[src=""] { display: none; }
.footer-qr figure figcaption { margin-top: 8px; font-size: 12px; color: #94a3b8; text-align: center; }
.footer-bottom {
  border-top: 1px solid #1c2a41;
  padding: 20px 0;
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between;
  font-size: 13px; color: #64748b;
}
.footer-bottom a { color: #64748b; }
.footer-bottom a:hover { color: #cbd5e1; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }

@media (max-width: 1023px) {
  .footer-top { grid-template-columns: repeat(2, 1fr); gap: 32px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 575px) {
  .footer-top { grid-template-columns: 1fr; padding: 40px 0 32px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  /* 底部链接改为横排胶囊，避免单列竖排过长 */
  .footer-col h5 { margin-bottom: 12px; }
  .footer-col a {
    display: inline-flex;
    align-items: center;
    padding: 6px 13px;
    margin: 0 8px 8px 0;
    background: rgba(255, 255, 255, .05);
    border: 1px solid #1c2a41;
    border-radius: var(--r-pill);
    white-space: nowrap;
  }
}

/* ============================ 悬浮工具条 ============================ */
.float-bar {
  position: fixed;
  right: 20px;
  bottom: 88px;
  z-index: 800;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.float-btn {
  width: 46px; height: 46px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--c-line);
  box-shadow: var(--sh-2);
  display: flex; align-items: center; justify-content: center;
  color: var(--c-muted);
  transition: all var(--t);
  position: relative;
}
.float-btn:hover { color: #fff; background: var(--c-primary-2); border-color: var(--c-primary-2); transform: translateY(-2px); }
.float-btn svg { width: 20px; height: 20px; }
.float-btn--top { opacity: 0; visibility: hidden; }
.float-btn--top.is-show { opacity: 1; visibility: visible; }
.float-btn__tip {
  position: absolute; right: calc(100% + 10px); top: 50%; transform: translateY(-50%);
  background: var(--c-ink); color: #fff; font-size: 12px; padding: 4px 10px;
  border-radius: var(--r-sm); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity var(--t);
}
.float-btn:hover .float-btn__tip { opacity: 1; }

@media (max-width: 767px) {
  .float-bar { right: 12px; bottom: 74px; }
  .float-btn { width: 40px; height: 40px; }
  .float-btn--hide-sm { display: none; }
}

/* ============================ 移动端底部 CTA 条 ============================ */
.mobile-cta {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 850;
  display: none;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: #fff;
  border-top: 1px solid var(--c-line);
  box-shadow: 0 -4px 16px rgba(15, 23, 42, .08);
}
.mobile-cta__price { flex: 1; font-size: 13px; color: var(--c-muted); }
.mobile-cta__price b { display: block; font-size: 20px; color: var(--c-primary); line-height: 1.2; }
.mobile-cta .btn { flex: none; }
@media (max-width: 767px) {
  .mobile-cta { display: flex; }
  body.has-mobile-cta { padding-bottom: 72px; }
}
