/* ============================================================================
   Ask Solved's visual blocks (src/blog-visuals.mjs), loaded only on an article
   that uses one. Tokens only (web/css/base.css), so Light, Auto and Dark all
   work; phone first; nothing wider than the column (a wide drawing scrolls in
   its own box); drawn, not animated.
   The Landlord Toolkit's look: teal, the gold line, Montserrat headings, Inter
   text, and its red and green flags from the warn and ok tokens.
   ========================================================================== */

.article-body .vx-timeline, .article-body .vx-compare__list, .article-body .vx-formmap__parts,
.article-body .vx-flow, .article-body .vx-flow__answers { list-style: none; margin-bottom: 0; padding: 0; }
/* Lists inside a block start flush; the blocks themselves keep the column's spacing. */
.article-body :is(.vx-compare__list, .vx-formmap__parts, .vx-flow__answers) { margin-top: 0; }
.article-body :is(.vx-timeline, .vx-compare__list, .vx-formmap__parts, .vx-flow, .vx-flow__answers) > li + li { margin-top: 0; }
.article-body :is(.vx-timeline, .vx-compare__list, .vx-formmap__parts, .vx-flow, .vx-flow__answers) > li::marker { content: none; }
.vx-timeline strong, .vx-compare strong, .vx-formmap strong, .vx-flow strong { color: var(--heading); font-weight: 600; }

/* ---------------------------------------------------------------- timeline -- */
/* An ordered list on the gold line: each step's "when" beside a gold stop. */
.vx-timeline { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); }
.vx-timeline__step { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; padding: 0 0 20px 38px; }
.vx-timeline__step:last-child { padding-bottom: 2px; }
.vx-timeline__step::before { content: ""; position: absolute; left: 10px; top: 14px; bottom: -6px; width: 3px; border-radius: 3px; background: var(--gold-line); }
.vx-timeline__step:last-child::before { content: none; }
.vx-timeline__step::after { content: ""; position: absolute; left: 2px; top: 3px; width: 19px; height: 19px; border-radius: 50%; box-sizing: border-box; border: 4px solid var(--gold-mid); background: var(--paper); }
.vx-timeline__when { font: 700 0.98rem/1.35 var(--font-display); letter-spacing: -0.01em; color: var(--heading); }
.vx-timeline__when, .vx-timeline__what { min-width: 0; overflow-wrap: anywhere; }
.vx-timeline__what { line-height: 1.6; }
@media (min-width: 640px) {
  .vx-timeline__step { grid-template-columns: 8.5rem minmax(0, 1fr); gap: 16px; padding-left: 36px; }
  .vx-timeline__when { padding-top: 1px; }
  /* A step without its bold label keeps its text in the text column, not squeezed into the label's. */
  .vx-timeline__what:first-child { grid-column: 2; }
}

/* ----------------------------------------------------------------- compare -- */
/* Two labelled columns, the Toolkit's green and red flags: stacked on phones, side by side from 640px. */
.vx-compare { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
@media (min-width: 640px) { .vx-compare { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } .vx-compare--one { grid-template-columns: minmax(0, 1fr); } }
.vx-compare__col { min-width: 0; border: 1px solid var(--border); border-radius: var(--r-md); overflow: hidden; background: var(--paper); }
.vx-compare__label { display: flex; align-items: center; gap: 10px; padding: 11px 14px; font: 700 0.98rem/1.3 var(--font-display); letter-spacing: -0.01em; }
.vx-compare__label span { min-width: 0; overflow-wrap: anywhere; }
.vx-compare__col--yes { border-color: color-mix(in oklab, var(--ok) 35%, var(--border)); }
.vx-compare__col--no { border-color: color-mix(in oklab, var(--warn) 35%, var(--border)); }
.vx-compare__col--yes .vx-compare__label { background: var(--ok-bg); color: color-mix(in oklab, var(--ok) 78%, var(--ink)); }
.vx-compare__col--no .vx-compare__label { background: var(--warn-bg); color: color-mix(in oklab, var(--warn) 78%, var(--ink)); }
.vx-mark { flex: none; width: 22px; height: 22px; }
.vx-compare__col--yes .vx-mark circle { fill: var(--ok); }
.vx-compare__col--no .vx-mark circle { fill: var(--warn); }
.vx-mark path { stroke: var(--paper); }
.article-body .vx-compare__list { padding: 2px 14px 6px; }
.vx-compare__list > li { padding: 10px 0; border-top: 1px solid var(--border); line-height: 1.55; overflow-wrap: anywhere; }
.vx-compare__list > li:first-child { border-top: 0; }

/* ----------------------------------------------------------------- formmap -- */
/* Our drawing of a document (never the form itself): a sheet with a folded corner, the gold line
   down its edge, ruled like a form, and the parts to watch marked in the warn colours. */
.vx-formmap__sheet { position: relative; padding: 20px 18px 18px 24px; border: 1px solid var(--border-strong); border-radius: 6px 0 6px 6px; background: var(--paper); box-shadow: var(--e2); }
.vx-formmap__sheet::before { content: ""; position: absolute; left: -1px; top: 20px; bottom: 20px; width: 4px; border-radius: 0 4px 4px 0; background: var(--gold-line); }
.vx-formmap__sheet::after { content: ""; position: absolute; top: -1px; right: -1px; width: 30px; height: 30px; border-bottom-left-radius: 7px; background: linear-gradient(to bottom left, var(--paper) 50%, var(--paper-3) 50%); box-shadow: -2px 2px 3px -1px hsl(var(--shadow-hsl) / 0.18); }
.vx-formmap__head { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 12px; align-items: start; padding-right: 26px; }
.vx-formmap__ico { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--teal-subtle); color: var(--heading); }
.vx-formmap__ico svg { width: 24px; height: 24px; }
.article-body .vx-formmap__k { font: 600 11.5px/1.3 var(--font-text); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-ink); }
.article-body .vx-formmap__title { margin-top: 4px; font: 700 1.04rem/1.35 var(--font-display); letter-spacing: -0.01em; color: var(--heading); overflow-wrap: anywhere; }
.article-body .vx-formmap__note { margin-top: 3px; font-size: 0.86rem; line-height: 1.45; color: var(--ink-soft); }
.article-body .vx-formmap__parts { margin-top: 14px; border-top: 1px solid var(--border); }
.vx-formmap__part { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 10px; align-items: start; padding: 10px 8px 10px 0; border-bottom: 1px dashed var(--border-strong); line-height: 1.55; }
.vx-formmap__n { display: grid; place-items: center; width: 26px; height: 26px; margin-top: 1px; border: 1px solid var(--border-strong); border-radius: 6px; background: var(--paper-2); font: 700 0.8rem/1 var(--font-display); color: var(--heading); font-variant-numeric: tabular-nums; }
.vx-formmap__t { min-width: 0; overflow-wrap: anywhere; }
.vx-formmap__part--watch { margin-inline: -8px 0; padding-left: 8px; border-radius: 6px; background: var(--warn-bg); border-bottom-style: solid; border-bottom-color: color-mix(in oklab, var(--warn) 30%, var(--border)); box-shadow: inset 3px 0 0 var(--warn); }
.vx-formmap__part--watch .vx-formmap__n { border-color: var(--warn); color: color-mix(in oklab, var(--warn) 80%, var(--ink)); background: var(--paper); }
.vx-formmap__flag { display: inline-block; margin-left: 4px; padding: 1px 8px; border-radius: var(--r-pill); border: 1px solid color-mix(in oklab, var(--warn) 55%, transparent); font: 700 0.7rem/1.5 var(--font-text); letter-spacing: 0.06em; text-transform: uppercase; color: color-mix(in oklab, var(--warn) 80%, var(--ink)); white-space: nowrap; vertical-align: 1px; }
.article-body .vx-formmap__fine { margin-top: 14px; font-size: 0.86rem; line-height: 1.5; color: var(--ink-soft); }
.article-body .vx-formmap__link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-top: 12px; padding: 8px 16px; border: 1.5px solid var(--teal); border-radius: var(--r-pill); font-weight: 600; color: var(--heading); text-decoration: none; }
.vx-formmap__link .ico { width: 18px; height: 18px; color: var(--accent-ink); }
.vx-formmap__link:hover { background: var(--teal-subtle); }

/* -------------------------------------------------------------------- flow -- */
/* A decision path: numbered question cards joined by a drafted line; each answer's label is a chip. */
.vx-flow { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.vx-flow__q { position: relative; scroll-margin-top: var(--onpage-h, 0px); }   /* (its links land as the answers' headings do: blog.css) */
@media (min-width: 1100px) { .vx-flow__q { scroll-margin-top: 0; } }
.vx-flow__q + .vx-flow__q::before { content: ""; position: absolute; left: 30px; top: -17px; height: 18px; border-left: 2px dashed var(--draft-soft); }
.vx-flow__card { padding: 14px 16px 12px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--paper); box-shadow: var(--e1); }
.vx-flow__q:target .vx-flow__card { border-color: var(--accent-ink); box-shadow: 0 0 0 3px color-mix(in oklab, var(--gold-1) 45%, transparent); }
.article-body .vx-flow__text { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; align-items: start; font: 600 1rem/1.5 var(--font-text); color: var(--heading); }
.vx-flow__text > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.vx-flow__n { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--gold-line); color: var(--on-gold); font: 700 0.85rem/1 var(--font-display); }
/* A question's answers share two columns, the chips and the text, so every answer's text starts at the
   same place; on a phone, a question with a long label puts each chip above its text. */
.article-body .vx-flow__answers { display: grid; grid-template-columns: fit-content(40%) minmax(0, 1fr); gap: 8px 10px; margin-top: 10px; }
.vx-flow__a { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-items: baseline; row-gap: 4px; padding-top: 8px; border-top: 1px solid var(--border); line-height: 1.55; }
.vx-flow__a > .vx-flow__then:only-child { grid-column: 1 / -1; }
@media (max-width: 599px) { .article-body .vx-flow__answers--long { grid-template-columns: minmax(0, 1fr); } }
.vx-flow__chip { justify-self: start; display: inline-block; min-width: 2.8rem; max-width: 100%; overflow-wrap: anywhere; padding: 2px 10px; border-radius: var(--r-pill); background: var(--teal-subtle); color: var(--heading); font: 700 0.8rem/1.5 var(--font-text); text-align: center; }
.vx-flow__then { min-width: 0; overflow-wrap: anywhere; }
@media (min-width: 480px) { .article-body .vx-flow__answers { margin-left: 42px; } }

/* ---------------------------------------------------------------- official -- */
/* One official page or PDF, like the form card. */
.article-body .vx-official { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--paper); color: var(--ink); text-decoration: none; }
.vx-official:hover { border-color: var(--teal); }
.vx-official__ico { flex: none; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--teal-subtle); color: var(--heading); }
.vx-official__ico svg { width: 24px; height: 24px; }
.vx-official__body { flex: 1; min-width: 0; display: grid; gap: 2px; }
.vx-official__k { font: 600 11px/1.3 var(--font-text); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-ink); }
.vx-official__body strong { color: var(--heading); font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
.vx-official__meta { font-size: 0.85rem; color: var(--ink-soft); overflow-wrap: anywhere; }
.vx-official > .ico { flex: none; width: 18px; height: 18px; color: var(--accent-ink); }

/* ---------------------------------------------------------------- download -- */
/* A printable: its first page, the title, pages and size. */
.article-body .vx-download { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 16px; align-items: center; padding: 14px; border: 1px solid var(--border); border-radius: var(--r-lg); background: linear-gradient(135deg, var(--paper-2), var(--paper) 70%); color: var(--ink); text-decoration: none; box-shadow: var(--e1); }
@media (min-width: 640px) { .article-body .vx-download { grid-template-columns: 116px minmax(0, 1fr); gap: 20px; padding: 16px 18px; } }
.vx-download:hover { border-color: var(--teal); }
.vx-download__page { display: block; aspect-ratio: 8.5 / 11; overflow: hidden; border: 1px solid var(--border-strong); border-radius: 4px; background: var(--paper); box-shadow: var(--e2); }
.vx-download__page img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.vx-download__page--blank { background: repeating-linear-gradient(to bottom, var(--paper) 0 10px, var(--border) 10px 11px); }
.vx-download__body { display: grid; gap: 3px; min-width: 0; }
.vx-download__k { font: 600 11px/1.3 var(--font-text); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-ink); }
.vx-download__t { font: 700 1.05rem/1.3 var(--font-display); letter-spacing: -0.01em; color: var(--heading); overflow-wrap: anywhere; }
.vx-download__meta, .vx-download__checked { font-size: 0.86rem; color: var(--ink-soft); }
.vx-download__go { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-weight: 600; color: var(--heading); text-decoration: underline; text-decoration-color: color-mix(in oklab, var(--accent-ink) 70%, transparent); text-underline-offset: 0.22em; }
.vx-download__go .ico { width: 16px; height: 16px; color: var(--accent-ink); }

/* ------------------------------------------------------------------ figure -- */
/* A drawing inlined so it follows the theme (the designer's five classes), or a photo. */
.vx-figure { margin: 0; }
.vx-figure__art { overflow-x: auto; padding: 14px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--paper); color: var(--draft-ink); -webkit-overflow-scrolling: touch; }
.vx-figure__svg { display: block; width: 100%; height: auto; min-width: 280px; }
.vx-figure--narrow { max-width: 460px; margin-inline: auto; }
.vx-figure__svg .f-line { fill: none; stroke: currentColor; }
.vx-figure__svg .f-soft { fill: none; stroke: var(--draft-soft); }
.vx-figure__svg .f-fill { fill: var(--paper-2); }
.vx-figure__svg .f-accent { fill: var(--gold-1); stroke: var(--accent-ink); }
.vx-figure__svg .f-text { fill: currentColor; stroke: none; font-family: var(--font-text); }
.vx-figure__photo { overflow: hidden; border-radius: var(--r-md); background: var(--paper-3); }
.vx-figure__photo img { width: 100%; height: auto; }
.article-body .vx-figure__cap { margin-top: 8px; font-size: 0.88rem; line-height: 1.5; color: var(--ink-soft); }

/* -------------------------------------------------------- the notice tool -- */
.tool--notice .tool__warn { margin-top: 10px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--warn-bg); box-shadow: inset 3px 0 0 var(--warn); font-size: 0.9rem; line-height: 1.5; }
.tool--notice .tool__rule { margin-top: 10px; font-size: 0.92rem; line-height: 1.55; }
.tool--notice .tool__out dd { overflow-wrap: anywhere; }
/* On a phone each answer sits under its label, so a long date or line isn't squeezed to the right. */
@media (max-width: 559px) { .tool--notice .tool__out dl div { display: grid; gap: 2px; } .tool--notice .tool__out dd { text-align: left; } }
/* Side by side, the grid's gap spaces the fields: base.css's .field + .field margin would drop every
   field but the first by 16px, so the first row's two fields wouldn't line up. A two-line label
   lines its box up with the one beside it. */
@media (min-width: 640px) { .tool--notice .tool__grid { align-items: end; } .tool--notice .tool__grid > .field + .field { margin-top: 0; } }

/* ---------------------------------------------------------- screen, print -- */
@media (prefers-reduced-motion: no-preference) {
  .vx-official, .vx-download, .vx-formmap__link { transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
}
@media print {
  .vx-timeline__step, .vx-compare__col, .vx-formmap__sheet, .vx-flow__q, .vx-official, .vx-download, .vx-figure { break-inside: avoid; }
  .vx-formmap__sheet, .vx-flow__card, .vx-download, .vx-download__page { box-shadow: none; }
  .vx-figure__art { overflow: visible; }
  .vx-timeline__step::before, .vx-timeline__step::after, .vx-flow__n, .vx-formmap__sheet::before { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .vx-compare__label, .vx-formmap__part--watch { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
}
