:root {
  --paper: #f5f0e8;
  --paper-deep: #ebe3d7;
  --ink: #18332d;
  --ink-soft: #61716b;
  --forest: #184d3d;
  --mint: #9bd5bc;
  --coral: #ed765f;
  --white: #fffdf9;
  --line: #d9d0c3;
  --shadow: 0 18px 50px rgba(41, 57, 49, .1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Inter, "PingFang SC", "Microsoft YaHei", sans-serif; }
button, input { font: inherit; }
button { color: inherit; }

.topbar { height: 78px; padding: 0 clamp(22px, 5vw, 72px); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(24, 51, 45, .11); }
.brand { color: inherit; text-decoration: none; display: flex; align-items: center; gap: 12px; }
.brand-mark { width: 40px; height: 40px; display: grid; place-items: center; background: var(--forest); color: white; border-radius: 12px 5px 12px 5px; font-family: Georgia, serif; font-size: 20px; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 17px; letter-spacing: .03em; }
.brand small { color: var(--ink-soft); margin-top: 2px; font-size: 11px; }
.privacy-pill { display: flex; align-items: center; gap: 8px; border: 1px solid #bfcfc6; background: rgba(255, 255, 255, .45); padding: 9px 14px; border-radius: 999px; font-size: 13px; }
.privacy-pill span { color: #2d9a69; font-size: 10px; }

main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.hero { min-height: 390px; display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .65fr); gap: 7vw; align-items: center; padding: 62px 2vw 54px; position: relative; }
.hero::before { content: ""; width: 230px; height: 230px; position: absolute; right: 5%; top: 65px; border: 1px solid rgba(24, 77, 61, .12); border-radius: 50%; pointer-events: none; }
.eyebrow, .step-label { margin: 0 0 14px; color: var(--coral); font-size: 11px; font-weight: 800; letter-spacing: .18em; }
h1 { margin: 0; font-family: Georgia, "Noto Serif SC", serif; font-size: clamp(42px, 6vw, 74px); line-height: 1.05; letter-spacing: -.04em; font-weight: 500; }
h1 em { color: var(--forest); font-style: normal; }
.hero-desc { margin: 24px 0 0; max-width: 720px; color: var(--ink-soft); line-height: 1.9; font-size: 16px; }
.privacy-card { position: relative; z-index: 1; background: var(--forest); color: white; padding: 28px; border-radius: 5px 28px 5px 28px; box-shadow: var(--shadow); display: flex; align-items: flex-start; gap: 16px; transform: rotate(1.5deg); }
.privacy-icon { flex: 0 0 42px; height: 42px; display: grid; place-items: center; background: var(--mint); color: var(--forest); border-radius: 50%; font-size: 22px; }
.privacy-card strong { font-size: 16px; }
.privacy-card p { color: #d7e8e1; margin: 7px 0 0; line-height: 1.65; font-size: 13px; }

.workflow, .progress-section, .results-section { background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: clamp(24px, 4vw, 48px); box-shadow: 0 12px 38px rgba(41, 57, 49, .05); margin-bottom: 36px; }
.section-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: 30px; }
.section-heading.compact { align-items: center; margin-bottom: 20px; }
.section-heading h2 { margin: 0; font-family: Georgia, "Noto Serif SC", serif; font-size: clamp(27px, 3vw, 38px); font-weight: 500; }
.section-heading > p { margin: 0; max-width: 360px; color: var(--ink-soft); line-height: 1.7; font-size: 13px; }
.upload-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.upload-panel { background: #faf7f1; border: 1px solid #e4ddd2; border-radius: 18px; padding: 20px; }
.panel-title { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.panel-number { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: var(--forest); background: var(--mint); font-weight: 800; font-size: 12px; }
.panel-title strong, .panel-title small { display: block; }
.panel-title small { color: var(--ink-soft); margin-top: 3px; }
.dropzone { min-height: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1.5px dashed #9cb2a8; border-radius: 13px; background: rgba(255, 255, 255, .72); cursor: pointer; transition: .18s ease; }
.dropzone:hover, .dropzone.dragging { border-color: var(--forest); background: #f0f8f3; transform: translateY(-2px); }
.drop-icon { width: 38px; height: 38px; display: grid; place-items: center; background: var(--forest); color: white; border-radius: 50%; font-size: 22px; margin-bottom: 10px; }
.dropzone small { color: var(--ink-soft); margin-top: 6px; }
.file-slot, .file-list { margin-top: 12px; min-height: 42px; }
.empty { display: grid; place-items: center; color: #89958f; font-size: 12px; }
.file-item { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 11px; border-radius: 10px; background: #eee8de; margin-top: 7px; }
.file-item:first-child { margin-top: 0; }
.file-type { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 7px; color: white; background: var(--forest); font-size: 9px; font-weight: 800; }
.file-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.file-meta { color: var(--ink-soft); font-size: 11px; }
.remove-file { border: 0; background: transparent; cursor: pointer; color: #7b8781; padding: 6px; border-radius: 6px; }
.remove-file:hover { background: #ded6cb; color: var(--coral); }
.notice { margin-top: 18px; padding: 13px 16px; border-radius: 10px; background: #fff1ed; color: #8d3427; border: 1px solid #f3c1b7; line-height: 1.55; font-size: 13px; white-space: pre-line; }
.primary-button { width: 100%; margin-top: 22px; border: 0; border-radius: 12px; padding: 18px 22px; display: flex; justify-content: center; gap: 18px; background: var(--forest); color: white; cursor: pointer; font-weight: 750; box-shadow: 0 8px 20px rgba(24, 77, 61, .2); }
.primary-button:hover:not(:disabled) { background: #0f3e31; transform: translateY(-1px); }
.primary-button:disabled { opacity: .38; cursor: not-allowed; box-shadow: none; }

.progress-track { height: 10px; background: var(--paper-deep); overflow: hidden; border-radius: 20px; }
.progress-track span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--forest), #49a77d); border-radius: inherit; transition: width .25s ease; }
#progress-message { margin: 14px 0 0; color: var(--ink-soft); font-size: 13px; }
.secondary-button, .download-button { border: 1px solid var(--forest); background: transparent; border-radius: 9px; padding: 10px 15px; cursor: pointer; color: var(--forest); font-weight: 700; }
.secondary-button:hover, .download-button:hover { background: var(--forest); color: white; }
.summary-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 24px; }
.summary-card { background: #f7f3ec; border-radius: 14px; padding: 18px; }
.summary-card small { display: block; color: var(--ink-soft); }
.summary-card strong { display: block; font-family: Georgia, serif; font-size: 28px; margin-top: 7px; font-weight: 500; }
.result-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 20px; border-top: 1px solid var(--line); padding: 20px 0; }
.result-item:first-child { border-top: 0; }
.result-name { font-weight: 750; overflow-wrap: anywhere; }
.result-meta { display: flex; flex-wrap: wrap; gap: 8px 15px; margin-top: 8px; color: var(--ink-soft); font-size: 12px; }
.result-status { display: inline-flex; align-items: center; gap: 6px; color: #287a58; }
.result-status.error { color: #a63b2d; }
.result-status::before { content: ""; width: 7px; height: 7px; background: currentColor; border-radius: 50%; }
footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 5px 0 32px; display: flex; justify-content: space-between; color: var(--ink-soft); font-size: 11px; }

@media (max-width: 760px) {
  .topbar { height: 68px; padding: 0 18px; }
  .privacy-pill { font-size: 0; padding: 8px 10px; }
  .privacy-pill span { font-size: 11px; }
  main { width: min(100% - 24px, 1180px); }
  .hero { grid-template-columns: 1fr; padding: 44px 5px 36px; gap: 30px; }
  .hero::before { display: none; }
  .privacy-card { transform: none; }
  .workflow, .progress-section, .results-section { border-radius: 17px; padding: 22px 16px; }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 12px; }
  .section-heading .secondary-button { margin-top: 15px; }
  .upload-grid, .summary-cards { grid-template-columns: 1fr; }
  .result-item { grid-template-columns: 1fr; }
  .download-button { width: 100%; }
  footer { display: block; text-align: center; line-height: 1.8; }
  footer span { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
