:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  background: #f8f9fc;
  color: #151b2d;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.topbar { background: #fff; border-bottom: 1px solid #e7ebf2; }
.topbar-inner { height: 66px; max-width: 1240px; padding: 0 26px; margin: 0 auto; display: flex; align-items: center; gap: 18px; }
.brand { font-size: 21px; font-weight: 800; letter-spacing: -.8px; text-decoration: none; display: inline-flex; align-items: center; gap: 9px; }
.brand-mark { background: #255ee6; color: #fff; height: 30px; width: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 15px; font-weight: 750; }
.topbar-caption { color: #7d8494; font-size: 12px; }
.topbar-link { margin-left: auto; color: #566174; text-decoration: none; font-size: 13px; }
.topbar-link:hover { color: #255ee6; }
.container { max-width: 1240px; padding: 44px 26px 68px; margin: 0 auto; }
.intro { margin-bottom: 30px; }
.eyebrow, .step-label { color: #255ee6; font-weight: 800; font-size: 11px; letter-spacing: 1.15px; }
.intro h1 { margin: 11px 0; font-size: clamp(28px, 3.8vw, 40px); letter-spacing: -1.8px; line-height: 1.2; }
.intro p { color: #677084; margin: 0; font-size: 14px; line-height: 1.75; max-width: 760px; }
.workspace { display: grid; grid-template-columns: minmax(360px, 1.07fr) minmax(360px, .93fr); align-items: start; gap: 20px; }
.panel { border: 1px solid #e3e8f1; border-radius: 19px; background: #fff; box-shadow: 0 9px 30px rgba(28, 45, 76, .035); padding: 28px; min-width: 0; }
.section-header, .questions-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-header h2, .questions-head h2 { margin: 5px 0 0; font-size: 19px; letter-spacing: -.65px; }
.tag { border-radius: 20px; background: #e9f1ff; color: #255ee6; font-weight: 700; font-size: 10px; padding: 6px 10px; white-space: nowrap; }
.tag.muted { background: #f1f3f7; color: #778297; }
.tag.warning { background: #fff0d6; color: #9c6206; }
.field { margin-top: 21px; min-width: 0; }
.field > label, .field-label { display: block; font-weight: 700; font-size: 13px; margin-bottom: 9px; }
.required { color: #255ee6; }
textarea, select, input:not([type="radio"]) { background: #fff; border: 1px solid #dce2ed; border-radius: 11px; width: 100%; padding: 12px 13px; outline: 0; color: #182037; }
textarea { display: block; min-height: 122px; resize: vertical; line-height: 1.65; font-size: 13px; }
textarea::placeholder { color: #9aa4b4; }
input, select { min-height: 44px; font-size: 13px; }
textarea:focus, select:focus, input:not([type="radio"]):focus { border-color: #2e64e8; box-shadow: 0 0 0 3px rgba(37,94,230,.1); }
input[type="radio"] { position: absolute; opacity: 0; height: 0; width: 0; }
.choice-group { display: flex; gap: 9px; }
.choice { flex: 1; cursor: pointer; }
.choice span { display: block; text-align: center; border: 1px solid #dce2ed; color: #566175; font-size: 13px; font-weight: 700; border-radius: 11px; padding: 12px; }
.choice input:checked + span { background: #eaf1ff; color: #255ee6; border-color: #7aa3ff; }
.choice input:focus-visible + span { outline: 3px solid #99baff; outline-offset: 2px; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hint { font-size: 11px; color: #8992a3; line-height: 1.6; display: block; margin-top: 7px; }
.questions-head { border-top: 1px solid #ecf0f5; margin-top: 29px; padding-top: 26px; }
.count { background: #f1f4f8; color: #67738a; padding: 5px 10px; border-radius: 16px; font-size: 11px; }
.question-note { margin: 8px 0 15px; }
.question-list { display: grid; gap: 13px; }
.question-card { border: 1px solid #eef0f5; border-radius: 12px; background: #fbfcfe; padding: 13px; }
.question-card label { font-weight: 700; font-size: 12px; line-height: 1.6; display: block; margin-bottom: 8px; }
.question-card .small { font-size: 11px; color: #8a94a6; line-height: 1.6; margin-top: 6px; }
.question-card select { background: #fff; min-height: 40px; }
.more { margin: 17px 0 22px; border-top: 1px solid #eef0f5; padding-top: 14px; }
.more summary { color: #53617a; font-size: 12px; font-weight: 700; cursor: pointer; user-select: none; }
.more-list { margin-top: 14px; }
.primary-button { display: flex; align-items: center; justify-content: space-between; gap: 9px; width: 100%; background: #255ee6; color: #fff; border: 0; border-radius: 12px; padding: 15px 18px; font-size: 14px; font-weight: 800; }
.primary-button:hover { background: #154bc1; }
.primary-button:disabled { opacity: .46; cursor: not-allowed; }
.form-error { color: #b62b3b; font-size: 12px; line-height: 1.5; margin: 0 0 12px; }
.result { position: sticky; top: 18px; }
.result-header { padding-bottom: 22px; }
.tabs { display: flex; background: #f1f3f8; border-radius: 10px; padding: 4px; gap: 3px; }
.tab { flex: 1; border: none; border-radius: 8px; background: transparent; padding: 10px 8px; color: #667186; font-size: 12px; font-weight: 700; }
.tab.active { color: #234eb4; background: white; box-shadow: 0 1px 4px rgba(19, 31, 57, .1); }
.tab:focus-visible, .primary-button:focus-visible, .secondary-button:focus-visible { outline: 3px solid #99baff; outline-offset: 2px; }
.output-wrap { margin-top: 13px; border-radius: 11px; background: #182137; color: #dce9ff; min-height: 322px; max-height: 560px; overflow: auto; border: 1px solid #23314d; }
.output-wrap pre { white-space: pre-wrap; word-break: break-word; overflow-wrap: anywhere; font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 11.5px; line-height: 1.75; margin: 0; padding: 18px; min-height: 322px; }
.output-note { min-height: 18px; }
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 15px; }
.secondary-button { padding: 11px 12px; border: 1px solid #dae2ee; background: #fff; border-radius: 10px; font-size: 12px; font-weight: 700; color: #33405a; }
.secondary-button:hover:not(:disabled) { border-color: #7fa4ff; background: #f8fbff; }
.secondary-button:disabled { opacity: .48; cursor: not-allowed; }
.bottom-note { border-top: 1px solid #ecf0f5; margin-top: 24px; padding-top: 17px; }
.bottom-note strong { font-size: 11px; color: #53617b; }
.bottom-note p { color: #7d8798; font-size: 11px; line-height: 1.7; margin: 7px 0 0; }
.footer { text-align: center; color: #a1a9b7; font-size: 11px; padding: 10px 20px 40px; }
@media (max-width: 900px) {
  .workspace { grid-template-columns: 1fr; }
  .result { position: static; }
}
@media (max-width: 560px) {
  .topbar-inner { height: 58px; padding: 0 18px; }
  .topbar-caption { display: none; }
  .container { padding: 31px 14px 36px; }
  .intro { padding: 0 4px; margin-bottom: 24px; }
  .intro h1 { letter-spacing: -1.2px; }
  .panel { padding: 19px 16px; border-radius: 15px; }
  .two-col { grid-template-columns: 1fr; gap: 0; }
  .two-col .field { margin-top: 16px; }
  .section-header h2, .questions-head h2 { font-size: 18px; }
  .tag { font-size: 9px; }
  .output-wrap { max-height: 470px; }
}
@media (prefers-reduced-motion: no-preference) {
  .primary-button, .secondary-button, .tab, .choice span { transition: background-color .16s ease, border-color .16s ease; }
}
