/*
 * Mom Knows public site. Warm Family palette from the app (lib/design/mk_colors.dart),
 * with the primary action darkened so white text on it meets WCAG AA contrast.
 */
:root {
  --canvas: #fbf7f2;
  --canvas-deep: #f3ece4;
  --surface: #ffffff;
  --border: #eee6dd;
  --border-strong: #dfd4c8;
  --navy: #1f2a44;
  --text: #34405e;
  --text-muted: #5b6275;
  --coral: #dd6b5e;
  --coral-action: #b5483d;
  --coral-action-pressed: #9c3c33;
  --coral-tint: #fdeeea;
  --coral-border: #f6d2ca;
  --link: #4353a8;
  --handled: #2e8566;
  --handled-tint: #e9f6ef;
  --handled-border: #cde8da;
  --attention: #b23830;
  --attention-tint: #fdedeb;
  --attention-border: #f5d0cb;
  --sunshine-tint: #fff7df;
  --amber-border: #f6ddb5;
  --focus: #4353a8;
  --radius: 16px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
}

.wrap {
  width: 100%;
  max-width: 46rem;
  margin: 0 auto;
  padding-inline: 1.25rem;
}

a {
  color: var(--link);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--navy);
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  padding: 0.5rem 0.875rem;
  background: var(--navy);
  color: #fff;
  border-radius: 10px;
  z-index: 10;
}

.skip-link:focus {
  top: 1rem;
  color: #fff;
}

.draft-banner {
  background: var(--sunshine-tint);
  border-bottom: 1px solid var(--amber-border);
  color: var(--navy);
  font-size: 0.9375rem;
  padding: 0.625rem 1.25rem;
  text-align: center;
}

/* ------------------------------------------------------------ header */

.site-header {
  padding-block: 1.5rem 0.5rem;
}

/* The approved wordmark artwork (assets/brand), never redrawn. Height set, width follows. */
.brand {
  display: inline-block;
  border-radius: 8px;
}

.brand-logo {
  display: block;
  width: auto;
  height: 2.5rem;
}

main {
  padding-block: 1.5rem 3.5rem;
}

/* ---------------------------------------------------------- document */

.eyebrow {
  margin: 0 0 0.375rem;
  color: var(--coral-action);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  color: var(--navy);
  line-height: 1.25;
  letter-spacing: -0.015em;
}

h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 6vw, 2.625rem);
  letter-spacing: -0.03em;
}

h2 {
  margin: 2.75rem 0 0.75rem;
  font-size: 1.5rem;
}

h3 {
  margin: 1.75rem 0 0.5rem;
  font-size: 1.1875rem;
}

p,
ul,
ol {
  margin: 0 0 1rem;
}

ul,
ol {
  padding-left: 1.25rem;
}

li + li {
  margin-top: 0.375rem;
}

.lede {
  font-size: 1.1875rem;
  color: var(--text);
}

.dates {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 0 0 1.25rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.dates div {
  display: flex;
  gap: 0.375rem;
}

.dates dt {
  font-weight: 600;
  color: var(--navy);
}

.dates dd {
  margin: 0;
}

section[id] {
  scroll-margin-top: 1rem;
}

.app-identity {
  padding: 0.75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 0.9375rem;
}

/* ---------------------------------------------------------- surfaces */

.card {
  margin: 1.75rem 0;
  padding: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(31, 42, 68, 0.04), 0 8px 24px rgba(31, 42, 68, 0.05);
}

.card > h2:first-child {
  margin-top: 0;
}

.callout {
  margin: 1.75rem 0;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--coral-border);
  background: var(--coral-tint);
}

.callout h2 {
  margin: 0 0 0.375rem;
  font-size: 1.25rem;
}

.callout p:last-child {
  margin-bottom: 0;
}

.toc {
  margin: 2rem 0;
  padding: 1.25rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.toc h2 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.toc ol {
  margin: 0;
  columns: 2 16rem;
  column-gap: 2rem;
}

.toc li {
  break-inside: avoid;
}

.status-note {
  display: inline-block;
  margin: 0 0 0.5rem;
  padding: 0.125rem 0.625rem;
  border-radius: 999px;
  background: var(--canvas-deep);
  color: var(--navy);
  font-size: 0.8125rem;
  font-weight: 600;
}

.launch-decision {
  display: block;
  margin: 1rem 0;
  padding: 0.75rem 1rem;
  border: 2px dashed #c98a22;
  border-radius: 12px;
  background: var(--sunshine-tint);
  color: var(--navy);
  font-size: 0.9375rem;
}

mark.launch-decision {
  display: inline;
  margin: 0;
  padding: 0.0625rem 0.375rem;
  border-width: 1px;
  border-radius: 6px;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 2.75rem;
  min-height: 2rem;
}

.steps li + li {
  margin-top: 0.875rem;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  font-size: 0.9375rem;
  display: grid;
  place-items: center;
}

.compare {
  display: grid;
  gap: 0.875rem;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  margin: 1rem 0;
}

.compare-item {
  padding: 1rem 1.125rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.compare-item h3 {
  margin: 0 0 0.375rem;
  font-size: 1.0625rem;
}

.compare-item p {
  margin: 0;
  font-size: 0.9688rem;
}

.compare-item-strong {
  border-color: var(--coral-border);
  background: var(--coral-tint);
}

/* ------------------------------------------------------------- forms */

.form {
  display: grid;
  gap: 1rem;
}

.card.form > p,
.card.form > ul {
  margin: 0;
}

.field {
  display: grid;
  gap: 0.375rem;
}

.field label {
  color: var(--navy);
  font-weight: 600;
}

.field input[type='email'],
.field input[type='password'] {
  width: 100%;
  min-height: 3rem;
  padding: 0.625rem 0.875rem;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  background: var(--surface);
  color: var(--navy);
  font: inherit;
}

.field input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 1px;
  border-color: var(--focus);
}

.field-hint {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.field-check {
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.625rem;
}

.field-check input {
  width: 1.25rem;
  height: 1.25rem;
  margin: 0.25rem 0 0;
  accent-color: var(--coral-action);
}

.field-check label {
  font-weight: 500;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.375rem;
  border: 0;
  border-radius: 12px;
  background: var(--coral-action);
  color: #fff;
  font: inherit;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
  justify-self: start;
}

.button:hover {
  background: var(--coral-action-pressed);
  color: #fff;
}

.button:disabled {
  opacity: 0.6;
  cursor: progress;
}

.button-danger {
  background: var(--attention);
}

.button-danger:hover {
  background: #8f2c25;
}

.form-status {
  margin: 0;
  min-height: 1.5rem;
  color: var(--attention);
  font-weight: 600;
}

.form-status:empty {
  min-height: 0;
}

.notice {
  margin: 1.75rem 0;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
}

.notice:focus {
  outline: none;
}

.notice h2,
.notice h3 {
  margin-top: 0;
}

.notice p:last-child {
  margin-bottom: 0;
}

.notice-success {
  border-color: var(--handled-border);
  background: var(--handled-tint);
}

.notice-error {
  border-color: var(--attention-border);
  background: var(--attention-tint);
}

.fallback {
  margin: 1rem 0 0;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.invitation {
  display: grid;
  gap: 0.25rem 1rem;
  grid-template-columns: max-content 1fr;
  margin: 1rem 0;
}

.invitation dt {
  color: var(--text-muted);
}

.invitation dd {
  margin: 0;
  color: var(--navy);
  font-weight: 600;
}

/* ------------------------------------------------------------ footer */

.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2rem 2.5rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin-bottom: 0.75rem;
}

.footer-nav a {
  color: var(--navy);
  font-weight: 600;
}

.footer-note {
  margin: 0;
}

@media (max-width: 30rem) {
  body {
    font-size: 1rem;
  }

  .card,
  .callout,
  .notice,
  .toc {
    padding: 1.125rem;
  }

  .button {
    width: 100%;
  }
}

@media print {
  .site-header,
  .site-footer,
  .skip-link,
  .draft-banner,
  .callout .button {
    display: none;
  }
}
