/* ================= 设计系统变量（蓝系 · 大厂标准版心规格：1200px） ================= */
:root {
  /* ---------- 背景：蓝调中性，H≈212 ---------- */
  --bg-page: #F6F9FC;        /* hsl(212, 54%, 97%) 页面底色，蓝调浅灰 */
  --bg-card: #FFFFFF;        /* 卡片纯白，与页面拉开层级 */
  --bg-subtle: #EAF1FA;      /* hsl(212, 60%, 95%) 分区/表头/占位底 */
  --bg-elevated: #FFFFFF;    /* 浮层/弹窗 */

  /* ---------- 文字：蓝黑渐进 ---------- */
  --text-primary: #121B26;   /* hsl(213, 35%, 11%) 深海军蓝黑，非纯黑 */
  --text-secondary: #33455C; /* hsl(215, 28%, 28%) */
  --text-muted: #57697F;     /* hsl(214, 18%, 42%) 在白底 5.2:1，过 AA */

  /* ---------- 品牌：直接引用基准 ---------- */
  --brand-primary: #3696FC;
  --brand-hover: #1C6CDC;
  --brand-deep: #0C5CAC;
  --brand-tint: rgba(54, 150, 252, 0.10);
  --brand-tint-strong: rgba(54, 150, 252, 0.16);
  --brand-ring: rgba(54, 150, 252, 0.38);   /* 新增：focus 外发光 */

  /* ---------- 边框：同色相半透明 ---------- */
  --border-subtle: rgba(18, 32, 50, 0.08);
  --border-strong: rgba(18, 32, 50, 0.14);
  --border-brand: rgba(54, 150, 252, 0.40); /* 新增：选中态描边 */

  /* ---------- 强调 / 语义 ---------- */
  --accent-warm: #C26A1A;                    /* 212° 互补橙，保持 */
  --accent-warm-bg: rgba(194, 106, 26, 0.10);
  --warn-boundary: #A8432E;                  /* 边界/危险，保持 */
  --warn-boundary-bg: rgba(168, 67, 46, 0.10);

  /* ---------- 阴影：蓝黑基色，去掉绿味 ---------- */
  --shadow-xs: 0 1px 2px rgba(15, 30, 50, 0.04);
  --shadow-sm: 0 4px 14px rgba(15, 30, 50, 0.05);
  --shadow-md: 0 10px 28px rgba(15, 30, 50, 0.07);
  --shadow-lg: 0 20px 44px rgba(15, 30, 50, 0.11);
  --shadow-fab: 0 10px 24px rgba(12, 92, 172, 0.30);  /* 用 brand-deep 投彩色阴影 */

  /* ---------- 圆角 ---------- */
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-full: 9999px;

  /* ---------- 字体 ---------- */
  --font-sans: "Plus Jakarta Sans", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-display: "Plus Jakarta Sans", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;

  /* ---------- 动效 ---------- */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.36, 0.64, 1);


  /* 大厂标准版心与断点间距规格 */
  --container-w: 1200px;
  --gutter-desktop: 24px;
  --gutter-tablet: 20px;
  --gutter-mobile: 16px;

  --header-h: 64px;
  --header-top-gap: 12px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scrollbar-gutter: stable;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 2px solid var(--brand-primary);
  outline-offset: 2px;
}

.icon { width: 20px; height: 20px; flex-shrink: 0; display: block; }

/* ================= 统一版心容器 ================= */
.container,
.subpage-wrap,
.assess-wrap {
  width: 100%;
  max-width: var(--container-w);
  margin-left: auto;
  margin-right: auto;
}

.container {
  padding-left: var(--gutter-desktop);
  padding-right: var(--gutter-desktop);
}

.subpage-wrap,
.assess-wrap {
  padding: 28px var(--gutter-desktop) 80px;
}

@media (max-width: 1024px) {
  .container {
    padding-left: var(--gutter-tablet);
    padding-right: var(--gutter-tablet);
  }
  .subpage-wrap,
  .assess-wrap {
    padding: 24px var(--gutter-tablet) 72px;
  }
}

@media (max-width: 640px) {
  .container {
    padding-left: var(--gutter-mobile);
    padding-right: var(--gutter-mobile);
  }
  .subpage-wrap,
  .assess-wrap {
    padding: 20px var(--gutter-mobile) 68px;
  }
}

/* ================= 悬浮非通栏顶部导航（与 1200px 版心对齐） ================= */
.floating-header-wrap {
  position: fixed;
  top: var(--header-top-gap);
  left: 0;
  right: 0;
  z-index: 900;
  padding-left: var(--gutter-desktop);
  padding-right: var(--gutter-desktop);
  pointer-events: none;
}
@media (max-width: 1024px) {
  .floating-header-wrap {
    padding-left: var(--gutter-tablet);
    padding-right: var(--gutter-tablet);
  }
}
@media (max-width: 640px) {
  .floating-header-wrap {
    padding-left: var(--gutter-mobile);
    padding-right: var(--gutter-mobile);
  }
}

.topbar.floating-header {
  position: relative;
  width: 100%;
  max-width: var(--container-w);
  height: var(--header-h);
  margin: 0 auto;
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.90);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.topbar-inner {
  width: 100%;
  height: 100%;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
@media (max-width: 640px) {
  .topbar-inner {
    padding: 0 14px;
  }
}

.brand { display: inline-flex; align-items: center; gap: 10px; user-select: none; }
.brand-mark { width: 32px; height: 32px; display: grid; place-items: center; flex-shrink: 0; }
.brand-text { display: flex; align-items: baseline; gap: 8px; }
.brand-name { font-family: var(--font-display); font-size: 18.5px; font-weight: 800; letter-spacing: -0.025em; color: var(--text-primary); }
.brand-tagline { font-size: 12px; font-weight: 500; color: var(--text-muted); letter-spacing: 0.01em; }
@media (max-width: 480px) { .brand-tagline { display: none; } }

.desktop-nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
  position: relative; padding: 8px 14px; border-radius: var(--radius-full);
  font-size: 14px; font-weight: 600; color: var(--text-secondary);
  transition: color 0.2s var(--ease-out), background 0.2s var(--ease-out);
  display: inline-flex; align-items: center; gap: 6px;
}
.nav-link:hover { color: var(--text-primary); background: var(--bg-subtle); }
.nav-link.active { color: var(--brand-deep); background: var(--brand-tint); }
.nav-link .icon { width: 16px; height: 16px; opacity: 0.85; }
.nav-link.active .icon { opacity: 1; color: var(--brand-primary); }

/* ================= 移动端汉堡按钮与内容宽度自适应下拉菜单 ================= */
.mobile-menu-anchor {
  position: relative;
  display: none;
}
@media (max-width: 820px) {
  .desktop-nav { display: none; }
  .mobile-menu-anchor { display: inline-flex; align-items: center; }
}

.burger-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  transition: background 0.2s var(--ease-out), color 0.2s var(--ease-out);
}
.burger-btn:hover { background: var(--bg-subtle); }
.burger-btn[aria-expanded="true"] { background: var(--brand-tint); color: var(--brand-deep); }

.burger-lines { width: 18px; height: 14px; display: flex; flex-direction: column; justify-content: space-between; }
.burger-lines span { display: block; height: 2px; width: 100%; border-radius: 2px; background: currentColor; transition: transform 0.25s var(--ease-out), opacity 0.2s; }
.burger-btn[aria-expanded="true"] .burger-lines span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger-btn[aria-expanded="true"] .burger-lines span:nth-child(2) { opacity: 0; }
.burger-btn[aria-expanded="true"] .burger-lines span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.mobile-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: max-content;
  min-width: 136px;
  max-width: calc(100vw - 32px);
  z-index: 910;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 6px;
}

.mobile-dropdown.open {
  display: block;
  animation: dropdownPop 0.2s var(--ease-out);
}

@keyframes dropdownPop {
  from {
    opacity: 0;
    transform: translateY(-6px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mobile-nav-item {
  width: auto;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
  text-align: left;
  transition: background 0.16s var(--ease-out), color 0.16s var(--ease-out);
}

.mobile-nav-item .icon {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

.mobile-nav-item:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
}

.mobile-nav-item.active {
  background: var(--brand-tint);
  color: var(--brand-deep);
}

.mobile-nav-item.active .icon {
  color: var(--brand-primary);
}

/* ================= 主体与区块节奏 ================= */
main {
  flex: 1;
  width: 100%;
  padding-top: calc(var(--header-h) + var(--header-top-gap) + 16px);
}

.view { display: none; animation: viewFade 0.28s var(--ease-out); }
.view.active { display: block; }
@keyframes viewFade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

.section { padding: 72px 0; }
@media (max-width: 1024px) { .section { padding: 60px 0; } }
@media (max-width: 640px) { .section { padding: 48px 0; } }

.section-head { margin-bottom: 36px; max-width: 680px; }
.section-kicker {
  font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--brand-deep); margin-bottom: 8px;
}
.section-title {
  font-family: var(--font-display); font-size: clamp(24px, 3.2vw, 34px);
  font-weight: 800; letter-spacing: -0.025em; line-height: 1.2; color: var(--text-primary);
}
.section-sub { margin-top: 10px; font-size: 15.5px; color: var(--text-muted); line-height: 1.65; }

.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 22px; border-radius: var(--radius-sm);
  background: var(--brand-primary); color: var(--bg-card);
  font-size: 15px; font-weight: 700; letter-spacing: -0.01em;
  box-shadow: 0 6px 18px rgba(54, 150, 252, 0.24);
  transition: transform 0.2s var(--ease-spring), background 0.2s var(--ease-out), box-shadow 0.2s;
}
.btn-primary:hover { background: var(--brand-hover); transform: translateY(-1px); box-shadow: 0 10px 22px rgba(54, 150, 252, 0.30); }
.btn-primary:active { transform: translateY(0) scale(0.99); }

.btn-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 20px; border-radius: var(--radius-sm);
  background: var(--bg-card); color: var(--text-primary);
  border: 1px solid var(--border-strong); font-size: 14.5px; font-weight: 600;
  box-shadow: var(--shadow-xs); transition: background 0.2s, border-color 0.2s, transform 0.2s var(--ease-spring);
}
.btn-secondary:hover { background: var(--bg-subtle); border-color: rgba(20, 32, 24, 0.22); transform: translateY(-1px); }

.subpage-head { margin-bottom: 28px; }

.quiz-card {
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-md);
}
@media (max-width: 640px) { .quiz-card { padding: 22px 18px; } }

.progress-bar { height: 6px; background: var(--bg-subtle); border-radius: var(--radius-full); overflow: hidden; margin-bottom: 24px; }
.progress-fill { height: 100%; background: var(--brand-primary); border-radius: var(--radius-full); transition: width 0.35s var(--ease-out); }

.ep-card {
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md); padding: 22px 24px; margin-bottom: 16px; box-shadow: var(--shadow-xs);
}
.ep-ext-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border-subtle); }
.ext-chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: var(--radius-full);
  background: var(--bg-subtle); color: var(--text-secondary); font-size: 12.5px; font-weight: 600;
  transition: background 0.18s, color 0.18s;
}
.ext-chip:hover { background: var(--brand-tint); color: var(--brand-deep); }

.note-item {
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md); padding: 26px 28px; margin-bottom: 18px; box-shadow: var(--shadow-xs);
}

/* ================= 浅色页脚（左 Logo+Witfly · 中横排菜单 · 右社交媒体 · 下版权与标语） ================= */
.site-footer.footer-light-bar {
  margin-top: auto;
  background: var(--bg-card);
  color: var(--text-primary);
  border-top: 1px solid var(--border-subtle);
  padding: 28px 0 24px;
}

.footer-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-subtle);
}

.footer-light-bar .footer-brand {
  color: var(--text-primary);
  flex-shrink: 0;
}

.footer-inline-nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-inline-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
  transition: color 0.18s var(--ease-out);
}

.footer-inline-link:hover,
.footer-inline-link.active {
  color: var(--brand-deep);
}

.footer-social-icons {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.footer-icon-link {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-subtle);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  transition: background 0.18s var(--ease-out), border-color 0.18s var(--ease-out), color 0.18s var(--ease-out), transform 0.18s var(--ease-spring);
}

.footer-icon-link:hover {
  background: var(--brand-tint);
  border-color: var(--brand-primary);
  color: var(--brand-deep);
  transform: translateY(-1px);
}

.footer-bottom {
  padding-top: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .footer-top-row {
    flex-direction: column;
    align-items: center;
    gap: 16px;
  }

  .footer-inline-nav {
    justify-content: center;
    gap: 14px 20px;
  }

  .footer-social-icons {
    justify-content: center;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
  }
}

/* ================= 图标按钮与弹窗 ================= */
.icon-action {
  width: 36px; height: 36px; border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--text-secondary); background: transparent;
  transition: background 0.18s, color 0.18s;
}
.icon-action:hover { background: var(--bg-subtle); color: var(--text-primary); }
.modal-close { width: 32px; height: 32px; border-radius: 50%; }

.copy-pill {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--bg-subtle); border: 1px solid var(--border-subtle);
  padding: 11px 14px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 600; color: var(--text-primary); word-break: break-all;
}
.copy-btn-sm { width: 32px; height: 32px; border-radius: 8px; background: var(--bg-card); border: 1px solid var(--border-subtle); flex-shrink: 0; }
.copy-btn-sm:hover { border-color: var(--brand-primary); color: var(--brand-deep); }

.qr-placeholder {
  width: 164px; height: 164px; margin: 4px auto 14px; border-radius: var(--radius-md);
  border: 1.5px dashed rgba(20, 32, 24, 0.2); background: var(--bg-subtle);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  color: var(--text-muted); font-size: 12px;
}

.modal-action-row { margin-top: 14px; display: flex; gap: 10px; }
.modal-action-row .btn-primary { flex: 1; height: 42px; font-size: 14px; }

.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 120;
  transform: translateX(-50%) translateY(16px);
  background: var(--text-primary); color: var(--bg-card);
  padding: 10px 18px; border-radius: var(--radius-full);
  font-size: 13.5px; font-weight: 600; opacity: 0; pointer-events: none;
  box-shadow: var(--shadow-lg); transition: opacity 0.2s, transform 0.25s var(--ease-out);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

