/* Knock — public website styles.
   Two themes, matching the app's Sage (light) and Forest (dark): packages/design-system/src/colors.ts.
   No JavaScript on this site; this file is the only thing making it look like Knock. */

@font-face {
  font-family: 'Figtree';
  src: url('/fonts/Figtree-Regular.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Figtree';
  src: url('/fonts/Figtree-Medium.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'Figtree';
  src: url('/fonts/Figtree-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Figtree';
  src: url('/fonts/Figtree-Bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}

:root {
  --bg: #f6f7f4;
  --surface: #ffffff;
  --surface-secondary: #eaeee8;
  --text: #18201b;
  --text-secondary: #454f48;
  --text-tertiary: #5e6861;
  --text-accent: #117346;
  --accent: #19a064;
  --on-accent: #ffffff;
  --mark-you: #18201b;
  --on-you: #ffffff;
  --border: rgba(24, 32, 27, 0.09);
  --shadow: rgba(12, 17, 14, 0.12);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101411;
    --surface: #1b211d;
    --surface-secondary: #262d28;
    --text: #edf2ee;
    --text-secondary: #b5bfb8;
    --text-tertiary: #8e9891;
    --text-accent: #5fe0a2;
    --accent: #3dd68c;
    --on-accent: #08110c;
    --mark-you: #edf2ee;
    --on-you: #101411;
    --border: rgba(237, 242, 238, 0.1);
    --shadow: rgba(0, 0, 0, 0.4);
  }
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    'Figtree',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--text-accent);
  text-decoration: none;
}
a:hover,
a:focus-visible {
  text-decoration: underline;
}
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Header */

.site-header {
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 10;
}

.site-nav {
  max-width: 960px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 18px;
  color: var(--text);
}
.wordmark:hover,
.wordmark:focus-visible {
  text-decoration: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.nav-links a {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
}
.nav-links a[aria-current='true'] {
  color: var(--text);
  font-weight: 700;
}
.lang-switch {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-tertiary);
}

/* The two-bar mark */

.mark {
  display: inline-flex;
  align-items: flex-end;
  gap: 4px;
  height: 20px;
}
.mark-bar {
  display: block;
  width: 5px;
  height: 20px;
  border-radius: 3px;
  transform-origin: bottom;
}
.mark-bar-you {
  background: var(--mark-you);
  animation: markStrike 4.5s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}
.mark-bar-them {
  background: var(--accent);
  animation: markDip 4.5s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.mark-hero {
  height: 96px;
  gap: 18px;
}
.mark-hero .mark-bar {
  width: 24px;
  height: 96px;
  border-radius: 12px;
}

@keyframes markStrike {
  0%,
  100% {
    transform: scaleY(1) scaleX(1);
  }
  1% {
    transform: scaleY(0.55) scaleX(1.18);
  }
  2.5% {
    transform: scaleY(1.1) scaleX(0.96);
  }
  4% {
    transform: scaleY(1) scaleX(1);
  }
}
@keyframes markDip {
  0%,
  4%,
  100% {
    transform: translateY(0);
  }
  5% {
    transform: translateY(6%);
  }
  7% {
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .mark-bar-you,
  .mark-bar-them {
    animation: none;
  }
}

/* Main content */

main {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px 96px;
}

.hero {
  max-width: 640px;
  margin: 72px auto 0;
  text-align: center;
}
.eyebrow {
  color: var(--text-tertiary);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.hero h1 {
  font-size: clamp(48px, 10vw, 72px);
  line-height: 1;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}
.lede {
  font-size: clamp(20px, 4vw, 26px);
  font-weight: 600;
  margin: 0 0 12px;
}
.sub {
  color: var(--text-secondary);
  font-size: 17px;
  margin: 0 auto;
  max-width: 520px;
}

.knock-moment {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin: 80px auto;
  text-align: center;
}
.caption {
  color: var(--text-tertiary);
  font-size: 15px;
  max-width: 420px;
  margin: 0;
}

.features {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin: 64px 0;
}
.feature h3 {
  font-size: 20px;
  margin: 0 0 8px;
}
.feature p {
  color: var(--text-secondary);
  margin: 0;
  max-width: 560px;
}

.callout {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  margin: 64px 0;
}
.callout h2 {
  margin-top: 0;
  font-size: 20px;
}
.callout p {
  color: var(--text-secondary);
}
.callout p:last-child {
  margin-bottom: 0;
}

.status-note {
  margin: 40px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.status-note p {
  color: var(--text-tertiary);
  font-size: 14px;
  margin: 0;
}

.not-found {
  margin-top: 96px;
}
.not-found h1 {
  font-size: 28px;
}

/* Legal / long-form pages */

.legal {
  max-width: 680px;
  margin: 48px auto 0;
}
.legal h1 {
  font-size: 34px;
  margin: 0 0 8px;
}
.legal-meta {
  color: var(--text-tertiary);
  font-size: 14px;
  margin: 0 0 40px;
}
.legal h2 {
  font-size: 20px;
  margin: 40px 0 12px;
  scroll-margin-top: 80px;
}
.legal p,
.legal li {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.65;
}
.legal ul {
  padding-left: 20px;
}
.legal strong {
  color: var(--text);
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 20px 60px;
  text-align: center;
}
.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.footer-links a {
  color: var(--text-secondary);
  font-size: 14px;
}
.footer-fine {
  color: var(--text-tertiary);
  font-size: 13px;
  max-width: 480px;
  margin: 0 auto;
}

@media (max-width: 520px) {
  .site-nav {
    flex-wrap: wrap;
  }
  .nav-links {
    gap: 14px;
  }
  .hero {
    margin-top: 48px;
  }
}
