/*
 * Mission Broadcast docs — landing-page styles (MB-145, Pass 6).
 *
 * Implements design-spec.md §5 (search-centric landing): warm-paper hero with a
 * prominent search box, color-coded role cards (parent=navy / missionary=sage /
 * subscriber=coral), a common-tasks index on a sage-tint band, and the
 * "how the pieces fit" explainer. Matches landing-mockup.html (light) and
 * landing-mockup-dark.html (dark).
 *
 * All styling is scoped to `.mb-home` (the wrapper in index.md) so it never
 * touches content pages. Palette tokens come from extra.css (--lp-*).
 * No inline styles — CSP-readiness rule.
 */

/* Let the bands run full-bleed out of Material's centered content column, and
   drop the page's default top/side gutters on the home page. */
.md-content .mb-home {
  margin: -1.2rem 0 0;   /* pull up over Material's content top padding */
}

.mb-home .mb-band {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: clamp(56px, 8vw, 96px) 24px;
}

.mb-home .mb-band-in {
  max-width: 1100px;
  margin: 0 auto;
}

/* ── Hero band — warm paper, search-forward (§5.1) ─────────────────────── */
.mb-home .mb-hero {
  background: var(--lp-surface-warm);
  padding: clamp(56px, 9vw, 104px) 24px;
  position: relative;
  overflow: hidden;
}

/* The standalone decorative SVG gets wrapped in a <p> by Markdown; zero its
   box so it doesn't add flow height (it's absolutely positioned anyway). */
.mb-home .mb-hero > p {
  margin: 0;
}

/* No ¶ permalinks on the landing hero/section headings — they're display
   copy, not anchored doc sections. */
.mb-home .headerlink {
  display: none;
}

.mb-home .mb-hero-deco {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.16;
  pointer-events: none;
}

.mb-home .mb-hero-in {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 1;
}

.mb-home .mb-eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lp-accent);
  margin: 0 0 16px;
}

.mb-home .mb-hero h1 {
  font-family: var(--lp-font-headline);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 700;
  color: var(--lp-accent-deep);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 16px;
}

.mb-home .mb-lede {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--lp-text-soft);
  max-width: 34em;
  margin: 0 auto 32px;
  line-height: 1.55;
}

/* The hero search — a styled wrapper around Material's real search input,
   relocated here by home-search.js (§5.1: wire to Material's built-in search). */
.mb-home .mb-search {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 560px;
  margin: 0 auto;
  background: var(--lp-surface);
  border: 1.5px solid var(--lp-accent);
  border-radius: 999px;
  padding: 0 20px;
  height: 56px;
  box-shadow: 0 1px 3px rgba(20, 40, 63, 0.06);
}

.mb-home .mb-search:focus-within {
  outline: 2px solid var(--lp-accent-3);
  outline-offset: 2px;
}

.mb-home .mb-search svg {
  flex: none;
  color: var(--lp-accent);
}

.mb-home .mb-search input {
  flex: 1;
  border: 0;
  background: transparent;
  font-family: inherit;
  font-size: 16px;
  color: var(--lp-text);
  height: 54px;
}

.mb-home .mb-search input:focus {
  outline: none;
}

.mb-home .mb-search input::placeholder {
  color: var(--lp-text-muted);
}

/* ── Section primitives ────────────────────────────────────────────────── */
.mb-home .mb-band-sage {
  background: var(--lp-section-sage);
}

.mb-home .mb-sec-eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  color: var(--lp-accent);
  margin: 0 0 10px;
}

.mb-home .mb-band h2 {
  font-family: var(--lp-font-headline);
  font-size: clamp(26px, 3.5vw, 38px);
  font-weight: 700;
  color: var(--lp-accent-deep);
  text-align: center;
  margin: 0 0 40px;
  letter-spacing: -0.01em;
}

/* ── Role cards — color-coded system (§5.2) ────────────────────────────── */
.mb-home .mb-roles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.mb-home .mb-role {
  background: var(--lp-surface);
  border: 1px solid var(--lp-border);
  border-top: 5px solid var(--lp-accent);   /* navy / parent */
  border-radius: 24px;
  padding: 30px 26px;
  box-shadow: 0 1px 3px rgba(20, 40, 63, 0.06);
  transition: transform 160ms ease, box-shadow 160ms ease;
  display: block;
  color: var(--lp-text);
  text-decoration: none;
}

.mb-home .mb-role:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(20, 40, 63, 0.08);
}

.mb-home .mb-role.sage {
  border-top-color: var(--lp-accent-2);
}

.mb-home .mb-role.coral {
  border-top-color: var(--lp-accent-3);
}

.mb-home .mb-chip {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--lp-accent-soft);
  color: var(--lp-accent);
  margin-bottom: 16px;
}

.mb-home .mb-role.sage .mb-chip {
  background: var(--lp-accent-2-soft);
  color: var(--lp-accent-2-deep);
}

.mb-home .mb-role.coral .mb-chip {
  background: var(--lp-accent-3-soft);
  color: var(--lp-accent-3-deep);
}

.mb-home .mb-role-title {
  display: block;
  font-family: var(--lp-font-headline);
  font-size: 22px;
  font-weight: 700;
  color: var(--lp-accent-deep);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.mb-home .mb-role-text {
  display: block;
  color: var(--lp-text-soft);
  margin: 0 0 16px;
}

.mb-home .mb-role .mb-go {
  font-weight: 600;
  color: var(--lp-accent);
}

.mb-home .mb-role.sage .mb-go {
  color: var(--lp-accent-2-deep);
}

.mb-home .mb-role.coral .mb-go {
  color: var(--lp-accent-3-deep);
}

/* ── Common tasks — tidy rows on the sage band (§5.3) ──────────────────── */
.mb-home .mb-tasks {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 40px;
  max-width: 760px;
  margin: 0 auto;
}

@media (max-width: 680px) {
  .mb-home .mb-tasks {
    grid-template-columns: 1fr;
  }
}

.mb-home .mb-task {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--lp-surface);
  border: 1px solid var(--lp-border);
  border-radius: 10px;
}

.mb-home .mb-task svg {
  flex: none;
  color: var(--lp-accent);
}

.mb-home .mb-task a {
  font-weight: 500;
  color: var(--lp-accent);
  text-decoration: none;
}

.mb-home .mb-task a:hover {
  color: var(--lp-accent-3-deep);
  text-decoration: underline;
}

/* ── "How the pieces fit" explainer (§5.4) ─────────────────────────────── */
.mb-home .mb-pieces {
  max-width: 760px;
  margin: 0 auto;
}

.mb-home .mb-pieces h2 {
  text-align: left;
  margin-bottom: 18px;
}

.mb-home .mb-pieces ul {
  list-style: disc;
  padding-left: 1.25em;
}

.mb-home .mb-pieces li {
  margin-bottom: 10px;
  color: var(--lp-text);
}

.mb-home .mb-pieces code {
  background: var(--lp-surface-warm);
  border: 1px solid var(--lp-border);
  border-radius: 4px;
  padding: 0.1em 0.35em;
  font-size: 0.85em;
  color: var(--lp-accent-deep);
}

/* ===========================================================================
 * DARK MODE — landing (design-spec §2.2). Bands, cards, search recolored for
 * the deep-navy field; every text/bg pairing ≥ AA.
 * ========================================================================= */
[data-md-color-scheme="slate"] .mb-home .mb-hero {
  background: #16293f;
}

[data-md-color-scheme="slate"] .mb-home .mb-hero-deco {
  opacity: 0.22;
}

[data-md-color-scheme="slate"] .mb-home .mb-eyebrow,
[data-md-color-scheme="slate"] .mb-home .mb-sec-eyebrow {
  color: #f0a9a6;   /* coral-light 8.4:1 */
}

[data-md-color-scheme="slate"] .mb-home .mb-hero h1,
[data-md-color-scheme="slate"] .mb-home .mb-band h2 {
  color: #f4efe7;
}

[data-md-color-scheme="slate"] .mb-home .mb-lede {
  color: #c2bcae;
}

[data-md-color-scheme="slate"] .mb-home .mb-search {
  background: #0f2236;
  border-color: #5e7da4;   /* 3.8:1 structural */
}

[data-md-color-scheme="slate"] .mb-home .mb-search svg {
  color: #a8c2a4;
}

[data-md-color-scheme="slate"] .mb-home .mb-search input {
  color: #e8e3d8;
}

[data-md-color-scheme="slate"] .mb-home .mb-search input::placeholder {
  color: #a59f92;
}

[data-md-color-scheme="slate"] .mb-home .mb-search:focus-within {
  outline-color: #f0a9a6;
}

[data-md-color-scheme="slate"] .mb-home .mb-band-sage {
  background: #14302a;
}

/* Role cards: top-border accents must clear 3:1 on the #16293f card
   (a11y-review §4 P2 #6): navy #6f8fb5 (4.41), coral #e0716c (4.74), sage
   #a8c2a4 (7.67). Icon + arrow use the lighter accents. */
[data-md-color-scheme="slate"] .mb-home .mb-role {
  background: #16293f;
  border-color: #26405c;
  border-top-color: #6f8fb5;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.sage {
  border-top-color: #a8c2a4;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.coral {
  border-top-color: #e0716c;
}

[data-md-color-scheme="slate"] .mb-home .mb-chip {
  background: #16314c;
  color: #bcd2ec;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.sage .mb-chip {
  background: #1c3320;
  color: #a8c2a4;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.coral .mb-chip {
  background: #3a1e1d;
  color: #f0a9a6;
}

[data-md-color-scheme="slate"] .mb-home .mb-role-title {
  color: #f4efe7;
}

[data-md-color-scheme="slate"] .mb-home .mb-role-text {
  color: #c2bcae;
}

[data-md-color-scheme="slate"] .mb-home .mb-role .mb-go {
  color: #bcd2ec;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.sage .mb-go {
  color: #a8c2a4;
}

[data-md-color-scheme="slate"] .mb-home .mb-role.coral .mb-go {
  color: #f0a9a6;
}

[data-md-color-scheme="slate"] .mb-home .mb-task {
  background: #16293f;
  border-color: #26405c;
}

[data-md-color-scheme="slate"] .mb-home .mb-task svg,
[data-md-color-scheme="slate"] .mb-home .mb-task a {
  color: #a8c2a4;
}

[data-md-color-scheme="slate"] .mb-home .mb-task a:hover {
  color: #f0a9a6;
}

[data-md-color-scheme="slate"] .mb-home .mb-pieces li {
  color: #e8e3d8;
}

[data-md-color-scheme="slate"] .mb-home .mb-pieces code {
  background: #16293f;
  border-color: #26405c;
  color: #e8e3d8;
}
