/* Alkor kit: tokens (light + dark), fonts and shared pieces for alkorlabs.com and every product page under it.
   Pages link /kit/alkor.css first, then their own stylesheet built on these tokens. See docs/DESIGN.md. */
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Bricolage";
  src: url("/fonts/bricolage-var.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #f6f5f1;
  --bg-2: #ffffff;
  --surface: rgba(13, 16, 32, 0.035);
  --surface-2: rgba(13, 16, 32, 0.06);
  --card-a: #ffffff;
  --card-b: rgba(255, 255, 255, 0.72);
  --tile-a: rgba(255, 255, 255, 0.95);
  --tile-b: rgba(255, 255, 255, 0.55);
  --line: rgba(13, 16, 32, 0.09);
  --line-2: rgba(13, 16, 32, 0.16);
  --gridline: rgba(13, 16, 32, 0.06);
  --header: rgba(255, 255, 255, 0.72);
  --text: #0d1020;
  --body-text: #3b4255;
  --muted: #555d70;
  --faint: #7d8494;
  --invert: #0d1020;
  --invert-hover: #23283d;
  --on-invert: #ffffff;
  --on-invert-muted: #a6adbd;
  --live-text: #116b35;
  --shadow: rgba(20, 24, 40, 0.28);
  --underline: rgba(13, 16, 32, 0.3);
  --amber: #c26a00;
  --coral: #e0483c;
  --violet: #6650d6;
  --cyan: #0a87a8;
  --green: #16a34a;
  --glow-a: rgba(102, 80, 214, 0.16);
  --glow-b: rgba(224, 72, 60, 0.12);
  --spot: rgba(102, 80, 214, 0.1);
  --aurora: 0.32;
  --aurora-blend: normal;
  --grain: 0.035;
  --grad: linear-gradient(100deg, var(--amber) 0%, var(--coral) 35%, var(--violet) 70%, var(--cyan) 100%);
  --display: "Bricolage", "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 22px;
  --wrap: 1160px;
}
/* Dark: the system preference unless the visitor picked light, or the visitor's explicit choice. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
  --bg: #07080d;
  --bg-2: #0c0e16;
  --surface: rgba(255, 255, 255, 0.035);
  --surface-2: rgba(255, 255, 255, 0.06);
  --card-a: rgba(255, 255, 255, 0.045);
  --card-b: rgba(255, 255, 255, 0.015);
  --tile-a: rgba(255, 255, 255, 0.09);
  --tile-b: rgba(255, 255, 255, 0.02);
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.16);
  --gridline: rgba(255, 255, 255, 0.05);
  --header: rgba(10, 12, 20, 0.62);
  --text: #eef0f6;
  --body-text: #c3c8d6;
  --muted: #9aa3b8;
  --faint: #6b7489;
  --invert: #eef0f6;
  --invert-hover: #ffffff;
  --on-invert: #0b0c12;
  --on-invert-muted: #4b5263;
  --live-text: #c9f7d8;
  --shadow: rgba(0, 0, 0, 0.9);
  --underline: rgba(255, 255, 255, 0.35);
  --amber: #f5b94a;
  --coral: #ff7a59;
  --violet: #8b7bff;
  --cyan: #3ad6f0;
  --green: #4ade80;
  --glow-a: rgba(139, 123, 255, 0.28);
  --glow-b: rgba(255, 122, 89, 0.22);
  --spot: rgba(139, 123, 255, 0.18);
  --aurora: 0.5;
  --aurora-blend: screen;
  --grain: 0.07;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #07080d;
  --bg-2: #0c0e16;
  --surface: rgba(255, 255, 255, 0.035);
  --surface-2: rgba(255, 255, 255, 0.06);
  --card-a: rgba(255, 255, 255, 0.045);
  --card-b: rgba(255, 255, 255, 0.015);
  --tile-a: rgba(255, 255, 255, 0.09);
  --tile-b: rgba(255, 255, 255, 0.02);
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.16);
  --gridline: rgba(255, 255, 255, 0.05);
  --header: rgba(10, 12, 20, 0.62);
  --text: #eef0f6;
  --body-text: #c3c8d6;
  --muted: #9aa3b8;
  --faint: #6b7489;
  --invert: #eef0f6;
  --invert-hover: #ffffff;
  --on-invert: #0b0c12;
  --on-invert-muted: #4b5263;
  --live-text: #c9f7d8;
  --shadow: rgba(0, 0, 0, 0.9);
  --underline: rgba(255, 255, 255, 0.35);
  --amber: #f5b94a;
  --coral: #ff7a59;
  --violet: #8b7bff;
  --cyan: #3ad6f0;
  --green: #4ade80;
  --glow-a: rgba(139, 123, 255, 0.28);
  --glow-b: rgba(255, 122, 89, 0.22);
  --spot: rgba(139, 123, 255, 0.18);
  --aurora: 0.5;
  --aurora-blend: screen;
  --grain: 0.07;
}

/* ---------- Base ---------- */
html { -webkit-text-size-adjust: 100%; }
body { background: var(--bg); color: var(--text); font-family: var(--body); -webkit-font-smoothing: antialiased; }
::selection { background: rgba(139, 123, 255, 0.35); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 8px; }

/* ---------- Header: product brand + "by Alkor Labs" + nav + theme toggle ---------- */
.ak-top {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: min(1160px, 100% - 32px); margin: 12px auto 0; padding: 8px 8px 8px 14px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--header);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  font-family: var(--body);
}
.ak-brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; color: var(--text); text-decoration: none; }
.ak-brand img { width: 30px; height: 30px; border-radius: 8px; flex: none; }
.ak-brand b { font: 650 17px/1 var(--display); letter-spacing: -0.01em; }
.ak-brand small { color: var(--faint); font-size: 12.5px; white-space: nowrap; }
.ak-nav { display: flex; align-items: center; gap: 2px; }
.ak-nav a { padding: 8px 12px; border-radius: 999px; color: var(--muted); text-decoration: none; font-size: 14.5px; white-space: nowrap; transition: color .2s, background .2s; }
.ak-nav a:hover, .ak-nav a[aria-current="page"] { color: var(--text); background: var(--surface-2); }
.ak-nav a.ak-pill { color: var(--on-invert); background: var(--invert); font-weight: 600; }
.ak-nav a.ak-pill:hover { background: var(--invert-hover); }
.theme-toggle {
  appearance: none; display: none; place-items: center; width: 36px; height: 36px; margin-right: 2px; padding: 0; flex: none;
  border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--muted); cursor: pointer;
  transition: color .2s, background .2s;
}
.js .theme-toggle { display: inline-grid; }
.theme-toggle:hover { color: var(--text); background: var(--surface-2); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: block; }
}

/* ---------- Shared pieces ---------- */
.ak-btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 13px 22px; border-radius: 999px; border: 1px solid transparent;
  font: 600 16px/1.2 var(--body); text-decoration: none; cursor: pointer; transition: transform .2s, background .2s;
}
.ak-btn:hover { transform: translateY(-2px); }
.ak-btn-primary { color: var(--on-invert); background: var(--invert); }
.ak-btn-primary:hover { background: var(--invert-hover); }
.ak-btn-ghost { color: var(--text); border-color: var(--line-2); background: var(--surface); }
.ak-btn-ghost:hover { background: var(--surface-2); }
.ak-soon {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text); font: 600 15px/1.2 var(--body);
}
.ak-soon::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 4px color-mix(in srgb, var(--amber) 20%, transparent); }
.ak-kicker { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 14px; color: var(--muted); font: 600 12.5px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; }
.ak-kicker::before { content: ""; width: 24px; height: 1px; background: var(--grad); }
.ak-grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Footer ---------- */
.ak-foot { width: min(1160px, 100% - 32px); margin: clamp(72px, 9vw, 112px) auto 0; padding: 32px 0 40px; border-top: 1px solid var(--line); color: var(--faint); font: 400 14px/1.6 var(--body); }
.ak-foot p { margin: 0 0 10px; }
.ak-foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.ak-foot a { color: var(--muted); text-decoration: none; }
.ak-foot a:hover { color: var(--text); }

@media (max-width: 680px) {
  .ak-brand small { display: none; }
  .ak-nav a:not(.ak-pill):not([data-keep]) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
