/* Titan Code — calm variant
   paper / ink palette, terminal kept as the single signature element */

:root {
  --paper: #f5f7f5;
  --paper-2: #eaeeea;
  --ink: #142019;
  --ink-2: #4a564f;
  --rule: #cfd6d0;
  --ledger: #1d7a46;       /* "settled" green: links, primary button */
  --ledger-dark: #145a33;
  --term-bg: #0f1612;
  --term-text: #cfe9d8;
  --term-green: #59e08f;
  --term-amber: #e7b24b;
  --term-dim: #7d8c83;

  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --measure: 66ch;
}

*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-feature-settings: "tnum" 0;
}

a { color: var(--ledger); text-underline-offset: 3px; }
a:hover { color: var(--ledger-dark); }

:focus-visible {
  outline: 3px solid var(--ledger);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* Header */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 22px;
  padding-bottom: 22px;
}
.brand {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 1rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand::before { content: "~/"; color: var(--ledger); }
.site-header nav { display: flex; gap: 22px; align-items: center; font-size: 0.95rem; }
.site-header nav a { color: var(--ink-2); text-decoration: none; }
.site-header nav a:hover { color: var(--ink); }
.site-header nav .nav-cta {
  color: var(--ink);
  border: 1px solid var(--ink);
  padding: 6px 14px;
  border-radius: 6px;
}
.site-header nav .nav-cta:hover { background: var(--ink); color: var(--paper); }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 56px;
  align-items: center;
  padding-top: 56px;
  padding-bottom: 96px;
}
.hero h1 {
  font-size: clamp(2rem, 1.4rem + 2.4vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -0.022em;
  font-weight: 600;
  margin: 0 0 22px;
  max-width: 18ch;
}
.lede {
  font-size: 1.15rem;
  color: var(--ink-2);
  margin: 0 0 32px;
  max-width: 46ch;
}

.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 1rem;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  line-height: 1.2;
}
.btn-primary { background: var(--ledger); color: #fff; }
.btn-primary:hover { background: var(--ledger-dark); color: #fff; }
.btn-quiet { color: var(--ink); box-shadow: inset 0 0 0 1px var(--rule); }
.btn-quiet:hover { color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink-2); }

/* Terminal: the one loud element */
.terminal {
  margin: 0;
  background: var(--term-bg);
  border-radius: 12px;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset, 0 24px 48px -24px rgba(20, 32, 25, 0.45);
  overflow: hidden;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  background: #18211b;
}
.terminal-bar .dot { width: 11px; height: 11px; border-radius: 50%; background: #3a463f; }
.terminal-title { margin-left: 8px; font-family: var(--mono); font-size: 0.75rem; color: var(--term-dim); }
.terminal-body {
  padding: 20px 22px 22px;
  font-family: var(--mono);
  font-size: 0.84rem;
  line-height: 1.7;
  color: var(--term-text);
}
.terminal-body p { margin: 0; }
.terminal-body .gap { margin-top: 14px; }
.terminal-body .ps { color: var(--term-dim); }
.terminal .motd { color: var(--term-green); font-weight: 500; }
.log { list-style: none; margin: 4px 0 0; padding: 0; }
.log li { padding-left: 8ch; text-indent: -8ch; }
.sha { color: var(--term-amber); }
.cursor {
  display: inline-block;
  width: 0.6em;
  height: 1.05em;
  vertical-align: -0.15em;
  background: var(--term-green);
  animation: blink 1.1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.terminal figcaption {
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--term-dim);
  padding: 10px 22px 14px;
  border-top: 1px solid #1f2a23;
}

/* Sections */
.section {
  padding-top: 72px;
  padding-bottom: 72px;
  border-top: 1px solid var(--rule);
}
.section h2,
.contact h2 {
  font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  font-weight: 600;
  margin: 0 0 32px;
}
.section-intro { color: var(--ink-2); margin: -16px 0 32px; max-width: var(--measure); }

/* Services */
.groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 56px;
}
.group h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ledger);
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--ledger);
}
.group dl { margin: 0; }
.group dt { font-weight: 600; margin-top: 20px; }
.group dt:first-child { margin-top: 0; }
.group dd { margin: 4px 0 0; color: var(--ink-2); max-width: 52ch; }

/* Pricing as a statement */
.statement {
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 8px 32px;
  max-width: 880px;
}
.line { padding: 26px 0; }
.line + .line { border-top: 1px dashed var(--rule); }
.line-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
}
.line-head h3 { margin: 0; font-size: 1.2rem; font-weight: 600; white-space: nowrap; }
.leader {
  flex: 1;
  border-bottom: 2px dotted var(--rule);
  transform: translateY(-5px);
  min-width: 24px;
}
.amount {
  margin: 0;
  font-weight: 600;
  font-size: 1.15rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.amount .per { font-weight: 400; color: var(--ink-2); font-size: 0.95rem; }
.terms { margin: 2px 0 10px; font-size: 0.92rem; color: var(--ledger); font-weight: 500; }
.line p:last-child { margin: 0; color: var(--ink-2); max-width: var(--measure); }
.fine { margin: 16px 0 0; font-size: 0.9rem; color: var(--ink-2); }

/* About */
.about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 56px; }
.about h2 { margin: 0; }
.about-body p { margin: 0 0 16px; max-width: var(--measure); }
.stack { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px !important; }
.stack span {
  font-family: var(--mono);
  font-size: 0.82rem;
  background: var(--paper-2);
  border-radius: 6px;
  padding: 4px 10px;
  color: var(--ink);
}

/* Contact */
.contact {
  padding-top: 88px;
  padding-bottom: 88px;
  border-top: 1px solid var(--rule);
}
.contact h2 { max-width: 24ch; margin-bottom: 14px; }
.contact > p { color: var(--ink-2); margin: 0 0 28px; max-width: var(--measure); }
.contact .contact-alt { margin: 24px 0 0; font-size: 0.95rem; }
.contact strong { color: var(--ink); font-weight: 600; }

/* Footer */
.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 24px;
  padding-bottom: 40px;
  border-top: 1px solid var(--rule);
  font-size: 0.9rem;
  color: var(--ink-2);
}
.site-footer p { margin: 0; }
.site-footer a { color: var(--ink-2); margin-left: 18px; }
.site-footer a:first-child { margin-left: 0; }

/* Blog */
.blog { padding-top: 40px; padding-bottom: 96px; }
.blog-title,
.post-head h1 {
  font-size: clamp(1.9rem, 1.4rem + 2vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  font-weight: 600;
  margin: 0 0 20px;
  max-width: var(--measure);
  overflow-wrap: anywhere;
}
.post-meta { margin: 0 0 12px; font-family: var(--mono); font-size: 0.82rem; color: var(--ink-2); }
.post-meta a { color: var(--ink-2); }

.post-list { list-style: none; margin: 0; padding: 0; max-width: var(--measure); }
.post-list li { padding: 24px 0; border-top: 1px solid var(--rule); }
.post-list h2 { font-size: 1.3rem; line-height: 1.3; font-weight: 600; margin: 0 0 6px; }
.post-list h2 a { color: var(--ink); text-decoration: none; }
.post-list h2 a:hover { color: var(--ledger-dark); text-decoration: underline; }
.post-list p:last-child { margin: 0; color: var(--ink-2); }

.prose { max-width: var(--measure); overflow-wrap: break-word; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: 1.5rem; line-height: 1.25; letter-spacing: -0.01em; font-weight: 600; margin: 2.2em 0 0.6em; }
.prose h3 { font-size: 1.2rem; line-height: 1.3; font-weight: 600; margin: 1.8em 0 0.5em; }
.prose p, .prose ul, .prose ol { margin: 0 0 1.1em; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li + li { margin-top: 0.35em; }
.prose blockquote {
  margin: 1.4em 0;
  padding: 0 0 0 1.1em;
  border-left: 3px solid var(--rule);
  color: var(--ink-2);
}
.prose blockquote > :last-child { margin-bottom: 0; }
.prose code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: var(--paper-2);
  padding: 0.12em 0.35em;
  border-radius: 4px;
}
.prose pre {
  margin: 1.4em 0;
  padding: 16px 18px;
  background: var(--term-bg);
  color: var(--term-text);
  border-radius: 10px;
  overflow-x: auto;
  font-size: 0.84rem;
  line-height: 1.65;
}
.prose pre code { background: none; padding: 0; font-size: inherit; color: inherit; }
.prose img { max-width: 100%; height: auto; }
.prose hr { border: 0; border-top: 1px solid var(--rule); margin: 2em 0; }

.post-cta { margin: 48px 0 0; padding-top: 24px; border-top: 1px solid var(--rule); max-width: var(--measure); color: var(--ink-2); }

/* Responsive */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 44px; padding-top: 32px; padding-bottom: 72px; }
  .groups { grid-template-columns: 1fr; gap: 44px; }
  .about { grid-template-columns: 1fr; gap: 20px; }
}

@media (max-width: 560px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  body { font-size: 1rem; }
  .hide-sm { display: none; }
  .site-header { flex-wrap: wrap; row-gap: 12px; }
  .site-header nav { gap: 14px; }
  .statement { padding: 4px 18px; }
  .line-head { flex-wrap: wrap; row-gap: 2px; }
  .line-head h3 { white-space: normal; flex-basis: 100%; }
  .leader { display: none; }
  .terminal-body { font-size: 0.78rem; padding: 16px; }
  .site-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  .cursor { animation: none; }
}
