@font-face {
  font-family: "Plus Jakarta Sans";
  src: url("fonts/plus-jakarta-sans.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("fonts/jetbrains-mono.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Brand (00_business/brand.md, light theme) */
  --bg: #f8f9fc;
  --surface: #ffffff;
  --ink: #1a2340;
  --body: #2a3458;
  --muted: #56647f;
  --blue: #2d5fbe;
  --purple: #5040b0;
  --rule: rgba(30, 58, 138, 0.12);
  --grid: rgba(45, 95, 190, 0.12);
  --on-ink: #c9d0e6;
  --white: #ffffff;
  --blue-tint: rgba(45, 95, 190, 0.06);
  --blue-tint-strong: rgba(45, 95, 190, 0.1);

  --sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* Spacing scale */
  --s0: 0.375rem;
  --s1: 0.5rem;
  --s2: 1rem;
  --s3: 1.5rem;
  --s4: 2rem;
  --s5: 3rem;
  --s6: 4rem;
  --section: clamp(4rem, 9vw, 7rem);
  --section-tight: clamp(3rem, 6vw, 4.5rem);
  --measure: 34rem; /* ~74 characters of body text; ch runs wide in Plus Jakarta Sans */

  --radius: 10px;
  --wrap: 70rem;
  --gutter: clamp(1rem, 4vw, 1.5rem);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { color: var(--ink); text-wrap: balance; overflow-wrap: break-word; hyphens: auto; }
p { text-wrap: pretty; }
a { color: inherit; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

.skip { position: absolute; left: var(--s2); top: -4rem; background: var(--ink); color: var(--white); padding: var(--s1) var(--s2); border-radius: var(--radius); z-index: 10; }
.skip:focus { top: var(--s2); }

/* Header */
.site-header { padding-block: var(--s4); }
.site-header .wrap { display: flex; justify-content: space-between; align-items: center; gap: var(--s2); }
.logo { height: 26px; width: auto; }
.site-header a.mail { font-weight: 600; color: var(--blue); text-decoration: none; }
.site-header a.mail:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3.25rem; padding: 0 var(--s3);
  border-radius: var(--radius); font-weight: 600; text-decoration: none;
  background: var(--ink); color: var(--white);
  transition: background-color 160ms var(--ease-out);
}
.btn:hover { background: var(--blue); }
.btn-blue { background: var(--blue); }
.btn-blue:hover { background: var(--purple); }
.btn:active { translate: 0 1px; }
.nowrap { white-space: nowrap; }
.text-link { font-weight: 600; text-underline-offset: 4px; }

/* Hero */
.hero { padding-block: var(--s5) var(--section); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: var(--s6); align-items: center; }
.hero h1 { font-size: clamp(2.25rem, 1.4rem + 3vw, 3.5rem); line-height: 1.06; letter-spacing: -0.03em; font-weight: 800; }
.hero .lead { font-size: clamp(1.125rem, 1rem + 0.4vw, 1.25rem); max-width: 38ch; margin-top: var(--s3); }
.hero .label { margin-bottom: var(--s2); }
.hero .actions { margin-top: var(--s4); display: flex; gap: var(--s3); align-items: center; flex-wrap: wrap; }

.person { background: var(--surface); border: 1px solid var(--rule); border-radius: 14px; padding: var(--s4); }
.avatar {
  width: 5.5rem; height: 5.5rem; border-radius: 50%; margin-bottom: var(--s3);
  background: var(--rule); object-fit: cover;
}
.person strong { display: block; color: var(--ink); font-size: 1.15rem; }
.person p { color: var(--muted); font-size: 0.95rem; margin-top: var(--s0); }
.person a { display: inline-block; margin-top: var(--s2); color: var(--blue); font-weight: 600; text-decoration: none; }
.person a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Section headings */
.section-title { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.1rem); letter-spacing: -0.02em; line-height: 1.15; font-weight: 700; }

/* Calculator: the squared sheet */
.calc-section { padding-block: var(--section); background: var(--surface); border-block: 1px solid var(--rule); scroll-margin-top: var(--s2); }
.calc-section .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: var(--s6); align-items: center; }
.calc-section .intro p { margin-top: var(--s2); max-width: 44ch; }
.edit-hint { color: var(--blue); font-weight: 600; }
.calc-section .btn { margin-top: var(--s4); }
.send-note { font-size: 0.92rem; color: var(--muted); margin-top: 0.75rem; max-width: 44ch; }
.ask-action .send-note { max-width: 22rem; }
.questions { margin-top: var(--s2); padding-left: 1.4rem; display: grid; gap: var(--s0); max-width: var(--measure); }
.questions li::marker { color: var(--blue); font-weight: 600; }

.sheet {
  /* Squared school paper: the grid is the subject (a Rechenheft), not decoration */
  background-color: #fcfdff;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 28px 28px;
  background-position: -1px -1px;
  border-radius: 6px;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  font-family: var(--mono);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(26, 35, 64, 0.08), 0 4px 8px -2px rgba(26, 35, 64, 0.1);
}
.sheet .task { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: baseline; font-family: var(--sans); font-size: 0.95rem; color: var(--muted); margin-bottom: var(--s3); }
.sheet .task textarea {
  flex: 1; min-width: 12ch; padding: 0.25rem 0; resize: none; overflow: hidden; line-height: 1.4;
  font: 600 1.05rem var(--sans); color: var(--blue);
  background: transparent; border: 0; border-bottom: 1.5px dashed var(--blue);
}
.row { display: grid; grid-template-columns: 2ch 8ch minmax(0, 1fr); gap: 0.875rem; align-items: center; min-height: 3.5rem; }
.row .op { color: var(--muted); font-size: 1.4rem; }
.row .num { text-align: right; font-size: 1.6rem; font-weight: 500; font-variant-numeric: tabular-nums; }
.row .unit { font-family: var(--sans); font-size: 0.95rem; color: var(--muted); }
.row input {
  width: 100%; min-height: 2.75rem; padding: 0 0.375rem;
  font: 600 1.6rem var(--mono); font-variant-numeric: tabular-nums; color: var(--blue); text-align: right;
  background: var(--blue-tint); border: 0; border-bottom: 1.5px dashed var(--blue); border-radius: 4px 4px 0 0;
}
.row input:hover { background: var(--blue-tint-strong); }
.row input:focus { background: var(--surface); outline: 2px solid var(--blue); outline-offset: 2px; }
.rates { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.25rem 0 var(--s2) calc(2ch + 0.875rem); }
.rates button {
  min-height: 2.75rem; padding: 0 var(--s2); border-radius: 999px; cursor: pointer;
  font: 500 0.9rem var(--sans); color: var(--body); background: var(--surface); border: 1px solid var(--rule);
  transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out);
}
.rates button:hover { border-color: var(--blue); }
.rates button[aria-pressed="true"] { color: var(--white); background: var(--blue); border-color: var(--blue); }
.sum-line { border-top: 2px solid var(--ink); width: calc(10ch + 0.875rem); margin-top: 0.25rem; }
.total {
  display: inline-block; position: relative; padding: 0.875rem 0 0.375rem;
  font-size: clamp(1.9rem, 1.2rem + 2.6vw, 2.6rem); font-weight: 700; line-height: 1.15;
  font-variant-numeric: tabular-nums; overflow-wrap: anywhere;
}
.total::after {
  /* Double underline: the result, as taught in school */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 6px;
  border-block: 2px solid var(--blue);
  transform-origin: left;
  animation: underline 700ms 300ms var(--ease-out) backwards;
}
.total.tick #total-value { animation: tick 260ms var(--ease-out); }
#total-value { display: inline-block; }
.total-unit { font-family: var(--sans); font-size: 1rem; color: var(--muted); margin-top: 0.625rem; }

@keyframes underline { from { transform: scaleX(0); } }
@keyframes tick { from { opacity: 0.35; transform: translateY(4px); } }

/* Steps */
.steps { padding-block: var(--section); }
.steps ol { list-style: none; margin-top: var(--s5); border-top: 1px solid var(--rule); }
.steps li { display: grid; grid-template-columns: 4rem minmax(0, 1fr) 14rem; gap: var(--s4); padding-block: var(--s4); border-bottom: 1px solid var(--rule); }
.steps .n { font-family: var(--mono); font-size: 1.1rem; font-weight: 500; color: var(--blue); padding-top: 0.2rem; }
.steps h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em; }
.steps li p { margin-top: var(--s0); max-width: var(--measure); }
.steps .price { text-align: right; color: var(--ink); font-weight: 600; padding-top: 0.2rem; }
.steps .price small { display: block; font-weight: 400; color: var(--muted); font-size: 0.9rem; line-height: 1.4; margin-top: 0.125rem; }
.steps .after { margin-top: var(--s3); color: var(--muted); max-width: var(--measure); }

/* Proof */
.proof { padding-bottom: var(--section); }
.proof .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: var(--s6); }
.proof p { max-width: var(--measure); }
.proof p + p { margin-top: var(--s2); }

/* Reference and exchange */
.label { font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--blue); }

.reference { padding-block: var(--section); background: var(--surface); border-block: 1px solid var(--rule); scroll-margin-top: var(--s2); }
.reference .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: var(--s6); align-items: start; }
.ref-intro .section-title { margin-top: var(--s1); }
.ref-logos { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s4); margin-top: var(--s3); }
.ref-logos img { height: 4rem; width: auto; }
.ref-intro p:not(.label) { margin-top: var(--s2); max-width: 44ch; }
.ref-intro .links { display: flex; flex-wrap: wrap; gap: var(--s1) var(--s3); }
.ref-intro .links a, .ref-list a { color: var(--blue); font-weight: 600; text-underline-offset: 4px; }
.ref-list { list-style: none; display: grid; gap: var(--s4); }
.ref-list li { border-top: 2px solid var(--blue); padding-top: var(--s2); }
.ref-list h3 { font-size: 1.15rem; font-weight: 700; letter-spacing: -0.01em; }
.ref-list p { max-width: var(--measure); margin-top: var(--s0); color: var(--muted); font-size: 0.98rem; }

/* The exchange that ends each door: what the visitor sends, what they get back */
.ask {
  grid-column: 1 / -1; scroll-margin-top: var(--s2);
  display: flex; gap: var(--s3) var(--s5); align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: var(--bg); border: 1px solid var(--rule); border-radius: 14px; padding: var(--s4);
}
.ask > div:first-child { flex: 1 1 32rem; }
.ask h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em; }
.ask p { margin-top: var(--s0); max-width: var(--measure); }
.trust { list-style: none; margin-top: var(--s3); display: grid; gap: var(--s1); max-width: var(--measure); }
.trust li { padding-left: var(--s3); position: relative; }
.trust li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 0.6rem; height: 2px; background: var(--blue); }
.trust strong { color: var(--ink); }

/* Home hub: one statement, three doors, one proof, one person */
.hub { padding-block: var(--s5) var(--section); }
.hub h1 { font-size: clamp(2.25rem, 1.2rem + 4.2vw, 4rem); line-height: 1.05; letter-spacing: -0.03em; font-weight: 800; max-width: 24ch; }
.byline { display: flex; align-items: center; gap: 0.75rem; margin-top: var(--s3); color: var(--muted); font-size: 0.95rem; }
.byline img { width: 2.75rem; height: 2.75rem; border-radius: 50%; object-fit: cover; }
.byline strong { color: var(--ink); }
.hub .lead { font-size: clamp(1.125rem, 1rem + 0.4vw, 1.25rem); max-width: 38rem; margin-top: var(--s3); }

.doors { margin-top: var(--s5); }
.doors ul { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s3); }
.doors a {
  position: relative; display: flex; flex-direction: column; height: 100%; text-decoration: none;
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: var(--s3); transition: border-color 160ms var(--ease-out);
}
.doors a:hover { border-color: var(--blue); }
.doors a:hover strong { color: var(--blue); }
.doors a:focus-visible { border-radius: var(--radius); outline-offset: 4px; }
.doors strong { color: var(--ink); font-size: 1.35rem; line-height: 1.25; letter-spacing: -0.01em; padding-right: var(--s4); }
.door-text { margin: var(--s0) 0 var(--s2); color: var(--body); font-size: 0.98rem; }
.door-proof { margin-top: auto; padding-top: var(--s2); border-top: 1px solid var(--rule); color: var(--ink); font-weight: 600; font-size: 0.9rem; }
.doors .arrow { position: absolute; top: var(--s3); right: var(--s3); color: var(--blue); font-size: 1.25rem; line-height: 1.3; transition: translate 160ms var(--ease-out); }
.doors a:hover .arrow { translate: 4px 0; }

.reference-short .ref-body p { max-width: var(--measure); }
.reference-short .links { margin-top: var(--s2); display: flex; flex-wrap: wrap; gap: var(--s1) var(--s3); }
.reference-short .links a { color: var(--blue); font-weight: 600; text-underline-offset: 4px; }

.about { padding-block: var(--section-tight); }
.reference-short { padding-block: var(--section-tight); }
.about .wrap { display: grid; grid-template-columns: 14rem minmax(0, 1fr); gap: var(--s3) var(--s6); align-items: center; }
.about .avatar { width: 14rem; height: 14rem; margin: 0; border-radius: 14px; }
.about p { margin-top: var(--s2); max-width: var(--measure); }
.about .phone { display: inline-block; margin-top: var(--s2); color: var(--blue); font-weight: 600; text-decoration: none; }
.about .phone:hover { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 860px) {
  .reference .wrap { grid-template-columns: minmax(0, 1fr); gap: var(--s5); }
  .reference-short .wrap { gap: var(--s2); }
  .reference .wrap { gap: var(--s4); }
  .proof .wrap { gap: var(--s2); }
  .doors ul { grid-template-columns: minmax(0, 1fr); gap: var(--s2); }
  .doors a { height: auto; }
}
@media (max-width: 600px) {
  .ask { padding: var(--s3); }
  .ask > div { flex-basis: 100%; }
  .about .wrap { grid-template-columns: minmax(0, 1fr); }
  .about .avatar { width: 9rem; height: 9rem; }
}

/* Contact */
.contact { background: var(--ink); color: var(--on-ink); padding-block: var(--section); line-height: 1.75; }
.contact h2 { color: var(--white); }
.contact .big {
  display: inline-block; margin-top: var(--s4);
  font-size: clamp(1.6rem, 1rem + 3vw, 3rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2;
  color: var(--white); text-decoration: none; border-bottom: 3px solid var(--blue); overflow-wrap: anywhere;
}
.contact .big:hover { border-color: var(--white); }
.contact .meta { margin-top: var(--s4); display: flex; align-items: center; gap: var(--s2) var(--s5); flex-wrap: wrap; }
.contact .promise { margin-top: var(--s2); max-width: var(--measure); font-size: 1.125rem; }
.contact .meta a { color: var(--white); text-decoration: none; }
.contact .meta a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Footer */
.site-footer { padding-block: var(--s4); color: var(--muted); font-size: 0.92rem; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: var(--s2); flex-wrap: wrap; }
.site-footer nav { display: flex; gap: var(--s3); }
.site-footer a { text-underline-offset: 3px; }

/* Legal pages */
.legal { padding-block: var(--s5) var(--section); }
.legal .wrap { max-width: 46rem; }
.legal h1 { font-size: clamp(2rem, 1.4rem + 2vw, 2.75rem); letter-spacing: -0.025em; line-height: 1.1; }
.legal h2 { font-size: 1.2rem; margin-top: var(--s5); }
.legal p, .legal ul { margin-top: var(--s2); }
.legal ul { padding-left: 1.25rem; }
.legal li + li { margin-top: var(--s0); }
.legal .updated { color: var(--muted); font-size: 0.92rem; margin-top: var(--s2); }
.legal a { color: var(--blue); text-underline-offset: 3px; }

/* Touch targets: standalone text links get a 44px tall hit area */
.site-header a.mail, .text-link, .person a, .about .phone, .links a, .contact .meta a, .site-footer nav a {
  display: inline-flex; align-items: center; min-height: 44px;
}

/* Responsive */
@media (max-width: 860px) {
  .hero .wrap, .calc-section .wrap, .proof .wrap { grid-template-columns: minmax(0, 1fr); gap: var(--s5); }
  .steps li { grid-template-columns: 2.5rem minmax(0, 1fr); gap: var(--s1) var(--s2); }
  .steps .price { grid-column: 2; text-align: left; padding-top: var(--s1); }
  .steps .price small { display: inline; margin-left: 0.375rem; }
  .person { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--s3); align-items: center; padding: var(--s3); }
  .person .avatar { grid-row: span 3; width: 4.5rem; height: 4.5rem; font-size: 1.3rem; margin-bottom: 0; }
  .person a { margin-top: var(--s1); justify-self: start; }
}
@media (max-width: 860px) {
  /* On one column the send button belongs under the result, not above the sheet */
  .calc-section .wrap { display: flex; flex-direction: column; gap: 0; }
  .calc-section .intro { display: contents; }
  .sheet { order: 1; margin-top: var(--s4); }
  .calc-section .btn { order: 2; align-self: flex-start; }
  .send-note { order: 3; }
}
@media (max-width: 600px) {
  .sheet .task textarea { flex-basis: 100%; }
  .rates button { padding: 0 0.875rem; font-size: 0.875rem; }
  .label { font-size: 0.875rem; }
}
@media (max-width: 600px) {
  .site-header { padding-block: var(--s3); }
  .hero, .hub { padding-top: var(--s3); }
}
@media (max-width: 480px) {
  .row { grid-template-columns: 1.5ch 8ch minmax(0, 1fr); gap: 0.625rem; }
  .row .num, .row input { font-size: 1.2rem; }
  .rates { margin-left: 0; }
  .sum-line { width: calc(8ch + 0.625rem); }
  .site-header a.mail { font-size: 0.95rem; }
}

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