:root {
  --canvas: #f7f6f3;
  --surface: #ffffff;
  --text: #2f3437;
  --muted: #787774;
  --line: #eaeaea;
  --ink: #111111;
  --pale-green: #edf3ec;
  --pale-green-text: #346538;
  --pale-blue: #e1f3fe;
  --pale-blue-text: #1f6c9f;
  --radius: 12px;
  --pad: clamp(1.25rem, 4vw, 4rem);
  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "Manrope", "Helvetica Neue", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--canvas);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: var(--pale-blue);
  color: var(--pale-blue-text);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem var(--pad);
  background: color-mix(in srgb, var(--canvas) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
}

.top.is-scrolled {
  border-bottom-color: var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--serif);
  font-size: 1.5rem;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.brand-logo {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  flex-shrink: 0;
}

.nav {
  display: none;
  gap: 1.5rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.nav a:hover {
  color: var(--ink);
}

.support-link {
  color: var(--muted);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, currentColor 35%, transparent);
  text-underline-offset: 3px;
  transition: color 0.18s ease;
}

.support-link:hover {
  color: var(--ink);
}

.support-link-header {
  font-size: 0.85rem;
  white-space: nowrap;
}

.btn,
.btn-small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ink);
  color: #fff;
  border: 0;
  border-radius: 6px;
  font-family: var(--sans);
  font-weight: 600;
  transition: background 0.18s cubic-bezier(0.22, 1, 0.36, 1), transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}

.btn {
  padding: 0.9rem 1.35rem;
  font-size: 0.95rem;
}

.btn-small {
  padding: 0.55rem 0.9rem;
  font-size: 0.85rem;
}

.btn:hover,
.btn-small:hover {
  background: #333;
  transform: scale(0.98);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn-ghost:hover {
  background: var(--surface);
}

.hidden {
  display: none !important;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-shrink: 0;
}

.auth-user {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.auth-user-label {
  font-size: 0.85rem;
  color: var(--muted);
  max-width: 10rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.auth-modal.hidden {
  display: none !important;
}

body.auth-modal-open {
  overflow: hidden;
}

.auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 17, 17, 0.35);
  backdrop-filter: blur(4px);
}

.auth-dialog {
  position: relative;
  width: min(100%, 400px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem 1.5rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

.auth-close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  width: 2rem;
  height: 2rem;
  border: 0;
  background: transparent;
  font-size: 1.35rem;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
  border-radius: 6px;
}

.auth-close:hover {
  color: var(--ink);
  background: var(--canvas);
}

.auth-title {
  font-family: var(--serif);
  font-size: 1.75rem;
  font-weight: 400;
  color: var(--ink);
  margin: 0 0 0.25rem;
  letter-spacing: -0.03em;
}

.auth-lead {
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.muted {
  color: var(--muted);
}

.auth-tabs {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}

.auth-tab {
  flex: 1;
  padding: 0.55rem 0.5rem;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.auth-tab.active {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.auth-flash {
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  font-size: 0.88rem;
  margin-bottom: 0.85rem;
}

.auth-flash.err {
  background: #fdebec;
  color: #9f2f2d;
}

.auth-flash.ok {
  background: var(--pale-green);
  color: var(--pale-green-text);
}

.auth-form label {
  display: block;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 0.3rem;
}

.auth-form input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  font: inherit;
  background: #fff;
}

.auth-form input:focus {
  outline: 2px solid color-mix(in srgb, var(--ink) 25%, transparent);
  outline-offset: 0;
  border-color: var(--ink);
}

.auth-form .btn {
  width: 100%;
  margin-top: 0.25rem;
}

.auth-hint {
  font-size: 0.78rem;
  color: var(--muted);
  margin: -0.35rem 0 0.65rem;
}

.hero {
  position: relative;
  min-height: 100dvh;
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(247, 246, 243, 0.18) 0%, rgba(247, 246, 243, 0.55) 48%, rgba(247, 246, 243, 0.94) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: calc(var(--pad) + 2rem) var(--pad) clamp(3rem, 8vw, 5.5rem);
  max-width: 42rem;
}

.brand-mark {
  display: block;
  width: 104px;
  height: auto;
  margin-bottom: 1rem;
}

.hero h1,
.section-head h2,
.problem-copy h2,
.faq h2,
.cta-panel h2 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--ink);
}

.hero h1 {
  font-size: clamp(2.2rem, 6vw, 4rem);
  margin-bottom: 1rem;
}

.lead {
  max-width: 34rem;
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 1.6rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.4rem;
}

.text-link {
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.1rem;
}

.text-link:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.problem,
.how,
.features,
.product,
.faq-cta {
  padding: clamp(3.5rem, 9vw, 7rem) var(--pad);
}

.problem {
  display: grid;
  gap: 2rem;
  align-items: center;
}

.eyebrow-num {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.9rem;
}

.problem-copy h2,
.section-head h2,
.faq h2,
.cta-panel h2 {
  font-size: clamp(2rem, 4.8vw, 3.4rem);
  margin-bottom: 1rem;
}

.problem-copy p:last-child {
  color: var(--muted);
  max-width: 32rem;
}

.frame {
  background: rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 1.5rem;
  padding: 0.4rem;
}

.frame-inner {
  overflow: hidden;
  border-radius: calc(1.5rem - 0.25rem);
  background: var(--surface);
  border: 1px solid var(--line);
}

.section-head {
  max-width: 40rem;
  margin-bottom: 2.2rem;
}

.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.steps {
  list-style: none;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.steps li {
  display: grid;
  gap: 0.7rem;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--line);
}

.tag {
  display: inline-flex;
  width: fit-content;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: var(--pale-green);
  color: var(--pale-green-text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.steps h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ink);
}

.steps p {
  color: var(--muted);
  max-width: 36rem;
}

.bento {
  display: grid;
  gap: 1rem;
}

.tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.4rem;
  transition: box-shadow 0.2s ease;
}

.tile:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.tile h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.55rem;
}

.tile p {
  color: var(--muted);
}

.product-frame {
  max-width: 980px;
  margin: 0 auto;
}

.product-stage {
  background: #efeee9;
}

.faq-cta {
  display: grid;
  gap: 2.5rem;
}

.faq-list {
  margin-top: 1.2rem;
}

.faq-list details {
  border-bottom: 1px solid var(--line);
  padding: 1rem 0;
}

.faq-list summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-weight: 600;
  color: var(--ink);
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  font-family: var(--mono);
  color: var(--muted);
  font-size: 1.1rem;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list p {
  margin-top: 0.7rem;
  color: var(--muted);
  max-width: 36rem;
}

.cta-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.6rem, 4vw, 2.4rem);
}

.cta-logo {
  display: block;
  width: 80px;
  height: 80px;
  margin-bottom: 0.75rem;
}

.cta-panel .btn {
  margin-top: 1.2rem;
}

.note {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem var(--pad) 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.88rem;
}

.policy-shell {
  width: min(860px, calc(100% - 2 * var(--pad)));
  margin: 0 auto;
  padding: clamp(3rem, 8vw, 7rem) 0;
}

.policy-card {
  padding: clamp(1.5rem, 4vw, 3.5rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: 0 18px 60px rgba(47, 52, 55, 0.06);
}

.policy-card h1 {
  margin: 0.35rem 0 0.75rem;
  font-family: var(--serif);
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.04em;
  color: var(--ink);
}

.policy-card h2 {
  margin: 2.3rem 0 0.7rem;
  font-size: 1.15rem;
  line-height: 1.25;
  color: var(--ink);
}

.policy-card p,
.policy-card li {
  color: var(--text);
}

.policy-card ul {
  display: grid;
  gap: 0.55rem;
  margin: 0.8rem 0 0 1.2rem;
}

.policy-card a {
  color: var(--pale-blue-text);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.policy-card .policy-lead,
.policy-card .policy-language {
  color: var(--muted);
}

.policy-card .policy-language {
  margin-top: 2.5rem;
  font-family: var(--mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.policy-card hr {
  margin: 3rem 0 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

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

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .btn:hover,
  .btn-small:hover {
    transform: none;
  }
}

@media (min-width: 768px) {
  .nav {
    display: flex;
  }

  .problem {
    grid-template-columns: 1fr 1.05fr;
    gap: 3rem;
  }

  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    border-top: 0;
  }

  .steps li {
    padding: 0 1.4rem 0 0;
    border-bottom: 0;
    border-right: 1px solid var(--line);
  }

  .steps li:last-child {
    border-right: 0;
    padding-right: 0;
  }

  .bento {
    grid-template-columns: repeat(2, 1fr);
  }

  .tile-wide {
    grid-column: span 2;
  }

  .faq-cta {
    grid-template-columns: 1.1fr 0.9fr;
    align-items: start;
  }
}

@media (min-width: 1100px) {
  .tile-wide {
    min-height: 10rem;
  }
}
