:root {
  color-scheme: light;
  --forest-950: #102e28;
  --forest-900: #173f36;
  --forest-800: #205248;
  --forest-700: #2b6659;
  --leaf-500: #3f806d;
  --cream-50: #fffdf7;
  --cream-100: #f7f1e5;
  --cream-200: #eadfcd;
  --cream-300: #d8c9b2;
  --gold-500: #a87a2d;
  --gold-300: #d7b86e;
  --ink: #1d2522;
  --muted: #626c67;
  --danger: #9f3b35;
  --success: #2f6c4f;
  --white: #ffffff;
  --shadow: 0 20px 50px rgba(23, 63, 54, 0.1);
  --max: 72rem;
  --reading: 44rem;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-width: 20rem;
  background: var(--cream-50);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.55;
}

body::before {
  position: fixed;
  inset: 0 0 auto;
  z-index: -1;
  height: 17rem;
  background: var(--forest-900);
  content: "";
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: var(--forest-800);
}

img,
canvas {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  color: var(--forest-950);
  font-family: Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.08;
}

h1 {
  margin-bottom: 1rem;
  font-size: clamp(2.35rem, 10vw, 5.4rem);
}

h2 {
  margin-bottom: 0.75rem;
  font-size: clamp(1.8rem, 6vw, 3rem);
}

h3 {
  margin-bottom: 0.5rem;
  font-size: 1.35rem;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  translate: 0 -160%;
  border: 2px solid var(--gold-300);
  border-radius: 0.35rem;
  background: var(--white);
  font-weight: 800;
}

.skip-link:focus {
  translate: 0;
}

.site-header {
  position: relative;
  z-index: 20;
  color: var(--white);
}

.header-inner {
  display: flex;
  max-width: var(--max);
  margin: 0 auto;
  padding: max(1rem, env(safe-area-inset-top)) 1rem 1rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.wordmark {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.45rem;
  color: var(--white);
  font-size: 1.12rem;
  font-weight: 850;
  line-height: 1;
  text-decoration: none;
}

.wordmark-mark {
  display: grid;
  width: 2rem;
  height: 2rem;
  flex: 0 0 2rem;
  place-items: center;
  border: 2px solid var(--gold-300);
  border-radius: 50%;
  color: var(--gold-300);
  font-size: 1.45rem;
}

.wordmark-dot {
  color: var(--gold-300);
}

.wordmark-section {
  display: none;
  padding-left: 0.55rem;
  border-left: 1px solid rgba(255, 255, 255, 0.38);
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.8rem;
  font-weight: 650;
  letter-spacing: 0.03em;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem;
}

.site-nav a {
  display: inline-flex;
  min-width: 2.75rem;
  min-height: 2.75rem;
  padding: 0.45rem 0.35rem;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none;
}

.site-nav a:first-child {
  display: none;
}

.site-nav a[aria-current="page"] {
  color: var(--gold-300);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.38rem;
}

#app {
  min-height: calc(100vh - 10rem);
  outline: none;
}

.page-shell,
.hero-inner,
.profile-shell,
.dashboard-shell {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding-right: 1rem;
  padding-left: 1rem;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 3rem 0 4rem;
  background: var(--forest-900);
  color: var(--white);
}

.hero::after {
  position: absolute;
  right: -4.5rem;
  bottom: -7rem;
  width: 17rem;
  height: 17rem;
  border: 1px solid rgba(215, 184, 110, 0.45);
  border-radius: 50%;
  box-shadow: 0 0 0 2.7rem rgba(215, 184, 110, 0.06), 0 0 0 5.4rem rgba(215, 184, 110, 0.04);
  content: "";
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.hero h1,
.hero h2 {
  max-width: 11em;
  color: var(--white);
}

.hero-lead {
  max-width: 38rem;
  margin-bottom: 1.75rem;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1.08rem, 3vw, 1.35rem);
}

.eyebrow {
  margin-bottom: 0.8rem;
  color: var(--gold-300);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.hero-actions,
.button-row,
.share-actions,
.story-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.button,
button.button {
  display: inline-flex;
  min-height: 3rem;
  padding: 0.75rem 1rem;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border: 1px solid transparent;
  border-radius: 0.55rem;
  background: var(--forest-900);
  color: var(--white);
  font-weight: 780;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background: var(--forest-800);
}

.button.primary-on-dark {
  background: var(--gold-300);
  color: var(--forest-950);
}

.button.primary-on-dark:hover {
  background: #e3ca8e;
}

.button.secondary-on-dark {
  border-color: rgba(255, 255, 255, 0.58);
  background: transparent;
}

.button.secondary,
button.button.secondary {
  border-color: var(--forest-800);
  background: transparent;
  color: var(--forest-900);
}

.button.secondary:hover {
  background: var(--cream-100);
}

.button.quiet,
button.button.quiet {
  border-color: var(--cream-300);
  background: var(--cream-50);
  color: var(--forest-900);
}

.button.small {
  min-height: 2.65rem;
  padding: 0.6rem 0.8rem;
  font-size: 0.92rem;
}

.button:disabled,
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.mission-math-wrap {
  padding: 0 1rem;
  background: var(--cream-100);
}

.mission-math {
  display: grid;
  position: relative;
  z-index: 2;
  max-width: 52rem;
  margin: -1.7rem auto 0;
  padding: 1.2rem 0.75rem;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: center;
  border: 1px solid var(--cream-200);
  border-radius: 0.8rem;
  background: var(--white);
  box-shadow: var(--shadow);
  text-align: center;
}

.mission-math strong {
  display: block;
  color: var(--forest-900);
  font-family: Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-size: clamp(1.65rem, 6vw, 2.65rem);
  font-weight: 600;
  line-height: 1;
}

.mission-math small {
  display: block;
  margin-top: 0.3rem;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.2;
}

.mission-arrow {
  color: var(--gold-500);
  font-size: 1.35rem;
}

.content-section {
  padding: 4rem 0;
}

.content-section.tinted {
  background: var(--cream-100);
}

.section-heading {
  max-width: var(--reading);
  margin-bottom: 2rem;
}

.section-heading p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.principles-grid,
.link-grid,
.metric-grid,
.circle-grid {
  display: grid;
  gap: 1rem;
}

.principle,
.card,
.link-card,
.metric-card,
.person-card,
.state-card,
.share-panel,
.story-kit,
.bio-kit {
  border: 1px solid var(--cream-200);
  border-radius: 0.8rem;
  background: var(--white);
  box-shadow: 0 10px 30px rgba(23, 63, 54, 0.05);
}

.principle,
.card,
.metric-card,
.person-card,
.state-card,
.share-panel,
.story-kit,
.bio-kit {
  padding: 1.25rem;
}

.principle-number {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--gold-500);
  font-family: Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-size: 1.65rem;
}

.principle p,
.card p,
.person-card p {
  margin-bottom: 0;
  color: var(--muted);
}

.page-intro {
  padding: 3rem 0 2rem;
  background: var(--forest-900);
  color: var(--white);
}

.page-intro h1,
.page-intro h2 {
  color: var(--white);
}

.page-intro p:not(.eyebrow) {
  max-width: var(--reading);
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.1rem;
}

.surface {
  margin-bottom: 4rem;
  padding: 1.2rem;
  border: 1px solid var(--cream-200);
  border-radius: 0.9rem;
  background: var(--cream-50);
  box-shadow: var(--shadow);
}

.prose {
  max-width: var(--reading);
  margin-right: auto;
  margin-left: auto;
}

.prose h2:not(:first-child) {
  margin-top: 2.25rem;
}

.form-grid {
  display: grid;
  gap: 1rem;
}

.field {
  display: grid;
  gap: 0.42rem;
}

.field label,
.field legend {
  color: var(--forest-950);
  font-size: 0.92rem;
  font-weight: 780;
}

.field-hint,
.fine-print,
.muted {
  color: var(--muted);
  font-size: 0.88rem;
}

input,
select,
textarea {
  width: 100%;
  min-height: 3rem;
  padding: 0.72rem 0.8rem;
  border: 1px solid var(--cream-300);
  border-radius: 0.45rem;
  background: var(--white);
  color: var(--ink);
}

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

.check-field {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.7rem;
  align-items: start;
}

.check-field input {
  width: 1.15rem;
  min-height: 1.15rem;
  margin-top: 0.2rem;
  accent-color: var(--forest-800);
}

.form-status,
.action-status {
  min-height: 1.5rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.form-status.error,
.action-status.error {
  color: var(--danger);
}

.form-status.success,
.action-status.success {
  color: var(--success);
}

.route-loading {
  display: grid;
  min-height: 26rem;
  place-content: center;
  background: var(--cream-100);
  color: var(--muted);
  text-align: center;
}

.loading-mark {
  width: 2.4rem;
  height: 2.4rem;
  margin: 0 auto 1rem;
  border: 3px solid var(--cream-300);
  border-top-color: var(--forest-800);
  border-radius: 50%;
  animation: spin 0.85s linear infinite;
}

@keyframes spin {
  to { transform: rotate(1turn); }
}

.state-card {
  max-width: 40rem;
  margin: 2rem auto 5rem;
  text-align: center;
}

.state-symbol {
  display: grid;
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
  place-items: center;
  border: 1px solid var(--cream-300);
  border-radius: 50%;
  color: var(--forest-800);
  font-size: 1.35rem;
}

.dashboard-shell,
.profile-shell {
  padding-top: 2.2rem;
  padding-bottom: 5rem;
}

.dashboard-header,
.profile-header {
  display: grid;
  margin-bottom: 1.5rem;
  padding: 1.4rem;
  gap: 1rem;
  border-radius: 0.9rem;
  background: var(--forest-900);
  color: var(--white);
}

.dashboard-header h1,
.profile-header h1 {
  margin-bottom: 0.5rem;
  color: var(--white);
  font-size: clamp(2.1rem, 8vw, 4rem);
}

.dashboard-header p,
.profile-header p {
  max-width: 42rem;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.78);
}

.profile-photo {
  width: 7rem;
  height: 7rem;
  border: 3px solid var(--gold-300);
  border-radius: 50%;
  object-fit: cover;
}

.dashboard-grid {
  display: grid;
  gap: 1rem;
}

.dashboard-section {
  scroll-margin-top: 5rem;
}

.dashboard-section > h2 {
  font-size: 1.75rem;
}

.mission-today {
  padding: 1.4rem;
  border-left: 0.35rem solid var(--gold-500);
  background: var(--cream-100);
}

.mission-today ol {
  margin-bottom: 1.25rem;
  padding-left: 1.35rem;
}

.mission-today li + li {
  margin-top: 0.55rem;
}

.metric-card strong {
  display: block;
  color: var(--forest-900);
  font-family: Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-size: 2rem;
  font-weight: 600;
}

.metric-card span {
  color: var(--muted);
  font-size: 0.9rem;
}

.person-card .button {
  margin-top: 0.75rem;
  margin-right: 0.4rem;
}

.person-card .action-status {
  margin-top: 0.5rem;
}

.progress-wrap {
  margin-top: 1rem;
}

progress {
  width: 100%;
  height: 0.85rem;
  overflow: hidden;
  border: 0;
  border-radius: 0.2rem;
  background: var(--cream-200);
  accent-color: var(--forest-700);
}

progress::-webkit-progress-bar {
  background: var(--cream-200);
}

progress::-webkit-progress-value {
  background: var(--forest-700);
}

progress::-moz-progress-bar {
  background: var(--forest-700);
}

.timeline {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.timeline li {
  display: grid;
  position: relative;
  padding: 0 0 1.2rem 1.7rem;
  grid-template-columns: 1fr;
}

.timeline li::before {
  position: absolute;
  top: 0.28rem;
  left: 0;
  width: 0.65rem;
  height: 0.65rem;
  border: 2px solid var(--forest-700);
  border-radius: 50%;
  background: var(--white);
  content: "";
}

.timeline li::after {
  position: absolute;
  top: 1.05rem;
  bottom: 0;
  left: 0.36rem;
  width: 1px;
  background: var(--cream-300);
  content: "";
}

.timeline li:last-child::after {
  display: none;
}

.timeline strong {
  font-size: 0.98rem;
}

.timeline time,
.timeline span {
  color: var(--muted);
  font-size: 0.84rem;
}

.share-panel {
  display: grid;
  gap: 1rem;
}

.share-message {
  min-height: 8.5rem;
}

.share-actions .button {
  flex: 1 1 8.7rem;
}

.qr-wrap {
  display: grid;
  gap: 0.7rem;
  justify-items: center;
  padding: 1rem;
  border: 1px solid var(--cream-200);
  border-radius: 0.55rem;
  background: var(--white);
}

.qr-wrap canvas {
  width: min(100%, 18rem);
  height: auto;
  image-rendering: pixelated;
}

.qr-wrap p {
  max-width: 28rem;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
  text-align: center;
  overflow-wrap: anywhere;
}

.bio-list {
  display: grid;
  gap: 0.65rem;
}

.bio-list details {
  border-top: 1px solid var(--cream-200);
  padding: 0.8rem 0 0.15rem;
}

.bio-list details:first-child {
  border-top: 0;
}

.bio-list summary {
  color: var(--forest-900);
  font-weight: 780;
  cursor: pointer;
}

.bio-list ol {
  margin-bottom: 0.75rem;
  padding-left: 1.4rem;
}

.bio-list li + li {
  margin-top: 0.35rem;
}

.story-layout {
  display: grid;
  gap: 1.25rem;
}

.story-preview {
  display: grid;
  justify-items: center;
}

.story-preview canvas {
  width: min(100%, 19rem);
  border: 1px solid var(--cream-300);
  border-radius: 0.65rem;
  box-shadow: 0 14px 34px rgba(23, 63, 54, 0.14);
}

.story-tabs {
  display: grid;
  margin-bottom: 1rem;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--cream-300);
  border-radius: 0.5rem;
  overflow: hidden;
}

.story-tabs button {
  min-height: 2.8rem;
  border: 0;
  border-right: 1px solid var(--cream-300);
  background: var(--white);
  color: var(--forest-900);
  font-weight: 780;
  cursor: pointer;
}

.story-tabs button:last-child {
  border-right: 0;
}

.story-tabs button[aria-pressed="true"] {
  background: var(--forest-900);
  color: var(--white);
}

.story-caption {
  min-height: 7rem;
}

.link-grid {
  margin-top: 1.3rem;
}

.link-card {
  display: grid;
  min-height: 7.5rem;
  padding: 1.15rem;
  align-content: center;
  color: var(--forest-950);
  text-decoration: none;
}

.link-card:hover {
  border-color: var(--gold-500);
  translate: 0 -2px;
}

.link-card strong {
  font-family: Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-size: 1.3rem;
}

.link-card span {
  margin-top: 0.25rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.profile-about,
.profile-projects {
  max-width: var(--reading);
  margin: 2rem 0;
}

.profile-socials {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
}

.profile-socials a {
  font-weight: 700;
}

.invite-card {
  max-width: 48rem;
  margin: 2rem auto 5rem;
  overflow: hidden;
  border: 1px solid var(--cream-200);
  border-radius: 0.9rem;
  background: var(--white);
  box-shadow: var(--shadow);
}

.invite-card-head {
  padding: 2rem 1.3rem;
  background: var(--forest-900);
  color: var(--white);
}

.invite-card-head h1 {
  color: var(--white);
  font-size: clamp(2.2rem, 9vw, 4.5rem);
}

.invite-card-body {
  padding: 1.3rem;
}

.empty-box {
  padding: 1.2rem;
  border: 1px dashed var(--cream-300);
  border-radius: 0.55rem;
  color: var(--muted);
  text-align: center;
}

.site-footer {
  padding: 1.8rem 1rem max(2rem, env(safe-area-inset-bottom));
  border-top: 1px solid var(--cream-200);
  background: var(--cream-100);
  color: var(--muted);
  font-size: 0.82rem;
  text-align: center;
}

.site-footer p {
  margin-bottom: 0.3rem;
}

.no-script {
  padding: 2rem 1rem;
  background: var(--cream-100);
  text-align: center;
}

:focus-visible {
  outline: 3px solid var(--gold-300);
  outline-offset: 3px;
}

@media (min-width: 34rem) {
  .wordmark-section,
  .site-nav a:first-child {
    display: inline;
  }

  .surface {
    padding: 2rem;
  }

  .form-grid.two-column {
    grid-template-columns: 1fr 1fr;
  }

  .field.full,
  .check-field.full,
  .form-actions.full {
    grid-column: 1 / -1;
  }

  .principles-grid,
  .metric-grid,
  .circle-grid,
  .link-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-header {
    grid-template-columns: auto 1fr;
    align-items: center;
  }
}

@media (min-width: 52rem) {
  .header-inner,
  .page-shell,
  .hero-inner,
  .profile-shell,
  .dashboard-shell {
    padding-right: 2rem;
    padding-left: 2rem;
  }

  .hero {
    min-height: 34rem;
    padding: 6rem 0 7rem;
  }

  .hero::after {
    right: 4vw;
    bottom: -11rem;
    width: 30rem;
    height: 30rem;
  }

  .mission-math-wrap {
    padding: 0 2rem;
  }

  .mission-math {
    padding: 1.5rem 2rem;
  }

  .content-section {
    padding: 6rem 0;
  }

  .principles-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dashboard-grid {
    grid-template-columns: minmax(0, 1.05fr) minmax(19rem, 0.95fr);
    align-items: start;
  }

  .dashboard-grid .wide {
    grid-column: 1 / -1;
  }

  .story-layout {
    grid-template-columns: minmax(15rem, 0.75fr) minmax(20rem, 1.25fr);
    align-items: center;
  }

  .invite-card-head,
  .invite-card-body {
    padding: 3rem;
  }
}

@media (min-width: 68rem) {
  .link-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media print {
  .site-header,
  .site-footer,
  .share-actions,
  .story-actions,
  .button-row {
    display: none !important;
  }

  body::before {
    display: none;
  }

  body,
  .content-section,
  .surface {
    background: var(--white);
  }
}
