/* Shared styling for the content pages — /chore-list, /weekly-cleaning-schedule,
   /printable-chore-chart, /chores-for-teenagers.

   Extracted when the second page arrived: four copies of the same inline
   stylesheet is four places for the brand to drift, and the fourth copy is
   where somebody quietly changes a green. `legal.css` is the precedent — the
   legal pages share one file for the same reason.

   ⚠️ An EXTERNAL stylesheet is safe here and an inline one is what needed
   justifying: the repo-root CSP allows `style-src 'self' 'unsafe-inline'`, so
   both work, and 'self' is the stricter of the two. Do not add a <style> block
   to a content page without a reason the CSP comment can point at.

   PRINT IS A FEATURE. A large share of the searches these pages answer want
   something to put on the fridge. The print rules at the foot are load-bearing;
   check them if you restructure a page. */

:root {
  --green: #12805a;
  --green2: #0c5f43;
  --ink: #10231b;
  --muted: #4a6459;
  --paper: #f6faf8;
  --line: #dfeae4;
  --mint: #eafff4;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: var(--font); color: var(--ink); background: var(--paper);
  line-height: 1.65; -webkit-font-smoothing: antialiased;
}
a { color: var(--green2); }
.wrap { width: min(820px, 92vw); margin: 0 auto; }

.topbar {
  background: var(--green); color: var(--mint);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.9rem clamp(1rem, 4vw, 2rem);
}
.brand { font-weight: 800; font-size: 1.15rem; display: inline-flex; align-items: center; gap: 0.5rem; }
.brand img { width: 1.5em; height: 1.5em; display: block; }
/* The darkened wash the app uses: a white overlay on this green put the mint
   text at 3.55:1, under AA. This sits at 8.4:1. */
.topbar a { color: var(--mint); text-decoration: underline; font-size: 0.9rem; }

.hero { padding: clamp(2.2rem, 7vw, 3.6rem) 0 1rem; }
h1 {
  font-size: clamp(1.9rem, 6vw, 2.7rem); line-height: 1.15;
  letter-spacing: -0.02em; color: var(--green2); margin-bottom: 0.9rem;
}
.lede { font-size: clamp(1.05rem, 2.6vw, 1.18rem); max-width: 36em; }
.lede + .lede { margin-top: 0.9rem; }

h2 {
  font-size: clamp(1.3rem, 3.4vw, 1.6rem); color: var(--green2);
  letter-spacing: -0.01em; margin: 2.4rem 0 0.5rem;
}
h3 { font-size: 1.02rem; color: var(--ink); margin: 1.1rem 0 0.3rem; }
p + p { margin-top: 0.7rem; }

.toc {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 1rem 1.2rem; margin-top: 1.6rem;
}
.toc ul { list-style: none; display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; margin-top: 0.4rem; }
.toc strong { font-size: 0.85rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }

.room {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 1.1rem 1.3rem; margin-top: 1rem;
}
.room ul { list-style: none; margin-top: 0.15rem; }
.room li { padding-left: 1.35rem; position: relative; }
/* A hollow box, because these are lists you work through — and it survives
   printing, where a colored bullet would not. */
.room li::before {
  content: ''; position: absolute; left: 0; top: 0.55em;
  width: 0.7em; height: 0.7em; border: 1.5px solid var(--green);
  border-radius: 3px;
}
/* A checklist nested inside another card (a day panel already IS the card), so
   it keeps the checkbox markers and loses the second border. */
.room.bare { background: none; border: 0; padding: 0; margin: 0; }
.rhythm {
  display: inline-block; font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--green2);
  background: var(--mint); border-radius: 999px; padding: 0.15rem 0.6rem;
  vertical-align: 0.15em; margin-left: 0.4rem;
}

.quiet {
  background: #eef4f1; border: 1px solid var(--line); border-radius: 14px;
  padding: 1.1rem 1.3rem; margin-top: 1.4rem;
}
.quiet p + p { margin-top: 0.7rem; }

/* The day-by-day grid (/weekly-cleaning-schedule) and the printable chart. */
.grid { display: grid; gap: 0.8rem; margin-top: 1rem; }
@media (min-width: 700px) { .grid.two { grid-template-columns: 1fr 1fr; } }
.day {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 0.9rem 1.1rem;
}
.day h3 { margin-top: 0; color: var(--green2); }
.day .mins { font-size: 0.8rem; color: var(--muted); display: block; margin-bottom: 0.35rem; }

/* The chart itself — a real table, because it is tabular and because a screen
   reader should read it as one. */
.chart { width: 100%; border-collapse: collapse; margin-top: 1rem; font-size: 0.92rem; }
.chart caption { text-align: left; color: var(--muted); font-size: 0.85rem; padding-bottom: 0.5rem; }
.chart th, .chart td { border: 1px solid var(--line); padding: 0.5rem 0.6rem; text-align: left; }
.chart thead th { background: var(--mint); color: var(--green2); font-size: 0.8rem; letter-spacing: 0.04em; text-transform: uppercase; }
.chart tbody th { font-weight: 600; background: #fff; }
.chart td { background: #fff; height: 2.2rem; }
.chart-scroll { overflow-x: auto; }

.cta { margin: 2.8rem 0 1rem; }
.btn {
  display: inline-block; background: var(--green); color: #fff;
  border-radius: 999px; padding: 0.8rem 1.6rem;
  font-weight: 700; font-size: 1rem; text-decoration: none;
}
.btn:hover { background: var(--green2); }
.cta p { color: var(--muted); font-size: 0.9rem; margin-top: 0.7rem; }

/* Where each content page points at its siblings. Internal links are how a
   crawler walks a small site; a page reachable only from the sitemap is
   reachable by the weaker of the two signals. */
.more { margin-top: 2.4rem; }
.more ul { list-style: none; display: grid; gap: 0.5rem; margin-top: 0.5rem; }
.more a { font-weight: 600; }
.more span { color: var(--muted); font-weight: 400; }

footer {
  border-top: 1px solid var(--line); margin-top: 3rem;
  padding: 1.6rem 0 2.4rem; color: var(--muted); font-size: 0.85rem;
}
footer p + p { margin-top: 0.4rem; }

/* A room that folds away (2026-09-08).
 *
 * Owner, on the guide pages: "The other pages got overwhelming and started to
 * bore me so I scrolled to bottom pretty fast… not sure if collapsing them
 * keeps them more user friendly but they did feel very 'blah'."
 *
 * The doubt is the right instinct, and it decided where this is used. Folding
 * PROSE just hides it — the reader still has no idea what is in there. Folding
 * a DIRECTORY is different: `chore-list` is seven rooms by four rhythms, so
 * closed it becomes seven names you can read at a glance and open at the one
 * you came for. The first room stays open so the page never opens as a stack
 * of shut boxes, which is its own kind of blah.
 *
 * ⚠️ The `id` sits on the <details>, not on the <h2> inside it, so the
 * table-of-contents links still land on a room that is closed — the summary
 * carries the name, so you always arrive somewhere legible. Browsers that
 * expand a fold when you navigate into it do that too; this does not depend
 * on it.
 */
.roomfold { margin-top: 1.6rem; }
.roomfold > summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: center; gap: 0.5rem;
  border-radius: 10px; padding: 0.1rem 0.3rem; margin-left: -0.3rem;
}
.roomfold > summary::-webkit-details-marker { display: none; }
.roomfold > summary h2,
.roomfold > summary h3 { margin: 0; }
/* ⚠️ **A shut fold must not inherit an open one's height.** A grid stretches
   every item in a row to the tallest, so with Monday open and Tuesday closed,
   Tuesday rendered as a tall empty box beside it — which reads as broken, not
   as collapsed. `align-items: start` lets each fold be its own height.

   A modifier rather than a change to `.grid`, because the printable chart uses
   the same grid for cards that do NOT collapse, and there equal heights are
   what you want. Scoped this way rather than with `:has()`, which would say the
   same thing while making a marketing page depend on selector support. */
.grid.folds { align-items: start; }

/* ⚠️ A day card inside the two-column grid brings its own gap. `.roomfold`'s
   top margin is for folds stacked down a page (the rooms on /chore-list); left
   in place here it would push the right-hand column out of line with the left. */
.grid > .roomfold { margin-top: 0; }
/* The affordance is a rotating caret, drawn rather than an image so it costs
   nothing and inherits the text color. */
.roomfold > summary::before {
  content: ''; flex: none; width: 0.5rem; height: 0.5rem;
  border-right: 2px solid var(--green); border-bottom: 2px solid var(--green);
  transform: rotate(-45deg); transition: transform 0.15s ease;
}
.roomfold[open] > summary::before { transform: rotate(45deg); }
.roomfold > summary:hover { background: var(--mint); }
.roomfold > summary:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  .roomfold > summary::before { transition: none; }
}

/* One real picture of the product on a guide page.
 *
 * ⚠️ `max-height`, never `width: 100%`. The captures are 390x780 — ratio 0.50 —
 * so at full column width a phone shot is over a thousand pixels tall and pushes
 * the text it illustrates off the screen entirely. Height is the constraint that
 * matters for a portrait image in a prose column; width follows from it.
 */
.shot { margin: 1.8rem 0; text-align: center; }
.shot img {
  max-height: 26rem; width: auto; max-width: 100%;
  border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.shot figcaption {
  margin-top: 0.6rem; font-size: 0.92rem; color: var(--muted);
}

@media print {
  body { background: #fff; font-size: 11pt; }
  .topbar, .cta, .toc, .more, footer a { display: none; }
  .wrap { width: auto; }
  .room, .quiet, .day { border: 1px solid #ccc; break-inside: avoid; page-break-inside: avoid; }
  .chart th, .chart td { border-color: #999; }
  .chart td { height: 2.6rem; }
  h2 { break-after: avoid; page-break-after: avoid; }
  /* ⚠️ A closed <details> prints closed, and these pages exist to be printed —
     a folded chore list would come off the printer as seven headings and
     nothing under them. Paper has no affordance to open, so on paper the folds
     do not exist. */
  .roomfold > summary::before { display: none; }
  .roomfold:not([open]) > * { display: block; }
  a { color: inherit; text-decoration: none; }
}
