/* Job Search Agent page: compact steps + tracker demo */
.js-lede { margin-bottom: 36px; max-width: none; }
.js-section-title { margin-bottom: 12px; }
.steps.steps-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 32px; margin: 0 0 56px;
}
.steps.steps-grid li {
  grid-template-columns: 30px minmax(0, 1fr); grid-template-rows: auto 1fr;
  gap: 4px 10px; padding: 16px 0 18px; font-size: 14.5px; line-height: 1.45;
}
.steps.steps-grid li::before { grid-row: 1 / span 2; font-size: 13px; padding-top: 2px; }
.steps.steps-grid h3 { font-size: 16px; }
.steps.steps-grid p { grid-column: 2; }
@media (max-width: 900px) { .steps.steps-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps.steps-grid { grid-template-columns: 1fr; } }

.jd { margin: 0 0 56px; max-width: 1180px; }
.jd-title { font-size: 28px; font-weight: 400; letter-spacing: -0.01em; margin: 0 0 16px; }
.jd-notice {
  border: 1.5px solid var(--ink); padding: 14px 18px; font-size: 15px; line-height: 1.5;
  max-width: 52em; margin: 0 0 28px;
}
/* Tabs: wrap instead of scrolling */
.jd-tabs { display: flex; flex-wrap: wrap; gap: 0 28px; border-bottom: 1px solid var(--ink); margin-bottom: 24px; }
.jd-tabs button {
  font: inherit; font-size: 15px; background: none; border: 0; padding: 10px 0; color: var(--muted);
  cursor: pointer; box-shadow: inset 0 -2px 0 transparent; white-space: nowrap;
}
.jd-tabs button[aria-selected="true"] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
.jd-tabs button:hover { color: var(--ink); }

.jd-sub { color: var(--muted); font-size: 15px; margin: 0 0 18px; max-width: 46em; }
.jd-stats { display: flex; flex-wrap: wrap; margin: 0 0 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.jd-stat { padding: 12px 28px 12px 0; margin-right: 28px; }
.jd-stat b { display: block; font-size: 26px; font-weight: 400; font-variant-numeric: tabular-nums; line-height: 1.2; }
.jd-stat span { font-size: 13px; color: var(--muted); }
.jd-stat + .jd-stat { border-left: 1px solid var(--line); padding-left: 28px; margin-right: 0; }

.jd-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.jd-table th { text-align: left; font-weight: 400; font-size: 12.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding: 0 12px 8px 0; border-bottom: 1px solid var(--ink); }
.jd-table td { padding: 12px 12px 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.jd-table tr.pick { cursor: pointer; }
.jd-table tr.pick:hover td { background: #f6f6f6; }
.jd-table .why { color: var(--muted); font-size: 13.5px; margin-top: 3px; }
.jd-table .gap { color: #a3341f; font-size: 13px; margin-top: 2px; }
/* Room around tables so the pencil circles are not clipped */
.jd-wrap { overflow-x: auto; padding: 12px 16px 2px; margin: -12px -16px 0; }

/* Grades: a small dot (green strong, amber solid, gray weak) + the letter */
.g { display: inline-flex; align-items: center; gap: 7px; font-size: 14.5px; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.g i { width: 9px; height: 9px; border-radius: 50%; background: #c9c9c9; flex: none; }
.g small { color: var(--muted); font-weight: 400; font-size: 13px; }
.g.S i { background: #1f6f4a; }
.g.A i { background: #4f9a6e; }
.g.B i { background: #d59b2b; }
.g.C i { background: #c9c9c9; }
.g.D i { background: #e3e3e3; box-shadow: inset 0 0 0 1px #c9c9c9; }

.jd-btn { font: inherit; font-size: 14px; padding: 7px 16px; border: 0; border-radius: 999px; background: #f0f0f0; color: var(--ink); cursor: pointer; }
.jd-btn:hover { background: #e6e6e6; }
.jd-btn.primary { background: #1f6f4a; color: #fff; }
.jd-btn.primary:hover { background: #185c3d; }
.jd-btn.link { border-radius: 0; padding: 2px 0; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; background: none; font-size: 12.5px; }
.jd-btn.link:hover { color: var(--ink); background: none; }
.jd-select { font: inherit; font-size: 14px; padding: 6px 10px; border: 0; border-radius: 999px; background: #f0f0f0; color: var(--ink); }

/* Tailor & grade */
.jd-tailor { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 32px; align-items: start; }
.jd-main { min-width: 0; }
.jd-picklist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); position: sticky; top: 90px; }
.jd-picklist button { display: block; width: 100%; text-align: left; font: inherit; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 12px 8px 12px 0; cursor: pointer; color: var(--ink); }
.jd-picklist button[aria-current="true"] { background: #f4f4f4; padding-left: 10px; border-radius: 10px; }
.jd-picklist .co { font-size: 15px; display: flex; gap: 8px; align-items: center; }
.jd-picklist .rl-role { font-size: 13px; color: var(--muted); margin-top: 2px; }
.jd-picklist .stt { font-size: 12px; color: var(--muted); margin-top: 4px; }
.jd-head { display: flex; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; align-items: flex-start; }
.jd-head h3 { margin: 0; font-size: 21px; font-weight: 500; }
.jd-head .meta { color: var(--muted); font-size: 14px; margin-top: 2px; }
.jd-actions { position: relative; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 6px 4px 0 0; }
.jd-head.has-note { margin-bottom: 44px; }
/* The approve note hangs under the button, arrow pointing up at it */
.hand-approve { position: absolute; left: 18px; top: calc(100% + 6px); width: max-content; max-width: 420px; }
.jd-status { display: inline-block; font-size: 13px; padding: 4px 12px; border-radius: 999px; background: #f0f0f0; color: var(--muted); }
.jd-status.ok { background: #e3f1e8; color: #1f6f4a; }

.jd-brief { margin: 18px 0 22px; }
.jd-brief-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 4px 18px; margin-bottom: 6px; }
.jd-brief .lbl { font-size: 12.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.jd-brief-table { border-top: 1px solid var(--ink); font-size: 14px; }
.br { display: grid; grid-template-columns: 82px minmax(0, 1.1fr) minmax(0, 1fr) 76px; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.br-head { font-size: 12px; color: var(--muted); padding: 7px 0; }
.br .ask { color: var(--ink); }
.br .ev { color: var(--muted); }
.br .w { font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.br .w-center { color: var(--ink); font-weight: 700; }
.br .fit { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.br .fit i { width: 8px; height: 8px; border-radius: 50%; background: #c9c9c9; }
.br .f-strong i { background: #1f6f4a; }
.br .f-partial i { background: #d59b2b; }
.br .f-gap i { background: #c9c9c9; box-shadow: inset 0 0 0 1px #9a9a9a; background: #fff; }

.jd-key { font-size: 13px; color: var(--muted); margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; }
.jd-key .g { font-size: 13.5px; }

/* The resume as a sheet of paper; grades sit in the left margin */
.jd-sheet {
  background: #fff; border: 1px solid #e3e3e3; border-radius: 2px;
  box-shadow: 0 1px 2px rgba(0,0,0,.05), 0 10px 30px rgba(0,0,0,.06);
  padding: 34px 40px 30px 74px; margin: 0 0 12px; font-size: 14px; line-height: 1.45;
}
.rh { text-align: center; margin: 0 0 14px 0; }
.rh-name { font-size: 23px; font-weight: 500; letter-spacing: .01em; }
.rh-contact { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.rh-headline { font-size: 13.5px; margin-top: 6px; font-weight: 500; }
.rs { margin-top: 14px; }
.rs h5 { margin: 0 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; border-bottom: 1px solid var(--ink); padding-bottom: 3px; }
.rj { margin-top: 10px; }
.rj-top, .rj-sub { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.rj-top span, .rj-sub span { color: var(--muted); font-size: 13px; }
.rj-sub i { font-style: italic; }
.rl { position: relative; padding: 5px 0 5px 14px; }
.rl::before { content: "•"; position: absolute; left: 0; top: 5px; }
.rl.skill::before, .rl.plain::before { content: none; }
.rl.skill, .rl.plain { padding-left: 0; }
.rl-g { position: absolute; left: -56px; top: 5px; }
.rl.skill .rl-g, .rl.plain .rl-g { left: -56px; }
.rl-ctx { font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.rl-t { color: var(--ink); }
.rl.edited .rl-t { background: #fff7cc; }
.rl-n { font-size: 12.5px; line-height: 1.4; color: #b8362a; margin-top: 2px; }
.rl .tools { display: none; gap: 14px; margin-top: 2px; }
.rl:hover .tools, .rl:focus-within .tools, .rl .tools.show { display: flex; }
@media (hover: none) { .rl .tools { display: flex; } }
.rl textarea, .jd-cmt textarea { font: inherit; font-size: 14px; width: 100%; min-height: 60px; padding: 8px; border: 1px solid var(--ink); border-radius: 6px; box-sizing: border-box; resize: vertical; margin-top: 2px; }
.jd-cmt p { margin: 4px 0 0; font-size: 13px; color: var(--ink); background: #f4f4f4; padding: 6px 10px; border-radius: 6px; }

/* Track */
.jd-filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; margin: 0 0 6px; }
.jd-seg { display: inline-flex; background: #f0f0f0; border-radius: 999px; padding: 3px; }
.jd-seg button { font: inherit; font-size: 13px; padding: 5px 12px; border: 0; border-radius: 999px; background: none; cursor: pointer; color: var(--muted); }
.jd-seg button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
tr.new td { background: #fff7cc; }

/* Pencil notes: red crayon rings and handwritten asides, for the demo only */
.scrib { position: relative; display: inline-block; }
.scrib .ring {
  position: absolute; left: -14px; right: -14px; top: -9px; bottom: -9px; width: calc(100% + 28px); height: calc(100% + 18px);
  overflow: visible; pointer-events: none; filter: url(#crayon);
}
.scrib .ring path { fill: none; stroke: #d0392b; stroke-width: 2.2; stroke-linecap: round; vector-effect: non-scaling-stroke; opacity: .9; }
.hand {
  display: inline-flex; align-items: flex-end; gap: 4px; font-family: "Caveat", "Bradley Hand", cursive;
  font-size: 21px; line-height: 1.05; color: #c8342a; font-weight: 500; max-width: 30em;
}
.hand .arrow { width: 34px; height: 28px; flex: none; overflow: visible; filter: url(#crayon); }
.hand .arrow path { fill: none; stroke: #d0392b; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hand-up { align-items: flex-start; }
.hand-row { display: flex; margin: 2px 0 4px; }
.hand-row.right { justify-content: flex-end; padding-right: 150px; }
.hand-row.left { justify-content: flex-start; }
.hand-row.left .hand { margin-left: 0; }
.hand-grade { margin: 6px 0 -2px -8px; }
.hand-brief { font-size: 19px; }
.hand-track { margin-bottom: 2px; }

.jd-toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); opacity: 0;
  background: var(--ink); color: #fff; padding: 10px 16px; font-size: 14px; max-width: calc(100% - 32px); border-radius: 8px;
  transition: opacity .2s, transform .2s; pointer-events: none; z-index: 50;
}
.jd-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 860px) {
  .jd-tailor { grid-template-columns: 1fr; }
  .jd-picklist { position: static; }
  .jd-table .hide-sm { display: none; }
  .hand-row.right { justify-content: flex-start; padding-right: 0; }
  .jd-head.has-note { margin-bottom: 0; }
  .hand-approve { position: static; flex-basis: 100%; width: auto; max-width: 100%; margin-top: 4px; }
  .br { grid-template-columns: 64px minmax(0, 1fr) 70px; }
  .br .ev { grid-column: 2; grid-row: 2; font-size: 13px; }
  .br-head .ev, .br-head span:nth-child(3) { display: none; }
  .jd-sheet { padding: 24px 18px 22px 58px; }
  .rl-g, .rl.skill .rl-g { left: -48px; }
}
