:root {
  --bg: #0f1419;
  --card: #1a2027;
  --border: #2d3742;
  --text: #d8dee6;
  --dim: #8b98a5;
  --gold: #d4a574;
  --accent: #f09a3e;
  --head: #e8b98a;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  background: radial-gradient(1000px 420px at 50% -60px, rgba(240,154,62,.10), transparent 60%), var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  line-height: 1.75;
  min-height: 100vh;
}
.topbar { text-align: center; padding: 36px 16px 18px; }
.topbar h1 { color: var(--gold); font-size: 1.9rem; letter-spacing: 2px; }
.subtitle { color: var(--dim); font-size: .85rem; margin-top: 8px; }
.container { max-width: 980px; margin: 0 auto; padding: 8px 16px 40px; }
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 24px;
  margin-bottom: 18px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
}
.card h2 {
  color: var(--head);
  font-size: 1.12rem;
  border-bottom: 1px solid rgba(212,165,116,.18);
  padding-bottom: 8px;
  margin: 18px 0 12px;
  letter-spacing: 1px;
}
.card h2:first-child { margin-top: 0; }
.hint { color: var(--dim); font-size: .82rem; margin-bottom: 10px; }
code { background: #23303c; color: #e8b98a; padding: 1px 6px; border-radius: 4px; font-size: .85em; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
@media (max-width: 720px) { .grid2 { grid-template-columns: 1fr; } }
label { display: flex; flex-direction: column; font-size: .86rem; color: var(--dim); gap: 5px; }
input, select, textarea {
  background: #12181f;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  font-size: .95rem;
  width: 100%;
  font-family: inherit;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
.pillars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 6px; }
@media (max-width: 720px) { .pillars { grid-template-columns: 1fr 1fr; } }
.pillar { font-size: 1.05rem; letter-spacing: 2px; text-align: center; }
textarea { resize: vertical; min-height: 70px; }
.actions { display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
button {
  border: none; border-radius: 9px; padding: 11px 22px;
  font-size: .95rem; cursor: pointer; font-family: inherit;
  transition: filter .15s;
}
button:hover { filter: brightness(1.12); }
.primary { background: linear-gradient(135deg, #f09a3e, #d97b29); color: #1a1206; font-weight: 700; }
.ghost { background: #23303c; color: var(--text); }
.output-card { display: block; }
.output-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.output-head h2 { margin: 0; border: none; padding: 0; }
.output-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.output-actions button { padding: 7px 14px; font-size: .84rem; background: #23303c; color: var(--text); }
.word-count { color: var(--accent); font-weight: 700; font-size: .92rem; }
.report {
  margin-top: 16px;
  padding: 26px 30px;
  background: #f5f1e8;
  color: #2b2b2b;
  border-radius: 10px;
  font-family: "Songti SC", "SimSun", "Noto Serif SC", serif;
  font-size: 15.5px;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 75vh;
  overflow-y: auto;
  line-height: 2;
}
.foot { text-align: center; color: var(--dim); font-size: .78rem; padding: 10px 16px 34px; }
#btn-generate:disabled { opacity: .55; cursor: wait; }