/* Salo - fast, dependency-free static site
   Layout & colour blocking: Option A. Type & ink/accent: Option B.
   Light by default; dark theme via [data-theme="dark"] on <html>. */

:root {
  /* Page ground, and the white fill used for cards on top of it */
  --bg:        #FBFAF6;
  --surface:   #FFFFFF;

  /* Ink, rules, accent */
  --ink:       #0C1013;
  --ink-soft:  #2B333A;
  --muted:     #5F686F;
  --rule:      #DBDDD9;
  --rule-2:    #C2C6C0;
  --accent:    #0F5B3A;
  --ink-on:    #FBFAF6;

  --max: 1120px;
  --header-h: 75px; /* .nav min-height + 1px border - keep in sync */
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

[data-theme="dark"] {
  --bg:        #14161A;
  --surface:   #191C21;

  --ink:       #E9EDEF;
  --ink-soft:  #C1C9CE;
  --muted:     #8D969D;
  --rule:      #242A30;
  --rule-2:    #333B42;
  --accent:    #6FD3A0;
  --ink-on:    #14161A;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.58;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background .2s ease, color .2s ease;
}

a { color: inherit; text-decoration: none; }
svg { display: block; }

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

.shell {
  width: min(calc(100% - 48px), var(--max));
  margin-inline: auto;
}

.narrow { width: min(calc(100% - 48px), 840px); }

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--rule-2);
  font-family: var(--mono);
  font-size: 13px;
  transform: translateY(-180%);
}

.skip-link:focus { transform: translateY(0); }

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--rule);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  min-height: 74px;
}

.brand {
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.045em;
}

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

nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: -0.01em;
}

nav > a { color: var(--muted); }
nav > a:hover { color: var(--ink); }

/* Theme toggle */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--rule-2);
  border-radius: 2px;
  cursor: pointer;
  transition: color .15s ease, border-color .15s ease;
}

.theme-toggle:hover {
  color: var(--ink);
  border-color: var(--ink);
}

.icon-sun { display: none; }
[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }

/* Type */
h1, h2, h3 {
  margin-top: 0;
  font-weight: 700;
  letter-spacing: -0.035em;
}

h1 {
  margin-bottom: 24px;
  font-size: clamp(42px, 5.4vw, 66px);
  line-height: 1.04;
}

h1 br { display: none; }

h1 em {
  display: block;
  font-style: normal;
  color: var(--accent);
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(29px, 3.3vw, 40px);
  line-height: 1.15;
}

h3 {
  margin-bottom: 9px;
  font-size: 20px;
  line-height: 1.28;
  letter-spacing: -0.025em;
}

p { margin-top: 0; }

.eyebrow,
.work-type {
  margin: 0 0 16px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* Hero — one centred column, sized to land above the fold */
.hero {
  padding: 150px 0 58px;
  border-bottom: 1px solid var(--rule);
}

.hero h1 { margin-bottom: 20px; }


.hero-copy {
  max-width: 760px;
  margin: 0 0 28px;
  color: var(--ink-soft);
  font-size: clamp(18px, 1.7vw, 21px);
  line-height: 1.5;
}

/* Text CTA in place of a button */
.hero-pitch {
  margin: 64px 0 0;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.015em;
  text-align: center;
}

.hero-pitch a {
  color: var(--accent);
  white-space: nowrap;
  border-bottom: 2px solid var(--accent);
}

.hero-pitch a:hover {
  color: var(--ink);
  border-color: var(--ink);
}

/* secondary link, centred on its own line closing the hero */
.hero-more {
  margin: 20px 0 0;
  text-align: center;
}

.text-link {
  padding-bottom: 2px;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13.5px;
  border-bottom: 1px solid var(--rule-2);
}

.text-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}


/* Sections */
.section {
  padding: 94px 0;
  border-bottom: 1px solid var(--rule);
}

.section-tight { padding-bottom: 86px; }

.section-heading {
  display: grid;
  grid-template-columns: 1.25fr .75fr;
  align-items: end;
  gap: 80px;
  margin-bottom: 44px;
}

.section-heading h2 {
  max-width: 780px;
  margin-bottom: 0;
}

/* Text-only section: nothing follows the heading, so drop its gap */
.shell > .section-heading:last-child { margin-bottom: 0; }

.section-heading > p {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 17px;
}

.compact-heading {
  grid-template-columns: 1fr;
  gap: 0;
}

.compact-heading-inner { max-width: 820px; }

.compact-heading h2 { margin-bottom: 14px; }

.section-lead {
  max-width: 720px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 18.5px;
  line-height: 1.5;
}

/* Universal Verifier — centred band closing the hero, no divider */
/* Statement and supported chains sit side by side, equal height */
.hero-verifier {
  display: grid;
  grid-template-columns: auto minmax(0, 360px);
  justify-content: start;
  gap: 36px;
  margin-top: 50px;
}

.hero-verifier h2 {
  margin: 0;
  font-size: clamp(26px, 2.8vw, 34px);
}

/* wrapped chip rows spread to match the heading's height */
.hero-verifier .chain-list { align-content: space-between; }

.chain-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.chain-list li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background: var(--surface);
  border: 1px solid var(--rule-2);
  border-radius: 2px;
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: -0.01em;
}

.chain-list li::before {
  content: "✓";
  color: var(--accent);
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.chain-list .chain-open { color: var(--muted); }

.chain-list .chain-open strong {
  color: var(--ink);
  font-weight: 700;
}

/* Closing contact statement */
.contact-line {
  max-width: 940px;
  margin: 0;
  font-size: clamp(26px, 2.9vw, 38px);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.035em;
}

.contact-line a {
  color: var(--accent);
  white-space: nowrap;
  border-bottom: 2px solid var(--accent);
}

.contact-line a:hover { color: var(--ink); border-color: var(--ink); }

/* Work */
.proof-groups {
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
}

.proof-group {
  display: grid;
  grid-template-columns: minmax(220px, .72fr) minmax(0, 1.6fr);
  align-items: start;
  gap: 54px;
  padding: 32px 34px;
  border-bottom: 1px solid var(--rule);
}

.proof-group:last-child { border-bottom: 0; }

.proof-group > .work-type,
.proof-group-heading .work-type {
  margin: 5px 0 0;
  font-size: 10.5px;
  line-height: 1.55;
}

.proof-group-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.scale-stat {
  flex: none;
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 5px 10px;
  color: var(--accent);
  border: 1px solid currentColor;
  border-radius: 2px;
  font-family: var(--mono);
  line-height: 1;
  white-space: nowrap;
}

.scale-stat strong {
  font-size: 18px;
  letter-spacing: -0.035em;
}

.scale-stat span {
  margin-left: 5px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
}

.codebase-list {
  margin: 0;
  color: var(--ink);
  font-size: clamp(18px, 1.65vw, 21px);
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: -0.018em;
}

.proof-summary {
  max-width: 840px;
  margin: 28px 0 0;
  color: var(--ink-soft);
  font-size: 18px;
  line-height: 1.55;
}

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  align-items: start;
  gap: 86px;
}

.team-copy > p:first-child {
  margin: 0;
  color: var(--ink-soft);
  font-size: 19px;
  line-height: 1.62;
}

/* Contact */
.cta-section {
  padding: 90px 0;
  border-bottom: 1px solid var(--rule);
}

/* Footer */
footer { padding: 38px 0; }

.footer-grid {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: 28px;
}

.footer-grid p {
  margin: 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
}

.brand-footer { font-size: 22px; }

/* Scroll to top - revealed after scrolling, hidden without JS */
.to-top {
  position: fixed;
  right: 40px;
  bottom: 40px;
  z-index: 30;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--rule-2);
  border-radius: 2px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s,
              color .15s ease, border-color .15s ease;
}

.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.to-top:hover {
  color: var(--ink);
  border-color: var(--ink);
}

/* Details page */
.page-hero {
  padding: 168px 0 88px;
  border-bottom: 1px solid var(--rule);
}

.page-hero h1 { max-width: 900px; }

.page-hero p:last-child {
  max-width: 740px;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: clamp(18px, 1.7vw, 21px);
  line-height: 1.5;
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule);
}

.steps li {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 24px;
  padding: 26px 0;
  border-bottom: 1px solid var(--rule);
}

.steps li > span {
  color: var(--accent);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .06em;
}

.steps h3 { margin-bottom: 6px; }

.steps p {
  max-width: 640px;
  margin: 0;
  color: var(--muted);
}

.feature-grid,
.engagement-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.feature-grid { grid-template-columns: repeat(3, 1fr); }

.feature-grid article,
.engagement-grid article {
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
}

.feature-grid p,
.engagement-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.comparison {
  padding: 88px 0;
  border-bottom: 1px solid var(--rule);
}

.comparison-grid {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  align-items: center;
  gap: 80px;
}

.comparison h2 { margin-bottom: 0; }

.comparison-cards {
  display: grid;
  gap: 12px;
}

.comparison-cards article {
  padding: 25px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
}

.comparison-cards span {
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.comparison-cards p {
  margin: 10px 0 0;
  color: var(--ink-soft);
}

/* Responsive */
@media (max-width: 960px) {
  .section-heading,
  .team-grid,
  .comparison-grid {
    grid-template-columns: 1fr;
    gap: 42px;
  }

  .section-heading { gap: 20px; }

  .feature-grid,
  .engagement-grid { grid-template-columns: repeat(2, 1fr); }

}

@media (max-width: 760px) {
  .proof-group {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 27px 24px;
  }

  .proof-group-heading {
    align-items: center;
  }

  .proof-group > .work-type,
  .proof-group-heading .work-type { margin-top: 0; }
}

@media (max-width: 720px) {
  :root { --header-h: 67px; }

  .shell,
  .narrow { width: min(calc(100% - 30px), var(--max)); }

  .nav { min-height: 66px; }
  nav { gap: 14px; }
  nav > a { display: none; }

  .hero,
  .page-hero { padding: 124px 0 66px; }

  h1 { font-size: clamp(36px, 11vw, 54px); }

  .section,
  .cta-section,
  .comparison { padding: 66px 0; }

  .section-lead { font-size: 17px; }

  .hero-verifier {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .chain-list li {
    padding: 9px 15px;
    font-size: 13px;
  }

  .feature-grid,
  .engagement-grid { grid-template-columns: 1fr; }

  .steps li {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .to-top {
    right: 24px;
    bottom: 24px;
    width: 40px;
    height: 40px;
  }
}

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