/* Cover Letter Scanner + Writer (2026-09-27). On top of tools.css + resume-scanner/scanner.css
   (wizard, drop zone, check rows, tables). The letter paper (.lt-page) is used by the preview
   and by print, so the PDF is exactly the preview. Our tokens only. */

.cl-wrap { width: 100%; max-width: var(--container); margin: 0 auto; padding: 8px var(--gutter) 72px; flex: 1; box-sizing: border-box; }
.cl-hero { text-align: center; margin: 8px auto 26px; max-width: 780px; }
.cl-hero h1 { font-size: clamp(30px, 4vw, 46px); font-weight: 700; letter-spacing: -.025em; line-height: 1.12; margin: 12px 0; }
.cl-hero p { color: var(--ink-3); font-size: 17px; line-height: 1.55; }
.cl-hero.small h1 { font-size: clamp(24px, 3vw, 32px); }
.cl-hero.small p { display: none; }
.cl-app [hidden], .cl-toast[hidden] { display: none !important; }
.cl-app { scroll-margin-top: 76px; }

/* ---------- start ---------- */
.cl-start { max-width: none; }
.cl-modes { display: grid; grid-template-columns: 1fr 1fr; background: var(--paper-2); border-bottom: 1px solid var(--hair); }
.cl-modes button { border: 0; background: none; padding: 18px 20px; text-align: left; cursor: pointer; font-family: var(--sans); border-bottom: 3px solid transparent; }
.cl-modes button b { display: block; font-size: 17px; color: var(--ink-2); }
.cl-modes button span { font-size: 13.5px; color: var(--ink-3); }
.cl-modes button[aria-selected="true"] { background: var(--surface); border-bottom-color: var(--accent); }
.cl-modes button[aria-selected="true"] b { color: var(--ink); }
.cl-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; }
.cl-col textarea, .cl-col input[type="text"], .cl-fld input, .cl-fld textarea, .cl-fld select, .cl-left input[type="text"], .cl-notes { width: 100%; box-sizing: border-box; font: 14.5px/1.5 var(--sans); border: 1px solid var(--hair-2); border-radius: 10px; padding: 9px 12px; background: var(--surface); color: var(--ink); }
.cl-col textarea:focus, .cl-fld input:focus, .cl-fld textarea:focus, .cl-left input:focus, textarea.cl-p:focus, .cl-notes:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cl-h { font-size: 15px; font-weight: 700; margin: 14px 0 8px; }
.cl-h:first-child { margin-top: 0; }
.cl-h small { font-weight: 500; color: var(--ink-4); font-size: 12.5px; }
.cl-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.cl-chips button { border: 1px solid var(--hair-2); background: var(--surface); border-radius: 99px; padding: 6px 12px; font: 600 13px var(--sans); color: var(--ink-2); cursor: pointer; min-height: 36px; }
.cl-chips button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.cl-res-acts { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 6px; }
#res-paste { margin-top: 6px; }
.cl-seg { display: inline-flex; border: 1px solid var(--hair-2); border-radius: 10px; overflow: hidden; margin: 0 8px 8px 0; }
.cl-seg button { border: 0; background: var(--surface); padding: 8px 14px; font: 600 13px var(--sans); color: var(--ink-3); cursor: pointer; min-height: 38px; }
.cl-seg button + button { border-left: 1px solid var(--hair-2); }
.cl-seg button[aria-checked="true"] { background: var(--accent); color: #fff; }
.cl-seg button:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: -3px; }
.cl-notes { margin-top: 4px; }
.cl-drop { border: 1.5px dashed var(--accent-line); background: var(--paper); min-height: 220px; }
.cl-recent { padding: 18px 32px 24px; border-top: 1px solid var(--hair); }

/* ---------- workspace ---------- */
.cl-else { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; padding: 10px 16px; background: var(--warn-soft); border-bottom: 1px solid var(--hair); font-size: 14px; color: var(--ink); }
.cl-else span { flex: 1 1 260px; }
.cl-work { background: var(--surface); border: 1px solid var(--hair); border-radius: var(--r-lg); box-shadow: var(--shadow-md); overflow: clip; }
.cl-bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--hair); flex-wrap: wrap; }
.cl-iconbtn { width: 36px; height: 36px; border: 1px solid var(--hair-2); background: var(--surface); border-radius: 10px; display: grid; place-items: center; cursor: pointer; color: var(--ink-2); }
.cl-doc-title { border: 1px solid transparent; border-radius: 8px; padding: 6px 8px; font: 700 16px var(--sans); color: var(--ink); min-width: 120px; flex: 0 1 320px; background: none; }
.cl-doc-title:hover, .cl-doc-title:focus { border-color: var(--hair-2); outline: none; }
.cl-saved { font-size: 12px; color: var(--ink-4); }
.cl-gap, .cl-grow { flex: 1; }
.cl-pill { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--hair-2); background: var(--surface); border-radius: 12px; padding: 4px 10px 4px 6px; cursor: pointer; font-family: var(--sans); text-align: left; }
.cl-pill b { display: block; font-size: 15px; line-height: 1.1; }
.cl-pill small { font-size: 11px; color: var(--ink-3); }
.cl-pill .cl-ring > b { display: none; }
.cl-fixbtn svg { margin-right: 4px; }
.cl-dl { position: relative; }
.cl-menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; width: 300px; background: var(--surface); border: 1px solid var(--hair-2); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; }
.cl-menu button { display: block; width: 100%; text-align: left; border: 0; background: none; border-radius: 8px; padding: 9px 10px; cursor: pointer; font-family: var(--sans); }
.cl-menu button:hover { background: var(--paper); }
.cl-menu b { display: block; font-size: 14px; color: var(--ink); }
.cl-menu span { font-size: 12.5px; color: var(--ink-3); }
.cl-tabs { display: flex; background: var(--paper-2); border-bottom: 1px solid var(--hair); overflow-x: auto; scrollbar-width: none; }
.cl-tabs::-webkit-scrollbar { display: none; }
.cl-tabs button { border: 0; background: none; padding: 13px 16px; font: 600 14px var(--sans); color: var(--ink-3); cursor: pointer; white-space: nowrap; border-bottom: 2.5px solid transparent; min-height: 44px; }
.cl-tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); border-bottom-color: var(--accent); }
.cl-panel { padding: 22px 24px 30px; min-width: 0; }

.cl-ring { position: relative; display: inline-block; flex: none; }
.cl-ring svg { width: 100%; height: 100%; display: block; }
.cl-ring > b { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 24px; font-weight: 700; letter-spacing: -.03em; line-height: 1; }
.cl-ring > b small { font-size: 10px; font-weight: 600; color: var(--ink-3); margin-top: 5px; letter-spacing: 0; text-align: center; }

/* the verdict (Resume Worded's "worth fixing, not rewriting") */
.cl-verdict { display: grid; grid-template-columns: auto minmax(0, 1fr) minmax(0, 1.1fr); gap: 18px 22px; align-items: center; border: 1px solid var(--hair); border-radius: var(--r-md); padding: 16px 18px; margin-bottom: 18px; background: var(--paper); }
.cl-verdict.send { background: var(--ok-soft); border-color: #BBF7D0; }
.cl-verdict.rewrite { background: var(--bad-soft); border-color: #FECDD3; }
.cl-v-t b { display: block; font-size: 19px; letter-spacing: -.01em; margin-bottom: 4px; }
.cl-v-t p { margin: 0 0 10px; font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.cl-v-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.cl-v-acts .btn svg { margin-right: 4px; }
.cl-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; }
.cl-g { display: grid; grid-template-columns: 1fr auto; gap: 3px 8px; }
.cl-g .t { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.cl-g .n { font-size: 11.5px; color: var(--ink-3); }
.cl-g .bar { grid-column: 1 / 3; height: 7px; background: var(--paper-3); border-radius: 99px; overflow: hidden; }
.cl-g .bar i { display: block; height: 100%; border-radius: 99px; }
.cl-g .bar i.hi { background: var(--accent); } .cl-g .bar i.mid { background: var(--warn); } .cl-g .bar i.lo { background: var(--bad); }
.cl-ai-note { font-size: 12.5px; color: var(--ink-4); margin: 6px 0 12px; }

/* the letter with notes beside each paragraph */
.cl-rows { border: 1px solid var(--hair-2); border-radius: var(--r-md); overflow: hidden; }
.cl-row { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); }
.cl-row + .cl-row { border-top: 1px solid var(--hair); }
.cl-left { padding: 14px 16px; min-width: 0; }
.cl-right { padding: 12px 14px; background: var(--paper); border-left: 1px solid var(--hair); min-width: 0; }
.cl-row-all { grid-template-columns: minmax(0, 1fr); }
.cl-row-all .cl-left { display: flex; gap: 10px; align-items: baseline; padding-bottom: 4px; }
.cl-row-all .cl-right { border-left: 0; columns: 2; column-gap: 24px; padding-top: 4px; }
.cl-row-all .cl-note { break-inside: avoid; }
.cl-row-all .cl-note + .cl-note { border-top: 0; }
.cl-lab { display: block; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-4); margin-bottom: 4px; }
.cl-stats { font-size: 13.5px; color: var(--ink-2); }
.cl-head-sum { margin-bottom: 10px; }
.cl-head-sum b { display: block; font-size: 15px; }
.cl-head-sum span { display: block; font-size: 13px; color: var(--ink-3); }
.cl-p-h { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; flex-wrap: wrap; }
.cl-p-h .cl-lab { margin: 0; }
.cl-wc { font-size: 12px; color: var(--ink-4); }
textarea.cl-p { width: 100%; box-sizing: border-box; font: 15px/1.6 var(--sans); color: var(--ink); border: 1px solid var(--hair); border-radius: 10px; padding: 10px 12px; resize: vertical; background: var(--surface); overflow: hidden; }
.cl-mini { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--hair-2); background: var(--surface); border-radius: 8px; padding: 4px 10px; font: 600 12.5px var(--sans); color: var(--ink-2); cursor: pointer; min-height: 36px; }
.cl-mini:hover { border-color: var(--accent-line); color: var(--accent-ink); }
.cl-mini svg { width: 13px; height: 13px; }
.cl-del { color: var(--bad); }
.cl-rw { position: relative; }
.cl-rw-menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 10; background: var(--surface); border: 1px solid var(--hair-2); border-radius: 10px; box-shadow: var(--shadow-md); padding: 4px; min-width: 180px; }
.cl-rw-menu button { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 8px 10px; font: 500 13.5px var(--sans); border-radius: 6px; cursor: pointer; color: var(--ink); }
.cl-rw-menu button:hover { background: var(--accent-soft); }
.cl-note { display: grid; grid-template-columns: 22px 1fr; gap: 8px; padding: 6px 0; font-size: 13.5px; line-height: 1.45; }
.cl-note + .cl-note { border-top: 1px dashed var(--hair-2); }
.cl-note .ic { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; }
.cl-note .ic svg { width: 12px; height: 12px; }
.cl-note.pass .ic { background: var(--ok-soft); color: var(--ok); }
.cl-note.warn .ic { background: var(--warn-soft); color: var(--warn); }
.cl-note.fail .ic { background: var(--bad-soft); color: var(--bad); }
.cl-note.info .ic { background: var(--paper-2); color: var(--ink-3); }
.cl-note-h { display: flex; gap: 8px; align-items: baseline; }
.cl-note-h b { font-size: 13.5px; color: var(--ink); }
.cl-pts { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--ink-3); background: var(--surface); border-radius: 99px; padding: 1px 8px; white-space: nowrap; border: 1px solid var(--hair); }
.cl-note .fd { color: var(--ink-3); margin-top: 2px; }
.cl-note .fx { margin-top: 4px; color: var(--ink); background: var(--warn-soft); border-radius: 8px; padding: 6px 9px; }
.cl-note.fail .fx { background: var(--bad-soft); }
.cl-good { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ok); padding: 6px 0 2px; }
.cl-good svg { width: 13px; height: 13px; flex: none; }
.cl-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; }
.cl-h3 { font-size: 16px; font-weight: 700; margin: 24px 0 10px; }
.cl-h3 small { font-weight: 500; color: var(--ink-4); font-size: 12.5px; }
.cl-all { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.cl-all-g { border: 1px solid var(--hair); border-radius: 12px; padding: 10px 14px; }
.cl-all-g h4 { font-size: 14px; margin: 0 0 4px; display: flex; justify-content: space-between; }
.cl-all-g h4 small { color: var(--ink-3); font-weight: 600; }
.cl-lead { color: var(--ink-2); font-size: 14.5px; line-height: 1.6; margin: 0 0 12px; }

/* details / design: form + paper */
.cl-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.cl-split-k { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
.cl-design { grid-template-areas: "a v" "b v"; grid-template-rows: auto 1fr; row-gap: 0; }
.cl-design .cl-da { grid-area: a; } .cl-design .cl-db { grid-area: b; } .cl-design .cl-view { grid-area: v; }
.cl-form .cl-h3:first-child { margin-top: 0; }
.cl-fld { display: flex; flex-direction: column; gap: 4px; margin-bottom: 10px; min-width: 0; }
.cl-fld > label { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.cl-view { position: sticky; top: 72px; }
.cl-paper-wrap { background: var(--paper-2); border-radius: 12px; overflow: hidden; }
.cl-paper-wrap .lt-page { transform-origin: top left; box-shadow: var(--shadow-md); outline: 1px solid var(--hair-2); }
.cl-pages { font-size: 12.5px; color: var(--ink-3); margin: 8px 2px 0; }
.cl-warn { color: var(--bad); font-weight: 600; }
.cl-presets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.cl-presets button { border: 1.5px solid var(--hair-2); background: var(--surface); border-radius: 12px; padding: 8px; cursor: pointer; font-family: var(--sans); text-align: left; }
.cl-presets button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.cl-presets b { display: block; font-size: 13px; margin-top: 6px; }
.pv { display: block; height: 52px; border-radius: 6px; background: #fff; border: 1px solid var(--hair); position: relative; }
.pv::before { content: ''; position: absolute; left: 10%; top: 12%; width: 45%; height: 7px; border-radius: 2px; background: #111827; }
.pv::after { content: ''; position: absolute; left: 10%; right: 10%; top: 42%; height: 18px; background: repeating-linear-gradient(#cbd5e1 0 2px, transparent 2px 6px); }
.pv-modern::before { background: #4F46E5; height: 9px; }
.pv-executive::before, .pv-serif::before { left: 27%; }
.pv-classic { box-shadow: inset 0 -30px 0 -29px #1E3A8A; }
.pv-minimal::before { background: #0F766E; }
.cl-accents { display: flex; gap: 8px; flex-wrap: wrap; }
.cl-accents button { width: 30px; height: 30px; border-radius: 50%; border: 3px solid var(--surface); box-shadow: 0 0 0 1px var(--hair-2); cursor: pointer; }
.cl-accents button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }

/* job match */
.cl-mhead { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.cl-mhead b { display: block; font-size: 17px; margin-bottom: 4px; }
.cl-mhead p { margin: 0; font-size: 14px; color: var(--ink-2); line-height: 1.5; }
.cl-kw { width: 100%; border-collapse: collapse; font-size: 14px; }
.cl-kw th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); font-weight: 700; padding: 10px 12px; background: var(--paper); border-bottom: 1px solid var(--hair-2); white-space: nowrap; }
.cl-kw td { padding: 9px 12px; border-bottom: 1px solid var(--hair); vertical-align: middle; }
.cl-kw tr:last-child td { border-bottom: 0; }
.cl-kw td b { display: block; }
.cl-kw td small { font-size: 11.5px; color: var(--ink-4); }
.cl-kw tr.fail td:first-child b { color: var(--bad); }
.cl-kw td.c { text-align: center; color: var(--ink-4); }
.cl-kw td.c svg { width: 15px; height: 15px; color: var(--ok); }
.cl-pick { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; font-weight: 600; color: var(--accent-ink); cursor: pointer; white-space: nowrap; }
.cl-jd { max-height: 560px; overflow: auto; font-size: 13.5px; }

/* AI */
.cl-ai { display: grid; gap: 14px; max-width: 900px; }
.cl-card { background: var(--surface); border: 1px solid var(--hair); border-radius: var(--r-md); padding: 16px 18px; }
.cl-card-h { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--accent-ink); margin: -16px -18px 14px; padding: 11px 18px; background: var(--accent-soft); border-radius: var(--r-md) var(--r-md) 0 0; border-bottom: 1px solid var(--accent-line); }
.cl-card p { font-size: 14.5px; color: var(--ink-2); line-height: 1.55; margin: 0 0 12px; }
.cl-card .btn svg { margin-right: 4px; }
.cl-draft { border: 1px solid var(--hair-2); border-radius: 12px; padding: 12px 16px; margin: 14px 0 10px; background: var(--paper); }
.cl-draft p { color: var(--ink); }
.cl-draft.flagged, .cl-opt.flagged { border-color: var(--warn-line); }
mark.cl-blank, .lt-page mark { background: var(--warn-soft); color: #92400E; border-radius: 3px; padding: 0 2px; }
.cl-opts { display: grid; gap: 8px; margin-top: 10px; }
.cl-opt { border: 1px solid var(--hair-2); border-radius: 12px; padding: 10px 12px; background: var(--surface); margin-top: 8px; }
.cl-opt p { margin: 0 0 8px; font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.cl-opt > div { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.cl-opt > div .btn { margin-left: auto; }
.cl-tagw { font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--bad-soft); color: var(--bad); }
.cl-steps { margin: 0 0 0 20px; padding: 0; }
.cl-steps li { font-size: 14px; color: var(--ink-4); margin-bottom: 4px; }
.cl-steps li.on { color: var(--ink); font-weight: 600; }
.cl-steps li.done { color: var(--ok); }
.cl-rev-h { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: center; justify-content: space-between; }
.cl-rev-h h3 { margin: 0 0 4px; font-size: 19px; }
.cl-rev-h p { margin: 0; color: var(--ink-3); font-size: 14px; max-width: 560px; }
.cl-ba { display: flex; align-items: center; gap: 10px; }
.cl-ba > div { text-align: center; }
.cl-ba small { display: block; font-size: 11.5px; color: var(--ink-4); }
.cl-ba .arrow { color: var(--ink-4); font-size: 22px; }
.cl-chg-in { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 12px; }
.cl-chg-in input[type="checkbox"] { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--accent); }
.cl-chg .old { font-size: 13.5px; color: var(--ink-4); text-decoration: line-through; text-decoration-color: rgba(100, 106, 130, .5); line-height: 1.5; margin-bottom: 8px; }
.cl-chg .new { font-size: 15px; color: var(--ink); line-height: 1.7; }
.cl-chg.off .new { color: var(--ink-4); }
.cl-bl { font: inherit; font-size: 14px; border: 0; border-bottom: 2px solid var(--warn); background: var(--warn-soft); border-radius: 4px 4px 0 0; padding: 1px 6px; min-width: 110px; color: var(--ink); }
.cl-bl:focus { outline: none; border-bottom-color: var(--accent); background: var(--accent-soft); }
.cl-bl.filled { border-bottom-color: var(--ok); background: var(--ok-soft); }
.cl-rev-foot { position: sticky; bottom: 0; z-index: 4; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: flex-end; padding: 12px 0 2px; background: linear-gradient(to top, var(--surface) 70%, rgba(255, 255, 255, 0)); }
.cl-rev-foot .note { margin-right: auto; font-size: 13.5px; color: var(--ink-3); }

/* saved */
.cl-pg-h { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.cl-saved { display: grid; gap: 8px; }
.cl-sv { display: flex; align-items: center; gap: 12px; border: 1px solid var(--hair); border-radius: 12px; padding: 10px 14px; flex-wrap: wrap; background: var(--surface); }
.cl-sv.on { border-color: var(--accent-line); background: var(--accent-soft); }
.cl-sv > div:nth-child(2) { flex: 1; min-width: 160px; }
.cl-sv b { display: block; font-size: 14.5px; }
.cl-sv span { font-size: 12.5px; color: var(--ink-3); }
.cl-sv .cl-ring > b { font-size: 14px; }
.cl-sv-acts { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.cl-sv-acts em { font-style: normal; font-size: 12.5px; color: var(--accent-ink); font-weight: 600; }
.cl-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-pill); font-size: 14px; box-shadow: var(--shadow-lg); z-index: 60; width: max-content; max-width: calc(100vw - 32px); box-sizing: border-box; text-align: center; }
/* how it works + the worked example (page copy under the app) */
.cl-how { margin: 8px 0 40px; }
.cl-steps4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 12px; }
.cl-steps4 .step { background: var(--surface); border: 1px solid var(--hair); border-radius: var(--r-md); padding: 16px; }
.cl-steps4 .step b { display: block; font-size: 15.5px; margin-bottom: 4px; }
.cl-steps4 .step p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
.cl-ex { margin: 0 0 48px; }
.cl-ex-lead { color: var(--ink-2); font-size: 16px; line-height: 1.6; max-width: 820px; }
.cl-ex-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 22px; align-items: start; margin-top: 14px; }
.cl-ex-paper { background: #fff; color: #1f2937; border: 1px solid var(--hair-2); border-radius: 12px; box-shadow: var(--shadow-sm); padding: 26px 30px; font-size: 15px; line-height: 1.6; }
.cl-ex-paper p { margin: 0 0 12px; }
.cl-ex-paper p:last-child { margin-bottom: 0; }
.cl-ex-paper mark { background: var(--warn-soft); color: #92400E; border-radius: 3px; padding: 0 2px; }
.cl-ex-side > p { font-size: 15px; line-height: 1.6; color: var(--ink-2); margin: 0 0 12px; }
.cl-ex-score { font-size: 17px !important; color: var(--ink) !important; }
.cl-ex-score b { font-size: 30px; letter-spacing: -.02em; }
.cl-ex-t { margin: 0 0 14px; }
.cl-ex-t td:last-child { text-align: right; white-space: nowrap; }
.cl-ex-notes { margin: 0 0 14px 20px; padding: 0; }
.cl-ex-notes li { font-size: 14.5px; line-height: 1.55; color: var(--ink-2); margin-bottom: 8px; }
.cl-ex-notes li span { display: block; color: var(--ink-3); }
.cl-ex-in { border: 1px solid var(--hair); border-radius: 10px; padding: 0 12px; margin: 0 0 8px; background: var(--surface); }
.cl-ex-in summary { cursor: pointer; font-weight: 600; font-size: 14px; padding: 10px 0; min-height: 24px; }
.cl-ex-in pre { white-space: pre-wrap; overflow-wrap: anywhere; font: 13px/1.55 var(--sans); color: var(--ink-2); margin: 0 0 12px; }
.cl-art { display: flex; gap: 10px; }
.cl-art i { width: 70px; height: 92px; background: #fff; border: 1px solid var(--hair-2); border-radius: 6px; box-shadow: var(--shadow-sm); }

/* ---------- the letter paper ---------- */
.lt-page { box-sizing: border-box; width: 8.5in; height: 11in; padding: var(--lt-margin, 1in); background: #fff; color: #1f2937; font-family: var(--lt-font); font-size: var(--lt-size, 11pt); line-height: var(--lt-lh, 1.3); overflow: hidden; text-align: left; -webkit-font-smoothing: antialiased; }
.lt-page.a4 { width: 8.27in; height: 11.69in; }
.lt-page * { box-sizing: border-box; }
.lt-flow > :first-child { margin-top: 0; }
.lt-head { margin-bottom: 1.4em; padding-bottom: .55em; }
.lt-name { font-size: 1.55em; font-weight: 700; color: #111827; line-height: 1.15; letter-spacing: -.01em; }
.name-m .lt-name { font-size: 1.3em; }
.name-xl .lt-name { font-size: 2em; color: var(--lt-accent); }
.lt-contact { font-size: .92em; color: #4b5563; margin-top: .25em; }
.lt-sep { color: #9ca3af; }
.rule-line .lt-head { border-bottom: 1px solid var(--lt-accent); }
.rule-bar .lt-head { border-bottom: 3px solid var(--lt-accent); }
.rule-double .lt-head { border-bottom: 3px double var(--lt-accent); }
.hdr-center .lt-head { text-align: center; }
.lt-page p { margin: 0 0 1em; }
.lt-date { margin-bottom: 1em; }
.lt-close { margin: 0 0 2.6em !important; }
.lt-sig { margin: 0 !important; font-weight: 600; color: #111827; }

/* a button that cannot be pressed yet looks it (the reason is written next to it) */
.cl-app .btn:disabled, .cl-app .btn[disabled] { opacity: .5; cursor: not-allowed; box-shadow: none; filter: saturate(.4); }

/* ---------- phones ---------- */
@media (max-width: 960px) {
  .cl-grid, .cl-split, .cl-split-k, .cl-verdict, .cl-row, .cl-all, .cl-ex-grid { grid-template-columns: minmax(0, 1fr); }
  .cl-steps4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cl-right { border-left: 0; border-top: 1px dashed var(--hair-2); }
  .cl-row-all .cl-right { columns: 1; }
  .cl-view { position: static; }
  .cl-design { grid-template-areas: "a" "v" "b"; grid-template-rows: auto; row-gap: 18px; }
  .cl-verdict { justify-items: start; }
}
@media (max-width: 560px) {
  .cl-wrap { padding: 8px 12px 56px; }
  .cl-modes button { padding: 14px 12px; }
  .cl-modes button b { font-size: 15px; }
  .cl-grid2, .row2, .cl-groups, .cl-steps4 { grid-template-columns: minmax(0, 1fr); }
  .cl-ex-paper { padding: 18px 16px; }
  .cl-panel { padding: 16px 12px 24px; }
  .cl-left, .cl-right { padding: 12px; }
  .cl-presets { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cl-pill small { display: none; }
  .cl-doc-title { flex-basis: 100%; order: -1; }
  .cl-recent { padding: 14px 16px; }
  .wiz-body { padding: 18px 14px; }
  /* Download menu: a sheet along the bottom of the screen, never off its edge */
  .cl-menu { position: fixed; left: 12px; right: 12px; top: auto; bottom: 12px; width: auto; max-height: calc(100vh - 24px); overflow-y: auto; z-index: 70; box-shadow: 0 -8px 40px rgba(15, 23, 42, .28); }
  .cl-menu button { padding: 12px 12px; }
  /* phones: every small control is at least 40 px tall */
  .cl-mini, .cl-iconbtn, .cl-doc-title { min-height: 40px; }
  .cl-iconbtn { width: 40px; height: 40px; }
  /* the tab strip scrolls sideways: fade the right edge so the hidden tabs show they are there */
  .cl-tabs { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .cl-tabs.at-end { -webkit-mask-image: none; mask-image: none; }
}

/* ---------- print: only the letter, full size ---------- */
.cl-print { display: none; }
@media print {
  body.cl-printing > *:not(.cl-print) { display: none !important; }
  body.cl-printing .cl-print { display: block; }
  body.cl-printing { background: #fff !important; }
  .cl-print .lt-page { box-shadow: none; transform: none; }
  .cl-print mark { background: none; color: inherit; }
}

/* phones: buttons wrap, text links are big enough to tap */
.cl-app .wiz-acts { flex-wrap: wrap; }
.cl-app .wiz-acts .btn { white-space: normal; text-align: center; }
.cl-app .link-btn { min-height: 40px; }

/* Lines of the post to stress + "why this company" (2026-10-03) */
.cl-app .cl-stress { margin: 8px 0 4px; }
.cl-app .cl-stress p { margin: 0 0 6px; color: var(--ink-3); }
.cl-app .cl-stress-list { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; padding: 2px; }
.cl-app .cl-stress-list button { text-align: left; font: 500 13.5px/1.4 var(--sans); color: var(--ink-2); background: var(--surface); border: 1px solid var(--hair-2); border-radius: 8px; padding: 8px 10px 8px 34px; min-height: 40px; cursor: pointer; position: relative; overflow-wrap: anywhere; }
.cl-app .cl-stress-list button::before { content: ""; position: absolute; left: 10px; top: 10px; width: 16px; height: 16px; border-radius: 4px; border: 1.5px solid var(--hair-2); background: var(--paper); }
.cl-app .cl-stress-list button[aria-pressed="true"] { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent-ink); }
.cl-app .cl-stress-list button[aria-pressed="true"]::before { background: var(--accent); border-color: var(--accent); box-shadow: inset 0 0 0 3px var(--accent-soft); }
.cl-app .cl-why { margin: 8px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--paper-2); border: 1px solid var(--hair-2); font-size: 13.5px; line-height: 1.5; color: var(--ink-2); }
.cl-app .cl-why p { margin: 0 0 4px; }
.cl-app .cl-why a { color: var(--accent-ink); font-weight: 600; }
.cl-app .cl-stress-now { margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: var(--accent-soft); border: 1px solid var(--accent-line); font-size: 13.5px; line-height: 1.5; color: var(--ink-2); }
.cl-app .cl-stress-now ul { margin: 6px 0 4px; padding-left: 18px; }

/* AI errors (2026-10-03 audit: a 429 under Fix my letter was grey text that was easy to miss) */
.cl-app .ai-err { display: flex; gap: 8px; align-items: flex-start; margin: 10px 0 0; padding: 10px 12px; border-radius: 10px; background: #fff7e6; border: 1px solid #f5c26b; color: #5b3b00; font-size: 14.5px; line-height: 1.45; font-weight: 500; }
.cl-app .ai-err::before { content: "!"; flex: none; width: 18px; height: 18px; border-radius: 50%; background: #e8a317; color: #fff; font: 700 12px/18px var(--sans, sans-serif); text-align: center; margin-top: 1px; }
