/* NeatCells website. System fonts, no frameworks, light and dark. */

:root {
  --bg: #ffffff;
  --bg-soft: #f2f7f6;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #475569;
  --line: #dbe4e3;
  --brand: #0f766e;
  --brand-strong: #115e59;
  --brand-soft: #ccfbf1;
  --on-brand: #ffffff;
  --link: #0f6b64;
  --warn-bg: #fff7e6;
  --warn-line: #f2c46d;
  --code-bg: #eef3f2;
  --shadow: 0 1px 2px rgb(15 23 42 / 6%), 0 8px 24px rgb(15 23 42 / 6%);
  --radius: 12px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1220;
    --bg-soft: #0f1b24;
    --card: #111c27;
    --text: #e6edf3;
    --muted: #a3b3c2;
    --line: #22313d;
    --brand: #2dd4bf;
    --brand-strong: #5eead4;
    --brand-soft: #134e4a;
    --on-brand: #04201d;
    --link: #5eead4;
    --warn-bg: #2a2110;
    --warn-line: #8a6a2b;
    --code-bg: #15222d;
    --shadow: none;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    17px/1.6 system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Noto Sans',
    'Helvetica Neue',
    Arial,
    sans-serif;
}

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

a {
  color: var(--link);
  text-underline-offset: 2px;
}

h1,
h2,
h3 {
  line-height: 1.2;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2rem, 4.5vw, 3.1rem);
  margin: 0 0 0.5em;
}

h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  margin: 2em 0 0.6em;
}

h3 {
  font-size: 1.15rem;
  margin: 1.6em 0 0.4em;
}

code,
kbd {
  font-family: ui-monospace, 'Cascadia Code', Consolas, monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  border-radius: 6px;
  padding: 0.1em 0.35em;
}

kbd {
  border: 1px solid var(--line);
}

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px;
}

.narrow {
  max-width: 760px;
}

.skip {
  position: absolute;
  left: -999px;
}

.skip:focus {
  left: 16px;
  top: 8px;
  background: var(--card);
  padding: 8px 12px;
  z-index: 10;
}

/* Header and footer */

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
}

.site-header ul,
.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
}

.site-header nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.site-header nav a:hover,
.site-header nav a[aria-current='page'] {
  color: var(--brand);
}

.site-footer {
  margin-top: 72px;
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 28px 0 40px;
  font-size: 0.9rem;
  color: var(--muted);
}

.site-footer p {
  max-width: 760px;
}

/* Buttons */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--on-brand);
}

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

.button.disabled {
  opacity: 0.65;
  cursor: default;
  pointer-events: none;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 24px 0;
}

/* Home */

.hero {
  background: linear-gradient(180deg, var(--bg-soft), var(--bg));
  padding: 56px 0 24px;
}

.hero p.lead {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 720px;
}

.hero .accent {
  color: var(--brand);
}

.shot {
  margin: 32px 0 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  background: var(--card);
}

.shot img {
  display: block;
  width: 100%;
}

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

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

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}

.card h2,
.card h3 {
  margin-top: 0;
}

.card p:last-child {
  margin-bottom: 0;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.steps li {
  counter-increment: step;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 20px 20px 64px;
  position: relative;
}

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

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  list-style: none;
}

.chips li {
  background: var(--brand-soft);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 0.95rem;
}

/* Pricing */

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

.plan {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.plan.featured {
  border: 2px solid var(--brand);
}

.plan h2 {
  font-size: 1.35rem;
  margin-bottom: 0;
}

.plan .price {
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
}

.plan .price small {
  font-size: 1rem;
  font-weight: 500;
  color: var(--muted);
}

.plan .button {
  margin-top: auto;
}

.badge {
  display: inline-block;
  background: var(--brand-soft);
  color: var(--text);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.85rem;
  font-weight: 600;
}

table {
  border-collapse: collapse;
  width: 100%;
  margin: 16px 0;
  font-size: 0.97rem;
}

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

thead th {
  background: var(--bg-soft);
}

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

/* Text pages: policies and guides */

.prose {
  padding-top: 40px;
}

.prose p,
.prose li {
  max-width: 72ch;
}

.prose li + li {
  margin-top: 0.3em;
}

.meta {
  color: var(--muted);
  font-size: 0.95rem;
}

.callout {
  background: var(--warn-bg);
  border: 1px solid var(--warn-line);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin: 20px 0;
}

.summary {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 20px 0;
}

.summary > :first-child {
  margin-top: 0;
}

.summary > :last-child {
  margin-bottom: 0;
}

.crumbs {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0 0 12px;
}

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

details {
  border-bottom: 1px solid var(--line);
  padding: 12px 0;
}

summary {
  cursor: pointer;
  font-weight: 600;
}

details > :not(summary) {
  margin-bottom: 0;
}

.guide-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.guide-list a {
  font-weight: 600;
}

/* Survey */

fieldset {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 0 0 20px;
}

legend {
  font-weight: 600;
  padding: 0 6px;
}

.choice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 6px 0;
}

.choice input {
  margin-top: 0.45em;
}

textarea {
  width: 100%;
  min-height: 120px;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  color: var(--text);
}

.hidden-field {
  position: absolute;
  left: -9999px;
}

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

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }

  .hero {
    padding-top: 32px;
  }
}
