/* Common Ground — two overlapping circles are the one signature element;
   everything else stays quiet: cool paper, navy ink, rows instead of cards. */

:root {
  --ink: #254e40;
  --ink-strong: #173b30;
  --text: #1c2433;
  --muted: #5a6577;
  --paper: #f8f7f2;
  --surface: #ffffff;
  --line: #dedfd5;
  --teal: #78936b;
  --teal-soft: #e6eddc;
  --overlap: #47613b;
  --danger: #b42318;
  --danger-soft: #fdecea;
  --focus: #f2a900;
  --radius-s: 6px;
  --radius-m: 10px;
  --display: "Avenir Next", Avenir, "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 16px/1.55 var(--body);
}
.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }
main.wrap { padding-top: 28px; padding-bottom: 64px; min-height: 70vh; }

h1, h2, h3 { font-family: var(--display); color: var(--ink-strong); line-height: 1.2; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.75rem, 1.2rem + 2vw, 2.4rem); font-weight: 700; margin: 0 0 12px; }
h2 { font-size: 1.3rem; font-weight: 650; margin: 32px 0 10px; }
h3 { font-size: 1.05rem; font-weight: 650; margin: 0 0 4px; }
p { margin: 0 0 12px; max-width: 72ch; }
a { color: var(--ink); text-underline-offset: 2px; }
a:hover { color: var(--overlap); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
.small, .hint { font-size: 0.875rem; color: var(--muted); }
.hint { display: block; font-weight: 400; margin-top: 2px; }
.req { font-size: 0.8rem; font-weight: 500; color: var(--overlap); margin-left: 4px; }
.lede { font-size: 1.15rem; color: var(--muted); }
.meta { color: var(--muted); font-size: 0.9rem; margin: 0 0 6px; }
.headline { margin: 0 0 4px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* ---- header / footer ---- */
header.site { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.15rem; color: var(--ink-strong); }
header nav { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }
header nav a, .linkish { padding: 8px 10px; border-radius: var(--radius-s); text-decoration: none; color: var(--text); font: inherit; background: none; border: 0; cursor: pointer; }
header nav a:hover, .linkish:hover { background: var(--paper); color: var(--ink); }
header nav a.active { color: var(--ink-strong); font-weight: 600; box-shadow: inset 0 -3px 0 var(--teal); border-radius: 0; }
.badge { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 10px; background: var(--teal); color: #fff; font-size: 0.75rem; text-align: center; line-height: 20px; }
footer.site { border-top: 1px solid var(--line); padding: 24px 0 40px; color: var(--muted); font-size: 0.875rem; }

/* ---- buttons & forms ---- */
.button { display: inline-block; padding: 10px 18px; border-radius: var(--radius-s); border: 1px solid var(--ink); background: var(--ink); color: #fff; font: 600 0.95rem var(--body); text-decoration: none; cursor: pointer; }
.button:hover { background: var(--ink-strong); color: #fff; }
.button.ghost { background: transparent; color: var(--ink); }
.button.ghost:hover { background: var(--surface); color: var(--ink-strong); }
.button.small { padding: 6px 12px; font-size: 0.875rem; }
.button.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.button.danger:hover { background: #8f1c13; }

form.stack, .stack { display: grid; gap: 16px; }
label { display: block; font-weight: 600; color: var(--ink-strong); }
label > input, label > select, label > textarea { display: block; margin-top: 6px; }
input[type=text], input[type=email], input[type=url], input[type=search], select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #b9c4d3; border-radius: var(--radius-s);
  font: 400 1rem var(--body); color: var(--text); background: var(--surface);
}
textarea { resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); }
fieldset { border: 0; border-top: 1px solid var(--line); padding: 18px 0 0; margin: 8px 0 0; min-width: 0; }
legend { font-family: var(--display); font-weight: 650; font-size: 1.05rem; color: var(--ink-strong); padding: 0 8px 0 0; }
.grid2 { display: grid; gap: 16px; grid-template-columns: 2fr 1fr; }
.form-page, .narrow { max-width: 720px; }
.narrow { margin-top: 24px; }
.actions { padding-top: 8px; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; color: var(--text); margin-top: 8px; }
label.check input { margin-top: 4px; width: 18px; height: 18px; flex: none; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 12px; }
.chip { display: inline-flex; font-weight: 400; cursor: pointer; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span { padding: 6px 12px; border: 1px solid #b9c4d3; border-radius: 999px; background: var(--surface); font-size: 0.9rem; color: var(--text); }
.chip input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.other { font-weight: 400; font-size: 0.9rem; color: var(--muted); }

.errors { background: var(--danger-soft); border-left: 4px solid var(--danger); padding: 12px 16px; border-radius: var(--radius-s); color: #6b140d; max-width: 72ch; }
.errors ul { margin: 4px 0 0; padding-left: 20px; }
.errors p { margin: 0; }
.notice { background: var(--teal-soft); border-left: 4px solid var(--teal); padding: 10px 16px; border-radius: var(--radius-s); color: #0d4d48; }
.devbox { margin-top: 20px; border: 2px dashed var(--focus); padding: 12px 16px; border-radius: var(--radius-s); background: #fff8e6; }
.empty { color: var(--muted); }
div.empty { padding: 24px; border: 1px dashed var(--line); border-radius: var(--radius-m); background: var(--surface); }

/* ---- the signature: overlapping circles ---- */
.overlap { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; flex: none; }
.overlap svg { display: block; overflow: visible; }
.ov-a { fill: var(--ink); fill-opacity: 0.9; }
.ov-b { fill: var(--teal); fill-opacity: 0.55; }
.ov-mid { fill: var(--overlap); }
.overlap-score { font: 700 1.05rem var(--display); color: var(--ink-strong); line-height: 1; }
.overlap-score small { font-size: 0.7em; font-weight: 600; color: var(--muted); }

/* ---- landing ---- */
.hero { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; padding: 32px 0 24px; }
.hero h1 { font-size: clamp(2rem, 1.3rem + 3vw, 3.1rem); line-height: 1.08; letter-spacing: -0.02em; }
.venn-big { position: relative; aspect-ratio: 1.45; width: 100%; max-width: 440px; margin: 0 auto; }
.venn-big span { position: absolute; display: flex; align-items: center; font: 600 0.95rem var(--display); }
.venn-big .v1, .venn-big .v2 { top: 0; width: 69%; aspect-ratio: 1; border-radius: 50%; padding: 0 9%; }
.venn-big .v1 { left: 0; background: var(--ink); color: #fff; justify-content: flex-start; }
.venn-big .v2 { right: 0; background: rgba(43, 165, 154, 0.55); color: var(--ink-strong); justify-content: flex-end; mix-blend-mode: multiply; }
.venn-big .v3 { left: 50%; top: 47.5%; transform: translate(-50%, -50%); color: #fff; font-size: 0.85rem; text-align: center; width: 30%; justify-content: center; line-height: 1.2; }
.steps ol { padding-left: 22px; max-width: 72ch; }
.steps li { margin-bottom: 8px; }
.promises ul { padding-left: 20px; max-width: 72ch; }

/* ---- lists ---- */
.page-head { margin-bottom: 16px; }
.match-list, .people-list, .idea-list, .conn-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.match, .people-list li, .idea-row, .conn-list li {
  display: grid; gap: 18px; padding: 18px 4px; border-bottom: 1px solid var(--line); align-items: start;
}
.match { grid-template-columns: 72px 1fr auto; }
.match h2, .people-list h2 { margin: 0 0 2px; font-size: 1.15rem; }
.match h2 a, .people-list h2 a, .idea-row h3 a { text-decoration: none; }
.match h2 a:hover, .people-list h2 a:hover, .idea-row h3 a:hover { text-decoration: underline; }
.match-action { align-self: center; }
.reasons { margin: 8px 0 0; display: grid; gap: 4px; }
.reason { display: grid; grid-template-columns: minmax(150px, 220px) 1fr; gap: 10px; font-size: 0.9rem; }
.reason dt { color: var(--muted); }
.reason dd { margin: 0; }
.r-offer dd, .r-need dd { color: var(--overlap); font-weight: 600; }
.people-list li { grid-template-columns: 48px 1fr auto; }
.idea-row { grid-template-columns: 56px 1fr; }
.idea-list .idea-row:not(:has(.overlap)) { grid-template-columns: 1fr; }
.conn-list li { grid-template-columns: 1fr auto; }
.conn-list p { margin: 0 0 4px; }
.conn-list .meta { margin-left: 6px; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
blockquote { margin: 6px 0 0; padding: 6px 12px; border-left: 3px solid var(--line); color: var(--text); background: var(--surface); }
.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.idea-suggest { margin-top: 40px; }

.avatar { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--teal-soft); color: var(--ink-strong); font: 700 0.95rem var(--display); }
.avatar.big { width: 72px; height: 72px; font-size: 1.4rem; }

.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 0; padding: 0; }
.tags li { font-size: 0.82rem; padding: 2px 10px; border-radius: 999px; background: #e8edf5; color: var(--ink-strong); }

.state { font-size: 0.9rem; color: var(--muted); }
.state.ok { color: var(--overlap); font-weight: 600; }

.filters { display: grid; grid-template-columns: 2fr 1fr auto; gap: 12px; align-items: end; margin: 8px 0 20px; }

/* ---- profile & idea pages ---- */
.profile-head { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.profile-head h1 { margin-bottom: 4px; }
.profile-score { display: grid; justify-items: center; gap: 2px; }
.facets { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 24px; }
.contact-box { margin-top: 32px; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-m); max-width: 720px; }
.contact-box h2 { margin-top: 0; }
.contact { padding-left: 18px; }
.connect-form { max-width: 560px; }
details.report { margin-top: 28px; color: var(--muted); max-width: 560px; }
details.report summary { cursor: pointer; font-size: 0.9rem; }
details.report form { margin-top: 12px; }

.danger-zone { margin-top: 40px; padding-top: 8px; border-top: 1px solid var(--line); }
.account-links { padding-left: 18px; }

.prose { max-width: 72ch; }
.prose li { margin-bottom: 6px; }
table { border-collapse: collapse; width: 100%; font-size: 0.9rem; background: var(--surface); }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 600; }
tr.resolved { color: var(--muted); }
.admin { overflow-x: auto; }
.stats { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 24px; }
.stats strong { font: 700 1.4rem var(--display); color: var(--ink-strong); margin-right: 4px; }

/* ---- small screens ---- */
@media (max-width: 720px) {
  .hero { grid-template-columns: 1fr; gap: 24px; padding-top: 8px; }
  .hero-art { order: -1; width: 100%; max-width: 320px; }
  .venn-big span { font-size: 0.74rem; }
  .venn-big .v1, .venn-big .v2 { padding: 0 6%; }
  .venn-big .v3 { font-size: 0.7rem; }
  .grid2, .filters { grid-template-columns: 1fr; }
  .match { grid-template-columns: 56px 1fr; }
  .match-action { grid-column: 2; }
  .people-list li { grid-template-columns: 44px 1fr; }
  .people-list .match-action { grid-column: 2; }
  .reason { grid-template-columns: 1fr; gap: 0; }
  .profile-head { grid-template-columns: auto 1fr; }
  .profile-score { grid-column: 1 / -1; justify-items: start; grid-auto-flow: column; align-items: center; gap: 8px; }
  .conn-list li { grid-template-columns: 1fr; }
  .site-inner { gap: 4px; padding-top: 8px; }
  header nav { gap: 0; margin: 0 -6px; }
  header nav a { padding: 8px 6px; font-size: 0.95rem; }
}

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

/* Onboarding */
.eyebrow {font-size:.72rem;letter-spacing:.17em;font-weight:700;color:var(--overlap);margin-bottom:14px}
.hero {padding-block:44px}.hero h1 {max-width:19ch;font-family:Georgia,serif;font-weight:400;font-size:clamp(2.4rem,5vw,3.7rem)}
.question-section {padding-top:28px}.question {margin:24px 0}.section-number {color:var(--overlap);font-size:.8rem;margin-right:8px}
.values-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-top:20px}
.snapshot {background:var(--teal-soft);padding:28px;border-radius:18px;margin:24px 0}.snapshot h2 {font-family:Georgia,serif;font-size:2.8rem;margin:8px 0 14px;font-weight:400}
.snapshot dt {font-size:.8rem;color:var(--muted);margin-top:18px}.snapshot dd {margin:3px 0;font-weight:600}.text-link {margin-left:12px}
.linkedin {display:flex;align-items:center;justify-content:center;gap:12px;background:#0a66c2;border-color:#0a66c2}.linkedin-icon {font-weight:800;font-size:1.25rem}
.login-detail {margin-top:24px}.pilot-banner {padding:10px 16px;background:var(--teal-soft);border-radius:8px}
@media(max-width:500px){.values-grid{grid-template-columns:1fr}.snapshot{padding:22px}.hero{padding-block:20px}.text-link{display:inline-block;margin:14px 0}}

.table-scroll{overflow-x:auto;margin:24px 0}.access-table th,.access-table td{vertical-align:top;overflow-wrap:anywhere}.access-json{white-space:pre-wrap;overflow-wrap:anywhere;padding:18px;background:var(--teal-soft);border-radius:10px;font-size:.8rem}
