/* ==========================================================================
   Promptly Found: tool surface layer (step 3d)
   Loads on /tools and every tool page (BaseLayout, for paths under /tools) after
   site-lead.css. Every rule is scoped to html.pfm.pfl. The copy and the markup do
   not change.

     Night    the heading band
     Console  the tool itself (the form or input), which crosses the bottom edge
              of the band from 1001px. Below that width it sits under the band.
     Desk     the results: a light gray area across the page, with the result
              cards as sheets at rest. Stats and callouts stay flat on the desk.
     List     the notes ("How the check works") and the /tools index: flat, a rule
              on top, the group heading sticky on the left
     Desk     "Guides about this" closes the page, with the guides as sheets

   The results stay light: they hold many color-coded states (pass, warning,
   fail) that are made for a light surface.
   ========================================================================== */

/* ---- The tool: a console ---------------------------------------------------- */
.pfm.pfl .pf-tx-hero > .pf-tx-hero__tool {
  --paper: var(--pfl-console); --panel: #222226; --ink: #edebe6; --ink-2: #b5b3ad; --ink-3: #918f8a;
  --line: var(--pfl-console-line); --accent: #e58a9a; --focus: #8eb0ff;
  --cc-ok: #5cc48e; --cc-warn: #e3a54e; --cc-bad: #e58a9a;
  position: relative; z-index: 1; max-width: var(--width-wide); padding: 28px 32px 26px; border-radius: 20px;
  background: var(--pfl-console); color: var(--ink); box-shadow: var(--pfl-console-lift);
}
.pfm.pfl .pf-tx-hero__tool .pf-tx-bar { border-color: #3a3a40; background: #121214; }
.pfm.pfl .pf-tx-hero__tool .pf-tx-bar:focus-within { border-color: var(--ink-3); }
.pfm.pfl .pf-tx-hero__tool :is(textarea, select, input:not([type="checkbox"], [type="radio"])) { color: var(--ink); }
.pfm.pfl .pf-tx-hero__tool .pf-tx-area { border-color: #3a3a40; background: #121214; }
.pfm.pfl .pf-tx-hero__tool .pf-tx-ex button { color: var(--ink-2); }
.pfm.pfl .pf-tx-hero__tool .pf-tx-ex button:hover { color: var(--ink); }
.pfm.pfl .pf-tx-hero__tool .pf-tx-index__label { color: var(--ink-2); }

/* ---- Results: sheets on the desk -------------------------------------------- */
.pfm.pfl .pf-tx-out {
  --line: #e2e0da; --panel: var(--pfl-sheet);
  margin-top: 64px; padding-block: 48px 56px;
  background: var(--pfl-desk); box-shadow: 0 0 0 100vmax var(--pfl-desk); clip-path: inset(0 -100vmax);
}
.pfm.pfl .pf-tx-out > :first-child { margin-top: 0; }
.pfm.pfl .pf-tx-out .pf-tx-card { --line: #ebe9e4; --panel: var(--pfl-desk); border: 0; border-radius: 16px; background: var(--pfl-sheet); box-shadow: var(--pfl-rest); }
.pfm.pfl .pf-tx-out .pf-tx-score { padding: 28px; }
.pfm.pfl .pf-tx-out .pf-tx-panel { padding-inline: 24px; }
.pfm.pfl .pf-tx-out .pf-pc__checks { padding: 4px 24px 12px; }
.pfm.pfl .pf-tx-out .pf-tx-stats li { border-top-color: var(--ink); }
.pfm.pfl .pf-tx-out .pf-tx-groups button { border-color: transparent; box-shadow: var(--pfl-rest); }
.pfm.pfl .pf-tx-out .pf-tx-groups button[aria-pressed="true"] { box-shadow: inset 0 0 0 1px var(--ink), var(--pfl-rest); }
/* the notes under the tool follow the results with the usual gap */
.pfm.pfl .pf-tx-out + .pf-ck__how { margin-top: 56px; }

/* ---- "Guides about this": the desk closes the page -------------------------- */
.pfm.pfl .pf-gap-l:has(> .pf-further) {
  margin-top: 96px; padding-block: 80px 96px;
  background: var(--pfl-desk); box-shadow: 0 0 0 100vmax var(--pfl-desk); clip-path: inset(0 -100vmax);
}
.pfm.pfl .pf-wrap:has(> .pf-gap-l:last-child > .pf-further) { padding-bottom: 0; }
.pfm.pfl .pf-gap-l > .pf-further .pf-entries--cols { gap: 20px; border: 0; border-radius: 0; overflow: visible; }
.pfm.pfl .pf-gap-l > .pf-further .pf-entry {
  border: 0; border-radius: 16px; background: var(--pfl-sheet); box-shadow: var(--pfl-rest); padding: 30px 32px;
}
.pfm.pfl .pf-gap-l > .pf-further .pf-entry:hover { background: color-mix(in srgb, var(--pfl-desk) 55%, var(--pfl-sheet)); }
.pfm.pfl .pf-gap-l > .pf-further .pf-entry:hover .pf-entry__title { color: var(--accent); }

/* ---- /tools: the tools as flat lists ---------------------------------------- */
.pfm.pfl .pf-tx-index .pf-tx-tools { border: 0; border-radius: 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line); overflow: visible; }
.pfm.pfl .pf-tx-index .pf-tx-tools a, .pfm.pfl .pf-tx-index .pf-tx-tools li:first-child a { padding-inline: 0; }
.pfm.pfl .pf-tx-index .pf-tx-tools a:hover { background: none; }
.pfm.pfl .pf-tx-index .pf-tx-tools a:hover h3 { color: var(--accent); }
.pfm.pfl .pf-tx-index .pf-tx-tools dl { border-left: 0; padding-left: 0; }
.pfm.pfl .pf-tx-index .pf-tx-tools a:hover .pf-tx-tools__art { background: color-mix(in srgb, var(--ink) 7%, var(--paper)); }

@media (min-width: 1001px) {
  .pfm.pfl { --pfl-cross: 76px; }
  /* the band runs on below the heading, and the tool crosses its bottom edge */
  .pfm.pfl .pf-tx-hero:has(> .pf-tx-hero__tool) > .pf-tx-hero__in { padding-bottom: calc(64px + var(--pfl-cross)); }
  .pfm.pfl .pf-tx-hero > .pf-tx-hero__tool { margin-top: calc(var(--pfl-cross) * -1); padding: 32px 36px 28px; }
  .pfm.pfl .pf-tx-hero--index > .pf-tx-hero__tool { max-width: 860px; }
  /* group headings on /tools stay in view while their list scrolls */
  .pfm.pfl .pf-tx-index { align-items: start; }
  .pfm.pfl .pf-tx-index > div:first-child { position: sticky; top: var(--pfl-rail-top); }
}
@media (max-width: 1000px) {
  .pfm.pfl .pf-tx-hero > .pf-tx-hero__tool { margin-top: 28px; }
  .pfm.pfl .pf-tx-out { padding-block: 36px 40px; }
  .pfm.pfl .pf-gap-l:has(> .pf-further) { padding-block: 56px 64px; }
}
@media (max-width: 600px) {
  .pfm.pfl .pf-tx-hero > .pf-tx-hero__tool { padding: 20px 16px; border-radius: 16px; }
  .pfm.pfl .pf-tx-out .pf-tx-score { padding: 20px 16px; }
  .pfm.pfl .pf-tx-out :is(.pf-tx-panel, .pf-pc__checks) { padding-inline: 16px; }
  .pfm.pfl .pf-gap-l > .pf-further .pf-entry { padding: 22px 20px; }
}
