:root {
  --bg: #f7fbf8;
  --surface: #ffffff;
  --ink: #18241f;
  --muted: #5e6c67;
  --line: #d9e5df;
  --brand: #26736c;
  --brand-dark: #164942;
  --accent: #ca5f52;
  --accent-soft: #f3d9d5;
  --title-font: Rockwell, 'Roboto Slab', Georgia, serif;
  --body-font: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body-font);
  line-height: 1.5;
  text-size-adjust: 100%;
}

body { margin: 0; background: var(--bg); }

a {
  color: var(--brand-dark);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover { color: var(--accent); }

img { max-width: 100%; }

.wrap { width: min(1120px, calc(100% - 32px)); margin-inline: auto; }

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 2;
  padding: 10px 12px; background: var(--surface); color: var(--ink);
  border: 1px solid var(--line);
}
.skip-link:focus { top: 16px; }

.site-header {
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, white);
}

.header-inner {
  min-height: 84px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex; align-items: center; gap: 12px;
  min-width: 230px; color: var(--ink); text-decoration: none;
}

.brand-mark {
  width: 44px; height: 44px; display: grid; place-items: center;
  border: 1px solid var(--brand); color: var(--brand-dark);
  background: var(--accent-soft);
  font-family: var(--title-font); font-size: 0.9rem; font-weight: 700;
}

.brand strong, h1, h2, h3, .footer-brand {
  font-family: var(--title-font); letter-spacing: 0;
}

.brand strong { display: block; font-size: 1.3rem; line-height: 1.1; }
.brand em {
  display: block; margin-top: 4px; color: var(--muted);
  font-size: 0.8rem; font-style: normal;
}

.nav {
  display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px;
}
.nav a {
  padding: 8px 10px; color: var(--muted); text-decoration: none;
  border-bottom: 2px solid transparent;
}
.nav a[aria-current="page"] { color: var(--ink); border-color: var(--accent); }

.eyebrow {
  margin: 0 0 12px; color: var(--brand-dark);
  font-size: 0.78rem; font-weight: 800; text-transform: uppercase;
}

h1 { max-width: 850px; margin: 0; line-height: 0.96; font-weight: 700; overflow-wrap: anywhere; }

.lead, .page-heading p, .article-header p {
  max-width: 720px; color: var(--muted); font-size: 1.18rem;
}

.button-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.button {
  min-height: 44px; display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 16px; border: 1px solid var(--brand-dark);
  font: inherit; font-weight: 800; text-decoration: none; cursor: pointer;
}
.button.primary { background: var(--brand-dark); color: white; }
.button.secondary { background: transparent; color: var(--brand-dark); }

.signup-card, .article-card, .disclosure-note, .identity-panel,
.feature-article, .teaser, .journal-card {
  background: var(--surface); border: 1px solid var(--line);
}

.split-section, .signup-section, .two-column,
.related-section, .policy-page, .article-page, .page-heading {
  padding-block: 56px;
}

.article-card h2 a, .teaser h3 a, .feature-article h2 a,
.journal-card h3 a {
  color: var(--ink); text-decoration: none;
}

.signup-card { padding: 22px; }

.signup-section h2 { margin: 0 0 12px; font-size: 2.5rem; line-height: 1; }
.signup-section .signup-promise { color: var(--muted); margin-top: 6px; font-size: 0.95rem; }

.field {
  display: grid; gap: 7px; margin-bottom: 14px; font-weight: 800;
}
.field small { color: var(--muted); font-weight: 600; }
.field input {
  width: 100%; min-height: 44px; padding: 10px 12px;
  border: 1px solid var(--line); background: var(--bg);
  color: var(--ink); font: inherit;
}
.field input:focus, .check input:focus, .button:focus-visible {
  outline: 3px solid var(--accent-soft); outline-offset: 2px;
}

.check {
  display: grid; grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px; margin: 14px 0; color: var(--muted); font-size: 0.92rem;
}
.check input { width: 18px; height: 18px; margin-top: 2px; }

.bot-field { position: absolute; left: -10000px; }

.form-note, .form-status { margin-bottom: 0; font-size: 0.9rem; }
.form-status[data-state="success"] { color: var(--brand-dark); }
.form-status[data-state="error"] { color: #9a2e24; }

.article-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px; padding-bottom: 56px;
}
.article-grid.small { padding-bottom: 0; }
.article-card { padding: 24px; min-height: 280px; }
.article-card h2 { font-size: 1.75rem; }

.article-header { padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.article-body { max-width: 760px; padding-top: 28px; font-size: 1.08rem; }
.article-body p { margin: 0 0 1.25rem; }

.disclosure-note {
  max-width: 760px; margin-top: 28px; padding: 18px; color: var(--muted);
}

.two-column {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px;
}
.two-column > div { border-top: 3px solid var(--accent); padding-top: 18px; }
.two-column h2 { margin: 0 0 12px; font-size: 2.1rem; }

.policy-page { max-width: 860px; }
.policy-page h1, .page-heading h1, .article-header h1 { font-size: 4.4rem; }
.policy-updated { color: var(--muted); }
.policy-page section { padding: 28px 0; border-top: 1px solid var(--line); }
.policy-page h2 { font-size: 2rem; }

.category-pills {
  list-style: none; padding: 0; margin: 16px 0 0;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.category-pills li {
  padding: 4px 12px; border: 1px solid var(--line);
  font-size: 0.85rem; color: var(--muted);
}

.site-footer { padding: 34px 0; border-top: 1px solid var(--line); }
.footer-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, auto); gap: 24px;
}
.footer-brand { margin: 0 0 6px; color: var(--ink); font-size: 1.3rem; font-weight: 800; }
.footer-links {
  display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px 16px;
}

@media (max-width: 860px) {
  .header-inner, .footer-grid, .two-column { grid-template-columns: 1fr; }
  .header-inner { align-items: flex-start; padding-block: 16px; }
  .nav, .footer-links { justify-content: flex-start; }
  .article-grid { grid-template-columns: 1fr; }
  .policy-page h1, .page-heading h1, .article-header h1 { font-size: 3.4rem; }
  .signup-section h2 { font-size: 2rem; }
}

@media (max-width: 520px) {
  .wrap { width: min(100% - 24px, 1120px); }
  .brand strong { font-size: 1.1rem; }
  .policy-page h1, .page-heading h1, .article-header h1 { font-size: 2.8rem; }
}
/* habit-stack */
.layout-habit-stack .habit-masthead { padding: 72px 0 24px; }
.layout-habit-stack .habit-grid { max-width: 760px; margin-inline: auto; }
.layout-habit-stack .habit-masthead h1 {
  font-size: 4rem; line-height: 1.02;
}
.layout-habit-stack .habit-stack-list { padding-block: 40px; max-width: 760px; margin-inline: auto; }
.layout-habit-stack .habit-list {
  list-style: none; padding: 0; margin: 12px 0 0;
}
.layout-habit-stack .habit {
  display: grid; grid-template-columns: 84px minmax(0, 1fr);
  gap: 24px; padding: 24px;
  margin-bottom: 12px;
  background: var(--surface); border: 1px solid var(--line);
  border-left: 5px solid var(--brand);
}
.layout-habit-stack .habit-no {
  font-family: var(--title-font);
  font-size: 3rem; font-weight: 800; line-height: 1;
  color: var(--brand-dark);
}
.layout-habit-stack .habit h2 {
  margin: 4px 0 8px; font-size: 1.7rem; line-height: 1.1;
}
.layout-habit-stack .habit h2 a { color: var(--ink); text-decoration: none; }
.layout-habit-stack .habit p { margin: 0; color: var(--muted); }
.layout-habit-stack .habit-sections {
  padding-block: 32px; max-width: 760px; margin-inline: auto;
  border-top: 1px solid var(--line);
}
.layout-habit-stack .habit-section-list {
  color: var(--muted); font-weight: 600; letter-spacing: 0.02em;
}
.layout-habit-stack .signup-section {
  max-width: 760px; margin-inline: auto; display: block;
}
.layout-habit-stack .signup-card { margin-top: 16px; }
@media (max-width: 640px) {
  .layout-habit-stack .habit-masthead h1 { font-size: 2.6rem; }
  .layout-habit-stack .habit { grid-template-columns: 56px minmax(0, 1fr); gap: 14px; padding: 18px; }
  .layout-habit-stack .habit-no { font-size: 2rem; }
}
/* nav-inline (default) */