
:root {
  --red: #8d1f24;
  --red-deep: #68151a;
  --red-soft: #f8eceb;
  --gold: #b78a42;
  --ink: #25211e;
  --muted: #6f6861;
  --line: #ded7ce;
  --paper: #fffdf8;
  --ground: #f3efe8;
  --green: #2d6a4f;
  --amber: #9a6518;
  --blue: #365e83;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 8%, rgba(183, 138, 66, .09), transparent 28rem),
    linear-gradient(180deg, #f8f5ef 0, var(--ground) 100%);
  font-family: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 253, 248, .92);
  border-bottom: 1px solid rgba(141, 31, 36, .12);
  backdrop-filter: blur(14px);
}
.header-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 72px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--red);
  border-radius: 12px 12px 12px 4px;
  font-family: SimHei, sans-serif;
  font-size: 22px;
}
.brand strong { display: block; font-size: 16px; letter-spacing: .04em; }
.brand small { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }
.rule-link { color: var(--red); font-size: 13px; font-weight: 700; text-decoration: none; border-bottom: 1px solid rgba(141,31,36,.25); }

.hero {
  width: min(1180px, calc(100% - 32px));
  margin: 42px auto 24px;
  padding: 48px;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 52px;
  align-items: center;
  color: #fff;
  background:
    linear-gradient(130deg, rgba(255,255,255,.05), transparent 48%),
    var(--red-deep);
  border-radius: 28px 28px 28px 8px;
  box-shadow: 0 22px 65px rgba(72, 22, 22, .16);
  overflow: hidden;
  position: relative;
}
.hero::after {
  content: "";
  position: absolute;
  width: 330px;
  height: 330px;
  right: -170px;
  top: -190px;
  border: 70px solid rgba(255,255,255,.045);
  border-radius: 50%;
}
.eyebrow { margin: 0 0 12px; color: #d7b777; font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero h1 { max-width: 760px; margin: 0; font-family: SimHei, "Microsoft YaHei", sans-serif; font-size: clamp(34px, 5vw, 58px); font-weight: 400; line-height: 1.18; letter-spacing: -.035em; }
.hero-copy > p:not(.eyebrow) { max-width: 750px; margin: 22px 0 0; color: rgba(255,255,255,.78); font-size: 16px; line-height: 1.85; }
.hero-points { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-points span { padding: 8px 12px; color: #f1dcc0; border: 1px solid rgba(241,220,192,.24); background: rgba(255,255,255,.06); border-radius: 999px; font-size: 12px; }
.hero-note { position: relative; z-index: 1; padding: 28px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); border-radius: 20px 20px 20px 6px; }
.note-number { display: block; color: #efd49c; font-family: Georgia, serif; font-size: 68px; line-height: .9; }
.hero-note strong { display: block; margin-top: 10px; font-size: 18px; }
.hero-note p { margin: 12px 0 0; color: rgba(255,255,255,.66); font-size: 13px; line-height: 1.7; }

.wizard-shell, .results {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto;
}
.stepper { max-width: 780px; margin: 0 auto 18px; display: flex; align-items: center; }
.step-item { min-width: 150px; display: flex; align-items: center; gap: 10px; color: #9b948d; }
.step-item > span { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--paper); border-radius: 50%; font-weight: 800; font-size: 13px; }
.step-item strong, .step-item small { display: block; }
.step-item strong { font-size: 13px; }
.step-item small { margin-top: 2px; font-size: 10px; }
.step-item.active { color: var(--red); }
.step-item.active > span { color: #fff; background: var(--red); border-color: var(--red); box-shadow: 0 6px 18px rgba(141,31,36,.24); }
.step-line { height: 1px; flex: 1; margin: 0 14px; background: var(--line); }

.form-panel {
  padding: 42px;
  background: rgba(255,253,248,.96);
  border: 1px solid rgba(103, 85, 68, .14);
  border-radius: 24px 24px 24px 8px;
  box-shadow: 0 18px 54px rgba(57, 43, 28, .08);
}
.section-heading { display: flex; gap: 16px; align-items: flex-start; padding-bottom: 26px; border-bottom: 1px solid var(--line); }
.section-index { color: var(--gold); font-family: Georgia, serif; font-size: 32px; line-height: 1; }
.section-heading h2 { margin: 0; font-family: SimHei, "Microsoft YaHei", sans-serif; font-size: 26px; font-weight: 400; }
.section-heading p { margin: 7px 0 0; color: var(--muted); font-size: 14px; }
.form-grid, .date-grid { margin-top: 28px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field.full, .check-card.full { grid-column: 1 / -1; }
.field > span, .date-field-top { font-size: 14px; font-weight: 700; }
.field em, .date-field em { margin-left: 5px; color: var(--red); font-size: 11px; font-style: normal; }
.field input, .field select, .date-field input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  color: var(--ink);
  background: #fff;
  border: 1px solid #d7d0c7;
  border-radius: 10px;
  outline: none;
  transition: border .2s, box-shadow .2s;
}
.field input:focus, .field select:focus, .date-field input:focus { border-color: var(--red); box-shadow: 0 0 0 3px rgba(141,31,36,.1); }
.field small, .date-field small { color: var(--muted); font-size: 11px; line-height: 1.5; }
.error-text { color: #b3262e; font-size: 12px; font-weight: 700; }
.check-card { padding: 16px; display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--line); background: #faf7f1; border-radius: 12px; cursor: pointer; }
.check-card input { width: 18px; height: 18px; accent-color: var(--red); }
.check-card strong, .check-card small { display: block; }
.check-card strong { font-size: 14px; }
.check-card small { margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.form-actions { margin-top: 30px; padding-top: 24px; display: flex; justify-content: space-between; align-items: center; gap: 12px; border-top: 1px solid var(--line); }
.privacy-note { color: var(--muted); font-size: 11px; }
.primary-button, .secondary-button, .result-actions button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 800;
  font-size: 13px;
}
.primary-button { color: #fff; background: var(--red); box-shadow: 0 8px 22px rgba(141,31,36,.2); }
.primary-button:hover { background: var(--red-deep); }
.secondary-button { color: var(--ink); background: transparent; border-color: var(--line); }

.date-field { padding: 16px; display: flex; flex-direction: column; gap: 8px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.date-field.required { border-left: 4px solid var(--red); }
.date-field.optional { background: #fbfaf7; }
.date-field-top { display: flex; justify-content: space-between; gap: 10px; }
.date-field-top em { flex: 0 0 auto; }
.date-field.optional .date-field-top em { color: var(--muted); }
.logic-note { margin-top: 22px; padding: 18px 20px; border: 1px solid #ead9bd; background: #fff9ec; border-radius: 12px; }
.logic-note strong { color: #76521d; font-size: 13px; }
.logic-note p { margin: 6px 0 0; color: #745f42; font-size: 12px; line-height: 1.7; }

.results { margin-top: 54px; padding-top: 24px; }
.results-header { display: flex; justify-content: space-between; align-items: flex-end; gap: 28px; }
.results-header h2 { margin: 0; font-family: SimHei, "Microsoft YaHei", sans-serif; font-size: 32px; font-weight: 400; }
.results-header > div > p:last-child { color: var(--muted); font-size: 13px; }
.result-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.result-actions button { color: var(--ink); background: var(--paper); border-color: var(--line); }
.result-actions .print-button { color: #fff; background: var(--red); border-color: var(--red); }
.summary-grid { margin: 24px 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.summary-grid > div { padding: 20px; background: var(--paper); border: 1px solid var(--line); border-radius: 14px 14px 14px 4px; }
.summary-grid span, .summary-grid small { display: block; color: var(--muted); font-size: 11px; }
.summary-grid strong { display: block; margin: 8px 0 5px; color: var(--red); font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.filter-bar { display: flex; gap: 8px; margin-bottom: 12px; overflow-x: auto; scrollbar-width: none; }
.filter-bar button { flex: 0 0 auto; padding: 8px 14px; color: var(--muted); background: transparent; border: 1px solid var(--line); border-radius: 999px; font-size: 12px; }
.filter-bar button.selected { color: #fff; background: var(--red); border-color: var(--red); }

.table-wrap { overflow: auto; background: var(--paper); border: 1px solid var(--line); border-radius: 16px 16px 16px 4px; }
table { width: 100%; min-width: 1080px; border-collapse: collapse; font-size: 12px; }
th { position: sticky; top: 0; z-index: 1; padding: 14px 12px; color: #fff; background: var(--red-deep); text-align: left; font-weight: 700; }
td { padding: 14px 12px; border-bottom: 1px solid #e9e3db; vertical-align: top; line-height: 1.55; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fcf8f1; }
td:first-child { width: 48px; color: var(--gold); font-family: Georgia, serif; font-size: 16px; }
td:nth-child(2) { width: 110px; color: var(--red); font-weight: 700; }
td:nth-child(3) { width: 210px; }
td:nth-child(4), td:nth-child(5) { width: 165px; }
td:nth-child(6) { width: 120px; }
td p { margin: 0; }
td small { display: block; margin-top: 5px; color: var(--muted); }
.date-cell { color: #3e3731; font-weight: 700; }
.status { display: inline-flex; align-items: center; padding: 5px 8px; border-radius: 999px; font-size: 10px; font-weight: 800; white-space: nowrap; }
.status.actual { color: var(--green); background: #e7f3ec; }
.status.computed { color: var(--blue); background: #e9f0f7; }
.status.pending { color: var(--amber); background: #fff2d8; }
.status.warning { color: #a2252b; background: #f9e1e1; }
.mobile-list { display: none; }
.result-notice { margin-top: 18px; padding: 18px 20px; display: flex; gap: 18px; color: #665c51; background: #ebe5dc; border-radius: 12px; }
.result-notice strong { flex: 0 0 auto; color: var(--red); font-size: 12px; }
.result-notice p { margin: 0; font-size: 11px; line-height: 1.7; }

footer { margin-top: 64px; padding: 28px 16px 36px; color: #817970; background: #e8e2d9; text-align: center; font-size: 11px; line-height: 1.6; }
footer p { margin: 3px 0; }

@media (max-width: 860px) {
  .header-inner { min-height: 62px; }
  .rule-link { display: none; }
  .hero { margin-top: 20px; padding: 30px 24px; grid-template-columns: 1fr; gap: 22px; border-radius: 20px 20px 20px 6px; }
  .hero h1 { font-size: 36px; }
  .hero-note { display: grid; grid-template-columns: auto 1fr; column-gap: 14px; align-items: center; }
  .note-number { grid-row: 1 / 3; font-size: 56px; }
  .hero-note strong { margin: 0; }
  .hero-note p { margin: 4px 0 0; }
  .stepper { justify-content: center; }
  .step-item { min-width: auto; }
  .step-item div { display: none; }
  .step-line { max-width: 72px; }
  .form-panel { padding: 26px 20px; }
  .form-grid, .date-grid { grid-template-columns: 1fr; }
  .field.full, .check-card.full { grid-column: auto; }
  .summary-grid { grid-template-columns: repeat(2, 1fr); }
  .results-header { align-items: flex-start; flex-direction: column; }
  .result-actions { justify-content: flex-start; }
  .desktop-table { display: none; }
  .mobile-list { display: grid; gap: 12px; }
  .timeline-card { padding: 18px; background: var(--paper); border: 1px solid var(--line); border-radius: 15px 15px 15px 5px; }
  .card-top { display: flex; align-items: center; gap: 8px; }
  .card-number { color: var(--gold); font-family: Georgia, serif; font-size: 18px; }
  .card-stage { margin-right: auto; color: var(--red); font-size: 11px; font-weight: 800; }
  .timeline-card h3 { margin: 14px 0; font-size: 16px; line-height: 1.45; }
  .card-date { padding: 12px; background: #f6f1e9; border-radius: 10px; }
  .card-date small, .card-date strong { display: block; }
  .card-date small { color: var(--muted); font-size: 10px; }
  .card-date strong { margin-top: 4px; font-size: 15px; }
  .timeline-card dl { margin: 14px 0 0; }
  .timeline-card dl div { padding: 9px 0; display: grid; grid-template-columns: 70px 1fr; gap: 10px; border-top: 1px dashed var(--line); }
  .timeline-card dt { color: var(--muted); font-size: 10px; }
  .timeline-card dd { margin: 0; font-size: 11px; line-height: 1.55; }
}

@media (max-width: 520px) {
  .header-inner, .hero, .wizard-shell, .results { width: min(100% - 20px, 1180px); }
  .brand-mark { width: 38px; height: 38px; }
  .brand strong { font-size: 14px; }
  .hero { padding: 26px 20px; }
  .hero h1 { font-size: 30px; }
  .hero-copy > p:not(.eyebrow) { font-size: 14px; }
  .form-panel { padding: 22px 15px; }
  .section-index { font-size: 26px; }
  .section-heading h2 { font-size: 21px; }
  .date-field-top { align-items: flex-start; flex-direction: column; }
  .date-field em { margin-left: 0; }
  .form-actions { align-items: stretch; flex-direction: column-reverse; }
  .form-actions button { width: 100%; }
  .privacy-note { text-align: center; }
  .results-header h2 { font-size: 25px; }
  .result-actions { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
  .result-actions .print-button { grid-column: 1 / -1; }
  .summary-grid { gap: 8px; }
  .summary-grid > div { padding: 15px; }
  .summary-grid strong { font-size: 23px; }
  .result-notice { flex-direction: column; gap: 5px; }
}

@media print {
  @page { size: landscape; margin: 10mm; }
  html, body { background: #fff; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .site-header, .wizard-shell, .print-hidden, footer { display: none !important; }
  .results { width: 100%; margin: 0; padding: 0; }
  .desktop-table { display: block !important; overflow: visible; border: 1px solid var(--line); border-radius: 10px; }
  table { width: 100%; min-width: 0; font-size: 8px; }
  thead { display: table-header-group; }
  tr { break-inside: avoid; }
  th { position: static; padding: 7px 6px; color: #fff; background: var(--red-deep) !important; }
  td { padding: 7px 6px; border-bottom: 1px solid #e9e3db; }
  .status { padding: 3px 5px; }
}
