:root{color:#15212a;background:#f4f7f8;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,PingFang SC,Hiragino Sans GB,Microsoft YaHei,sans-serif;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;--teal: #1f7a8c;--teal-strong: #125a67;--green: #4f8f4a;--amber: #c17727;--coral: #cf5c4b;--ink: #15212a;--muted: #60717d;--line: #d8e1e5;--surface: #ffffff;--surface-soft: #eef5f6}*{box-sizing:border-box}body{margin:0;min-width:320px}button,input,select{font:inherit}button{cursor:pointer}.app-shell{min-height:100vh;background:linear-gradient(180deg,#f4f7f8f2,#f4f7f8),radial-gradient(circle at 20% 0%,rgba(31,122,140,.12),transparent 34%),radial-gradient(circle at 92% 20%,rgba(207,92,75,.1),transparent 28%)}.topbar{position:sticky;top:0;z-index:10;display:flex;align-items:center;justify-content:space-between;gap:20px;min-height:72px;padding:14px clamp(18px,4vw,44px);border-bottom:1px solid rgba(216,225,229,.86);background:#ffffffe0;-webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px)}.brand{display:inline-flex;align-items:center;gap:12px;color:inherit;text-decoration:none}.brand-mark{display:grid;place-items:center;width:42px;height:42px;border-radius:8px;color:#fff;background:var(--teal);box-shadow:0 12px 24px #1f7a8c33}.brand span:last-child{display:grid;gap:2px}.brand strong{font-size:17px;line-height:1.2}.brand small{color:var(--muted);font-size:12px}.topbar-actions{display:flex;align-items:center;gap:10px}.icon-button,.primary-button,.preview-header button,.button-grid button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:42px;border:1px solid var(--line);border-radius:8px;color:var(--ink);background:#fff;transition:transform .16s ease,border-color .16s ease,background .16s ease,box-shadow .16s ease}.icon-button{width:42px}.primary-button,.preview-header button,.button-grid button.strong{padding:0 16px;color:#fff;border-color:var(--teal);background:var(--teal);box-shadow:0 12px 22px #1f7a8c38}.icon-button:hover,.button-grid button:hover,.preview-header button:hover,.primary-button:hover{transform:translateY(-1px);box-shadow:0 12px 24px #15212a1f}.tool-layout{display:grid;grid-template-columns:minmax(280px,340px) minmax(0,1fr);gap:clamp(18px,3vw,34px);align-items:start;padding:clamp(18px,4vw,44px)}.control-panel{position:sticky;top:96px;display:grid;gap:16px}.control-section{display:grid;gap:16px;padding:18px;border:1px solid var(--line);border-radius:8px;background:#ffffffeb;box-shadow:0 14px 34px #15212a14}.section-title{display:flex;align-items:center;gap:8px;color:var(--teal-strong)}.section-title h2{margin:0;font-size:16px}.field,.range-field{display:grid;gap:8px;color:var(--muted);font-size:13px;font-weight:650}.field select,.stepper input{width:100%;height:42px;border:1px solid var(--line);border-radius:8px;color:var(--ink);background:#fff}.field select{padding:0 12px}.helper-text{margin:-6px 0 0;color:var(--muted);font-size:13px;line-height:1.5}.stepper-row,.metric-row,.toggle-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.stepper-row>span,.metric-row>span,.toggle-row>span{color:var(--muted);font-size:13px;font-weight:650}.stepper{display:grid;grid-template-columns:38px 64px 38px;gap:6px;align-items:center}.stepper button{display:grid;place-items:center;height:38px;border:0;border-radius:8px;color:var(--teal);background:var(--surface-soft)}.stepper input{text-align:center}.metric-row{min-height:46px;padding:10px 12px;border:1px solid var(--line);border-radius:8px;background:#fbfcfc}.metric-row strong{font-size:22px;color:var(--teal-strong)}.range-field input{width:100%;accent-color:var(--teal)}.toggle-row input{width:44px;height:24px;accent-color:var(--teal)}.button-grid{display:grid;grid-template-columns:1fr;gap:10px}.button-grid button{min-width:0;padding:0 12px}.preview-area{display:grid;gap:18px;min-width:0}.preview-header{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 20px;border:1px solid var(--line);border-radius:8px;background:#ffffffe6}.preview-header h1{margin:0 0 4px;font-size:clamp(24px,4vw,40px);line-height:1.08}.preview-header p{margin:0;color:var(--muted);line-height:1.5}.sheet-stack{display:grid;gap:24px;justify-items:center;min-width:0;padding:clamp(14px,2vw,24px);border-radius:8px;background:linear-gradient(90deg,rgba(31,122,140,.08) 1px,transparent 1px),linear-gradient(180deg,rgba(31,122,140,.08) 1px,transparent 1px),#e8eef1;background-size:24px 24px}.sheet-frame{max-width:100%}.sheet-preview{position:relative;display:grid;align-content:start;gap:20px;width:794px;min-height:1123px;padding:56px;overflow:hidden;color:#111827;background:#fff;box-shadow:0 18px 40px #15212a29;transform:scale(var(--preview-scale));transform-origin:top left}.sheet-title{display:grid;gap:8px;padding-bottom:12px;border-bottom:2px solid #111827;text-align:center}.sheet-title h2{margin:0;font-family:Times New Roman,SimSun,serif;font-size:clamp(20px,3vw,28px);line-height:1.2}.sheet-meta{display:flex;justify-content:space-between;gap:8px;color:#5f6772;font-size:clamp(10px,1.4vw,14px)}.problem-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));column-gap:clamp(10px,4%,38px);row-gap:var(--problem-row-gap)}.problem-item{display:flex;align-items:baseline;min-width:0;white-space:nowrap;font-family:Times New Roman,SimSun,serif;font-size:var(--problem-font-size);line-height:1.1}.problem-item.answer{color:#394451}.answer-line{display:inline-block;width:var(--underline-width);height:.75em;margin-left:5px;border-bottom:2px solid #111827}.answer-sheet .sheet-title{border-bottom:1px dashed #6b7280}.page-number{position:absolute;right:0;bottom:22px;left:0;color:#7a8490;text-align:center;font-size:12px}@media(max-width:1120px){.tool-layout{grid-template-columns:1fr}.control-panel{position:static;grid-template-columns:repeat(2,minmax(0,1fr))}.sheet-preview{min-height:1123px}}@media(max-width:720px){.topbar{align-items:flex-start;flex-direction:column}.topbar-actions,.primary-button{width:100%}.control-panel{grid-template-columns:1fr}.preview-header{align-items:stretch;flex-direction:column}.preview-header button{width:100%}.sheet-meta{flex-direction:column;align-items:center}.problem-grid{column-gap:clamp(10px,4%,38px)}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important;animation-iteration-count:1!important}}@media print{@page{size:A4 portrait;margin:0}:root,body,.app-shell{background:#fff!important}body{min-width:0;color:#111827;-webkit-print-color-adjust:exact;print-color-adjust:exact}.topbar,.control-panel,.preview-header{display:none!important}.tool-layout,.preview-area,.sheet-stack{display:block;margin:0;padding:0;background:#fff!important}.sheet-frame{width:auto!important;height:auto!important;max-width:none}.sheet-preview{width:210mm;min-height:297mm;margin:0;padding:15mm;box-shadow:none;break-after:page;page-break-after:always;transform:none;transform-origin:initial}.sheet-frame:last-child .sheet-preview{break-after:auto;page-break-after:auto}.sheet-title h2{font-size:24px}.sheet-meta{flex-direction:row;align-items:center;justify-content:space-between;font-size:14px}}
