/* The sign-up site's one stylesheet, in MVV's own look (the owner, 13 Oct 2026: "let's use MVV look and feel, let's make it
   proper"): the palette of the MVV app and of Control (the house's theme-derive.ts ROOT_TOKENS, apps/control/src/app.css), the
   dark green MVV mark in the header (drawn in the page itself, apps/signup/lib/pages.mjs BRAND_MARK), white cards on a pale
   green canvas, light headings and dark green pill buttons. Nothing is fetched: the app's type, IBM Plex Sans, is used when the
   device has it, else the system's own sans serif (the Content-Security-Policy allows fonts from this site alone). A phone
   first; light and dark. */

:root {
  color-scheme: light dark;
  /* MVV's brand: dark forest green, lime accent */
  --green-900: #1c2820;
  --green-800: #26352a;
  --green-700: #324736;
  --green-600: #44604a;
  --lime: #c8e66b;
  --lime-dark: #a9c84f;
  /* the page */
  --bg: #f6f8f4;
  --surface: #ffffff;
  --canvas-2: #eef2ea;
  --text: #1a1f1c;
  --ink-soft: #545c54;
  --muted: #5f675f;
  --line: #e7ebe6;
  --line-strong: #d3dad1;
  --accent: #44604a;
  --marker: #44604a;
  --primary: #26352a;
  --primary-hover: #324736;
  --primary-text: #ffffff;
  --selected-bg: #eef3ee;
  --hero: #26352a;
  --hero-text: #ffffff;
  --hero-soft: #c9d4c8;
  --hero-accent: #c8e66b;
  /* the Terms box's bar, and the words that warn */
  --note-bg: #eef2ea;
  --note-line: #a9c84f;
  --warn-bg: #fdf6e3;
  --warn-line: #c9a227;
  --warn-text: #6e5512;
  /* shape */
  --r-sm: 10px;
  --r: 16px;
  --shadow-sm: 0 1px 2px rgba(28, 40, 32, .06), 0 1px 3px rgba(28, 40, 32, .04);
  --font: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101511;
    --surface: #172019;
    --canvas-2: #1e2920;
    --text: #e6ebe5;
    --ink-soft: #bcc5bb;
    --muted: #a3aca2;
    --line: #29342b;
    --line-strong: #37443a;
    --accent: #c8e66b;
    --marker: #a9c84f;
    --primary: #c8e66b;
    --primary-hover: #d6ef8a;
    --primary-text: #12180a;
    --selected-bg: #1f2b1f;
    --hero: #26352a;
    --hero-text: #ffffff;
    --hero-soft: #c9d4c8;
    --hero-accent: #c8e66b;
    --note-bg: #1e2920;
    --note-line: #c8e66b;
    --warn-bg: #33290f;
    --warn-line: #d9b451;
    --warn-text: #f0dca0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  }
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap { max-width: 46rem; margin: 0 auto; padding: 0 16px; }

a { color: var(--accent); text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid var(--lime-dark); outline-offset: 2px; border-radius: 4px; }

.skip { position: absolute; left: -9999px; top: 0; }
.skip:focus { left: 16px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 1; }

.preview-banner {
  margin: 0;
  padding: 10px 16px;
  background: var(--warn-bg);
  color: var(--warn-text);
  border-bottom: 2px solid var(--warn-line);
  font-weight: 600;
  text-align: center;
}

/* ── the header: the MVV mark, the page's name, the help links ───────────────────────────────────────────────── */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 20px; padding-top: 12px; padding-bottom: 12px; min-height: 60px; }
.site-header .wrap > * { min-width: 0; }
.brand-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark { display: block; flex: none; width: 34px; height: 34px; border-radius: 9px; }
.brand { font-weight: 600; font-size: 1.02rem; line-height: 1.25; letter-spacing: -.005em; color: var(--text); text-decoration: none; min-width: 0; }
.brand:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.site-header nav { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: .92rem; }
.site-header nav a { color: var(--ink-soft); text-decoration: none; }
.site-header nav a:hover { color: var(--text); text-decoration: underline; }
.site-header nav a[aria-current] { font-weight: 700; color: var(--text); }

main.wrap { padding-top: 8px; padding-bottom: 48px; }
main.wrap > * { min-width: 0; max-width: 100%; }
main a[href^="mailto:"] { overflow-wrap: anywhere; }

/* ── type: light headings, as the MVV app's ─────────────────────────────────────────────────────────────────── */
h1 { font-size: 2.1rem; font-weight: 300; line-height: 1.2; letter-spacing: -.02em; margin: 36px 0 12px; }
h2 { font-size: 1.3rem; font-weight: 500; line-height: 1.3; letter-spacing: -.01em; margin: 32px 0 8px; }
h3 { font-size: 1.08rem; font-weight: 600; line-height: 1.35; margin: 22px 0 6px; }
h4, h5, h6 { font-size: 1rem; font-weight: 600; margin: 18px 0 6px; }
p { margin: 0 0 14px; }

.lead { font-size: 1.1rem; line-height: 1.5; color: var(--ink-soft); }
.lead strong { color: var(--text); font-weight: 600; overflow-wrap: anywhere; }
.meta, .doc-meta { color: var(--muted); }

.not-published {
  display: inline-block;
  padding: 2px 8px;
  background: var(--warn-bg);
  color: var(--warn-text);
  border-left: 4px solid var(--warn-line);
  font-weight: 600;
}

/* ── cards ───────────────────────────────────────────────────────────────────────────────────────────────────── */
.cards, .doc-list { list-style: none; padding: 0; }
.cards li, .doc-list li { margin: 0 0 12px; }
.cards a { display: block; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm); text-decoration: none; color: var(--text); }
.cards a:hover { border-color: var(--lime-dark); }
.cards strong { display: block; color: var(--text); font-size: 1.1rem; font-weight: 600; }
.cards span { color: var(--muted); }

.plans { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .plans { grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); } }
.plan { padding: 18px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow-sm); display: flex; flex-direction: column; min-width: 0; }
.plan h2 { margin-top: 0; }
.plan ul { padding-left: 20px; flex: 1; }
.price { margin: 0 0 8px; }
.amount { font-size: 1.6rem; font-weight: 300; letter-spacing: -.02em; }

/* ── the buttons: MVV's dark green pill ──────────────────────────────────────────────────────────────────────── */
.button {
  display: inline-block;
  min-height: 48px;
  padding: 12px 26px;
  border: 0;
  border-radius: 999px;
  background: var(--primary);
  color: var(--primary-text);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: .005em;
  text-align: center;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: background-color .14s ease, transform .14s ease;
}
.button:hover { background: var(--primary-hover); }
.button:active { transform: translateY(1px); }

.table-wrap { overflow-x: auto; margin: 16px 0; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; width: 100%; }
th, td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
th { background: var(--canvas-2); }

blockquote { margin: 16px 0; padding: 4px 16px; border-left: 4px solid var(--line-strong); color: var(--muted); }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.92em; overflow-wrap: anywhere; }
pre { overflow-x: auto; padding: 12px; background: var(--canvas-2); border-radius: var(--r-sm); }
hr { border: 0; border-top: 1px solid var(--line); margin: 28px 0; }

.versions { margin-top: 32px; padding-top: 8px; border-top: 1px solid var(--line); }

/* ── the footer ─────────────────────────────────────────────────────────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 0.86rem; line-height: 1.55; }
.site-footer .wrap { padding-top: 20px; padding-bottom: 28px; }
.site-footer p { margin: 0; }

/* ── the steps, the boxes and the form ──────────────────────────────────────────────────────────────────────── */
.step { margin: 8px 0 24px; }
.step > h2:first-child { margin-top: 24px; }
.step > p:last-child { margin-bottom: 0; }
fieldset { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 10px 18px 14px; margin: 0 0 16px; min-width: 0; }
legend { font-weight: 600; padding: 0 6px; }
.plan-choice { display: block; padding: 10px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.plan-choice:last-child { border-bottom: 0; }
.plan-choice span { display: block; color: var(--muted); padding-left: 28px; }
label { font-weight: 600; }
.hint { display: block; color: var(--muted); font-size: 0.92rem; font-weight: 400; }
input[type="text"], input:not([type]), input[type="email"], input[type="number"] {
  display: block;
  width: 100%;
  max-width: 28rem;
  margin-top: 4px;
  padding: 10px 12px;
  font: inherit;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
}
input:focus-visible, button:focus-visible { outline: 3px solid var(--lime-dark); outline-offset: 2px; }
input[type="radio"], input[type="checkbox"] { width: 18px; height: 18px; margin: 0 8px 0 0; vertical-align: -3px; accent-color: var(--marker); }
button { font: inherit; cursor: pointer; }
button.button { border: 0; }
button[disabled] { opacity: 0.6; cursor: wait; }
.link-button { background: none; border: 0; padding: 10px 4px; color: var(--accent); text-decoration: underline; }
.said { margin: 16px 0; padding: 12px 16px; border-left: 4px solid var(--warn-line); border-radius: 0 var(--r-sm) var(--r-sm) 0; background: var(--warn-bg); color: var(--warn-text); font-weight: 600; overflow-wrap: anywhere; }
.note { padding: 12px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); }
.cf-turnstile { margin: 16px 0; min-height: 65px; }

/* the key points of the Terms, just above the tick box: set apart, so the buyer reads them before they accept */
.key-points { margin: 24px 0; padding: 20px 22px 18px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--note-line); border-radius: var(--r); box-shadow: var(--shadow-sm); font-size: 0.95rem; line-height: 1.6; }
.key-points h3 { margin: 0 0 14px; font-size: 1.08rem; }
.key-points ol { margin: 0; padding-left: 1.5em; }
.key-points li { margin: 0 0 10px; padding-left: 6px; }
.key-points li::marker { color: var(--marker); font-weight: 600; }
.key-points-summary { margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line); font-weight: 600; }

/* the tick box: a card of its own, the tick hanging beside the words */
.accept { margin: 16px 0 22px; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r); line-height: 1.55; }
.accept label { display: block; position: relative; padding-left: 32px; font-weight: 400; cursor: pointer; }
.accept input[type="checkbox"] { position: absolute; left: 0; top: 0.15em; margin: 0; }
.accept:has(input:checked) { border-color: var(--marker); background: var(--selected-bg); box-shadow: 0 0 0 1px var(--marker); }

/* the Italian specific approval (0067): the schedule's clauses in a box of their own, scrolled, and the second tick below it */
.it-approval { margin: 24px 0; padding: 20px 22px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow-sm); line-height: 1.55; }
.it-approval h3 { margin: 0 0 8px; }
.it-approval .approval-text { max-height: 22rem; overflow-y: auto; overscroll-behavior: contain; padding: 4px 16px 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg); font-size: 0.92rem; overflow-wrap: anywhere; }
.it-approval .approval-text h4, .it-approval .approval-text h5 { margin: 0.9rem 0 0.4rem; }
.it-approval .accept.second { margin: 1rem 0 0; }

/* ── the invitation page: the one invited plan, as a card ────────────────────────────────────────────────────── */
/* Plan, Seats, AI and Price are the rows of one white card; the first month is its foot, in MVV's dark green with the
   amount in lime, as the MVV app shows a figure that matters. Style only: the words and the elements are the page's own. */
main[data-invite] h1 { margin-bottom: 4px; }
#pay-step > h2 + .lead { margin-bottom: 18px; }
#pay-step > h2 + .lead + p,
#pay-step > h2 + .lead + p + p,
#pay-step > h2 + .lead + p + p + p,
#pay-step > h2 + .lead + p + p + p + p {
  margin: 0;
  padding: 13px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-bottom-width: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
#pay-step > h2 + .lead + p { border-radius: var(--r) var(--r) 0 0; }
#pay-step > h2 + .lead + p + p + p + p:has(+ #invite-total-line[hidden]) { border-bottom-width: 1px; border-radius: 0 0 var(--r) var(--r); margin-bottom: 22px; }
#pay-step > h2 + .lead + p > strong,
#pay-step > h2 + .lead + p > span,
#pay-step > h2 + .lead + p + p > span,
#pay-step > h2 + .lead + p + p + p > span,
#pay-step > h2 + .lead + p + p + p + p > span { color: var(--text); font-weight: 600; font-size: 1rem; }
#invite-total-line {
  margin: 0 0 24px;
  padding: 18px 20px 18px;
  background: var(--hero);
  border: 1px solid var(--hero);
  border-radius: 0 0 var(--r) var(--r);
  color: var(--hero-soft);
  font-size: 0.95rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
#invite-total { display: inline-block; max-width: 100%; color: var(--hero-accent); font-size: 1.6rem; font-weight: 400; line-height: 1.25; letter-spacing: -.01em; }
#invite-acceptor { color: var(--muted); font-size: 0.95rem; }

/* ── the short pages (the by-invitation front page, back from Stripe, not found): their words on one white card ─────── */
main.wrap:not([data-intake]) {
  width: calc(100% - 32px);
  max-width: 40rem;
  margin: 48px auto 64px;
  padding: 6px 32px 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: 0 6px 24px rgba(28, 40, 32, .08);
}
main.wrap:not([data-intake]) h1 { margin-top: 26px; }
main.wrap:not([data-intake]) > :last-child { margin-bottom: 0; }

@media (max-width: 540px) {
  h1 { font-size: 1.75rem; margin-top: 28px; }
  main.wrap:not([data-intake]) { margin: 24px auto 40px; padding: 4px 20px 22px; }
  main.wrap:not([data-intake]) h1 { margin-top: 20px; }
  .site-header .wrap { gap: 6px 16px; }
  .key-points, .it-approval { padding: 16px 16px 14px; }
  .key-points ol { padding-left: 1.3em; }
  .it-approval .approval-text { padding: 2px 12px 10px; }
  #pay-step > h2 + .lead + p,
  #pay-step > h2 + .lead + p + p,
  #pay-step > h2 + .lead + p + p + p,
  #pay-step > h2 + .lead + p + p + p + p,
  #invite-total-line { padding-left: 16px; padding-right: 16px; }
  #invite-total { font-size: 1.45rem; }
  main[data-invite] .button { display: block; width: 100%; }
}
