:root {
  --bg: #070708;
  --bg-2: #101012;
  --text: #f5f5f7;
  --muted: #8e8e96;
  --line: rgba(255, 255, 255, 0.1);
  --panel: rgba(22, 22, 26, 0.78);
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #fb7185;
  --radius: 20px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
html { touch-action: manipulation; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(255, 255, 255, 0.07), transparent 55%),
    radial-gradient(ellipse 50% 40% at 90% 20%, rgba(80, 120, 255, 0.08), transparent 50%),
    radial-gradient(ellipse 40% 35% at 10% 70%, rgba(255, 90, 60, 0.05), transparent 50%);
  background-attachment: fixed;
}
body::before {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  opacity: 0.035;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
body > * { position: relative; z-index: 2; }

a { color: inherit; text-decoration: none; }
p a, .lead a, .muted a, li a { text-decoration: underline; text-underline-offset: 3px; color: #fff; }

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 28px;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  backdrop-filter: blur(22px) saturate(1.2);
  border-bottom: 1px solid transparent;
}
.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
}
.nav-brand svg, .nav-brand img.mark { width: 22px; height: 22px; border-radius: 22%; display: block; }
.auth-panel { display: grid; gap: 10px; text-align: left; }
.auth-panel .btn, .auth-panel button { width: 100%; }
.auth-panel .apple { background: #fff; color: #111; }
.auth-panel .google { background: rgba(255,255,255,0.08); }
.auth-or { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; }
.auth-or::before, .auth-or::after { content: ""; height: 1px; background: var(--line); }
.auth-form { display: grid; gap: 10px; }
.auth-form label { display: grid; gap: 6px; font-size: 12px; color: var(--muted); font-weight: 600; }
.auth-form .row button { width: auto; }
button.linkish, .linkish {
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  padding: 0;
  width: auto;
  justify-content: flex-start;
}
.auth-note { min-height: 1.2em; margin: 0; }
.nav-links {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
  z-index: 1;
}
.nav-links a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border-radius: 999px;
}
.nav-links a:hover, .nav-links a[aria-current="page"] {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  text-decoration: none;
}
.nav-links svg { width: 15px; height: 15px; }
.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  margin-left: auto;
  flex-shrink: 0;
  position: relative;
  z-index: 3;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  border-radius: 1px;
  background: currentColor;
}
.nav.menu-open .nav-links,
.nav.nav-compact.menu-open .nav-links {
  display: flex;
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  transform: none;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  margin: 0;
  padding: 8px 12px 14px;
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  backdrop-filter: blur(22px) saturate(1.2);
  border-bottom: 1px solid var(--line);
  z-index: 40;
}
.nav.menu-open .nav-links a,
.nav.nav-compact.menu-open .nav-links a {
  justify-content: center;
  padding: 14px 16px;
  font-size: 16px;
  border-radius: 14px;
}
.nav-brand, .nav-end, .nav > .nav-download { position: relative; z-index: 2; }
.nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 1;
  min-width: 0;
  margin-left: auto;
  max-width: calc(50% - 188px);
}
#who { display: flex; align-items: center; gap: 8px; min-width: 0; overflow: hidden; }
#who .row { flex-wrap: nowrap; min-width: 0; max-width: 100%; }
#who .muted {
  font-size: 12px;
  max-width: 180px;
  min-width: 0;
  flex: 0 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#who button, .nav-end > .nav-download { flex-shrink: 0; }
header.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 36px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: var(--text);
}

button, .btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  border-radius: 999px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}
button:hover, .btn:hover { background: rgba(255, 255, 255, 0.12); text-decoration: none; }
button:disabled { opacity: 0.5; cursor: default; }
.primary, button.primary, .btn.primary {
  background: #fff;
  color: #111;
}
.primary:hover, button.primary:hover, .btn.primary:hover { background: #e8e8ea; }
.ghost {
  background: transparent;
  border: 1px solid var(--line);
}
.nav-download { font-size: 13px; background: #fff; color: #111; }
.danger { color: var(--danger); background: rgba(251, 113, 133, 0.08); }

.wrap { max-width: 1040px; margin: 0 auto; padding: 40px 24px 80px; }
.narrow { max-width: 640px; }
h1 { font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -0.04em; line-height: 1.08; margin: 0 0 12px; font-weight: 650; }
h2 { font-size: 1.25rem; margin: 0 0 12px; letter-spacing: -0.02em; }
p.lead { color: var(--muted); font-size: 1.08rem; margin: 0 0 36px; max-width: 620px; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.center { text-align: center; }
.hidden { display: none !important; }

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
}
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.plan { display: flex; flex-direction: column; gap: 14px; position: relative; overflow: hidden; }
.plan.featured { border-color: rgba(255, 255, 255, 0.28); box-shadow: 0 0 0 1px rgba(255,255,255,0.08), 0 24px 60px rgba(0,0,0,0.35); }
.plan .badge { position: absolute; top: 18px; right: 18px; }
.price { font-size: 2.6rem; font-weight: 700; letter-spacing: -0.04em; }
.price small { font-size: 1rem; color: var(--muted); font-weight: 500; }
ul.features { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; color: #d8d8de; }
ul.features li { display: flex; align-items: flex-start; gap: 10px; }
ul.features li::before { content: none; }
ul.features li svg { width: 16px; height: 16px; color: var(--ok); flex-shrink: 0; margin-top: 3px; }
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.page-kicker svg { width: 15px; height: 15px; }
.film {
  overflow: hidden;
  margin: 0 0 36px;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.film-track {
  display: flex;
  gap: 12px;
  width: max-content;
  animation: film 42s linear infinite;
}
.film:hover .film-track { animation-play-state: paused; }
@keyframes film {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.film img {
  width: min(200px, 38vw);
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 14px;
  flex: 0 0 auto;
  background: #151518;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #d4d4dc;
}
.badge.ok { background: rgba(52, 211, 153, 0.14); color: #6ee7b7; }
.badge.warn { background: rgba(251, 191, 36, 0.14); color: #fcd34d; }
.badge.bad { background: rgba(251, 113, 133, 0.14); color: #fda4af; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.spread h2 { display: flex; align-items: center; gap: 8px; }
.spread h2 svg { width: 18px; height: 18px; }
.stack { display: grid; gap: 16px; }
.steps { display: grid; gap: 14px; text-align: left; margin-top: 24px; }
.steps > div { display: flex; align-items: flex-start; gap: 10px; }
.steps svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 3px; }
.list { display: grid; gap: 0; }
.list > * { padding: 14px 0; border-bottom: 1px solid var(--line); }
.list > *:last-child { border-bottom: 0; }
input, select, textarea {
  font: inherit;
  color: var(--text);
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 12px;
  width: 100%;
}
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #1a1a1f;
  border: 1px solid var(--line);
  padding: 12px 18px;
  border-radius: 12px;
  z-index: 100;
}
.toast.error { border-color: rgba(251, 113, 133, 0.5); }
.toast.ok { border-color: rgba(52, 211, 153, 0.5); }
.post-list { display: grid; gap: 18px; }
.post-card h2 { margin: 0 0 6px; font-size: 1.35rem; }
.post-card h2 a { text-decoration: none; }
.post-card h2 a:hover { text-decoration: underline; text-underline-offset: 3px; }
.post-meta { color: var(--muted); font-size: 0.85rem; margin: 0 0 8px; }
.post-cover { width: 100%; border-radius: 16px; display: block; margin: 8px 0 22px; }
.prose { font-size: 1.05rem; line-height: 1.7; }
.prose p, .prose li { color: #d4d4dc; }
.prose h2 { margin: 1.5em 0 0.4em; font-size: 1.45rem; }
.prose h3, .prose h4 { margin: 1.3em 0 0.4em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 0.3em 0; }
.prose a { color: #fff; }
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.9em; background: rgba(255, 255, 255, 0.06); padding: 0.1em 0.35em; border-radius: 6px; }
.prose pre { overflow: auto; background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.prose pre code { background: none; padding: 0; }
.prose figure { margin: 1.2em 0; }
.prose figure img { width: 100%; border-radius: 16px; display: block; }
.icon-circle {
  width: 72px; height: 72px; margin: 0 auto 22px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(52, 211, 153, 0.14); border: 1px solid rgba(52, 211, 153, 0.3);
  color: #6ee7b7;
}
.icon-circle svg { width: 32px; height: 32px; }
footer, .site-foot {
  margin-top: 48px;
  color: var(--muted);
  font-size: 0.85rem;
  text-align: center;
  padding: 28px 16px 56px;
}
.site-foot p { margin: 8px 0; }
.site-foot a { display: inline-flex; align-items: center; gap: 6px; }

@media (max-width: 860px) {
  .nav { padding: 12px 14px; gap: 12px; min-width: 0; }
  .nav-brand { min-width: 0; }
  .nav-links { display: none; }
  /* A growing .nav-end used to swallow the free space, so the menu button's margin-left:auto collapsed to 0 and it sat next to the logo. Push from the brand instead, and keep the button the last item. */
  .nav-brand { margin-right: auto; }
  .nav-toggle { display: inline-flex; order: 2; margin-left: 0; }
  .nav-end, .nav > .nav-download { order: 1; margin-left: 0; flex: 0 1 auto; }
  .nav-end {
    max-width: none;
    min-width: 0;
    justify-content: flex-end;
    overflow: hidden;
  }
}
.nav.nav-compact .nav-brand { margin-right: auto; }
.nav.nav-compact .nav-toggle { display: inline-flex; order: 2; margin-left: 0; }
.nav.nav-compact .nav-links { display: none; }
.nav.nav-compact .nav-end,
.nav.nav-compact > .nav-download { order: 1; margin-left: 0; flex: 0 1 auto; }
.nav.nav-compact .nav-end { max-width: none; min-width: 0; overflow: hidden; }
.nav.nav-compact.menu-open .nav-links { display: flex; }

@media (max-width: 480px), ((max-width: 760px) and (pointer: coarse)) {
  .nav-download { display: none !important; }
}

.free-tier {
  margin-top: 18px;
  padding: 14px 16px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
}
.free-tier-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.free-kicker {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.free-tier-head h2 {
  margin: 1px 0 0;
  font-size: 1.02rem;
  letter-spacing: -0.02em;
}
.free-tier-head .primary {
  flex-shrink: 0;
  padding: 8px 14px;
  font-size: 13px;
}
.free-compare {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) 1.4fr;
  gap: 8px 22px;
  margin-top: 10px;
}
.free-compare ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 4px;
}
.free-compare ul:last-child { grid-template-columns: 1fr 1fr; }
.free-compare li {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #c8c8d0;
  font-size: 13px;
  line-height: 1.25;
}
.free-compare svg { width: 13px; height: 13px; flex-shrink: 0; }
.free-compare li.yes svg { color: var(--ok); }
.free-compare li.no svg { color: var(--danger); }
@media (max-width: 720px) {
  .free-tier-head { flex-direction: column; align-items: flex-start; }
  .free-tier-head .primary { align-self: flex-start; }
  .free-compare, .free-compare ul:last-child { grid-template-columns: 1fr; }
}
