/* Rental Host Workbook & Turnover Kit: the rental after dark. Studio kit version 2 (dark) with this site's own palette:
   indigo night, fresh linen and porch-light apricot. Palette checked with ventures/_studio/tools/check-accent.mjs (all PASS).
   Shared by index.html and the two calculator pages; the kit's own rules live in /studio/studio.css. */
:root {
  --ss-bg: #171a36;          /* night sky over the street: the page */
  --ss-surface: #22264a;     /* indoor shadow: cards, calculator, buy box, footer, inputs */
  --ss-ink: #f1eee8;         /* fresh linen: body text */
  --ss-muted: #c2c0d8;       /* moonlit gray-lilac: hints, secondary text */
  --ss-line: #3b3f6b;        /* hairlines (decorative only) */
  --ss-accent: #ffa978;      /* porch light: buttons, header stripe, focus ring, lit windows */
  --ss-accent-ink: #171a36;  /* text on the accent */
  --ss-accent-text-dark: #ffc4a0; /* links and accent text */
  /* site-only tokens */
  --rk-wall: #2c3160;        /* facade wall (decorative) */
  --rk-window: #1d2042;      /* unlit window (decorative) */
  --rk-deep: #5b61a8;        /* fourth layer of the linen stack (decorative) */
  --rk-field: #8e92c4;       /* input borders: 3:1 or more on the page and on cards */
  --rk-err: #ffb3a7;         /* error text on --rk-err-bg: 8.5:1 */
  --rk-err-bg: #3a1f38;
}
body.ss [hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 1rem; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body.ss h2 { margin-bottom: .4em; }
body.ss li { margin-bottom: .4rem; }
body.ss li::marker { color: var(--ss-accent); }
.rk-intro { color: var(--ss-muted); max-width: 40em; margin: 0 0 1.25rem; }
.rk-fine { color: var(--ss-muted); font-size: .875rem; max-width: 46em; }
.rk-fine strong { color: var(--ss-ink); }

/* ---------- the way to the workbook: a pill first in every header, and "#buy" lands on the price, not just the button ---------- */
.ss-nav a.rk-get { background: var(--ss-accent); color: var(--ss-accent-ink); font-weight: 700; line-height: 1.4; padding: .5rem 1rem; border-radius: 999px; border-bottom: 0; }
.ss-nav a.rk-get:hover { border-bottom: 0; filter: brightness(1.08); }
.rk-get .rk-sm { display: none; }
@media (max-width: 40rem) { .ss-nav { column-gap: .75rem; } .ss-nav a.rk-get { padding-inline: .85rem; } }
/* On phones the pill is a full 44px target; it lives on the header's existing row, so no row is added. */
@media (max-width: 43.75rem) { .ss-nav a.rk-get { display: inline-flex; align-items: center; box-sizing: border-box; min-height: 44px; } }
@media (max-width: 23.75rem) { .rk-get .rk-lg { display: none; } .rk-get .rk-sm { display: inline; } }
#buy { scroll-margin-top: 9.5rem; }

/* ---------- sections: space, and one hairline ---------- */
.rk-sec { padding-block: 2.25rem; border-top: 1px solid var(--ss-line); }
/* More free calculators: two cards after the break-even calculator */
.more-calcs { margin-top: 2.5rem; }
.more-calcs h3 { margin-bottom: .75rem; font-size: 1.5rem; }
.more-calcs ul { list-style: none; margin: 0; padding: 0; }
.more-calcs .ss-grid { grid-template-columns: 1fr; }
.more-calcs .ss-card p { margin: 0; color: var(--ss-muted); }
.more-calcs .ss-card p:first-child { margin-bottom: .4rem; }
.more-calcs .ss-card a { font-weight: 700; font-size: 1.1rem; }
@media (min-width: 40rem) { .more-calcs .ss-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rk-sec:first-child { border-top: 0; }
@media (min-width: 56rem) { .rk-sec { padding-block: 3.25rem; } }

/* ---------- the facade: one window per night ---------- */
.rk-wall { fill: var(--rk-wall); }
.rk-street { fill: var(--ss-line); }
.rk-moon { fill: var(--ss-ink); }
.rk-w { fill: var(--rk-window); }
.rk-w.on { fill: var(--ss-accent); }
.rk-k { fill: var(--ss-bg); opacity: 0; }
.rk-k.on { opacity: 1; }
.rk-anim .rk-w, .rk-anim .rk-k { transition: fill .18s ease-out, opacity .18s ease-out; }
@media (prefers-reduced-motion: reduce) { .rk-anim .rk-w, .rk-anim .rk-k { transition: none; } }
.rk-facade { display: block; width: 100%; height: auto; }
.rk-legend { color: var(--ss-muted); font-size: .875rem; line-height: 1.45; margin: 0; }

/* ---------- home: first screen ---------- */
.rk-hero { padding-block: 1.25rem 1.75rem; }
.rk-hero__grid { display: grid; gap: 1rem; }
.rk-copy, .rk-side { display: contents; }
.rk-hero h1 { order: 1; margin: 0 0 .4rem; font-size: clamp(2.4rem, 1.7rem + 3.2vw, 3.6rem); }
.rk-for { order: 2; margin: 0 0 .5rem; color: var(--ss-muted); }
.rk-lead { order: 3; margin: 0; font-size: clamp(1.1rem, 3.2vw, 1.3rem); line-height: 1.5; max-width: 32em; }
.rk-strip { order: 4; display: block; width: min(100%, 300px); height: auto; }
.rk-art { display: none; margin: 0; }
.rk-striplegend { order: 4; margin-top: -.5rem; }
.rk-hero .ss-buy { order: 5; align-self: start; }
.rk-hero-link { order: 6; margin: 0; font-weight: 600; }
.rk-byline { order: 7; color: var(--ss-muted); font-size: .95rem; max-width: 34em; margin: 0; }
.ss-buy__price { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.ss-buy__price small { margin-left: 0; font-size: 1rem; }
.ss-buy .rk-what { color: var(--ss-muted); margin: 0 0 1rem; }
.ss-buy .ss-btn { display: flex; width: 100%; }
.ss-buy__fine { text-align: left; }
@media (min-width: 56rem) {
  .rk-hero { padding-block: 2rem 2.5rem; }
  .rk-hero__grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 2.5rem; align-items: start; }
  .rk-copy, .rk-side { display: block; }
  .rk-hero .ss-buy, .rk-hero .rk-strip { order: 0; }
  .rk-strip, .rk-striplegend { display: none; }
  .rk-hero h1 { margin-bottom: .6rem; }
  .rk-lead { margin-bottom: 1rem; }
  .rk-byline { margin-bottom: 1rem; }
  .rk-art { display: flex; align-items: center; gap: 1.25rem; margin-bottom: 1.25rem; }
  .rk-art svg { flex: none; width: auto; height: 15.5rem; }
  .rk-hero .ss-buy { margin: 0; }
}

/* ---------- home: what's inside (a sheet of tabs over one panel) ---------- */
.rk-sheet { margin: 0 0 2rem; }
.rk-tabs { display: flex; flex-wrap: wrap; gap: 4px; }
.rk-tab { padding: .45rem .9rem; border-radius: var(--ss-radius) var(--ss-radius) 0 0; background: var(--ss-surface); color: var(--ss-muted); font-size: .9rem; font-weight: 600; line-height: 1.2; border: 1px solid var(--ss-line); border-bottom: 0; }
.rk-tab.on { background: var(--ss-accent); border-color: var(--ss-accent); color: var(--ss-accent-ink); }
.rk-tabs[role="tablist"] .rk-tab { cursor: pointer; }
.rk-tabs[role="tablist"] .rk-tab:not(.on):hover { color: var(--ss-ink); }
.rk-sheetbody { background: var(--ss-surface); border: 1px solid var(--ss-line); border-radius: 0 var(--ss-radius-lg) var(--ss-radius-lg) var(--ss-radius-lg); padding: 1.25rem; }
.rk-tabpanel { display: grid; gap: 1rem; }
.rk-tabpanel:not([role="tabpanel"]) + .rk-tabpanel { margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--ss-line); }
.rk-tabpanel h3 { margin-bottom: .25rem; font-size: 1.5rem; }
.rk-tabpanel p { margin: 0; color: var(--ss-muted); font-size: 1.1rem; line-height: 1.5; max-width: 30em; }
.rk-ill { display: none; }
.rk-ill--chart { display: block; }
.rk-bars { display: block; width: 100%; max-width: 20rem; height: auto; }
.rk-bar-a { fill: var(--ss-accent); }
.rk-bar-b { fill: var(--ss-muted); }
.rk-base { fill: var(--ss-line); }
/* a few rows of the real sheets (made-up sample data), drawn as small tables */
.rk-mini { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .8rem; line-height: 1.3; font-variant-numeric: tabular-nums; background: var(--ss-bg); border: 1px solid var(--ss-line); border-radius: var(--ss-radius); overflow: hidden; }
.rk-mini th, .rk-mini td { overflow-wrap: normal; word-break: normal; hyphens: manual; }
.rk-mini th { text-align: left; font-weight: 600; color: var(--ss-muted); background: var(--rk-wall); padding: .45rem .6rem; vertical-align: bottom; }
.rk-mini td { padding: .45rem .6rem; border-top: 1px solid var(--ss-line); color: var(--ss-ink); }
.rk-mini .n { text-align: right; }
.rk-mini .nw { white-space: nowrap; }
.rk-mini .c { background: var(--rk-window); }
.rk-mini .rk-empty td { height: 2rem; }
.rk-skel { display: block; height: .55rem; width: var(--w, 80%); border-radius: 3px; background: var(--ss-line); }
.rk-sheet figcaption { color: var(--ss-muted); font-size: .8rem; margin-top: .5rem; }
@media (min-width: 56rem) {
  .rk-sheetbody { padding: 1.75rem; min-height: 15rem; }
  .rk-tabpanel { grid-template-columns: minmax(0, .8fr) minmax(0, 2fr); gap: 2rem; align-items: start; }
  .rk-ill { display: table; }
  .rk-ill--chart { display: block; justify-self: end; align-self: end; width: 100%; max-width: 26rem; }
  .rk-ill--chart .rk-bars { max-width: none; }
}
.rk-download { display: grid; gap: 1.75rem; }
.rk-dl-item { display: flex; gap: 1rem; align-items: flex-start; }
.rk-dl-item + .rk-dl-item { margin-top: 1.25rem; }
.rk-dl-item h3 { margin-bottom: .25rem; }
.rk-dl-item p { margin: 0; color: var(--ss-muted); max-width: 34em; }
.rk-spot { flex: none; width: 3.5rem; height: auto; }
.rk-spot .l-a { fill: var(--ss-ink); }
.rk-spot .l-b { fill: var(--ss-muted); }
.rk-fold { stroke: var(--ss-bg); stroke-width: 2; stroke-linecap: round; fill: none; }
.rk-edge { stroke: var(--ss-bg); stroke-width: 2; }
.rk-spot .rk-keyfill { fill: var(--ss-accent); }
#kit h3 { margin-bottom: .5rem; }
#kit li { color: var(--ss-ink); }
@media (min-width: 56rem) { .rk-download { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 3rem; align-items: start; } }

/* ---------- home: who it is for ---------- */
.rk-split { display: grid; gap: 1.75rem; }
.rk-who { display: flex; gap: 1rem; align-items: flex-start; }
.rk-who h3 { margin-bottom: .5rem; }
.rk-who ul { margin: 0; padding-left: 1.25rem; }
.rk-who .rk-spot { width: 2.75rem; margin-top: .15rem; }
.rk-not { padding-left: calc(2.75rem + 1rem); }
.rk-not ul { margin: 0; padding-left: 1.25rem; }
@media (max-width: 55.99rem) { .rk-not { padding-left: 0; } }
@media (min-width: 56rem) { .rk-split { grid-template-columns: 1fr 1fr; gap: 3rem; } }

/* ---------- home: questions, who made this ---------- */
.rk-qa { display: grid; gap: 2rem; }
.rk-faq details { border-top: 1px solid var(--ss-line); }
.rk-faq details:last-child { border-bottom: 1px solid var(--ss-line); }
.rk-faq summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 48px; padding-block: .1rem; cursor: pointer; list-style: none; }
.rk-faq summary::-webkit-details-marker { display: none; }
.rk-faq summary h3 { margin: 0; font-size: 1.25rem; }
.rk-faq summary::after { content: ""; flex: none; width: .55rem; height: .55rem; margin-right: .25rem; border-right: 2px solid var(--ss-accent); border-bottom: 2px solid var(--ss-accent); transform: rotate(45deg); transition: transform .15s ease-out; }
.rk-faq details[open] summary::after { transform: rotate(-135deg); }
@media (prefers-reduced-motion: reduce) { .rk-faq summary::after { transition: none; } }
.rk-faq details > p { margin: 0 0 1rem; color: var(--ss-muted); max-width: 40em; }
.rk-faq details > p strong { color: var(--ss-ink); }
.rk-about p { max-width: 36em; }
@media (min-width: 56rem) { .rk-qa { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 3.5rem; align-items: start; } }

/* ---------- calculators (home and the two inner pages) ---------- */
.calc { --calc-pad: 1.1rem; background: var(--ss-surface); border: 1px solid var(--ss-line); border-radius: var(--ss-radius-lg); padding: var(--calc-pad); display: grid; gap: 1.4rem; }
.fields { display: grid; gap: .9rem; align-content: start; grid-template-columns: minmax(0, 1fr); margin: 0; padding: 0; border: 0; min-width: 0; }
.field label { display: block; margin-bottom: .25rem; }
.field input { width: 100%; background: var(--ss-bg); border: 1.5px solid var(--rk-field); }
.field input[aria-invalid="true"] { border-color: var(--rk-err); background: var(--rk-err-bg); }
.hint { display: block; color: var(--ss-muted); font-size: .85rem; line-height: 1.4; margin-top: .25rem; }
.field-error { display: block; color: var(--rk-err); font-size: .88rem; font-weight: 600; margin-top: .25rem; }
.field-error:empty { display: none; }
.legend { color: var(--ss-muted); font-size: .9rem; margin-bottom: .6rem; padding: 0; }
.results h3 { margin-bottom: .6rem; }
.rk-result { display: grid; gap: 1rem; }
.rk-result .rk-pic { display: flex; flex-direction: column; gap: .5rem; }
.tiles { display: grid; gap: .6rem; }
.tile { background: var(--ss-bg); border: 1px solid var(--ss-line); border-radius: var(--ss-radius-lg); padding: .8rem 1rem; }
.tile .k { display: block; font-size: .9rem; color: var(--ss-muted); }
.tile .v { display: block; font-family: var(--ss-display); font-weight: 700; font-size: 2.2rem; line-height: 1.05; letter-spacing: .01em; font-variant-numeric: tabular-nums; color: var(--ss-ink); overflow-wrap: anywhere; }
.tile .u { font-size: .85rem; color: var(--ss-muted); }
.breakdown { margin: 1rem 0 0; display: grid; grid-template-columns: 1fr auto; gap: .25rem .75rem; font-size: .95rem; }
.breakdown dt { color: var(--ss-muted); }
.breakdown dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
.friendly { background: var(--rk-err-bg); color: var(--rk-err); border-radius: var(--ss-radius-lg); padding: .75rem .9rem; font-weight: 600; margin: 0; }
.formula { border-top: 1px solid var(--ss-line); padding-top: 1.1rem; grid-column: 1 / -1; }
.formula h3 { font-family: var(--ss-font); font-size: 1rem; font-weight: 700; margin-bottom: .5rem; }
.formula ol { padding-left: 1.25rem; font-size: .95rem; }
.formula p { max-width: 46em; }
.estimate { font-size: .9rem; color: var(--ss-muted); margin: .75rem 0 0; }
.estimate strong { color: var(--ss-ink); }
.rates-note { display: none; }
@media (min-width: 40rem) {
  .calc { --calc-pad: 1.5rem; padding: 1.5rem; }
  .fields { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 56.25rem) {
  .calc { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 2rem; }
  .tile .v { font-size: 3rem; }
  .rk-result { grid-template-columns: minmax(0, 11rem) minmax(0, 1fr); align-items: center; gap: 1.25rem; }
  .rk-result.rk-stacked { grid-template-columns: minmax(0, 12.5rem) minmax(0, 1fr); gap: 1.5rem; }
  .rk-stacked .rk-pic { justify-content: center; align-self: stretch; }
  .results .breakdown { margin-top: 1.25rem; }
  /* three tiles: the picture sits above them, with its legend beside it */
  .calc--wide .rk-result { grid-template-columns: minmax(0, 1fr); align-items: start; }
  .calc--wide .rk-pic { flex-direction: row; align-items: center; gap: 1rem; }
  .calc--wide .rk-pic .rk-facade { width: 12rem; flex: none; }
  .calc--wide .tile .v { font-size: 2.6rem; }
}
/* Keep side-by-side inputs level when a label wraps to two lines. */
@media (min-width: 40rem) {
  @supports (grid-template-rows: subgrid) {
    .calc--home .fields { row-gap: 0; }
    .calc--home .fields .field { display: grid; grid-template-rows: subgrid; grid-row: span 4; margin-bottom: .9rem; }
  }
}
/* Inner pages: one column of inputs beside the results from 900px, as before. */
.calc--inner .fields { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 40rem) and (max-width: 56.2rem) { .calc--inner .fields { grid-template-columns: 1fr 1fr; } }

/* Results on phones and small tablets: the result bar moves above the inputs and sticks to the top of the card while you
   type, so the numbers are always in view; the picture shrinks to a small strip beside them. 900px and up is unchanged. */
@media (max-width: 56.2rem) {
  .calc { display: flex; flex-direction: column; gap: 1.1rem; }
  .results h3 { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .calc--inner .results, .calc--home #results { order: -1; position: sticky; top: 0; z-index: 3; margin: 0 calc(var(--calc-pad) * -1); padding: .5rem var(--calc-pad) .6rem; background: var(--ss-surface); border-bottom: 1px solid var(--ss-line); }
  .calc--home .results { display: contents; }
  .rk-result { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: .6rem; }
  .rk-result .rk-pic .rk-legend, .rk-result .rk-pic .rk-pic__text { display: none; }
  .rk-result .rk-facade { width: auto; height: 3.4rem; }
  .tiles { grid-template-columns: 1fr 1fr; gap: .5rem; }
  .calc--wide .tiles { grid-template-columns: .9fr 1.1fr 1.35fr; }
  .tile { display: flex; flex-direction: column; justify-content: space-between; gap: .15rem; padding: .45rem .6rem; }
  .tile .k { font-size: .74rem; line-height: 1.25; }
  .tile .v { font-size: clamp(1.4rem, 6.6vw, 1.9rem); }
  .tile .u { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .friendly { padding: .5rem .75rem; font-size: .9rem; line-height: 1.35; }
  .rates-note { display: block; order: 1; margin: 0 0 -.4rem; color: var(--ss-muted); font-size: .88rem; }
  .breakdown { order: 1; margin: 0; }
  .formula { order: 2; }
  .field input { scroll-margin-top: 9rem; }
  .results:has(#calc-output[hidden]) ~ .rates-note, .results:has(#calc-output[hidden]) ~ .breakdown { display: none; }
  .calc--home #results:has(#calc-output[hidden]) ~ .rates-note, .calc--home #results:has(#calc-output[hidden]) ~ .breakdown { display: none; }
}
@media (max-width: 56.2rem) {
  .calc--wide .results, .calc--wide #results, .calc--wide #calc-output, .calc--wide .rk-result { display: contents; }
  .calc--wide .results { position: static; margin: 0; padding: 0; border: 0; }
  .calc--wide .tiles, .calc--wide #calc-message { order: -2; position: sticky; top: 0; z-index: 3; margin: 0 calc(var(--calc-pad) * -1); padding: .5rem var(--calc-pad) .6rem; background: var(--ss-surface); border-bottom: 1px solid var(--ss-line); border-radius: 0; }
  .calc--wide .tiles { gap: .4rem; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) minmax(0, 1.2fr); }
  .calc--wide .tile { padding: .4rem .5rem; }
  .calc--wide .tile .v { font-size: clamp(1.1rem, 5vw, 1.4rem); }
  .calc--wide .tile .k { font-size: .7rem; }
  .calc--wide .rk-pic { order: -1; flex-direction: row; align-items: center; gap: 1rem; }
  .calc--wide .rk-result .rk-facade { height: 6.5rem; width: auto; flex: none; }
  .calc--wide .rk-result .rk-pic .rk-pic__text { display: block; }
}
@media (min-width: 56.25rem) { .results:has(#calc-output[hidden]) .breakdown { display: none; } }

/* ---------- inner pages ---------- */
.rk-page-head { padding-block: .5rem 1rem; }
.rk-page-head h1 { margin-bottom: .4rem; }
.rk-page-head .rk-for { margin: 0 0 .5rem; }
.rk-page-head .rk-lead { margin-bottom: .75rem; max-width: 36em; }
.rk-page-head .rk-intro { margin: 0; }
.rk-calc-sec { padding-block: 1rem 1.5rem; }
.rk-calc-sec h2 { font-size: 1.5rem; margin-bottom: .75rem; }
/* The band under a free tool: what the paid file adds, the price, the refund line and one button. It sits below the
   calculator card (after "How it is worked out"), never inside it, so it reads as a separate offer and the sticky results,
   which are bounded by the card's grid, can never slide over it. */
.rk-cta { margin-top: 1.25rem; display: grid; gap: .9rem; padding: 1rem 1.1rem; background: var(--ss-bg); border: 2px solid var(--ss-accent); border-radius: var(--ss-radius-lg); }
.rk-cta h3 { font-size: 1.4rem; margin-bottom: .3rem; }
.rk-cta p { color: var(--ss-muted); max-width: 40em; margin: 0 0 .5rem; }
.rk-cta .rk-cta__price { color: var(--ss-ink); }
.rk-cta .rk-cta__price strong { font-family: var(--ss-display); font-size: 1.7rem; line-height: 1; letter-spacing: .01em; }
.rk-cta .rk-cta__fine { font-size: .85rem; line-height: 1.5; margin: 0; }
.rk-cta .ss-btn { width: 100%; text-align: center; }
@media (min-width: 40rem) {
  .rk-cta { grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 1.5rem; padding: 1.1rem 1.4rem; }
  .rk-cta .ss-btn { width: auto; max-width: 15rem; }
}
.rk-also { margin: 1.25rem 0 1.5rem; color: var(--ss-muted); font-size: .95rem; max-width: 46em; }
.rk-stack { display: block; width: 100%; height: auto; }
.rk-stack .l-a { fill: var(--ss-ink); }
.rk-stack .l-b { fill: var(--ss-muted); }
@media (max-width: 56.2rem) { .rk-result .rk-stack { width: auto; height: 3.4rem; } }
.rk-pic__text .rk-legend { margin-bottom: .25rem; }
.rk-limit { font-size: .8rem; color: var(--ss-muted); margin: 0; }
.rk-limit:empty { display: none; }

/* ---------- the cleaning fee build-up page: a turnover as a stack of linen ---------- */
.field select { width: 100%; background: var(--ss-bg); border: 1.5px solid var(--rk-field); }
.field .hint a { font-weight: 600; }
.rk-inputs { display: grid; gap: 1.4rem; min-width: 0; align-content: start; }
.rk-builder .fields .field--full { grid-column: 1 / -1; }
.rk-partstack .p-a { fill: var(--ss-accent); }
.rk-partstack .p-b { fill: var(--ss-ink); }
.rk-partstack .p-c { fill: var(--rk-field); }
.rk-partstack .p-d { fill: var(--rk-deep); }
.rk-parts { list-style: none; margin: 0 0 .6rem; padding: 0; display: grid; gap: .3rem; font-size: .95rem; }
.rk-parts li { display: grid; grid-template-columns: .85rem minmax(0, 1fr) auto; align-items: center; gap: .5rem; margin: 0; }
.rk-parts .sw { width: .85rem; height: .85rem; border-radius: 3px; }
.rk-parts .sw.p-a { background: var(--ss-accent); }
.rk-parts .sw.p-b { background: var(--ss-ink); }
.rk-parts .sw.p-c { background: var(--rk-field); }
.rk-parts .sw.p-d { background: var(--rk-deep); border: 1px solid var(--rk-field); }
.rk-parts .nm { color: var(--ss-muted); }
.rk-parts .am { font-weight: 600; font-variant-numeric: tabular-nums; }
.rk-night { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: .5rem; margin: 0 0 .6rem; padding-top: .45rem; border-top: 1px solid var(--ss-line); font-size: .95rem; }
.rk-night[hidden] { display: none; }
.rk-night span { color: var(--ss-muted); }
.rk-night strong { font-variant-numeric: tabular-nums; white-space: nowrap; }
.rk-says { display: none; margin: 0; color: var(--ss-muted); font-size: .95rem; line-height: 1.5; }
@media (min-width: 56.25rem) {
  .rk-builder .results { position: sticky; top: 1rem; align-self: start; }
  /* The sticky results ride down the right column only: "How it is worked out" sits under the inputs, so the results
     never slide over it (owner, 2026-11-20). A sticky box is bounded by the whole grid, not by its row, so nothing full
     width may sit inside the card below it; the workbook band is outside the form, after the card. */
  .rk-builder .rk-inputs { grid-column: 1; grid-row: 1; }
  .rk-builder .formula { grid-column: 1; grid-row: 2; }
  .rk-builder .results { grid-column: 2; grid-row: 1 / span 2; }
  .rk-says { display: block; }
  .calc--wide.rk-builder .rk-pic .rk-facade { width: 8.5rem; }
}
.rk-guide { max-width: 42rem; margin-inline: 0; }
.rk-guide h2 { margin-top: 2rem; }
.rk-guide h2:first-child { margin-top: 0; }
.rk-count, .rk-steps { padding-left: 1.25rem; }
.rk-count li, .rk-steps li { margin-bottom: .75rem; }
.rk-count strong { color: var(--ss-ink); }
.rk-steps li::marker { color: var(--ss-accent); font-weight: 700; }

/* ---------- print: always light, no pictures ---------- */
@media print {
  :root { --ss-bg: #fff; --ss-surface: #fff; --ss-ink: #000; --ss-muted: #333; --ss-line: #999; --ss-link: #000;
    --ss-accent: #000; --ss-accent-ink: #fff; --ss-accent-text-dark: #000; --rk-field: #666; --rk-err: #7a1b12; --rk-err-bg: #fff; }
  html { scroll-behavior: auto; }
  .rk-art, .rk-strip, .rk-striplegend, .rk-facade, .rk-stack, .rk-spot, .rk-bars, .rk-ill, .rk-tabs, .rk-pic, .rk-sheet figcaption, .rk-cta { display: none !important; }
  .results, #results { position: static !important; margin: 0 !important; padding: 0 !important; border: 0 !important; }
  .tile { border: 1px solid #999; }
  .rk-faq details > * { display: block; }
  .rk-faq summary::after { display: none; }
  .calc { border: 1px solid #999; padding: .75rem; }
  .field input { background: #fff; border-color: #666; }
}
