/* Landing page. Shares the palette in app.css; overrides the app's fixed-viewport layout. */
/* app.css sets `html, body { height: 100%; overflow: hidden }` so the tool can own a
   fixed viewport. Content pages must undo it on BOTH elements — overriding only <body>
   leaves <html> clipping the page, which suppresses the scrollbar and stops
   position:sticky from having a scroll container to stick to. This stylesheet loads
   after app.css, so equal-specificity rules win without !important. */
html { height: auto; overflow: auto; }
body.page { overflow: auto; height: auto; min-height: 100%; }

/* app.css lays the tool out as a fixed-height flex row (panel | globe). Content pages
   share that stylesheet for the palette, and without this override every <section>
   became a flex column — which is why About and Validation rendered as newspaper
   columns running off the side of the page. */
body.page main {
  display: block;
  height: auto;
}
body.page nav { display: flex; gap: 1rem; align-items: center; }

body.page header {
  position: sticky; top: 0; z-index: 20;
  justify-content: space-between;
  /* Opaque: the page scrolls underneath it. */
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: inherit; }
body.page nav a, body.page nav a:visited { color: var(--brass-lit); text-decoration: none; font-size: .88rem; }
body.page nav a:hover { text-decoration: underline; }

.prose {
  max-width: 46rem;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
  line-height: 1.65;
}
.prose section { margin-bottom: 2.75rem; }
.prose h2 { font-size: 1.85rem; line-height: 1.25; margin: 0 0 1rem; font-weight: 600; }
.prose h3 {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .14em;
  color: var(--muted); margin: 0 0 .9rem; font-weight: 600;
}
.prose p { margin: 0 0 1rem; }
.prose a, .prose a:visited { color: var(--brass-lit); }
.prose a:hover { color: var(--brass); }

.hero { border-bottom: 1px solid var(--line); padding-bottom: 2.5rem; }
.lede { font-size: 1.05rem; color: var(--text); }
.fineprint { color: var(--muted); font-size: .82rem; }

.cta {
  display: inline-block;
  background: var(--brass); color: var(--ink) !important;
  padding: .6rem 1.2rem; border-radius: 3px;
  font-weight: 600; text-decoration: none; font-size: .92rem;
}
.cta:hover { background: var(--brass-lit); }
.ghost {
  display: inline-block; margin-left: .6rem;
  padding: .6rem 1.2rem; border: 1px solid var(--line); border-radius: 3px;
  text-decoration: none; font-size: .92rem;
}

ul.grid { list-style: none; padding: 0; display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
ul.grid li {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 4px; padding: .9rem 1rem; font-size: .88rem; color: var(--muted);
}
ul.grid strong { color: var(--text); }
@media (max-width: 700px) { ul.grid { grid-template-columns: 1fr; } }

.scope {
  border-left: 2px solid var(--brass);
  padding-left: .9rem; color: var(--muted); font-size: .88rem;
}
#contact ul { padding-left: 1.1rem; color: var(--muted); }
#contact strong { color: var(--text); }
.contact-line { margin-top: 1.2rem; }

.prose footer {
  border-top: 1px solid var(--line); padding-top: 1.2rem;
  font-size: .78rem; color: var(--muted);
}
.prose footer .muted { color: var(--line); }

table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: .84rem;
  margin: 0 0 1rem;
}
table.data th, table.data td {
  text-align: left;
  padding: .5rem .6rem;
  border-bottom: 1px solid var(--line);
}
table.data th {
  color: var(--muted);
  font-weight: 600;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .1em;
}
table.data td { font-variant-numeric: tabular-nums; }
table.data td.good { color: var(--green, #5FD9A0); }
.prose h4 {
  font-size: .92rem; margin: 1.5rem 0 .5rem; color: var(--text); font-weight: 600;
}
.prose pre {
  background: var(--surface); border: 1px solid var(--line); border-radius: 4px;
  padding: .8rem .9rem; overflow-x: auto; font-size: .78rem;
}
.prose code { font-family: var(--font-data); }
.prose ul { color: var(--muted); padding-left: 1.1rem; }
.prose ul li { margin-bottom: .7rem; }
.prose ul strong { color: var(--text); }


/* Long pages need a way back that does not depend on the header being in view. */
.backlinks {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 2rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
  font-size: .85rem;
}
.backlinks a, .backlinks a:visited { color: var(--brass-lit); text-decoration: none; }
.backlinks a:hover { text-decoration: underline; }

/* Legal pages: denser than marketing copy, and numbered sections need room to breathe. */
.legal h2 { font-size: 1.5rem; margin-top: 0; }
.legal h3 { font-size: .95rem; text-transform: none; letter-spacing: 0; color: var(--text); margin-top: 2rem; }
.legal h4 { font-size: .88rem; }
.legal p, .legal li { font-size: .9rem; }
.legal blockquote {
  margin: 1.2rem 0; padding: .8rem 1rem;
  border-left: 2px solid var(--brass); background: var(--surface);
  color: var(--muted); font-size: .85rem;
}
.legal blockquote p { margin: 0 0 .5rem; }
.legal blockquote p:last-child { margin: 0; }
.legal hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

/* The animated mark, floated beside the hero. Below 900px the prose column is too narrow
   to give up 260px, so it goes back above the headline at a size that still reads. */
.hero { position: relative; }
.hero-globe {
  float: right;
  width: 260px;
  margin: -1rem 0 1rem 2rem;
  shape-outside: circle(50%);
}
@media (max-width: 900px) {
  .hero-globe { float: none; width: min(60vw, 220px); margin: 0 auto 1.5rem; }
}

/* Contact form. The only form on a content page, so the styling lives here rather than in
   app.css — app.css's controls are sized for a dense side panel, and a page a stranger is
   asked to type a paragraph into wants the opposite. Inputs inherit app.css's `select`
   rule for colour; everything below is size, spacing and the states that rule has none of. */
.form .field { margin-bottom: 1.6rem; }
.form label {
  display: block;
  font-size: .78rem; text-transform: uppercase; letter-spacing: .12em;
  color: var(--muted); font-weight: 600;
}
.form label .opt {
  text-transform: none; letter-spacing: 0; font-weight: 400;
  color: var(--line); margin-left: .4rem;
}
.form input[type="text"], .form input[type="email"], .form textarea, .form select {
  width: 100%;
  margin-top: .45rem;
  padding: .6rem .7rem;
  background: var(--ink);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 3px;
  font-family: var(--font-ui);
  font-size: .92rem;
}
.form textarea { resize: vertical; line-height: 1.5; }
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none; border-color: var(--brass);
}
.form .hint { color: var(--muted); font-size: .8rem; margin: .5rem 0 0; line-height: 1.5; }

/* Name and organisation share a row: two optional fields stacked read as four more things
   to fill in. Below 620px there is no room for two, and stacking beats scrolling sideways. */
.form .field.two { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 620px) { .form .field.two { grid-template-columns: 1fr; } }

/* The honeypot. Not `display: none` and not `hidden`: both are ignored by the naive bots
   this catches, and some of them specifically skip fields hidden that way. Off-screen with
   zero footprint is invisible to a person and indistinguishable from a real field to a
   script reading the DOM. */
.form .hp {
  position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden;
}

.form-actions { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; }
.form-actions button.cta { border: 0; cursor: pointer; font-family: var(--font-ui); }
.form-actions button.cta:disabled { opacity: .55; cursor: default; }
#cf-status.bad { color: var(--brass-lit); }
/* The Turnstile widget renders its own 300px box; this only keeps it off its neighbours. */
#cf-turnstile:empty { margin: 0; }
