:root {
  --bg: #f6f7f6;
  --surface: #ffffff;
  --surface-2: #eef2f1;
  --text: #14191a;
  --muted: #586366;
  --line: #e0e5e4;
  --brand: #3f7c84;
  --brand-strong: #2d5f66;
  --on-brand: #ffffff;
  --radius: 20px;
  --shadow: 0 1px 2px rgb(20 25 26 / 0.06), 0 12px 32px -12px rgb(20 25 26 / 0.18);
  --max: 1080px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1213;
    --surface: #161b1c;
    --surface-2: #1d2425;
    --text: #edf1f1;
    --muted: #9ba7a9;
    --line: #273032;
    --brand: #7db6be;
    --brand-strong: #a3cfd5;
    --on-brand: #0e1213;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 12px 32px -12px rgb(0 0 0 / 0.6);
    color-scheme: dark;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--brand-strong);
  text-underline-offset: 3px;
}

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

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand img {
  width: 32px;
  height: 32px;
  border-radius: 9px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 15px;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
}

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

.site-nav a.button,
.site-nav a.button:hover {
  color: var(--on-brand);
}

.site-nav a.button.secondary {
  color: var(--text);
  background: var(--surface);
  border-color: var(--line);
}

.site-nav a.button.secondary:hover {
  color: var(--text);
  background: var(--surface-2);
}

@media (max-width: 640px) {
  .site-nav .optional {
    display: none;
  }
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: var(--brand);
  color: var(--on-brand);
  font: inherit;
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, transform 0.15s;
}

.button:hover {
  background: var(--brand-strong);
}

.button:active {
  transform: scale(0.98);
}

.button.secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.button.secondary:hover {
  background: var(--surface-2);
}

.button.small {
  min-height: 38px;
  padding: 0 16px;
  font-size: 14px;
}

.button svg {
  width: 18px;
  height: 18px;
  flex: none;
}

:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
}

/* ---------- Hero ---------- */

.hero {
  padding: 72px 0 48px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  margin: 0 0 16px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
}

h1 {
  margin: 0 auto;
  max-width: 14ch;
  font-size: clamp(40px, 7vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 800;
}

.lede {
  margin: 20px auto 0;
  max-width: 34rem;
  color: var(--muted);
  font-size: 19px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

/* ---------- Live palette ---------- */

.palette-demo {
  margin: 56px auto 0;
  max-width: 920px;
}

.swatches {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  height: 340px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.swatch {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  padding: 16px 6px;
  transition: background-color 0.45s ease;
}

.swatch button {
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
  border-radius: 8px;
}

.swatch .hex {
  padding: 4px 8px;
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, monospace;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.swatch .hex:hover {
  background: rgb(127 127 127 / 0.18);
}

.swatch .lock {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  opacity: 0.55;
}

.swatch .lock:hover,
.swatch .lock[aria-pressed="true"] {
  opacity: 1;
}

.swatch .lock svg {
  width: 20px;
  height: 20px;
}

.demo-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 16px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 15px;
}

kbd {
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--surface);
  font-family: inherit;
  font-size: 13px;
}

@media (max-width: 640px) {
  .hero {
    padding-top: 48px;
  }
  .swatches {
    height: 240px;
  }
  .swatch {
    padding: 10px 2px;
  }
  .swatch .hex {
    font-size: 11px;
    padding: 4px 2px;
  }
  .hide-mobile {
    display: none;
  }
}

/* ---------- Sections ---------- */

section {
  padding: 72px 0;
}

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

h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.025em;
  font-weight: 750;
}

.section-head p {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.feature {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.feature .icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--brand-strong);
}

.feature .icon svg {
  width: 22px;
  height: 22px;
}

.feature h3 {
  margin: 16px 0 6px;
  font-size: 18px;
  letter-spacing: -0.01em;
}

.feature p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

/* ---------- Plans ---------- */

.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.plan {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.plan.pro {
  border-color: var(--brand);
  box-shadow: var(--shadow);
}

.plan h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 22px;
}

.plan .note {
  margin: 4px 0 20px;
  color: var(--muted);
  font-size: 15px;
}

.badge {
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--brand);
  color: var(--on-brand);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.checks {
  margin: 0;
  padding: 0;
  list-style: none;
}

.checks li {
  position: relative;
  padding: 8px 0 8px 30px;
  border-top: 1px solid var(--line);
  font-size: 16px;
}

.checks li:first-child {
  border-top: 0;
}

.checks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 15px;
  width: 14px;
  height: 8px;
  border-left: 2.5px solid var(--brand);
  border-bottom: 2.5px solid var(--brand);
  transform: rotate(-45deg);
}

.checks li.minus::before {
  top: 19px;
  height: 0;
  border-left: 0;
  transform: none;
  border-color: var(--muted);
}

/* ---------- Closing CTA ---------- */

.closing {
  text-align: center;
}

.closing .button {
  margin-top: 28px;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 32px 0 48px;
  color: var(--muted);
  font-size: 15px;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.site-footer a {
  color: var(--muted);
}

/* ---------- Long-form pages (privacy, deletion) ---------- */

.doc {
  max-width: 44rem;
  padding: 56px 0 72px;
}

.doc h1 {
  max-width: none;
  font-size: clamp(34px, 5vw, 48px);
}

.doc .updated {
  margin: 12px 0 32px;
  color: var(--muted);
}

.doc h2 {
  margin: 44px 0 12px;
  font-size: 24px;
}

.doc h3 {
  margin: 28px 0 8px;
  font-size: 18px;
}

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

.doc ul,
.doc ol {
  padding-left: 22px;
}

.doc li {
  margin: 6px 0;
}

.doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 15px;
}

.doc th,
.doc td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px 10px 0;
  border-bottom: 1px solid var(--line);
}

.doc th {
  color: var(--muted);
  font-weight: 600;
}

.table-scroll {
  overflow-x: auto;
}

.callout {
  margin: 24px 0;
  padding: 18px 20px;
  border-radius: 14px;
  background: var(--surface-2);
  border-left: 4px solid var(--brand);
}

.callout p {
  margin: 0;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0 !important;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding: 4px 0 4px 44px;
  margin: 14px 0;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 2px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 700;
  font-size: 15px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

/* Scrollbars: a slim pill in the muted ink that floats over the content and
   turns brand teal while dragged. Styled natively (not a JS replacement), so
   wheel, touch, keyboard and screen readers behave exactly as usual. The
   colors follow the light/dark tokens. */
:root {
  --scroll-thumb: color-mix(in srgb, var(--muted) 38%, transparent);
  --scroll-thumb-hover: color-mix(in srgb, var(--muted) 62%, transparent);
  --scroll-thumb-active: var(--brand);
}

/* Chrome, Edge, Safari. */
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

::-webkit-scrollbar-track,
::-webkit-scrollbar-corner {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  min-height: 40px;
  border: 3px solid transparent; /* inset the pill from the edges */
  border-radius: 999px;
  background: var(--scroll-thumb) padding-box;
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--scroll-thumb-hover);
}

::-webkit-scrollbar-thumb:active {
  background-color: var(--scroll-thumb-active);
}

::-webkit-scrollbar-button {
  display: none;
}

/* Firefox. Only where the rules above don't apply: in Chrome, setting these
   standard properties would switch off the custom pill. */
@supports not selector(::-webkit-scrollbar) {
  * {
    scrollbar-width: thin;
    scrollbar-color: var(--scroll-thumb-hover) transparent;
  }
}
