:root { font-family: system-ui, -apple-system, "Microsoft YaHei", sans-serif; color: #182921; background: #f4f7f5 }
* { box-sizing: border-box }
body { margin: 0; line-height: 1.6 }
.shell { max-width: 820px; margin: 28px auto; padding: 0 18px 40px }
.shell.wide { max-width: 1240px }
header { display: flex; justify-content: space-between; align-items: baseline; gap: 16px }
h1 { font-size: 1.45rem; margin: 0 0 18px }
h2 { font-size: 1.22rem; margin: 0 0 14px }
h3 { font-size: 1.05rem; margin: 18px 0 8px }
.card { background: white; border: 1px solid #dce7e0; border-radius: 12px; padding: 22px; margin-bottom: 16px }
.muted { color: #52665c }
.error { color: #9b2525; background: #fff0f0; border: 1px solid #efb7b7; padding: 11px 14px; border-radius: 8px; margin-bottom: 16px }
#notice:not([hidden]) { color: #9b2525; background: #fff0f0; border: 1px solid #efb7b7; padding: 11px 14px; border-radius: 8px; margin-bottom: 16px }
#preview-note:not([hidden]) { color: #5d3c00; background: #fff1d1; border: 1px solid #e8c270; padding: 11px 14px; border-radius: 8px; margin-bottom: 16px }
.test-restart { margin: 0 0 0 14px; padding: 6px 12px; background: #765418 }
label { display: block; font-weight: 600; margin: 14px 0 6px }
input[type=text], input[type=number], select, textarea { width: 100%; padding: 10px 12px; border: 1px solid #abbeb2; border-radius: 7px; font: inherit; background: white }
fieldset { border: 1px solid #dce7e0; border-radius: 7px; margin: 18px 0; padding: 8px 12px }
legend { font-weight: 600; padding: 0 5px }
select:disabled { background: #f1f4f2; color: #52665c }
textarea { min-height: 115px; resize: vertical }
button { border: 0; background: #225b45; color: white; padding: 11px 20px; border-radius: 7px; cursor: pointer; font: inherit; font-weight: 600; margin-top: 12px }
button:disabled { opacity: .5; cursor: default }
.choice { display: block; border: 1px solid #d6e4dc; padding: 12px; border-radius: 7px; margin: 10px 0; font-weight: 400; cursor: pointer }
.choice input { margin-right: 9px }
.history { max-height: 340px; overflow: auto; border: 1px solid #e0e8e3; padding: 12px; border-radius: 7px; background: #f9fbfa }
.turn { margin: 8px 0; padding: 8px; border-bottom: 1px solid #e6eeea; white-space: pre-wrap }
.turn strong { display: block }
.thinking { display: flex; align-items: center; gap: 9px; color: #225b45; font-weight: 600; margin-top: 12px }
.thinking[hidden] { display: none }
.thinking-dot { width: 10px; height: 10px; border-radius: 50%; background: #2b7558; animation: thinking-pulse 1s ease-in-out infinite }
@keyframes thinking-pulse { 0%, 100% { opacity: .3; transform: scale(.75) } 50% { opacity: 1; transform: scale(1) } }
@media (prefers-reduced-motion: reduce) { .thinking-dot { animation: none } }
.progress { height: 9px; background: #dfe8e3; border-radius: 10px; overflow: hidden; margin: 8px 0 18px }
.progress > div { height: 100%; background: #225b45 }
.inline { display: flex; gap: 12px; align-items: center }
.inline input[type=checkbox] { width: auto }
.info { background: #edf6f0; border-left: 4px solid #225b45; padding: 12px; margin: 12px 0; white-space: pre-wrap }
.task-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 340px); gap: 24px; align-items: start }
.task-main { min-width: 0 }
.task-assistant { position: sticky; top: 16px; min-width: 0; padding: 0 0 0 20px; border-left: 1px solid #dce7e0 }
.task-assistant h3 { margin-top: 0 }
.task-assistant .history { max-height: 380px }
ul { padding-left: 22px }
@media (max-width: 760px) {
  .shell { margin: 12px auto }
  .card { padding: 16px }
  .task-layout { grid-template-columns: minmax(0, 1fr) }
  .task-assistant { position: static; border-left: 0; border-top: 1px solid #dce7e0; padding: 18px 0 0 }
}
