/* The written pages (kapshur.co/<slug>, made by scripts/seo/content.mjs from seo/content/*.md) and the free tools
   (kapshur.co/tools/*). Loaded after styles.css and guides.css; uses their tokens. One reading column, white cards,
   Fraunces for headings only, vermilion only for the main action. No JavaScript is needed. */

/* ---------------------------------------------------------------- article */
.ct-hero { padding-bottom: 8px; }
.ct-hero .display { font-size: clamp(34px, 4.6vw, 56px); line-height: 1.04; }
.ct-answer { max-width: 680px; color: var(--ink); font-size: 19px; }
.ct-answer a, .ct-body a, .ct-intro a, .faq a, .tl-prose a { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: var(--act); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.ct-meta { max-width: 680px; }

.ct-body { display: grid; gap: 16px; padding-top: 16px; max-width: 720px; }
.ct-body > p, .ct-body li { font-size: 17px; line-height: 1.65; }
.ct-body > p { color: var(--ink-2); }
.ct-body h2 {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 2.6vw, 30px); line-height: 1.15;
  letter-spacing: -0.02em; margin-top: 28px; scroll-margin-top: 96px;
}
.ct-body h3 { font-size: 19px; margin-top: 12px; scroll-margin-top: 96px; }
.ct-body h4 { font-size: 16px; margin: 8px 0 0; }
.ct-body strong { font-weight: 650; }
.ct-list, .ct-olist { display: grid; gap: 8px; padding-left: 22px; }
.ct-list { list-style: disc; }
.ct-olist { list-style: decimal; }
.ct-list li::marker, .ct-olist li::marker { color: var(--muted); }
.ct-body hr { border: 0; border-top: 1px solid var(--line-2); margin: 16px 0; }

/* a checklist (GFM task list): a white card with a row for each item */
.ct-checklist { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 4px 0; }
.ct-checklist li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 14px; padding: 14px 20px; font-size: 16px; }
.ct-checklist li + li { border-top: 1px solid var(--line); }
.ct-box { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line-2); margin-top: 2px; }

/* tables: a white card that scrolls sideways on a phone */
.ct-table { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; }
.ct-body .ct-table { width: min(920px, calc(100vw - 2 * var(--gutter))); }
.ct-table table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.45; }
.ct-table th, .ct-table td { text-align: left; vertical-align: top; padding: 12px 16px; border-bottom: 1px solid var(--line); min-width: 120px; }
.ct-table thead th { font-size: 13px; font-weight: 700; color: var(--muted); background: var(--soft); white-space: nowrap; }
.ct-table tbody th { font-weight: 650; }
.ct-table tr:last-child th, .ct-table tr:last-child td { border-bottom: 0; }
.ct-table .ct-center { text-align: center; }
.ct-table .ct-right { text-align: right; }

.ct-note { margin: 0; background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--ink); border-radius: 14px; padding: 16px 20px; display: grid; gap: 8px; }
.ct-note p { font-size: 16px; }
.ct-code { margin: 0; background: var(--ink); color: #F1F2F4; border-radius: 14px; padding: 16px 18px; overflow-x: auto; font: 14px/1.6 var(--font-mono); }
.ct-code code { background: none; padding: 0; color: inherit; }

.ct-section { padding-top: 48px; display: grid; gap: 16px; }
.ct-section .faq { max-width: 720px; }
.ct-intro { color: var(--muted); max-width: 640px; }
.ct-sources ul { display: grid; gap: 6px; font-size: 14px; color: var(--muted); max-width: 720px; overflow-wrap: anywhere; }
.ct-sources a { color: var(--ink); }

.ct-related { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.ct-rel { display: grid; gap: 6px; align-content: start; height: 100%; padding: 18px 20px; text-decoration: none; transition: border-color var(--ease), transform var(--ease); }
.ct-rel:hover { border-color: var(--line-2); transform: translateY(-2px); }
.ct-rel .hint { font-size: 14px; }
.ct-article { padding-bottom: 24px; }

/* ---------------------------------------------------------------- tools */
.tl-crumbs { padding-top: 40px; }
.tl-hero { padding-top: 16px; padding-bottom: 24px; display: grid; gap: 20px; justify-items: start; }
.tl-hero .display { font-size: clamp(36px, 5vw, 64px); }
.tl-hero .lede { max-width: 640px; }
.tl-form { width: 100%; max-width: 760px; display: grid; gap: 12px; }
.tl-fieldset { border: 0; padding: 0; margin: 0 0 4px; display: grid; gap: 10px; min-width: 0; }
.tl-segs { display: flex; flex-wrap: wrap; gap: 8px; }
.tl-seg { position: relative; }
.tl-seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tl-seg span { display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--card); font-size: 14px; font-weight: 600; color: var(--muted); }
.tl-seg input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.tl-seg input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }
.tl-label { font-size: 14px; font-weight: 650; display: block; margin-bottom: 6px; }
.tl-label .hint { font-weight: 500; }
.tl-input {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line-2);
  background: var(--soft); color: var(--ink); font: 15px/1.4 var(--font-mono);
}
.tl-input:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; background: var(--card); }
.tl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
.tl-check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); }
.tl-check input { width: 18px; height: 18px; margin-top: 1px; accent-color: var(--ink); flex: none; }
.tl-form button, .tl-out button { cursor: pointer; font-family: inherit; }
.tl-out[hidden], .tl-out [hidden] { display: none !important; }
.tl-out { width: 100%; max-width: 760px; display: grid; gap: 12px; }
.tl-url code { display: block; padding: 12px 14px; border-radius: 12px; background: var(--soft); font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; word-break: break-all; }
.tl-warn { display: grid; gap: 6px; padding-left: 20px; list-style: disc; font-size: 14px; color: #8A5300; }
.tl-error { font-weight: 600; }
.tl-qr { grid-template-columns: 220px minmax(0, 1fr); align-items: start; gap: 20px; }
.tl-qr-img svg { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); }
.tl-qr-side { display: grid; gap: 12px; min-width: 0; }
.tl-section { padding-top: 40px; padding-bottom: 8px; display: grid; gap: 16px; }
.tl-prose > * { max-width: 760px; }
.tl-prose p, .tl-prose li { font-size: 16px; line-height: 1.6; }

@media (max-width: 900px) {
  .ct-related { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .ct-related { grid-template-columns: minmax(0, 1fr); }
  .ct-answer { font-size: 17px; }
  .ct-body > p, .ct-body li { font-size: 16px; }
  .ct-checklist li { padding: 12px 16px; }
  .tl-grid { grid-template-columns: minmax(0, 1fr); }
  .tl-qr { grid-template-columns: minmax(0, 1fr); }
  .tl-qr-img { max-width: 240px; }
  .tl-crumbs { padding-top: 28px; }
}
