/* =============================================================
   LEXUNYU — tracker selection check (tool page)
   Depends on site.css tokens and lexunyu-sections.css (--mono, --lx-ease)
   ============================================================= */

.page-hero .tool-meta {
  margin: 18px 0 0;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}

.tool { padding: 56px 0 clamp(90px, 8vw, 120px); }
.tool__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  gap: clamp(40px, 5vw, 78px);
  align-items: start;
}

/* ---------- questions ---------- */
.tool__form { display: grid; gap: 0; border-top: 1px solid var(--ink); }
.q { margin: 0; padding: 30px 0; border: 0; border-bottom: 1px solid var(--line); }
.q legend {
  display: flex; align-items: baseline; gap: 14px;
  padding: 0; margin-bottom: 6px;
  font-size: 21px; font-weight: 700; line-height: 1.24; letter-spacing: -.022em;
}
.q__n { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--red); }
.q__hint { margin: 0 0 16px; max-width: 44em; color: var(--muted); font-size: 14px; line-height: 1.6; }
.q legend + .opts, .q legend + .q__text { margin-top: 18px; }

.opts { display: grid; gap: 9px; }
.opts label {
  position: relative; display: flex; align-items: center; gap: 13px;
  min-height: 52px; padding: 10px 16px;
  border: 1px solid #cbd1d7; background: #fff; cursor: pointer;
  font-size: 15px; line-height: 1.45;
  transition: border-color .16s var(--lx-ease), background .16s var(--lx-ease), color .16s var(--lx-ease);
}
.opts label::before {
  content: ""; flex: 0 0 auto; width: 15px; height: 15px;
  border: 1px solid #b6bdc5; background: #fff;
  transition: border-color .16s var(--lx-ease), background .16s var(--lx-ease), box-shadow .16s var(--lx-ease);
}
.opts label:hover { border-color: var(--ink); }
.opts input { position: absolute; opacity: 0; width: 0; height: 0; }
.opts label:has(input:checked) { border-color: var(--ink); background: var(--ink); color: #fff; }
.opts label:has(input:checked)::before { background: var(--red); border-color: var(--red); box-shadow: inset 0 0 0 3px var(--ink); }
.opts label:focus-within { outline: 2px solid var(--red); outline-offset: 2px; }

.opts--chips { grid-auto-flow: column; grid-template-columns: none; display: flex; flex-wrap: wrap; gap: 9px; }
.opts--chips label { min-height: 46px; padding: 0 15px; }

.q__text {
  width: 100%; max-width: 34em; min-height: 52px; margin-top: 14px;
  padding: 13px 15px; border: 1px solid #cbd1d7; background: #fff;
  font-size: 15.5px; color: var(--ink); outline: none;
}
.q__text:focus { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }

/* ---------- result panel ---------- */
.tool__result { position: sticky; top: calc(var(--header) + 22px); }
.res { border: 1px solid var(--ink); background: var(--paper); }
.res__head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
  padding: 20px 24px 16px;
}
.res__head b { font-size: 17px; letter-spacing: -.02em; }
.res__head span { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.res__bar { height: 2px; background: var(--line); }
.res__bar i { display: block; height: 2px; width: 0; background: var(--red); transition: width .45s var(--lx-ease); }

.res__empty { padding: 26px 24px 30px; }
.res__empty p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.65; }

.res__block { padding: 22px 24px; border-bottom: 1px solid var(--line); }
.res__lbl { display: block; margin-bottom: 10px; font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.res__block > b { display: block; font-size: 18px; line-height: 1.3; letter-spacing: -.02em; }
.res__block p { margin: 10px 0 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.res__block ul { margin: 0; padding: 0; list-style: none; }
.res__block li { position: relative; padding-left: 18px; margin-bottom: 9px; font-size: 14px; line-height: 1.6; }
.res__block li::before { content: ""; position: absolute; left: 0; top: 8px; width: 6px; height: 6px; background: var(--red); }
.res__block li:last-child { margin-bottom: 0; }
.res__block--flag { background: #fdf3f2; }
.res__block--flag li::before { background: var(--ink); }

.res__acts { display: flex; flex-wrap: wrap; gap: 10px; padding: 22px 24px 6px; }
.res__acts .lx-fbtn { min-height: 46px; padding: 0 20px; font-size: 14px; text-decoration: none; }
.res__foot { margin: 0; padding: 14px 24px 22px; color: var(--muted); font-size: 12.5px; line-height: 1.6; }

/* ---------- notes ---------- */
.tool__notes { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(40px, 5vw, 80px); }
.tool__notes h2 { margin: 10px 0 0; }
.tool__notes-body p { margin: 0 0 16px; color: var(--muted); font-size: 16px; line-height: 1.75; max-width: 40em; }
.tool__notes-body p:last-child { margin-bottom: 0; }
.tool__notes-body strong { color: var(--ink); font-weight: 700; }

@media (max-width: 1050px) {
  .tool__layout { grid-template-columns: 1fr; }
  .tool__result { position: static; }
  .tool__notes { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 560px) {
  .q legend { font-size: 19px; }
  .opts label { font-size: 14.5px; }
}
@media (prefers-reduced-motion: reduce) {
  .opts label, .res__bar i { transition: none; }
}

.res__foot a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
