/* =============================================
   火速贷 - 前台样式（基于原型2设计语言）
   ============================================= */
:root {
  --bg: #f0f4fc;
  --surface: #fafbfd;
  --card: #ffffff;
  --text: #0f1f3d;
  --text-secondary: #3d4f6f;
  --muted: #647196;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-soft: rgba(37, 99, 235, 0.09);
  --accent: #059669;
  --border: rgba(15, 31, 61, 0.08);
  --border-strong: rgba(37, 99, 235, 0.18);
  --shadow-sm: 0 1px 2px rgba(15, 31, 61, 0.04);
  --shadow-md: 0 4px 20px rgba(15, 31, 61, 0.06);
  --shadow-lg: 0 16px 48px rgba(37, 99, 235, 0.1);
  --radius: 16px;
  --radius-sm: 12px;
  --radius-lg: 22px;
  --font: "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--text);
  line-height: 1.65;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 120% 80% at 50% -30%, rgba(37,99,235,0.14), transparent 55%),
    radial-gradient(ellipse 70% 50% at 100% 0%, rgba(5,150,105,0.06), transparent 45%),
    linear-gradient(180deg, #eef3fb 0%, #f4f6fb 40%, #eef1f8 100%);
  background-attachment: fixed;
}

a { color: inherit; text-decoration: none; }

.container { width: min(1160px, 92%); margin: 0 auto; }

/* ---- Topbar ---- */
.topbar {
  background: linear-gradient(90deg, #0c1e4a 0%, #132a5c 50%, #0f2454 100%);
  color: rgba(230,238,255,0.92);
  font-size: 13px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.topbar .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.topbar .left span { margin-right: 18px; opacity: 0.95; }

/* ---- Navbar ---- */
.navbar {
  position: sticky; top: 0; z-index: 30;
  backdrop-filter: saturate(180%) blur(16px);
  background: rgba(255,255,255,0.82);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.nav-wrap { height: 68px; display: flex; justify-content: space-between; align-items: center; }
.brand { font-size: 21px; font-weight: 800; letter-spacing: -0.02em; color: var(--text); }
.brand small { color: var(--primary); font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.85; }
.nav-links { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; }
.nav-links a { color: var(--text-secondary); font-weight: 600; font-size: 14px; padding: 8px 14px; border-radius: 999px; transition: color 0.2s, background 0.2s; }
.nav-links a:hover, .nav-links a.active { color: var(--primary); background: var(--primary-soft); }

/* ---- Buttons ---- */
.btn { border: none; border-radius: 999px; padding: 12px 22px; font-size: 14px; font-weight: 700; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s, background 0.2s; display: inline-flex; align-items: center; gap: 8px; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 4px 14px rgba(37,99,235,0.25); }
.btn-primary:hover { background: var(--primary-hover); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(37,99,235,0.3); }
.btn-outline { background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.35); color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.5); }
.btn-ghost { background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); border-radius: var(--radius-sm); padding: 8px 14px; font-size: 13px; font-weight: 700; cursor: pointer; transition: border-color 0.2s, color 0.2s; }
.btn-ghost:hover { border-color: rgba(37,99,235,0.3); color: var(--primary); }
.btn-small { border: 1px solid var(--border); background: var(--surface); color: var(--text-secondary); border-radius: var(--radius-sm); padding: 8px 14px; font-size: 13px; font-weight: 700; cursor: pointer; transition: background 0.2s, border-color 0.2s, color 0.2s; }
.btn-small:hover { border-color: rgba(37,99,235,0.3); color: var(--primary); background: #fff; }
.btn-small.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-small.primary:hover { background: var(--primary-hover); transform: translateY(-1px); }

/* ---- Hero ---- */
.hero { padding: 48px 0 32px; }
.hero-grid { display: grid; grid-template-columns: 1.12fr 0.88fr; gap: 20px; align-items: stretch; }
.hero-main {
  background: linear-gradient(145deg, #1e4ed8 0%, #1d3fad 42%, #152c78 100%);
  color: #fff; border-radius: var(--radius-lg); padding: 40px 36px;
  box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
  border: 1px solid rgba(255,255,255,0.12);
}
.hero-main::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 85% 15%, rgba(56,189,248,0.35), transparent 42%),
    radial-gradient(circle at 10% 90%, rgba(99,102,241,0.25), transparent 40%);
  pointer-events: none;
}
.hero-main h1 { font-size: clamp(26px,4vw,36px); line-height: 1.22; margin-bottom: 16px; position: relative; z-index: 1; font-weight: 800; letter-spacing: -0.03em; }
.hero-main p { color: rgba(226,236,255,0.92); max-width: 34em; margin-bottom: 24px; position: relative; z-index: 1; font-size: 15px; line-height: 1.7; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; position: relative; z-index: 1; }
.hero-stats { display: grid; grid-template-columns: repeat(2,1fr); gap: 14px; }
.stat-card { background: var(--card); border-radius: var(--radius); padding: 20px 18px; box-shadow: var(--shadow-md); border: 1px solid var(--border); min-height: 112px; transition: box-shadow 0.25s, border-color 0.25s, transform 0.25s; }
.stat-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.stat-title { color: var(--muted); font-size: 12px; margin-bottom: 8px; font-weight: 600; letter-spacing: 0.02em; }
.stat-value { font-size: clamp(22px,3vw,28px); font-weight: 800; color: var(--text); letter-spacing: -0.03em; }

/* ---- Section ---- */
.section { padding: 28px 0; }
.section-title { font-size: clamp(22px,2.5vw,26px); margin-bottom: 10px; font-weight: 800; color: var(--text); letter-spacing: -0.03em; }
.section-sub { color: var(--muted); margin-bottom: 22px; max-width: 52em; font-size: 15px; line-height: 1.65; }

/* ---- Panel ---- */
.panel { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); box-shadow: var(--shadow-md); padding: 24px 26px; }
.panel > h3:first-child { font-size: 17px; font-weight: 800; color: var(--text); margin-bottom: 4px; letter-spacing: -0.02em; }

/* ---- Chip ---- */
.chip-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.chip { border: 1px solid var(--border); border-radius: 999px; padding: 8px 16px; font-size: 13px; color: var(--text-secondary); cursor: pointer; user-select: none; background: var(--surface); transition: background 0.2s, border-color 0.2s, color 0.2s; }
.chip:hover { border-color: rgba(37,99,235,0.25); color: var(--primary); }
.chip.active { background: var(--primary-soft); border-color: var(--border-strong); color: var(--primary-hover); font-weight: 700; }

/* ---- Tag / Badge ---- */
.tag { font-size: 11px; padding: 4px 10px; border-radius: 999px; background: var(--primary-soft); color: var(--primary-hover); border: 1px solid rgba(37,99,235,0.15); font-weight: 600; }
.badge { display: inline-flex; align-items: center; justify-content: center; min-width: 76px; height: 30px; border-radius: 999px; font-size: 12px; font-weight: 700; padding: 0 10px; border: 1px solid; }
.badge.ok { color: #0b7c58; background: #e7faf3; border-color: #8ce0bf; }
.badge.warn { color: #9a6400; background: #fff6e4; border-color: #ffd085; }
.badge.risk { color: #a81e34; background: #ffecef; border-color: #ffc1cb; }

/* ---- 产品列表卡片（行式） ---- */
.list-grid { display: grid; gap: 14px; margin-top: 20px; }
.loan-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; display: grid; grid-template-columns: 1.2fr 1fr 0.8fr 0.8fr auto; gap: 14px; align-items: center; background: linear-gradient(180deg,#fff 0%,#fafbfd 100%); transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s; }
.loan-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.loan-name { font-size: 16px; font-weight: 800; color: var(--text); margin-bottom: 6px; letter-spacing: -0.02em; }
.loan-name a { color: inherit; transition: color 0.2s; }
.loan-name a:hover { color: var(--primary); }
.loan-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.metric .k { color: var(--muted); font-size: 12px; margin-bottom: 4px; }
.metric .v { font-size: 17px; font-weight: 800; color: var(--text); letter-spacing: -0.02em; }
.loan-actions { display: flex; gap: 8px; justify-content: flex-end; }

/* ---- 筛选表单 ---- */
.filter-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 14px; margin-bottom: 14px; }
.field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 7px; font-weight: 600; }
.field input, .field select { width: 100%; height: 46px; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0 14px; outline: none; color: var(--text); background: var(--surface); font-size: 14px; transition: border-color 0.2s, box-shadow 0.2s; }
.field input:focus, .field select:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); background: #fff; }

/* ---- 信用卡板块 ---- */
.cc-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(260px,1fr)); gap: 16px; }
.cc-card { border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); overflow: hidden; transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s; display: flex; flex-direction: column; }
.cc-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.cc-card-header { padding: 18px 18px 14px; display: flex; align-items: flex-start; gap: 14px; border-bottom: 1px solid var(--border); }
.cc-logo { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 800; flex-shrink: 0; color: #fff; }
.cc-logo.cmb  { background: linear-gradient(135deg,#c0392b,#e74c3c); }
.cc-logo.icbc { background: linear-gradient(135deg,#c0392b,#922b21); }
.cc-logo.boc  { background: linear-gradient(135deg,#1a5276,#2980b9); }
.cc-logo.ccb  { background: linear-gradient(135deg,#1e8449,#27ae60); }
.cc-logo.spdb { background: linear-gradient(135deg,#6c3483,#9b59b6); }
.cc-logo.citic { background: linear-gradient(135deg,#d35400,#e67e22); }
.cc-logo.ceb  { background: linear-gradient(135deg,#1a5276,#117a65); }
.cc-info { flex: 1; min-width: 0; }
.cc-name { font-size: 15px; font-weight: 800; color: var(--text); letter-spacing: -0.02em; margin-bottom: 4px; }
.cc-bank { font-size: 12px; color: var(--muted); font-weight: 600; }
.cc-body { padding: 12px 18px; flex: 1; }
.cc-perks { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.cc-perk { font-size: 11px; padding: 3px 9px; border-radius: 999px; background: var(--primary-soft); color: var(--primary-hover); border: 1px solid rgba(37,99,235,0.15); font-weight: 600; }
.cc-perk.green { background: rgba(5,150,105,0.08); color: #065f46; border-color: rgba(5,150,105,0.2); }
.cc-perk.orange { background: rgba(217,119,6,0.08); color: #92400e; border-color: rgba(217,119,6,0.2); }
.cc-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.55; }
.cc-footer { padding: 12px 18px; border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cc-reward { font-size: 12px; color: var(--muted); }
.cc-reward strong { color: #b45309; font-size: 14px; }

/* ---- 文章卡片 ---- */
.content-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.content-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; background: var(--card); transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s; }
.content-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.content-card h4 { color: var(--text); margin-bottom: 8px; font-size: 16px; font-weight: 800; letter-spacing: -0.02em; }
.content-card p { color: #5f7398; font-size: 14px; margin-bottom: 10px; }
.content-link { display: inline-block; color: var(--primary); font-size: 13px; font-weight: 700; margin-top: 4px; }
.content-link:hover { color: var(--primary-hover); text-decoration: underline; text-underline-offset: 3px; }
.content-meta { font-size: 12px; color: var(--muted); margin-top: 8px; }

/* ---- 产品详情页 ---- */
.detail-layout { display: grid; grid-template-columns: 1fr 300px; gap: 24px; padding: 28px 0; }
.detail-main { min-width: 0; }
.detail-header { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 28px; margin-bottom: 20px; }
.detail-header h1 { font-size: clamp(22px,3vw,28px); font-weight: 800; letter-spacing: -0.03em; margin-bottom: 12px; }
.detail-meta { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.detail-kpi { display: grid; grid-template-columns: repeat(2,1fr); gap: 14px; margin-bottom: 20px; }
.kpi-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; }
.kpi-item .k { font-size: 12px; color: var(--muted); margin-bottom: 6px; font-weight: 600; }
.kpi-item .v { font-size: 22px; font-weight: 800; color: var(--primary-hover); letter-spacing: -0.02em; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.detail-body { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 28px; margin-bottom: 20px; }
.detail-body h2 { font-size: 18px; font-weight: 800; margin-bottom: 14px; letter-spacing: -0.02em; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.detail-body p { color: var(--text-secondary); font-size: 15px; line-height: 1.75; margin-bottom: 12px; }
.detail-sidebar {}
.sidebar-panel { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 20px; margin-bottom: 16px; }
.sidebar-panel h3 { font-size: 15px; font-weight: 800; margin-bottom: 14px; letter-spacing: -0.02em; }
.recommend-list { display: grid; gap: 10px; }
.recommend-item { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; background: var(--surface); transition: border-color 0.2s; }
.recommend-item:hover { border-color: var(--border-strong); }
.recommend-item a { font-size: 14px; font-weight: 700; color: var(--text); }
.recommend-item a:hover { color: var(--primary); }
.recommend-item .sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.apply-cta { background: linear-gradient(135deg, var(--primary) 0%, #1d4ed8 100%); border-radius: var(--radius-lg); padding: 24px; text-align: center; color: #fff; }
.apply-cta h3 { font-size: 16px; font-weight: 800; margin-bottom: 8px; }
.apply-cta p { font-size: 13px; opacity: 0.85; margin-bottom: 16px; }
.apply-cta a { display: block; background: #fff; color: var(--primary-hover); padding: 12px; border-radius: 999px; font-weight: 700; font-size: 14px; transition: transform 0.2s; }
.apply-cta a:hover { transform: translateY(-2px); }

/* ---- 文章详情页 ---- */
.article-layout { display: grid; grid-template-columns: 1fr 280px; gap: 24px; padding: 28px 0; }
.article-header { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 28px; margin-bottom: 20px; }
.article-header h1 { font-size: clamp(20px,3vw,26px); font-weight: 800; letter-spacing: -0.03em; margin-bottom: 12px; }
.article-body { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 28px; line-height: 1.8; color: var(--text-secondary); font-size: 15px; }
.article-body h2 { font-size: 20px; font-weight: 800; color: var(--text); margin: 24px 0 12px; }
.article-body h3 { font-size: 17px; font-weight: 700; color: var(--text); margin: 18px 0 10px; }
.article-body p { margin-bottom: 14px; }
.article-body ul, .article-body ol { padding-left: 20px; margin-bottom: 14px; }
.article-body li { margin-bottom: 6px; }

/* ---- 面包屑 ---- */
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); padding: 16px 0 8px; }
.breadcrumb a { color: var(--muted); transition: color 0.2s; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb i { font-size: 10px; }

/* ---- 分页 ---- */
.pagination { display: flex; justify-content: center; gap: 8px; margin: 28px 0; }
.pagination a, .pagination span { display: flex; align-items: center; justify-content: center; min-width: 38px; height: 38px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 14px; font-weight: 600; color: var(--text-secondary); transition: all 0.2s; padding: 0 10px; }
.pagination a:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.pagination .current { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ---- 单页面 ---- */
.page-layout { max-width: 800px; margin: 0 auto; padding: 28px 0; }
.page-body { background: var(--card); border-radius: var(--radius-lg); border: 1px solid var(--border); padding: 36px; line-height: 1.8; color: var(--text-secondary); font-size: 15px; }
.page-body h1 { font-size: 26px; font-weight: 800; color: var(--text); margin-bottom: 20px; letter-spacing: -0.03em; }
.page-body h2 { font-size: 18px; font-weight: 800; color: var(--text); margin: 24px 0 10px; }
.page-body p { margin-bottom: 14px; }

/* ---- Result / Info box ---- */
.result-box { padding: 14px 16px; border-radius: var(--radius-sm); background: linear-gradient(135deg,rgba(37,99,235,0.06) 0%,rgba(5,150,105,0.04) 100%); border: 1px solid rgba(37,99,235,0.12); color: var(--text-secondary); font-size: 14px; line-height: 1.65; }
.empty { padding: 22px; border: 1px dashed rgba(37,99,235,0.22); border-radius: var(--radius-sm); color: var(--muted); background: var(--surface); text-align: center; font-size: 14px; }

/* ---- Toast ---- */
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(16px); opacity: 0; transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.4,0,0.2,1); background: linear-gradient(135deg,#0f2744 0%,#1e3a5f 100%); color: #fff; font-size: 13px; padding: 12px 20px; border-radius: 999px; z-index: 100; pointer-events: none; box-shadow: 0 8px 32px rgba(15,31,61,0.35); border: 1px solid rgba(255,255,255,0.1); }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---- 浮动按钮（右侧垂直居中） ---- */
.floating-contact {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.float-btn {
  background: linear-gradient(135deg, var(--primary) 0%, #1d4ed8 100%);
  color: #fff;
  border-radius: 8px 0 0 8px;
  border: none;
  padding: 12px 10px;
  font-size: 12px;
  font-weight: 700;
  writing-mode: vertical-rl;
  letter-spacing: 0.1em;
  box-shadow: -4px 0 16px rgba(37,99,235,0.25);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
  white-space: nowrap;
}
.float-btn:hover {
  transform: translateX(-4px);
  box-shadow: -6px 0 20px rgba(37,99,235,0.35);
}
.float-btn.accent {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  box-shadow: -4px 0 16px rgba(5,150,105,0.25);
}
.float-btn.accent:hover {
  box-shadow: -6px 0 20px rgba(5,150,105,0.35);
}

/* ---- Footer ---- */
.footer { margin-top: 40px; background: linear-gradient(180deg,#0f2744 0%,#0a1628 100%); color: rgba(214,226,248,0.88); padding: 36px 0 20px; font-size: 13px; border-top: 1px solid rgba(255,255,255,0.06); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 28px; margin-bottom: 28px; }
.footer-col h4 { color: #fff; font-size: 14px; font-weight: 700; margin-bottom: 12px; }
.footer-col p, .footer-col a { font-size: 13px; color: rgba(214,226,248,0.65); line-height: 1.9; display: block; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.07); padding-top: 16px; text-align: center; font-size: 12px; color: rgba(214,226,248,0.45); }

/* ---- 响应式 ---- */
@media (max-width: 1050px) {
  .hero-grid, .detail-layout, .article-layout { grid-template-columns: 1fr; }
  .content-grid { grid-template-columns: repeat(2,1fr); }
  .filter-grid { grid-template-columns: 1fr 1fr; }
  .loan-card { grid-template-columns: 1fr 1fr 1fr; }
}
@media (max-width: 780px) {
  .nav-links { display: none; }
  .loan-card { grid-template-columns: 1fr; }
  .loan-actions { justify-content: flex-start; }
  .content-grid { grid-template-columns: 1fr; }
  .detail-kpi { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .filter-grid { grid-template-columns: 1fr; }
  .hero-main { padding: 32px 22px; }
  .detail-kpi { grid-template-columns: 1fr; }
}

/* ---- Hero 专属按钮（深色背景上使用） ---- */
.btn-hero-primary {
  background: #fff;
  color: var(--primary-hover);
  box-shadow: 0 4px 14px rgba(0,0,0,0.12);
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-hero-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.15); }

.btn-hero-outline {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  border-radius: 999px;
  padding: 12px 22px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s, border-color 0.2s;
}
.btn-hero-outline:hover { background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.5); }

/* ---- 贷款工具板块 ---- */
.tools-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.tools-form { display: grid; gap: 12px; margin-top: 14px; }
.alert-box { margin-top: 10px; border-radius: 10px; border: 1px solid #ffe1b3; background: #fff8ec; color: #8b5b00; padding: 10px 12px; font-size: 14px; display: none; }
.alert-box.show { display: block; }

@media (max-width: 780px) {
  .tools-grid { grid-template-columns: 1fr; }
}

/* ---- 工具板块内部布局 ---- */
.wizard-grid { display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 12px; align-items: end; margin-top: 14px; }
@media (max-width: 900px) { .wizard-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .wizard-grid { grid-template-columns: 1fr; } }

/* 工具板块按钮（深色背景下用白色，这里在白色panel内用蓝色） */
.btn-tool-primary { background: var(--primary); color: #fff; border: none; border-radius: 999px; padding: 12px 20px; font-size: 14px; font-weight: 700; cursor: pointer; transition: background 0.2s, transform 0.2s; white-space: nowrap; }
.btn-tool-primary:hover { background: var(--primary-hover); transform: translateY(-1px); }

/* ---- 对比清单 ---- */
.compare-item { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 14px; display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--surface); transition: border-color 0.2s; }
.compare-item:hover { border-color: rgba(37,99,235,0.2); }
.compare-list { display: grid; gap: 8px; margin-top: 8px; }

/* ---- 对比表格 ---- */
.mini-table { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 13px; }
.mini-table th, .mini-table td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; color: var(--text-secondary); }
.mini-table th { background: var(--surface); font-weight: 700; color: var(--text); font-size: 12px; }
.mini-table tr:nth-child(even) td { background: rgba(250,251,253,0.8); }

/* ---- FAQ ---- */
.faq-item { border-top: 1px solid #e9eef8; padding: 12px 0; }
.faq-item:first-child { border-top: none; }
.faq-q { cursor: pointer; font-weight: 700; color: var(--text); padding: 4px 0; transition: color 0.2s; user-select: none; }
.faq-q:hover { color: var(--primary); }
.faq-a { margin-top: 8px; color: #5f7398; font-size: 14px; line-height: 1.65; display: none; }
.faq-item.active .faq-a { display: block; }

/* ---- 回到顶部 ---- */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 42px;
  height: 42px;
  background: rgba(15,31,61,0.55);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s, background 0.2s, transform 0.2s;
  z-index: 65;
  backdrop-filter: blur(6px);
}
.back-to-top.visible { opacity: 1; visibility: visible; }
.back-to-top:hover { background: var(--primary); transform: translateY(-3px); }

/* 信用卡 logo 通用色板（按首字哈希自动着色，后端渲染时 inline style 覆盖即可） */
.cc-logo { background: linear-gradient(135deg, #2563eb, #1d4ed8); }

/* 工具板块 4列自适应 */
@media (min-width: 1050px) {
  .tools-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---- 产品对比浮动栏 ---- */
.compare-bar {
  position: fixed;
  bottom: -100px;
  left: 0; right: 0;
  z-index: 60;
  transition: bottom 0.32s cubic-bezier(0.4,0,0.2,1);
  pointer-events: none;
}
.compare-bar.show { bottom: 0; pointer-events: none; }

.compare-bar-inner {
  max-width: 900px;
  margin: 0 auto;
  background: linear-gradient(135deg, #0f2744 0%, #1a3a6b 100%);
  border-radius: 16px 16px 0 0;
  border: 1px solid rgba(255,255,255,0.1);
  border-bottom: none;
  box-shadow: 0 -8px 32px rgba(15,31,61,0.25);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  pointer-events: auto;
}

.compare-bar-slots {
  display: flex;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.compare-slot {
  flex: 1;
  min-width: 0;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  font-size: 13px;
  gap: 6px;
}

.compare-slot.filled {
  background: rgba(37,99,235,0.35);
  border: 1px solid rgba(99,149,255,0.5);
  color: #fff;
  font-weight: 600;
}

.compare-slot.empty-slot {
  background: rgba(255,255,255,0.06);
  border: 1px dashed rgba(255,255,255,0.2);
  color: rgba(214,226,248,0.5);
  justify-content: center;
}

.compare-slot-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

.compare-slot-remove {
  background: none;
  border: none;
  color: rgba(214,226,248,0.6);
  font-size: 16px;
  cursor: pointer;
  padding: 0 2px;
  line-height: 1;
  flex-shrink: 0;
  transition: color 0.2s;
}
.compare-slot-remove:hover { color: #ff6b6b; }

.compare-bar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.compare-bar-count {
  font-size: 13px;
  color: rgba(214,226,248,0.7);
  white-space: nowrap;
}
.compare-bar-count strong { color: #fff; }

.btn-compare-open {
  background: #fff;
  color: var(--primary-hover);
  border: none;
  border-radius: 999px;
  padding: 9px 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.btn-compare-open:hover { background: #f0f4ff; transform: translateY(-1px); }

.btn-compare-clear {
  background: none;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 999px;
  padding: 9px 16px;
  font-size: 13px;
  color: rgba(214,226,248,0.7);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-compare-clear:hover { border-color: #ff6b6b; color: #ff6b6b; }

/* ---- 对比抽屉 ---- */
.compare-mask {
  position: fixed; inset: 0;
  background: rgba(15,31,61,0.4);
  z-index: 70;
  display: none;
}
.compare-mask.show { display: block; }

.compare-drawer {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  max-height: 70vh;
  background: #fff;
  border-radius: 20px 20px 0 0;
  z-index: 80;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
  display: flex;
  flex-direction: column;
  box-shadow: 0 -12px 40px rgba(15,31,61,0.15);
}
.compare-drawer.show { transform: translateY(0); }

.compare-drawer-head {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 16px;
  font-weight: 800;
  flex-shrink: 0;
}

.compare-drawer-body {
  padding: 16px 20px 24px;
  overflow: auto;
  flex: 1;
}

@media (max-width: 600px) {
  .compare-bar-slots { flex-direction: column; gap: 6px; }
  .compare-slot { height: 36px; }
}
