/* in.artificial.kz — base styles. Tokens, header, grain and type follow artificial.kz (/opt/apps/artificial/style.css).
   Fonts: self-hosted variable woff2, Latin + Cyrillic + Kazakh (Әә Ғғ Ққ Ңң Өө Ұұ Үү Һһ Іі), SIL OFL. */
@font-face { font-family: "Inter Tight"; font-style: normal; font-weight: 300 600; font-display: swap; src: url("fonts/inter-tight.woff2") format("woff2"); unicode-range: U+0020-007E, U+00A0-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+0400-045F, U+0490-0493, U+049A-049B, U+04A2-04A3, U+04AE-04B1, U+04BA-04BB, U+04D8-04D9, U+04E8-04E9, U+2010-2014, U+2018-201E, U+2022, U+2026, U+2032-2033, U+2039-203A, U+20AC, U+20B8, U+2116, U+2122, U+2190-2193, U+2197, U+2212, U+2713; }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 500; font-display: block; src: url("fonts/jetbrains-mono.woff2") format("woff2"); unicode-range: U+0020-007E, U+00A0-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+0400-045F, U+0490-0493, U+049A-049B, U+04A2-04A3, U+04AE-04B1, U+04BA-04BB, U+04D8-04D9, U+04E8-04E9, U+2010-2014, U+2018-201E, U+2022, U+2026, U+2032-2033, U+2039-203A, U+20AC, U+2116, U+2122, U+2190-2193, U+2197, U+2212, U+2713; }

:root {
  color-scheme: dark;
  --bg: #0e0e0e;
  --fg: #f2f2f2;
  --soft: #c8c8c8;
  --mid: #8a8a8a;
  --dim: #3a3a3a;
  --line: #1e1e1e;
  --card: #131313;
  --bad: #ff7a7a;
  --sans: "Inter Tight", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --pad: clamp(16px, 4vw, 56px);
  --sat: env(safe-area-inset-top, 0px);
  --ease: cubic-bezier(.2, .7, .1, 1);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  --grain-bar: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .088 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); color: var(--fg); -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body {
  min-height: 100svh; display: flex; flex-direction: column;
  background: var(--bg); padding-top: var(--sat);
  font-family: var(--sans); font-weight: 400; line-height: 1.4;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
a:focus:not(:focus-visible), button:focus:not(:focus-visible) { outline: none; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }
::selection { background: var(--fg); color: var(--bg); }
button, input { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 30; padding: 10px 16px; border-radius: 20px; background: var(--fg); color: var(--bg); font-size: 14px; }
.skip:focus { top: calc(12px + var(--sat)); }

/* film grain over the page — UNDER the header (9 < 10); the header carries its own grain (as on artificial.kz) */
html::after {
  content: ""; position: fixed; inset: 0; z-index: 9; pointer-events: none;
  background-image: var(--grain); background-size: 180px 180px; opacity: .16;
}

/* ---------- header ---------- */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: calc(12px + var(--sat)) var(--pad) 4px;
  font-family: var(--mono); font-size: 14.5px; letter-spacing: .06em; color: #fff;
  background-color: #181818;   /* iPhone paints the strip under the clock with this colour */
}
.bar::before { content: ""; position: absolute; inset: -300px 0 0 0; z-index: -1; background: var(--grain-bar) 0 300px / 180px 180px, var(--bg); }
.bar::after {
  content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 24px;
  background: var(--grain-bar) 0 0 / 180px 180px, var(--bg);
  -webkit-mask-image: linear-gradient(#000, transparent); mask-image: linear-gradient(#000, transparent);
}
.bar::before, .bar::after { pointer-events: none; }
.mark { display: inline-flex; align-items: center; gap: 10px; line-height: 40px; white-space: nowrap; }
.mark .ball { width: 26px; height: 26px; flex: none; color: var(--fg); transition: transform .6s var(--ease); }
.mark .dom { color: var(--fg); }
.mark .dom span { color: var(--mid); }
@media (hover: hover) { .mark:hover .ball { transform: rotate(-24deg); } }

/* language switch: EN · KK · RU */
.langs { display: flex; align-items: center; font-size: 13px; letter-spacing: .08em; }
.langs a, .langs b { display: grid; place-items: center; min-width: 34px; height: 40px; padding: 0 4px; font-weight: 400; }
.langs a { color: var(--mid); transition: color .25s; }
.langs a:hover, .langs a:focus-visible { color: var(--fg); }
.langs b { color: var(--fg); }
.langs i { font-style: normal; color: var(--dim); padding: 0 1px; }

/* ---------- layout ---------- */
main { flex: 1; width: 100%; position: relative; }
.wrap { padding: calc(132px + var(--sat)) var(--pad) clamp(56px, 10vh, 120px); }
.idx {
  display: block; font-family: var(--mono); font-size: 13.5px; font-weight: 400;
  letter-spacing: .08em; text-transform: uppercase; color: var(--mid);
}
.idx b { font-weight: 400; color: inherit; margin-right: .7em; }
h1 {
  font-weight: 300; font-size: clamp(48px, 7.4vw, 112px); line-height: .92; letter-spacing: -.04em;
  margin: 18px 0 clamp(32px, 5vh, 56px) -0.05em;
  text-wrap: balance; overflow-wrap: anywhere; hyphens: auto;
}
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; }
.muted { color: var(--mid); }
.line { color: var(--mid); font-size: 17px; line-height: 1.55; max-width: 560px; }
.line a, a.u { color: var(--fg); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: rgba(242, 242, 242, .35); transition: text-decoration-color .25s; }
.line a:hover, a.u:hover { text-decoration-color: var(--fg); }

/* auth screens: form on the left, dotted ball on the right (desktop) */
.auth { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: var(--pad); align-items: center; min-height: calc(100svh - 64px); padding-top: calc(96px + var(--sat)); }
.auth .form { max-width: 560px; }
.art { display: grid; place-items: center; align-self: center; }
.art .ball { width: min(100%, 52vh, 520px); height: auto; color: var(--fg); opacity: .92; }
@media (max-width: 860px) {
  .auth { grid-template-columns: 1fr; align-items: start; min-height: 0; padding-top: calc(104px + var(--sat)); }
  .art { display: none; }
}

/* ---------- fields and buttons ---------- */
.form { display: grid; gap: 12px; }
.field {
  width: 100%; height: 72px; padding: 0 30px; border-radius: 36px;
  border: 1px solid var(--dim); background: transparent; color: var(--fg);
  font-size: 24px; font-weight: 300; letter-spacing: -.01em; outline: none;
  transition: border-color .25s;
}
.field::placeholder { color: #5a5a5a; }
.field:hover { border-color: #555; }
.field:focus { border-color: var(--fg); }
.field.bad, .field[aria-invalid="true"] { border-color: var(--bad); }
.field:-webkit-autofill { -webkit-text-fill-color: var(--fg); -webkit-box-shadow: 0 0 0 100px var(--bg) inset; caret-color: var(--fg); }
.input { /* small field, as in the artificial.kz admin */
  width: 100%; height: 52px; padding: 0 20px; border-radius: 26px; border: 1px solid var(--dim);
  background: transparent; color: var(--fg); font-size: 16px; outline: none; transition: border-color .25s;
}
.input:focus { border-color: var(--fg); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 64px; padding: 0 32px; border-radius: 32px; border: 0;
  background: var(--fg); color: var(--bg); font-size: 18px; font-weight: 500; letter-spacing: -.005em;
  cursor: pointer; white-space: nowrap; transition: transform .2s, opacity .25s, background-color .25s;
}
.btn:hover { background: #fff; }
.btn:active { transform: scale(.98); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .4; cursor: default; transform: none; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.wide { width: 100%; }
.btn.ghost { background: transparent; color: var(--fg); border: 1px solid var(--dim); font-weight: 400; }
.btn.ghost:hover { border-color: var(--fg); }
.pill { /* small pill, as the filter chips on artificial.kz */
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 36px; padding: 0 16px; border-radius: 18px; border: 1px solid var(--dim); background: transparent;
  font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--mid);
  cursor: pointer; white-space: nowrap; transition: color .25s, border-color .25s, background-color .25s;
}
.pill:hover { color: var(--fg); border-color: var(--mid); }
.pill[aria-selected="true"], .pill[aria-pressed="true"], .pill.on { background: var(--fg); border-color: var(--fg); color: var(--bg); }
.pill:disabled { color: var(--dim); border-color: var(--line); cursor: default; }
.or { display: flex; align-items: center; gap: 14px; margin: 10px 0; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mid); }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.err { min-height: 22px; font-size: 15px; color: var(--bad); }
.err:empty { min-height: 0; }
.note { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--mid); }

/* links row under a form: "Send again 0:42 · Use another email" */
.acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; margin-top: 14px; font-family: var(--mono); font-size: 13px; letter-spacing: .04em; }
.acts a, .acts button { background: none; border: 0; padding: 10px 0; color: var(--mid); cursor: pointer; transition: color .25s; }
.acts a:hover, .acts button:not(:disabled):hover { color: var(--fg); }
.acts button:disabled { color: #5a5a5a; cursor: default; }
.acts .t { font-variant-numeric: tabular-nums; }

/* ---------- 6-digit code: one real input over six drawn cells ---------- */
.code { --cg: 12px; --ch: 88px; --fs: 44px; container-type: inline-size; position: relative; width: 100%; height: var(--ch); overflow: hidden; }
.code > * { --cw: calc((100cqw - 5 * var(--cg)) / 6); }
.code .cells { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--cg); pointer-events: none; }
.code .cells i { border: 1px solid var(--dim); border-radius: 18px; transition: border-color .2s, background-color .2s; }
.code input {
  position: absolute; inset: 0 auto 0 0; width: calc(6 * (var(--cw) + var(--cg)) + 40px); height: 100%;
  padding: 0 0 0 calc((var(--cw) - .6 * var(--fs)) / 2);
  border: 0; background: transparent; outline: none; color: var(--fg);
  font-family: var(--mono); font-size: var(--fs); font-weight: 400; letter-spacing: calc(var(--cw) + var(--cg) - .6 * var(--fs));
  font-variant-numeric: tabular-nums; caret-color: transparent;
}
.code input::placeholder { color: transparent; }
.code:hover .cells i { border-color: #555; }
.code:focus-within .cells i.cur, .code:focus-within .cells i.cur ~ i:last-child:is(.cur) { border-color: var(--fg); }
.code .cells i.cur { position: relative; }
.code:focus-within .cells i.cur::after { content: ""; position: absolute; left: 50%; top: 26%; bottom: 26%; width: 2px; margin-left: -1px; background: var(--fg); animation: blink 1.1s steps(1) infinite; }
.code .cells i.full { border-color: #5a5a5a; }
.code.bad .cells i, .code.bad:focus-within .cells i.cur { border-color: var(--bad); }
.code.bad { animation: shake .4s; }
html:not(.js) .code .cells { display: none; }
html:not(.js) .code input { width: 100%; border: 1px solid var(--dim); border-radius: 18px; caret-color: var(--fg); }
@keyframes blink { 50% { opacity: 0; } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.sent { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; color: var(--mid); margin: -12px 0 28px; overflow-wrap: anywhere; }
.sent b { font-weight: 400; color: var(--fg); }

/* ---------- account page ---------- */
.me { display: grid; gap: clamp(56px, 9vh, 96px); max-width: 960px; }
.who { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.who-sec h1 { margin: 18px 0 0 -0.05em; font-size: clamp(40px, 6vw, 88px); }
.who-sec h1.h-mail { font-size: clamp(32px, 4.4vw, 64px); letter-spacing: -.03em; }
.who-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 22px; }
.status {
  display: inline-flex; align-items: center; gap: 9px; height: 36px; padding: 0 16px 0 13px; border-radius: 18px;
  border: 1px solid var(--dim); font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg);
}
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--mid); }
.status.pending::before { background: transparent; border: 1.5px solid var(--fg); animation: pulse 2s ease-in-out infinite; }
.status.approved { background: var(--fg); border-color: var(--fg); color: var(--bg); padding-left: 11px; }
.status.approved::before { width: 14px; height: 14px; background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M4 7.2l2 2 4-4.4' fill='none' stroke='%23f2f2f2' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat; }
.status.needs_info::before { background: var(--fg); }
.status.rejected, .status.suspended { color: var(--mid); }
.status.rejected::before, .status.suspended::before { background: var(--dim); }
@keyframes pulse { 50% { opacity: .3; } }
.mod-note { max-width: 640px; padding-left: 16px; border-left: 1px solid var(--fg); font-size: 17px; line-height: 1.55; color: var(--soft); margin-top: 20px; }
.who-mail { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; color: var(--mid); overflow-wrap: anywhere; }

.sec .idx { margin-bottom: 24px; }
/* MCP address with a copy button */
.mcp {
  display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px clamp(20px, 2.4vw, 30px);
  border: 1px solid var(--dim); border-radius: 44px; background: rgba(14, 14, 14, .6);
}
.mcp code { flex: 1; min-width: 0; font-family: var(--mono); font-size: clamp(17px, 2.3vw, 28px); letter-spacing: -.01em; color: var(--fg); white-space: nowrap; overflow-x: auto; scrollbar-width: none; }
.mcp code::-webkit-scrollbar { display: none; }
.mcp code span { color: var(--mid); }
.copy { flex: none; }
.copy .go, .copy .ok { display: inline-flex; align-items: center; gap: 8px; }
.copy .ok { display: none; }
.copy.done .ok { display: inline-flex; }
.copy.done .go { display: none; }

/* client tabs */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; }
.panel { margin-top: 8px; }
html.js .panel:not(.on) { display: none; }
html:not(.js) .panel { border-top: 1px solid var(--line); margin-top: 32px; }
html:not(.js) .panel::before { content: attr(data-name); display: block; padding-top: 20px; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mid); }
.steps { list-style: none; counter-reset: s; }
.steps li {
  counter-increment: s; display: grid; grid-template-columns: 64px minmax(0, 1fr); column-gap: 16px; align-items: baseline;
  padding: 20px 0; border-bottom: 1px solid var(--line); font-size: clamp(17px, 1.6vw, 20px); line-height: 1.45;
}
.steps li::before { content: "/ 0" counter(s); font-family: var(--mono); font-size: 12px; letter-spacing: .08em; color: var(--mid); }
.steps li > * { grid-column: 2; }
.steps kbd, .ui { font-family: var(--mono); font-size: .8em; letter-spacing: .01em; color: var(--fg); }
.steps .m { color: var(--mid); }
.snip { position: relative; display: flex; align-items: flex-start; gap: 10px; margin-top: 12px; padding: 14px 10px 14px 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
.snip pre { flex: 1; min-width: 0; overflow-x: auto; font-family: var(--mono); font-size: 13px; line-height: 1.6; color: var(--soft); white-space: pre-wrap; overflow-wrap: anywhere; padding-top: 6px; }
.snip-l { display: block; margin-top: 16px; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--mid); }
.first { display: flex; align-items: center; gap: 14px; margin-top: 28px; padding: 20px 14px 20px 22px; border-radius: 22px; background: var(--card); border: 1px solid var(--line); }
.first q { flex: 1; min-width: 0; font-size: clamp(17px, 1.7vw, 21px); line-height: 1.4; quotes: none; }
.first .idx { margin-bottom: 8px; font-size: 11px; }
.conn { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 20px; font-family: var(--mono); font-size: 12px; letter-spacing: .04em; color: var(--mid); }
.conn b { font-weight: 400; color: var(--fg); }
.conn b::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%; background: var(--fg); vertical-align: 1px; }
.out { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding-top: 28px; border-top: 1px solid var(--line); }

/* ---------- error page ---------- */
.oops { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--pad); align-items: end; min-height: calc(100svh - 64px); padding-top: calc(96px + var(--sat)); }
.oops .num { font-family: var(--mono); font-size: 13.5px; letter-spacing: .08em; color: var(--mid); }
.oops .art .ball { width: min(38vw, 46vh, 420px); opacity: .35; }
.oops .btns { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 860px) { .oops { grid-template-columns: 1fr; align-items: start; min-height: 0; padding-top: calc(104px + var(--sat)); } }

/* ---------- footer ---------- */
.foot {
  position: relative; display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 22px var(--pad) calc(22px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line); font-family: var(--mono); font-size: 12px; letter-spacing: .05em; color: var(--mid);
}
.foot a { transition: color .25s; }
.foot a:hover { color: var(--fg); }

/* ---------- phones ---------- */
@media (max-width: 560px) {
  .bar { font-size: 13px; gap: 8px; }
  .mark { gap: 8px; }
  .mark .ball { width: 22px; height: 22px; }
  .langs { font-size: 12px; }
  .langs a, .langs b { min-width: 32px; height: 44px; }
  .idx { font-size: 12.5px; }
  h1 { font-size: clamp(42px, 13vw, 64px); }
  .field { height: 64px; padding: 0 24px; font-size: 20px; border-radius: 32px; }
  .btn { height: 60px; font-size: 17px; }
  .code { --cg: 8px; --ch: 72px; --fs: 34px; }
  .code .cells i { border-radius: 14px; }
  .mcp { border-radius: 26px; padding: 8px 8px 8px 18px; }
  .mcp .copy .lbl { display: none; }
  .mcp .copy { width: 44px; padding: 0; }
  .steps li { grid-template-columns: 1fr; row-gap: 6px; padding: 16px 0; }
  .steps li > * { grid-column: 1; }
  .first { flex-direction: column; align-items: stretch; }
  .first .pill { align-self: flex-start; }
  .out .btn { flex: 1; }
}
@media (max-width: 360px) { .mark .dom { display: none; } }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
@media print {
  html::after, .bar, .foot { display: none; }
  html, body { background: #fff; color: #000; }
}

/* button + quiet link in one row */
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; margin-top: 28px; }
.cta .btn { padding: 0 44px; }
.cta .link { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; color: var(--mid); padding: 10px 0; transition: color .25s; }
.cta .link:hover { color: var(--fg); }
.sent.who-mail { margin: 0 0 6px; }
.acts .done { color: var(--fg); }
.acts .done::before { content: "✓ "; }
.me > *, .sec, .panel, .steps li > * { min-width: 0; }
@media (max-width: 560px) { .out .btn { flex: 0 1 auto; padding: 0 40px; } }

/* ---------- header: section menu, sign-in icon, DEMO, mobile menu (blocks nav / acct / bar_end / after_bar of base.html) ---------- */
.bar-r { display: flex; align-items: center; gap: 14px; }
.acct { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--mid); overflow: hidden;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .04em; color: var(--fg); transition: border-color .25s, color .25s; }
.acct:hover, .acct:focus-visible { border-color: var(--fg); }
.acct.anon { border: 0; color: var(--mid); }
.acct.anon:hover, .acct.anon:focus-visible { color: var(--fg); }
.acct svg { width: 30px; height: 30px; display: block; }
.acct.pic { border-color: var(--dim); }
.acct img { width: 100%; height: 100%; object-fit: cover; display: block; }
.demo-tag { font-family: var(--mono); font-size: 10px; letter-spacing: .14em; line-height: 16px; color: var(--mid); border: 1px solid var(--dim); border-radius: 9px; padding: 0 7px; }
.bar.has-nav { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); }
.bar.has-nav .bar-r { justify-self: end; }
.pnav { display: flex; gap: clamp(16px, 2vw, 30px); height: 40px; align-items: center; font-size: 14px; letter-spacing: .06em; white-space: nowrap; }
.pnav a { color: var(--mid); transition: color .25s; padding: 10px 0; }
.pnav a:hover, .pnav a[aria-current="page"] { color: var(--fg); }
.burger { display: none; width: 40px; height: 40px; margin-right: -8px; border: 0; background: none; cursor: pointer; position: relative; }
.burger i { position: absolute; left: 10px; right: 10px; height: 1.5px; background: var(--fg); transition: transform .3s var(--ease); }
.burger i:first-child { top: 15px; } .burger i:last-child { top: 23px; }
.burger[aria-expanded="true"] i:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] i:last-child { transform: translateY(-4px) rotate(-45deg); }
.menu { position: fixed; inset: 0; z-index: 9; background: var(--bg); padding: calc(96px + var(--sat)) var(--pad) 40px; display: flex; flex-direction: column; gap: 32px; overflow-y: auto; }
.menu[hidden] { display: none; }
.menu nav { display: grid; }
.menu nav a { font-size: clamp(32px, 9vw, 52px); font-weight: 300; letter-spacing: -.03em; padding: 6px 0; color: var(--mid); }
.menu nav a[aria-current="page"] { color: var(--fg); }
.menu-langs { display: flex; gap: 22px; font-family: var(--mono); font-size: 15px; letter-spacing: .08em; border-top: 1px solid var(--line); padding-top: 24px; }
.menu-langs a { color: var(--mid); padding: 10px 0; } .menu-langs b { font-weight: 400; padding: 10px 0; }
@media (max-width: 1180px) {
  .pnav { display: none; }
  .burger { display: block; }
  .bar.has-nav { display: flex; }
}
@media (max-width: 640px) { .bar-r { gap: 8px; } .acct { width: 32px; height: 32px; } .acct svg { width: 28px; height: 28px; } }
@media (max-width: 560px) { .bar.has-nav .langs a, .bar.has-nav .langs i { display: none; } }
@media (max-width: 379px) { .demo-tag { display: none; } }
@media print { .bar-r, .pnav, .burger, .menu { display: none !important; } }
