/* Scout Portal — one stylesheet, no framework.
   Dark surface, high contrast, one accent reserved for actions. */

:root {
  --bg:        #0d0f11;
  --surface:   #14181b;
  --line:      #262c31;
  --line-soft: #1c2226;
  --text:      #eef1f3;
  --text-dim:  #8b969e;
  --accent:    #ff5a1f;   /* actions only — never decoration */

  --display: ui-sans-serif, system-ui, "Helvetica Neue", Arial, sans-serif;
  --body:    ui-sans-serif, system-ui, "Helvetica Neue", Arial, sans-serif;
  --mono:    ui-monospace, SFMono-Regular, Menlo, monospace;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;   /* numbers line up */
}

/* Numbers are load-bearing here. */
.num, table.events td, table.events th {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

/* ---- top bar ---- */

.topbar {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 0 20px;
  height: 56px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
}
.wordmark span { color: var(--text-dim); margin-left: 2px; }

.topbar nav { display: flex; gap: 4px; }

.topbar nav a {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 14px;
  border: 1px solid transparent;
}
.topbar nav a:hover { color: var(--text); }
.topbar nav a.active {
  color: var(--text);
  border-color: var(--line);
  background: var(--bg);
}

/* ---- page ---- */

main { padding: 28px 20px 64px; max-width: 1100px; }

.page-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}

h1 {
  margin: 0;
  font-family: var(--display);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.count { margin: 0; color: var(--text-dim); font-size: 13px; }
.count .num { color: var(--text); font-weight: 600; }

/* ---- events table ---- */

.table-wrap { overflow-x: auto; border: 1px solid var(--line); }

table.events {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table.events th {
  text-align: left;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 10px 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

table.events td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: top;
}
table.events tr:last-child td { border-bottom: none; }

.col-at   { white-space: nowrap; color: var(--text-dim); width: 1%; }
.col-kind { white-space: nowrap; width: 1%; }

.kind {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 2px 7px;
}

/* ---- empty state: say what happens next ---- */

.empty {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 28px;
  max-width: 620px;
}
.empty-lead {
  margin: 0 0 8px;
  font-family: var(--display);
  font-size: 17px;
  font-weight: 700;
}
.empty p:last-child { margin: 0; color: var(--text-dim); }

/* Body links: the accent is for actions, and a link is an action. */
.empty a, .banner a, .hint a { color: var(--accent); }

/* ---- accessibility ---- */

a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---- phone ---- */

@media (max-width: 640px) {
  .topbar { gap: 14px; padding: 0 14px; }
  main { padding: 20px 14px 48px; }
  h1 { font-size: 21px; }
  table.events td, table.events th { padding: 10px; }
}

/* ---- submit page ---- */

.handle { color: var(--text-dim); margin-left: 6px; }

.principle {
  margin: 0 0 20px;
  color: var(--text-dim);
  font-size: 13px;
  letter-spacing: 0.03em;
}

.submit-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 620px;
  margin-bottom: 20px;
}

.submit-form label {
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-top: 10px;
}
.submit-form label .opt {
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: none;
  opacity: 0.7;
}

.submit-form input {
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  padding: 12px 13px;      /* generous hit target, used on phones */
  min-height: 46px;
  width: 100%;
}
.submit-form input::placeholder { color: #5d686f; }
.submit-form input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}

.btn-primary {
  margin-top: 16px;
  align-self: flex-start;
  background: var(--accent);
  color: #100b08;
  border: 1px solid var(--accent);
  font-family: var(--display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0 28px;
  min-height: 46px;
  cursor: pointer;
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-primary:active { filter: brightness(0.94); }

/* ---- inline result banner ---- */

.banner {
  border: 1px solid var(--line);
  border-left-width: 3px;
  background: var(--surface);
  padding: 14px 16px;
  max-width: 620px;
  margin: 0 0 24px;
}
.banner-lead { margin: 0; font-weight: 600; }
.banner-detail {
  margin: 4px 0 0;
  color: var(--text-dim);
  font-family: var(--mono);
  font-size: 12px;
}
.banner-ok   { border-left-color: #3f9d55; }
.banner-bad  { border-left-color: var(--accent); }
.banner-warn { border-left-color: #c99a2e; }
.banner p + p { margin-top: 4px; color: var(--text-dim); }

.section-head {
  font-family: var(--display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 32px 0 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

/* ---- submission status ---- */

.status {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 8px;
  border: 1px solid var(--line);
}
.status-pending { color: var(--text-dim); }
.status-used    { color: #6fd18a; border-color: #2e5b3a; }
.status-passed  { color: #8b969e; border-color: var(--line); opacity: 0.8; }

.vid {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.vid:hover { border-bottom-color: var(--accent); }
.note {
  display: block;
  margin-top: 4px;
  color: var(--text-dim);
  font-size: 13px;
}


/* ---- review screen ---- */

.review-grid {
  display: grid;
  grid-template-columns: minmax(280px, 380px) 1fr;
  gap: 28px;
  align-items: start;
}

.player iframe {
  width: 100%;
  aspect-ratio: 9 / 16;
  max-height: 62vh;
  border: 1px solid var(--line);
  background: #000;
  display: block;
}

.player-fallback {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 24px;
  text-align: center;
}
.player-fallback a { color: var(--accent); }

.player-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 8px 0 0;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-dim);
}
.player-meta a { color: var(--text); text-decoration: none; }
.player-meta a:hover { color: var(--accent); }

.scout-note {
  margin: 10px 0 0;
  padding: 10px 12px;
  border-left: 2px solid var(--line);
  color: var(--text-dim);
  font-size: 14px;
}

/* Big targets — this screen is used fast, often on a phone. */
.verdict-row { display: flex; gap: 12px; }

.btn-verdict {
  flex: 1;
  min-height: 72px;
  font-family: var(--display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.08em;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.btn-use  { background: var(--accent); border-color: var(--accent); color: #100b08; }
.btn-use:hover { filter: brightness(1.08); }
.btn-pass:hover { border-color: var(--text-dim); }

.btn-verdict kbd {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0;
  border: 1px solid currentColor;
  padding: 1px 6px;
  opacity: 0.65;
}

.hint { margin: 10px 0 0; font-size: 13px; color: var(--text-dim); }

/* Reason chips — one click each, never a dropdown. */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip { cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: inline-block;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text-dim);
  padding: 9px 13px;
  font-size: 13px;
  min-height: 38px;
  line-height: 20px;
  user-select: none;
}
.chip span:hover { color: var(--text); border-color: var(--text-dim); }
.chip input:checked + span {
  color: var(--text);
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.section-head .opt {
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: none;
  opacity: 0.7;
}

.feature-row { display: flex; flex-wrap: wrap; gap: 14px; }
.feature-row label { flex: 1 1 200px; }

.controls label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.controls select,
.controls input[type=text] {
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  letter-spacing: 0;
  text-transform: none;
  padding: 10px 11px;
  min-height: 42px;
  width: 100%;
}
.controls select:focus-visible,
.controls input[type=text]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}

.more-features summary {
  cursor: pointer;
  font-family: var(--display);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 6px 0;
}
.more-features summary:hover { color: var(--text); }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  padding-top: 10px;
}

.note-label { margin-top: 20px; }

@media (max-width: 860px) {
  .review-grid { grid-template-columns: 1fr; gap: 20px; }
  .player iframe { max-height: 54vh; }
  .btn-verdict { min-height: 64px; font-size: 19px; }
}


/* ---- sign out ---- */

.logout-form { margin: 0 0 0 8px; display: flex; align-items: center; }
.logout-form button {
  background: none;
  border: 1px solid transparent;
  color: var(--text-dim);
  font-family: var(--body);
  font-size: 14px;
  height: 34px;
  padding: 0 12px;
  cursor: pointer;
}
.logout-form button:hover { color: var(--text); border-color: var(--line); }

.banner code {
  font-family: var(--mono);
  font-size: 12px;
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 1px 5px;
  color: var(--text);
}


/* ---- earnings ---- */

/* The use rate is the quality incentive, so it gets the largest type
   on the page and sits above the money. */
.rate-block {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  background: var(--surface);
  padding: 22px 26px;
  margin-bottom: 20px;
}

.rate-figure { display: flex; flex-direction: column; }

.rate-num {
  font-family: var(--display);
  font-size: 64px;
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.02em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.rate-num .pct { font-size: 30px; color: var(--text-dim); margin-left: 2px; }
.rate-none { color: var(--text-dim); }

.rate-label {
  margin-top: 8px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.rate-detail { margin: 0; color: var(--text-dim); font-size: 14px; max-width: 40ch; }
.rate-detail strong { color: var(--text); }

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.stat {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 18px 20px;
}

.stat-num {
  font-family: var(--display);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  margin-top: 6px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.stat-note { margin-top: 3px; font-size: 12px; color: var(--text-dim); opacity: 0.8; }

.col-worth { text-align: right; white-space: nowrap; width: 1%; }
.dim { color: var(--text-dim); }

@media (max-width: 640px) {
  .rate-block { padding: 18px; gap: 16px; }
  .rate-num { font-size: 52px; }
  .stat-num { font-size: 27px; }
}


/* ---- payouts ---- */

.batch-create {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin: 16px 0 8px;
}
.batch-create .btn-primary { margin-top: 0; }
.batch-create .hint { margin: 0; max-width: 46ch; }

table.events tfoot td {
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding: 11px 14px;
}

.back-link { margin-top: 24px; }
.back-link a { color: var(--text-dim); text-decoration: none; }
.back-link a:hover { color: var(--accent); }


.rule {
  margin: -12px 0 20px;
  color: var(--text-dim);
  font-size: 13px;
  letter-spacing: 0.03em;
}


.poster-line {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--text-dim);
}
.poster-line strong { color: var(--text); font-family: var(--mono); font-size: 12px; }


/* ---- signup ---- */

.signup-form { max-width: 560px; }

.field-error {
  color: var(--accent);
  font-size: 13px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
  margin-top: -2px;
}
.field-hint {
  color: var(--text-dim);
  font-size: 12px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
}

.check {
  flex-direction: row !important;
  align-items: center;
  gap: 10px !important;
  margin-top: 22px;
  cursor: pointer;
  text-transform: none !important;
  letter-spacing: 0 !important;
  font-family: var(--body) !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  color: var(--text) !important;
}
.check input {
  width: 20px;
  height: 20px;
  min-height: 0;
  accent-color: var(--accent);
  flex: none;
}

.link-box {
  border: 1px solid var(--accent);
  background: var(--surface);
  padding: 16px 18px;
  max-width: 620px;
  overflow-x: auto;
}
.link-box code {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text);
  white-space: nowrap;
}
.go { margin-top: 24px; }
.go .btn-primary {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

/* ---- scouts roster ---- */

.scout-card {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 18px 20px;
  margin-bottom: 12px;
}
.scout-paused { opacity: 0.75; border-left: 3px solid #c99a2e; }

.scout-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.scout-name {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 700;
}
.scout-head .status { margin-left: 8px; }

.pause-form button {
  background: none;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-family: var(--body);
  font-size: 13px;
  min-height: 36px;
  padding: 0 16px;
  cursor: pointer;
}
.pause-form button:hover { color: var(--text); border-color: var(--accent); }

.pause-reason {
  margin: 10px 0 0;
  color: #d8ae52;
  font-size: 13px;
}

.scout-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--text-dim);
}
.scout-stats strong {
  color: var(--text);
  font-family: var(--display);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  margin-right: 3px;
}

.scout-detail {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 6px 14px;
  margin: 14px 0 0;
  font-size: 13px;
}
.scout-detail dt {
  font-family: var(--display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding-top: 3px;
}
.scout-detail dd { margin: 0; overflow-wrap: anywhere; }
.scout-detail code { font-family: var(--mono); font-size: 12px; }
.scout-detail .note { display: block; margin-top: 3px; }

@media (max-width: 640px) {
  .scout-detail { grid-template-columns: 1fr; gap: 2px; }
  .scout-detail dt { padding-top: 8px; }
}


.grace-note {
  margin: 10px 0 0;
  color: var(--text-dim);
  font-size: 13px;
}


/* ---- payment details on the scout's own page ---- */

.payment-nag { max-width: 620px; }
.payment-nag a { color: var(--accent); }

.payment-form { max-width: 620px; margin-bottom: 8px; }

.payment-fields {
  display: grid;
  grid-template-columns: minmax(0, 200px) minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}

.payment-form label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.payment-form select,
.payment-form input {
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  letter-spacing: 0;
  text-transform: none;
  padding: 0 11px;
  height: 44px;
  width: 100%;
}
.payment-form select:focus-visible,
.payment-form input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}
.payment-form .btn-primary { margin-top: 0; }
.payment-form .field-error {
  color: var(--accent);
  font-size: 12px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
}

.status-unpayable {
  color: #d8ae52;
  border-color: #6a5220;
  margin-left: 6px;
}
.missing { color: #d8ae52; }

@media (max-width: 640px) {
  .payment-fields { grid-template-columns: 1fr; }
}


/* ---- who can't be paid, on the payout screens ---- */

.row-unpayable td { background: rgba(201, 154, 46, 0.07); }

.pay-via {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}
.pay-to {
  display: block;
  margin-top: 2px;
  font-family: var(--mono);
  font-size: 11px;
  color: #6f7a82;
  overflow-wrap: anywhere;
}


/* ---- owner dashboard ---- */

.stats-4 { grid-template-columns: repeat(auto-fit, minmax(165px, 1fr)); }

.section-head-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.section-head-row .section-head { flex: 1 1 auto; }

.btn-small {
  height: 34px;
  min-height: 0;
  padding: 0 16px;
  font-size: 12px;
  margin: 0 0 12px;
  align-self: center;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

/* One-off decisions straight from the dashboard. */
.inline-decide { display: inline; }
.inline-decide button {
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text-dim);
  padding: 5px 10px;
  cursor: pointer;
}
.inline-decide .mini-use:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #100b08;
}
.inline-decide .mini-pass:hover { color: var(--text); border-color: var(--text-dim); }


/* ---- email verification nag ---- */

.verify-nag { max-width: 620px; }
.resend-form { margin-top: 10px; }
.resend-form button {
  background: none;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-family: var(--body);
  font-size: 13px;
  min-height: 34px;
  padding: 0 14px;
  cursor: pointer;
}
.resend-form button:hover { color: var(--text); border-color: var(--accent); }


/* ---- scout removal ---- */

.confirm-panel { max-width: 720px; }
.confirm-panel .scout-actions { margin-top: 14px; }
.owed-warning { color: #d8ae52; }

.btn-danger {
  background: none;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-family: var(--display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  min-height: 36px;
  padding: 0 18px;
  cursor: pointer;
}
.btn-danger:hover { background: var(--accent); color: #100b08; }

.confirm-panel form[method=get] button {
  background: none;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-family: var(--body);
  font-size: 13px;
  min-height: 36px;
  padding: 0 16px;
  cursor: pointer;
}

.removed-block { margin-top: 34px; }
.removed-block summary {
  cursor: pointer;
  font-family: var(--display);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.removed-block summary:hover { color: var(--text); }
.removed-block .table-wrap { margin-top: 12px; opacity: 0.85; }


/* ============================================================
   PUBLIC PAGES ONLY — landing, signup, sign in.
   Section 9 exempts these from "no illustration"; the work
   screens above keep the plain typographic treatment.
   ============================================================ */

body.public {
  /* Palette lifted from the photo: khaki, pine, and low sun. Deliberately
     warm and green-brown rather than the neutral black used on the work
     screens, so the card belongs to the landscape behind it. */
  --pub-text:    #f3eee2;
  --pub-dim:     #c2bca8;
  --pub-surface: rgba(28, 33, 24, 0.56);
  --pub-line:    rgba(203, 184, 138, 0.26);
  --pub-accent:  #e0a33f;
  --pub-ink:     #17190f;

  min-height: 100vh;
  min-height: 100dvh;
  background-color: #0e1109;
  color: var(--pub-text);
}

/* ---- the photograph and everything moving over it ---- */

.hero {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg {
  position: absolute;
  /* Flush to the viewport: the old -3% inset stacked on top of the zoom
     below and cropped the mountains and lake out of the frame. */
  inset: 0;
  background-image: url('/static/scout-hero-1800.jpg');
  background-size: cover;
  /* Keeps him right of centre as the viewport narrows. */
  background-position: 61% 45%;
  transform: scale(1.01);
  animation: kenburns 64s ease-in-out infinite;
}

/* Barely more than 1x, so the landscape stays in shot. The scale only
   exists to give the pan somewhere to go without exposing an edge. */
@keyframes kenburns {
  0%   { transform: scale(1.01) translate3d(0, 0, 0); }
  50%  { transform: scale(1.05) translate3d(-0.9%, -0.6%, 0); }
  100% { transform: scale(1.01) translate3d(0, 0, 0); }
}

/* Sky only — faded out before it reaches the treeline and mountains. */
.hero-sky {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 52%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, #000 58%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 58%, transparent 100%);
}

.cloud {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(closest-side,
    rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
  will-change: transform;
}
.cloud-1 { top: 6%;  width: 46vw; height: 15vh; opacity: 0.30; animation: drift 190s linear infinite; }
.cloud-2 { top: 22%; width: 32vw; height: 11vh; opacity: 0.22; animation: drift 260s linear infinite -70s; }
.cloud-3 { top: 13%; width: 58vw; height: 18vh; opacity: 0.16; animation: drift 320s linear infinite -180s; }

@keyframes drift {
  from { transform: translate3d(-60vw, 0, 0); }
  to   { transform: translate3d(160vw, 0, 0); }
}

/* Birds cross now and then rather than continuously: each animation spends
   most of its cycle parked off-screen at zero opacity. */
.bird {
  position: absolute;
  width: 34px;
  opacity: 0;
  will-change: transform;
}
.bird svg { width: 100%; height: auto; display: block; animation: flap 0.85s ease-in-out infinite alternate; }
.bird svg path {
  fill: none;
  stroke: rgba(14, 18, 10, 0.8);
  stroke-width: 1.7;
  stroke-linecap: round;
  /* A faint light edge so they read against dark cloud as well as blue. */
  filter: drop-shadow(0 0 1.5px rgba(255, 255, 255, 0.35));
}

/* Kept high in the frame: lower down they cross his hat rather than sky. */
.bird-1 { top: 13%; width: 50px; animation: fly-a 68s linear infinite; }
.bird-2 { top: 7%;  width: 34px; animation: fly-b 95s linear infinite -40s; }
.bird-3 { top: 19%; width: 42px; animation: fly-a 124s linear infinite -85s; }

@keyframes fly-a {
  0%   { transform: translate3d(-12vw, 0, 0);        opacity: 0; }
  2%   { opacity: 0.55; }
  14%  { opacity: 0.55; }
  17%  { transform: translate3d(112vw, -5vh, 0);     opacity: 0; }
  100% { transform: translate3d(112vw, -5vh, 0);     opacity: 0; }
}
@keyframes fly-b {
  0%   { transform: translate3d(112vw, 0, 0);        opacity: 0; }
  3%   { opacity: 0.45; }
  16%  { opacity: 0.45; }
  20%  { transform: translate3d(-12vw, 4vh, 0);      opacity: 0; }
  100% { transform: translate3d(-12vw, 4vh, 0);      opacity: 0; }
}
@keyframes flap {
  from { transform: scaleY(1); }
  to   { transform: scaleY(0.55); }
}

/* Darkens the left so the copy and card stay readable, and clears away
   toward the right so he keeps the light. */
.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    /* Eased off: at 0.94 the mountains and lake behind the copy were simply
       painted out. The card carries its own backing now, and the headline
       has a shadow, so the left doesn't need to be this dark. */
    linear-gradient(to right,
      rgba(9, 11, 7, 0.86) 0%,
      rgba(9, 11, 7, 0.74) 24%,
      rgba(9, 11, 7, 0.46) 44%,
      rgba(9, 11, 7, 0.16) 64%,
      rgba(9, 11, 7, 0.00) 84%),
    linear-gradient(to bottom,
      rgba(9, 11, 7, 0.34) 0%,
      rgba(9, 11, 7, 0.00) 26%,
      rgba(9, 11, 7, 0.00) 68%,
      rgba(9, 11, 7, 0.40) 100%);
}

.public-main {
  position: relative;
  z-index: 1;
  padding: 0;
  max-width: none;
}

/* ---- landing: copy and card in the darkened left column ---- */

.landing {
  display: grid;
  grid-template-columns: minmax(0, 540px) minmax(0, 1fr);
  align-items: center;
  height: 100dvh;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px 0 clamp(24px, 5vw, 76px);
}

.landing-left { min-width: 0; }

.landing-narrow {
  display: block;
  height: auto;
  max-width: 540px;
  padding: 56px clamp(24px, 5vw, 76px) 72px;
  margin: 0;
}

.eyebrow {
  margin: 0 0 12px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--pub-accent);
}

.landing-head {
  margin: 0 0 12px;
  font-family: var(--display);
  font-size: clamp(30px, 3.6vw, 50px);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--pub-text);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.55);
}

.landing-sub {
  margin: 0;
  max-width: 42ch;
  color: var(--pub-dim);
  font-size: 15px;
  line-height: 1.5;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.5);
}

.landing-copy { margin-bottom: 22px; }

/* ---- the card ---- */

.card {
  position: relative;
  background: var(--pub-surface);
  /* Warm hairline, low enough to read as an edge rather than a frame. */
  border: 1px solid rgba(219, 197, 148, 0.16);
  border-radius: 14px;
  /* More blur to carry the extra translucency: the landscape shows through
     without the fields losing contrast. */
  backdrop-filter: blur(20px) saturate(118%);
  -webkit-backdrop-filter: blur(20px) saturate(118%);
  /* Two shadows: a wide soft one to lift it off the photo, a tighter one
     to seat it. */
  box-shadow:
    0 28px 70px rgba(0, 0, 0, 0.50),
    0 6px 18px rgba(0, 0, 0, 0.32);
  padding: 20px 22px 18px;
}

.card-solo { max-width: 460px; }

.signup-form { display: flex; flex-direction: column; gap: 10px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.form-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }

.form-field label,
.card .submit-form label {
  font-family: var(--display);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pub-dim);
  margin: 0;
}
.form-field label .opt {
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: none;
  opacity: 0.65;
}

.form-field select,
.form-field input,
.card .submit-form input {
  background: rgba(12, 15, 9, 0.62);
  border: 1px solid rgba(203, 184, 138, 0.22);
  color: var(--pub-text);
  font-family: var(--body);
  font-size: 14px;
  padding: 0 10px;
  height: 36px;
  min-height: 0;
  width: 100%;
  border-radius: 7px;
}
.form-field input::placeholder { color: #8d8b78; }
.form-field select:focus-visible,
.form-field input:focus-visible,
.card .submit-form input:focus-visible {
  outline: 2px solid var(--pub-accent);
  outline-offset: 1px;
  border-color: var(--pub-accent);
}

.form-field select {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  padding-right: 28px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--pub-dim) 50%),
    linear-gradient(135deg, var(--pub-dim) 50%, transparent 50%);
  background-size: 5px 5px, 5px 5px;
  background-position: right 13px center, right 8px center;
  background-repeat: no-repeat;
}
/* The dropdown list itself is drawn by the OS, so it needs real colours. */
.form-field select option { background: #1b2018; color: var(--pub-text); }

.field-error {
  color: var(--pub-accent);
  font-size: 11.5px;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 400;
}

.card .check {
  flex-direction: row !important;
  align-items: center;
  gap: 9px !important;
  margin: 2px 0 0;
  cursor: pointer;
  text-transform: none !important;
  letter-spacing: 0 !important;
  font-family: var(--body) !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  color: var(--pub-dim) !important;
}
.card .check input {
  width: 17px;
  height: 17px;
  min-height: 0;
  accent-color: var(--pub-accent);
  flex: none;
}

.card .btn-primary {
  border-radius: 8px;
  margin: 6px 0 0;
  align-self: stretch;
  height: 42px;
  min-height: 0;
  font-size: 13px;
  letter-spacing: 0.12em;
  background: var(--pub-accent);
  border-color: var(--pub-accent);
  color: var(--pub-ink);
}
.card .btn-primary:hover { filter: brightness(1.07); }

.card .banner { max-width: none; margin-bottom: 14px; }

.card-foot {
  margin: 12px 0 0;
  padding-top: 11px;
  border-top: 1px solid var(--pub-line);
  font-size: 13px;
  color: var(--pub-dim);
}
.card-foot a { color: var(--pub-accent); text-decoration: none; }
.card-foot a:hover { text-decoration: underline; }

.link-box {
  border-radius: 8px;
  border: 1px solid var(--pub-accent);
  background: rgba(12, 15, 9, 0.6);
  padding: 14px 16px;
  overflow-x: auto;
}
.link-box code { font-family: var(--mono); font-size: 14px; color: var(--pub-text); white-space: nowrap; }
.go { margin-top: 20px; }
.go .btn-primary {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  background: var(--pub-accent);
  border-color: var(--pub-accent);
  color: var(--pub-ink);
}
.public .hint { color: var(--pub-dim); }

/* ---- phone: card over the image, much stronger scrim, less motion ---- */

@media (max-width: 900px) {
  .hero-bg {
    background-image: url('/static/scout-hero-1000.jpg');
    background-position: 62% center;
    /* A slow pan on a phone is mostly wasted battery. */
    animation: none;
    transform: scale(1.03);
  }
  /* Birds are a few pixels wide here and read as dirt on the screen. */
  .bird { display: none; }
  .cloud-2, .cloud-3 { display: none; }
  .cloud-1 { opacity: 0.18; animation-duration: 260s; }

  .hero-scrim {
    background:
      linear-gradient(to bottom,
        rgba(9, 11, 7, 0.72) 0%,
        rgba(9, 11, 7, 0.80) 45%,
        rgba(9, 11, 7, 0.92) 100%);
  }

  .landing {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 100dvh;
    padding: 30px 16px 40px;
    align-content: center;
  }
  .card {
    padding: 18px 16px 16px;
    /* The phone scrim is already heavy; a near-transparent card on top of
       it turns the fields to mud. */
    background: rgba(24, 29, 20, 0.68);
  }
  .landing-narrow { padding: 34px 18px 56px; }
}

@media (max-width: 560px) {
  .form-row { grid-template-columns: 1fr; gap: 10px; }
}

@media (min-width: 901px) and (max-height: 680px) {
  .landing { height: auto; min-height: 100dvh; padding-top: 40px; padding-bottom: 40px; }
}

/* Section 9: no animation at all when reduced motion is asked for. */
@media (prefers-reduced-motion: reduce) {
  /* Same framing everyone else gets, just held still. */
  .hero-bg { animation: none; transform: scale(1.01); }
  .cloud, .bird, .bird svg { animation: none; }
  .bird { display: none; }
  /* The blur stays: it is not motion, and without it a 56%-opaque card
     leaves the labels sitting on bare photograph. */
}


/* ---- password show/hide, Turnstile, roster actions ---- */

.pw-toggle[hidden] { display: none; }
.pw-toggle {
  align-self: flex-start;
  background: none;
  border: none;
  padding: 0;
  margin: -2px 0 0;
  color: var(--pub-dim);
  font-family: var(--body);
  font-size: 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.pw-toggle:hover { color: var(--pub-accent); }

.cf-turnstile { margin: 4px 0 0; min-height: 65px; }

.scout-actions { display: flex; gap: 8px; flex-wrap: wrap; }


/* ---- public top nav, sitting over the photograph ---- */

.site-nav {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 2;
  display: flex;
  /* Only one thing lives here now. */
  justify-content: flex-end;
  padding: 18px clamp(16px, 5vw, 76px);
  background: linear-gradient(to bottom,
    rgba(9, 11, 7, 0.42) 0%, rgba(9, 11, 7, 0) 100%);
}

/* Filled, but a deeper gold than SIGN UP: present and easy to hit without
   competing with the page's main action. */
.btn-nav {
  display: inline-flex;
  align-items: center;
  height: 46px;
  padding: 0 26px;
  border: 1px solid #b8801f;
  border-radius: 9px;
  background: #b8801f;
  color: #17190f;
  font-family: var(--display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
}
.btn-nav:hover { background: #c9902a; border-color: #c9902a; }

/* Keep the narrow pages clear of the bar. */
.landing-narrow { padding-top: 96px; }

@media (max-width: 900px) {
  .site-nav { padding: 14px 16px; }
  .btn-nav { height: 42px; padding: 0 20px; font-size: 12.5px; }
  .landing { padding-top: 76px; }
  .landing-narrow { padding-top: 84px; }
}
