/* Base */
:root{
  --bg: #1a35cc;
  --panel: rgba(48, 82, 106, 0.08);
  --panel-2: rgba(255,255,255,.12);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.72);
  --brand: #4f8cff;
  --brand-2: #36d399;
  --danger: #ff5a5f;
  --shadow: 0 18px 60px rgba(0,0,0,.35);
  --ring: 0 0 0 4px rgba(79,140,255,.22);
  --radius: 18px;
  --radius-sm: 12px;
  --max: 1120px;
}

[data-theme="light"]{
  --bg: #f6f8ff;
  --panel: rgba(0,0,0,.05);
  --panel-2: rgba(0,0,0,.08);
  --text: rgba(0,0,0,.88);
  --muted: rgba(0,0,0,.62);
  --shadow: 0 18px 60px rgba(0,0,0,.12);
  --ring: 0 0 0 4px rgba(79,140,255,.18);
}

[data-theme="dark"]{
  --bg: #0b1220;
  --panel: rgba(255,255,255,.08);
  --panel-2: rgba(255,255,255,.12);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.72);
  --shadow: 0 18px 60px rgba(0,0,0,.35);
  --ring: 0 0 0 4px rgba(79,140,255,.22);
}

@media (prefers-color-scheme: light){
  :root{
    --bg: #f6f8ff;
    --panel: rgba(0,0,0,.05);
    --panel-2: rgba(0,0,0,.08);
    --text: rgba(0,0,0,.88);
    --muted: rgba(0,0,0,.62);
    --shadow: 0 18px 60px rgba(0,0,0,.12);
    --ring: 0 0 0 4px rgba(79,140,255,.18);
  }
}

*{ box-sizing: border-box; }
html,body{ height: 100%; }
body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "PingFang SC","Hiragino Sans GB","Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1000px 520px at 12% 10%, rgba(79,140,255,.35), transparent 65%),
    radial-gradient(900px 500px at 82% 18%, rgba(54,211,153,.25), transparent 62%),
    radial-gradient(900px 520px at 62% 88%, rgba(255,90,95,.18), transparent 60%),
    var(--bg);
  line-height: 1.55;
}

a{ color: inherit; text-decoration: none; }
img{ max-width: 100%; display: block; }
button, input, textarea{ font: inherit; color: inherit; }

.container{
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.card{
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.section{
  padding: 46px 0;
}

.section-title{
  display:flex;
  align-items:flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.section-title h2{
  margin: 0;
  letter-spacing: .2px;
  font-size: 22px;
}
.section-title p{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.grid{
  display:grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
}

.btn{
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.08);
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
  transition: transform .08s ease, background .15s ease, border-color .15s ease;
  user-select: none;
}
.btn:hover{ background: rgba(255,255,255,.12); }
.btn:active{ transform: scale(.98); }
.btn:focus-visible{ outline: none; box-shadow: var(--ring); }
.btn.primary{
  border-color: rgba(79,140,255,.55);
  background: linear-gradient(135deg, rgba(79,140,255,.65), rgba(54,211,153,.30));
}
.btn.danger{
  border-color: rgba(255,90,95,.55);
  background: rgba(255,90,95,.16);
}

.pill{
  display:inline-flex;
  align-items:center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: var(--muted);
  font-size: 13px;
}

/* Header / Nav (injected by js/switch-buttons.js) */
.site-header{
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 0;
  backdrop-filter: blur(12px);
  background: rgba(8, 24, 64, .92); /* 深蓝 */
  border-bottom: 1px solid rgba(255,255,255,.10);
  color: rgba(248,250,252,.96);
}
.site-header.scrolled{
  background: rgba(255,255,255,.60); /* 下滑后白色 60% 透明 */
  border-bottom-color: rgba(15,23,42,.10);
  color: rgba(15,23,42,.92);
}

.site-header > .container{
  padding: 14px 0;
}

.topbar{
  background: rgba(8, 24, 64, .92);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-header.scrolled .topbar{
  background: rgba(255,255,255,.60);
  border-bottom-color: rgba(15,23,42,.08);
}
.topbar .container{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  padding: 8px 0;
}
.topbar .tel{
  font-size: 12px;
  letter-spacing: .2px;
  color: inherit;
  opacity: .92;
}
.site-header.scrolled .topbar .tel{
  opacity: .88;
}
.nav-wrap{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
}
.brand{
  display:flex;
  align-items:center;
  gap: 10px;
  min-width: 240px;
}
.brand-badge{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: transparent;
  border: none;
  box-shadow: none;
  display:grid;
  place-items:center;
  font-weight: 800;
  letter-spacing: .5px;
  overflow: hidden;
}
.brand-logo{
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.site-header.scrolled .brand-badge{ background: transparent; border: none; }
.brand-title{
  display:flex;
  flex-direction: column;
  gap: 2px;
}
.brand-title .name{
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .3px;
}
.brand-title .slogan{
  font-size: 12px;
  color: rgba(226,232,240,.86);
}
.site-header.scrolled .brand-title .slogan{
  color: rgba(51,65,85,.82);
}
.nav{
  display:flex;
  gap: 10px;
  align-items:center;
  justify-content:center;
  flex-wrap: wrap;
}
.nav a{
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(15,23,42,.10);
  background: rgba(255,255,255,.92); /* 下面部分白色 */
  color: rgba(15,23,42,.78);
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.nav a:hover{
  background: rgba(255,255,255,.98);
  color: var(--brand); /* 悬停字体变蓝 */
}
.nav a.active{
  color: var(--brand);
  border-color: rgba(29,78,216,.35);
  background: rgba(29,78,216,.10);
}

.nav-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap: 10px;
  min-width: 240px;
}
.icon-btn{
  width: 40px;
  height: 40px;
  display:grid;
  place-items:center;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.10);
  cursor: pointer;
  transition: transform .08s ease, background .15s ease;
}
.icon-btn:hover{ background: rgba(255,255,255,.10); }
.icon-btn:active{ transform: scale(.98); }
.icon-btn:focus-visible{ outline: none; box-shadow: var(--ring); }

.site-header.scrolled .icon-btn{
  border-color: rgba(15,23,42,.10);
  background: rgba(255,255,255,.78);
}
.site-header.scrolled .icon-btn:hover{
  background: rgba(255,255,255,.92);
}

/* Mobile menu */
.mobile-only{ display:none; }
@media (max-width: 920px){
  .brand{ min-width: auto; }
  .nav{ display:none; }
  .mobile-only{ display: inline-grid; }
  .nav-actions{ min-width: auto; }
}
.drawer-backdrop{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  display:none;
  z-index: 60;
}
.drawer{
  position: fixed;
  top: 10px;
  right: 10px;
  width: min(420px, calc(100% - 20px));
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.92);
  box-shadow: var(--shadow);
  display:none;
  z-index: 61;
}
.drawer .drawer-head{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.drawer .drawer-links{
  display:flex;
  flex-direction: column;
  gap: 10px;
}
.drawer .drawer-links a{
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15,23,42,.10);
  background: rgba(255,255,255,.92);
  color: rgba(15,23,42,.78);
}
.drawer .drawer-links a:hover{
  color: var(--brand);
  background: rgba(255,255,255,.98);
}
.drawer .drawer-links a.active{
  color: var(--brand);
  border-color: rgba(29,78,216,.35);
  background: rgba(29,78,216,.10);
}

.drawer-backdrop.open,
.drawer.open{ display:block; }

/* Hero */
.hero{
  padding: 18px 0 42px;
}
.hero-grid{
  display:grid;
  grid-template-columns: 1.35fr .65fr;
  gap: 16px;
  align-items: stretch;
}
@media (max-width: 980px){
  .hero-grid{ grid-template-columns: 1fr; }
}

.carousel{
  overflow:hidden;
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  min-height: 340px;
  position: relative;
}
.carousel-track{
  display:flex;
  width: 100%;
  height: 100%;
  transition: transform 420ms ease;
}
.slide{
  min-width: 100%;
  height: 100%;
  position: relative;
}
.slide.is-link{
  cursor: pointer;
}
.slide.is-link:focus-visible{
  outline: none;
  box-shadow: var(--ring);
}
.slide img{
  width: 100%;
  height: 340px;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.02);
}
.slide .caption{
  position:absolute;
  inset: auto 14px 14px 14px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(0,0,0,.35);
  border: 1px solid rgba(255,255,255,.16);
  backdrop-filter: blur(10px);
}
@media (prefers-color-scheme: light){
  .slide .caption{
    background: rgba(255,255,255,.35);
  }
}
.caption .kicker{
  display:inline-flex;
  gap: 8px;
  align-items:center;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}
.caption h1{
  margin: 0 0 8px;
  font-size: 22px;
  letter-spacing: .3px;
}
.caption p{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.carousel-controls{
  position:absolute;
  inset: 12px 12px auto auto;
  display:flex;
  gap: 10px;
}
.dots{
  position:absolute;
  inset: auto 14px 12px 14px;
  display:flex;
  gap: 8px;
  justify-content:center;
}
.dot{
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.34);
  background: rgba(255,255,255,.12);
  cursor: pointer;
}
.dot.active{
  width: 18px;
  background: rgba(79,140,255,.7);
  border-color: rgba(79,140,255,.85);
}

.hero-side{
  padding: 16px;
  border-radius: var(--radius);
}
.hero-side h3{
  margin: 0 0 10px;
  font-size: 16px;
}
.hero-side p{
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
}
.stat{
  display:flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  margin-top: 10px;
}
.stat b{
  font-size: 18px;
}
.stat span{
  color: var(--muted);
  font-size: 12px;
}

/* Feature cards */
.feature{
  grid-column: span 4;
  padding: 16px;
  border-radius: var(--radius);
}
@media (max-width: 980px){
  .feature{ grid-column: span 6; }
}
@media (max-width: 640px){
  .feature{ grid-column: span 12; }
}
.feature h4{
  margin: 10px 0 8px;
  font-size: 15px;
}
.feature p{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.feature .icon{
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display:grid;
  place-items:center;
  background: rgba(79,140,255,.18);
  border: 1px solid rgba(79,140,255,.28);
}

/* Footer (injected) */
.site-footer{
  padding: 40px 0 26px;
  color: var(--muted);
}
.footer-grid{
  display:grid;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap: 16px;
  padding: 18px;
  border-radius: var(--radius);
}
@media (max-width: 920px){
  .footer-grid{ grid-template-columns: 1fr; }
}
.footer-grid h4{ margin: 0 0 10px; color: var(--text); font-size: 14px; }
.footer-grid p{ margin: 0; font-size: 13px; }
.footer-grid a{ color: var(--text); opacity: .9; }
.copyright{
  text-align:center;
  font-size: 12px;
  margin-top: 14px;
  opacity: .9;
}

/* Forms */
.form{
  padding: 16px;
}
.form-row{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 760px){
  .form-row{ grid-template-columns: 1fr; }
}
.field{
  display:flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}
.label{
  font-size: 13px;
  color: var(--muted);
}
input[type="text"], input[type="email"], textarea{
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  padding: 10px 12px;
  outline: none;
}
textarea{ resize: vertical; min-height: 120px; }
input:focus, textarea:focus{ box-shadow: var(--ring); }
.hint{ color: var(--muted); font-size: 12px; margin-top: 4px; }

/* Message board list */
.msg-list{
  display:flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}
.msg-item{
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
}
.msg-meta{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}
.msg-content{
  white-space: pre-wrap;
  word-break: break-word;
}
.msg-actions{
  display:flex;
  gap: 10px;
  margin-top: 10px;
}

/* Utility */
.spacer-8{ height: 8px; }
.spacer-12{ height: 12px; }
.spacer-18{ height: 18px; }
.muted{ color: var(--muted); }
.two-col{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 980px){
  .two-col{ grid-template-columns: 1fr; }
}

/* 可点击的产品卡片（首页产品概览） */
a.link-card{
  text-decoration: none;
  display: block;
  transition: border-color .2s ease, box-shadow .2s ease;
}
a.link-card:hover{
  border-color: rgba(79,140,255,.4);
  box-shadow: 0 20px 50px rgba(0,0,0,.2);
}

/* Back to top */
.backtop{
  position: fixed;
  right: 16px;
  bottom: 16px;
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display:none;
  place-items:center;
  z-index: 70;
}
.backtop.show{ display:grid; }

