/* LetsSplit — one stylesheet, no external requests.
   Light and dark, because the app supports both. */

:root {
  --accent:      #1DAE5A;
  --accent-ink:  #FFFFFF;
  --bg:          #FFFFFF;
  --surface:     #F5F5F7;
  --surface-2:   #FFFFFF;
  --ink:         #1C1C1E;
  --ink-muted:   #6E6E73;
  --rule:        #E5E5EA;
  --pos:         #1F9D55;
  --neg:         #D2453C;
  --shadow:      0 1px 2px rgb(0 0 0 / .04), 0 8px 24px rgb(0 0 0 / .06);
  --radius:      14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent:     #35C878;
    --accent-ink: #06240F;
    --bg:         #000000;
    --surface:    #131315;
    --surface-2:  #1C1C1E;
    --ink:        #F5F5F7;
    --ink-muted:  #98989F;
    --rule:       #2C2C2E;
    --pos:        #40D782;
    --neg:        #FF6961;
    --shadow:     0 1px 2px rgb(0 0 0 / .5), 0 8px 24px rgb(0 0 0 / .4);
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 720px; margin: 0 auto; padding: 0 24px; }
.wrap--wide { max-width: 960px; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------------------------------------------------------------- header */

.site-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 22px 0;
}

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600; font-size: 17px; color: var(--ink); letter-spacing: -.01em;
}
.brand:hover { text-decoration: none; }

.brand-mark {
  width: 28px; height: 28px; border-radius: 8px; background: var(--accent);
  display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr;
  gap: 2px; padding: 6px;
}
.brand-mark i { background: var(--accent-ink); border-radius: 1px; opacity: .9; }
.brand-mark i:nth-child(1) { opacity: 1; }
.brand-mark i:nth-child(4) { opacity: .55; }

.site-nav { display: flex; gap: 20px; font-size: 15px; }
.site-nav a { color: var(--ink-muted); }

/* ------------------------------------------------------------------ hero */

.hero { padding: 56px 0 40px; text-align: center; }

h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 6vw, 52px); line-height: 1.08;
  letter-spacing: -.03em; font-weight: 700;
}

.lede {
  margin: 0 auto; max-width: 30em;
  font-size: clamp(18px, 2.4vw, 21px); color: var(--ink-muted);
}

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

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 50px; padding: 0 26px; border-radius: 999px;
  font-size: 17px; font-weight: 600; letter-spacing: -.01em;
  background: var(--accent); color: var(--accent-ink);
  border: 1px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; filter: brightness(1.06); }

.btn--quiet {
  background: transparent; color: var(--ink); border-color: var(--rule);
}

.btn[aria-disabled="true"] { opacity: .55; pointer-events: none; }

/* ------------------------------------------------------ the grid picture */

.grid-card {
  margin: 56px auto 0; max-width: 520px;
  background: var(--surface-2); border: 1px solid var(--rule);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px 22px; text-align: left;
  font-variant-numeric: tabular-nums;
}

.grid-card table { width: 100%; border-collapse: collapse; }

.grid-card th {
  font-size: 13px; font-weight: 600; color: var(--ink-muted);
  text-align: right; padding: 0 0 12px; letter-spacing: .01em;
}
.grid-card th:first-child { text-align: left; }

.grid-card td {
  padding: 11px 0; border-top: 1px solid var(--rule);
  text-align: right; font-size: 17px;
}
.grid-card td:first-child { text-align: left; font-weight: 500; }

.grid-card .paid { font-weight: 600; }
.grid-card .owed { color: var(--ink-muted); font-size: 15px; }
.grid-card .nil  { color: var(--ink-muted); opacity: .4; }

.grid-card tfoot td {
  border-top: 2px solid var(--rule); font-weight: 600; font-size: 15px;
  padding-top: 13px;
}
.grid-card .pos { color: var(--pos); }
.grid-card .neg { color: var(--neg); }

.caption {
  margin: 14px 0 0; font-size: 14px; color: var(--ink-muted); text-align: center;
}

/* -------------------------------------------------------------- features */

.features {
  margin: 72px 0 0; padding: 0; list-style: none;
  display: grid; gap: 28px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.features h3 { margin: 0 0 6px; font-size: 17px; font-weight: 600; letter-spacing: -.01em; }
.features p  { margin: 0; font-size: 15px; color: var(--ink-muted); line-height: 1.55; }

/* ----------------------------------------------------------- text pages */

.page { padding: 40px 0 24px; }
.page h1 { font-size: clamp(30px, 5vw, 40px); text-align: left; margin-bottom: 8px; }
.page .updated { color: var(--ink-muted); font-size: 15px; margin: 0 0 40px; }

.page h2 {
  margin: 44px 0 12px; font-size: 21px; font-weight: 650; letter-spacing: -.015em;
  padding-top: 20px; border-top: 1px solid var(--rule);
}
.page h3 { margin: 28px 0 8px; font-size: 17px; font-weight: 650; }
.page p, .page li { color: var(--ink); }
.page ul { padding-left: 22px; }
.page li { margin: 8px 0; }
.page li::marker { color: var(--ink-muted); }

.note {
  background: var(--surface); border: 1px solid var(--rule);
  border-radius: var(--radius); padding: 16px 20px; margin: 28px 0;
  font-size: 15px; color: var(--ink-muted);
}
.note strong { color: var(--ink); }

/* ------------------------------------------------------------ join page */

.join { padding: 64px 0 40px; text-align: center; }

.code-plate {
  display: inline-block; margin: 28px 0 8px; padding: 22px 30px;
  background: var(--surface); border: 1px solid var(--rule);
  border-radius: var(--radius);
  font: 600 clamp(30px, 8vw, 44px)/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .14em; color: var(--ink);
}
.code-plate .sep { opacity: .45; padding: 0 .12em; }

.steps {
  margin: 40px auto 0; max-width: 420px; padding: 0; list-style: none;
  text-align: left; counter-reset: step;
}
.steps li {
  position: relative; padding: 0 0 20px 40px; counter-increment: step;
  font-size: 16px; color: var(--ink-muted);
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 1px;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink);
  font-size: 14px; font-weight: 600;
  display: grid; place-items: center;
}
.steps strong { color: var(--ink); font-weight: 600; }

/* ---------------------------------------------------------------- footer */

.site-foot {
  margin-top: 88px; padding: 28px 0 44px; border-top: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; gap: 8px 24px;
  align-items: center; justify-content: space-between;
  font-size: 14px; color: var(--ink-muted);
}
.site-foot nav { display: flex; gap: 24px; }
.site-foot a { color: var(--ink-muted); }
