/* =====================================================================
   assets/question-types.css — /skill_tests "Question types" (9 Nov 2026)
   ---------------------------------------------------------------------
   Sits on top of assets/pages-ui.css (the Classic page kit: .cp tokens,
   .cp-card, .cp-btn …). Every class here starts with "qt-". Its own look:
   each type is an exam "ticket" — a coloured stub with the type's mark,
   a dashed tear line, then the name, one line, your progress.
   Day = .cp, night = html.dark .cp (the tokens switch by themselves).
   Light on weak phones: no blur, no big shadows, motion only on
   transform, nothing moves with "reduce motion".
   ===================================================================== */
.qt .qt-wk { font-size: 22px !important; line-height: 1.15; }

/* ── the skill switch (sticks under the menu while you scroll) ───────── */
.qt-switch { position: sticky; top: 62px; z-index: 5; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 6px;
  margin: 4px 0 18px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; box-shadow: var(--shadow); }
.qt-switch a { display: flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 0 10px; border-radius: 999px;
  color: var(--body); font-weight: 700; font-size: 14px; text-decoration: none; transition: background .15s, color .15s; }
.qt-switch a .cp-ic { color: var(--k); }
.qt-switch a em { font-style: normal; font-size: 11.5px; font-weight: 800; min-width: 22px; padding: 2px 6px; border-radius: 999px; background: var(--ks); color: var(--ki); text-align: center; }
.qt-switch a:hover, .qt-switch a.on { background: var(--ks); color: var(--ink); }
@media (max-width: 560px) {
  .qt-switch { top: 56px; border-radius: 18px; gap: 4px; padding: 5px; }
  .qt-switch a { flex-direction: column; gap: 2px; min-height: 52px; font-size: 11.5px; padding: 4px 2px; border-radius: 13px; }
  .qt-switch a em { display: none; }
}

/* ── "Start here": the weakest type ─────────────────────────────────── */
.qt-spot { display: flex; align-items: center; gap: 14px; padding: 16px 18px; margin: 0 0 22px; border-radius: 20px; text-decoration: none; color: var(--ink);
  background: linear-gradient(120deg, var(--gold-soft), var(--card) 75%); border: 1.5px solid var(--gold-fill); box-shadow: var(--shadow); transition: transform .15s; }
.qt-spot:hover { transform: translateY(-2px); }
.qt-spot-k { flex: none; width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--gold-fill); color: var(--gold-ink); }
.qt-spot-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.qt-spot-t b { font-size: 19px; line-height: 1.2; }
.qt-spot-t small { color: var(--body); font-size: 13px; }
@media (max-width: 560px) { .qt-spot { flex-wrap: wrap; } .qt-spot .cp-btn { width: 100%; justify-content: center; } }

/* ── a lane = one skill ──────────────────────────────────────────────── */
.qt-lane { position: relative; margin: 0 0 26px; padding: 18px 18px 20px 22px; border-radius: 24px; background: var(--card); border: 1px solid var(--line);
  box-shadow: var(--shadow); scroll-margin-top: 130px; overflow: hidden; }
.qt-lane::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--k); }
.qt-lane::after { content: attr(id); position: absolute; right: -6px; top: -18px; font-family: var(--num-font); font-size: 92px; line-height: 1; letter-spacing: .02em;
  text-transform: uppercase; color: var(--k); opacity: .06; pointer-events: none; }
.qt-lane-h { position: relative; display: flex; align-items: center; gap: 12px; margin: 0 0 14px; }
.qt-lane-ic { flex: none; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--k); color: #fff; }
html.dark .qt-lane-ic { color: #0a0820; }
.qt-lane-h > div { flex: 1; min-width: 0; }
.qt-lane-h h2 { margin: 0; font-size: 21px; font-weight: 800; }
.qt-lane-h p { margin: 2px 0 0; color: var(--mute); font-size: 13.5px; line-height: 1.35; }
.qt-all { flex: none; display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; color: var(--ki); text-decoration: none; padding: 8px 12px;
  border-radius: 999px; background: var(--ks); }
.qt-all:hover { text-decoration: underline; }
@media (max-width: 600px) {
  .qt-lane { padding: 14px 12px 14px 16px; border-radius: 20px; }
  .qt-lane-h { flex-wrap: wrap; }
  .qt-all { order: 3; margin-left: 58px; padding: 6px 10px; }
  .qt-lane::after { font-size: 64px; }
}
.qt-sub { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: 16px 0 10px; }
.qt-sub b { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ki); background: var(--ks); padding: 3px 9px; border-radius: 999px; }
.qt-sub span { color: var(--mute); font-size: 13px; }
.qt-lane-h + .qt-sub { margin-top: 4px; }

/* ── the tickets ─────────────────────────────────────────────────────── */
.qt-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.qt-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1000px) { .qt-grid, .qt-grid.three { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .qt-grid, .qt-grid.three { grid-template-columns: 1fr; gap: 9px; } }

.qt-tk { position: relative; display: flex; align-items: stretch; min-height: 92px; text-decoration: none; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 16px; transition: transform .15s, border-color .15s, box-shadow .15s; }
.qt-tk:hover { transform: translateY(-2px); border-color: var(--k); box-shadow: var(--shadow-up); }
.qt-tk:active { transform: translateY(0); }
.qt-tk:focus-visible { outline: 3px solid var(--k); outline-offset: 2px; }
/* the stub: the type's mark on the skill's colour, with two punched half-circles on the tear line */
.qt-stub { position: relative; flex: none; width: 62px; display: grid; place-items: center; background: var(--ks); border-radius: 15px 0 0 15px;
  border-right: 2px dashed color-mix(in srgb, var(--k) 45%, transparent); }
.qt-stub b { font-family: var(--lab-font); font-weight: 800; font-size: 16px; letter-spacing: .02em; color: var(--ki); }
.qt-stub::before, .qt-stub::after { content: ""; position: absolute; right: -8px; width: 14px; height: 14px; border-radius: 50%; background: var(--card);
  border: 1px solid var(--line); }
.qt-stub::before { top: -8px; clip-path: inset(50% 0 0 0); }
.qt-stub::after { bottom: -8px; clip-path: inset(0 0 50% 0); }
.qt-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 12px 42px 12px 14px; }
.qt-nm { font-size: 15px; line-height: 1.25; }
.qt-body small { color: var(--body); font-size: 13px; line-height: 1.35; }
.qt-meta { color: var(--mute); font-size: 12.5px; margin-top: 2px; }
.qt-meta em { font-style: normal; font-weight: 800; }
.qt .hi { color: var(--ok); } .qt .mid { color: var(--s-ink); } .qt .lo { color: var(--bad); }
.qt-bar { display: block; height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; margin-top: 5px; }
.qt-bar i { display: block; height: 100%; width: 100%; background: var(--k); transform-origin: left center; border-radius: 6px; }
.qt-bar.hi i { background: var(--ok); } .qt-bar.mid i { background: var(--s); } .qt-bar.lo i { background: var(--bad); }
.qt-go { position: absolute; right: 11px; top: 50%; margin-top: -14px; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: var(--card); color: var(--mute); border: 1px solid var(--line); transition: background .15s, color .15s; }
.qt-tk:hover .qt-go { background: var(--k); border-color: var(--k); color: #fff; }
.qt-badge { position: absolute; top: -9px; right: 12px; background: var(--bad); color: #fff; font-size: 10.5px; font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; padding: 3px 8px; border-radius: 999px; }
.qt-tk:not(.is-weak) .qt-badge { background: var(--gold-fill); color: var(--gold-ink); }
.qt-tk.is-weak { border-color: var(--bad); }
.qt-tk.is-weak .qt-stub { background: var(--bad-soft); }
.qt-tk.is-weak .qt-stub b { color: var(--bad); }

/* ── how it works ────────────────────────────────────────────────────── */
.qt-how { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 6px 0 16px; }
.qt-how div { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.qt-how b { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--gold-fill); color: var(--gold-ink); font-weight: 800; }
.qt-how p { margin: 0; font-size: 13.5px; color: var(--body); }
@media (max-width: 700px) { .qt-how { grid-template-columns: 1fr; gap: 8px; } }

@media (prefers-reduced-motion: reduce) { .qt-tk, .qt-spot { transition: none; } .qt-tk:hover, .qt-spot:hover { transform: none; } }

/* ── fixes after the first look (9 Nov 2026) ─────────────────────────── */
.qt-tk .qt-nm, .qt-spot-t b { color: var(--ink); }
.qt-tk:hover .qt-nm { color: var(--ki); }
@media (max-width: 600px) {
  .qt-lane-h > div { flex: 1 1 calc(100% - 60px); }
  .qt-tk { min-height: 64px; }
  .qt-tk .qt-body small { display: none; }           /* phones: name + progress only; the trainer explains each type */
  .qt-body { padding: 10px 40px 10px 12px; justify-content: center; }
  .qt-stub { width: 52px; }
  .qt-stub b { font-size: 14px; }
}
