/* Tree survey pages (/tree-surveys, its guides and its area pages) in the "Site Plan" brand.
   Loads after guides.css, whose article column, slot frame, cards and closing band these pages share.
   The drawings come from views/tree/_art.ejs; trees are green, the brand's tree colour (BRAND.md §3). */

/* ============ 1 · Drawings ============
   A drawing on paper keeps its light palette in dark mode too, like the guide illustrations.
   Each layer (.lyr) carries --p (0 → 1): strokes draw with dashoffset, fills fade, trees and RPAs grow. */
@property --p { syntax: "<number>"; inherits: true; initial-value: 1; }

.tdraw { display: block; width: 100%; height: 100%; color-scheme: light; }
.tdraw .lyr { --p: 1; }
.tdraw .ln { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: calc(1 - var(--p)); }
.tdraw .fd, .tdraw text, .tdraw .t-tag, .tdraw .t-north, .tdraw .t-stamp, .tdraw .t-cat { opacity: var(--p); }
.tdraw .gr { transform: scale(calc(.25 + .75 * var(--p))); opacity: calc(.2 + .8 * var(--p)); transform-box: fill-box; transform-origin: 50% 50%; }
.tdraw .gr.up { transform-origin: 50% 100%; }
.tdraw .gr.down { transform-origin: 50% 0; }

.tdraw text { font-family: var(--font-mono); font-size: 10px; letter-spacing: .07em; fill: #6B6F77; }
.tdraw .t-bg { fill: #F7F5F0; }
.tdraw .t-grid { fill: none; stroke: rgba(17, 18, 20, .045); stroke-width: 1; }
.tdraw .t-hbg { fill: #FFF3D6; }
.tdraw .t-hl { stroke: #F59E0B; stroke-width: 1.4; opacity: .75; }
.tdraw .t-soil { stroke: rgba(120, 100, 70, .15); stroke-width: 1; }
/* plan */
.tdraw .t-road { fill: #FFFFFF; }
.tdraw .t-kerb { stroke: #CFC7B8; stroke-width: 2; }
.tdraw .t-lane { stroke: #E4DFD3; stroke-width: 2; stroke-dasharray: 18 14; }
.tdraw .t-plot { fill: #F1EEE6; stroke: #DAD4C7; stroke-width: 1; }
.tdraw .t-plot.on { fill: #FBFAF6; stroke: #CFC7B8; }
.tdraw .t-lawn { fill: #EEF5E6; }
.tdraw .t-fp { fill: #E9E4D8; stroke: #CFC7B8; stroke-width: 1.2; }
.tdraw .t-fp.f { fill: #ECE8DE; stroke: #DAD4C7; }
.tdraw .t-ridge { stroke: #BDB5A4; stroke-width: 1; }
.tdraw .t-pathline { stroke: #E6E0D3; stroke-width: 10; }
.tdraw .t-kerbdrop { stroke: #D97706; stroke-width: 5; }
/* trees: canopies in green, the stem, the root protection area as a dashed green zone */
.tdraw .t-can { fill: #D8EEDC; stroke: #8FCB9E; stroke-width: 1.4; }
.tdraw .t-can2 { fill: #C9E7D0; stroke: none; }
.tdraw .t-can.on { fill: #BFE3C8; stroke: #16A34A; stroke-width: 1.6; }
.tdraw .t-can.e { fill: #9FD7AE; stroke: #5FB37A; stroke-width: 1.6; }
.tdraw .t-can.e2 { fill: #B4E0BF; stroke: #5FB37A; stroke-width: 1.4; }
.tdraw .t-stem { fill: #8E6B4E; }
.tdraw .t-rpa { fill: rgba(22, 163, 74, .07); stroke: #16A34A; stroke-width: 1.4; stroke-dasharray: 6 5; }
.tdraw .t-trunk { stroke: #8E6B4E; stroke-width: 9; }
.tdraw .t-branch { stroke: #8E6B4E; stroke-width: 4; }
.tdraw .t-root { stroke: #A88468; stroke-width: 1.6; }
.tdraw .t-fence { stroke: #15803D; stroke-width: 3.4; stroke-dasharray: none; }
.tdraw .t-post { fill: #15803D; }
.tdraw .t-tag rect { fill: #FFFFFF; stroke: rgba(17, 18, 20, .14); stroke-width: 1; }
.tdraw .t-tag text { font-size: 9.6px; fill: #15803D; letter-spacing: .08em; }
/* the proposal: amber hatch, amber-deep line */
.tdraw .t-prop { stroke: #D97706; stroke-width: 1.6; stroke-linejoin: round; }
.tdraw .t-propl { stroke: #D97706; stroke-width: 2; }
/* the red line: the application site, and nothing else */
.tdraw .t-site { stroke: #E5412D; stroke-width: 2.6; }
/* blueprint: dimensions and designations */
.tdraw .t-dim { stroke: #2E62F0; stroke-width: 1.2; }
.tdraw .t-dimhead { fill: none; stroke: #2E62F0; stroke-width: 1.3; }
.tdraw .t-dimt { fill: #1F47B8; font-size: 10.5px; }
.tdraw .t-tpo { stroke: #2E62F0; stroke-width: 1.8; }
.tdraw .t-area { fill: rgba(46, 98, 240, .05); stroke: #2E62F0; stroke-width: 1.4; stroke-dasharray: 7 5; }
.tdraw .t-north path { fill: #6B6F77; }
.tdraw .t-anno.a { fill: #8A4B04; }
.tdraw .t-anno.g { fill: #15803D; }
.tdraw .t-anno.b { fill: #1F47B8; }
.tdraw .t-anno.r { fill: #C23A27; }
.tdraw .t-anno.f { fill: #8C9098; }
/* elevation */
.tdraw .t-earth { fill: #EFE7D8; }
.tdraw .t-gl { stroke: #BFB6A4; stroke-width: 1.6; }
.tdraw .t-wall { stroke: none; }
.tdraw .t-ink { stroke: #8A8F99; stroke-width: 1.4; }
.tdraw .t-roof { fill: #5B6170; stroke: #4A505D; stroke-width: 1; }
.tdraw .t-chim { fill: #B9826A; stroke: #8E6150; stroke-width: 1; }
.tdraw .t-win { fill: #FFFFFF; stroke: #8A8F99; stroke-width: 1.4; }
.tdraw .t-bar { stroke: #8A8F99; stroke-width: 1; }
.tdraw .t-door { stroke: rgba(17, 18, 20, .25); stroke-width: 1; }
.tdraw .t-foot { fill: #DAD3C4; stroke: #BEB6A6; stroke-width: 1; }
.tdraw .t-crack { stroke: #3F434A; stroke-width: 1.4; }
/* map */
.tdraw .t-mcase { fill: none; stroke: #E4DFD3; stroke-width: 26; stroke-linecap: round; }
.tdraw .t-mroad { fill: none; stroke: #FFFFFF; stroke-width: 20; stroke-linecap: round; }
.tdraw .t-block { fill: #E9E4D8; stroke: #D3CCBC; stroke-width: .8; }
/* sheet */
.tdraw .t-desk { fill: #EFECE4; }
.tdraw .t-sheet { fill: #FFFFFF; stroke: #DED9CE; stroke-width: 1; filter: drop-shadow(0 10px 16px rgba(17, 18, 20, .1)); }
.tdraw .t-lined { fill: #E2DDD2; }
.tdraw .t-rule { stroke: #CFC7B8; stroke-width: 1.2; }
.tdraw .t-rule.f { stroke: #ECE8DE; }
.tdraw .t-cell { font-size: 11px; fill: #3F434A; }
.tdraw .t-cat rect { fill: #F1EEE6; }
.tdraw .t-cat text { font-size: 11px; font-weight: 600; fill: #3F434A; }
.tdraw .t-cat.cA rect { fill: #D8EEDC; } .tdraw .t-cat.cA text { fill: #15803D; }
.tdraw .t-cat.cB rect { fill: #E7F7EC; } .tdraw .t-cat.cB text { fill: #15803D; }
.tdraw .t-cat.cC rect { fill: #FFF0CF; } .tdraw .t-cat.cC text { fill: #8A4B04; }
.tdraw .t-cat.cU rect { fill: #EFECE4; } .tdraw .t-cat.cU text { fill: #6B6F77; }
.tdraw .t-stamp rect { fill: rgba(255, 255, 255, .7); stroke: #15803D; stroke-width: 2.4; }
.tdraw .t-stamp text { font-size: 17px; font-weight: 600; letter-spacing: .16em; fill: #15803D; }
/* small cards: labels and the finest lines go */
.tdraw--card .t-lane, .tdraw--card .t-root { display: none; }

/* Motion. The lead drawing draws itself as the page opens (motion mode only, motion-gate.ejs); later drawings wait
   until they scroll in (.rv-wait → .in, story.js). Crawlers, reduced motion and no-JS see the finished drawing. */
@keyframes tdIn { from { --p: 0; } to { --p: 1; } }
.pw-motion .tdraw--hero .lyr { animation: tdIn 900ms var(--ease-draw) both; animation-delay: calc(140ms + var(--d, 0) * 170ms); }
.pw-motion .tdraw--hero .lyr-labels { animation-duration: 500ms; }
.tdraw .gr { transition: none; }
.pw-motion .tdraw--hero .gr { transition-delay: calc(var(--o, 0) * 60ms); }
.tw .tdraw .lyr { transition: --p 900ms var(--ease-draw); transition-delay: calc(var(--d, 0) * 150ms); }
.pw-motion .tw.rv-wait:not(.in) .tdraw .lyr { --p: 0; }
.tw.instant .tdraw .lyr, .pw-static .tdraw .lyr { transition: none !important; animation: none !important; }
@media (prefers-reduced-motion: reduce) { .tdraw .lyr { animation: none !important; transition: none !important; --p: 1 !important; } }

/* ============ 2 · Page shell ============ */
.page-tree .ar-h1 em, .page-tree .tx-h1 em { font-style: normal; background: linear-gradient(transparent 60%, var(--amber-field) 60%, var(--amber-field) 92%, transparent 92%); padding: 0 .04em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.page-tree .label--tree::before { background: var(--green); box-shadow: 0 0 0 4px var(--green-wash); }
.page-tree .ar-hero-svg { aspect-ratio: 16 / 10; }
.page-tree .ar-hero-art figcaption { display: flex; justify-content: space-between; gap: 12px; }
.tx-key { display: inline-flex; flex-wrap: wrap; gap: 4px 12px; }
.tx-key i { display: inline-block; width: 12px; height: 8px; margin-right: 5px; border-radius: 2px; vertical-align: 0; }
.tx-key .k-tree { background: #D8EEDC; box-shadow: inset 0 0 0 1px #16A34A; border-radius: 50%; width: 9px; height: 9px; }
.tx-key .k-rpa { border: 1.4px dashed #16A34A; border-radius: 50%; width: 10px; height: 10px; }
.tx-key .k-site { border: 2px solid var(--site-red); }
.tx-key .k-prop { background: repeating-linear-gradient(45deg, #FFF3D6 0 2px, #F59E0B 2px 3.2px); box-shadow: inset 0 0 0 1px #D97706; }
@media (max-width: 640px) { .tx-key { display: none; } }

/* the article column, for blocks laid out outside .ar-article */
.tx-col { max-width: 640px; }
.tx-sec { padding-top: clamp(48px, 6vw, 72px); }
.tx-sec-head { display: grid; gap: 12px; margin-bottom: 24px; }
.tx-h2 { font-family: var(--font-display); font-weight: 600; font-size: clamp(27px, 2.5vw, 36px); line-height: 1.06; letter-spacing: -0.03em; color: var(--ink); text-wrap: balance; }
.tx-sub { color: var(--ink-2); font-size: 16.5px; line-height: 1.6; max-width: 46em; }
.tx-src { font-family: var(--font-mono); font-size: 12px; line-height: 1.5; color: var(--ink-3); letter-spacing: 0; }

/* ============ 3 · Live data (area pages) ============ */
.tx-data { padding: clamp(40px, 5vw, 64px) 0 0; }
.tx-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 8px; }
.tx-stat { display: grid; gap: 10px; align-content: start; padding: 20px 22px 22px; border-radius: var(--r-lg); background: var(--sheet); box-shadow: var(--sh-2); position: relative; overflow: hidden; }
.tx-stat::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--green); }
.tx-stat-n { font-family: var(--font-display); font-weight: 600; font-size: clamp(40px, 4.4vw, 62px); line-height: .95; letter-spacing: -0.04em; color: var(--ink); font-variant-numeric: tabular-nums; }
.tx-stat-l { font-size: 15px; line-height: 1.4; color: var(--ink-2); }
.tx-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
.tx-h2.sm { font-size: clamp(23px, 2vw, 28px); margin-bottom: 14px; }
/* application types: a table whose rows carry a bar */
.tx-bars { width: 100%; border-collapse: collapse; }
.tx-bars th { padding: 0 0 8px; font-family: var(--font-mono); font-size: 11.5px; font-weight: 400; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); text-align: left; border-bottom: 1px solid var(--rule); }
.tx-bars th:last-child, .tx-bars td:last-child { text-align: right; }
.tx-bars td { padding: 11px 0 12px; border-bottom: 1px solid var(--rule); vertical-align: bottom; }
.tx-bars td:first-child { width: 100%; padding-right: 16px; }
.tx-bar-t { display: block; font-size: 15px; line-height: 1.4; color: var(--ink); overflow-wrap: anywhere; margin-bottom: 7px; }
.tx-bar-n { font-family: var(--font-mono); font-size: 13px; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.tx-bar-track { display: block; height: 6px; border-radius: 3px; background: var(--paper-3); overflow: hidden; }
.tx-bar-fill { display: block; height: 100%; width: calc(var(--w) * 1%); border-radius: 3px; background: var(--green); transform-origin: 0 50%; transition: transform 700ms var(--ease-out); transition-delay: calc(var(--i, 0) * 60ms); }
.pw-motion .tx-bars.rv-wait:not(.in) .tx-bar-fill { transform: scaleX(0); }
.tx-bars.instant .tx-bar-fill { transition: none; }
/* postcode districts */
.tx-areas { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.tx-area { display: inline-flex; align-items: baseline; gap: 8px; min-height: 40px; padding: 9px 14px; border-radius: 12px; background: var(--sheet); box-shadow: inset 0 0 0 1px var(--rule-2); }
.tx-area b { font-family: var(--font-mono); font-weight: 500; font-size: 14px; color: var(--ink); letter-spacing: .02em; }
.tx-area span { font-family: var(--font-mono); font-size: 12.5px; color: var(--green-ink); }
/* recent applications: rows like the product's table */
.tx-apps { display: grid; border-radius: var(--r-lg); background: var(--sheet); box-shadow: var(--sh-2); overflow: hidden; }
.tx-app { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 18px; padding: 16px 20px; border-top: 1px solid var(--rule); }
.tx-app:first-child { border-top: 0; }
.tx-app-d { font-size: 15.5px; line-height: 1.45; color: var(--ink); font-weight: 500; overflow-wrap: anywhere; }
.tx-app-m { grid-column: 1 / 2; font-family: var(--font-mono); font-size: 12px; line-height: 1.55; color: var(--ink-3); overflow-wrap: anywhere; }
.tx-app-m a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--green); text-underline-offset: 3px; }
.tx-app-m a:hover { color: var(--ink); }
.tx-app .chip { grid-row: 1; grid-column: 2; align-self: start; }
.tx-note { margin-top: 14px; font-size: 15px; color: var(--ink-2); }
.tx-note a, .tx-thin a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--amber); text-underline-offset: 3px; }
.tx-thin { padding: 20px 22px; border-radius: var(--r-lg); background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--rule); color: var(--ink-2); font-size: 16px; line-height: 1.6; }

/* ============ 4 · Guidance column with its drawing ============ */
.tx-guide { display: grid; grid-template-columns: minmax(0, 640px) minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); align-items: start; padding-top: clamp(48px, 6vw, 72px); }
.tx-guide .ar-article h2:not(:first-child) { margin-top: 44px; }
.tx-fig { position: sticky; top: calc(var(--nav-clear) + 28px); margin: 0; border-radius: var(--r-xl); overflow: hidden; background: var(--sheet); box-shadow: var(--sh-2); }
.tx-fig-art { aspect-ratio: 16 / 10; background: #F7F5F0; }
.tx-fig figcaption { padding: 12px 16px; font-size: 14px; line-height: 1.5; color: var(--ink-2); border-top: 1px solid var(--rule); }
.tx-fig figcaption b { display: block; font-weight: 600; color: var(--ink); }

/* FAQ outside the guides' article (area pages) */
.tx-faq { max-width: 760px; }

/* ============ 5 · Tools: RPA calculator, TPO checker ============ */
.tx-tool { margin: 44px 0 0; border-radius: var(--r-lg); background: var(--sheet); box-shadow: 0 0 0 1px var(--rule), 0 24px 50px -32px rgba(17, 18, 20, .35); overflow: hidden; scroll-margin-top: calc(var(--nav-clear) + 24px); }
.tx-tool-head { display: grid; gap: 8px; padding: 22px 24px 0; }
.ar-article .tx-tool-head h2 { margin: 0; font-size: clamp(23px, 2vw, 27px); }
.ar-article .tx-tool-head p { margin: 0; font-size: 16px; line-height: 1.55; }
.tx-tool-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; padding: 18px 24px 22px; }
.tx-tool-form .field { flex: 1 1 180px; max-width: 240px; }
.tx-tool-form .field span { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.tx-tool-form .input { height: 48px; font-size: 17px; }
.tx-tool-form .input:focus { border-color: var(--ink); }
.tx-tool-form .btn { height: 48px; }
.tx-rpa { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); border-top: 1px solid var(--rule); }
.tx-rpa-fig { position: relative; background: #F7F5F0; border-right: 1px solid var(--rule); min-height: 220px; }
.tx-rpa-fig svg { width: 100%; height: 100%; display: block; }
.tx-rpa-out { display: grid; gap: 14px; align-content: start; padding: 20px 24px 22px; }
.tx-rpa-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tx-rpa-num { padding: 14px 16px; border-radius: 14px; background: var(--paper-2); }
.tx-rpa-num b { display: block; white-space: nowrap; font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 2.1vw, 30px); line-height: 1; letter-spacing: -0.03em; color: var(--ink); font-variant-numeric: tabular-nums; }
.tx-rpa-num span { display: block; margin-top: 6px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); letter-spacing: .02em; }
.ar-article .tx-rpa-note { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
.rpa-ring { transform-box: fill-box; transform-origin: 50% 50%; transition: transform 520ms var(--ease-out); }
.rpa-svg .r-bg { fill: #F7F5F0; } .rpa-svg .r-grid { fill: none; stroke: rgba(17, 18, 20, .05); }
.rpa-svg .r-cap { fill: none; stroke: #B8B5AE; stroke-width: 1.2; stroke-dasharray: 3 4; }
.rpa-svg .r-rpa { fill: rgba(22, 163, 74, .09); stroke: #16A34A; stroke-width: 1.8; stroke-dasharray: 7 5; }
.rpa-svg .r-can { fill: #D8EEDC; stroke: #8FCB9E; stroke-width: 1.4; }
.rpa-svg .r-stem { fill: #8E6B4E; }
.rpa-svg .r-dim { stroke: #2E62F0; stroke-width: 1.3; fill: none; }
.rpa-svg text { font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; fill: #6B6F77; }
.rpa-svg .r-dimt { fill: #1F47B8; }
.rpa-svg .r-capt { fill: #8C9098; }
.tx-tpo-out { padding: 0 24px 22px; }
.tx-tpo-out:empty { display: none; }
.tx-tpo-res { display: grid; gap: 10px; padding: 18px 20px; border-radius: 14px; background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--rule); }
.ar-article .tx-tpo-res p { margin: 0; font-size: 16px; }
.ar-article .tx-tpo-res ul { margin: 0; padding-left: 1.2em; }
.ar-article .tx-tpo-res li { font-size: 16px; }
.ar-article .tx-tpo-res .tx-src { font-size: 12px; }
.ar-article .tx-tpo-msg { margin: 0; font-size: 15px; color: var(--ink-3); }
.ar-article .tx-tpo-msg.err { color: var(--amber-ink); font-weight: 500; }

/* ============ 6 · The surveyor call to action ============ */
.tx-cta { display: grid; grid-template-columns: 176px minmax(0, 1fr); gap: 22px; align-items: center; margin: 56px 0 0; padding: 18px; border-radius: var(--r-lg); background: var(--green-wash);
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, .28); }
.tx-cta-art { border-radius: 12px; overflow: hidden; aspect-ratio: 16 / 10; box-shadow: 0 0 0 1px rgba(17, 18, 20, .06); }
.ar-article .tx-cta h3, .tx-cta h3 { margin: 0 0 6px; font-family: var(--font-display); font-weight: 600; font-size: 21px; line-height: 1.2; letter-spacing: -0.02em; color: var(--ink); }
.ar-article .tx-cta p, .tx-cta p { margin: 0 0 14px; font-size: 16px; line-height: 1.55; color: var(--ink-2); }
.tx-cta .btn { color: var(--paper); }

/* ============ 7 · Hub and guides index ============ */
.tx-hero { padding: calc(var(--nav-clear) + clamp(24px, 3.5vw, 52px)) 0 clamp(48px, 6vw, 84px); background-color: var(--paper-2); border-bottom: 1px solid var(--rule); }
.tx-hero-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 560px); gap: clamp(32px, 5vw, 72px); align-items: center; }
.tx-hero-copy { display: grid; gap: 22px; justify-items: start; min-width: 0; }
.tx-h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(40px, 5.2vw, 76px); line-height: .98; letter-spacing: -0.045em; color: var(--ink); text-wrap: balance; max-width: 12em; }
.tx-hero .lead { max-width: 34em; }
.tx-hero-art { margin: 0; border-radius: var(--r-xl); overflow: hidden; background: var(--sheet); box-shadow: var(--sh-3); }
.tx-hero-art .ar-hero-svg { aspect-ratio: 16 / 10; }
.tx-hero-art figcaption { display: flex; justify-content: space-between; gap: 12px; padding: 10px 16px; font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); border-top: 1px solid var(--rule); }
.tx-proof { display: flex; flex-wrap: wrap; gap: 14px 36px; margin-top: 6px; padding-top: 20px; border-top: 1px solid var(--rule); }
.tx-proof div { display: grid; gap: 6px; }
.tx-proof dt { font: 500 11px/1.3 var(--font-mono); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); }
.tx-proof dd { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: 34px; line-height: 1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.tx-crumb { margin-bottom: clamp(18px, 2.6vw, 30px); }
.tx-grid-sec { padding-top: clamp(56px, 7vw, 96px); }
.tx-grid-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 22px; }
.tx-grid-head h2 span { font-family: var(--font-mono); font-size: 13px; font-weight: 400; letter-spacing: 0; color: var(--ink-3); vertical-align: 5px; margin-left: 6px; }
.gx-card-art.tx-art { aspect-ratio: 16 / 10; overflow: hidden; background: #F7F5F0; }
.gx-card .gx-meta b.g { color: var(--green-ink); }
/* areas */
.tx-top { display: flex; flex-wrap: wrap; gap: 8px; }
.tx-top a { display: inline-flex; align-items: baseline; gap: 9px; min-height: 42px; padding: 10px 15px; border-radius: 12px; background: var(--sheet); box-shadow: inset 0 0 0 1px var(--rule-2); font-weight: 500; font-size: 15px; color: var(--ink);
  transition: box-shadow var(--dur-instant), transform var(--dur-instant) var(--ease-out); }
.tx-top a span { font-family: var(--font-mono); font-size: 12px; font-weight: 400; color: var(--green-ink); }
.tx-top a:hover { box-shadow: inset 0 0 0 1px var(--ink-4); transform: translateY(-1px); }
.tx-az { margin-top: 18px; border-radius: var(--r-lg); background: var(--paper-2); box-shadow: inset 0 0 0 1px var(--rule); }
.tx-az summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 20px; font-weight: 600; color: var(--ink); }
.tx-az summary::-webkit-details-marker { display: none; }
.tx-az summary span { font-family: var(--font-mono); font-size: 12px; font-weight: 400; color: var(--ink-3); }
.tx-az-list { columns: 4 180px; column-gap: 28px; padding: 4px 20px 20px; }
.tx-az-list a { display: block; padding: 4px 0; font-size: 14.5px; color: var(--ink-2); break-inside: avoid; }
.tx-az-list a:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--amber); text-underline-offset: 3px; }
/* the hub's guide as an article with its contents rail */
.tx-hub-body { border-top: 1px solid var(--rule); margin-top: clamp(56px, 7vw, 96px); }

/* related guides at the foot of a page */
.tx-related { padding-bottom: clamp(56px, 7vw, 96px); border-top: 1px solid var(--rule); }

/* ============ 8 · Responsive ============ */
@media (max-width: 1100px) { .tx-guide { grid-template-columns: minmax(0, 1fr); } .tx-fig { position: static; max-width: 620px; } }
@media (max-width: 1000px) {
  .tx-hero-in { grid-template-columns: 1fr; }
  .tx-hero-art { max-width: 620px; width: 100%; }
  .tx-split { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .tx-stats { grid-template-columns: 1fr; gap: 10px; }
  .tx-stat { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 14px; padding: 16px 18px; }
  .tx-stat-n { font-size: 40px; }
  .tx-rpa { grid-template-columns: 1fr; }
  .tx-rpa-fig { border-right: 0; border-bottom: 1px solid var(--rule); min-height: 0; aspect-ratio: 16 / 10; }
}
@media (max-width: 640px) {
  .tx-cta { grid-template-columns: 1fr; padding: 18px; }
  .tx-cta-art { display: none; }
  .tx-app { grid-template-columns: 1fr; padding: 14px 16px; }
  .tx-app .chip { grid-row: auto; grid-column: 1; justify-self: start; }
  .tx-grid-head { flex-direction: column; align-items: start; }
  .tx-proof dd { font-size: 28px; }
  .tx-tool-head { padding: 18px 18px 0; }
  .tx-tool-form { padding: 16px 18px 18px; }
  .tx-tool-form .field { max-width: none; }
  .tx-rpa-out { padding: 16px 18px 18px; }
  .tx-tpo-out { padding: 0 18px 18px; }
  .tx-az-list { columns: 2 140px; }
  .gx-card-art.tx-art { aspect-ratio: auto; }
}
@media (prefers-reduced-motion: reduce) { .tx-bar-fill, .rpa-ring, .tx-top a { transition: none; } }
.page-tree main :is(a, button, summary, select, input):focus-visible { outline: 2px solid var(--amber-deep); outline-offset: 2px; }
.tdraw .t-leader { stroke: #8C9098; stroke-width: 1; }
.tdraw .t-leader.a { stroke: #D97706; }
.tdraw .t-leader.g { stroke: #15803D; }
