/* leibler.dev/kullback */
.kb-hero { padding-top: 112px; padding-bottom: 48px; }
.kb-hero h1 { max-width: none; margin: 32px 0 24px; font-size: clamp(28px, 4.2vw, 52px); }
.kb-hero .w { display: inline-block; }
.kb-hero .cta { margin-top: 28px; }
html.js .kb-hero .w, html.js .kb-hero .prompt, html.js .kb-hero .sub, html.js .kb-hero .cta { opacity: 0; transform: translateY(14px); animation: kb-up .8s cubic-bezier(.2,.7,.2,1) forwards; }
html.js .kb-hero .w { animation-delay: calc(120ms + var(--i) * 60ms); }
html.js .kb-hero .prompt { animation-delay: 0ms; }
html.js .kb-hero .sub { animation-delay: 680ms; }
html.js .kb-hero .cta { animation-delay: 820ms; }
@keyframes kb-up { to { opacity: 1; transform: none; } }

/* the loop */
.loop { border-top: 1px solid var(--line); padding-top: 44px; padding-bottom: 20px; }
.loop svg { display: block; width: 100%; height: auto; overflow: visible; }
.loop .v { display: none; }
.loop .ln { stroke: var(--line-2); stroke-width: 1.2; fill: none; }
.loop .fl { stroke: #3a3a3a; stroke-width: 1.2; fill: none; stroke-dasharray: 3 7; animation: kb-flow 1.4s linear infinite; }
@keyframes kb-flow { to { stroke-dashoffset: -10; } }
.loop .nd circle { fill: #000; stroke: #fff; stroke-width: 1.4; }
.loop .nd .on { fill: #fff; stroke: none; opacity: 0; animation: kb-on 9s linear infinite; animation-delay: var(--d); }
@keyframes kb-on { 0% { opacity: 0; } 2%, 14% { opacity: 1; } 24%, 100% { opacity: 0; } }
.loop .nd text { font: 11px "Geist Mono", ui-monospace, monospace; fill: var(--fg-3); animation: kb-txt 9s linear infinite; animation-delay: var(--d); }
.loop .nd .cap { font-size: 10px; fill: #5a5a5a; }
@keyframes kb-txt { 0% { fill: #8a8a8a; } 2%, 16% { fill: #fff; } 28%, 100% { fill: #8a8a8a; } }
.loop .ring { fill: none; stroke: #fff; stroke-width: 1; opacity: 0; transform-box: fill-box; transform-origin: center; animation: kb-ring 9s ease-out infinite; animation-delay: var(--d); }
@keyframes kb-ring { 0% { transform: scale(1); opacity: 0; } 1% { transform: scale(1); opacity: .8; } 9%, 100% { transform: scale(2.6); opacity: 0; } }
.loop .dot { fill: #fff; animation: kb-dot 9s linear infinite; }
@keyframes kb-dot { from { offset-distance: 0%; } to { offset-distance: 100%; } }
.loop .arc-l { font: 10px "Geist Mono", ui-monospace, monospace; fill: #5a5a5a; }
.loop .arrow { fill: #3a3a3a; }
.loop-cap { color: var(--fg-3); font-size: 12.5px; padding-top: 12px; max-width: 66ch; }
.loop-cap b { color: #fff; font-weight: 500; }

/* sections */
.kb-sec { border-top: 1px solid var(--line); padding-top: 64px; padding-bottom: 64px; }
.kb-sec h2 { font-size: clamp(20px, 2.6vw, 26px); line-height: 1.25; margin-bottom: 20px; }
.kb-sec p { color: var(--fg-2); max-width: 60ch; line-height: 1.7; }
.kb-list { list-style: none; margin-top: 8px; max-width: 60ch; }
.kb-list li { padding: 12px 0; border-top: 1px dashed var(--line-2); color: var(--fg-2); line-height: 1.6; }
.kb-list li:last-child { border-bottom: 1px dashed var(--line-2); }
.kb-list li b { color: #fff; font-weight: 500; }
.kb-tbl { margin-top: 24px; max-width: 60ch; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.kb-tbl .proof td:last-child, .kb-tbl .proof th:last-child { color: var(--fg-3); }
.kb-tbl .proof td:nth-child(2) { color: #fff; }
.kb-note { margin-top: 16px; font-size: 13px; }
.kb-links a { color: #fff; border-bottom: 1px solid var(--line-2); transition: border-color 150ms ease; }
.kb-links a:hover { border-color: #fff; }
.kb-close { border-top: 1px solid var(--line); padding-top: 80px; padding-bottom: 56px; }
.kb-close h2 { font-size: clamp(24px, 3.4vw, 38px); line-height: 1.15; max-width: 30ch; margin-bottom: 14px; }
.kb-close p { color: var(--fg-2); max-width: 60ch; line-height: 1.7; }
.kb-close .cta { margin-top: 24px; }

/* scroll reveal */
html.js .rv { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
html.js .rv.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html.js .kb-hero .w, html.js .kb-hero .prompt, html.js .kb-hero .sub, html.js .kb-hero .cta, html.js .rv { opacity: 1; transform: none; animation: none; transition: none; }
  .loop .fl, .loop .nd .on, .loop .nd text, .loop .ring, .loop .dot { animation: none; }
  .loop .dot { display: none; }
  .loop .nd text { fill: #fff; }
}
@media (max-width: 720px) {
  .kb-hero { padding-top: 64px; padding-bottom: 40px; }
  .loop { padding-top: 32px; padding-bottom: 12px; }
  .loop .h { display: none; } .loop .v { display: block; max-width: 340px; }
  .loop .nd text { font-size: 13px; } .loop .nd .cap { font-size: 11px; }
  .kb-sec { padding-top: 48px; padding-bottom: 48px; }
  .kb-close { padding-top: 56px; padding-bottom: 40px; }
}
@media (max-width: 560px) { .proof { font-size: 12px; } .proof th, .proof td { padding: 10px 8px; } }
.brand { display: inline-flex; align-items: center; gap: 9px; }
.brand .mark { width: 24px; height: 24px; border-radius: 5px; border: 1px solid var(--line-2); }
.btn .gh { flex: none; }
