:root {
  --ink: #13231e;
  --ink-soft: #5d6b65;
  --paper: #f3f0e8;
  --cream: #fbf9f2;
  --line: #d8d4c9;
  --green: #0d3b2e;
  --green-2: #185a43;
  --jade: #2f8767;
  --gold: #c6a15b;
  --red: #d94b42;
  --blue: #377c9b;
  --shadow: 0 24px 70px rgba(24, 48, 39, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: "Microsoft YaHei", "Noto Sans SC", sans-serif; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1; opacity: .38;
  background-image: radial-gradient(rgba(19, 35, 30, .13) .55px, transparent .55px);
  background-size: 7px 7px;
}

.site-header { height: 78px; padding: 0 clamp(22px, 5vw, 78px); display: flex; align-items: center; gap: 42px; background: rgba(251,249,242,.94); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(16px); }
.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.brand-seal { width: 46px; height: 46px; display: grid; place-items: center; color: #f7ebcf; background: var(--green); border-radius: 4px 14px 4px 14px; font-family: STKaiti, KaiTi, serif; font-size: 18px; box-shadow: inset 0 0 0 2px rgba(255,255,255,.15); }
.brand strong, .brand small { display: block; }
.brand strong { font-family: STKaiti, KaiTi, serif; letter-spacing: .08em; font-size: 21px; }
.brand small { margin-top: 2px; color: var(--ink-soft); font: 9px/1.2 Georgia, serif; letter-spacing: .18em; }
nav { display: flex; gap: 30px; font-size: 14px; font-weight: 700; }
nav a { padding: 28px 0 24px; border-bottom: 3px solid transparent; }
nav a:hover { color: var(--jade); border-color: var(--gold); }
.market-status { color: var(--ink-soft); font-size: 12px; display: flex; align-items: center; gap: 8px; }
.market-status i, .online i { width: 8px; height: 8px; border-radius: 50%; background: var(--jade); box-shadow: 0 0 0 5px rgba(47,135,103,.12); }

.hero { min-height: 610px; display: grid; grid-template-columns: .92fr 1.08fr; gap: clamp(40px, 7vw, 110px); align-items: center; padding: 90px clamp(22px, 7vw, 110px) 64px; overflow: hidden; background: linear-gradient(135deg, #f8f4e9 0%, #efe9dc 100%); position: relative; }
.hero::after { content: "元"; position: absolute; left: 29%; top: 5%; color: rgba(13,59,46,.035); font: 520px/1 STKaiti, KaiTi, serif; pointer-events: none; }
.eyebrow { margin: 0 0 14px; color: var(--jade); font: 700 11px/1.4 Georgia, serif; letter-spacing: .19em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 24px; font-family: STKaiti, KaiTi, serif; font-size: clamp(45px, 5.2vw, 76px); line-height: 1.12; font-weight: 700; letter-spacing: .02em; }
h1 em { color: var(--green-2); font-style: normal; border-bottom: 5px solid var(--gold); }
.hero-intro { max-width: 610px; color: var(--ink-soft); font-size: 17px; line-height: 1.9; }
.hero-actions { display: flex; gap: 12px; margin-top: 34px; }
.button { border: 0; border-radius: 3px 13px 3px 13px; min-height: 44px; padding: 0 22px; display: inline-flex; justify-content: center; align-items: center; cursor: pointer; font-weight: 800; transition: transform .2s, box-shadow .2s, background .2s; }
.button:hover { transform: translateY(-2px); }
.button.primary { color: white; background: var(--green); box-shadow: 0 12px 28px rgba(13,59,46,.2); }
.button.secondary { color: var(--green); background: transparent; border: 1px solid var(--green); }
.button.buy { color: white; background: var(--red); }
.button.sell { color: white; background: var(--blue); }
.button.full { width: 100%; }

.hero-terminal { color: #e9f2ed; background: #102e25; border: 1px solid rgba(255,255,255,.12); border-radius: 6px 28px 6px 28px; padding: 24px; box-shadow: 26px 34px 0 #d2bd8d, var(--shadow); position: relative; z-index: 2; }
.hero-terminal::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(130deg, rgba(255,255,255,.07), transparent 40%); pointer-events: none; }
.terminal-top, .terminal-foot { display: flex; justify-content: space-between; color: #8eafa2; font: 10px/1.5 monospace; letter-spacing: .13em; }
.index-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 25px 0; }
.index-card { padding: 15px; background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.08); }
.index-card span, .index-card strong, .index-card small { display: block; }
.index-card span { color: #a9bdb5; font-size: 12px; }
.index-card strong { margin: 8px 0 3px; font: 23px/1.2 Georgia, serif; }
.index-card small { font-family: monospace; }
.up { color: var(--red) !important; }
.down { color: #48a8cf !important; }
.skeleton { height: 84px; background: linear-gradient(90deg, rgba(255,255,255,.04), rgba(255,255,255,.1), rgba(255,255,255,.04)); background-size: 200% 100%; animation: shimmer 1.5s infinite; }
#pulseChart { width: 100%; height: 150px; overflow: visible; }
.terminal-foot { margin-top: 12px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.08); }

.ticker-strip { min-height: 62px; display: flex; align-items: center; overflow-x: auto; color: #dce9e3; background: #0b2820; border-top: 1px solid rgba(255,255,255,.1); }
.ticker-item { min-width: 230px; padding: 0 26px; display: flex; justify-content: space-between; align-items: center; border-right: 1px solid rgba(255,255,255,.1); }
.ticker-item span { color: #8eafa2; font-size: 12px; }
.ticker-item strong { font-family: Georgia, serif; }

.workflow-dashboard { padding: 18px clamp(22px, 7vw, 110px); display: grid; grid-template-columns: 1.25fr repeat(5, 1fr); gap: 8px; color: #dce9e3; background: #102e25; border-top: 1px solid rgba(255,255,255,.08); }
.workflow-title { display: flex; flex-direction: column; justify-content: center; }
.workflow-title span { color: var(--gold); font: 9px Georgia, serif; letter-spacing: .16em; }
.workflow-title strong { margin-top: 5px; font: 20px STKaiti, KaiTi, serif; }
.workflow-step { min-height: 58px; padding: 9px 11px; display: flex; align-items: center; gap: 9px; background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.07); }
.workflow-step:hover { background: rgba(255,255,255,.1); }
.workflow-step i { width: 24px; height: 24px; flex: none; display: grid; place-items: center; color: #102e25; background: var(--gold); border-radius: 50%; font: 700 11px Georgia, serif; }
.workflow-step span { font-size: 11px; font-weight: 800; }
.workflow-step small { display: block; margin-top: 4px; color: #8eafa2; font-size: 9px; font-weight: 400; }

.history-section { background: #ebe7dc; }
.history-toolbar { display: grid; grid-template-columns: minmax(260px, 360px) auto 1fr; gap: 14px; align-items: end; padding: 20px; background: var(--cream); border: 1px solid var(--line); }
.history-toolbar .button { height: 46px; }
.history-source { min-height: 46px; display: flex; justify-content: flex-end; align-items: center; gap: 9px; color: var(--ink-soft); font-size: 11px; }
.history-source i { width: 8px; height: 8px; border-radius: 50%; background: var(--jade); }
.history-metrics { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin: 14px 0; }
.history-metrics article { padding: 18px; background: var(--cream); border: 1px solid var(--line); }
.history-metrics span { display: block; margin-bottom: 8px; color: var(--ink-soft); font-size: 11px; }
.history-metrics strong { font: 700 22px/1.2 Georgia, serif; }
.kline-shell { padding: 22px; background: #102e25; border-radius: 4px 18px 4px 18px; box-shadow: var(--shadow); }
.kline-shell .chart-title { color: #dce9e3; }
.kline-shell .chart-title span { color: #9ab0a7; }
#klineChart { width: 100%; height: 430px; display: block; margin-top: 12px; cursor: crosshair; touch-action: pan-y; }
.kline-legend { display: flex; justify-content: center; gap: 22px; margin-top: 10px; color: #9ab0a7; font-size: 10px; }
.kline-legend span { display: flex; align-items: center; gap: 6px; }
.kline-legend i { width: 15px; height: 3px; display: inline-block; }
.legend-up { background: var(--red); }
.legend-down { background: #48a8cf; }
.legend-volume { background: #78958a; }
.legend-ma5 { background: #e1bd72; }
.legend-ma20 { background: #e8eee9; }
.legend-ma60 { background: #63a98b; }
.history-table-panel { margin-top: 14px; padding: 22px; background: var(--cream); border: 1px solid var(--line); }
.history-table-panel .panel-heading span { color: var(--ink-soft); font-size: 11px; }

.analysis-section { color: #eaf1ed; background: #0c2d24; position: relative; overflow: hidden; }
.analysis-section::before { content: ""; position: absolute; inset: 0; opacity: .16; background: linear-gradient(115deg, transparent 0 48%, rgba(198,161,91,.22) 48% 48.2%, transparent 48.2% 100%); pointer-events: none; }
.analysis-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 18px; position: relative; }
.radar-panel, .technical-panel, .strategy-marketplace { padding: 24px; color: var(--ink); background: #f8f6ef; border: 1px solid rgba(255,255,255,.12); }
.panel-kicker { display: block; margin-bottom: 5px; color: var(--jade); font: 700 9px/1.3 Georgia, serif; letter-spacing: .16em; }
.radar-panel .panel-heading h3, .technical-panel .panel-heading h3, .marketplace-heading h3 { margin: 0; font: 700 25px STKaiti, KaiTi, serif; }
.radar-panel .panel-heading select { width: 145px; height: 38px; margin: 0; }
.market-breadth { display: flex; gap: 26px; margin: 20px 0 4px; padding: 12px 14px; color: var(--ink-soft); background: #ece9df; font-size: 11px; }
.market-breadth strong { margin-left: 5px; font: 700 15px Georgia, serif; }
.radar-signal { display: inline-flex; min-width: 52px; justify-content: center; padding: 3px 7px; color: var(--ink-soft); background: #e8e5dc; font-size: 10px; }
.radar-signal.strong { color: #9c302b; background: rgba(217,75,66,.1); }
.radar-signal.weak { color: #276d8a; background: rgba(72,168,207,.12); }
.signal-pill { padding: 7px 10px; color: #7c6540; background: #e9dfc8; font-size: 10px; font-weight: 800; }
.signal-pill.bullish { color: #9c302b; background: rgba(217,75,66,.12); }
.signal-pill.bearish { color: #276d8a; background: rgba(72,168,207,.14); }
.indicator-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 22px; }
.indicator-grid div { padding: 13px 10px; background: #ebe8de; }
.indicator-grid span, .price-zones span { display: block; color: var(--ink-soft); font-size: 9px; }
.indicator-grid strong { display: block; margin-top: 7px; font: 700 16px Georgia, serif; }
.price-zones { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.price-zones div { padding: 13px; border: 1px solid var(--line); }
.price-zones strong { display: block; margin-top: 7px; font: 700 18px Georgia, serif; }
.analysis-note { margin: 16px 0 0; padding: 14px; color: var(--ink-soft); background: #eeeae0; border-left: 3px solid var(--gold); font-size: 11px; line-height: 1.75; }
.strategy-marketplace { margin-top: 18px; position: relative; }
.marketplace-heading { display: flex; justify-content: space-between; align-items: end; gap: 30px; }
.marketplace-heading p { max-width: 500px; margin: 0; color: var(--ink-soft); font-size: 12px; }
.strategy-card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 22px; }
.strategy-template { padding: 19px; background: #efede5; border-top: 3px solid var(--green); transition: transform .2s, box-shadow .2s; }
.strategy-template:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(13,59,46,.12); }
.strategy-template h4 { margin: 14px 0 8px; font: 700 20px STKaiti, KaiTi, serif; }
.strategy-template p { min-height: 66px; margin-bottom: 14px; color: var(--ink-soft); font-size: 11px; line-height: 1.7; }
.risk-tag { display: inline-flex; padding: 4px 7px; font-size: 9px; font-weight: 800; }
.low-risk { color: #236449; background: rgba(47,135,103,.12); }
.mid-risk { color: #8a6526; background: rgba(198,161,91,.18); }
.high-risk { color: #a23731; background: rgba(217,75,66,.12); }
.template-meta { display: flex; justify-content: space-between; padding-top: 12px; border-top: 1px dashed var(--line); color: var(--ink-soft); font-size: 9px; }
.strategy-template button { width: 100%; height: 38px; margin-top: 14px; border: 1px solid var(--green); color: var(--green); background: transparent; cursor: pointer; font-weight: 800; }
.strategy-template button:hover { color: white; background: var(--green); }

.section { padding: 100px clamp(22px, 7vw, 110px); }
.section-heading { display: flex; justify-content: space-between; gap: 50px; align-items: end; margin-bottom: 42px; }
.section-heading h2, .live-placeholder h2 { margin-bottom: 0; font: 700 clamp(35px, 4vw, 54px)/1.1 STKaiti, KaiTi, serif; }
.section-heading > p { max-width: 560px; margin-bottom: 0; color: var(--ink-soft); line-height: 1.8; }
.section-heading.light { color: white; }
.section-heading.light > p { color: #a9bdb5; }

.strategy-section { background: var(--cream); }
.lab-grid { display: grid; grid-template-columns: 290px 1fr; gap: 26px; }
.control-panel, .result-panel { background: white; border: 1px solid var(--line); box-shadow: 0 16px 45px rgba(24,48,39,.07); }
.control-panel { padding: 25px; }
label { display: block; color: var(--ink-soft); font-size: 12px; font-weight: 700; position: relative; }
input, select, textarea { width: 100%; margin-top: 8px; color: var(--ink); background: #f8f7f2; border: 1px solid #d8d5ca; border-radius: 2px; outline: 0; }
input, select { height: 46px; padding: 0 12px; }
textarea { padding: 12px; resize: none; }
input:focus, select:focus, textarea:focus { border-color: var(--jade); box-shadow: 0 0 0 3px rgba(47,135,103,.1); }
.control-panel label { margin-bottom: 18px; }
.input-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.input-unit { position: absolute; right: 12px; bottom: 15px; color: var(--ink-soft); }
.fine-print { margin: 15px 0 0; color: #77837e; font-size: 11px; line-height: 1.6; }
.result-panel { padding: 25px; min-width: 0; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.metric-grid article, .account-summary article { padding: 18px; border: 1px solid var(--line); background: #faf9f5; }
.metric-grid span, .account-summary span { display: block; margin-bottom: 8px; color: var(--ink-soft); font-size: 12px; }
.metric-grid strong, .account-summary strong { font: 700 24px/1.2 Georgia, serif; }
.chart-shell { margin-top: 22px; padding: 18px; background: #f7f7f2; border: 1px solid var(--line); }
.chart-title { display: flex; justify-content: space-between; color: var(--ink-soft); font-size: 12px; }
#backtestChart { width: 100%; height: 260px; display: block; margin-top: 12px; }
.trade-log { max-height: 145px; overflow-y: auto; margin-top: 16px; font-size: 12px; }
.result-action { margin-top: 16px; }
.log-row { display: grid; grid-template-columns: 90px 80px 1fr; gap: 12px; padding: 9px 4px; border-bottom: 1px dashed var(--line); }
.empty { color: #8a948f; font-size: 13px; text-align: center; padding: 24px; }
.trade-plan-builder { margin-top: 26px; padding: 26px; background: #ede9df; border: 1px solid var(--line); box-shadow: 0 16px 45px rgba(24,48,39,.06); }
.plan-heading { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.plan-heading h3 { margin: 0; font: 700 27px STKaiti, KaiTi, serif; }
.plan-status { padding: 7px 10px; color: #795f31; background: #e1d4b7; font-size: 10px; font-weight: 800; }
.plan-status.ready { color: #1e684c; background: rgba(47,135,103,.13); }
.plan-status.warning { color: #a23731; background: rgba(217,75,66,.12); }
.plan-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.trade-plan-builder textarea { height: 82px; }
.trade-plan-builder > label { margin-top: 15px; }
.plan-summary { margin-top: 14px; padding: 14px; display: flex; gap: 38px; color: var(--ink-soft); background: #e2ded3; font-size: 11px; }
.plan-summary strong { margin-left: 7px; color: var(--ink); font: 700 16px Georgia, serif; }
.plan-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }

.paper-section { color: #eaf1ed; background: var(--green); position: relative; overflow: hidden; }
.paper-section::after { content: "模拟"; position: absolute; right: -50px; top: 80px; color: rgba(255,255,255,.025); font: 260px/1 STKaiti, KaiTi, serif; }
.account-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; position: relative; z-index: 1; }
.account-summary article { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.12); }
.account-summary span { color: #a9bdb5; }
.risk-console { display: grid; grid-template-columns: 1.2fr repeat(3, 1fr) 1.1fr 1fr; gap: 12px; align-items: end; margin-top: 16px; padding: 18px; color: var(--ink); background: #e7e2d5; position: relative; z-index: 1; }
.risk-console-title h3 { margin: 0; font: 700 22px STKaiti, KaiTi, serif; }
.risk-console input { margin-top: 7px; background: #f8f6ef; }
.kill-switch { height: 46px; padding: 0 12px; display: flex; align-items: center; gap: 9px; background: #f8f6ef; border: 1px solid var(--line); cursor: pointer; }
.kill-switch input { width: 16px; height: 16px; margin: 0; box-shadow: none; }
.kill-switch span { color: var(--ink); font-size: 11px; }
.risk-health { height: 46px; padding: 0 12px; display: flex; flex-direction: column; justify-content: center; color: #21654b; background: rgba(47,135,103,.12); font-size: 10px; }
.risk-health strong { margin-top: 3px; color: var(--ink); }
.risk-health.danger { color: #9f302b; background: rgba(217,75,66,.13); }
.trading-grid { display: grid; grid-template-columns: 330px 1fr; gap: 22px; margin-top: 22px; position: relative; z-index: 1; }
.order-ticket, .position-panel { color: var(--ink); background: #f8f6ef; padding: 25px; }
.ticket-tabs { display: grid; grid-template-columns: 1fr 1fr; margin: -25px -25px 24px; }
.ticket-tabs button { height: 52px; border: 0; color: var(--ink-soft); background: #e4e2da; cursor: pointer; font-weight: 800; }
.ticket-tabs .buy-tab.active { color: white; background: var(--red); }
.ticket-tabs .sell-tab.active { color: white; background: var(--blue); }
.order-ticket label { margin-bottom: 16px; }
.price-display { height: 50px; margin-top: 8px; padding: 0 12px; display: flex; align-items: center; justify-content: space-between; background: #efede5; }
.price-display strong { font: 22px Georgia, serif; }
.price-display span { color: var(--ink-soft); font-size: 10px; }
.quick-quantity { display: flex; gap: 6px; margin: -8px 0 15px; }
.quick-quantity button, .panel-heading button { border: 1px solid var(--line); color: var(--ink-soft); background: transparent; cursor: pointer; }
.quick-quantity button { flex: 1; padding: 6px; }
.order-estimate { display: flex; justify-content: space-between; margin-bottom: 15px; font-size: 12px; }
.order-estimate strong { font-family: Georgia, serif; }
.pretrade-checks { margin: 0 0 14px; padding: 10px; color: var(--ink-soft); background: #ebe8df; border-left: 3px solid var(--gold); font-size: 10px; line-height: 1.6; }
.pretrade-checks.pass { color: #21654b; border-color: var(--jade); }
.pretrade-checks.block { color: #9f302b; border-color: var(--red); }
.panel-heading { display: flex; align-items: center; justify-content: space-between; }
.panel-heading h3, .recent-orders h3 { margin: 0; font: 700 22px STKaiti, KaiTi, serif; }
.panel-heading button { padding: 7px 10px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; margin-top: 18px; border-collapse: collapse; white-space: nowrap; font-size: 12px; }
th, td { padding: 13px 10px; text-align: right; border-bottom: 1px solid var(--line); }
th:first-child, td:first-child { text-align: left; }
th { color: var(--ink-soft); font-weight: 600; }
.recent-orders { margin-top: 30px; }
#orderLog { max-height: 120px; overflow-y: auto; }
.review-ledger { margin-top: 22px; padding: 26px; color: var(--ink); background: #f8f6ef; position: relative; z-index: 1; }
.review-heading { display: flex; justify-content: space-between; align-items: end; gap: 30px; }
.review-heading h3 { margin: 0; font: 700 28px STKaiti, KaiTi, serif; }
.review-stats { display: flex; gap: 25px; color: var(--ink-soft); font-size: 10px; }
.review-stats strong { display: block; margin-top: 4px; color: var(--ink); font: 700 17px Georgia, serif; }
.review-entry { margin-top: 14px; padding: 18px; border: 1px solid var(--line); background: #efede5; }
.review-entry-head { display: flex; justify-content: space-between; gap: 15px; }
.review-entry-head h4 { margin: 0; font: 700 19px STKaiti, KaiTi, serif; }
.review-entry-head span { color: var(--ink-soft); font-size: 10px; }
.review-entry-plan { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin: 13px 0; }
.review-entry-plan div { padding: 10px; background: #e3e0d7; }
.review-entry-plan span { display: block; color: var(--ink-soft); font-size: 9px; }
.review-entry-plan strong { display: block; margin-top: 5px; font: 700 14px Georgia, serif; }
.review-compose { display: grid; grid-template-columns: 140px 1fr auto; gap: 8px; align-items: end; }
.review-compose button { height: 46px; border: 0; padding: 0 16px; color: white; background: var(--green); cursor: pointer; font-weight: 800; }
.review-text { margin: 12px 0 0; padding: 11px; color: var(--ink-soft); background: #e4e1d8; font-size: 11px; line-height: 1.7; }

.community-section { background: #ebe7dc; }
.community-grid { display: grid; grid-template-columns: 280px 1fr; min-height: 560px; border: 1px solid var(--line); background: var(--cream); box-shadow: var(--shadow); }
.room-info { padding: 30px; color: #e8f0ec; background: #16392f; }
.online { display: flex; gap: 8px; align-items: center; margin-bottom: 40px; }
.online strong { font: 24px Georgia, serif; }
.online span { color: #9eb5ac; font-size: 12px; }
.room-info h3 { font: 23px STKaiti, KaiTi, serif; }
.room-info ul { padding-left: 18px; color: #b6c8c1; font-size: 12px; line-height: 2; }
.topic-card { margin-top: 40px; padding: 18px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); }
.topic-card span, .topic-card strong { display: block; }
.topic-card span { margin-bottom: 8px; color: var(--gold); font-size: 10px; letter-spacing: .1em; }
.topic-card strong { font-size: 13px; line-height: 1.6; }
.chat-panel { min-width: 0; display: flex; flex-direction: column; }
.messages { flex: 1; height: 390px; padding: 25px; overflow-y: auto; }
.message { display: grid; grid-template-columns: 42px 1fr; gap: 12px; margin-bottom: 19px; animation: rise .3s ease; }
.avatar { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 4px 13px 4px 13px; color: white; background: var(--jade); font: 700 16px STKaiti, KaiTi, serif; }
.message-head { display: flex; gap: 10px; align-items: center; margin-bottom: 5px; }
.message-head strong { font-size: 13px; }
.message-head time { color: #929a96; font-size: 10px; }
.stock-tag { padding: 2px 6px; color: var(--jade); background: rgba(47,135,103,.1); font-size: 10px; }
.message-body { display: inline-block; max-width: 92%; padding: 10px 13px; background: #eeece5; font-size: 13px; line-height: 1.65; }
.chat-form { padding: 18px 25px 22px; border-top: 1px solid var(--line); background: white; }
.chat-fields { display: grid; grid-template-columns: 180px 1fr; gap: 10px; }
.message-compose { display: grid; grid-template-columns: 1fr 90px; gap: 10px; margin-top: 10px; }
.message-compose textarea { height: 70px; margin: 0; }

.live-placeholder { display: flex; align-items: center; justify-content: space-between; gap: 40px; background: #d8c79f; }
.live-placeholder p { max-width: 750px; margin: 18px 0 0; color: #48534e; line-height: 1.8; }
.locked { flex: none; padding: 18px 24px; color: var(--green); border: 1px solid var(--green); font-size: 12px; font-weight: 800; }
footer { padding: 42px clamp(22px, 7vw, 110px); color: #a9bdb5; background: #091f19; display: grid; grid-template-columns: 1fr 2fr auto; gap: 30px; align-items: center; font-size: 12px; }
footer strong { color: white; font: 20px STKaiti, KaiTi, serif; }
footer p { margin: 0; }
footer a { color: var(--gold); }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 50; max-width: 360px; padding: 14px 18px; color: white; background: #142f27; box-shadow: var(--shadow); opacity: 0; transform: translateY(15px); pointer-events: none; transition: .25s; }
.toast.show { opacity: 1; transform: translateY(0); }

@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 980px) {
  nav { display: none; }
  .hero { grid-template-columns: 1fr; padding-top: 60px; }
  .hero-terminal { box-shadow: 14px 18px 0 #d2bd8d; }
  .lab-grid, .trading-grid { grid-template-columns: 1fr; }
  .control-panel { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .control-panel .full, .control-panel .fine-print { grid-column: 1 / -1; }
  .community-grid { grid-template-columns: 220px 1fr; }
  .history-metrics { grid-template-columns: repeat(3, 1fr); }
  .analysis-grid { grid-template-columns: 1fr; }
  .strategy-card-grid { grid-template-columns: 1fr 1fr; }
  .workflow-dashboard { grid-template-columns: repeat(5, 1fr); }
  .workflow-title { grid-column: 1 / -1; }
  .plan-grid { grid-template-columns: repeat(3, 1fr); }
  .risk-console { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 700px) {
  .site-header { height: 68px; padding: 0 16px; }
  .brand strong { font-size: 17px; }
  .brand small, .market-status span { display: none; }
  .market-status { margin-left: auto; }
  .hero { min-height: auto; padding: 54px 18px 48px; }
  h1 { font-size: 45px; }
  .hero-intro { font-size: 15px; }
  .hero-actions { flex-direction: column; }
  .hero-terminal { padding: 16px; }
  .index-grid { grid-template-columns: 1fr; }
  .index-card { display: grid; grid-template-columns: 1fr auto; align-items: center; }
  .index-card strong { grid-row: span 2; }
  #pulseChart { height: 110px; }
  .section { padding: 70px 18px; }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 15px; }
  .history-toolbar { grid-template-columns: 1fr; }
  .history-source { justify-content: flex-start; }
  .history-metrics { grid-template-columns: 1fr 1fr; }
  #klineChart { height: 330px; }
  .market-breadth { gap: 12px; justify-content: space-between; }
  .strategy-card-grid { grid-template-columns: 1fr; }
  .indicator-grid { grid-template-columns: 1fr 1fr; }
  .marketplace-heading { display: block; }
  .marketplace-heading p { margin-top: 12px; }
  .workflow-dashboard { padding: 14px 18px; display: flex; overflow-x: auto; }
  .workflow-title { min-width: 130px; }
  .workflow-step { min-width: 135px; }
  .plan-grid { grid-template-columns: 1fr 1fr; }
  .plan-summary { flex-direction: column; gap: 8px; }
  .plan-actions { flex-direction: column; }
  .risk-console { grid-template-columns: 1fr 1fr; }
  .risk-console-title, .risk-health { grid-column: 1 / -1; }
  .control-panel { display: block; }
  .metric-grid, .account-summary { grid-template-columns: 1fr 1fr; }
  .metric-grid strong, .account-summary strong { font-size: 19px; }
  .result-panel, .order-ticket, .position-panel { padding: 16px; }
  .ticket-tabs { margin: -16px -16px 18px; }
  .review-heading { display: block; }
  .review-stats { margin-top: 15px; justify-content: space-between; }
  .review-entry-plan { grid-template-columns: 1fr 1fr; }
  .review-compose { grid-template-columns: 1fr; }
  .community-grid { grid-template-columns: 1fr; }
  .room-info { padding: 22px; }
  .room-info ul { display: none; }
  .online { margin-bottom: 18px; }
  .topic-card { margin-top: 18px; }
  .messages { height: 400px; padding: 16px; }
  .chat-form { padding: 14px; }
  .chat-fields { grid-template-columns: 1fr 1fr; }
  .message-compose { grid-template-columns: 1fr; }
  .message-compose .button { height: 44px; }
  .live-placeholder { display: block; }
  .locked { display: inline-block; margin-top: 24px; }
  footer { grid-template-columns: 1fr; gap: 12px; }
}
