/* ==========================================================================
   汇分账 OpenBanks 门户站点 — 共享样式
   主色：深海军蓝 #0A2540 / #0F3A5F  强调：品牌青 #00D4AA  浅底：#F8FAFC
   ========================================================================== */

:root {
  /* 品牌色 */
  --navy-900: #071A2F;
  --navy-800: #0A2540;
  --navy-700: #0F3A5F;
  --navy-600: #164B78;
  --teal-500: #00D4AA;
  --teal-600: #00B894;
  --teal-700: #0E8F73;
  --teal-50:  #E4F7F1;

  /* 中性色 */
  --ink-900: #0A2540;
  --ink-700: #2E3D52;
  --ink-500: #4A5B70;
  --ink-400: #64748B;
  --ink-300: #94A3B8;
  --line:    #E2E8F0;
  --line-soft: #EDF2F7;
  --bg:      #F8FAFC;
  --white:   #FFFFFF;

  /* 字体 */
  --font-sans: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei",
               "Source Han Sans SC", -apple-system, BlinkMacSystemFont,
               "Segoe UI", Roboto, sans-serif;
  --font-num: "SF Pro Display", "Helvetica Neue", Inter, var(--font-sans);

  /* 尺度 */
  --maxw: 1240px;
  --radius: 18px;
  --radius-lg: 28px;
  --nav-h: 72px;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- 基础重置 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-700);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; }

h1, h2, h3, h4 {
  margin: 0;
  color: var(--ink-900);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: clamp(1.1rem, 1.6vw, 1.32rem); }
p  { margin: 0; }

:focus-visible {
  outline: 2px solid var(--teal-600);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 导航 ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  background: rgba(10, 37, 64, 0.82);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease);
}
.nav--solid {
  background: rgba(7, 26, 47, 0.96);
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.nav__inner {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav__brand {
  display: flex;
  align-items: center;
  height: 40px;
  flex-shrink: 0;
}
.nav__brand img { height: 100%; width: auto; }

.nav__menu {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  flex: 1;
}

.nav__link {
  position: relative;
  display: block;
  padding: 10px 16px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.76);
  border-radius: 8px;
  transition: color 0.22s var(--ease), background 0.22s var(--ease);
}
.nav__link:hover { color: var(--white); background: rgba(255, 255, 255, 0.08); }
.nav__link[aria-current="page"] { color: var(--white); font-weight: 600; }
.nav__link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 16px; right: 16px; bottom: 4px;
  height: 2px;
  border-radius: 2px;
  background: var(--teal-500);
}

/* 外链项（淂翼卡）：金色小圆点标识，区别于站内栏目 */
.nav__link--ext { display: inline-flex; align-items: center; gap: 6px; }
.nav__link--ext::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #C9A961;
  transition: background 0.22s var(--ease);
}
.nav__link--ext:hover::before { background: #E8D3A4; }

.nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 20px;
  border-radius: 10px;
  background: var(--teal-500);
  color: var(--navy-900);
  font-size: 14.5px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.22s var(--ease), background 0.22s var(--ease),
              box-shadow 0.22s var(--ease);
}
.nav__cta:hover {
  background: #16E0B8;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px -8px rgba(0, 212, 170, 0.7);
}
.nav__cta:active { transform: scale(0.97); }

.nav__toggle {
  display: none;
  width: 42px; height: 42px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: var(--white);
  transition: background 0.22s var(--ease);
}
.nav__toggle:hover { background: rgba(255, 255, 255, 0.1); }
.nav__toggle svg { width: 22px; height: 22px; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 52px;
  padding: 0 28px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease),
              background 0.22s var(--ease), color 0.22s var(--ease),
              border-color 0.22s var(--ease);
}
.btn:active { transform: scale(0.98); }

.btn--primary {
  background: var(--teal-500);
  color: var(--navy-900);
  box-shadow: 0 10px 26px -12px rgba(0, 212, 170, 0.8);
}
.btn--primary:hover {
  background: #16E0B8;
  transform: translateY(-2px);
  box-shadow: 0 16px 34px -14px rgba(0, 212, 170, 0.9);
}

.btn--ghost {
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: var(--white);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.btn--ghost:hover {
  border-color: var(--teal-500);
  color: var(--teal-500);
  transform: translateY(-2px);
}

.btn--dark {
  background: var(--navy-800);
  color: var(--white);
}
.btn--dark:hover {
  background: var(--navy-700);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -14px rgba(10, 37, 64, 0.6);
}

.btn--line {
  border: 1px solid var(--line);
  color: var(--ink-700);
  background: var(--white);
}
.btn--line:hover {
  border-color: var(--teal-600);
  color: var(--teal-700);
  transform: translateY(-2px);
}

.btn svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ---------- 区块通用 ---------- */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section--tight { padding: clamp(48px, 6vw, 76px) 0; }
.section--dark {
  background: var(--navy-800);
  color: rgba(255, 255, 255, 0.78);
  position: relative;
  overflow: hidden;
}
.section--dark h2, .section--dark h3 { color: var(--white); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--teal-700);
  text-transform: uppercase;
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 2px;
  border-radius: 2px;
  background: var(--teal-500);
}
.section--dark .eyebrow { color: var(--teal-500); }

.lede {
  margin-top: 18px;
  max-width: 62ch;
  font-size: 17px;
  line-height: 1.8;
  color: var(--ink-500);
}
.section--dark .lede { color: rgba(255, 255, 255, 0.68); }

.head { max-width: 780px; }
.head--center { margin: 0 auto; text-align: center; }
.head--center .lede { margin-inline: auto; }
.head--center .eyebrow { justify-content: center; }

/* ---------- 卡片 ---------- */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  transition: transform 0.32s var(--ease), box-shadow 0.32s var(--ease),
              border-color 0.32s var(--ease);
}
.card:hover {
  transform: translateY(-4px);
  border-color: #C7D6E4;
  box-shadow: 0 18px 40px -22px rgba(10, 37, 64, 0.28);
}
.card h3 { margin-bottom: 12px; }
.card p { color: var(--ink-500); font-size: 15px; }

.grid { display: grid; gap: 22px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ---------- 标签 ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 11px;
  border-radius: 6px;
  background: var(--teal-50);
  color: var(--teal-700);
  font-size: 12.5px;
  font-weight: 600;
}
.tag--dark {
  background: rgba(0, 212, 170, 0.14);
  color: var(--teal-500);
  border: 1px solid rgba(0, 212, 170, 0.28);
}

/* ---------- 滚动入场 ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }

/* JS 未执行时（禁用脚本 / 抓取器 / 打印）直接显示，绝不留白 */
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- 页脚 ---------- */
.footer {
  background: var(--navy-900);
  color: rgba(255, 255, 255, 0.56);
  padding: 68px 0 32px;
  font-size: 14px;
}
.footer__top {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 48px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}
.footer__brand img { height: 44px; width: auto; margin-bottom: 18px; }
.footer__brand p { max-width: 34ch; line-height: 1.8; }
.footer__col h4 {
  color: var(--white);
  font-size: 14.5px;
  margin-bottom: 18px;
  letter-spacing: 0;
}
.footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer__col a { transition: color 0.2s var(--ease); }
.footer__col a:hover { color: var(--teal-500); }
.footer__bottom {
  padding-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.42);
}
/* ICP 备案号：使用工信部官方图标（本地 assets/images/beian.png），链接至官方查询入口 */
.footer__icp {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: rgba(255, 255, 255, 0.52);
  transition: color 0.2s var(--ease);
}
.footer__icp img {
  height: 16px;
  width: auto;
  flex-shrink: 0;
}
.footer__icp:hover { color: var(--teal-500); }

/* ---------- 响应式 ---------- */
@media (max-width: 1080px) {
  .nav__menu { gap: 0; }
  .nav__link { padding: 10px 11px; font-size: 14.5px; }
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__top { grid-template-columns: 1fr 1fr; gap: 36px; }
}

@media (max-width: 860px) {
  :root { --nav-h: 64px; }
  .nav__toggle { display: flex; }
  .nav__cta { display: none; }

  .nav__menu {
    position: fixed;
    inset: var(--nav-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 14px 24px 22px;
    background: rgba(7, 26, 47, 0.985);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease),
                visibility 0.3s;
    max-height: calc(100dvh - var(--nav-h));
    overflow-y: auto;
  }
  .nav__menu.is-open {
    transform: none;
    opacity: 1;
    visibility: visible;
  }
  .nav__link { padding: 14px 12px; font-size: 16px; }
  .nav__link[aria-current="page"]::after { left: 12px; right: auto; width: 18px; }

  .grid--2, .grid--3 { grid-template-columns: 1fr; }
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__top { grid-template-columns: 1fr; gap: 32px; }
  .footer__bottom { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 520px) {
  .grid--4 { grid-template-columns: 1fr; }
  .wrap { padding: 0 18px; }
  .card { padding: 24px; }
}