.eq-page {
  --eq-paper: #faf8f4;
  --eq-text: #242624;
  --eq-muted: #625f58;
  --eq-line: #d8d3c9;
  --eq-red: #872d23;
  color: var(--eq-text);
  background: var(--eq-paper);
}
.eq-page *, .eq-page *::before, .eq-page *::after { box-sizing: border-box; }
.eq-page [hidden] { display: none !important; }
.eq-wrap { max-width: 1248px; margin-inline: auto; }
.eq-intro { padding: clamp(48px, 6vw, 90px) 0 clamp(28px, 3.9vw, 55px); border-bottom: 1px solid var(--eq-text); }
.eq-intro h1, .eq-section-head h2, .eq-result h2 {
  margin: 0; color: var(--eq-text); font-family: var(--serif, "Songti TC", "Noto Serif TC", "Times New Roman", serif);
  font-weight: 600;
}
.eq-intro h1 { font-size: clamp(42px, 5.2vw, 74px); line-height: 1.18; letter-spacing: -.035em; }
.eq-intro p { max-width: 60ch; margin: 17px 0 0; color: var(--eq-muted); font-size: clamp(15px, 1.25vw, 18px); line-height: 1.7; }
.eq-form { margin: 0; }
.eq-fields, .eq-mode { min-width: 0; margin: 0; padding: 0; border: 0; }
.eq-layout { display: grid; grid-template-columns: minmax(200px, 0.75fr) minmax(0, 2.08fr); gap: clamp(40px, 7.4vw, 110px); padding: 46px 0 clamp(64px, 7vw, 104px); }
.eq-mode { width: 100%; }
.eq-mode legend { margin-bottom: 14px; padding: 0; font-size: 14px; color: var(--eq-muted); font-weight: 600; }
.eq-mode-option { display: flex; align-items: flex-start; gap: 12px; padding: 20px 15px; cursor: pointer; border: 1px solid var(--eq-line); border-radius: 2px; }
.eq-mode-option + .eq-mode-option { margin-top: 9px; }
.eq-mode-option:has(input:checked) { border-color: var(--eq-red); background: #f4ebe5; }
.eq-mode-option input, .eq-demo-control input { accent-color: var(--eq-red); }
.eq-mode-option input { flex: 0 0 16px; width: 16px; height: 16px; margin: 3px 0 0; }
.eq-mode-copy { display: grid; gap: 7px; }
.eq-mode-copy strong { font-size: 17px; line-height: 1.35; font-weight: 650; }
.eq-mode-copy > span { font-size: 13px; line-height: 1.65; color: var(--eq-muted); }
.eq-main, .eq-section { min-width: 0; }
.eq-section + .eq-section { margin-top: 38px; padding-top: 30px; border-top: 1px solid var(--eq-line); }
.eq-section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 22px; }
.eq-section-head h2, .eq-result h2 { font-size: clamp(24px, 2.3vw, 33px); line-height: 1.25; letter-spacing: -.025em; }
.eq-section-head > span { color: var(--eq-muted); font-size: 12px; white-space: nowrap; }
.eq-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 19px 20px; }
.eq-field { min-width: 0; }
.eq-wide { grid-column: 1 / -1; }
.eq-field label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; line-height: 1.45; }
.eq-star, .eq-error { color: var(--eq-red); }
.eq-field input, .eq-field select, .eq-field textarea {
  display: block; width: 100%; min-width: 0; min-height: 46px; padding: 11px 12px; border: 1px solid #aaa79d; border-radius: 2px; 
  background-color: #fffefa; color: var(--eq-text); font: inherit; font-size: 15px; line-height: 1.45;
}
.eq-field input::placeholder, .eq-field textarea::placeholder { color: #716f66; opacity: 1; }
.eq-field select { padding-right: 26px; }
.eq-field textarea { min-height: 100px; resize: vertical; }
.eq-page :is(input, select, textarea, summary, button):focus-visible { outline: 2px solid var(--eq-red); outline-offset: 3px; }
.eq-field [aria-invalid="true"] { border-color: var(--eq-red); }
.eq-error { display: block; margin-top: 5px; font-size: 13px; line-height: 1.5; }
.eq-action-area { margin-top: 31px; }
.eq-submit-row { display: flex; align-items: center; gap: 18px; }
.eq-submit, .eq-secondary { min-height: 46px; padding: 12px 19px; border: 1px solid var(--eq-red); border-radius: 2px; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.eq-submit { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; background: var(--eq-red); color: #fff; }
.eq-submit:hover { background: #70251d; }
.eq-submit:disabled { cursor: progress; opacity: .72; }
.eq-secondary { background: transparent; color: var(--eq-red); }
.eq-demo-note { margin: 0; color: var(--eq-muted); font-size: 13px; line-height: 1.65; }
.eq-demo-control { margin-top: 16px; color: var(--eq-muted); font-size: 13px; }
.eq-demo-control summary { width: fit-content; padding: 6px 0; cursor: pointer; }
.eq-demo-control label { display: flex; align-items: center; gap: 6px; width: fit-content; min-height: 36px; }
.eq-status:not(:empty) { margin-bottom: 15px; padding: 12px 14px; background: #f0ede5; font-size: 14px; line-height: 1.6; }
.eq-status-error { border-left: 3px solid var(--eq-red); color: var(--eq-red); }
.eq-result { max-width: 660px; margin: 54px auto 0; padding-bottom: 84px; }
.eq-check { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 17px; background: var(--eq-red); color: #fff; border-radius: 50%; font-size: 24px; }
.eq-result p { line-height: 1.8; color: var(--eq-muted); }
.eq-result dl { margin: 24px 0; padding: 0; border-top: 1px solid var(--eq-line); font-size: 15px; }
.eq-result dl div { display: grid; grid-template-columns: minmax(95px, .6fr) minmax(0, 1.4fr); gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--eq-line); }
.eq-result dt { color: var(--eq-muted); }
.eq-result dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 840px) {
  .eq-layout { grid-template-columns: 1fr; gap: 28px; padding-top: 28px; }
  .eq-mode { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .eq-mode-option + .eq-mode-option { margin-top: 0; }
  .eq-mode-option { padding: 14px 12px; }
}
@media (max-width: 540px) {
  .eq-intro { padding: 37px 0 26px; }
  .eq-intro h1 { font-size: 39px; }
  .eq-intro p { margin-top: 12px; }
  .eq-mode-option { gap: 8px; padding: 12px 9px; }
  .eq-mode-copy strong { font-size: 15px; }
  .eq-mode-copy > span { font-size: 12px; }
  .eq-grid { gap: 16px 12px; }
  .eq-field:not([data-eq-field="quantity"]):not([data-eq-field="unit"]) { grid-column: 1 / -1; }
  .eq-section + .eq-section { margin-top: 28px; padding-top: 24px; }
  .eq-section-head { margin-bottom: 17px; }
  .eq-field input, .eq-field select, .eq-field textarea { font-size: 16px; }
  .eq-submit-row { align-items: flex-start; flex-direction: column; gap: 10px; }
  .eq-submit { width: 100%; justify-content: center; }
}
@media (max-width: 360px) {
  .eq-mode { grid-template-columns: 1fr; }
  .eq-mode-option { padding: 11px; }
}
