@font-face { font-family: "iA Writer Quattro S"; src: url("/fonts/iAWriterQuattroS-Regular.ttf") format("truetype"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "iA Writer Quattro S"; src: url("/fonts/iAWriterQuattroS-Bold.ttf") format("truetype"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "iA Writer Quattro S"; src: url("/fonts/iAWriterQuattroS-Italic.ttf") format("truetype"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "iA Writer Mono S"; src: url("/fonts/iAWriterMonoS-Regular.ttf") format("truetype"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
  --bg: #FAFAF7;
  --fg: #201F1B;
  --muted: #6E6D66;
  --faint: #A3A29A;
  --border: #E3E2DB;
  --surface: #F1F0EA;
  --blue: #2E5AAC;
  --ink: #000000;
  --green: #B3FF97;
  --green-ink: #1F5A10;
  --font: "iA Writer Quattro S", "iA Writer Quattro", Georgia, "Times New Roman", serif;
  --mono: "iA Writer Mono S", "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #191A18; --fg: #E4E3DD; --muted: #9C9B92; --faint: #66655E; --border: #2C2D29; --surface: #202220;
    --blue: #7FA8E8; --ink: #E4E3DD; --green: #B3FF97; --green-ink: #B3FF97;
  }
}
:root[data-theme="dark"] {
  --bg: #191A18; --fg: #E4E3DD; --muted: #9C9B92; --faint: #66655E; --border: #2C2D29; --surface: #202220;
  --blue: #7FA8E8; --ink: #E4E3DD; --green: #B3FF97; --green-ink: #B3FF97;
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font-family: var(--font); font-size: 17px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--green); color: #000; }

.wrap { max-width: 60rem; margin: 0 auto; padding: 0 1.5rem; }

/* Header */
header { padding: 2.25rem 0 0; }
header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.mark { display: block; width: 8.5rem; line-height: 0; }
.mark svg { width: 100%; height: auto; display: block; }
.k-logo-ink { fill: var(--ink); }
.k-logo-a { stop-color: var(--blue); }
.k-logo-b { stop-color: var(--ink); }
nav { display: flex; gap: 1.5rem; font-size: 0.92rem; }
nav a { color: var(--muted); text-decoration: none; }
nav a:hover { color: var(--fg); text-decoration: underline; }

/* Hero */
.hero { padding: 6.5rem 0 5.5rem; }
.hero h1 {
  font-size: clamp(2rem, 5.2vw, 3rem); line-height: 1.12; font-weight: 700; letter-spacing: -0.015em;
  margin: 0 0 1.25rem; text-wrap: balance;
}
.hero h1 em { font-style: normal; color: var(--blue); }
.hero p.lede { font-size: 1.2rem; color: var(--muted); margin: 0 0 2.75rem; text-wrap: pretty; }

.dl { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.25rem; }
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  background: var(--fg); color: var(--bg); text-decoration: none;
  font-weight: 700; font-size: 1.02rem; padding: 0.8rem 1.25rem 0.8rem 1.05rem; border-radius: 8px;
  border: 1px solid var(--fg); transition: transform 120ms ease, box-shadow 120ms ease;
}
.btn::before { content: ""; width: 4px; height: 1.15em; background: var(--green); border-radius: 1px; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(0,0,0,0.12); text-decoration: none; }
.btn:active { transform: translateY(0); box-shadow: none; }
.fine { font-family: var(--mono); font-size: 0.78rem; color: var(--muted); line-height: 1.5; }
.fine a { color: inherit; }

/* Sections, headed with the logo's bars */
section { padding: 4.75rem 0; border-top: 1px solid var(--border); }
h2 {
  font-size: 1.45rem; line-height: 1.25; font-weight: 700; letter-spacing: -0.01em; margin: 0 0 1.5rem;
  padding-left: 1rem; position: relative; text-wrap: balance;
}
h2::before {
  content: ""; position: absolute; left: 0; top: 0.15em; bottom: 0.15em; width: 4px;
  background: var(--green); border-radius: 1px;
}
section p { margin: 0 0 1.25rem; text-wrap: pretty; }
section p:last-child { margin-bottom: 0; }
code { font-family: var(--mono); font-size: 0.88em; background: var(--surface); padding: 0.1em 0.35em; border-radius: 4px; }

.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem 4rem; }
.pair h2 { font-size: 1.2rem; }
@media (max-width: 40rem) { .pair { grid-template-columns: 1fr; } }

/* Feedback form */
form { display: grid; gap: 1.25rem; margin-top: 2.25rem; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 40rem) { .row { grid-template-columns: 1fr; } }
label { display: grid; gap: 0.35rem; font-size: 0.85rem; color: var(--muted); }
label span.opt { color: var(--faint); }
input, textarea {
  font: inherit; font-size: 1rem; color: var(--fg); background: var(--surface);
  border: 1px solid var(--border); border-radius: 6px; padding: 0.65rem 0.8rem; width: 100%;
}
input:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 18%, transparent); }
textarea { min-height: 9rem; resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.actions { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
button.btn { cursor: pointer; font-family: inherit; }
button.btn[disabled] { opacity: 0.55; cursor: default; transform: none; box-shadow: none; }
.status { font-size: 0.92rem; color: var(--muted); min-height: 1.4em; }
.status.ok { color: var(--green-ink); }
.status.err { color: #B23A2E; }

footer { border-top: 1px solid var(--border); padding: 3rem 0 4rem; }
footer .wrap { display: flex; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
footer p { margin: 0; }

@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:hover { transform: none; } }
