:root {
  --navy: #101828;
  --navy-2: #172235;
  --ink: #182230;
  --muted: #718096;
  --line: #e7ebf0;
  --canvas: #f7f8fa;
  --panel: #ffffff;
  --orange: #f26d4f;
  --orange-dark: #d9583c;
  --mint: #34b59a;
  --yellow: #f4c95d;
  --shadow: 0 18px 42px rgba(18, 31, 53, .08);
  --content-max: 1680px;
  font-family: "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--canvas); font-family: var(--app-font, "Microsoft YaHei", "微软雅黑", Arial, sans-serif); }
body, body * { font-family: var(--app-font, "Microsoft YaHei", "微软雅黑", Arial, sans-serif); }
body.protected-content { user-select: none; -webkit-user-select: none; }
body.protected-content input, body.protected-content textarea { user-select: text; }
#pageSubtitle, #tipText { white-space: pre-line; }
.content-watermark { position: fixed; z-index: 80; inset: 0; display: none; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(var(--watermark-rows, 8), 170px); grid-auto-rows: 170px; align-items: center; justify-items: center; row-gap: var(--watermark-row-gap, 28px); column-gap: var(--watermark-column-gap, 72px); overflow: hidden; padding: 24px 42px; color: var(--watermark-color, #f26d4f); opacity: var(--watermark-opacity, .32); font-size: var(--watermark-size, 16px); font-weight: 800; letter-spacing: .025em; pointer-events: none; transform: translate(var(--watermark-offset-x, 0px), var(--watermark-offset-y, 0px)); }
body.protected-content .content-watermark { display: grid; }
.content-watermark span { white-space: nowrap; transform: rotate(var(--watermark-rotation, -18deg)); text-shadow: 0 1px 2px rgba(0,0,0,.28), 0 0 1px rgba(242,109,79,.25); }
.content-watermark[data-viewport-mode="phone"] span, .content-watermark[data-viewport-mode="mobile"] span { text-shadow: 0 1px 2px rgba(0,0,0,.42), 0 0 2px currentColor; }
.content-watermark span.is-staggered { letter-spacing: .035em; }
button, input { font: inherit; }
button { cursor: pointer; }
.app-shell { min-height: 100vh; display: flex; }
.sidebar { width: 244px; background: var(--navy); color: #fff; padding: 28px 18px 18px; display: flex; flex-direction: column; flex-shrink: 0; }
.brand-lockup { display: flex; align-items: center; gap: 11px; padding: 0 10px 34px; }
.brand-mark { width: 30px; height: 30px; background: var(--orange); border-radius: 9px; display: grid; place-items: center; transform: rotate(-8deg); position: relative; }
.brand-dot { width: 9px; height: 9px; border-radius: 50%; background: #fff; position: absolute; left: 8px; top: 7px; }
.brand-dot--muted { left: 14px; top: 14px; opacity: .66; }
.brand-name { font-size: 17px; font-weight: 700; letter-spacing: .02em; }
.brand-caption { color: #94a1b8; font-size: 8px; letter-spacing: .16em; margin-top: 3px; }
.sidebar-nav { display: grid; gap: 7px; }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; color: #a8b3c7; background: transparent; border: 0; padding: 12px 12px; border-radius: 8px; text-align: left; font-size: 13px; }
.nav-item svg { width: 17px; height: 17px; }
.nav-item:hover { color: #fff; background: rgba(255,255,255,.06); }
.nav-item.is-active { background: #243249; color: #fff; box-shadow: inset 3px 0 0 var(--orange); }
.nav-item kbd { margin-left: auto; color: #667894; font-size: 10px; }
.nav-count { margin-left: auto; font-size: 11px; color: #c9d1df; background: rgba(255,255,255,.08); border-radius: 20px; padding: 2px 7px; }
.sidebar-spacer { flex: 1; }
.sidebar-tip { border: 1px solid rgba(255,255,255,.09); background: rgba(255,255,255,.04); padding: 15px 14px; border-radius: 10px; margin: 18px 4px 24px; }
.tip-icon { width: 26px; height: 26px; border-radius: 7px; background: rgba(242,109,79,.16); color: var(--orange); display: grid; place-items: center; margin-bottom: 12px; }
.tip-icon svg { width: 14px; }
.tip-title { font-size: 12px; font-weight: 600; }
.sidebar-tip p { font-size: 11px; line-height: 1.6; color: #8593a9; margin: 6px 0 0; }
.sidebar-footer { display: flex; align-items: center; gap: 10px; border-top: 1px solid rgba(255,255,255,.09); padding: 18px 5px 0; }
.profile-avatar, .avatar-button { display: grid; place-items: center; background: #c6e6e2; color: #276e67; border-radius: 50%; width: 31px; height: 31px; padding: 0 3px; font-size: 11px; font-weight: 700; border: 0; white-space: nowrap; overflow: hidden; }
.profile-copy { display: grid; gap: 3px; flex: 1; }
.profile-copy strong { font-size: 12px; font-weight: 600; }
.profile-copy span { color: #8593a9; font-size: 10px; }
.profile-copy span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.main-content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.site-footer { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px 20px; min-height: 44px; margin-top: auto; padding: clamp(28px, 5vh, 60px) 8px 12px; color: var(--muted); font-size: 12px; text-align: center; }
.site-footer a { display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: inherit; text-decoration: none; text-underline-offset: 3px; }
.site-footer svg { width: 15px; height: 15px; flex: 0 0 15px; color: var(--orange); }
.site-footer .public-security-badge { width: 18px; height: 22px; flex: 0 0 18px; object-fit: contain; }
.site-footer .miit-filing-badge { width: 20px; height: 20px; flex: 0 0 20px; object-fit: contain; }
.site-footer a:hover, .site-footer a:focus-visible { color: var(--orange-dark); text-decoration: underline; }
@media (max-width: 760px) { .site-footer { margin-top: auto; padding-top: 28px; padding-bottom: max(14px, env(safe-area-inset-bottom)); font-size: 12px; } }
.topbar { min-height: 72px; padding: 0 38px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.82); }
.breadcrumb { display: flex; align-items: center; gap: 11px; color: #667085; font-size: 12px; }
.eyebrow, .section-kicker { color: #98a2b3; font-size: 9px; font-weight: 700; letter-spacing: .17em; }
.crumb-separator { color: #c9d1db; }
.topbar-actions, .heading-actions { display: flex; align-items: center; gap: 13px; }.top-summary { display: flex; align-items: center; gap: 10px; margin-left: auto; margin-right: 22px; }.top-summary-item { display: inline-flex; align-items: center; gap: 8px; min-width: 104px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255,255,255,.68); }.top-summary-item > svg { width: 17px; color: var(--orange); }.top-summary-item span { display: grid; gap: 1px; }.top-summary-item small { color: #8793a5; font-size: 9px; line-height: 1.2; }.top-summary-item strong { color: var(--ink); font-size: 15px; line-height: 1.1; }
.status-pill { display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; background: #f1faf7; color: #3b887a; border-radius: 20px; font-size: 11px; }
.status-button { border: 0; cursor: pointer; }.status-button:hover { filter: brightness(.98); }.status-pill.is-licensed { background: #edf7ff; color: #3f779e; }.status-pill.is-locked { background: #fff4f0; color: #bd5b47; }.status-pill.is-locked .status-dot { background: var(--orange); box-shadow: 0 0 0 3px rgba(242,109,79,.13); }
.mobile-license-button { display: none; align-items: center; justify-content: center; gap: 5px; min-width: 66px; min-height: 36px; padding: 7px 9px; border: 1px solid rgba(242,109,79,.42); border-radius: 7px; color: #fff; background: var(--orange); font-size: 11px; font-weight: 700; white-space: nowrap; box-shadow: 0 5px 12px rgba(242,109,79,.18); }.mobile-license-button svg { width: 14px; height: 14px; }
.status-dot, .live-indicator { width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 3px rgba(52,181,154,.13); }
.top-license-note { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; opacity: .9; }
.icon-button { width: 33px; height: 33px; border-radius: 7px; border: 1px solid transparent; background: transparent; color: #67758a; display: grid; place-items: center; position: relative; }
.icon-button:hover { background: #f1f3f6; color: var(--ink); }
.icon-button svg { width: 16px; }
.icon-button.subtle { color: #75839a; }
.notification-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--orange); position: absolute; top: 6px; right: 6px; }
.avatar-button { width: 30px; height: 30px; }
.page-scroll { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 36px 38px 60px; overflow: auto; }
.page-heading { position: relative; isolation: isolate; width: 100%; max-width: none; margin: 0 0 28px; padding: 22px 24px; display: flex; align-items: end; justify-content: space-between; gap: 24px; overflow: hidden; border: 1px solid rgba(231,235,240,.9); border-radius: 14px; background: linear-gradient(120deg, rgba(255,255,255,.95), rgba(248,251,255,.9)); box-shadow: 0 16px 38px rgba(18,31,53,.055); }
.page-heading::before { content: ""; position: absolute; z-index: -1; top: -105px; right: clamp(20px, 8vw, 140px); width: 260px; height: 260px; border-radius: 50%; background: radial-gradient(circle, rgba(242,109,79,.15), rgba(242,109,79,0) 68%); pointer-events: none; }
.page-heading::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: linear-gradient(180deg, var(--orange), rgba(242,109,79,.25)); }
.page-heading > div { width: 100%; min-width: 0; max-width: none; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(24px, 3vw, 34px); line-height: 1.2; letter-spacing: -.02em; margin-top: 9px; }
h2 { font-size: 22px; line-height: 1.25; margin-top: 7px; letter-spacing: -.02em; }
.section-subtitle { max-width: 980px; color: var(--muted); font-size: 13px; margin-top: 10px; }
.primary-button, .secondary-button { border: 0; border-radius: 7px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 15px; font-size: 12px; font-weight: 600; transition: .18s ease; }
.primary-button { color: #fff; background: var(--orange); box-shadow: 0 7px 14px rgba(242,109,79,.19); }
.primary-button:hover { background: var(--orange-dark); transform: translateY(-1px); }
.secondary-button { color: #4d5c70; background: #fff; border: 1px solid #dfe4ea; }
.secondary-button:hover { border-color: #c1cad6; background: #fbfcfd; }
.primary-button svg, .secondary-button svg { width: 15px; }
.compact { padding: 10px 13px; margin-top: 15px; }
.workbench-grid { width: 100%; max-width: none; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; align-items: start; }
.answer-column { min-width: 0; width: 100%; }
.search-panel { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 19px 19px 16px; margin-top: 0; box-shadow: 0 14px 32px rgba(18,31,53,.06); }
.search-label-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }.search-label-row label { font-size: 12px; font-weight: 600; }.search-label-row span { color: #a0aabb; font-size: 10px; }
.search-scope { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 10px 12px; margin: -2px 0 11px; }.search-scope-label { color: #8d99aa; font-size: 11px; }.scope-segmented { display: inline-flex; padding: 3px; border: 1px solid #e2e7ed; border-radius: 7px; background: #f7f9fb; }.scope-segmented button { border: 0; border-radius: 5px; padding: 8px 14px; color: #7b8798; background: transparent; font-size: 13px; cursor: pointer; }.scope-segmented button:hover { color: var(--orange-dark); }.scope-segmented button.is-active { color: #fff; background: var(--orange); }.semantic-toggle { flex: 0 0 auto; border: 1px solid #dce3eb; border-radius: 6px; padding: 8px 12px; color: #718096; background: #fff; font-size: 12px; cursor: pointer; }.semantic-toggle:hover { color: var(--orange-dark); border-color: var(--orange); }.semantic-toggle.is-active { color: #fff; border-color: var(--orange); background: var(--orange); }
.search-box { display: flex; align-items: center; gap: 8px; height: 45px; border: 1px solid #dfe4ea; border-radius: 7px; padding: 0 7px 0 13px; transition: .18s; }.search-box:focus-within { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(242,109,79,.1); }.search-box > svg { color: #94a0b2; width: 16px; flex-shrink: 0; }.search-box input { border: 0; outline: 0; flex: 1; min-width: 0; font-size: 12px; color: var(--ink); background: transparent; }.search-box input::placeholder { color: #aab3c0; }.clear-search, .stop-search { border: 0; background: transparent; color: #aeb8c5; display: grid; place-items: center; padding: 5px; }.clear-search svg, .stop-search svg { width: 14px; }.stop-search { color: var(--orange-dark); }.search-submit { width: 31px; height: 31px; border: 0; border-radius: 5px; color: #fff; background: var(--orange); display: grid; place-items: center; }.search-submit svg { width: 15px; }
.quick-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }.quick-tags button { border: 0; background: #f5f7f9; color: #748197; font-size: 10px; padding: 6px 9px; border-radius: 5px; }.quick-tags button:hover { background: #fff1ed; color: var(--orange-dark); }
.search-help { display: flex; align-items: flex-start; gap: 10px; margin-top: 12px; padding: 11px 12px; border: 1px solid #e8edf2; border-radius: 8px; color: #7f8b9c; background: linear-gradient(135deg, #fbfcfd, #f7f9fc); font-size: 11px; line-height: 1.55; }
.search-help-icon { width: 28px; height: 28px; flex: 0 0 28px; display: grid; place-items: center; border-radius: 7px; color: var(--orange); background: rgba(242,109,79,.1); }
.search-help-icon svg { width: 15px; height: 15px; }
.search-help-content { min-width: 0; flex: 1; }
.search-help strong { display: block; margin-bottom: 6px; color: #4d5b6e; font-size: 12px; font-weight: 700; }
.search-help-points { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px 18px; }
.search-help-points span { display: flex; align-items: flex-start; gap: 6px; min-width: 0; }
.search-help-points b { width: 17px; height: 17px; flex: 0 0 17px; display: grid; place-items: center; border-radius: 50%; color: var(--orange-dark); background: rgba(242,109,79,.1); font-size: 9px; line-height: 1; }
.answer-header { display: flex; justify-content: space-between; align-items: end; margin-bottom: 15px; }.result-count { font-size: 10px; color: #98a2b3; padding-bottom: 3px; }
.answer-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px rgba(27,39,56,.06); padding: 23px 23px 20px; min-height: 244px; }.answer-card.empty { display: grid; place-items: center; text-align: center; color: #98a2b3; min-height: 220px; }.empty svg { width: 28px; color: #c2ccd7; margin-bottom: 10px; }.empty span { font-size: 14px; }.empty-hint { display: block; max-width: 620px; margin-top: 10px; color: #7f8da3; font-size: 11px; line-height: 1.7; overflow-wrap: anywhere; }
.question-meta { display: flex; align-items: center; gap: 7px; color: #98a2b3; font-size: 10px; flex-wrap: wrap; }.subject-tag { padding: 4px 7px; border-radius: 4px; background: #eef8f6; color: #3f8d7f; font-size: 9px; font-weight: 600; }.type-tag, .result-type { color: var(--orange-dark); font-weight: 600; }.difficulty { color: #e1a941; }.question-origin { margin-top: 7px; color: #8d99aa; font-size: 10px; overflow-wrap: anywhere; }
.image-view-trigger { display: block; width: 100%; max-width: 100%; border: 0; padding: 0; margin: 13px 0 15px; background: transparent; text-align: left; cursor: zoom-in; }.question-image { display: block; width: 100%; max-width: 100%; height: auto; max-height: min(60vh, 520px); object-fit: contain; object-position: left center; border: 1px solid #edf0f3; border-radius: 7px; background: #fbfcfd; }
.question-text { font-size: 14px; line-height: 1.75; font-weight: 600; margin: 12px 0 17px; white-space: pre-line; }.answer-divider { border-top: 1px solid #edf0f3; margin: 0 -21px; }.answer-label { font-size: 10px; color: #98a2b3; letter-spacing: .11em; margin-top: 16px; }.answer-text { font-size: 20px; font-weight: 700; color: var(--orange-dark); margin-top: 8px; white-space: pre-line; }.explanation { color: #667085; font-size: 11px; line-height: 1.7; margin-top: 8px; white-space: pre-line; }.card-actions { display: flex; align-items: center; gap: 8px; margin-top: 16px; }.card-actions button { display: inline-flex; align-items: center; gap: 5px; border: 1px solid #e2e6eb; background: #fff; color: #718096; border-radius: 5px; padding: 7px 9px; font-size: 10px; }.card-actions button:hover { border-color: #f7c3b8; color: var(--orange-dark); background: #fff8f6; }.card-actions svg { width: 13px; }
.result-list { margin-top: 12px; display: grid; grid-auto-rows: max-content; align-content: start; gap: 7px; overflow-x: hidden; }.result-item { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 13px 14px; cursor: pointer; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 9px; align-items: center; min-width: 0; content-visibility: auto; contain-intrinsic-size: 68px; transition: border-color .16s, background .16s, transform .16s; }.result-item:hover, .result-item.is-selected { border-color: #f7b4a5; background: #fffaf8; transform: translateY(-1px); }.result-copy { display: flex; align-items: center; gap: 9px; min-width: 0; }.result-copy > div { min-width: 0; }.result-media-indicator { width: 28px; height: 28px; flex-shrink: 0; display: grid; place-items: center; border-radius: 6px; background: #fff3ef; color: var(--orange-dark); }.result-media-indicator svg { width: 15px; }.result-item p { font-size: 12px; line-height: 1.55; color: #526174; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; white-space: normal; overflow-wrap: anywhere; }.result-item small { display: block; color: #a0a9b7; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.result-answer { color: var(--orange-dark); font-size: 12px; font-weight: 700; white-space: nowrap; }.result-feedback-button { border: 1px solid #e3e8ee; border-radius: 5px; padding: 4px 7px; color: #8a96a6; background: #fff; font-size: 10px; cursor: pointer; white-space: nowrap; }.result-feedback-button:hover { color: var(--orange-dark); border-color: #f7b4a5; background: #fff8f5; }
.result-thumb { width: 42px; height: 32px; flex-shrink: 0; object-fit: contain; border: 1px solid #edf0f3; border-radius: 4px; background: #fff; }
.result-image-only { grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 8px; padding: 10px; cursor: pointer; }.result-browse-image { width: 100%; display: flex; justify-content: center; }.result-browse-thumb { display: block; width: 100%; height: 104px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; background: #fff; pointer-events: none; }.result-browse-meta { display: grid; gap: 2px; justify-items: center; color: var(--muted); font-size: 10px; }.result-browse-meta small { color: var(--muted); font-size: 9px; }.result-image-only.is-selected { border-color: var(--orange); }
.question-origin { display: block; color: #8f9caf; font-size: 10px; font-weight: 400; line-height: 1.35; }
mark { padding: 0 2px; border-radius: 3px; color: #8f2f1e; background: #ffd7cc; font-weight: 800; box-shadow: 0 0 0 1px rgba(242,109,79,.12); }
.load-more-button { width: 100%; margin-top: 10px; padding: 10px; border: 1px solid #e2e7ed; border-radius: 7px; background: #fff; color: #718096; font-size: 11px; }.load-more-button:hover { border-color: #f7b4a5; color: var(--orange-dark); background: #fffaf8; }
.recent-panel { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 17px; }.panel-heading { display: flex; align-items: center; justify-content: space-between; font-size: 11px; font-weight: 600; }.text-button { background: transparent; border: 0; color: #a0aabb; font-size: 10px; padding: 4px; }.text-button:hover { color: var(--orange-dark); }.recent-list { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }.recent-chip { border: 1px solid #e7ebef; background: #fff; border-radius: 5px; color: #778398; font-size: 10px; padding: 7px 9px; }.recent-chip:hover { border-color: #f7b4a5; color: var(--orange-dark); }
.library-view { max-width: 1260px; margin: 0 auto; }.view-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 22px; }.view-heading p:last-child { color: var(--muted); font-size: 12px; margin-top: 9px; }.library-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }.library-stats > div { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 16px; display: grid; gap: 9px; }.library-stats span { color: #8d99aa; font-size: 10px; }.library-stats strong { font-size: 22px; }.bank-table-wrap { background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: auto; }table { width: 100%; border-collapse: collapse; min-width: 760px; }th, td { text-align: left; border-bottom: 1px solid #edf0f3; padding: 14px 17px; font-size: 11px; }th { color: #98a2b3; font-size: 10px; font-weight: 500; background: #fbfcfd; }td:first-child { color: #334155; width: 72px; }.table-thumb { width: 50px; height: 38px; border-radius: 4px; object-fit: cover; border: 1px solid #e5e9ee; }.no-image { color: #b2bbc6; font-size: 10px; }.history-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }.history-card { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 15px; cursor: pointer; }.history-card:hover { border-color: #f7b4a5; }.history-card p { color: #3f4d5f; font-size: 12px; line-height: 1.6; }.history-card small { display: block; color: #9ba5b3; font-size: 10px; margin-top: 12px; }.history-thumb { width: 100%; height: 120px; object-fit: cover; border-radius: 5px; margin-bottom: 11px; border: 1px solid #e5e9ee; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 18px); background: #1d2939; color: #fff; padding: 10px 14px; border-radius: 6px; font-size: 11px; opacity: 0; pointer-events: none; transition: .2s; }.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.section-subtitle { font-size: 15px; line-height: 1.8; }
.search-label-row label { font-size: 14px; }
.search-label-row span { font-size: 12px; }
.search-scope-label { font-size: 13px; }
.scope-segmented button { font-size: 14px; padding: 9px 15px; }
.semantic-toggle { font-size: 13px; padding: 9px 13px; }
.search-box input { font-size: 14px; }
.search-box input::placeholder { font-size: 13px; }
.quick-tags button { font-size: 12px; padding: 7px 10px; }
.search-help { font-size: 12px; line-height: 1.65; padding: 9px 10px; }
.search-help svg { width: 15px; height: 15px; }
.answer-header .section-kicker { font-size: 10px; }
.result-count { font-size: 12px; }
.empty span { font-size: 14px; }
.panel-heading { font-size: 13px; }
.recent-empty { color: #8d99aa; font-size: 12px; }
body.dark-theme .recent-empty { color: #aebbd0; }
.quick-tags button:focus-visible, .scope-segmented button:focus-visible, .semantic-toggle:focus-visible, .search-submit:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.license-dialog { width: min(450px, calc(100vw - 32px)); border: 1px solid var(--line); border-radius: 12px; padding: 0; color: var(--ink); box-shadow: 0 24px 80px rgba(18,31,53,.24); }.license-dialog::backdrop { background: rgba(16,24,40,.58); backdrop-filter: blur(3px); }.license-dialog form { padding: 25px; }.dialog-kicker { color: #98a2b3; font-size: 9px; letter-spacing: .17em; font-weight: 700; }.license-dialog h2 { margin: 9px 0 8px; }.license-dialog p { color: var(--muted); font-size: 12px; line-height: 1.6; }.license-dialog label { display: block; color: #526174; font-size: 11px; font-weight: 600; margin: 20px 0 7px; }.license-dialog input { width: 100%; height: 42px; border: 1px solid #dfe4ea; border-radius: 7px; padding: 0 11px; outline: 0; font-size: 12px; }.license-dialog input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(242,109,79,.1); }.license-feedback { display: flex; align-items: center; min-height: 38px; margin: 0 0 10px; padding: 9px 11px; border: 1px solid #e5b6ac; border-left: 4px solid var(--orange); border-radius: 7px; background: #fff5f2; color: #a83d2c; font-size: 12px; font-weight: 700; line-height: 1.45; }.license-feedback.is-success { border-color: #9ad8c9; border-left-color: var(--mint); background: #effaf7; color: #217563; }.dialog-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 20px; }.license-note { color: #a0aabb; font-size: 10px; margin-top: 13px; overflow-wrap: anywhere; }.license-usage-summary { margin: 12px 0 2px; padding: 9px 10px; border: 1px solid rgba(242,109,79,.28); border-radius: 7px; color: var(--orange-dark); background: rgba(242,109,79,.07); font-size: 11px; line-height: 1.5; }
.image-dialog { width: min(1100px, calc(100vw - 28px)); max-width: 1100px; max-height: calc(100vh - 28px); overflow: hidden; padding: 46px 18px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--ink); box-shadow: 0 24px 90px rgba(0,0,0,.38); }.image-dialog::backdrop { background: rgba(2,8,20,.78); backdrop-filter: blur(3px); }.image-dialog img { position: relative; z-index: 1; display: block; max-width: none; max-height: none; width: auto; height: auto; margin: 0 auto; object-fit: contain; transform-origin: center center; transition: transform .12s ease; cursor: zoom-in; touch-action: none; user-select: none; -webkit-user-drag: none; will-change: transform; }.image-dialog img.is-zoomed { cursor: grab; transition: none; }.image-dialog img.is-zoomed:active { cursor: grabbing; }.image-dialog-watermark { position: absolute; z-index: 3; inset: 0; display: none; align-items: center; justify-items: center; overflow: hidden; padding: 46px 24px 18px; font-weight: 800; letter-spacing: .025em; pointer-events: none; }.image-dialog-watermark span { white-space: nowrap; text-shadow: 0 1px 2px rgba(0,0,0,.5), 0 0 2px currentColor; }.image-dialog-watermark span.is-staggered { letter-spacing: .035em; }body.protected-content .image-dialog-watermark { display: grid; }.image-dialog-close { position: absolute; z-index: 5; top: 10px; right: 12px; width: 32px; height: 32px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); color: var(--ink); font-size: 24px; line-height: 1; cursor: pointer; }.image-dialog-close:hover { background: #263952; }
@media (max-width: 640px) { .image-dialog { width: calc(100vw - 18px); max-height: calc(100vh - 18px); padding: 42px 8px 8px; border-radius: 8px; }.image-dialog img { max-width: 100%; max-height: calc(100vh - 78px); }.image-dialog-close { top: 7px; right: 7px; width: 30px; height: 30px; font-size: 22px; } }
.stop-search { display: inline-flex; align-items: center; gap: 5px; color: var(--orange-dark); font-size: 11px; font-weight: 600; white-space: nowrap; }.stop-search[hidden] { display: none; }.stop-search:hover { background: #fff1ed; border-radius: 5px; }.search-submit { flex-shrink: 0; }
.answer-layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(290px, .75fr); gap: 14px; align-items: start; }.result-pane { min-width: 0; }.result-pane .result-list { margin-top: 0; max-height: 560px; overflow: auto; padding-right: 2px; }
.practice-view { max-width: none; width: 100%; margin: 0; }
.practice-heading { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 12px; }
.practice-heading > div > p:not(.section-kicker) { color: var(--muted); font-size: 12px; line-height: 1.5; margin-top: 5px; max-width: 680px; }
.practice-type-tabs { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; }.practice-type-tab { border: 1px solid var(--line); border-radius: 6px; padding: 7px 10px; color: var(--muted); background: var(--panel); font-size: 11px; }.practice-type-tab:hover, .practice-type-tab.is-active { color: var(--orange-dark); border-color: #f7b4a5; background: #fff8f6; }
.practice-stats { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 12px; color: var(--muted); font-size: 11px; }.practice-stats span { color: var(--ink); font-weight: 600; }.practice-stats small { color: var(--muted); font-size: 10px; }
.practice-card { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); padding: 24px; min-height: 0; }
.practice-empty { min-height: 220px; display: grid; place-items: center; align-content: center; gap: 9px; color: var(--muted); text-align: center; }.practice-empty svg { width: 36px; height: 36px; color: var(--orange); margin-bottom: 6px; }.practice-empty strong { color: var(--ink); font-size: 18px; }.practice-empty span { font-size: 12px; }
.practice-topline { display: flex; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 11px; border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 15px; }.practice-progress { color: var(--orange-dark); font-weight: 700; }.practice-question { margin-top: 14px; }.practice-question .question-image { max-height: min(42vh, 360px); }.practice-answer-label { color: var(--muted); font-size: 12px; font-weight: 600; margin-top: 18px; }.practice-options { display: grid; gap: 8px; margin-top: 9px; }.practice-option { display: flex; align-items: center; gap: 9px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); font-size: 13px; cursor: pointer; }.practice-option:has(input:checked) { border-color: var(--orange); background: rgba(242,109,79,.08); }.practice-option input { accent-color: var(--orange); }.practice-answer-input { width: 100%; min-height: 44px; margin-top: 9px; border: 1px solid var(--line); border-radius: 7px; padding: 0 12px; outline: 0; color: var(--ink); background: var(--panel); }.practice-answer-input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(242,109,79,.1); }.practice-submit { margin-top: 16px; }.practice-feedback { display: grid; gap: 9px; margin-top: 18px; padding: 15px; border-radius: 8px; border: 1px solid var(--line); }.practice-feedback strong { font-size: 15px; }.practice-feedback span { color: var(--orange-dark); font-weight: 700; }.practice-feedback p { color: var(--muted); font-size: 12px; line-height: 1.7; white-space: pre-line; }.practice-feedback small { color: var(--muted); }.practice-feedback.is-correct { border-color: rgba(52,181,154,.45); background: rgba(52,181,154,.08); }.practice-feedback.is-correct strong { color: #23836f; }.practice-feedback.is-wrong { border-color: rgba(242,109,79,.35); background: rgba(242,109,79,.06); }.practice-feedback.is-wrong strong { color: var(--orange-dark); }
@media (max-width: 980px) { .sidebar { width: 70px; padding: 22px 10px 14px; }.brand-lockup { padding: 0 10px 30px; }.brand-lockup > div:last-child, .nav-item span, .nav-item kbd, .sidebar-tip, .profile-copy, .sidebar-footer .icon-button { display: none; }.nav-item { justify-content: center; padding: 12px 0; }.nav-count { display: block !important; position: absolute; margin: -26px 0 0 24px; padding: 2px 5px; background: var(--orange); color: #fff; font-size: 8px; }.sidebar-footer { justify-content: center; }.topbar { padding: 0 24px; }.page-scroll { padding: 30px 24px 50px; }.answer-layout { grid-template-columns: 1fr; }.result-pane .result-list { max-height: none; overflow: visible; } }
@media (max-width: 980px) and (min-width: 761px) { .library-stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) { .topbar { min-height: 62px; padding: 0 15px; }.breadcrumb .eyebrow, .crumb-separator { display: none; }.top-summary { gap: 5px; margin-right: 8px; }.top-summary-item { min-width: 0; padding: 5px 7px; }.top-summary-item > svg { width: 15px; }.top-summary-item small { font-size: 8px; }.top-summary-item strong { font-size: 13px; }.page-heading { align-items: start; flex-direction: column; margin-bottom: 22px; padding: 17px 16px; border-radius: 11px; }.heading-actions { width: 100%; }.heading-actions button { flex: 1; min-height: 44px; }.workbench-grid { grid-template-columns: 1fr; }.page-scroll { padding: 24px 15px 45px; }h1 { font-size: 26px; }.library-stats { grid-template-columns: 1fr; }.view-heading { align-items: start; gap: 14px; flex-direction: column; }.search-box { height: 50px; }.search-box input { font-size: 16px; }.search-help-points { grid-template-columns: 1fr; gap: 6px; } }
@media (max-width: 760px) { .content-watermark { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(var(--watermark-rows, 8), 150px); grid-auto-rows: 150px; row-gap: var(--watermark-row-gap, 28px); column-gap: var(--watermark-column-gap, 34px); padding: 18px 22px; font-size: var(--watermark-size, 13px); } }
@media (max-width: 430px) { .sidebar { width: 58px; }.topbar-actions .status-pill { display: none; }.page-heading h1 { font-size: 23px; }.content-watermark { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(var(--watermark-rows, 8), 138px); grid-auto-rows: 138px; row-gap: var(--watermark-row-gap, 28px); column-gap: var(--watermark-column-gap, 24px); padding: 14px 14px; font-size: var(--watermark-size, 12px); } }
@media (max-width: 760px) { .app-shell { display: block; }.sidebar { position: fixed; z-index: 40; inset: 0 0 auto; width: 100%; height: 58px; padding: 7px 10px; flex-direction: row; align-items: center; border-bottom: 1px solid rgba(255,255,255,.09); box-shadow: 0 7px 22px rgba(5,12,24,.22); }.brand-lockup, .sidebar-spacer, .sidebar-tip, .sidebar-footer { display: none; }.sidebar-nav { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }.nav-item { min-height: 44px; justify-content: center; flex-direction: row; gap: 7px; padding: 8px 10px; border: 1px solid transparent; border-radius: 7px; font-size: 12px; font-weight: 600; }.nav-item svg { width: 16px; height: 16px; }.nav-item > span:not(.nav-count) { display: block; }.nav-item kbd, .nav-count { display: none !important; }.nav-item.is-active { border-color: rgba(255,255,255,.08); background: #283750; box-shadow: inset 0 -2px 0 var(--orange); }.main-content { width: 100%; min-height: 100dvh; padding-top: 58px; padding-bottom: 0; }.topbar-actions .status-pill, .topbar-actions .icon-button, .topbar-actions .avatar-button { display: none; }.topbar-actions .mobile-license-button { display: inline-flex; }.page-scroll { padding-bottom: 28px; } }
.mobile-action-bar { display: none; }
@media (max-width: 760px) {
  .mobile-action-bar { position: fixed; z-index: 125; right: 0; bottom: 0; left: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; padding: 7px max(8px, env(safe-area-inset-left)) max(7px, env(safe-area-inset-bottom)); border-top: 1px solid rgba(214,223,233,.95); background: rgba(255,255,255,.96); box-shadow: 0 -8px 24px rgba(25,43,66,.12); backdrop-filter: blur(14px); }
  .mobile-action-bar button { min-width: 0; min-height: 44px; display: grid; place-items: center; gap: 3px; border: 0; border-radius: 8px; color: #718096; background: transparent; font: inherit; font-size: 10px; font-weight: 700; }
  .mobile-action-bar button:active, .mobile-action-bar button:focus-visible { color: var(--orange-dark); background: #fff1ed; outline: 0; }
  .mobile-action-bar svg { width: 17px; height: 17px; }
  .main-content { padding-bottom: calc(68px + env(safe-area-inset-bottom)); }
  .site-footer { padding-bottom: calc(74px + env(safe-area-inset-bottom)); }
  body.dark-theme .mobile-action-bar { border-top-color: #27384e; background: rgba(13,23,40,.97); box-shadow: 0 -8px 24px rgba(0,0,0,.22); }
  body.dark-theme .mobile-action-bar button { color: #a8b6c9; }
  body.dark-theme .mobile-action-bar button:active, body.dark-theme .mobile-action-bar button:focus-visible { color: #ffb8a8; background: #2a2630; }
}
@media (max-width: 760px) {
  /* 为固定快捷栏和手机底部安全区留出完整滚动空间，避免最后内容/备案信息被遮挡。 */
  .page-scroll { padding-bottom: calc(76px + env(safe-area-inset-bottom)); scroll-padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  .mobile-action-bar { padding-right: max(8px, env(safe-area-inset-right)); }
}
@media (max-width: 760px) { .sidebar-nav { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }.nav-item { min-width: 0; gap: 5px; padding-inline: 4px; font-size: 10px; white-space: nowrap; }.nav-item svg { flex: 0 0 auto; width: 15px; height: 15px; } }
@media (max-width: 760px) { .practice-heading { align-items: start; flex-direction: column; }.practice-heading .primary-button { width: 100%; }.practice-card { padding: 16px; }.practice-topline { font-size: 10px; } }
@media (max-width: 760px) { html, body { max-width: 100%; overflow-x: hidden; }.main-content, .page-scroll, .topbar, .content-panel, .answer-card, .result-pane, .search-panel, .workbench-grid, .answer-layout { min-width: 0; max-width: 100%; width: 100%; box-sizing: border-box; }.main-content { overflow-x: clip; }.topbar { overflow: hidden; }.breadcrumb { min-width: 0; overflow: hidden; }.breadcrumb strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.top-summary { flex-shrink: 0; }.search-scope { align-items: stretch; flex-wrap: wrap; }.scope-segmented { width: 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }.scope-segmented button, .semantic-toggle { min-width: 0; padding-inline: 6px; font-size: 12px; }.answer-layout { gap: 10px; }.result-pane .result-list { max-height: 48vh; }.result-item, .result-copy, .result-copy > div { min-width: 0; }.result-copy p, .question-text, .answer-text, .explanation { overflow-wrap: anywhere; word-break: break-word; }.image-group-tools { width: 100%; box-sizing: border-box; }.image-group-actions { width: 100%; }.group-mode-button { min-width: 0; width: 100%; white-space: normal; }.practice-type-tabs { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }.practice-type-tab { min-width: 0; white-space: normal; }.license-dialog, .consent-dialog { width: calc(100vw - 20px); max-width: calc(100vw - 20px); padding: 18px; }.license-dialog input, .consent-dialog button { font-size: 16px; } }

@media (max-width: 430px) {
  .topbar { min-height: 56px; padding: 6px 10px; gap: 5px; }
  .breadcrumb { display: none; }
  .top-summary { flex: 1 1 auto; gap: 4px; margin: 0; }
  .top-summary-item { flex: 1 1 0; padding: 4px 6px; }
  .topbar-actions { flex: 0 0 auto; gap: 4px; }
  .topbar-actions .status-pill { display: none; }
  .topbar-actions .avatar-button { display: none; }
  .topbar-actions .mobile-license-button { display: inline-flex; }
  .page-scroll { padding: 14px 10px 28px; }
  .page-heading { margin-bottom: 14px; }
  .page-heading h1 { font-size: 21px; line-height: 1.25; }
  .section-subtitle { font-size: 11px; line-height: 1.65; }
  .search-panel { padding: 13px 10px; }
  .search-scope-label { display: none; }
  .scope-segmented button, .semantic-toggle { min-height: 38px; font-size: 11px; }
  .quick-tags { max-height: 74px; overflow-y: auto; }
  .quick-tags button { font-size: 10px; padding: 7px 8px; }
  .search-help { padding: 9px; font-size: 10px; line-height: 1.55; }
  .answer-header h2 { font-size: 21px; }
  .content-watermark { padding: 76px 18px 24px; }
  .search-label-row { margin-bottom: 8px; }
  .search-scope { gap: 8px; margin-bottom: 10px; }
  .search-help { margin-top: 8px; }
  .answer-header { margin: 16px 0 10px; }
  .answer-card { padding: 16px 13px; min-height: 190px; }
  .practice-heading { gap: 12px; margin-bottom: 12px; }
  .practice-heading h2 { font-size: 21px; }
  .practice-card { min-height: 0; }
}

/* Keep the initial workbench compact: results remain available below the answer card. */
@media (min-width: 761px) {
  .sidebar-spacer { flex: 0 0 clamp(28px, 8vh, 96px); }
  .sidebar-footer { margin-top: auto; }
  .page-scroll { padding-top: 22px; padding-bottom: 22px; }
  .page-heading { margin-bottom: 18px; }
  .answer-layout { grid-template-columns: 1fr; gap: 10px; }
  .answer-layout.has-results { grid-template-columns: minmax(0, 1.65fr) minmax(290px, .75fr); gap: 14px; }
  .answer-layout:not(.has-results) .result-pane { display: none; }
  .answer-layout .result-pane { width: 100%; }
  .answer-card.empty { min-height: 168px; }
  .result-pane .result-list { max-height: 300px; }
  .answer-layout.has-results { align-items: stretch; }
  .answer-layout.has-results .result-pane { display: flex; flex-direction: column; align-self: start; min-height: 0; height: min(760px, calc(100vh - 280px)); max-height: calc(100vh - 280px); overflow: hidden; }
  .answer-layout.has-results .result-pane .result-list { flex: 1 1 auto; height: 100%; max-height: none; min-height: 0; overflow-y: auto; overflow-x: hidden; align-content: start; overscroll-behavior: contain; scrollbar-gutter: stable; }
  .recent-panel { display: none; }
}

body.dark-theme { --canvas: #0b1220; --panel: #111b2d; --ink: #edf3fb; --muted: #9aa9bd; --line: #24344a; --shadow: 0 18px 42px rgba(0,0,0,.22); }
body.dark-theme .topbar { background: rgba(11,18,32,.92); }
body.dark-theme .top-summary-item { border-color: #334760; background: #101b2d; }
body.dark-theme .top-summary-item small { color: #9aa9bd; }
body.dark-theme .top-summary-item strong { color: #e8eef7; }
body.dark-theme .breadcrumb, body.dark-theme .section-subtitle, body.dark-theme .result-count { color: #9aa9bd; }
body.dark-theme .icon-button { color: #9aa9bd; }
body.dark-theme .icon-button:hover { background: #1a2940; color: #fff; }
body.dark-theme .search-panel, body.dark-theme .answer-card, body.dark-theme .result-item, body.dark-theme .history-card, body.dark-theme .library-stats > div, body.dark-theme .bank-table-wrap { background: var(--panel); border-color: var(--line); box-shadow: 0 12px 30px rgba(0,0,0,.14); }
body.dark-theme .search-box { border-color: #344760; background: #0e1727; }
body.dark-theme .search-box input { color: var(--ink); }
body.dark-theme .search-scope-label { color: #9aa9bd; }
body.dark-theme .scope-segmented { border-color: #334760; background: #0e1727; }
body.dark-theme .scope-segmented button { color: #aebbd0; }
body.dark-theme .scope-segmented button.is-active { color: #fff; background: var(--orange); }
body.dark-theme .semantic-toggle { border-color: #334760; color: #aebbd0; background: #101b2d; }
body.dark-theme .semantic-toggle:hover { color: #fff; border-color: var(--orange); }
body.dark-theme .semantic-toggle.is-active { color: #fff; background: var(--orange); }
body.dark-theme .quick-tags button, body.dark-theme .recent-chip { background: #19263a; color: #aebbd0; border-color: #2b3c54; }
body.dark-theme .quick-tags button:hover, body.dark-theme .recent-chip:hover { background: #263952; color: #fff; }
body.dark-theme .search-help { border-color: #2b3c54; color: #aebbd0; background: #121e31; }
body.dark-theme .search-help strong { color: #d9e3ef; }
body.dark-theme .search-help-icon, body.dark-theme .search-help-points b { background: rgba(242,109,79,.16); }
body.dark-theme .page-heading { border-color: #24344a; background: linear-gradient(120deg, rgba(20,32,51,.97), rgba(14,24,40,.94)); box-shadow: 0 18px 42px rgba(0,0,0,.18); }

/* 首页主内容统一从搜索卡片的左边缘开始，覆盖旧版居中/内缩规则。 */
#deskHeading,
#deskHeading > div,
#deskView,
#practiceView { width: 100% !important; max-width: none !important; margin-left: 0 !important; margin-right: 0 !important; }
#deskHeading { padding-left: 24px !important; padding-right: 24px !important; }
#deskHeading > div { padding-left: 0 !important; transform: none !important; }
.page-scroll { align-items: stretch !important; }
.page-scroll > #deskHeading,
.page-scroll > #deskView,
.page-scroll > #practiceView { align-self: stretch !important; justify-self: stretch !important; }
.page-scroll > #deskHeading > div { text-align: left !important; }
@media (max-width: 760px) {
  #deskHeading { padding-left: 16px !important; padding-right: 16px !important; }
}
body.dark-theme .result-item:hover, body.dark-theme .result-item.is-selected { background: #18283d; border-color: #d47760; }
body.dark-theme mark { color: #fff5f1; background: #884637; box-shadow: 0 0 0 1px rgba(255,154,127,.32); }
body.dark-theme .result-item p, body.dark-theme .question-text, body.dark-theme td { color: #d9e3ef; }
body.dark-theme .answer-divider, body.dark-theme th, body.dark-theme td { border-color: #24344a; }
body.dark-theme th { background: #0e1727; color: #94a5bd; }
body.dark-theme .text-button, body.dark-theme .recent-panel, body.dark-theme .view-heading p:last-child { color: #9aa9bd; }
body.dark-theme .secondary-button, body.dark-theme .card-actions button { background: #17253a; color: #c2cede; border-color: #334760; }
body.dark-theme .secondary-button:hover, body.dark-theme .card-actions button:hover { background: #21334d; }
body.dark-theme .license-dialog { background: #111b2d; color: var(--ink); border-color: #344760; }
body.dark-theme .license-usage-summary { border-color: #704233; color: #ffb8a8; background: #2a211f; }
body.dark-theme .license-feedback { background: #3a211d; border-color: #8e4d3d; color: #ffd2c6; }
body.dark-theme .license-feedback.is-success { background: #17372f; border-color: #397f6f; color: #b9f0e2; }
body.dark-theme h1, body.dark-theme h2, body.dark-theme .search-label-row label, body.dark-theme .panel-heading, body.dark-theme .answer-label, body.dark-theme .library-stats strong { color: #f4f7fb; }
body.dark-theme .answer-text { color: #ff9a7f; }
body.dark-theme .page-heading h1 { text-shadow: 0 1px 0 rgba(255,255,255,.04); }
body.dark-theme .empty, body.dark-theme .empty span, body.dark-theme .answer-card.empty { color: #b8c6d8; }
body.dark-theme .question-meta, body.dark-theme .search-label-row span, body.dark-theme .library-stats span { color: #aebbd0; }
body.dark-theme .question-origin { color: #9aa9bd; }
body.dark-theme .question-image { border-color: #344760; background: #0e1727; }
body.dark-theme .check-row { color: #c2cede; }
body.dark-theme .image-group-tools { background: #111b2d; border-color: #24344a; }
body.dark-theme .image-group-heading span { color: #edf3fb; }
body.dark-theme .image-group-heading small { color: #9aa9bd; }
body.dark-theme .group-mode-button { background: #17253a; border-color: #334760; color: #c2cede; }
body.dark-theme .group-mode-button:hover { background: #21334d; border-color: #d47760; }
body.dark-theme .group-mode-button.is-active { background: #63372f; border-color: #d47760; color: #fff; }
body.dark-theme .result-group-label { background: #17253a; border-color: #334760; color: #c2cede; }
body.dark-theme .result-group-label small { color: #9aa9bd; }
@media (max-width: 760px) { .topbar-actions #themeToggle { display: grid; } }

.image-group-tools { margin: -4px 0 12px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 8px; background: #fbfcfd; }
.check-row { display: flex; align-items: center; gap: 8px; color: #526174; font-size: 11px; margin: 10px 0; }.check-row input { width: 15px; height: 15px; accent-color: var(--orange); }
.image-load-failed { opacity: .45; background: repeating-linear-gradient(135deg, rgba(148,163,184,.16) 0 8px, transparent 8px 16px); }
.image-group-heading { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }.image-group-heading span { color: #526174; font-size: 11px; font-weight: 600; }.image-group-heading small { color: #98a2b3; font-size: 9px; }
.image-group-actions { display: flex; align-items: center; gap: 8px; min-width: 0; }.group-mode-button { display: inline-flex; align-items: center; gap: 5px; flex: 0 0 auto; border: 1px solid #e2e7ed; border-radius: 5px; padding: 7px 9px; background: #fff; color: #718096; font-size: 10px; cursor: pointer; }.group-mode-button svg { width: 13px; }.group-mode-button:hover, .group-mode-button.is-active { border-color: #f7b4a5; color: var(--orange-dark); background: #fff8f6; }
.result-group-label { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 4px 0 -1px; padding: 8px 10px; border: 1px solid #e7ebef; border-radius: 5px; background: #f7f9fb; color: #526174; font: inherit; font-size: 10px; text-align: left; cursor: pointer; }.result-group-label > span { display: inline-flex; align-items: center; gap: 5px; }.result-group-label svg { width: 13px; height: 13px; }.result-group-label:hover, .result-group-label.is-collapsed { border-color: #f2a18f; background: #fff8f6; color: var(--orange-dark); }.result-group-label small { color: #98a2b3; font-size: 9px; }
.result-inline-answer { display: none; grid-column: 1 / -1; margin-top: 8px; padding: 12px; border-top: 1px solid var(--line); background: rgba(242,109,79,.045); border-radius: 7px; }.result-inline-label, .result-inline-answer-label { color: var(--muted); font-size: 10px; letter-spacing: .08em; font-weight: 700; text-transform: uppercase; }.result-inline-question { margin-top: 7px; color: var(--ink); font-size: 13px; line-height: 1.7; white-space: normal; overflow-wrap: anywhere; }.result-inline-divider { margin: 10px 0; border-top: 1px solid var(--line); }.result-inline-answer-text { margin-top: 5px; color: var(--orange-dark); font-size: 18px; font-weight: 800; }.result-inline-explanation { margin-top: 7px; color: var(--muted); font-size: 11px; line-height: 1.65; white-space: pre-line; }.result-inline-image { display: block; max-width: 100%; max-height: 220px; margin: 8px auto; object-fit: contain; border-radius: 5px; }
body.dark-theme .result-group-label:hover, body.dark-theme .result-group-label.is-collapsed { background: #3b2828; border-color: #d47760; color: #ffd2c6; }
body.dark-theme .result-inline-answer { background: rgba(242,109,79,.08); border-color: #334760; }
@media (max-width: 760px) { .result-inline-answer { display: block; } }
@media (max-width: 640px) { .image-group-actions { align-items: stretch; flex-direction: column; }.group-mode-button { justify-content: center; }.image-group-tools { padding: 9px; } }
.search-box { border-width: 2px; border-color: #e79a88; box-shadow: 0 5px 18px rgba(242,109,79,.08); }
.search-box:focus-within { border-color: var(--orange); box-shadow: 0 0 0 4px rgba(242,109,79,.16), 0 8px 24px rgba(242,109,79,.12); }
.search-box input { font-size: 14px; font-weight: 500; }
body.dark-theme .search-box { border-color: #d47760; box-shadow: 0 5px 22px rgba(0,0,0,.22); }
body.dark-theme .search-box:focus-within { border-color: var(--orange); }
body.dark-theme .search-box input::placeholder { color: #bdc9d8; }

body.font-system { --app-font: "Microsoft YaHei", "微软雅黑", Arial, sans-serif; }
body.font-yahei { --app-font: "Microsoft YaHei", "微软雅黑", "Noto Sans SC", sans-serif; }
body.font-song { --app-font: SimSun, "宋体", "Noto Serif CJK SC", serif; }
body.font-kai { --app-font: KaiTi, "楷体", STKaiti, "Kaiti SC", "Noto Serif CJK SC", serif; }
body.font-fangsong { --app-font: FangSong, "仿宋", STFangsong, "Noto Serif CJK SC", serif; }
body.font-xingkai { --app-font: "STXingkai", "华文行楷", KaiTi, "Kaiti SC", cursive; }
body.practice-away .practice-card { filter: blur(18px); pointer-events: none; }

/* 客服入口与品牌 Logo */
.brand-logo { width: 34px; height: 34px; flex: 0 0 auto; display: block; border-radius: 10px; object-fit: cover; box-shadow: 0 5px 14px rgba(242,109,79,.22); }
.support-button { min-height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 11px; border: 1px solid rgba(242,109,79,.32); border-radius: 7px; color: var(--orange-dark); background: rgba(242,109,79,.08); font-size: 11px; font-weight: 700; white-space: nowrap; cursor: pointer; transition: background .15s ease, border-color .15s ease, transform .15s ease; }
.support-button svg { width: 15px; height: 15px; }
.support-button:hover { background: rgba(242,109,79,.15); border-color: var(--orange); transform: translateY(-1px); }
.support-dialog { width: min(440px, calc(100vw - 28px)); max-height: calc(100dvh - 28px); padding: 0; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); color: var(--ink); box-shadow: 0 26px 70px rgba(5,12,24,.32); }
.support-dialog::backdrop { background: rgba(5,12,24,.62); backdrop-filter: blur(3px); }
.support-dialog-card { position: relative; padding: 25px; text-align: center; }
.support-dialog-close { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); color: var(--muted); font-size: 22px; line-height: 1; cursor: pointer; }
.support-dialog-close:hover { color: var(--ink); background: rgba(148,163,184,.1); }
.support-dialog-icon { width: 42px; height: 42px; display: grid; place-items: center; margin: 0 auto 10px; border-radius: 12px; background: rgba(7,193,96,.1); color: #07a94f; }
.support-dialog-icon svg { width: 22px; height: 22px; }
.support-dialog h2 { margin-top: 5px; font-size: 22px; }
.support-dialog-lead { margin: 8px auto 16px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.support-qr-frame { width: min(300px, 100%); margin: 0 auto; padding: 10px; border: 1px solid var(--line); border-radius: 13px; background: #fff; box-shadow: 0 10px 28px rgba(5,12,24,.08); }
.support-qr-frame img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; user-select: auto; -webkit-user-drag: auto; }
.support-dialog-mobile-tip { margin: 13px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.support-dialog-actions { display: flex; justify-content: center; gap: 9px; margin-top: 17px; }
.support-dialog-actions > * { min-width: 122px; min-height: 39px; justify-content: center; }
.support-download { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.support-download svg { width: 15px; height: 15px; }
body.dark-theme .support-button { color: #ffd2c6; border-color: #7d463c; background: #35241f; }
body.dark-theme .support-button:hover { border-color: #d47760; background: #472c26; }
body.dark-theme .support-dialog, body.dark-theme .support-dialog-close { background: #111b2d; border-color: #344760; }
body.dark-theme .support-dialog-close { color: #b8c6d8; }
body.dark-theme .support-qr-frame { border-color: #344760; }
@media (max-width: 760px) {
  .support-button { min-height: 36px; padding: 0 9px; }
  .support-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
  .support-dialog-card { padding: 22px 16px 18px; }
}
@media (max-width: 430px) {
  .support-button { width: 36px; min-width: 36px; padding: 0; }
  .support-button span { display: none; }
  .support-dialog-actions { flex-direction: column-reverse; }
  .support-dialog-actions > * { width: 100%; }
}
[hidden] { display: none !important; }
.practice-options { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 9px; }
.practice-option { display: inline-flex; align-items: center; gap: 9px; padding: 12px 22px; min-width: 112px; justify-content: center; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--ink); font-weight: 700; transition: background .15s ease, border-color .15s ease, color .15s ease, transform .1s ease; }
.practice-option:hover { border-color: var(--orange); background: rgba(242,109,79,.08); transform: translateY(-1px); }
.practice-option:has(input:checked), .practice-option.is-selected { border-color: var(--orange); background: var(--orange); color: #fff; box-shadow: 0 5px 14px rgba(242,109,79,.24); }
.practice-option input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.practice-question-options { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.practice-question-option { min-width: min(100%, 220px); justify-content: flex-start; }
body.dark-theme .practice-option { background: #17243a; border-color: #334760; color: #e5edf8; }
body.dark-theme .practice-option:hover { background: #263a58; border-color: #f08b73; }
body.dark-theme .practice-option:has(input:checked), body.dark-theme .practice-option.is-selected { background: #c95e45; border-color: #ff9a7f; color: #fff; }
body.dark-theme .practice-heading > div > p:not(.section-kicker) { color: #c3cfdd; }
body.dark-theme .practice-type-tab { color: #c0ccdb; background: #17243a; border-color: #3a4d66; }
body.dark-theme .practice-type-tab:hover, body.dark-theme .practice-type-tab.is-active { color: #fff4ef; background: #63372f; border-color: #f08b73; }
[hidden] { display: none !important; }
.practice-question .question-image { max-width: min(100%, 920px); max-height: min(60vh, 620px); margin: 0 auto; }
.font-setting { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin: -2px 0 11px; }
.font-setting label { color: #8d99aa; font-size: 10px; }
.font-setting select { min-width: 112px; height: 30px; padding: 0 8px; border: 1px solid #e2e7ed; border-radius: 5px; background: #fff; color: #526174; font-size: 10px; outline: 0; }
.font-setting select:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(242,109,79,.1); }
.consent-dialog { width: min(450px, calc(100vw - 32px)); border: 1px solid var(--line); border-radius: 12px; padding: 0; color: var(--ink); background: var(--panel); box-shadow: 0 24px 80px rgba(18,31,53,.24); }
.consent-dialog::backdrop { background: rgba(16,24,40,.5); backdrop-filter: blur(2px); }
.consent-dialog form { padding: 25px; }
.consent-scroll { max-height: min(52vh, 420px); overflow: auto; padding-right: 6px; }
.consent-scroll strong { color: var(--ink); }
.consent-version { color: #98a2b3 !important; font-size: 10px !important; }
.consent-dialog h2 { margin: 9px 0 9px; }
.consent-dialog p { color: var(--muted); font-size: 12px; line-height: 1.7; margin: 7px 0; }
.consent-check { display: flex; align-items: flex-start; gap: 8px; margin: 19px 0 4px; color: #526174; font-size: 11px; line-height: 1.6; cursor: pointer; }
.consent-check input { width: 16px; height: 16px; flex: 0 0 auto; margin: 2px 0 0; accent-color: var(--orange); }
.consent-dialog .primary-button:disabled { opacity: .45; cursor: not-allowed; }
body.dark-theme .font-setting label { color: #aebbd0; }
body.dark-theme .font-setting select { background: #17253a; border-color: #334760; color: #d9e3ef; }
body.dark-theme .consent-dialog { background: #111b2d; color: var(--ink); border-color: #344760; }
body.dark-theme .consent-check { color: #c2cede; }
body.dark-theme .consent-scroll strong { color: #f2f5f8; }
@media (max-width: 430px) { .font-setting { justify-content: space-between; }.font-setting select { flex: 1; } }

@media (max-width: 760px) {
  .topbar { position: sticky; z-index: 35; top: 58px; }
  .page-scroll { overflow: visible; }
  .search-submit { width: 42px; height: 42px; flex: 0 0 42px; }
  .clear-search, .stop-search { min-width: 36px; min-height: 40px; flex: 0 0 auto; }
  .scope-segmented button, .semantic-toggle, .quick-tags button { min-height: 40px; }
  /* On phones, let the document carry the scroll so the first result cannot
     appear stuck inside a nested scrolling panel. */
  .result-pane { overflow: visible; }
  .result-pane .result-list { max-height: none; overflow: visible !important; overscroll-behavior: auto; scrollbar-gutter: auto; }
  .load-more-button { min-height: 44px; }
}

@media (max-width: 430px) {
  .top-summary-item small { white-space: nowrap; }
  .top-summary-item > svg { display: none; }
  .mobile-license-button { min-width: 62px; min-height: 38px; }
  .result-pane .result-list { max-height: none; }
}

@media (max-width: 760px) and (max-height: 600px) {
  .result-pane .result-list { max-height: none; }
}
.support-contact-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 13px 0 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; color: var(--muted); background: rgba(148,163,184,.06); font-size: 12px; text-align: left; }
.support-contact-row strong { color: var(--ink); user-select: text; }
.support-contact-row .secondary-button { min-height: 34px; padding: 0 12px; flex: 0 0 auto; }
.support-hours { margin: 10px 0 0; color: var(--muted); font-size: 11px; }
.update-banner { position: fixed; right: 22px; bottom: 22px; z-index: 300; width: min(440px, calc(100vw - 32px)); display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 14px; border: 1px solid rgba(242,109,79,.28); border-radius: 12px; color: var(--ink); background: var(--panel); box-shadow: 0 18px 46px rgba(16,24,40,.2); }
.update-banner > span { font-size: 12px; line-height: 1.5; }
.update-banner > div { display: flex; gap: 7px; flex: 0 0 auto; }
.update-banner button { min-height: 34px; padding: 0 12px; }
body.dark-theme .support-contact-row { border-color: #344760; background: #17243a; }
body.dark-theme .update-banner { border-color: #704237; background: #111b2d; }
@media (max-width: 560px) {
  .support-contact-row { align-items: stretch; flex-direction: column; text-align: center; }
  .support-contact-row .secondary-button { width: 100%; }
  .update-banner { right: 10px; bottom: max(10px, env(safe-area-inset-bottom)); left: 10px; width: auto; align-items: stretch; flex-direction: column; }
  .update-banner > div { display: grid; grid-template-columns: 1fr 1fr; }
}

/* Visual refinement: stronger hierarchy, calmer surfaces, and clearer actions. */
:root {
  --canvas: #f3f6f9;
  --panel: #ffffff;
  --line: #dfe6ee;
  --shadow: 0 20px 48px rgba(20, 35, 55, .08);
}
body { background: var(--canvas); }
.sidebar { width: 258px; padding: 30px 20px 20px; background: linear-gradient(180deg, #0d1728 0%, #142238 100%); }
.brand-lockup { padding: 0 10px 38px; }
.brand-logo { width: 40px; height: 40px; border-radius: 12px; box-shadow: 0 8px 20px rgba(242,109,79,.25); }
.brand-name { font-size: 18px; letter-spacing: .01em; }
.brand-caption { font-size: 8px; letter-spacing: .2em; }
.sidebar-nav { gap: 8px; }
.nav-item { min-height: 44px; padding: 12px 13px; border: 1px solid transparent; }
.nav-item.is-active { border-color: rgba(255,255,255,.08); background: rgba(255,255,255,.1); box-shadow: inset 3px 0 0 var(--orange), 0 8px 18px rgba(0,0,0,.12); }
.sidebar-tip { border-radius: 14px; padding: 16px 15px; background: rgba(255,255,255,.055); }
.topbar { min-height: 76px; padding: 0 clamp(18px, 3vw, 42px); border-bottom-color: rgba(214,223,233,.9); background: rgba(255,255,255,.9); box-shadow: 0 5px 22px rgba(28,42,60,.035); backdrop-filter: blur(14px); }
.breadcrumb { color: #617087; font-size: 12px; }
.top-summary-item { min-width: 112px; padding: 8px 11px; border-radius: 10px; background: rgba(255,255,255,.8); }
.top-summary-item strong { font-size: 16px; }
.page-scroll { padding: 34px clamp(18px, 3vw, 42px) 58px; }
.page-heading { margin-bottom: 22px; padding: 28px 30px; border-radius: 18px; border-color: rgba(211,221,232,.9); background: linear-gradient(135deg, #ffffff 0%, #f7fbff 70%, #fff7f3 100%); box-shadow: 0 18px 42px rgba(22, 40, 64, .07); }
.page-heading::after { width: 5px; }
.page-heading h1 { font-size: clamp(28px, 3.2vw, 42px); letter-spacing: -.035em; }
.page-heading .section-subtitle { max-width: 760px; font-size: 14px; line-height: 1.75; }
.heading-actions { gap: 9px; }
.primary-button, .secondary-button { min-height: 42px; border-radius: 9px; padding: 11px 16px; }
.primary-button { box-shadow: 0 10px 18px rgba(242,109,79,.2); }
.workbench-grid { gap: 20px; }
.search-panel { padding: 23px 23px 19px; border-radius: 16px; border-color: #dbe4ed; box-shadow: 0 17px 36px rgba(25, 43, 66, .07); }
.search-label-row label { font-size: 13px; }
.search-box { height: 52px; border-radius: 10px; padding-left: 15px; background: #fbfcfe; }
.search-box input { font-size: 13px; }
.search-submit { width: 36px; height: 36px; border-radius: 8px; }
.scope-segmented { border-radius: 9px; background: #f1f5f8; }
.scope-segmented button { min-height: 34px; border-radius: 7px; padding-inline: 16px; }
.quick-tags button { border: 1px solid #e4eaf0; border-radius: 999px; padding: 7px 11px; background: #f8fafc; }
.quick-tags button:hover { border-color: #f4b3a4; }
.search-help { border-radius: 11px; padding: 13px; background: #f8fafc; }
.answer-header { margin-bottom: 12px; }
.answer-header h2 { font-size: 23px; }
.answer-card, .result-item, .practice-card { border-radius: 14px; border-color: #dfe6ee; box-shadow: 0 14px 30px rgba(25,43,66,.055); }
.answer-card { padding: 26px 27px 22px; }
.answer-card.empty { min-height: 250px; background: linear-gradient(135deg, #fff, #f9fbfd); }
.result-list { gap: 9px; }
.result-item { padding: 14px 15px; }
.result-item:hover, .result-item.is-selected { border-color: #f1a18f; background: #fffaf8; box-shadow: 0 10px 22px rgba(242,109,79,.08); }
.result-media-indicator { width: 32px; height: 32px; border-radius: 9px; }
.image-group-tools { border-radius: 12px; border-color: #dfe6ee; background: #fbfcfe; }
.practice-heading { margin-bottom: 16px; }
.practice-heading h2 { font-size: 27px; }
.practice-type-tab { min-height: 36px; border-radius: 999px; padding-inline: 13px; }
.practice-type-tab:hover, .practice-type-tab.is-active { background: #fff4f0; border-color: #f3b09f; }
.practice-card { padding: 28px; }
.practice-empty { min-height: 280px; }
.practice-empty svg { width: 42px; height: 42px; padding: 9px; border-radius: 13px; background: #fff0eb; }
.practice-option { min-height: 48px; border-radius: 10px; padding: 13px 15px; }
.site-footer { padding-top: 38px; }
body.dark-theme .topbar { background: rgba(13,23,40,.92); border-bottom-color: #27384e; }
body.dark-theme .page-heading { background: linear-gradient(135deg, #152238, #132035 70%, #2b211f); border-color: #2a3d54; }
body.dark-theme .search-panel, body.dark-theme .answer-card, body.dark-theme .result-item, body.dark-theme .practice-card { box-shadow: 0 18px 38px rgba(0,0,0,.18); }
body.dark-theme .search-box, body.dark-theme .search-help { background: #101c2e; }
body.dark-theme .quick-tags button { background: #18263b; border-color: #2e4159; }
@media (max-width: 760px) {
  .topbar { min-height: 64px; }
  .page-scroll { padding: 20px 14px 40px; }
  .page-heading { padding: 21px 19px; border-radius: 15px; }
  .page-heading h1 { font-size: 27px; }
  .search-panel { padding: 17px 15px 15px; border-radius: 13px; }
  .answer-card { padding: 19px 17px 17px; }
  .practice-card { padding: 19px 16px; }
}
@media (max-width: 760px) {
  /* 最终覆盖移动端页面间距，保证固定快捷栏不遮挡最后内容。 */
  .page-scroll { padding-bottom: calc(76px + env(safe-area-inset-bottom)); scroll-padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  .mobile-action-bar { padding-right: max(8px, env(safe-area-inset-right)); }
}
