/* How Tally works: the public page that explains the idea. Same night-blue,
   glass and ring as the sign-in, so arriving from it feels like one place. */

@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/public-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/public-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/public-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/public-sans-latin-700-normal.woff2") format("woff2"); }

:root {
  --bg: #141a46; --glass: rgba(0, 0, 0, .32); --glass-2: rgba(255, 255, 255, .05);
  --line: rgba(255, 255, 255, .12); --line-strong: rgba(255, 255, 255, .25);
  --text: rgba(255, 255, 255, .88); --strong: #fff; --muted: rgba(255, 255, 255, .64);
  --accent: #c2a9ea; --accent-fill: rgba(136, 106, 181, .75); --accent-line: #886ab5;
  --good: #6ff0e1; --warn: #ffd27a; --soft: #b8c2ff;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; min-height: 100vh; position: relative;
  font: 400 16px/1.6 "Public Sans", system-ui, sans-serif;
  background: var(--bg); color: var(--text);
}
a { color: var(--accent); }
h1, h2, h3 { color: var(--strong); margin: 0; line-height: 1.2; }
p { margin: 0; }
em { font-style: normal; color: var(--strong); }
.i { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* The sign-in's ring, behind the opening screen; clipped so it never widens the page. */
.ring-clip { position: absolute; z-index: 0; top: 0; left: 0; right: 0; height: 1000px; overflow: hidden; pointer-events: none; }
.ring {
  position: absolute; z-index: 0; top: -120px; right: -180px;
  width: min(760px, 110vw); aspect-ratio: 1; border-radius: 50%;
  background: conic-gradient(from 0deg, #ffffff, #ff8ad8, #9b6cf5, #3fd1f0, #ffffff, #f472b6, #b794f4, #ffffff);
  -webkit-mask: radial-gradient(closest-side, transparent 64%, #000 70%, #000 82%, transparent 92%);
          mask: radial-gradient(closest-side, transparent 64%, #000 70%, #000 82%, transparent 92%);
  filter: blur(16px); opacity: .55;
  animation: ring 48s linear infinite;
}
@keyframes ring { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .ring { animation: none; } }

.top, main, .foot { position: relative; z-index: 1; }
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px clamp(16px, 5vw, 72px);
}
.brand { display: flex; align-items: center; gap: 12px; color: #fff; font-size: 20px; font-weight: 700; text-decoration: none; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .12); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22);
}
.brand-mark svg { width: 22px; height: 22px; }
.top-links { display: flex; align-items: center; gap: 24px; }
.top-links a { color: #fff; font-size: 15px; text-decoration: none; white-space: nowrap; }
.top-links a:hover { opacity: .8; }
.top-links .pill { padding: 8px 16px; border: 1px solid var(--line-strong); border-radius: 999px; }

main { width: min(1120px, 100%); margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }

/* ── Opening screen ─────────────────────────────────────────────────────── */
.hero {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center;
  min-height: calc(100vh - 140px); padding: 48px 0 64px;
}
.eyebrow { color: var(--accent); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px; }
.hero h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 600; letter-spacing: -.02em; }
.lead { margin-top: 20px; font-size: 18px; color: var(--muted); max-width: 56ch; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 24px;
  border: 1px solid var(--line-strong); border-radius: 8px; color: #fff; text-decoration: none; font-weight: 500;
  background: rgba(255, 255, 255, .04);
}
.button:hover { background: rgba(255, 255, 255, .1); }
.button.primary { background: var(--accent-fill); border-color: var(--accent-line); }
.button.primary:hover { background: #886ab5; }
a:focus-visible, .button:focus-visible { outline: 2px solid #b69ae0; outline-offset: 3px; }

/* The example statement: what a month looks like once Tally has been through it. */
.demo {
  margin: 0; padding: 20px; border-radius: 16px;
  background: var(--glass); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  box-shadow: 0 8px 32px rgba(31, 38, 135, .37);
}
.demo figcaption { display: flex; justify-content: space-between; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.demo-tag { padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line-strong); font-size: 12px; }
.demo ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.demo li { display: grid; gap: 8px; padding: 14px 16px; border-radius: 10px; background: var(--glass-2); border: 1px solid var(--line); }
.mv { display: flex; justify-content: space-between; gap: 12px; }
.mv-desc { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; color: var(--strong); overflow-wrap: anywhere; }
.mv-amt { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; }
.mv-amt.out { color: #ffb3d6; }
.mv-amt.in { color: var(--good); }
.mv-what { display: inline-flex; align-items: center; gap: 6px; justify-self: start; padding: 3px 10px; border-radius: 999px; font-size: 13px; }
.mv-what .i { width: 15px; height: 15px; stroke-width: 2.4; }
.mv-what.ok { background: rgba(29, 201, 183, .18); color: var(--good); }
.mv-what.need { background: rgba(255, 196, 77, .16); color: var(--warn); }
.mv-what.aside { background: rgba(150, 165, 255, .16); color: var(--soft); }

/* ── Sections ───────────────────────────────────────────────────────────── */
.band { padding: 64px 0; border-top: 1px solid var(--line); }
.band h2 { font-size: clamp(26px, 3.4vw, 34px); font-weight: 600; letter-spacing: -.01em; margin-bottom: 12px; }
.intro, .note { color: var(--muted); max-width: 70ch; }
.note { margin-top: 24px; font-size: 15px; }
h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
article p { color: var(--muted); font-size: 15px; }

.pains, .people { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 24px; }
.people { grid-template-columns: repeat(2, 1fr); }
.pains article, .people article, .features article {
  padding: 24px; border-radius: 14px; background: var(--glass); border: 1px solid var(--line);
}
.idea {
  margin-top: 28px; padding: 20px 24px; border-radius: 14px; font-size: 18px; color: var(--strong);
  background: linear-gradient(90deg, rgba(136, 106, 181, .35), rgba(136, 106, 181, .08));
  border-left: 3px solid var(--accent);
}
.idea strong { color: var(--accent); }

/* The four steps, numbered. */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 28px; }
.step {
  position: relative; padding: 28px 22px 24px; border-radius: 14px;
  background: var(--glass); border: 1px solid var(--line);
}
.step-n {
  position: absolute; top: -14px; left: 22px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-size: 14px; font-weight: 700; color: #1b1236; background: var(--accent);
}
.step-i { width: 28px; height: 28px; color: var(--accent); margin: 6px 0 14px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 24px; }
.features .i { color: var(--accent); margin-bottom: 14px; }

/* Integrations, in three groups: what comes in, what it is checked against, what goes out. */
.group-title { margin: 36px 0 14px; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
/* Three across while they fit, never two-and-an-orphan; one column on a phone. */
.integrations { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 20px; }
.integration {
  display: grid; align-content: start; gap: 12px; padding: 24px; border-radius: 14px;
  background: var(--glass); border: 1px solid var(--line);
}
.integration header { display: flex; align-items: center; gap: 12px; }
.integration header .i { width: 40px; height: 40px; padding: 9px; border-radius: 10px; color: var(--accent); background: rgba(136, 106, 181, .22); }
.integration h4 { margin: 0; font-size: 17px; font-weight: 600; color: var(--strong); }
.integration .setup { padding-top: 12px; border-top: 1px solid var(--line); font-size: 14px; }
.integration .setup strong { color: var(--strong); font-weight: 600; }

.trust { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px 32px; }
.trust li { display: flex; gap: 14px; color: var(--muted); font-size: 15px; }
.trust .i { color: var(--good); margin-top: 1px; }
.trust strong { color: var(--strong); font-weight: 600; }

.start-steps { margin: 24px 0 0; padding-left: 22px; display: grid; gap: 10px; font-size: 17px; }
.start-steps li::marker { color: var(--accent); font-weight: 700; }
.start-steps strong { color: var(--strong); font-weight: 600; }

.foot { padding: 32px 16px 48px; text-align: center; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }

/* ── Narrower screens ───────────────────────────────────────────────────── */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; min-height: 0; gap: 40px; padding-top: 32px; }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .features { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .top-links { gap: 14px; }
  .top-links a:not(.pill) { display: none; }
  .pains, .people, .steps, .features, .trust { grid-template-columns: 1fr; }
  .band { padding: 48px 0; }
  .lead { font-size: 17px; }
  .cta .button { flex: 1 1 100%; }
}
