/* =========================================================
   Chenfeng — inquiry layer
   /quote/ · /search/ · /quote/thank-you/
   Loaded after site.css and catalog.css.
   ========================================================= */

/* ---------- shared page head ---------- */
.qhead { padding: 30px 0 0; }
.qhead-in { display: grid; gap: 24px; }
.qhead h1 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: 30px; line-height: 1.14; letter-spacing: -0.022em;
  max-width: 26ch; margin-top: 12px;
  text-wrap: balance;
}
.qhead .lede { margin-top: 14px; max-width: 62ch; font-size: 15.5px; }

.qhead-facts {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 0; margin-top: 24px; padding-top: 18px;
  border-top: 1px solid var(--line-2);
}
.qhead-facts li {
  display: flex; flex-direction: column; gap: 1px;
  padding-right: 14px; font-size: 11.5px; color: var(--muted);
}
.qhead-facts li:nth-child(even) { border-left: 1px solid var(--line-2); padding-left: 14px; }
.qhead-facts b {
  font-family: var(--ff-head); font-size: 18px; font-weight: 700;
  color: var(--ink); letter-spacing: -0.01em; line-height: 1.15;
}

/* ---------- SLA card ---------- */
.sla {
  padding: 18px 18px 16px; border-radius: 3px;
  background: var(--ink); color: #C9D5E1;
}
.sla-top { display: flex; align-items: center; gap: 9px; }
.sla-top b { font-size: 13px; font-weight: 600; color: #fff; letter-spacing: 0.01em; }
.sla-dot {
  position: relative; flex: none;
  width: 7px; height: 7px; border-radius: 50%;
  background: #6E7F90;
}
.sla.is-open .sla-dot { background: #3FBF7A; box-shadow: 0 0 0 3px rgba(63,191,122,0.18); }
.sla-line { margin-top: 10px; font-size: 13px; line-height: 1.55; color: #DCE6EF; }
.sla-line strong { color: #fff; font-weight: 600; }
.sla-sub { margin-top: 8px; font-size: 11.5px; line-height: 1.55; color: #93A5B6; }

/* ---------- form shell ---------- */
.qsec { padding-top: 26px; }
.qform { gap: 0; }
.qform fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }

.qgroup { display: grid; gap: 16px; }
.qgroup + .qgroup {
  margin-top: 30px; padding-top: 26px;
  border-top: 1px solid var(--line);
}
.qlegend {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
  width: 100%; margin-bottom: 4px; padding: 0 0 12px;
  border-bottom: 1px solid var(--line-2);
  font-family: var(--ff-head); font-size: 15.5px; font-weight: 700;
  letter-spacing: -0.01em; color: var(--ink);
}
.qlegend .qn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--ink); color: #fff;
  font-family: var(--ff-mono); font-size: 11px; font-weight: 400;
}
.qlegend em {
  margin-left: auto; font-style: normal;
  font-family: var(--ff-body); font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--accent-dk);
}
.qgroup-opt .qlegend em { color: var(--muted-2); }

.qrow-side { align-items: start; }
.qform .field { align-content: start; }
.qform .req { color: var(--accent-dk); font-weight: 700; }
.qform .glabel {
  font-size: 12.5px; font-weight: 600; letter-spacing: 0.02em; color: #3C4B5A;
}
.qform .fhint, .qform .ferr {
  font-size: 11.5px; line-height: 1.5; color: var(--muted);
}
.qform .fhint code {
  font-family: var(--ff-mono); font-size: 11px;
  background: var(--soft); border: 1px solid var(--line-2);
  padding: 0 4px; border-radius: 2px;
}
.qform .ferr {
  display: flex; gap: 6px; color: #B3261E; font-weight: 500;
}
.qform .ferr::before { content: "!"; font-weight: 700; }
.qform .free-mail { color: var(--accent-dk); }
.qform .is-bad { border-color: #D08A84; background: #FFFBFA; }

/* select: same box as inputs, native arrow removed */
.qform select {
  width: 100%; padding: 11px 34px 11px 12px;
  border: 1px solid var(--line); border-radius: 2px;
  font-family: var(--ff-body); font-size: 14.5px; color: var(--ink);
  background-color: #fff;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%235B6B7B' stroke-width='1.4' d='M1 1.5 6 6.5l5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
  -webkit-appearance: none; appearance: none;
}
.qform select:focus {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent);
}

/* radios */
.radios { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.radio {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 2px;
  font-size: 13px; font-weight: 500; color: #435261; cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease;
}
.radio:hover { border-color: #BCC7D2; }
.radio input { accent-color: var(--accent); margin: 0; }
.radio:has(input:checked) {
  border-color: var(--accent); background: #FFF8F2; color: var(--ink); font-weight: 600;
}

/* honeypot: off-screen, never display:none — bots fill hidden fields */
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* ---------- parsed part list ---------- */
.field-parts { margin-top: 2px; }
.qform textarea#q-parts {
  font-family: var(--ff-mono); font-size: 13.5px; line-height: 1.7;
  letter-spacing: 0.005em; min-height: 132px;
}
.ppreview {
  margin-top: 10px; border: 1px solid var(--line); background: var(--soft);
  border-radius: 2px; overflow: hidden;
}
.pp-head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px;
  padding: 10px 12px; border-bottom: 1px solid var(--line-2);
  font-size: 12px; color: var(--muted);
}
.pp-head b { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.pp-match { margin-left: auto; font-weight: 500; }
.pp-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.pp-table th {
  padding: 7px 10px; text-align: left;
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--muted-2); background: #fff;
}
.pp-table td { padding: 7px 10px; border-top: 1px solid var(--line-2); vertical-align: baseline; }
.pp-table td:first-child { color: var(--muted-2); font-family: var(--ff-mono); font-size: 11px; width: 28px; }
.pp-table th:nth-child(3) { width: 62px; text-align: right; }
.pp-table td:nth-child(3) { text-align: right; }
.pp-table th:nth-child(4) { width: 148px; }
.pp-table .pm { font-family: var(--ff-mono); font-size: 12.5px; font-weight: 500; color: var(--ink); word-break: break-all; }
.pp-table .pm a { border-bottom: 1px solid #C6CFD8; }
.pp-table .pm a:hover { border-color: var(--accent); color: var(--accent-dk); }
.pp-table .pq { width: 46px; font-variant-numeric: tabular-nums; }
.pp-note {
  padding: 8px 12px 10px; border-top: 1px solid var(--line-2);
  font-size: 11px; line-height: 1.5; color: var(--muted-2); background: #fff;
}
.pp-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 500;
}
.pp-badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.pp-badge.ok { color: #276A4C; }
.pp-badge.listed { color: #8A6516; }
.pp-badge.unknown { color: var(--muted-2); }

/* ---------- submit block ---------- */
.qsubmit { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.qsubmit .btn { min-height: 52px; font-size: 15.5px; }
.qsubmit .btn[disabled] { opacity: 0.6; cursor: progress; }
.qsubmit-note {
  margin-top: 11px; font-size: 12.5px; line-height: 1.55; color: var(--muted);
}
.qsubmit-note strong { color: var(--ink); font-weight: 600; }
.qsubmit-alt { margin-top: 6px; font-size: 12px; color: var(--muted-2); }
.qform .form-note { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.qform .form-note a { border-bottom: 1px solid #C6CFD8; color: var(--ink); }
.qform .form-note a:hover { border-color: var(--accent); color: var(--accent-dk); }

.qalert {
  margin-top: 14px; padding: 13px 14px;
  border: 1px solid #E4B7B1; border-left: 3px solid #B3261E;
  background: #FFFAF9; border-radius: 2px;
  font-size: 13px; line-height: 1.55; color: #7C2B22;
}
.qalert b { display: block; color: #6A2119; margin-bottom: 3px; }
.qalert a { text-decoration: underline; text-underline-offset: 2px; font-weight: 600; }
.qalert .qalert-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.qalert .qalert-acts .btn { min-height: 40px; font-size: 13px; }

/* ---------- lookup (inline block on category / model pages) ---------- */
.lookup-inline { display: grid; gap: 7px; width: 100%; }
.lookup-inline label {
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--muted-2);
}
.lookup-row { display: flex; gap: 8px; }
.lookup-row input {
  flex: 1 1 auto; min-width: 0;
  padding: 11px 12px; border: 1px solid #C6D0DA; border-radius: 2px;
  font-family: var(--ff-mono); font-size: 14px; color: var(--ink);
  background: #fff;
}
.lookup-row input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.lookup-row .btn { flex: 0 0 auto; min-height: 46px; padding: 0 18px; font-size: 14px; }
.find-note { font-size: 11.5px; line-height: 1.5; color: var(--muted-2); }

/* ---------- /search/ ---------- */
.lhead { padding: 34px 0 40px; }
.lhead-in { max-width: 860px; }
.lhead h1 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: 30px; line-height: 1.15; letter-spacing: -0.022em;
  margin-top: 10px; max-width: 26ch;
  text-wrap: balance;
}
.lhead .lede { margin-top: 14px; }

.lookup { margin-top: 30px; display: grid; gap: 9px; }
.lookup > label {
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--muted-2);
}
.lookup .lookup-row { gap: 10px; }
.lookup .lookup-row input {
  height: 58px; padding: 0 16px;
  font-family: var(--ff-mono); font-size: 16px; letter-spacing: 0.01em;
  border: 1px solid #B9C4CF; border-radius: 2px;
}
.lookup .lookup-row .btn { min-height: 58px; padding: 0 26px; font-size: 15px; }
.lookup-hint { font-size: 12px; line-height: 1.55; color: var(--muted); }
.lookup-hint span { font-weight: 600; color: var(--ink); }

.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 4px; }
.chip {
  padding: 5px 10px; border: 1px solid var(--line); border-radius: 2px;
  background: #fff; color: #435261;
  font-family: var(--ff-mono); font-size: 11.5px; cursor: pointer;
  transition: border-color .15s ease, color .15s ease, background-color .15s ease;
}
.chip:hover { border-color: var(--accent); color: var(--accent-dk); background: #FFF8F2; }

.lres { margin-top: 26px; }
.lres:empty { margin-top: 0; }
.res-head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px;
  padding-bottom: 10px; border-bottom: 1px solid var(--line);
  font-size: 12px; color: var(--muted);
}
.res-head b { font-size: 12.5px; color: var(--ink); font-weight: 600; }
.res-head .res-kill { margin-left: auto; }
.res-kill button {
  background: none; border: 0; padding: 0; cursor: pointer;
  font-size: 12px; color: var(--muted); border-bottom: 1px solid #C6CFD8;
}
.res-kill button:hover { color: var(--ink); border-color: var(--accent); }

.hit {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "main side" "go go";
  gap: 6px 16px; align-items: center;
  padding: 15px 2px; border-bottom: 1px solid var(--line-2);
}
.hit:hover { background: #FAFCFD; }
.hit-main { grid-area: main; min-width: 0; }
.hit-model {
  display: inline-block;
  font-family: var(--ff-mono); font-size: 15px; font-weight: 500;
  color: var(--ink); word-break: break-all;
  border-bottom: 1px solid transparent;
}
.hit-model:hover { border-color: var(--accent); color: var(--accent-dk); }
.hit-meta { margin-top: 3px; font-size: 12px; color: var(--muted); }
.hit-side {
  grid-area: side; display: flex; flex-direction: column;
  align-items: flex-end; gap: 2px; text-align: right;
}
.hit .st {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 2px 7px; border-radius: 2px;
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.02em;
  background: var(--soft); color: #435261;
}
.hit .st-in { background: #EDF5F0; color: #276A4C; }
.hit .st-short { background: #FFF3E6; color: #8A5217; }
.hit .st-sourced { background: #EEF1F4; color: #4A5A69; }
.hit-lead { font-size: 10.5px; color: var(--muted-2); }
.hit-go {
  grid-area: go; font-size: 12.5px; font-weight: 600; color: var(--accent-dk);
  display: inline-flex; align-items: center; gap: 5px;
}
.hit-go:hover { text-decoration: underline; text-underline-offset: 3px; }

.miss {
  margin-top: 6px; padding: 20px 18px;
  border: 1px solid var(--line); border-left: 3px solid var(--accent);
  background: var(--soft); border-radius: 0 2px 2px 0;
}
.miss h2 {
  font-family: var(--ff-head); font-size: 18px; font-weight: 700;
  letter-spacing: -0.01em;
}
.miss p { margin-top: 8px; font-size: 13.5px; line-height: 1.6; color: #435261; max-width: 66ch; }
.miss-acts { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 15px; }
.miss-acts .btn { min-height: 44px; font-size: 13.5px; }
.miss-acts b { font-family: var(--ff-mono); font-weight: 500; }
.miss-note { font-size: 11.5px !important; color: var(--muted-2) !important; }

.lhelp { margin-top: 46px; padding: 34px 0 40px; border-top: 1px solid var(--line); background: var(--soft); }
.lhelp-in { display: grid; gap: 30px; }
.lhelp h2 {
  font-family: var(--ff-head); font-size: 18px; font-weight: 700;
  letter-spacing: -0.012em; margin-bottom: 10px;
}
.lhelp p { font-size: 14px; line-height: 1.65; color: #435261; max-width: 62ch; }
.lhelp p + p { margin-top: 10px; }
.lhelp .btn { margin-top: 16px; min-height: 44px; font-size: 14px; }
.lcat { display: grid; gap: 0; margin-top: 2px; border-top: 1px solid var(--line); }
.lcat li { border-bottom: 1px solid var(--line); }
.lcat a { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; padding: 12px 0; }
.lcat strong { font-size: 14px; font-weight: 600; color: var(--ink); }
.lcat span { font-size: 11.5px; color: var(--muted-2); white-space: nowrap; }
.lcat a:hover strong { color: var(--accent-dk); }

/* ---------- /quote/thank-you/ ---------- */
.thanks { padding: 44px 0 56px; }
.thanks-in { max-width: 760px; }
.thanks h1 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: 32px; line-height: 1.12; letter-spacing: -0.024em;
  margin-top: 8px; max-width: 22ch;
  text-wrap: balance;
}
.thanks-lede { margin-top: 14px; font-size: 15px; line-height: 1.65; color: var(--muted); max-width: 60ch; }
.thanks-lede a { color: var(--ink); border-bottom: 1px solid #C6CFD8; }
.thanks-card {
  display: grid; gap: 0; margin-top: 28px;
  border: 1px solid var(--line); border-radius: 2px; overflow: hidden;
}
.thanks-ref {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 14px 16px; background: var(--ink); color: #C9D5E1;
}
.thanks-ref span {
  font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
}
.thanks-ref b {
  font-family: var(--ff-mono); font-size: 15px; font-weight: 500; color: #fff;
  letter-spacing: 0.02em;
}
.thanks-sla { display: flex; gap: 11px; padding: 16px; background: #fff; }
.thanks-sla .sla-dot { margin-top: 6px; background: #3FBF7A; box-shadow: 0 0 0 3px rgba(63,191,122,0.18); }
.thanks-sla p { font-size: 13px; line-height: 1.6; color: var(--muted); }
.thanks-sla strong { color: var(--ink); font-weight: 600; }

.thanks-steps { display: grid; gap: 14px; margin-top: 28px; counter-reset: ts; }
.thanks-steps li {
  position: relative; padding-left: 34px;
  font-size: 14px; line-height: 1.62; color: #435261; counter-increment: ts;
}
.thanks-steps li::before {
  content: counter(ts); position: absolute; left: 0; top: 1px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--soft); border: 1px solid var(--line);
  font-family: var(--ff-mono); font-size: 11px; color: var(--muted);
  display: flex; align-items: center; justify-content: center;
}
.thanks-steps b { display: block; color: var(--ink); font-weight: 600; font-size: 14.5px; }

.thanks-acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.thanks-acts .btn { min-height: 46px; font-size: 14px; }

.thanks-links {
  display: grid; gap: 0; margin-top: 34px;
  border-top: 1px solid var(--line);
}
.thanks-links li { padding: 12px 0; border-bottom: 1px solid var(--line-2); }
.thanks-links a {
  font-size: 13.5px; font-weight: 600; color: var(--ink);
  border-bottom: 1px solid #C6CFD8;
}
.thanks-links a:hover { border-color: var(--accent); color: var(--accent-dk); }
.thanks-links span { display: block; margin-top: 3px; font-size: 12px; color: var(--muted); }

/* ---------- responsive ---------- */
@media (min-width: 640px) {
  .qhead-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .qhead-facts li:nth-child(n) { border-left: 1px solid var(--line-2); padding-left: 14px; }
  .qhead-facts li:first-child { border-left: 0; padding-left: 0; }
  .lhead h1, .qhead h1 { font-size: 34px; }
  .thanks h1 { font-size: 38px; }
  .thanks-card { grid-template-columns: 220px minmax(0, 1fr); }
  .thanks-ref { flex-direction: column; align-items: flex-start; gap: 4px; justify-content: center; }
  .lhelp-in { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 40px; }
}

@media (min-width: 760px) {
  .qrow-side { grid-template-columns: 150px minmax(0, 1fr); }
  .qform { padding: 30px 30px 30px; }
}

@media (min-width: 1000px) {
  .qhead { padding-top: 40px; }
  .qhead-in { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; gap: 44px; }
  .qhead h1 { font-size: 40px; }
  .qwrap { grid-template-columns: minmax(0, 1.5fr) minmax(300px, 0.62fr); gap: 44px; }
  .qaside { position: sticky; top: 88px; }
  .hit {
    grid-template-columns: minmax(0, 1fr) 132px max-content;
    grid-template-areas: "main side go"; gap: 0 18px;
    padding: 13px 8px;
  }
  .hit-go { justify-self: end; white-space: nowrap; }
}

@media (max-width: 639px) {
  .qhead-facts li:nth-child(n) { padding-right: 12px; }
  .qhead h1, .lhead h1 { font-size: 27px; }
  .lookup .lookup-row { flex-direction: column; }
  .lookup .lookup-row .btn { width: 100%; }
  .lookup-row { flex-direction: column; }
  .lookup-row .btn { width: 100%; }
  .qsubmit .btn { width: 100%; }
  .pp-table th:nth-child(4), .pp-table td:nth-child(4) { display: none; }
  .thanks h1 { font-size: 28px; }
}

/* ---------- print ---------- */
@media print {
  .lookup, .chips, .lhelp, .thanks-acts, .qaside { display: none !important; }
  .qhead, .thanks { padding-top: 0; }
}

/* ---------- model page: inline quick form ---------- */
.pquote-alt { margin-top: 12px; font-size: 12.5px; line-height: 1.55; color: var(--muted); }
.pquote-alt a { color: var(--accent-dk); border-bottom: 1px solid #D8BFA8; }
.pquote-alt a:hover { border-color: var(--accent); }

.qform-quick { gap: 14px; }
.qpart {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px; align-items: center;
  padding: 12px 14px; border: 1px solid var(--line-2); background: var(--soft);
}
.qpart-k {
  display: block; font-size: 9.5px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted-2); margin-bottom: 3px;
}
.qpart .mono { font-family: var(--ff-mono); font-size: 13.5px; font-weight: 500; word-break: break-all; }
.qpart-qty { display: grid; gap: 4px; width: 92px; }
.qpart-qty label { font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted-2); }
.qpart-qty input { padding: 7px 8px; font-size: 14px; text-align: center; }
.qform-quick .form-note { margin-top: 4px; padding-top: 0; border-top: 0; font-size: 11.5px; }

.thanks-sum {
  margin-top: 12px; font-size: 12.5px; font-weight: 500;
  letter-spacing: 0.01em; color: var(--accent-dk);
}

/* ---------- inline lookup inside the bottom recovery block ----------
   catalog.css sizes the right column as `auto`, which lets the input stretch
   and squeezes the heading to three words per line. Bound it. */
@media (min-width: 900px) {
  .find-in { grid-template-columns: minmax(0, 1fr) minmax(300px, 400px); gap: 30px; }
  .find-acts { width: 100%; justify-content: stretch; }
  .lookup-inline { width: 100%; }
}
.find-acts > .lookup-inline + .find-note { margin-top: 7px; }

/* ---------- iOS zoom guard ----------
   `.qform select` (14.5px), `.qform textarea#q-parts` (13.5px) and the lookup
   input (14px) are all under the 16px threshold Safari uses to decide whether
   to zoom on focus. They also out-specify the `.field input` rule in site.css,
   so the reset has to live here, after it. */
@media (max-width: 760px) {
  .qform .field input, .qform .field textarea,
  .qform select, .qform textarea#q-parts,
  .lookup-row input { font-size: 16px; }
}
