:root {
  /* Stan-like structure; Backlogr palette (not purple) */
  --brand: #0f3d2e;
  --brand-deep: #07261c;
  --ink: #102018;
  --muted: #5a6f64;
  --paper: #ffffff;
  --fog: #eef6f1;
  --cta: #b8f34d;
  --cta-ink: #07261c;
  --line: rgba(255, 255, 255, 0.22);
  --radius-pill: 999px;
  --font-display: "Syne", system-ui, sans-serif;
  --font-body: "Outfit", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  background: var(--brand);
  color: #fff;
}

.site-header.is-light {
  background: var(--paper);
  color: var(--ink);
  border-bottom: 1px solid #e8ebf4;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 50%;
  background: var(--cta);
  color: var(--cta-ink);
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 800;
}

.nav-center {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-weight: 600;
  font-size: 0.98rem;
}

.nav-center a {
  opacity: 0.92;
}

.nav-center a:hover,
.nav-center a.is-active {
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 0.3em;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-weight: 700;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 0;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1rem;
  border-radius: var(--radius-pill);
  padding: 0.85rem 1.35rem;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
}

.btn-ghost {
  background: transparent;
  color: inherit;
  padding-inline: 0.4rem;
}

.btn-solid {
  background: #fff;
  color: var(--brand-deep);
  padding: 0.65rem 1.15rem;
  font-size: 0.95rem;
}

.site-header.is-light .btn-solid {
  background: var(--brand);
  color: #fff;
}

.btn-cta {
  background: var(--cta);
  color: var(--cta-ink);
}

.hero {
  background: linear-gradient(165deg, var(--brand) 0%, var(--brand-deep) 100%);
  color: #fff;
  padding: 3.5rem 1.5rem 5.5rem;
  clip-path: polygon(0 0, 100% 0, 100% 88%, 0 100%);
}

.hero-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  margin: 0 0 1rem;
  font-weight: 800;
}

.hero p {
  margin: 0 0 1.75rem;
  font-size: 1.15rem;
  line-height: 1.55;
  max-width: 34rem;
  color: rgba(255, 255, 255, 0.88);
}

.hero-visual {
  min-height: 280px;
  border-radius: 1.5rem;
  background:
    radial-gradient(circle at 30% 20%, rgba(184, 243, 77, 0.28), transparent 42%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.03));
  border: 1px solid var(--line);
  padding: 1.75rem 1.6rem;
  display: grid;
  align-content: center;
  gap: 0.65rem;
}

.hero-kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--cta);
}

.hero-idea {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.hero-steps {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.7;
}

.section {
  max-width: 960px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
}

.section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  letter-spacing: -0.03em;
  margin: 0 0 0.75rem;
}

.section p.lead {
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.6;
  margin: 0 0 2rem;
  max-width: 40rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.feature {
  background: var(--fog);
  border-radius: 1rem;
  padding: 1.25rem;
}

.feature h3 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.feature p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.price {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.4rem;
}

.page-hero {
  background: var(--brand);
  color: #fff;
  padding: 3rem 1.5rem 2.5rem;
}

.page-hero-inner {
  max-width: 860px;
  margin: 0 auto;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  letter-spacing: -0.04em;
  margin: 0 0 0.75rem;
}

.page-hero p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.1rem;
  line-height: 1.55;
  max-width: 40rem;
}

.prose {
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  font-size: 1.08rem;
  line-height: 1.7;
  color: #2a3144;
}

.prose h2 {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-top: 2rem;
}

.blog-list {
  display: grid;
  gap: 1rem;
  max-width: 760px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.blog-item {
  display: block;
  padding: 1.25rem 1.35rem;
  border: 1px solid #e6e9f2;
  border-radius: 1rem;
  background: #fff;
}

.blog-item:hover {
  border-color: #c9d0e6;
}

.blog-item .meta {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 0.35rem;
}

.blog-item h2 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.blog-item p {
  margin: 0;
  color: var(--muted);
}

.auth-shell {
  min-height: calc(100vh - 72px);
  display: grid;
  place-items: center;
  padding: 2rem 1.5rem;
  background: var(--fog);
}

.auth-card {
  width: min(100%, 420px);
  background: #fff;
  border-radius: 1.25rem;
  padding: 1.75rem;
  box-shadow: 0 20px 50px rgba(7, 38, 28, 0.08);
}

.auth-card h1 {
  font-family: var(--font-display);
  margin: 0 0 0.35rem;
  font-size: 1.8rem;
  letter-spacing: -0.03em;
}

.auth-card .sub {
  color: var(--muted);
  margin: 0 0 1.25rem;
}

.auth-card label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin: 0.85rem 0 0.35rem;
}

.auth-card input {
  width: 100%;
  border: 1px solid #d7dceb;
  border-radius: 0.75rem;
  padding: 0.85rem 0.95rem;
  font: inherit;
}

.auth-card input:focus {
  outline: 2px solid rgba(26, 47, 143, 0.25);
  border-color: var(--brand);
}

.auth-card .btn {
  width: 100%;
  margin-top: 1.25rem;
}

.auth-card .alt {
  text-align: center;
  margin-top: 1rem;
  color: var(--muted);
}

.auth-card .lede,
.auth-card .sub {
  color: var(--muted);
  margin: 0 0 1rem;
}

.auth-card .stack {
  display: grid;
  gap: 0.75rem;
}

.auth-card .stack input,
.auth-card .stack button {
  width: 100%;
  font: inherit;
  padding: 0.85rem 1rem;
  border-radius: 0.85rem;
  border: 1px solid #d9e0dc;
}

.auth-card .stack button {
  border: 0;
  background: var(--brand);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.auth-card .error {
  color: #c0392b;
  font-weight: 700;
}

.auth-card .ok {
  color: #1b6b3a;
  font-weight: 700;
}

.auth-card .muted {
  color: var(--muted);
  margin-top: 1rem;
}

.auth-card .alt a {
  color: var(--brand);
  font-weight: 700;
}

.error {
  color: #c0392b;
  margin-top: 0.75rem;
  font-weight: 600;
}

.site-footer {
  border-top: 1px solid #e8ebf4;
  padding: 1.5rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
}

.mobile-nav {
  display: none;
}

/* Distraction-free onboarding (Stan-style) */
.onboarding-body {
  min-height: 100vh;
  background: #fff;
  margin: 0;
}

.onboarding-back {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 5;
  font-weight: 700;
  color: var(--muted);
  font-size: 0.95rem;
}

.onboarding-back:hover {
  color: var(--ink);
}

.onboarding-progress {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(420px, calc(100% - 2rem));
  height: 4px;
  background: #e8eee9;
  border-radius: 999px;
  margin-top: 0.85rem;
  overflow: hidden;
  z-index: 4;
}

.onboarding-progress-fill {
  height: 100%;
  background: var(--brand);
  border-radius: inherit;
}

.onboarding-main {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 3.5rem 1.25rem 2rem;
}

.onboarding-card {
  width: min(100%, 420px);
}

.step-back {
  display: inline-block;
  margin: 0 0 0.85rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
}

.step-back:hover {
  color: var(--ink);
}

.onboarding-card h1 {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.1rem);
  letter-spacing: -0.03em;
  margin: 0 0 0.4rem;
}

.onboarding-card .sub {
  color: var(--muted);
  margin: 0 0 1.35rem;
  line-height: 1.45;
}

.field {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  border: 1px solid #d9e0dc;
  border-radius: 0.85rem;
  padding: 0.15rem 0.85rem;
  margin-bottom: 0.75rem;
  background: #fff;
}

.field:focus-within {
  border-color: var(--brand);
  outline: 2px solid rgba(15, 61, 46, 0.12);
}

.field-icon {
  opacity: 0.55;
  font-size: 0.95rem;
  width: 1.2rem;
  text-align: center;
}

.field input,
.field textarea {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 0.9rem 0;
  font: inherit;
  width: 100%;
}

.field input:focus,
.field textarea:focus {
  outline: none;
}

.field-plain {
  align-items: flex-start;
}

.field-plain textarea {
  resize: vertical;
  min-height: 120px;
}

.btn-brand {
  width: 100%;
  background: var(--brand);
  color: #fff;
  margin-top: 0.5rem;
}

.btn-brand:disabled {
  opacity: 0.65;
  cursor: wait;
}

.legal {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
  margin: 0.9rem 0 0;
  text-align: center;
}

.onboarding-wide {
  width: min(100%, 560px);
}

.preset-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.preset-chip {
  border: 1px solid #d9e0dc;
  border-radius: 0.85rem;
  padding: 0.85rem 0.75rem;
  text-align: left;
  font-weight: 700;
  font-family: var(--font-body);
  font-size: 0.95rem;
  cursor: pointer;
  background: #fff;
  color: var(--ink);
}

.preset-chip:hover {
  border-color: var(--brand);
}

.preset-chip.is-selected {
  border-color: var(--brand);
  background: var(--fog);
  color: var(--brand-deep);
}

@media (max-width: 520px) {
  .preset-grid {
    grid-template-columns: 1fr;
  }
}

.price-box {
  border: 1px solid #d9e0dc;
  border-radius: 1rem;
  padding: 1.15rem 1.2rem;
  margin-bottom: 1rem;
  background: var(--fog);
}

.price-amount {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.price-amount span {
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
  margin-left: 0.2rem;
}

.price-trial {
  margin: 0.25rem 0 0;
  color: var(--brand);
  font-weight: 700;
}

.price-perks {
  margin: 0.75rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
  line-height: 1.6;
}

.plan-kicker {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
}

.plan-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  margin: 0 0 0.85rem;
}

.plan-builder {
  margin: 0.35rem 0 0.25rem;
  text-align: center;
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.plan-builder.is-leaving {
  opacity: 0;
  transform: translateY(-6px);
}

.plan-builder-mark {
  position: relative;
  width: 3.4rem;
  height: 3.4rem;
  margin: 0.4rem auto 1rem;
  display: grid;
  place-items: center;
}

.plan-builder-pulse {
  position: absolute;
  inset: 0;
  border-radius: 1rem;
  background: var(--fog);
  border: 1px solid #d9e0dc;
  animation: planPulse 1.5s ease-in-out infinite;
}

.plan-builder-letter {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--brand-deep);
}

.plan-builder-status {
  margin: 0 0 1rem;
  min-height: 1.5em;
  font-weight: 700;
  color: var(--ink);
  transition: opacity 0.25s ease;
}

.plan-builder-stages {
  list-style: none;
  margin: 0 0 0.85rem;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.35rem;
}

.plan-builder-stages li {
  border-radius: 999px;
  padding: 0.4rem 0.2rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--muted);
  background: #f7faf8;
  border: 1px solid #e4ebe6;
}

.plan-builder-stages li.is-active {
  color: var(--brand-deep);
  background: var(--fog);
  border-color: #cfe0d6;
}

.plan-builder-stages li.is-done {
  color: #1b6b3a;
  background: #e8f8ee;
  border-color: #cfe9d8;
}

.plan-builder-bar {
  height: 0.45rem;
  border-radius: 999px;
  background: #e8f0eb;
  overflow: hidden;
}

.plan-builder-bar-fill {
  height: 100%;
  width: 12%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand) 0%, #1a5c43 55%, #b8f34d 100%);
  background-size: 200% 100%;
  animation: planShimmer 1.8s linear infinite;
  transition: width 0.45s ease;
}

@keyframes planPulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.06);
    opacity: 0.85;
  }
}

@keyframes planShimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: -100% 0;
  }
}

@keyframes planTaskIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.plan-task-list {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}

.plan-task {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  border: 1px solid #d9e0dc;
  border-radius: 0.85rem;
  padding: 0.85rem 0.9rem;
  line-height: 1.4;
}

.plan-task-enter {
  opacity: 0;
  animation: planTaskIn 0.4s ease forwards;
}

.plan-task.is-done span {
  color: var(--muted);
  text-decoration: line-through;
}

.plan-check {
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.1rem;
  border-radius: 0.35rem;
  border: 2px solid var(--brand);
  background: #fff;
  cursor: pointer;
  flex-shrink: 0;
}

.plan-task.is-done .plan-check {
  background: var(--brand);
}

@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .nav-center {
    display: none;
  }

  .mobile-nav {
    display: flex;
    gap: 1rem;
    justify-content: center;
    padding: 0.75rem 1rem 1rem;
    background: var(--brand);
    color: #fff;
    font-weight: 600;
  }

  .site-header.is-light + .mobile-nav {
    background: var(--paper);
    color: var(--ink);
    border-bottom: 1px solid #e8ebf4;
  }
}
