:root {
  --ground: #F4F7F9;
  --surface: #FFFFFF;
  --ink: #1C2733;
  --body: #2B3743;
  --muted: #566472;
  --line: #DFE6EB;
  --border: #C3CDD5;
  --divider-dark: #33414F;
  --accent: #2A74A8;
  --accent-hover: #1F5A85;
  --tint: #DCEBF6;
  --on-tint: #174A6E;
  --point: #F5C39B;
  --on-point: #5C2C0A;

  --font-head: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;

  --max: 1120px;
  --pad: 32px;
  --radius-card: 22px;
}

@media (max-width: 600px) {
  :root { --pad: 20px; }
}

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

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--body);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--ink);
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
}

p { margin: 0; }

a { color: var(--accent); }
a:hover { color: var(--accent-hover); }

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

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

.wrap {
  max-width: calc(var(--max) + var(--pad) * 2);
  margin: 0 auto;
  padding: 0 var(--pad);
}

/* Header */
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 80px;
}
.logo {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.logo img { display: block; height: 32px; width: auto; }
.header-link {
  font-weight: 600;
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
}
.header-link:hover { color: var(--accent); }

/* Hero */
.hero { padding: 56px 0 96px; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 24px;
}
.eyebrow svg { flex: none; }
.hero h1 {
  font-size: clamp(40px, 6.4vw, 84px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  max-width: 12ch;
}
.hero-sub {
  font-size: clamp(18px, 2vw, 20px);
  max-width: 34em;
  margin-top: 24px;
}

.signup { margin-top: 40px; max-width: 520px; }
.signup-label {
  display: block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 18px;
  color: var(--ink);
  margin-bottom: 12px;
}
.signup-row { display: flex; gap: 8px; }
.signup-row input { flex: 1; min-width: 0; }
.fine {
  font-size: 14px;
  color: var(--muted);
  margin-top: 12px;
}

/* Inputs and buttons */
input[type="email"], input[type="text"], input[type="url"], textarea {
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  min-height: 52px;
  padding: 0 22px;
  width: 100%;
}
textarea {
  border-radius: 22px;
  padding: 14px 22px;
  min-height: 120px;
  resize: vertical;
}
input::placeholder, textarea::placeholder { color: var(--muted); }
input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}

.btn {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  white-space: nowrap;
}
.btn:hover { background: var(--accent-hover); }
.btn[disabled] { opacity: 0.7; cursor: progress; }
.btn-dark { background: var(--ink); }
.btn-dark:hover { background: var(--accent-hover); }

.form-status {
  margin-top: 12px;
  font-size: 15px;
  font-weight: 500;
  border-radius: 16px;
  padding: 12px 18px;
}
.form-status[hidden] { display: none; }
.form-status.is-ok { background: var(--tint); color: var(--on-tint); }
.form-status.is-error { background: var(--surface); color: var(--on-point); border: 1px solid var(--point); }

@media (max-width: 480px) {
  .signup-row { flex-direction: column; }
  .signup-row .btn { width: 100%; }
}

/* What Puddle is */
.about { padding-bottom: 96px; }
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 32px;
}
.card h2 { font-size: 24px; font-weight: 600; margin-bottom: 10px; }
.card p { font-size: 17px; }
@media (max-width: 860px) {
  .cards { grid-template-columns: 1fr; }
}

/* Five checks */
.checks {
  background: var(--ink);
  color: #fff;
  padding: 96px 0;
}
.checks h2 {
  color: #fff;
  font-size: clamp(34px, 4.6vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.checks-intro {
  font-size: clamp(17px, 1.8vw, 19px);
  color: var(--border);
  max-width: 40em;
  margin-top: 20px;
}
.check-list {
  list-style: none;
  margin: 56px 0 0;
  padding: 0;
  border-top: 1px solid var(--divider-dark);
}
.check-list li {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 16px;
  align-items: baseline;
  padding: 24px 0;
  border-bottom: 1px solid var(--divider-dark);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.4;
}
.check-num {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--point);
  font-size: clamp(22px, 2.4vw, 28px);
  letter-spacing: -0.02em;
}
@media (max-width: 480px) {
  .check-list li { grid-template-columns: 48px 1fr; }
}

/* Makers */
.makers { padding: 96px 0; scroll-margin-top: 16px; }
.makers-panel {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 48px;
}
.makers h2 {
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.makers-text { margin-top: 20px; font-size: 18px; }
.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: var(--ink);
  margin-bottom: 6px;
}
.field .optional { font-weight: 400; color: var(--muted); }
.mom-check {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--point);
  color: var(--on-point);
  font-weight: 600;
  border-radius: 999px;
  min-height: 52px;
  padding: 0 22px;
  margin-bottom: 20px;
  cursor: pointer;
}
.mom-check input {
  width: 22px; height: 22px;
  margin: 0;
  accent-color: var(--on-point);
  flex: none;
}
.makers-form .btn { width: 100%; }
@media (max-width: 860px) {
  .makers-panel { grid-template-columns: 1fr; gap: 32px; padding: 32px 24px; }
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 48px;
  font-size: 15px;
  color: var(--muted);
}
.footer-brand { color: var(--body); }
.footer-brand {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 12px;
}
.footer-logo { display: block; height: 24px; width: auto; }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 600;
}

/* Privacy page */
.prose { max-width: 680px; padding: 32px 0 96px; }
.prose h1 { font-size: clamp(36px, 5vw, 56px); letter-spacing: -0.03em; line-height: 1.05; margin-bottom: 32px; }
.prose h2 { font-size: 22px; font-weight: 600; margin: 32px 0 8px; }
.prose p { font-size: 17px; }

/* Phones: get the signup above the fold, tighten padding, keep tap targets */
@media (max-width: 600px) {
  .site-header .wrap { min-height: 64px; }
  .hero { padding: 16px 0 64px; }
  .eyebrow { font-size: 14px; margin-bottom: 16px; }
  .hero-sub { margin-top: 16px; }
  .signup { margin-top: 28px; }
  .about { padding-bottom: 64px; }
  .card { padding: 24px; }
  .card h2 { font-size: 22px; }
  .checks { padding: 64px 0; }
  .check-list { margin-top: 40px; }
  .check-list li { padding: 20px 0; }
  .makers { padding: 64px 0; }
  .makers-panel { padding: 28px 20px; border-radius: 20px; }
  .makers-text { font-size: 17px; }
  .mom-check { border-radius: 18px; padding: 14px 18px; align-items: flex-start; line-height: 1.35; }
  .mom-check input { margin-top: 1px; }
}

/* ---------- Landing: maker call to action ---------- */
.makers-cta { display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.makers-cta .btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; color: #fff; }
.makers-cta .btn:hover { color: #fff; }

/* ---------- Submit page ---------- */
.submit-page { max-width: calc(720px + var(--pad) * 2); padding-top: 24px; padding-bottom: 96px; }
.submit-intro h1 { font-size: clamp(36px, 5vw, 56px); line-height: 1.05; letter-spacing: -0.03em; }
.submit-intro p { margin-top: 16px; font-size: 18px; }
.submit-intro .fine { font-size: 15px; margin-top: 12px; }

.submit-form { margin-top: 40px; }
.section {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  padding: 28px 32px 12px;
  margin: 0 0 20px;
  min-width: 0;
}
.section legend {
  float: left;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 22px;
  color: var(--ink);
  padding: 0;
  margin-bottom: 20px;
}
.section legend + * { clear: both; }
.section legend .optional { font-family: var(--font-body); font-size: 15px; font-weight: 400; }
.section-num {
  display: inline-grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 999px;
  background: var(--tint);
  color: var(--on-tint);
  font-size: 15px;
  font-weight: 700;
  flex: none;
}
.section-hint { margin: -8px 0 16px; }
.field { margin-bottom: 20px; }
.field .label, .field label:not(.choice) {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: var(--ink);
  margin: 0 0 6px;
}
.label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.counter { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.counter.is-near { color: var(--on-point); font-weight: 600; }
.hint { font-size: 14px; color: var(--muted); margin: -2px 0 8px; }
.field-error { font-size: 14px; color: #A3361F; font-weight: 500; margin: 6px 0 0; }
.field-error:empty { display: none; }
.has-error input[type="text"], .has-error input[type="url"], .has-error input[type="email"] { border-color: #A3361F; }

.choices { display: flex; flex-wrap: wrap; gap: 8px; }
.field .choice {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  cursor: pointer;
  font-weight: 500;
  color: var(--ink);
}
.choice input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.choice:has(input:checked) { border-color: var(--accent); background: var(--tint); color: var(--on-tint); }
.choice:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }

.section .mom-check { margin-bottom: 20px; }

/* Uploads */
.upload { display: flex; flex-wrap: wrap; gap: 12px; align-items: stretch; }
.thumbs { display: contents; }
.thumb {
  position: relative;
  margin: 0;
  width: 112px; height: 200px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--ground);
  overflow: hidden;
}
.thumb-icon { width: 112px; height: 112px; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-icon img { object-fit: contain; }
.thumb-remove {
  position: absolute; top: 6px; right: 6px;
  width: 32px; height: 32px;
  border-radius: 999px; border: 0;
  background: var(--ink); color: #fff;
  display: grid; place-items: center;
  cursor: pointer;
}
.thumb-remove::after { content: ""; position: absolute; inset: -6px; } /* 44px tap area */
.drop {
  display: flex !important;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 4px;
  width: 112px; min-height: 112px;
  padding: 12px;
  border: 1.5px dashed var(--border);
  border-radius: 16px;
  background: var(--ground);
  cursor: pointer;
  margin: 0 !important;
}
.upload[data-kind="screenshots"] .drop { min-height: 200px; }
.drop:hover, .upload.is-drag .drop { border-color: var(--accent); background: var(--tint); }
.upload:focus-within .drop { outline: 3px solid var(--accent); outline-offset: 2px; }
.drop-main { font-weight: 600; color: var(--accent); font-size: 15px; }
.drop-sub { font-size: 13px; color: var(--muted); font-weight: 400; }
.drop[hidden] { display: none !important; }

.error-summary {
  border: 1.5px solid #A3361F;
  border-radius: 20px;
  background: var(--surface);
  padding: 20px 24px;
  margin-top: 32px;
}
.error-summary h2 { font-size: 18px; color: #A3361F; margin-bottom: 8px; }
.error-summary ul { margin: 0; padding-left: 20px; }
.error-summary li { margin: 4px 0; }
.error-summary a { color: #A3361F; font-weight: 500; }

.submit-footer { margin-top: 8px; }
.btn-wide { width: 100%; }
#turnstile:empty { display: none; }
#turnstile { margin-bottom: 12px; }

.submit-done {
  margin-top: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 48px 32px;
  text-align: center;
}
.submit-done h2 { font-size: clamp(32px, 4vw, 44px); letter-spacing: -0.03em; }
.submit-done p { margin: 12px 0 28px; font-size: 18px; }
.submit-done .btn { display: inline-flex; align-items: center; text-decoration: none; color: #fff; }

@media (max-width: 600px) {
  .submit-page { padding-top: 8px; padding-bottom: 64px; }
  .section { padding: 24px 20px 4px; border-radius: 20px; }
  .section legend { font-size: 20px; }
  .choices { flex-direction: column; }
  .choice { width: 100%; }
  .thumb, .drop { width: calc((100% - 24px) / 3); }
  .thumb-icon, .upload[data-kind="icon"] .drop { width: 112px; }
  .thumb, .upload[data-kind="screenshots"] .drop { height: auto; aspect-ratio: 9 / 16; min-height: 0; }
  .thumb-icon { aspect-ratio: 1; height: 112px; }
}

/* ---------- Header nav ---------- */
.header-nav { display: flex; align-items: center; gap: 20px; }

/* ---------- App list (home + /apps) ---------- */
.app-list { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; overflow: hidden; }
.app-list li + li { border-top: 1px solid var(--line); }
.app-row { display: flex; align-items: center; gap: 16px; padding: 18px 24px; color: inherit; text-decoration: none; min-height: 96px; }
.app-row:hover { background: var(--ground); color: inherit; }
.app-row:hover .app-row-name { color: var(--accent); }
.app-row:focus-visible { outline-offset: -3px; }
.app-row-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.app-row-name { font-family: var(--font-head); font-weight: 600; font-size: 20px; color: var(--ink); letter-spacing: -0.01em; }
.app-row-tagline { color: var(--body); margin-top: 2px; }
.app-row-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 14px; color: var(--muted); margin-top: 6px; }
.app-row-arrow { color: var(--border); flex: none; }
.app-icon { flex: none; display: block; border-radius: 22%; border: 1px solid var(--line); object-fit: cover; background: var(--surface); }
.app-icon-md { width: 64px; height: 64px; }
.app-icon-lg { width: 96px; height: 96px; }
.app-icon-letter { display: grid; place-items: center; background: var(--tint); color: var(--on-tint); font-family: var(--font-head); font-weight: 700; border-color: transparent; }
.app-icon-md.app-icon-letter { font-size: 28px; }
.app-icon-lg.app-icon-letter { font-size: 42px; }
.mom-tag { display: inline-flex; align-items: center; background: var(--point); color: var(--on-point); border-radius: 999px; padding: 2px 10px; font-size: 13px; font-weight: 600; }

/* Home section */
.new-apps { padding-bottom: 96px; }
.new-apps-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.new-apps-head h2 { font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -0.03em; }
.see-all { font-weight: 600; display: inline-flex; align-items: center; min-height: 44px; }

/* /apps */
.apps-page { padding-top: 24px; padding-bottom: 96px; max-width: calc(880px + var(--pad) * 2); }
.apps-page h1 { font-size: clamp(36px, 5vw, 56px); letter-spacing: -0.03em; line-height: 1.05; }
.apps-sub { font-size: 18px; margin-top: 12px; max-width: 36em; }
.apps-count { color: var(--muted); font-size: 15px; margin: 32px 0 12px; }
.apps-empty { margin-top: 32px; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 32px; }
.apps-empty p { font-size: 18px; margin-bottom: 16px; }
.apps-empty .btn, .btn-open { display: inline-flex; align-items: center; text-decoration: none; color: #fff; }

/* /apps/<slug> */
.preview-bar { margin-top: 8px; padding: 12px 20px !important; background: var(--point); color: var(--on-point); border-radius: 14px; font-weight: 600; max-width: calc(880px) !important; }
.app-page { padding-top: 16px; padding-bottom: 96px; max-width: calc(880px + var(--pad) * 2); }
.back-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 600; text-decoration: none; }
.back-link::before { content: ""; width: 8px; height: 8px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-right: 2px; }
.app-head { display: flex; gap: 24px; align-items: flex-start; margin-top: 16px; }
.app-head h1 { font-size: clamp(34px, 4.6vw, 52px); letter-spacing: -0.03em; line-height: 1.05; }
.app-tagline { font-size: clamp(18px, 2vw, 21px); margin-top: 8px; }
.app-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag { display: inline-flex; align-items: center; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 2px 12px; font-size: 14px; color: var(--body); }
.tag-founding { background: var(--tint); color: var(--on-tint); border-color: transparent; font-weight: 600; }
.btn-open { margin-top: 28px; gap: 10px; flex-wrap: wrap; justify-content: center; }
.btn-open:hover { color: #fff; }
.btn-host { font-weight: 400; opacity: 0.85; font-size: 14px; }
.app-shots { display: flex; gap: 12px; overflow-x: auto; margin-top: 32px; padding-bottom: 8px; scroll-snap-type: x mandatory; }
.app-shots img { height: 420px; width: auto; border-radius: 20px; border: 1px solid var(--line); scroll-snap-align: start; flex: none; background: var(--surface); }
.app-section { margin-top: 48px; }
.app-section h2 { font-size: clamp(24px, 3vw, 32px); letter-spacing: -0.02em; margin-bottom: 12px; }
.maker-name { font-weight: 600; color: var(--ink); }
.maker-story { margin: 16px 0 0; padding: 20px 24px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--point); border-radius: 0 20px 20px 0; font-size: 18px; }
.maker-story p + p { margin-top: 10px; }
.checked-by { display: flex; gap: 8px; align-items: flex-start; color: var(--accent); font-weight: 500; }
.checked-by svg { flex: none; margin-top: 3px; }
.check-items { list-style: none; margin: 20px 0 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; }
.check-item { display: grid; grid-template-columns: 48px 1fr; gap: 12px; padding: 20px 24px; }
.check-item + .check-item { border-top: 1px solid var(--line); }
.check-item .check-num { font-family: var(--font-head); font-weight: 700; color: var(--accent); font-size: 20px; }
.check-item h3 { font-size: 18px; font-weight: 600; }
.check-item p { margin-top: 4px; }
.data-box { margin-top: 12px; background: var(--tint); color: var(--on-tint); border-radius: 16px; padding: 14px 16px; }
.data-box h4 { margin: 0; font-size: 14px; font-family: var(--font-body); color: var(--on-tint); }
.data-box p { margin: 4px 0 6px; }
.data-box a { color: var(--on-tint); font-weight: 600; }

@media (max-width: 600px) {
  .header-nav { gap: 12px; }
  .app-row { padding: 16px; gap: 14px; }
  .app-icon-md { width: 56px; height: 56px; }
  .app-row-name { font-size: 18px; }
  .app-row-arrow { display: none; }
  .new-apps { padding-bottom: 64px; }
  .app-head { gap: 16px; }
  .app-icon-lg { width: 72px; height: 72px; }
  .btn-open { width: 100%; }
  .app-shots img { height: 360px; }
  .check-item { grid-template-columns: 36px 1fr; padding: 18px 16px; }
  .maker-story { padding: 16px 18px; font-size: 17px; }
}
