/* Bayou Signal — shared stylesheet
   Plain CSS, no build step. Linked relatively so it works over file:// too.
   The no-build-step constraint duplicates header/footer MARKUP across the four
   pages; it does not require duplicating the styles. One file, four links. */

:root {
  --paper:      #faf8f4;
  --paper-sunk: #ece7dd;
  --ink:        #1a1a17;
  --ink-soft:   #4a463f;
  --muted:      #6f6a61;
  --rule:       #ddd7cc;
  --accent:     #1f4d3d;
  --accent-lit: #2c6b54;
  --flag:       #8a5a1c;
  --flag-bg:    #fdf4e6;
  --measure:    34rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper:      #14140f;
    --paper-sunk: #22221a;
    --ink:        #eceae4;
    --ink-soft:   #c3bfb5;
    --muted:      #948e83;
    --rule:       #35342c;
    --accent:     #7fc4a8;
    --accent-lit: #9ad9bf;
    --flag:       #e0b070;
    --flag-bg:    #2a2114;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.65 ui-serif, Georgia, "Iowan Old Style", "Times New Roman", serif;
}

.wrap {
  /* The container and the reading measure must agree, or the column drifts.
     37rem - 3rem of padding = 34rem content box = exactly --measure, so the
     text is centred in the viewport rather than flush-left inside a wider box. */
  max-width: calc(var(--measure) + 3rem);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Masthead and footer stay wider so four nav links do not wrap on desktop.
   Both are centred on the same axis, so they read as concentric, not misaligned. */
.masthead .wrap,
footer .wrap {
  max-width: 46rem;
}

/* R48 — skip link, revealed on focus */
.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: var(--paper);
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.7rem 1.1rem;
  z-index: 10;
}

.skip:focus { left: 0; color: var(--paper); }

@media (prefers-color-scheme: dark) { .skip, .skip:focus { color: #101010; } }

/* ---------- masthead ---------- */

.masthead {
  border-bottom: 1px solid var(--rule);
}

.masthead .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.5rem;
  padding-top: 1.4rem;
  padding-bottom: 1.4rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  color: var(--ink);
  text-decoration: none;
  margin-right: auto;
}

.masthead nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.875rem;
}

.masthead nav a {
  color: var(--ink-soft);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  /* Hit area grows to ~44px without moving the type. */
  padding: 0.6rem 0;
  margin: -0.6rem 0;
}

.masthead nav a:hover,
.masthead nav a:focus-visible { color: var(--accent); border-bottom-color: var(--accent); }

.masthead nav a[aria-current="page"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--accent); }

/* R50 — the site's one visual anchor. Same motif as the favicon. */
.mark { display: block; width: 20px; height: 20px; flex: none; }

/* ---------- hero ---------- */

.hero { padding: 3.5rem 0 2.75rem; border-bottom: 1px solid var(--rule); }

.eyebrow {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 1.1rem;
}

h1 {
  font-size: clamp(1.85rem, 5.2vw, 2.6rem);
  line-height: 1.18;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin: 0 0 1.4rem;
  max-width: var(--measure);
}

.standfirst {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: var(--measure);
  margin: 0 0 1.75rem;
}

/* ---------- sections ---------- */

section { padding: 2.75rem 0; border-bottom: 1px solid var(--rule); }

h2 {
  font-size: 1.35rem;
  line-height: 1.3;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 1.1rem;
  max-width: var(--measure);
}

h3 {
  font-size: 1.02rem;
  font-weight: 600;
  margin: 1.9rem 0 0.4rem;
}

p { max-width: var(--measure); margin: 0 0 1.05rem; }

p.lede { font-size: 1.05rem; color: var(--ink-soft); }

a { color: var(--accent); }
a:hover, a:focus-visible { color: var(--accent-lit); }

/* R47 — one focus rule for every interactive element, not just inputs. */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

@media (prefers-color-scheme: dark) {
  a:focus-visible,
  button:focus-visible { outline-color: var(--accent-lit); }
}

strong { font-weight: 600; }

/* ---------- the single ask ---------- */

.ask { text-align: left; background: var(--paper-sunk); border-bottom: 0; }

.button {
  display: inline-block;
  background: var(--accent);
  color: var(--paper);
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  padding: 0.85rem 1.6rem;
  border: 1px solid var(--accent);
  border-radius: 2px;
}

.button:hover, .button:focus-visible { background: var(--accent-lit); border-color: var(--accent-lit); color: var(--paper); }

@media (prefers-color-scheme: dark) {
  .button { color: #101010; }
  .button:hover, .button:focus-visible { color: #101010; }
}

/* A path, not an ask. Deliberately not a button — see WEBSITE-BRAINSTORM.md 3.5. */
.path {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 2px;
}

/* ---------- steps ---------- */

ol.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; max-width: var(--measure); }

ol.steps li { counter-increment: step; position: relative; padding-left: 2.4rem; margin-bottom: 1.35rem; }

ol.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: 0.12em;
  width: 1.6rem; height: 1.6rem;
  border: 1px solid var(--rule);
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.78rem;
  color: var(--muted);
}

/* ---------- sources / never lists ---------- */

ul.plain { max-width: var(--measure); padding-left: 1.15rem; margin: 0 0 1.05rem; }
ul.plain li { margin-bottom: 0.45rem; }

/* ---------- pull quote for the load-bearing sentence ---------- */

.pull {
  border-left: 3px solid var(--accent);
  padding: 0.1rem 0 0.1rem 1.15rem;
  margin: 1.6rem 0;
  max-width: var(--measure);
  font-size: 1.05rem;
  color: var(--ink);
}

.pull p:last-child { margin-bottom: 0; }

/* ---------- team ---------- */

.team { list-style: none; padding: 0; margin: 0; max-width: var(--measure); }

.team li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.9rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--rule);
}

.team li:last-child { border-bottom: 0; }

.team .who { font-weight: 600; min-width: 12rem; }
.team .what { color: var(--muted); }

/* ---------- FAQ ---------- */

.faq { max-width: var(--measure); }
.faq dt { font-weight: 600; margin-top: 1.5rem; }
.faq dd { margin: 0.35rem 0 0; color: var(--ink-soft); }

.todo {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--flag);
  background: var(--flag-bg);
  border: 1px solid var(--flag);
  border-radius: 2px;
  padding: 0.1rem 0.4rem;
  margin-right: 0.4rem;
}

/* ---------- the composite brief, as rendered on brief.html ---------- */

.composite-banner {
  border-left: 3px solid var(--flag);
  background: var(--flag-bg);
  padding: 0.9rem 1.1rem;
  margin: 1.5rem 0;
  max-width: var(--measure);
  font-size: 0.98rem;
}

/* The brief is a document inside the page. The inset says so. */
.brief-doc {
  border: 1px solid var(--rule);
  border-radius: 3px;
  background: var(--paper-sunk);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  padding: 1.75rem;
  margin: 0 0 1.25rem;
  max-width: var(--measure);
}

.brief-doc > :first-child { margin-top: 0; }
.brief-doc > :last-child { margin-bottom: 0; }

.brief-title {
  font-size: 1.15rem;
  line-height: 1.35;
  margin: 0 0 1.25rem;
  padding-bottom: 0.9rem;
  border-bottom: 2px solid var(--ink);
}

.brief-doc h4 {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 1.9rem 0 0.7rem;
}

.brief-facts { margin: 0 0 1.1rem; }

.brief-facts dt {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 0.9rem;
}

.brief-facts dd { margin: 0.15rem 0 0; }

.brief-doc ol.steps li { margin-bottom: 0.9rem; }
.brief-doc ul.plain li { margin-bottom: 0.7rem; }

.brief-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.05rem;
  font-size: 0.95rem;
}

.brief-table th, .brief-table td {
  text-align: left;
  vertical-align: top;
  padding: 0.55rem 0.7rem 0.55rem 0;
  border-bottom: 1px solid var(--rule);
}

.brief-table th {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

/* Wide content scrolls inside its own container; the page never scrolls sideways. */
.scroller { overflow-x: auto; }

@media (max-width: 30rem) {
  .brief-doc { padding: 1.15rem; }
}

/* ---------- form ---------- */

form { max-width: var(--measure); }

.field { margin-bottom: 1.6rem; }

.field label, .field legend {
  display: block;
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  padding: 0;
}

.field .hint {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.83rem;
  color: var(--muted);
  margin: 0 0 0.5rem;
  max-width: none;
}

input[type="text"], input[type="email"], textarea, select {
  width: 100%;
  font: inherit;
  font-size: 0.98rem;
  color: var(--ink);
  background: var(--paper-sunk);
  border: 1px solid var(--rule);
  border-radius: 2px;
  padding: 0.6rem 0.7rem;
}

textarea { min-height: 3.5rem; resize: vertical; }

input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

fieldset { border: 0; padding: 0; margin: 0; }

.checks { display: grid; gap: 0.15rem; }

.checks label {
  font-weight: 400;
  font-family: inherit;
  font-size: 1rem;
  display: flex;
  gap: 0.55rem;
  align-items: baseline;
  margin: 0;
  padding: 0.45rem 0;
}

.checks input { margin: 0; }

button[type="submit"] {
  font: inherit;
  cursor: pointer;
  background: var(--accent);
  color: var(--paper);
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.85rem 1.6rem;
  border: 1px solid var(--accent);
  border-radius: 2px;
}

button[type="submit"]:hover { background: var(--accent-lit); border-color: var(--accent-lit); }

@media (prefers-color-scheme: dark) { button[type="submit"] { color: #101010; } }

/* R40 — a reassurance, not fine print */
.reassure {
  font-size: 0.98rem;
  color: var(--ink-soft);
  border-left: 2px solid var(--rule);
  padding-left: 0.9rem;
  max-width: var(--measure);
}

/* ---------- footer ---------- */

/* R49 — the page ends at the footer's top rule, not a floating section rule. */
main section:last-of-type { border-bottom: 0; }

footer {
  border-top: 1px solid var(--rule);
  padding: 2.25rem 0 3.5rem;
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
}

footer p { max-width: var(--measure); margin-bottom: 0.55rem; }

footer a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
footer a:hover, footer a:focus-visible { color: var(--accent); }

.source {
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.83rem;
  color: var(--muted);
}

@media (max-width: 34rem) {
  body { font-size: 16px; }
  .hero { padding: 2.5rem 0 2rem; }
  .team .who { min-width: 100%; }

  /* R16 — stop the primary link being orphaned on a row of its own. */
  .masthead .wrap { padding-top: 1rem; padding-bottom: 1rem; }
  .masthead nav { gap: 0.5rem 0.9rem; font-size: 0.82rem; }
  .wordmark { margin-right: 0; width: 100%; }
}
