/* Site styles. Were an inline <style> block in base.html until the
   Content-Security-Policy (SECURITY-TODO.md 3.10) stopped inline code. */
/* Layout (Matt, 2026-11-18): pages sit at the left edge of the window, up to
   1050px wide (room on a 1080p screen). Paragraphs keep a readable measure;
   tables, screenshots, header and footer use the full width. */
*, *::before, *::after { box-sizing: border-box; }
body { font: 16px/1.5 system-ui, sans-serif; color: #1c2430; background: #fff; max-width: 1050px; margin: 0; padding: 0 1.5rem; }
main p, main li, main dd { max-width: 46rem; }
/* A screenshot inside a capped <dd> (the Product page) still spans the whole column. */
main dd figure.shot { width: calc(min(100vw, 1050px) - 3rem); }
figure.shot figcaption { max-width: 46rem; }
/* Small screens: less padding around the sign-in card. */
@media (max-width: 600px) { .band { padding: 1rem; } .card { padding: 1.5rem; } }
header, footer { padding: 1rem 0; }
/* Header: logo on the left; site links and account links on two right-aligned lines. */
header { border-bottom: 1px solid #c9d3e0; display: flex; flex-wrap: wrap; gap: .5rem 2rem; align-items: center; justify-content: space-between; }
header .brand { color: #2F4A6E; display: block; }
header .brand svg { display: block; height: 34px; width: auto; }
header .navs { display: flex; flex-direction: column; align-items: flex-end; gap: .2rem; }
nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .15rem 1rem; }
nav a { color: #4C6E9E; }
nav.account a { font-size: .95rem; }
footer { border-top: 1px solid #c9d3e0; margin-top: 3rem; font-size: .85rem; color: #4a5565; }
.placeholder { background: #fdf3df; border-left: 4px solid #E3A33C; padding: .5rem 1rem; }
code { font-family: ui-monospace, Consolas, monospace; }
.messages { list-style: none; padding: 0; }
.messages li { background: #e8f3ea; border-left: 4px solid #2E9E4F; padding: .4rem 1rem; margin: .5rem 0; }
input, button, select { font: inherit; padding: .35rem .5rem; }
.errorlist { color: #a12; }
table.prices { border-collapse: collapse; margin: 1rem 0; }
table.prices th, table.prices td { border-bottom: 1px solid #c9d3e0; padding: .3rem .9rem .3rem 0; text-align: left; }
code.hash { word-break: break-all; font-size: .85rem; }
dl.release dt { font-weight: 600; margin-top: .4rem; }
dl.release dd { margin-left: 0; }
figure.shot { margin: 1.25rem 0 1.75rem; }
figure.shot img { display: block; max-width: 100%; height: auto; border: 1px solid #c9d3e0; }
figure.shot figcaption { font-size: .9rem; color: #4a5565; margin-top: .4rem; }
form.inline { display: inline; }

/* Sign-in pages (Matt chose style B, 2026-11-18). Sign in, Create account and
   the code page: a card on a navy band, with how it works beside it. The other
   allauth pages get the same card without the band (templates/allauth/layouts/base.html). */
.band { margin-top: 1.5rem; background: linear-gradient(135deg, #2F4A6E, #4C6E9E); border-radius: 12px; padding: 2rem; display: flex; flex-wrap: wrap; gap: 2rem 3rem; align-items: flex-start; }
.card { width: 400px; max-width: 100%; flex: none; background: #fff; border: 1px solid #d5dde8; border-radius: 10px; padding: 2rem; }
.band .card { border: 0; box-shadow: 0 8px 28px rgba(0, 0, 0, .25); }
.card-plain { margin-top: 2rem; box-shadow: 0 6px 24px rgba(28, 36, 48, .10); }
.card h1 { font-size: 1.6rem; margin: 0 0 1rem; }
.card form { display: flex; flex-direction: column; gap: .35rem; }
.card form p { margin: 0; }
.card label { font-weight: 600; font-size: .9rem; margin-top: .5rem; }
.card fieldset { border: 0; padding: 0; margin: 0 0 .25rem; }
.card legend { font-weight: 600; font-size: .9rem; padding: 0; margin-bottom: .3rem; }
.card fieldset div { display: flex; flex-direction: column; gap: .2rem; }
.card fieldset label { font-weight: 400; font-size: 1rem; margin: 0; display: flex; gap: .5rem; align-items: center; }
.card input[type=email], .card input[type=text] { padding: .6rem .75rem; border: 1px solid #b9c4d3; border-radius: 6px; width: 100%; }
.card input[name=code] { font-size: 1.4rem; letter-spacing: .25em; font-variant-numeric: tabular-nums; }
.card input[name=code]::placeholder { letter-spacing: normal; font-size: 1rem; }
.card a { color: #4C6E9E; }
.card .field { display: flex; flex-direction: column; gap: .35rem; }
.card .field.off { opacity: .45; }
.card .field.off input { background: #eef1f5; cursor: not-allowed; }
.card small, .card .helptext { color: #4a5565; font-size: .82rem; }
.card .cf-turnstile { margin-top: .9rem; min-height: 65px; }
.card button { font-weight: 600; margin-top: 1rem; padding: .75rem 1rem; border: 0; border-radius: 6px; background: #2F4A6E; color: #fff; cursor: pointer; }
.card button:hover { background: #253c5a; }
.card button.link { background: none; color: #4C6E9E; padding: 0; margin: 0; font-weight: 400; text-decoration: underline; }
.card form.inline-link { display: inline; }
.card .note { font-size: .85rem; color: #4a5565; margin: 1rem 0 0; }
.card .switch { margin: 1rem 0 0; padding-top: 1rem; border-top: 1px solid #e1e7ef; font-size: .95rem; }
.band .side { color: #fff; padding-top: .5rem; flex: 1 1 18rem; max-width: 26rem; }
.band .side h2 { font-size: 1.25rem; margin: 0 0 1rem; }
.band .side ol { margin: 0; padding-left: 1.2rem; display: grid; gap: .8rem; }
.band .side p { color: #dfe7f2; font-size: .9rem; }
.band .side a { color: #fff; }

/* Signed-in pages: My account, My organization, Members (Matt, 2026-11-18).
   The same white cards as the sign-in pages, side by side on a wide screen;
   facts as text, actions as buttons. */
.lede { font-size: 1.05rem; color: #3a4554; }
.panels { display: grid; grid-template-columns: repeat(auto-fit, minmax(24rem, 1fr)); gap: 1.5rem; margin-top: 1.5rem; align-items: start; }
.panels .card, .card.wide { width: auto; box-shadow: 0 4px 16px rgba(28, 36, 48, .07); }
.card.wide { margin-top: 1.5rem; padding: 1.25rem 1.5rem; }
.card.notice { width: auto; margin: 1rem 0; border-left: 4px solid #E3A33C; padding: 1rem 1.5rem; }
.card.notice p { margin: 0; }
.card h2 { font-size: 1.15rem; margin: 0 0 .75rem; color: #2F4A6E; }
dl.facts { margin: 0; display: grid; grid-template-columns: 7.5rem 1fr; gap: .55rem 1rem; }
dl.facts dt { color: #4a5565; font-size: .9rem; padding-top: .1rem; }
dl.facts dd { margin: 0; }
details.change { display: inline; margin-left: .5rem; }
details.change summary { display: inline; cursor: pointer; color: #4C6E9E; text-decoration: underline; font-size: .9rem; }
details.change[open] { display: block; margin: .6rem 0 0; }
details.change form { margin-top: .5rem; }
.card .actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.25rem; }
.card .actions form { display: inline; }
.card .actions button { margin-top: 0; }
a.button { display: inline-block; font-weight: 600; padding: .6rem 1rem; border-radius: 6px; background: #2F4A6E; color: #fff; text-decoration: none; }
a.button:hover { background: #253c5a; }
a.button.secondary, .card button.secondary { background: #fff; color: #2F4A6E; border: 1px solid #b9c4d3; }
a.button.secondary:hover, .card button.secondary:hover { background: #f1f4f8; }
.card button.small { margin: 0; padding: .3rem .7rem; font-size: .9rem; font-weight: 500; }
.card form.inline { display: inline-flex; flex-direction: row; align-items: center; gap: .4rem; }
.card .more { margin: 1rem 0 0; font-size: .92rem; }
.back { margin: 1rem 0 0; font-size: .95rem; }
table.people { width: 100%; border-collapse: collapse; }
table.people th { text-align: left; font-size: .85rem; color: #4a5565; font-weight: 600; padding: 0 .75rem .5rem 0; border-bottom: 1px solid #e1e7ef; }
table.people td { padding: .6rem .75rem .6rem 0; border-bottom: 1px solid #eef1f5; vertical-align: middle; }
table.people td.row-actions { text-align: right; white-space: nowrap; }
.card select { font: inherit; padding: .3rem .4rem; border: 1px solid #b9c4d3; border-radius: 6px; }
ul.plain { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }

/* Buttons that start a trial (2026-11-21): in the header on every page for a
   signed-out visitor, twice on Home. One filled button per place; the other is outlined. */
a.button.big { padding: .8rem 1.5rem; font-size: 1.05rem; border: 1px solid transparent; }
a.button.big.secondary { border-color: #b9c4d3; }
a.button.small { padding: .3rem .8rem; font-size: .9rem; }
nav.account a.button { margin-left: .35rem; }
a.button.light { background: #fff; color: #2F4A6E; }
a.button.light:hover { background: #eef2f7; }
a.button.ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); }
a.button.ghost:hover { background: rgba(255, 255, 255, .12); }
.cta-row { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.5rem 0 .9rem; }

/* Home (2026-11-21). The hero, then one investigation told with the real
   screenshots. Each step sets its text beside a screenshot; when the screenshot comes
   into view the camera moves in on the evidence, once, on a timer (see "The animation"
   below). The page scrolls normally. Where the camera ends is --s (zoom) and --cx, --cy (the centre, as
   fractions of the screenshot) in the .z-<id> classes below; the ring is drawn
   in the screenshot's own pixels, so it moves with the camera. The stage takes its
   shape from the screenshot's width and height (not all are 1440 x 900).
   tests/test_home_walkthrough.py keeps every ring inside the zoomed window.
   Without script, or with reduced motion, the page simply shows the end state: the
   crop, ringed, with a link to the full screenshot. */
.hero { padding: 1.75rem 0 0; }
.hero h1 { font-size: clamp(1.9rem, 4vw, 2.5rem); line-height: 1.15; letter-spacing: -.012em; margin: 0 0 .9rem; }
.hero .lede { font-size: 1.15rem; color: #2a3442; max-width: 40rem; margin: 0; }
.hero .cta-row { margin: 1.25rem 0 .75rem; }
.hero .fine { font-size: .9rem; color: #4a5565; margin: 0; }
.walk { margin-top: 2.25rem; padding-top: 1.25rem; border-top: 1px solid #c9d3e0; }
.walk h2 { font-size: 1.15rem; line-height: 1.2; margin: 0 0 .35rem; }
.walk-note { font-size: .92rem; color: #3a4554; margin: 0; }
.walk-index { list-style: none; display: flex; flex-wrap: wrap; gap: .3rem 1.4rem; padding: 0; margin: .75rem 0 1.25rem; font-size: .9rem; }
.walk-index a { color: #2F4A6E; text-decoration: none; border-bottom: 1px solid #b9c4d3; }
.walk-index a:hover { border-bottom-color: #2F4A6E; }
.walk-index span { font: 600 .8rem ui-monospace, Consolas, monospace; color: #4a5565; }
.walk code { background: #eef2f7; padding: .05rem .3rem; border-radius: 3px; font-size: .88em; }
.walk-end { margin-top: 1.5rem; }
.home a:not(.button) { color: #2F5C94; }
.home .walk-index a { color: #2F4A6E; }

/* The base is a plain two-column article: text, then the ringed crop (the end state). */
.step { display: grid; grid-template-columns: 15rem minmax(0, 1fr); gap: 0 1.75rem; margin-bottom: 3.5rem; }
.step-text, .stage { align-self: start; }
.step-text .step-n { font: 600 .78rem/1 ui-monospace, Consolas, monospace; letter-spacing: .08em; text-transform: uppercase; color: #4a5565; margin: .3rem 0 .7rem; }
.step h3 { font-size: 1.3rem; line-height: 1.25; margin: 0 0 .7rem; }
.step-text p { font-size: .95rem; margin: 0 0 .7rem; }
.step-text .needs { font-size: .8rem; color: #4a5565; }
.step-text .full { font-size: .85rem; }
.stage { margin: 0; overflow: hidden; background: #fff; border: 1px solid #b9c4d3; border-radius: 8px; box-shadow: 0 10px 30px rgba(28, 36, 48, .14); }
.pan { position: relative; width: 100%; transform-origin: 0 0; --k: 1; --e: calc(var(--s) * var(--k));
  --end: translate(clamp(calc((1 - var(--e)) * 100%), calc((.5 - var(--e) * var(--cx)) * 100%), 0%), clamp(calc((1 - var(--e)) * 100%), calc((.5 - var(--e) * var(--cy)) * 100%), 0%)) scale(var(--e));
  transform: var(--end); }
.pan img { display: block; width: 100%; height: auto; }
.pan svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ring-halo, .ring { fill: none; }
.ring-halo { stroke: #fff; stroke-width: calc(9 / var(--e)); opacity: .9; }
.ring { stroke: #2F4A6E; stroke-width: calc(4 / var(--e)); }
/* --km: how much closer a phone's narrow stage looks, as large as keeps the ring in view. */
.z-wait { --s: 1.9; --cx: .286; --cy: .14; --km: 1; }
.z-event { --s: 2.7; --cx: .1278; --cy: .6889; --km: 1.5; }
.z-sql { --s: 1.85; --cx: .268; --cy: .74; --km: 1; }
.z-lock { --s: 2.2; --cx: .70; --cy: .85; --km: 1.5; }
.z-line { --s: 2; --cx: .625; --cy: .3222; --km: 1.25; }
.z-card { --s: 2.2; --cx: .74; --cy: .3333; --km: 1; }
.z-offer { --s: 2.4; --cx: .343; --cy: .2; --km: 1; }
.z-script { --s: 1.4; --cx: .35; --cy: .2; --km: 1; }
.z-applied { --s: 2.2; --cx: .22; --cy: .2; --km: 1; }
.z-follow { --s: 2.2; --cx: .2; --cy: .9; --km: 1; }
.z-trace { --s: 1.7; --cx: .73; --cy: .17; --km: 1; }
.z-tkprof { --s: 1.6; --cx: .3; --cy: .617; --km: 1; }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 1.5rem 3rem; margin-top: 1rem; padding-top: 1.75rem; border-top: 1px solid #c9d3e0; }
.facts h2 { font-size: 1.1rem; margin: 0 0 .5rem; color: #2F4A6E; }
.facts p { margin: 0; }
.close { margin: 3rem 0 1.25rem; background: linear-gradient(135deg, #2F4A6E, #4C6E9E); color: #fff; border-radius: 12px; padding: 2.25rem; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 1.75rem 3rem; align-items: start; }
.close h2 { font-size: 1.8rem; line-height: 1.15; margin: 0 0 .75rem; }
.close p { color: #e6edf6; margin: 0; }
.close ol { margin: 0; padding-left: 1.3rem; display: grid; gap: .9rem; color: #e6edf6; }
.close .cta-row { margin: 1.5rem 0 0; }
.home .more { font-size: .95rem; color: #3a4554; }

/* The animation: a timed move, not tied to the scroll bar. site.js marks each step
   "ready" (screenshot whole, ring hidden) and, the first time its screenshot is mostly
   in view, "play": a short pause on the whole screen, then the camera moves in and the
   ring appears. Taking "play" away (site.js does, after a while or as the step leaves
   the screen) runs it backwards: the ring goes and the camera moves out. Without script, or with reduced motion, nothing is marked and the page
   shows the end state. */
@media (prefers-reduced-motion: no-preference) {
  .step.ready .pan { transform: none; transition: transform 1.4s cubic-bezier(.45, 0, .25, 1); }
  .step.ready .stage svg { opacity: 0; transition: opacity .3s ease; }
  .step.ready.play .pan { transform: var(--end); transition: transform 2.8s cubic-bezier(.45, 0, .25, 1) .9s; }
  .step.ready.play .stage svg { opacity: 1; transition: opacity .6s ease 3.5s; }
}
/* Replay: only when script is running the animation (the step is "ready"). */
.replay { display: none; position: absolute; right: .6rem; bottom: .6rem; z-index: 2; font-size: .8rem; padding: .25rem .7rem; border: 1px solid #b9c4d3; border-radius: 999px; background: rgba(255, 255, 255, .92); color: #2F4A6E; cursor: pointer; }
.replay:hover { background: #fff; }
.step.ready .replay { display: block; }
.stage { position: relative; }
@media (max-width: 800px) {
  .step { display: block; margin: 0 0 2.5rem; }
  .stage { margin-top: 1rem; }
  .pan { --k: var(--km); }
  .close { grid-template-columns: 1fr; padding: 1.5rem; }
}
