:root {
  --bg: #0f1720;
  --panel: #ffffff;
  --ink: #1b2430;
  --muted: #5b6b7c;
  --line: #e4e9ef;
  --accent: #0f8a5f;
  --accent-ink: #ffffff;
  --accent-soft: #e8f6ef;
  --warn: #8a6d0f;
  --warn-bg: #fdf6e3;
  --radius: 12px;
  --maxw: 1080px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: #f6f8fa;
  color: var(--ink);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Roboto, Helvetica, Arial, sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header {
  background: var(--bg);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 20;
}
.site-header .container { display: flex; align-items: center; gap: 18px; min-height: 60px; flex-wrap: wrap; }
.brand { font-weight: 800; letter-spacing: .5px; color: #fff; font-size: 18px; }
.brand:hover { text-decoration: none; }
.site-nav { display: flex; gap: 16px; flex-wrap: wrap; margin-left: auto; }
.site-nav a { color: #cfd8e3; font-size: 14.5px; }
.site-nav a:hover { color: #fff; text-decoration: none; }
.lang-switch {
  border: 1px solid #3a4756; color: #cfd8e3; border-radius: 999px;
  padding: 4px 12px; font-size: 13px;
}
.lang-switch:hover { color: #fff; border-color: #6b7a8c; text-decoration: none; }

/* Hero */
.hero { background: var(--bg); color: #fff; padding: 54px 0 46px; }
.hero h1 { font-size: 34px; line-height: 1.25; margin: 0 0 12px; }
.hero p { color: #b9c4d0; font-size: 16.5px; margin: 0 0 22px; max-width: 620px; }
.btn {
  display: inline-block; border-radius: 10px; padding: 11px 20px;
  font-weight: 600; font-size: 15px; border: 1px solid transparent; cursor: pointer;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { text-decoration: none; filter: brightness(1.06); }
.btn-ghost { background: transparent; color: #fff; border-color: #3a4756; }
.btn-ghost:hover { text-decoration: none; border-color: #6b7a8c; }

/* Sections */
main { display: block; }
section { padding: 40px 0; }
.section-title { font-size: 22px; margin: 0 0 18px; }
.section-sub { color: var(--muted); margin: -10px 0 20px; }

.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px;
}

/* Broker grid */
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.broker-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; }
.broker-card h3 { margin: 0 0 6px; font-size: 18px; }
.broker-card .one-liner { color: var(--muted); font-size: 14px; margin: 0 0 14px; flex: 1; }
.kv { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 5px 0; border-top: 1px dashed var(--line); }
.kv .k { color: var(--muted); }
.kv .v { font-weight: 600; text-align: right; }
.badge {
  display: inline-block; background: var(--accent-soft); color: var(--accent);
  border-radius: 999px; padding: 2px 10px; font-size: 12px; font-weight: 600;
}
.badge-pending { background: var(--warn-bg); color: var(--warn); }
.card-actions { margin-top: 14px; display: flex; gap: 10px; }

/* Table */
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
th, td { text-align: left; padding: 11px 13px; font-size: 14px; border-bottom: 1px solid var(--line); }
th { background: #f0f3f7; color: var(--muted); font-weight: 600; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }

/* Flow */
.flow { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); counter-reset: step; }
.flow .step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.flow .step .n { display: inline-flex; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.flow .step h4 { margin: 0 0 6px; font-size: 15px; }
.flow .step p { margin: 0; color: var(--muted); font-size: 13.5px; }

/* Calculator */
.calc { display: grid; gap: 16px; grid-template-columns: 1.2fr 1fr; align-items: start; }
.calc .card { padding: 22px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 6px; }
.field input, .field select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line);
  border-radius: 9px; font-size: 15px; background: #fff; color: var(--ink);
}
.result-box { background: var(--accent-soft); border: 1px solid #cbe9dc; border-radius: var(--radius); padding: 22px; }
.result-box .label { color: var(--muted); font-size: 13.5px; }
.result-box .value { font-size: 34px; font-weight: 800; color: var(--accent); margin: 4px 0 8px; }
.note { color: var(--muted); font-size: 12.5px; }

/* Prose */
.prose { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.prose h2 { font-size: 19px; margin: 22px 0 10px; }
.prose p, .prose li { color: #2c3846; }
.prose ul { padding-left: 20px; }

/* Breadcrumbs */
.crumbs { font-size: 13px; color: var(--muted); padding: 14px 0 0; }
.crumbs a { color: var(--muted); }

/* Notice */
.notice { background: var(--warn-bg); border: 1px solid #f0e2b8; color: #6b5510; border-radius: var(--radius); padding: 14px 16px; font-size: 13.5px; }

/* Footer */
.site-footer { background: #0b111a; color: #93a1b1; padding: 34px 0; margin-top: 40px; font-size: 13.5px; }
.site-footer a { color: #c4d0dc; }
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 12px; }
.footer-disclaimer { max-width: 760px; line-height: 1.6; }

@media (max-width: 720px) {
  .hero h1 { font-size: 26px; }
  .calc { grid-template-columns: 1fr; }
  .site-nav { gap: 12px; }
}
