/* Resume vs JD Keyword Match (v3, 2026-11-20): the score ring, the empty state, the reveal, the folded documents and the
   phone cards for the skill table. Theme tokens only, so light mode works. Selectors are doubled where gp-v2.css
   (loaded after this file) would otherwise win on equal specificity. */

/* ---- result panel: ring and verdict side by side, then the three figures ---- */
.v2-ring.m-ring { width: 132px; height: 132px; font-size: 16px; }
.m-ring-in { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; text-align: center; }
.v2-ring.m-ring .m-glyph { width: 40px; height: 40px; rotate: none; color: var(--muted); }
.m-score { font: 600 1.85rem/1 "JetBrains Mono", monospace; font-variant-numeric: tabular-nums; color: var(--text); }
.m-score small { display: block; margin-top: 6px; font: 500 .64rem/1.3 "Plus Jakarta Sans", sans-serif; color: var(--muted); letter-spacing: 0; }
.m-score.t-good { color: var(--green-text); }
.m-score.t-warn { color: var(--gold-text); }
.m-score.t-bad { color: var(--red-text); }
.v2-ring.m-ring[data-state="empty"] .m-score { display: none; }
.v2-ring.m-ring:not([data-state="empty"]) .m-glyph { display: none; }
.v2-ring.m-ring[data-state="few"] .m-score { font-size: 1.05rem; }
.v2-ring.m-ring[data-tier="good"] .v2-ring-fill { stroke: var(--green-text); }
.v2-ring.m-ring[data-tier="bad"] .v2-ring-fill { stroke: var(--red-text); }
.m-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: center; margin-bottom: 16px; }
.m-head-copy { display: grid; gap: 12px; min-width: 0; }
.m-head-copy .vt { margin: 0; }
.m-steps { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; counter-reset: st; font-size: .84rem; line-height: 1.45; color: var(--text-mid); }
.m-steps li { counter-increment: st; display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; align-items: start; }
.m-steps li::before { content: counter(st); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font: 700 .72rem/1 "JetBrains Mono", monospace; color: var(--gold-text); background: var(--surface2); border: 1px solid var(--border-hi); }
.t-kpis.m-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 14px; }
.m-kpis .t-kpi b { font-size: .92rem; }
.m-kpis .t-kpi span { line-height: 1.35; }
@media (max-width: 480px) {
  .v2-ring.m-ring { width: 112px; height: 112px; }
  .m-head { gap: 14px; }
}
@media (max-width: 380px) { .t-kpis.m-kpis { grid-template-columns: minmax(0, 1fr); } }

/* ---- the reveal: the panel and the results rise in once a run is done (restarted by JS) ---- */
@keyframes m-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.m-read.is-run .m-rise { animation: m-rise .55s var(--ease-out, ease-out) both; animation-delay: calc(var(--i, 0) * 70ms); }
.m-results.is-run > .sec { animation: m-rise .6s var(--ease-out, ease-out) both; }
.m-results.is-run > .sec:nth-child(2) { animation-delay: 60ms; }
.m-results.is-run > .sec:nth-child(3) { animation-delay: 120ms; }
.m-results.is-run > .sec:nth-child(4) { animation-delay: 180ms; }
.v2-ring.m-ring .v2-ring-fill { transition: stroke-dashoffset 1.1s var(--ease-out, ease-out); }

/* ---- the marked-up documents: no inner scroll, so the nice-to-have list is never cut off ---- */
.m-doc { max-height: none; overflow: visible; }
.btn.m-fold-toggle { display: none; margin: 0 0 12px; }

/* ---- the SAMPLE picture in the hero ---- */
.m-s-top { display: flex; align-items: center; gap: 18px; }
.m-s-facts { display: grid; gap: 8px; min-width: 0; flex: 1; }
.v2-ring.m-ring-s { width: 118px; height: 118px; flex: none; font-size: 14px; }
.v2-ring.m-ring-s b { font: 600 1.85em/1 "JetBrains Mono", monospace; }
.m-s-note { margin: 0; font-size: .82rem; line-height: 1.5; color: var(--text-mid); }

/* ---- phones: the marked-up documents start folded; the skill table reads as one card per skill ---- */
@media (max-width: 639px) {
  .btn.m-fold-toggle { display: inline-flex; }
  .m-fold:not(.is-open) { display: none; }
  .m-skills .t-skills thead { display: none; }
  .m-skills .t-skills,
  .m-skills .t-skills tbody { display: block; width: 100%; }
  .m-skills .t-skills tr { display: grid; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
  .m-skills .t-skills tr:last-child { border-bottom: 0; }
  .m-skills .t-skills tr.t-cur { display: block; padding: 10px 14px; background: var(--surface2); }
  .m-skills .t-skills td { display: block; border: 0; padding: 0; min-width: 0; overflow-wrap: anywhere; }
  .m-skills .t-skills td[data-l]:not([data-l="Skill"])::before { content: attr(data-l); display: block; margin-bottom: 2px; font: 600 .62rem/1.2 "JetBrains Mono", monospace; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
}

@media (prefers-reduced-motion: reduce) {
  .m-read.is-run .m-rise, .m-results.is-run > .sec { animation: none !important; }
  .v2-ring.m-ring .v2-ring-fill { transition: none !important; }
}
.v2-ring.m-ring[data-state="empty"] .v2-ring-fill, .v2-ring.m-ring[data-state="few"] .v2-ring-fill { opacity: 0; }
.v2-ring.m-ring .v2-ring-trk { stroke: var(--border-hi); }
