:root {
  color-scheme: light;
  --page: #f5f9ff;
  --surface: #ffffff;
  --surface-soft: #f7faff;
  --blue: #2563eb;
  --blue-dark: #1746b8;
  --blue-soft: #eaf2ff;
  --cyan: #0ea5e9;
  --green: #12a978;
  --red: #df5262;
  --amber: #d98b18;
  --text: #17243d;
  --muted: #6c7b92;
  --muted-light: #9aa7ba;
  --line: #e3ebf6;
  --line-strong: #c8d9f2;
  --shadow: 0 18px 55px rgba(39, 78, 142, .09);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  min-width: 320px;
  color: var(--text);
  background: var(--page);
  font-family: "Manrope", "Noto Sans SC", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.page-glow {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 0%, rgba(111, 183, 255, .18), transparent 29%),
    radial-gradient(circle at 88% 18%, rgba(82, 141, 255, .1), transparent 25%),
    linear-gradient(rgba(52, 112, 210, .025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(52, 112, 210, .025) 1px, transparent 1px);
  background-size: auto, auto, 40px 40px, 40px 40px;
  mask-image: linear-gradient(to bottom, #000 0 50%, transparent 90%);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 max(24px, calc((100vw - 1320px) / 2));
  border-bottom: 1px solid rgba(209, 222, 240, .9);
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(18px);
}
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark { display: grid; place-items: center; flex: 0 0 auto; width: 48px; height: 42px; padding: 2px; border: 1px solid #e2ebf5; border-radius: 11px; background: #fff; box-shadow: 0 7px 18px rgba(34, 91, 154, .11); overflow: hidden; }
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 17px; letter-spacing: .04em; }
.brand strong { white-space: nowrap; }
.brand small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.topbar-status { display: flex; align-items: center; gap: 8px; }
.status-pill { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--surface); font-size: 11px; }
.status-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted-light); }
.status-pill.online { color: #418770; background: #f1fbf7; border-color: #d7f1e6; }
.status-pill.online i { background: var(--green); box-shadow: 0 0 0 3px rgba(18,169,120,.1); }
.status-pill.failed { color: #b64350; background: #fff6f7; border-color: #f5d8dc; }
.status-pill.failed i { background: var(--red); }
.status-pill.model.ready { color: #2762c7; background: #f3f7ff; border-color: #d9e6fb; }
.status-pill.model.ready i { background: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.status-pill.model.fallback { color: #92703d; background: #fffaf2; border-color: #f4e6c8; }
.status-pill.model.fallback i { background: var(--amber); }
.status-pill.model.reconnecting { color: #3c6fae; background: #f4f8ff; border-color: #d7e5fa; }
.status-pill.model.reconnecting i { background: var(--cyan); animation: reconnectPulse 1s infinite; }
@keyframes reconnectPulse { 50% { opacity: .3; transform: scale(.72); } }
.provider-switch { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 7px 0 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: #fff; font-size: 10px; }
.provider-switch select { max-width: 105px; border: 0; outline: 0; color: var(--blue-dark); background: transparent; font-size: 10px; font-weight: 600; cursor: pointer; }
.help-button, .clear-button { border: 0; color: var(--muted); background: transparent; }
.help-button { padding: 7px 9px; font-size: 12px; }
.help-button:hover, .clear-button:hover { color: var(--blue); }
.execution-toggle { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; color: #52647d; background: #fff; font-size: 10px; transition: .18s; }
.execution-toggle i { width: 7px; height: 7px; border: 1.5px solid var(--blue); border-radius: 50%; box-shadow: 0 0 0 3px rgba(37,99,235,.08); }
.execution-toggle:hover, .execution-toggle[aria-pressed="true"] { color: var(--blue); border-color: #b7cff5; background: #f5f9ff; }

.execution-panel { position: fixed; z-index: 40; right: 14px; top: 84px; bottom: 14px; display: flex; flex-direction: column; width: min(390px, calc(100vw - 28px)); border: 1px solid #d7e3f4; border-radius: 18px; background: rgba(255,255,255,.98); box-shadow: 0 25px 75px rgba(28,55,96,.2); transform: translateX(calc(100% + 30px)); opacity: 0; pointer-events: none; transition: transform .24s ease, opacity .2s ease; }
.execution-panel.open { transform: translateX(0); opacity: 1; pointer-events: auto; }
.execution-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 20px 20px 15px; border-bottom: 1px solid var(--line); }
.execution-head span, .execution-head strong { display: block; }
.execution-head span { color: var(--blue); font-size: 8px; font-weight: 700; letter-spacing: .15em; }
.execution-head strong { margin-top: 5px; font-size: 16px; }
.execution-head button { width: 30px; height: 30px; border: 0; border-radius: 8px; color: var(--muted); background: #f3f6fa; font-size: 18px; }
.execution-summary { display: flex; gap: 10px; margin: 14px 16px 8px; padding: 11px 12px; border: 1px solid #dce8f8; border-radius: 11px; background: #f5f9ff; }
.execution-summary > i { flex: 0 0 auto; width: 8px; height: 8px; margin-top: 4px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px rgba(37,99,235,.1); }
.execution-summary p { margin: 0; }
.execution-summary strong, .execution-summary span { display: block; }
.execution-summary strong { font-size: 10px; }
.execution-summary span { margin-top: 3px; color: var(--muted); font-size: 8px; line-height: 1.55; }
.execution-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin: 6px 16px 2px; padding: 3px; border-radius: 9px; background: #eef3f9; }
.execution-tabs button { height: 29px; border: 0; border-radius: 7px; color: var(--muted); background: transparent; font-size: 9px; font-weight: 600; }
.execution-tabs button.active { color: var(--blue); background: #fff; box-shadow: 0 2px 8px rgba(48,75,116,.09); }
.execution-list { display: none; flex: 1; min-height: 0; overflow: auto; padding: 8px 16px 12px; scrollbar-width: thin; scrollbar-color: #c8d7ea transparent; }
.execution-list.active { display: block; }
.execution-empty { display: grid; place-items: center; min-height: 180px; color: var(--muted-light); font-size: 10px; text-align: center; line-height: 1.7; }
.execution-item { position: relative; display: grid; grid-template-columns: 10px minmax(0,1fr) auto; gap: 9px; padding: 10px 0; border-bottom: 1px solid #edf2f8; }
.execution-item:last-child { border-bottom: 0; }
.execution-dot { width: 8px; height: 8px; margin-top: 4px; border: 2px solid #9eb7db; border-radius: 50%; background: #fff; }
.execution-item.success .execution-dot { border-color: var(--green); background: #e7f8f2; }
.execution-item.warning .execution-dot { border-color: var(--amber); background: #fff4df; }
.execution-item.error .execution-dot { border-color: var(--red); background: #fff0f2; }
.execution-item.active .execution-dot { border-color: var(--blue); background: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.execution-item.decision .execution-dot { border-color: #6c7cff; background: #eef0ff; }
.execution-copy strong, .execution-copy span { display: block; }
.execution-copy strong { font-size: 10px; font-weight: 600; }
.execution-copy span { margin-top: 4px; color: var(--muted); font-size: 8px; line-height: 1.55; word-break: break-word; }
.execution-item time { color: var(--muted-light); font-size: 8px; }
.execution-foot { display: flex; align-items: center; justify-content: space-between; padding: 11px 16px; border-top: 1px solid var(--line); color: var(--muted-light); font-size: 8px; }
.execution-foot > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.execution-foot > div { display: flex; flex: 0 0 auto; gap: 6px; margin-left: 8px; }
.execution-foot button { padding: 5px 8px; border: 0; border-radius: 6px; color: var(--muted); background: #f1f5fa; font-size: 8px; }
.execution-backdrop { position: fixed; z-index: 35; inset: 0; display: none; width: 100%; height: 100%; padding: 0; border: 0; background: rgba(26,43,68,.18); backdrop-filter: blur(2px); }
.execution-backdrop.open { display: none; }

.page { width: min(1320px, calc(100% - 48px)); margin: 0 auto; }
.intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; width: min(1080px, 100%); margin: 0 auto; padding: 36px 4px 25px; }
.intro-kicker, .section-label { color: var(--blue); font-size: 10px; font-weight: 700; letter-spacing: .13em; }
.intro h1 { margin: 9px 0 8px; font-size: clamp(28px, 3.4vw, 42px); line-height: 1.18; letter-spacing: -.04em; }
.intro p { max-width: 680px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.75; }
.intro-metrics { display: flex; align-items: center; flex: 0 0 auto; padding: 13px 18px; border: 1px solid rgba(217, 227, 242, .9); border-radius: 14px; background: rgba(255, 255, 255, .7); box-shadow: 0 12px 34px rgba(53, 85, 137, .055); }
.intro-metrics[hidden] { display: none; }
.intro-metrics span { min-width: 66px; text-align: center; }
.intro-metrics strong, .intro-metrics small { display: block; }
.intro-metrics strong { font-size: 20px; }
.intro-metrics small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.intro-metrics i { width: 1px; height: 25px; margin: 0 8px; background: var(--line); }

.app-grid { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); width: min(1080px, 100%); min-height: 470px; height: calc(100vh - 245px); margin: 0 auto; }
.chat-card { border: 1px solid rgba(217, 227, 242, .95); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow); }
.chat-card { display: flex; flex-direction: column; min-width: 0; min-height: 0; overflow: hidden; }
.chat-head { display: flex; align-items: flex-start; justify-content: space-between; }
.chat-head { gap: 20px; padding: 22px 24px 18px; border-bottom: 1px solid #edf2f8; }
.chat-head h2 { margin: 5px 0 0; font-size: 19px; letter-spacing: -.02em; }
.chat-head-actions { display: flex; align-items: center; gap: 10px; }
.agent-mode-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border: 1px solid #d8e4f4; border-radius: 12px; background: #f3f7fc; }
.agent-mode-switch button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 104px; height: 34px; padding: 0 12px; border: 0; border-radius: 8px; color: #667992; background: transparent; font-size: 12px; font-weight: 600; transition: .18s ease; }
.agent-mode-switch button i { width: 7px; height: 7px; border-radius: 50%; background: #a8b7c9; }
.agent-mode-switch button.active { color: #1f5fca; background: #fff; box-shadow: 0 3px 11px rgba(37,99,235,.12); }
.agent-mode-switch button.active i { background: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.agent-mode-switch button[data-agent-mode="chat"].active { color: #5064cf; }
.agent-mode-switch button[data-agent-mode="chat"].active i { background: #6875dd; box-shadow: 0 0 0 3px rgba(104,117,221,.11); }
.clear-button { display: flex; align-items: center; gap: 5px; padding: 6px; font-size: 11px; }
.clear-button svg, .send-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.message-list { flex: 1; min-height: 140px; overflow: auto; padding: 12px 24px 15px; scrollbar-width: thin; scrollbar-color: #c9d8eb transparent; }
.message { display: flex; gap: 10px; margin: 14px 0; animation: messageIn .22s ease both; }
@keyframes messageIn { from { opacity: 0; transform: translateY(5px); } }
.message.user { justify-content: flex-end; }
.avatar { display: grid; place-items: center; flex: 0 0 auto; width: 36px; height: 36px; border: 1px solid #cae4f7; border-radius: 50%; background: #eef9ff; box-shadow: 0 7px 17px rgba(37,99,235,.14); overflow: hidden; }
.avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.message-body { max-width: calc(100% - 50px); }
.bubble { padding: 10px 13px; border: 1px solid var(--line); border-radius: 4px 13px 13px 13px; color: #40536f; background: #f8faff; font-size: 13px; line-height: 1.72; }
.bubble strong { color: var(--text); }
.message.user .bubble { border: 0; border-radius: 13px 4px 13px 13px; color: #fff; background: linear-gradient(135deg, #3778ee, #2563eb); box-shadow: 0 8px 22px rgba(37,99,235,.14); }
.message-time { margin-top: 5px; color: var(--muted-light); font-size: 9px; }
.message.user .message-time { text-align: right; }
.typing { display: inline-flex; align-items: center; gap: 4px; min-width: 45px; }
.typing i { width: 5px; height: 5px; border-radius: 50%; background: var(--blue); animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; }
.typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%,70%,100% { opacity:.25; transform:translateY(0)} 35% { opacity:1; transform:translateY(-2px)} }

.result-card { margin-top: 8px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; box-shadow: 0 11px 28px rgba(44, 75, 122, .07); }
.result-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #f7faff; }
.result-head strong { font-size: 12px; }
.result-head span { padding: 3px 7px; border-radius: 999px; color: var(--blue); background: var(--blue-soft); font-size: 9px; }
.result-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 8px 12px; border-bottom: 1px solid #edf2f8; color: var(--muted); font-size: 10px; }
.result-toolbar b { color: var(--blue); font-weight: 600; }
.board-row { display: grid; grid-template-columns: minmax(135px, .9fr) minmax(180px, 1.2fr) auto; gap: 10px; align-items: center; padding: 11px 12px; border-bottom: 1px solid #edf2f8; }
.board-row:last-child { border-bottom: 0; }
.selectable-board-row { width: 100%; border: 0; border-bottom: 1px solid #edf2f8; color: inherit; background: #fff; text-align: left; transition: background .18s ease, box-shadow .18s ease; }
.selectable-board-row:hover { background: #f5f9ff; box-shadow: inset 3px 0 var(--blue); }
.selectable-board-row.selected { background: #eef5ff; box-shadow: inset 3px 0 var(--blue); }
.selectable-board-row.selected .resource-state small { color: var(--blue); }
.board-info strong, .board-info span { display: block; }
.board-info strong { font-size: 11px; }
.board-info span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.board-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.board-tags span { padding: 3px 6px; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); background: #fafcff; font-size: 8px; }
.daily-price { color: var(--blue); font-size: 12px; font-weight: 700; white-space: nowrap; }
.daily-price small { margin-left: 2px; color: var(--muted); font-size: 8px; font-weight: 400; }
.resource-state { color: var(--green); font-size: 11px; font-weight: 600; text-align: right; white-space: nowrap; }
.resource-state small { display: block; margin-top: 2px; color: var(--muted); font-size: 8px; font-weight: 400; }
.calendar-resource { padding: 11px 12px; border-bottom: 1px solid #edf2f8; }
.calendar-resource:last-child { border-bottom: 0; }
.calendar-resource-head { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.calendar-resource-head strong { font-size: 10px; }
.calendar-resource-head span { color: var(--muted); font-size: 8px; }
.day-strip { display: grid; grid-template-columns: repeat(7, minmax(28px,1fr)); gap: 5px; }
.day-cell { display: grid; place-items: center; min-height: 38px; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); background: #fafcff; font-size: 7px; }
.day-cell b { color: var(--text); font-size: 10px; }
.day-cell small, .day-cell em { font-size: 7px; font-style: normal; }
.day-cell.available { border-color: #ccecdf; color: #278866; background: #f1fbf7; }
.day-cell.available b { color: #187454; }
.day-cell.occupied { border-color: #f2d9dc; color: #ba5260; background: #fff7f8; }
.day-cell.occupied b { color: #9f3d49; }
.price-hero { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; padding: 11px; }
.price-hero.unit-only { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.price-cell { padding: 10px; border: 1px solid var(--line); border-radius: 8px; background: #fafcff; }
.price-cell.highlight { border-color: #bfd5fb; background: var(--blue-soft); }
.price-cell span, .price-cell small { display: block; color: var(--muted); font-size: 8px; }
.price-cell strong { display: block; margin: 5px 0 2px; font-size: 14px; }
.price-cell.highlight strong { color: var(--blue); }
.formula { margin: 0 11px 11px; padding: 8px 10px; border-left: 3px solid var(--blue); color: var(--muted); background: #f7faff; font-size: 9px; }
.formula strong { color: var(--blue); }
.formula span { display: block; margin-top: 3px; }
.case-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 8px; padding: 10px; }
.case-card { overflow: hidden; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.case-image-button { position: relative; display: block; width: 100%; padding: 0; border: 0; background: #eef4fc; overflow: hidden; }
.case-image-button img { display: block; width: 100%; aspect-ratio: 16/8.5; object-fit: cover; transition: transform .25s ease; }
.case-image-button > span { position: absolute; right: 8px; bottom: 8px; margin: 0; padding: 4px 7px; border-radius: 999px; color: #fff; background: rgba(18,36,63,.72); opacity: 0; font-size: 9px; transition: opacity .2s ease; }
.case-image-button:hover img { transform: scale(1.025); }
.case-image-button:hover > span { opacity: 1; }
.case-card div { padding: 8px; }
.case-card strong, .case-card span { display: block; }
.case-card strong { font-size: 11px; }
.case-card span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.spec-row { padding: 11px 12px; border-bottom: 1px solid #edf2f8; }
.spec-row:last-child { border-bottom: 0; }
.spec-row > div:first-child { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.spec-row > div strong { font-size: 10px; }
.spec-row > div span { color: var(--muted); font-size: 8px; }
.spec-row dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 0; }
.spec-row dl div { padding: 7px; border: 1px solid var(--line); border-radius: 7px; background: #fafcff; }
.spec-row dt { color: var(--muted); font-size: 7px; }
.spec-row dd { margin: 3px 0 0; color: var(--text); font-size: 8px; }
.spec-summary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 12px; }
.spec-summary-grid > div { display: flex; flex-wrap: wrap; align-content: flex-start; gap: 5px; min-height: 70px; padding: 10px; border: 1px solid var(--line); border-radius: 9px; background: #fafcff; }
.spec-summary-grid strong { flex: 0 0 100%; color: var(--text); font-size: 12px; }
.spec-summary-grid span { padding: 4px 7px; border-radius: 6px; color: #506985; background: #eef4fd; font-size: 10px; line-height: 1.45; }
.recommend-row { display: grid; width: 100%; grid-template-columns: 26px minmax(0, 1fr) auto; align-items: center; gap: 9px; padding: 11px 12px; border: 0; border-bottom: 1px solid #edf2f8; color: inherit; background: #fff; text-align: left; font: inherit; }
.recommend-row:last-child { border-bottom: 0; }
.selectable-recommend-row { cursor: pointer; transition: background .18s ease, box-shadow .18s ease; }
.selectable-recommend-row:hover { background: #f5f9ff; box-shadow: inset 3px 0 0 var(--blue); }
.selectable-recommend-row.selected { background: #eef5ff; box-shadow: inset 3px 0 0 var(--blue); }
.recommend-row > i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; color: #fff; background: var(--blue); font-size: 9px; font-style: normal; }
.recommend-row strong, .recommend-row span, .recommend-row small { display: block; }
.recommend-row strong { font-size: 10px; }
.recommend-row span, .recommend-row small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.recommend-row > div:last-child { text-align: right; }
.recommend-row > div:last-child b { color: var(--blue); font-size: 13px; }
.knowledge-card { padding-bottom: 0; }
.knowledge-answer { margin: 0; padding: 13px 13px 8px; color: #3e526f; font-size: 12px; line-height: 1.75; }
.knowledge-card ul { margin: 0; padding: 0 28px 12px; color: var(--muted); font-size: 11px; line-height: 1.75; }
.knowledge-check { margin: 0 12px 12px; padding: 10px; border: 1px solid #cfe0fa; border-radius: 8px; background: #f4f8ff; }
.knowledge-check strong { color: var(--blue); font-size: 9px; }
.knowledge-check p { margin: 4px 0 0; color: #4d6381; font-size: 9px; line-height: 1.65; }
.knowledge-source { padding: 8px 12px; border-top: 1px solid var(--line); color: var(--muted-light); background: #fafcff; font-size: 8px; }
.knowledge-miss { margin-top: 8px; padding: 12px; border: 1px solid #d9e5f5; border-radius: 10px; background: #fafcff; }
.knowledge-miss strong { font-size: 11px; }
.knowledge-miss p { margin: 5px 0 0; color: var(--muted); font-size: 10px; line-height: 1.65; }
.suggestions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.suggestions button, .retry-button { padding: 6px 9px; border: 1px solid #cbdcf6; border-radius: 999px; color: var(--blue); background: #f5f9ff; font-size: 9px; }
.suggestions button:hover, .retry-button:hover { border-color: var(--blue); background: var(--blue-soft); }
.empty-card, .error-card { margin-top: 7px; padding: 11px; border: 1px dashed var(--line-strong); border-radius: 9px; color: var(--muted); background: #fafcff; font-size: 9px; }
.error-card { border-style: solid; border-color: #f2d6da; color: #a74b57; background: #fff8f9; }
.error-card strong { font-size: 9px; }.error-card p { margin: 5px 0 9px; line-height: 1.6; }

.choice-card { margin-top: 8px; border: 1px solid #d8e5f7; border-radius: 12px; overflow: hidden; background: #fff; box-shadow: 0 12px 30px rgba(44,75,122,.075); }
.choice-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #f6f9ff; }
.choice-head > span { padding: 3px 7px; border-radius: 999px; color: #fff; background: var(--blue); font-size: 8px; }
.choice-head strong { flex: 1; font-size: 11px; }
.choice-head em { color: var(--muted); font-size: 8px; font-style: normal; }
.station-choice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; max-height: 230px; padding: 10px; overflow: auto; scrollbar-width: thin; scrollbar-color: #c9d8eb transparent; }
.station-choice-grid button { display: flex; align-items: center; gap: 7px; min-width: 0; padding: 8px; border: 1px solid var(--line); border-radius: 8px; color: #40546f; background: #fbfdff; text-align: left; }
.station-choice-grid button:hover { color: var(--blue); border-color: #a9c5f3; background: #f1f6ff; }
.station-choice-grid i { display: grid; place-items: center; flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; color: var(--blue); background: var(--blue-soft); font-size: 7px; font-style: normal; }
.station-choice-grid span { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.condition-chips { display: flex; flex-wrap: wrap; gap: 5px; padding: 10px 11px 4px; }
.condition-chips span { padding: 4px 7px; border: 1px solid #d6e4f8; border-radius: 999px; color: #3e67a4; background: #f4f8ff; font-size: 8px; }
.choice-tip { margin: 4px 12px 8px; color: var(--muted); font-size: 10px; }
.resource-choice-list { display: grid; gap: 6px; max-height: 220px; padding: 0 10px 9px; overflow: auto; scrollbar-width: thin; scrollbar-color: #c9d8eb transparent; }
.resource-choice { display: grid; grid-template-columns: 23px minmax(0, 1fr) auto; align-items: center; gap: 8px; width: 100%; padding: 9px; border: 1px solid var(--line); border-radius: 9px; color: #566981; background: #fff; text-align: left; transition: .16s; }
.resource-choice:hover { border-color: #b6cdf1; background: #f9fbff; }
.resource-choice.selected { border-color: #abc7f4; background: #f3f7ff; box-shadow: inset 0 0 0 1px rgba(37,99,235,.03); }
.resource-check { display: grid; place-items: center; width: 21px; height: 21px; border: 1px solid #c8d7ea; border-radius: 6px; color: transparent; background: #fff; font-size: 10px; font-style: normal; }
.resource-choice.selected .resource-check { color: #fff; border-color: var(--blue); background: var(--blue); }
.resource-choice strong, .resource-choice small { display: block; }
.resource-choice strong { color: var(--text); font-size: 11px; }
.resource-choice small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.resource-choice em { color: #59708e; font-size: 10px; font-style: normal; font-weight: 600; white-space: nowrap; }
.choice-actions { display: flex; gap: 7px; padding: 10px; border-top: 1px solid var(--line); background: #fafcff; }
.choice-actions button { height: 34px; padding: 0 13px; border-radius: 8px; font-size: 9px; font-weight: 600; }
.confirm-choice { color: #fff; border: 1px solid var(--blue); background: var(--blue); box-shadow: 0 6px 14px rgba(37,99,235,.14); }
.confirm-choice:hover { background: var(--blue-dark); }
.modify-choice { color: #59708e; border: 1px solid var(--line-strong); background: #fff; }
.modify-choice:hover { color: var(--blue); border-color: #9bbbf0; }
.line-tag { position: relative; padding-left: 10px !important; }
.line-tag::before { content: ""; position: absolute; left: 4px; top: 50%; width: 3px; height: 10px; border-radius: 2px; background: var(--line-color); transform: translateY(-50%); }

.composer-wrap { padding: 12px 24px 18px; border-top: 1px solid #edf2f8; background: rgba(255,255,255,.96); }
.composer { display: flex; align-items: flex-end; gap: 10px; min-height: 50px; padding: 8px 9px 8px 12px; border: 1px solid #cbdaf0; border-radius: 14px; background: #fff; box-shadow: 0 8px 24px rgba(42, 83, 145, .07); transition: .2s; }
.composer:focus-within { border-color: #8fb6f5; box-shadow: 0 0 0 4px rgba(37,99,235,.08), 0 8px 24px rgba(42,83,145,.07); }
.composer-mark { display: grid; place-items: center; flex: 0 0 auto; width: 30px; height: 30px; margin-bottom: 1px; border: 1px solid #cae4f7; border-radius: 50%; background: #eef9ff; overflow: hidden; }
.composer-mark img { display: block; width: 100%; height: 100%; object-fit: cover; }
.composer textarea { flex: 1; min-width: 0; max-height: 80px; padding: 7px 0; border: 0; outline: 0; resize: none; color: var(--text); background: transparent; font-size: 14px; line-height: 1.5; }
.composer textarea::placeholder { color: #9aa8bb; }
.send-button { display: grid; place-items: center; flex: 0 0 auto; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 10px; color: #fff; background: linear-gradient(145deg, #397df1, #2563eb); box-shadow: 0 7px 16px rgba(37,99,235,.2); }
.send-button:hover { transform: translateY(-1px); }
.send-button:disabled { opacity: .5; cursor: wait; transform: none; }
.composer-meta { display: flex; justify-content: space-between; margin-top: 7px; color: var(--muted-light); font-size: 8px; }


footer { display: flex; justify-content: space-between; padding: 14px 4px 18px; color: var(--muted-light); font-size: 9px; }
.help-dialog { width: min(470px, calc(100vw - 40px)); padding: 26px; border: 1px solid var(--line); border-radius: 16px; color: var(--text); background: #fff; box-shadow: 0 28px 80px rgba(36,66,108,.22); }
.help-dialog::backdrop { background: rgba(43,61,88,.25); backdrop-filter: blur(5px); }
.help-dialog h2 { margin: 7px 0; }
.help-dialog > p { color: var(--muted); font-size: 11px; line-height: 1.7; }
.dialog-close { position: absolute; right: 13px; top: 12px; width: 30px; height: 30px; border: 0; border-radius: 8px; color: var(--muted); background: #f3f6fa; font-size: 18px; }
.help-examples { display: grid; gap: 7px; margin-top: 16px; }
.help-examples button { padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; color: #49617e; background: #f9fbfe; text-align: left; font-size: 10px; }
.help-examples button:hover { border-color: #a9c5f3; color: var(--blue); background: #f3f7ff; }
.image-preview-dialog { width: min(1080px, calc(100vw - 36px)); max-height: calc(100vh - 36px); padding: 12px; border: 1px solid var(--line); border-radius: 16px; color: var(--text); background: #fff; box-shadow: 0 30px 90px rgba(28,48,78,.3); }
.image-preview-dialog::backdrop { background: rgba(17,31,52,.65); backdrop-filter: blur(5px); }
.image-preview-dialog img { display: block; width: 100%; max-height: calc(100vh - 110px); border-radius: 11px; object-fit: contain; background: #eef3f9; }
.image-preview-dialog > strong { display: block; padding: 10px 4px 2px; font-size: 13px; }

/* V1.1 可读性升级：主要交互文字不低于 10px，正文保持 12–15px。 */
.brand small { font-size: 11px; }
.status-pill, .provider-switch, .provider-switch select, .execution-toggle { font-size: 12px; }
.intro-kicker, .section-label { font-size: 11px; }
.intro-metrics small, .clear-button { font-size: 11px; }
.avatar { font-size: 10px; }
.bubble { font-size: 15px; line-height: 1.68; }
.message-time { font-size: 10px; }
.result-head strong { font-size: 14px; }
.result-head span { font-size: 11px; }
.result-toolbar { font-size: 12px; }
.board-info strong, .resource-state { font-size: 13px; }
.board-info span, .resource-state small { font-size: 11px; }
.board-tags span { font-size: 10px; }
.daily-price { font-size: 14px; }
.daily-price small { font-size: 10px; }
.calendar-resource-head strong { font-size: 12px; }
.calendar-resource-head span { font-size: 10px; }
.day-cell { min-height: 44px; font-size: 9px; }
.day-cell b { font-size: 13px; }
.day-cell small, .day-cell em { font-size: 9px; }
.price-cell span, .price-cell small { font-size: 10px; }
.price-cell strong { font-size: 18px; }
.formula { font-size: 12px; line-height: 1.55; }
.case-card strong { font-size: 13px; }
.case-card span { font-size: 11px; }
.spec-row > div strong, .recommend-row strong { font-size: 12px; }
.spec-row > div span, .recommend-row span, .recommend-row small { font-size: 10px; }
.spec-row dt { font-size: 9px; }
.spec-row dd { font-size: 11px; }
.knowledge-answer { font-size: 14px; }
.knowledge-card ul { font-size: 12px; }
.knowledge-check strong, .knowledge-check p, .knowledge-source { font-size: 10px; }
.knowledge-miss strong { font-size: 13px; }
.knowledge-miss p { font-size: 12px; }
.suggestions button, .retry-button, .empty-card, .error-card { font-size: 11px; }
.free-chat-models { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 10px; padding: 9px 10px; border: 1px solid #dce8f7; border-radius: 10px; background: #f7faff; }
.free-chat-models > span { margin-right: 2px; color: var(--muted); font-size: 11px; }
.free-chat-models button { height: 29px; padding: 0 10px; border: 1px solid #d6e2f3; border-radius: 999px; color: #60738d; background: #fff; font-size: 11px; font-weight: 600; }
.free-chat-models button.active { color: var(--blue); border-color: #a9c8f7; background: #edf5ff; box-shadow: 0 3px 10px rgba(37,99,235,.09); }
.free-chat-models button:disabled { opacity: .45; cursor: not-allowed; }
.choice-head > span, .choice-head em { font-size: 10px; }
.choice-head strong { font-size: 13px; }
.station-choice-grid span { font-size: 11px; }
.condition-chips span { font-size: 10px; }
.choice-tip { font-size: 12px; }
.resource-choice strong { font-size: 13px; }
.resource-choice small, .resource-choice em { font-size: 11px; }
.choice-actions button { font-size: 11px; }
.composer textarea { font-size: 15px; }
.composer-meta { font-size: 10px; }
footer { font-size: 9px; }
.execution-head span { font-size: 10px; }
.execution-summary strong { font-size: 12px; }
.execution-summary span { font-size: 10px; }
.execution-tabs button { font-size: 11px; }
.execution-empty { font-size: 12px; }
.execution-copy strong { font-size: 12px; }
.execution-copy span { font-size: 10px; }
.execution-item time, .execution-foot, .execution-foot button { font-size: 9px; }
.help-dialog > p, .help-examples button { font-size: 12px; }

@media (max-width: 1000px) {
  .page { width: min(100% - 28px, 820px); }
  .intro { align-items: flex-start; padding-top: 28px; }
  .intro-metrics { display: none; }
  .app-grid { grid-template-columns: 1fr; grid-template-rows: auto; height: auto; }
  .chat-card { min-height: 680px; }
}
@media (max-width: 680px) {
  .topbar { position: sticky; top: 0; z-index: 30; height: 58px; padding: 0 12px; }
  .brand small, .status-pill.online, .status-pill.model, .help-button { display: none; }
  .brand-mark { width: 38px; height: 34px; border-radius: 10px; }
  .brand { gap: 8px; }
  .brand strong { font-size: 16px; }
  .topbar-status { gap: 6px; }
  .execution-toggle span { display: none; }
  .execution-toggle { width: 34px; height: 34px; padding: 0; justify-content: center; }
  .execution-panel { top: 66px; right: 8px; bottom: 8px; width: calc(100vw - 16px); }
  .execution-backdrop.open { display: block; }
  .provider-switch > span { display: none; }
  .provider-switch { max-width: 148px; height: 34px; padding-inline: 10px 7px; }
  .provider-switch select { width: 118px; max-width: 118px; font-size: 12px; text-overflow: ellipsis; }
  .status-pill { padding: 0 9px; font-size: 9px; }
  .page { width: calc(100% - 24px); }
  .intro { padding: 12px 4px 10px; }
  .intro-kicker { font-size: 9px; letter-spacing: .1em; }
  .intro h1 { margin: 5px 0; font-size: clamp(21px, 6vw, 24px); line-height: 1.2; }
  .intro p { display: -webkit-box; overflow: hidden; font-size: 11px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 1; }
  .chat-card { border-radius: 16px; }
  .chat-head { flex-direction: column; gap: 11px; padding: 16px 14px 13px; }
  .chat-head h2 { margin-top: 4px; font-size: 18px; }
  .chat-head-actions { width: 100%; }
  .agent-mode-switch { flex: 1; }
  .agent-mode-switch button { min-width: 0; height: 38px; padding-inline: 8px; font-size: 13px; }
  .clear-button { flex: 0 0 38px; justify-content: center; width: 38px; height: 38px; padding: 0; overflow: hidden; font-size: 0; }
  .clear-button svg { width: 18px; height: 18px; }
  .message-list { padding: 10px 14px 16px; }
  .message { gap: 9px; margin: 13px 0; }
  .avatar { width: 34px; height: 34px; }
  .message-body { max-width: calc(100% - 43px); }
  .bubble { padding: 10px 12px; font-size: 14px; line-height: 1.67; }
  .suggestions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .suggestions button { min-height: 36px; padding: 7px 8px; border-radius: 10px; line-height: 1.35; }
  .composer-wrap { padding: 10px 12px calc(12px + env(safe-area-inset-bottom)); }
  .composer { align-items: center; min-height: 68px; padding: 8px 8px 8px 10px; border-radius: 15px; }
  .composer-mark { margin-bottom: 0; }
  .composer textarea { min-height: 50px; padding-block: 4px; font-size: 14px; line-height: 1.5; }
  .send-button { width: 38px; height: 38px; }
  .composer-meta span:first-child { display: none; }
  .composer-meta { justify-content: flex-end; margin-top: 6px; font-size: 9px; }
  .board-row { grid-template-columns: 1fr; }
  .selectable-board-row .resource-state { text-align: left; }
  .price-hero { grid-template-columns: repeat(2,1fr); }
  .case-grid { grid-template-columns: 1fr; }
  .spec-row dl { grid-template-columns: 1fr 1fr; }
  .spec-summary-grid { grid-template-columns: 1fr; }
  .station-choice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .resource-choice { grid-template-columns: 23px minmax(0, 1fr); }
  .resource-choice em { grid-column: 2; }
  .recommend-row { grid-template-columns: 24px minmax(0, 1fr) auto; gap: 8px; padding: 12px 10px; }
  .chat-card { min-height: 0; height: max(520px, calc(100dvh - 166px)); max-height: 700px; }
  footer { padding-inline: 2px; }
}

@media (max-width: 380px) {
  .brand strong { font-size: 14px; }
  .provider-switch { max-width: 132px; }
  .provider-switch select { width: 102px; max-width: 102px; }
  .intro h1 { font-size: 21px; }
  .chat-head h2 { font-size: 17px; }
  .agent-mode-switch button { font-size: 12px; }
}
