:root {
  --bg: #FAFAF7;
  --text: #0A0A0A;
  --muted: #555;
  --accent: #C8102E;
  --rule: #E5E5E0;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0F0F0E;
    --text: #EFEFEC;
    --muted: #8A8A85;
    --accent: #E25C72;
    --rule: #2A2A26;
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Inter", "Söhne", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 18px;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 32px 128px;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 96px;
}

nav .brand {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
}

nav .brand .a-mark {
  color: var(--accent);
  font-weight: 700;
}

nav .logo {
  height: 32px;
  width: auto;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 32px;
}

nav a {
  color: var(--text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 400;
  transition: color 0.15s;
}

nav a:hover, nav a.active {
  color: var(--accent);
}

h1 {
  font-size: 56px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 24px;
}

h2 {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-top: 64px;
  margin-bottom: 24px;
}

h3 {
  font-size: 20px;
  font-weight: 500;
  margin-top: 48px;
  margin-bottom: 16px;
}

.tagline {
  font-size: 22px;
  color: var(--muted);
  margin-bottom: 48px;
  font-weight: 400;
  line-height: 1.4;
}

.imperatives {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
  margin-top: 24px;
  margin-bottom: 8px;
  color: var(--text);
  max-width: none;
}

.imperatives-tag {
  font-size: 22px;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 32px;
  font-style: italic;
}

.meyer-quote {
  border-left: 3px solid var(--accent);
  margin: 24px 0 32px;
  padding: 8px 0 8px 24px;
  font-size: 18px;
  color: var(--text);
  max-width: 60ch;
}

.meyer-quote p {
  margin-bottom: 0;
}

.substack-embed-wrapper {
  margin: 32px 0 48px;
}

.substack-embed-wrapper iframe {
  display: block;
}

.footer-note {
  display: block;
  margin-top: 8px;
  font-size: 13px;
}

p {
  margin-bottom: 24px;
  max-width: 65ch;
}

ul.body, ol.body {
  margin-bottom: 24px;
  padding-left: 24px;
}

ul.body li, ol.body li {
  margin-bottom: 8px;
}

a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--rule);
  text-underline-offset: 4px;
  transition: text-decoration-color 0.15s, color 0.15s;
}

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

.paper-link {
  display: block;
  padding: 24px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  margin: 48px 0;
  text-decoration: none;
}

.paper-link .label {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 8px;
}

.paper-link .title {
  font-size: 20px;
  font-weight: 500;
  color: var(--text);
}

.paper-link:hover .title {
  color: var(--accent);
}

.services-item {
  padding: 32px 0;
  border-bottom: 1px solid var(--rule);
}

.services-item:first-child {
  border-top: 1px solid var(--rule);
}

.services-item .name {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 8px;
}

.services-item .price {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 16px;
}

.contract-block {
  border: 1px solid var(--rule);
  padding: 24px 28px;
  margin: 32px 0;
  border-radius: 4px;
}

.contract-block ol {
  list-style: decimal;
  padding-left: 20px;
}

.contract-block li {
  margin-bottom: 6px;
}

footer {
  margin-top: 128px;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
  font-size: 14px;
  color: var(--muted);
}

footer a {
  color: var(--muted);
}

@media (max-width: 640px) {
  body { font-size: 17px; }
  .container { padding: 48px 24px 96px; }
  h1 { font-size: 40px; }
  h2 { font-size: 24px; margin-top: 48px; }
  .tagline { font-size: 19px; margin-bottom: 36px; }
  nav { margin-bottom: 64px; flex-direction: column; gap: 24px; align-items: flex-start; }
  nav ul { gap: 20px; flex-wrap: wrap; }
}
