@font-face {
  font-family: Geist;
  src: url(/fonts/Geist-Variable.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url(/fonts/GeistMono-Variable.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

/* Tokens. Light is the default; dark follows the system unless data-theme says otherwise.
   Structure is drawn with hairlines (--line); elevation with layered shadows (--lift). Colour is kept for state:
   warm = needs you, nothing else is tinted. */
:root {
  --bg: #f7f7f5;
  --panel: #fff;
  --sub: #f0f0ee;
  --sub2: #e8e8e5;
  --line: #e6e6e2;
  --fg: #1a1a1e;
  --mut: #5f5f69;
  --faint: #8b8b95;
  --warm: #a85a08;
  --warmbg: #fbf4ea;
  --warmline: #e0bf8c;
  --bad: #c13030;
  --ring: #4a78e8;
  --btn: #1a1a1e;
  --btnfg: #fff;
  --screen: #16181d;
  --lift: 0 0 0 1px rgb(0 0 0/.06),0 1px 2px rgb(0 0 0/.04),0 4px 12px -2px rgb(0 0 0/.05);
  --pop: 0 0 0 1px rgb(0 0 0/.07),0 8px 24px -4px rgb(0 0 0/.14),0 2px 6px rgb(0 0 0/.06);
  --edge: oklch(0 0 0/.1);
  --font: Geist,system-ui,-apple-system,sans-serif;
  --mono: "Geist Mono",ui-monospace,Menlo,monospace;
  --ease: cubic-bezier(.23,1,.32,1);
  --ease-io: cubic-bezier(.77,0,.175,1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1012;
    --panel: #151618;
    --sub: #1d1e21;
    --sub2: #26272b;
    --line: #26272b;
    --fg: #ececef;
    --mut: #a0a0a9;
    --faint: #72727c;
    --warm: #f0b35a;
    --warmbg: #1f1a12;
    --warmline: #5a4526;
    --bad: #ff7b72;
    --ring: #7ea0f5;
    --btn: #ececef;
    --btnfg: #0f1012;
    --lift: 0 0 0 1px rgb(255 255 255/.07),0 1px 2px rgb(0 0 0/.4),0 4px 12px -2px rgb(0 0 0/.35);
    --pop: 0 0 0 1px rgb(255 255 255/.09),0 8px 28px -4px rgb(0 0 0/.6);
    --edge: oklch(1 0 0/.1);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1012;
  --panel: #151618;
  --sub: #1d1e21;
  --sub2: #26272b;
  --line: #26272b;
  --fg: #ececef;
  --mut: #a0a0a9;
  --faint: #72727c;
  --warm: #f0b35a;
  --warmbg: #1f1a12;
  --warmline: #5a4526;
  --bad: #ff7b72;
  --ring: #7ea0f5;
  --btn: #ececef;
  --btnfg: #0f1012;
  --lift: 0 0 0 1px rgb(255 255 255/.07),0 1px 2px rgb(0 0 0/.4),0 4px 12px -2px rgb(0 0 0/.35);
  --pop: 0 0 0 1px rgb(255 255 255/.09),0 8px 28px -4px rgb(0 0 0/.6);
  --edge: oklch(1 0 0/.1);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}
html,
body,
#root {
  height: 100%;
}
body {
  margin: 0;
  background: var(--panel);
  color: var(--fg);
  font: 14px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
button {
  font: inherit;
  color: inherit;
}
h1,
h2,
h3,
h4 {
  text-wrap: balance;
}
p,
small,
.md {
  text-wrap: pretty;
}
code,
pre,
.mono {
  font-family: var(--mono);
  font-size: 12px;
}
a {
  color: inherit;
}
.tn {
  font-variant-numeric: tabular-nums;
}
:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
  border-radius: 8px;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Buttons: a hairline ring instead of a border, a press at .96, only the properties that change are transitioned. */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 0;
  background: var(--panel);
  color: var(--fg);
  border-radius: 8px;
  padding: 0 12px;
  height: 30px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: inset 0 0 0 1px var(--line);
  transition-property: background-color, box-shadow, color, scale, opacity;
  transition-duration: 0.15s, 0.15s, 0.15s, 0.12s, 0.15s;
  transition-timing-function: var(--ease);
}
.btn:active {
  scale: 0.96;
}
.btn.sm {
  height: 26px;
  padding: 0 10px;
  font-size: 12.5px;
  border-radius: 7px;
}
.btn.pri {
  background: var(--btn);
  color: var(--btnfg);
  box-shadow: none;
}
.btn.quiet,
.btn.ghost {
  background: transparent;
  box-shadow: none;
  color: var(--mut);
}
@media (hover: hover) {
  .btn:hover {
    background: var(--sub);
  }
  .btn.pri:hover {
    opacity: 0.86;
    background: var(--btn);
  }
  .btn.quiet:hover,
  .btn.ghost:hover {
    background: var(--sub);
    color: var(--fg);
  }
  .btn.bad:hover {
    color: var(--bad);
  }
}
.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
  scale: 1;
}
.btn svg,
.chip svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.ibtn {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: var(--mut);
  border-radius: 7px;
  cursor: pointer;
  transition-property: background-color, color, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
  padding: 0;
}
.ibtn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ibtn:active {
  scale: 0.96;
}
.ibtn::after {
  content: "";
  position: absolute;
  inset: -8px;
}
@media (hover: hover) {
  .ibtn:hover {
    background: var(--sub);
    color: var(--fg);
  }
}
.ibtn[aria-pressed="true"] {
  color: var(--fg);
  background: var(--sub);
}
.tip {
  background: var(--fg);
  color: var(--panel);
  font-size: 12px;
  font-weight: 500;
  padding: 4px 8px;
  border-radius: 6px;
  z-index: 60;
  margin: 0;
  box-shadow: var(--pop);
  border: 0;
}

/* Shell */
.app {
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
}
.side {
  background: var(--bg);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 12px 8px 10px;
  gap: 2px;
  min-height: 0;
  position: relative;
}
.top {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 6px 10px;
}
.top b {
  font-weight: 650;
  font-size: 15px;
  letter-spacing: -0.02em;
}
.top .brand {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.brandmark {
  flex: none;
  color: var(--fg);
}
.where {
  margin-left: auto;
  font-size: 12.5px;
  color: var(--mut);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 0;
  border-radius: 7px;
  padding: 0 6px 0 8px;
  background: transparent;
  cursor: pointer;
  height: 26px;
  font-weight: 500;
  transition-property: background-color, color, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
  position: relative;
}
.where:active {
  scale: 0.96;
}
.where svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
@media (hover: hover) {
  .where:hover {
    background: var(--sub);
    color: var(--fg);
  }
}
.where[aria-expanded="true"] {
  background: var(--sub);
  color: var(--fg);
}
/* A status dot exists only where it means something: working (quiet pulse) and needs-you (warm). Idle has none. */
.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex: none;
  display: inline-block;
  background: var(--faint);
}
.dot[data-state="needs"] {
  background: var(--warm);
}
.dot[data-state="thinking"],
.dot[data-state="working"] {
  background: var(--mut);
}
.bots {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.bot {
  position: relative;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 6px 8px;
  border-radius: 10px;
  border: 0;
  background: none;
  text-align: left;
  width: 100%;
  cursor: pointer;
  transition-property: background-color, scale;
  transition-duration: 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.bot:active {
  scale: 0.98;
}
@media (hover: hover) {
  .bot:hover {
    background: var(--sub);
  }
}
.bot[aria-current="true"] {
  background: var(--sub);
}
.bot .t {
  min-width: 0;
  flex: 1;
}
.bot b {
  display: block;
  font-weight: 550;
  font-size: 13.5px;
  line-height: 1.3;
}
.bot small {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--mut);
  font-size: 12px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bot small span {
  overflow: hidden;
  text-overflow: ellipsis;
}
.bot[data-needs="true"] small {
  color: var(--warm);
}
.bot .mark {
  display: none;
  position: absolute;
  left: 30px;
  top: 5px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--warm);
  box-shadow: 0 0 0 2px var(--bg);
}
.face {
  flex: none;
  display: block;
  position: relative;
  overflow: hidden;
  color: #17171a;
}
.face .eyes {
  position: absolute;
  left: 0;
  right: 0;
  top: 34%;
  display: flex;
  justify-content: center;
  transform: translate(var(--ex, 0px), var(--ey, 0px));
  transition: transform 0.14s var(--ease);
}
.face .eye {
  display: block;
  background: currentColor;
  border-radius: 99px;
  transition: transform 0.09s ease-out;
  transform-origin: center;
}
.face.blink .eye {
  transform: scaleY(0.12);
}
.grow {
  flex: 1;
}
.foot {
  border-top: 1px solid var(--line);
  padding: 10px 6px 2px;
  display: grid;
  gap: 4px;
  font-size: 12.5px;
  color: var(--mut);
}
.foot .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.foot .need {
  color: var(--warm);
  font-weight: 550;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  font-size: 12.5px;
}
@media (hover: hover) {
  .foot .need:hover {
    text-decoration: underline;
  }
}

.main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  position: relative;
}
.hd {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  flex: none;
}
.hd b {
  font-weight: 600;
  white-space: nowrap;
}
.hd .st {
  color: var(--mut);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hd .st span {
  overflow: hidden;
  text-overflow: ellipsis;
}
.hd .sp {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--mut);
  font-size: 12.5px;
  white-space: nowrap;
}
.feed {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  scroll-behavior: auto;
}
.col {
  width: 100%;
  max-width: 720px;
  padding: 20px 20px 12px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: auto;
}

.you {
  align-self: flex-end;
  background: var(--sub);
  border-radius: 14px;
  padding: 7px 12px;
  max-width: min(500px, 92%);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.msg {
  display: flex;
  gap: 10px;
  min-width: 0;
}
.msg .body {
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  justify-items: start;
}
.msg .body > * {
  max-width: 100%;
}
.who {
  font-weight: 600;
  font-size: 13px;
  color: var(--fg);
}
.stale {
  position: fixed;
  left: 50%;
  top: 16px;
  translate: -50% 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: min(560px, calc(100% - 32px));
  text-wrap: pretty;
  padding: 10px 10px 10px 14px;
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--pop);
  font-size: 13px;
  color: var(--fg);
}
.stale .btn {
  flex: none;
}
.signed {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--mut);
  min-height: 20px;
}
.signed .btn {
  margin-left: 4px;
}
.signed > svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.ghmark {
  width: 15px;
  height: 15px;
  flex: none;
}
.link.pr .prico {
  width: 40px;
  height: 40px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: var(--sub);
  color: var(--fg);
  flex: none;
}
.link.pr .u {
  font-family: var(--font);
  font-weight: 550;
}
.signc {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--lift);
  max-width: min(520px, 100%);
}
.signt {
  font-size: 13px;
  line-height: 1.5;
  color: var(--mut);
  text-wrap: pretty;
}
.signt b {
  color: var(--fg);
  font-weight: 550;
}
.smh {
  margin-top: -14px;
  min-width: 0;
}
.smh > div {
  padding-top: 14px;
  display: flex;
  flex-direction: column;
}
.smh > div:empty {
  padding-top: 0;
}
.thk {
  display: grid;
  gap: 4px;
  max-width: min(560px, 100%);
}
.thkh {
  display: flex;
  align-items: center;
  gap: 7px;
}
.thkl {
  font-size: 13px;
  font-weight: 500;
  color: var(--mut);
  background: linear-gradient(90deg, var(--mut) 40%, var(--fg) 50%, var(--mut) 60%) 0 0/300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.thkt {
  margin-left: 23px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--faint);
  max-height: calc(1.55em * 4);
  overflow: hidden;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 1.4em);
  mask-image: linear-gradient(to bottom, transparent 0, #000 1.4em);
}
.tho {
  display: grid;
  gap: 6px;
  max-width: min(560px, 100%);
}
.thob {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  justify-self: start;
  border: 0;
  background: none;
  padding: 2px 0;
  font: inherit;
  font-size: 12.5px;
  color: var(--faint);
  cursor: pointer;
}
.thob svg {
  width: 11px;
  height: 11px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: rotate 0.15s var(--ease);
}
.tho[data-open="true"] .thob svg {
  rotate: 90deg;
}
@media (hover: hover) {
  .thob:hover {
    color: var(--mut);
  }
}
.thof {
  margin-left: 16px;
  padding-left: 10px;
  box-shadow: inset 1px 0 0 var(--line);
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--faint);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.note {
  font-size: 12.5px;
  color: var(--mut);
  text-align: center;
  align-self: center;
  max-width: 100%;
  overflow-wrap: anywhere;
}
.handoff {
  font-size: 12.5px;
  color: var(--mut);
  align-self: center;
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  min-width: 0;
}
.handoff .hv {
  min-width: 0;
  overflow-wrap: anywhere;
}
.handoff svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

/* Steps: one quiet, collapsible list */
.steps {
  font-size: 12.5px;
  color: var(--mut);
}
.steps summary {
  display: flex;
  max-width: 100%;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  list-style: none;
  border-radius: 6px;
  padding: 1px 4px 1px 0;
  user-select: none;
}
.steps summary::-webkit-details-marker {
  display: none;
}
.steps summary > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.steps summary svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: rotate 0.15s var(--ease);
  flex: none;
}
.steps[open] summary svg {
  rotate: 90deg;
}
@media (hover: hover) {
  .steps summary:hover {
    color: var(--fg);
  }
}
.steps ol {
  list-style: none;
  margin: 5px 0 0 5px;
  padding: 0 0 0 12px;
  border-left: 1px solid var(--line);
  display: grid;
  gap: 3px;
}
.steps li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  min-width: 0;
  overflow-wrap: anywhere;
}
.steps li .mk {
  width: 10px;
  height: 10px;
  flex: none;
  margin-top: calc((1lh - 10px) / 2);
  display: grid;
  place-items: center;
} /* on the first line of a long step */
.steps li .mk svg {
  width: 10px;
  height: 10px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.steps li[data-state="run"] .mk {
  border: 1.5px solid var(--faint);
  border-top-color: transparent;
  border-radius: 50%;
}
.steps li[data-state="fail"],
.steps li[data-state="stopped"] {
  color: var(--faint);
}
.steps li small {
  color: var(--faint);
  font-size: 12px;
}
.steps .tick {
  font-variant-numeric: tabular-nums;
}

/* Streamdown text */
.md {
  min-width: 0;
  overflow-wrap: anywhere;
}
.md > div > *:first-child,
.md > *:first-child {
  margin-top: 0;
}
.md p {
  margin: 0.2em 0;
}
.md ul,
.md ol {
  margin: 0.3em 0;
  padding-left: 1.3em;
}
.md h1,
.md h2,
.md h3 {
  font-size: 14.5px;
  margin: 0.7em 0 0.2em;
}
.md a {
  text-underline-offset: 2px;
  text-decoration-color: var(--faint);
}
.md code {
  background: var(--sub);
  border-radius: 5px;
  padding: 1px 5px;
}
/* Tables scroll sideways instead of squeezing words to one letter per line on phones. */
.md table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
}
.md th,
.md td {
  overflow-wrap: normal;
  word-break: normal;
}
.md pre {
  background: var(--sub);
  border-radius: 10px;
  padding: 10px 12px;
  overflow: auto;
  max-width: 100%;
}
.md pre code {
  background: none;
  padding: 0;
}
.md table {
  border-collapse: collapse;
}
.md td,
.md th {
  border: 1px solid var(--line);
  padding: 2px 8px;
}
.md button {
  display: none;
}

/* The approval: a calm request, the same for every kind. Neutral surface; warm only while it waits for you. */
.ap {
  border-radius: 14px;
  padding: 12px 12px 10px;
  background: var(--panel);
  box-shadow: var(--lift);
  max-width: 480px;
  width: 100%;
  display: grid;
  gap: 3px;
  transition-property: box-shadow, background-color;
  transition-duration: 0.2s;
  transition-timing-function: var(--ease);
}
.ap[data-status="pending"] {
  box-shadow:
    0 0 0 1px var(--warmline),
    0 4px 12px -2px rgb(0 0 0/0.06);
}
.ap .q {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  min-width: 0;
}
.ap .q span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.ap .d {
  color: var(--mut);
  font-size: 13px;
  margin: 0 0 0 28px;
  overflow-wrap: anywhere;
}
.ap .d.code {
  font-family: var(--mono);
  font-size: 12px;
}
.ap .res {
  font-size: 12.5px;
  color: var(--mut);
  margin: 0 0 0 28px;
}
.ap[data-status="allowed"],
.ap[data-status="denied"],
.ap[data-status="expired"] {
  padding: 8px 12px;
}
.ap[data-status="allowed"] .q,
.ap[data-status="denied"] .q,
.ap[data-status="expired"] .q {
  color: var(--mut);
  font-weight: 450;
  font-size: 13px;
}
.ap .acts {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 8px 0 0 28px;
}

/* The computer: a framed window. While it starts, a skeleton desktop with real stages; then it cross-fades to the live frame. */
/* the floating preview of a live computer (like T3 Code's mini player) */
.floatlayer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 40;
}
.floatwin {
  position: absolute;
  pointer-events: auto;
  border-radius: 12px;
  background: var(--screen);
  box-shadow:
    0 0 0 1px var(--edge),
    0 18px 40px -8px rgb(0 0 0/0.45),
    0 4px 10px rgb(0 0 0/0.18);
}
.floatwin .cc-screen {
  position: absolute;
  inset: 0;
  aspect-ratio: auto;
  border-radius: inherit;
  box-shadow: none;
}
.floatwin.max {
  left: 12px;
  right: 12px;
  top: 12px;
  bottom: 12px;
}
.floatwin.dragging,
.floatwin.dragging * {
  user-select: none;
  cursor: grabbing;
}
.floatwin.dragging iframe {
  pointer-events: none;
} /* the stream must not swallow the drag */
/* A small handle that is always there (the bot face); pointing at it opens the toolbar. The page never sees the pointer while
   it is over the stream (another site's frame), so a hover on the whole preview cannot be relied on. */
.fw-pill {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  align-items: center;
  gap: 1px;
  padding: 2px;
  border-radius: 9px;
  background: color-mix(in oklab, var(--panel) 90%, transparent);
  backdrop-filter: blur(14px);
  box-shadow:
    0 0 0 1px var(--line),
    0 4px 12px rgb(0 0 0/0.2);
  cursor: grab;
  touch-action: none;
}
.fw-pill > :not(.fw-handle) {
  display: none;
}
.fw-pill:hover > :not(.fw-handle),
.fw-pill:focus-within > :not(.fw-handle),
.floatwin.dragging .fw-pill > :not(.fw-handle),
.floatwin.max .fw-pill > :not(.fw-handle) {
  display: grid;
}
@media (hover: none) {
  .fw-pill > :not(.fw-handle) {
    display: grid;
  }
}
.fw-handle {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
}
.fw-pill .ibtn,
.fw-pill button {
  width: 26px;
  height: 26px;
}
.fw-grip {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 16px;
  height: 16px;
  cursor: nesw-resize;
  touch-action: none;
}
.fw-grip::after {
  content: "";
  position: absolute;
  left: 4px;
  bottom: 4px;
  width: 7px;
  height: 7px;
  border-left: 2px solid #ffffff80;
  border-bottom: 2px solid #ffffff80;
  border-radius: 0 0 0 3px;
  opacity: 0;
  transition: opacity 0.15s var(--ease);
}
.floatwin:hover .fw-grip::after,
.fw-grip:hover::after {
  opacity: 1;
}
@media (prefers-reduced-motion: no-preference) {
  .floatwin {
    animation: fadein 0.2s var(--ease) both;
  }
}
.ccline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--mut);
  min-height: 28px;
  max-width: 100%;
}
.ccline .m {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.ccline .m b {
  color: var(--fg);
  font-weight: 550;
}
.ccline .ccnote {
  color: var(--faint);
  white-space: nowrap;
}
@media (prefers-reduced-motion: no-preference) {
  .floatwin {
    animation: fadein 0.2s var(--ease) both;
  }
}
.cc {
  width: 100%;
  max-width: 520px;
  border-radius: 14px;
  background: var(--panel);
  box-shadow: var(--lift);
  padding: 4px;
  transition: max-width 0.3s var(--ease);
}
.cc.wide {
  max-width: 720px;
}
.cc-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 8px 8px;
  min-height: 44px;
}
.cc-bar .m {
  min-width: 0;
  flex: 1;
}
.cc-bar .m b {
  display: block;
  font-weight: 550;
  font-size: 13.5px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.cc-bar .m > span {
  display: block;
  font-size: 12.5px;
  color: var(--mut);
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.cc-bar .r {
  display: flex;
  gap: 2px;
  flex: none;
}
.cc-screen {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: 10px;
  overflow: hidden;
  background: var(--screen);
  box-shadow: inset 0 0 0 1px var(--edge);
}
.cc.wide .cc-screen {
  aspect-ratio: 16/10;
}
.cc-screen iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--screen);
}
.boot {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: #16181d;
  color: #c9ced6;
  transition:
    opacity 0.28s var(--ease),
    visibility 0.28s;
  overflow: hidden;
}
.boot.out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.boot .glow {
  position: absolute;
  inset: -30%;
  background:
    radial-gradient(40% 40% at 28% 30%, #3b4560aa, transparent 70%),
    radial-gradient(38% 38% at 74% 70%, #4d3b6a88, transparent 70%);
  filter: blur(24px);
}
.boot .bar {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 7%;
  background: #ffffff0d;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 3%;
}
.boot .bar i {
  display: block;
  height: 34%;
  border-radius: 99px;
  background: #ffffff1c;
}
.boot .dock {
  position: absolute;
  bottom: 5%;
  left: 50%;
  translate: -50% 0;
  display: flex;
  gap: 6px;
  padding: 5px 8px;
  border-radius: 12px;
  background: #ffffff12;
}
.boot .dock i {
  display: block;
  width: clamp(10px, 3.2cqw, 22px);
  aspect-ratio: 1;
  border-radius: 6px;
  background: #ffffff1f;
}
.boot .shimmer {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, #ffffff0a 50%, transparent 70%);
  translate: -100% 0;
}
.cc-screen {
  container-type: inline-size;
}
.stages {
  position: relative;
  display: grid;
  gap: 7px;
  font-size: 13px;
  min-width: 0;
  padding: 0 12px;
}
.stages li {
  display: flex;
  align-items: center;
  gap: 9px;
  list-style: none;
  color: #7e8590;
  transition: color 0.25s var(--ease);
}
.stages li[data-s="done"] {
  color: #aeb4bd;
}
.stages li[data-s="now"] {
  color: #f1f3f5;
}
.stages li .mk {
  width: 14px;
  height: 14px;
  flex: none;
  display: grid;
  place-items: center;
}
.stages li .mk svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.stages li[data-s="todo"] .mk:before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #59606b;
}
.stages li[data-s="now"] .mk:before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.5px solid #8b929d;
  border-top-color: transparent;
  box-sizing: border-box;
}
.stages {
  margin: 0;
  padding-inline: 12px;
}
.boot .elapsed {
  position: absolute;
  bottom: 13%;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 12px;
  color: #8b929d;
  font-variant-numeric: tabular-nums;
}
.boot .msg2 {
  position: relative;
  text-align: center;
  font-size: 13px;
  padding: 0 16px;
  display: grid;
  gap: 10px;
  justify-items: center;
}
.boot .btn {
  background: #ffffff14;
  color: #f1f3f5;
  box-shadow: none;
}
@media (hover: hover) {
  .boot .btn:hover {
    background: #ffffff24;
  }
}

.link {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 14px;
  padding: 8px;
  max-width: 480px;
  width: 100%;
  background: var(--panel);
  box-shadow: var(--lift);
}
.thumb {
  width: 76px;
  height: 48px;
  border-radius: 6px;
  position: relative;
  flex: none;
  overflow: hidden;
  background: var(--sub);
  box-shadow: inset 0 0 0 1px var(--edge);
}
.thumb iframe {
  position: absolute;
  left: 0;
  top: 0;
  width: 1280px;
  height: 800px;
  border: 0;
  transform: scale(0.0594);
  transform-origin: 0 0;
  pointer-events: none;
}
.link .u {
  font: 12.5px var(--mono);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
}
.link small {
  display: block;
  color: var(--mut);
  font-size: 12.5px;
  line-height: 1.4;
}
.link .m {
  min-width: 0;
  flex: 1;
}
.link .r {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.shot {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  object-fit: cover;
  background: var(--sub);
  outline: 1px solid var(--edge);
  outline-offset: -1px;
  border-radius: 8px;
}
.shotc {
  border-radius: 14px;
  background: var(--panel);
  box-shadow: var(--lift);
  padding: 4px;
  width: 100%;
  max-width: 480px;
}
.shotc .cap {
  padding: 6px 8px 4px;
  color: var(--mut);
  font-size: 12.5px;
  overflow-wrap: anywhere;
}
.forks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 8px;
  width: 100%;
  max-width: 640px;
}
.fk {
  border-radius: 14px;
  background: var(--panel);
  box-shadow: var(--lift);
  padding: 4px;
  display: flex;
  flex-direction: column;
  transition-property: box-shadow, opacity;
  transition-duration: 0.2s;
  transition-timing-function: var(--ease);
}
.fk.sel {
  box-shadow: 0 0 0 1.5px var(--mut);
}
.fk.gone {
  opacity: 0.5;
}
.fk .pv {
  aspect-ratio: 16/10;
  position: relative;
  background: var(--sub);
  overflow: hidden;
  border-radius: 10px;
  box-shadow: inset 0 0 0 1px var(--edge);
}
.fk .pv iframe {
  position: absolute;
  left: 0;
  top: 0;
  width: 1280px;
  height: 800px;
  border: 0;
  transform-origin: 0 0;
  pointer-events: none;
}
.fk .ft {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 6px 4px 2px 8px;
  font-size: 13px;
}
.fk .ft b {
  font-weight: 550;
}
.fk .ft .r {
  display: flex;
  gap: 4px;
  align-items: center;
}
.forknote {
  font-size: 12.5px;
  color: var(--mut);
}
.picked {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--mut);
  font-size: 12.5px;
  padding-right: 6px;
}
.picked svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Composer */
.comp {
  margin: 0 auto 14px;
  width: calc(100% - 40px);
  max-width: 720px;
  border-radius: 16px;
  padding: 8px 8px 8px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--panel);
  flex: none;
  box-shadow: var(--lift);
  transition: box-shadow 0.15s var(--ease);
}
.comp:focus-within {
  box-shadow:
    0 0 0 1px var(--faint),
    0 4px 12px -2px rgb(0 0 0/0.06);
}
.comp textarea {
  flex: none;
  border: 0;
  outline: 0;
  background: none;
  resize: none;
  font: inherit;
  color: var(--fg);
  padding: 6px 0;
  max-height: 140px;
  min-height: 24px;
  line-height: 1.45;
}
.comp textarea::placeholder {
  color: var(--faint);
}
.send {
  position: relative;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--btn);
  color: var(--btnfg);
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  flex: none;
  padding: 0;
  transition-property: opacity, scale, background-color;
  transition-duration: 0.15s, 0.12s, 0.15s;
  transition-timing-function: var(--ease);
}
.send svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.send:active {
  scale: 0.96;
}
.send::after {
  content: "";
  position: absolute;
  inset: -6px;
}
@media (hover: hover) {
  .send:hover {
    opacity: 0.86;
  }
}
.send[disabled] {
  opacity: 0.3;
  cursor: default;
  scale: 1;
}
.send.stop {
  background: var(--sub2);
  color: var(--fg);
}
.send.stop svg {
  fill: currentColor;
  stroke: none;
  width: 12px;
  height: 12px;
}
.comp.nokey {
  padding: 10px 10px 10px 14px;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  justify-content: space-between;
  color: var(--mut);
}
.comp.nokey span {
  min-width: 0;
}

/* First run */
.steps2 {
  border-radius: 14px;
  box-shadow: var(--lift);
  background: var(--panel);
  overflow: hidden;
}
.step {
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}
.step + .step {
  border-top: 1px solid var(--line);
}
.step .h {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 550;
  font-size: 14px;
}
.step .h .tag {
  margin-left: auto;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--mut);
}
.step small {
  color: var(--mut);
  font-size: 13px;
  display: block;
  margin-left: 24px;
  line-height: 1.45;
}
.step > :not(.h):not(small) {
  margin-left: 24px;
}
.num {
  width: 14px;
  flex: none;
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
}
.num svg {
  width: 14px;
  height: 14px;
  stroke: var(--fg);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  display: block;
}
.fld {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.in {
  flex: 1;
  min-width: 0;
  border: 0;
  border-radius: 8px;
  padding: 0 10px;
  height: 32px;
  font: inherit;
  font-size: 13px;
  background: var(--panel);
  color: var(--fg);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: box-shadow 0.15s var(--ease);
}
.in:focus {
  outline: 0;
  box-shadow: inset 0 0 0 1.5px var(--ring);
}
.err {
  color: var(--bad);
  font-size: 12.5px;
}
.okline {
  color: var(--mut);
  font-size: 12.5px;
}

/* Popover (waitlist), menu, dialog */
.pop {
  width: min(310px, calc(100vw - 24px));
  background: var(--panel);
  border-radius: 14px;
  box-shadow: var(--pop);
  padding: 8px;
  z-index: 30;
  font-size: 13px;
  display: grid;
  gap: 4px;
  margin: 0;
  color: var(--fg);
  border: 0;
}
.opt {
  display: flex;
  gap: 10px;
  padding: 8px;
  border-radius: 8px;
  align-items: flex-start;
}
.opt.on {
  background: var(--sub);
}
.opt b {
  display: block;
  font-size: 13.5px;
  font-weight: 550;
}
.opt small {
  color: var(--mut);
  font-size: 12.5px;
  line-height: 1.4;
  display: block;
}
.opt .mut2 {
  color: var(--faint);
  font-weight: 400;
}
.wl {
  display: flex;
  gap: 6px;
  margin: 4px 8px 0;
  flex-wrap: wrap;
}
.wl .in {
  min-width: 120px;
}
.fine {
  color: var(--faint);
  font-size: 12px;
  margin: 4px 8px 2px;
  line-height: 1.4;
}
.menu {
  background: var(--panel);
  border-radius: 12px;
  box-shadow: var(--pop);
  padding: 4px;
  min-width: 190px;
  z-index: 30;
  margin: 0;
  border: 0;
}
.menu [role="menuitem"] {
  display: flex;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  gap: 8px;
  align-items: center;
}
.menu [role="menuitem"][data-highlighted],
.menu [role="menuitem"]:hover {
  background: var(--sub);
}
.menu [role="menuitem"][data-destructive] {
  color: var(--bad);
}
.menu [role="menuitem"][aria-disabled="true"],
.menu [role="menuitem"][data-disabled] {
  opacity: 0.45;
}

/* json-render */
.jr-card {
  border-radius: 14px;
  padding: 12px 14px;
  max-width: 640px;
  width: 100%;
  display: grid;
  gap: 8px;
  background: var(--panel);
  box-shadow: var(--lift);
}
.jr-card h4 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}
.jr-text {
  margin: 0;
}
.mut {
  color: var(--mut);
}
.jr-scroll {
  overflow-x: auto;
}
.jr-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.jr-table td,
.jr-table th {
  text-align: left;
  padding: 6px 12px 6px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.jr-table tr:last-child td {
  border-bottom: 0;
}
.jr-table th {
  color: var(--mut);
  font-weight: 500;
  font-size: 12.5px;
}
.jr-meter .track {
  display: block;
  height: 6px;
  background: var(--sub2);
  border-radius: 3px;
  overflow: hidden;
}
.jr-meter .ind {
  display: block;
  height: 100%;
  background: var(--fg);
  width: var(--meter-percentage, calc(var(--value, 0)*1%));
}

@media (max-width: 760px) {
  .app {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
  }
  .side {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 8px 12px 6px;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
  }
  .top {
    padding: 0;
    flex: 1 1 100%;
    order: 0;
  }
  .bots {
    flex-direction: row;
    gap: 4px;
    order: 1;
    flex: 1 1 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .bot {
    width: auto;
    padding: 4px 10px 4px 6px;
    flex: none;
    gap: 8px;
    min-height: 44px;
  }
  .bot small {
    display: none;
  }
  .bot .t b {
    font-size: 13px;
  }
  .bot[data-needs="true"] .mark {
    display: block;
  }
  .bot .face {
    margin: 0;
  }
  .grow {
    display: none;
  }
  .foot {
    order: 2;
    flex: 1 1 100%;
    border-top: 0;
    padding: 0 2px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0 12px;
  }
  .foot .need {
    flex: 1 1 100%;
    min-height: 28px;
  }
  .foot .tot {
    flex: 1;
    min-width: 0;
    justify-content: flex-start;
    gap: 12px;
  }
  .foot .emu {
    display: none;
  }
  .foot .row .btn {
    height: 44px;
  }
  .hd {
    padding: 0 12px;
  }
  .col {
    padding: 14px 12px 8px;
  }
  .link {
    flex-wrap: wrap;
  }
  .link .m {
    flex: 1 1 calc(100% - 96px);
  }
  .link .u {
    white-space: normal;
    overflow-wrap: anywhere;
  }
  .link .r {
    justify-content: flex-start;
    width: 100%;
  }
  .btn,
  .btn.sm {
    height: 44px;
    padding: 0 14px;
    font-size: 14px;
  }
  .ibtn {
    width: 44px;
    height: 44px;
  }
  .ibtn::after {
    inset: 0;
  }
  .where {
    height: 44px;
  }
  .send {
    width: 44px;
    height: 44px;
  }
  .comp {
    width: calc(100% - 24px);
    margin-bottom: 10px;
  }
  .ap .d,
  .ap .res,
  .ap .acts {
    margin-left: 0;
  }
  .ap .acts .btn {
    flex: 1 1 auto;
  }
  .ob {
    padding: 20px 16px 28px;
  }
  .cc-bar {
    padding-right: 2px;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .dot[data-state="thinking"],
  .dot[data-state="working"] {
    animation: pulse 1.6s ease-in-out infinite;
  }
  .steps li[data-state="run"] .mk,
  .stages li[data-s="now"] .mk:before {
    animation: spin 0.9s linear infinite;
  }
  .boot .shimmer {
    animation: sweep 2.4s var(--ease-io) infinite;
  }
  .cc,
  .fk,
  .ap {
    animation: rise 0.22s var(--ease) both;
  }
  .smh {
    transition: height 0.24s var(--ease);
  }
  .thk {
    animation: fadein 0.24s var(--ease) both;
  }
  /* New step lines and folded thoughts open from zero height instead of popping in (where the browser can animate to auto). */
  .thkl {
    animation: glint 1.8s linear infinite;
  }
}
@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}
@keyframes spin {
  to {
    rotate: 360deg;
  }
}
@keyframes sweep {
  to {
    translate: 100% 0;
  }
}
@keyframes fadein {
  from {
    opacity: 0;
  }
}
@keyframes glint {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: 0 0;
  }
}
@keyframes rise {
  from {
    opacity: 0;
    translate: 0 4px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition-duration: 0.01ms !important;
  }
  .face .eyes {
    transition: none;
  }
}
.jr-card .btn {
  justify-self: start;
}
@media (max-width: 760px) {
  .hide-m {
    display: none;
  }
}

/* Composer: model chip */
.compbar {
  display: flex;
  align-items: center;
  gap: 6px;
}
.mchip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 26px;
  max-width: min(240px, 58vw);
  padding: 0 6px 0 8px;
  margin-left: -8px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--mut);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition-property: background-color, color, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.mchip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mchip:active {
  scale: 0.96;
}
.mchip svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
@media (hover: hover) {
  .mchip:hover {
    background: var(--sub);
    color: var(--fg);
  }
}
.mchip[aria-expanded="true"] {
  background: var(--sub);
  color: var(--fg);
}
.mpop {
  width: min(280px, calc(100vw - 24px));
  max-height: min(420px, 60dvh);
  overflow-y: auto;
  gap: 0;
  padding: 6px;
}
.mgl {
  font-size: 11.5px;
  font-weight: 550;
  color: var(--faint);
  padding: 8px 8px 3px;
  letter-spacing: 0.01em;
}
.mi {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  border: 0;
  background: none;
  text-align: left;
  padding: 7px 8px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
  color: var(--fg);
}
.mi span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mi svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.mi[aria-pressed="true"] {
  background: var(--sub);
}
@media (hover: hover) {
  .mi:hover {
    background: var(--sub);
  }
}
.mi.manage {
  color: var(--mut);
  margin-top: 4px;
  border-top: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
  padding-top: 9px;
}

/* Boat button: white with the boat logo in both themes (literal colours on purpose) */
.boatin {
  display: grid;
  gap: 6px;
  justify-items: start;
}
.boatrow {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.boatbtn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: #16181d;
  border-radius: 9px;
  padding: 0 14px;
  height: 36px;
  font-size: 13.5px;
  font-weight: 550;
  border: 1px solid rgb(22 24 29/0.18);
  cursor: pointer;
  box-shadow: 0 1px 2px rgb(0 0 0/0.06);
  transition-property: background-color, scale, opacity, box-shadow;
  transition-duration: 0.15s, 0.12s, 0.15s, 0.15s;
  transition-timing-function: var(--ease);
}
.boatbtn:active {
  scale: 0.96;
}
@media (hover: hover) {
  .boatbtn:hover {
    background: #f4f5f7;
    box-shadow: 0 1px 3px rgb(0 0 0/0.1);
  }
}
.boatbtn[disabled] {
  opacity: 0.7;
  cursor: not-allowed;
  scale: 1;
  box-shadow: none;
}
.boatmark {
  display: block;
  width: 16px;
  height: auto;
  flex: none;
}
.boatname {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* Settings page */
.settings .hd {
  gap: 12px;
}
.backbtn {
  margin-left: -8px;
  gap: 5px;
}
.setw {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
}
.setnav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 10px;
  border-right: 1px solid var(--line);
  overflow-y: auto;
}
.setnav button {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: none;
  text-align: left;
  height: 34px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--mut);
  cursor: pointer;
  transition-property: background-color, color, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.setnav button svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.setnav button:active {
  scale: 0.98;
}
@media (hover: hover) {
  .setnav button:hover {
    background: var(--sub);
    color: var(--fg);
  }
}
.setnav button[aria-current="page"] {
  background: var(--sub);
  color: var(--fg);
}
.setbody {
  overflow-y: auto;
  min-width: 0;
  padding: 24px 24px 48px;
}
.setcol {
  max-width: 720px;
  margin: 0 auto;
  display: grid;
  gap: 28px;
  animation: rise 0.2s var(--ease) both;
}
.scard-w h2 {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--fg);
  letter-spacing: 0.01em;
  text-transform: none;
}
.sintro {
  margin: -2px 0 10px;
  font-size: 12.5px;
  color: var(--mut);
  line-height: 1.45;
}
.scard {
  border-radius: 14px;
  background: var(--bg);
  box-shadow: inset 0 0 0 1px var(--line);
  overflow: hidden;
}
.scard > * + *,
.scard .prov + .prov {
  border-top: 1px solid var(--line);
}
.srow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  min-width: 0;
}
.srow .st {
  min-width: 0;
  flex: 1;
}
.stt {
  font-size: 13.5px;
  font-weight: 550;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.std {
  font-size: 12.5px;
  color: var(--mut);
  line-height: 1.45;
  margin-top: 1px;
}
.sc {
  flex: none;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
  min-width: 0;
  max-width: 60%;
}
.srow.stack {
  align-items: flex-start;
  flex-direction: column;
  gap: 10px;
}
.srow.stack .sc {
  max-width: 100%;
  justify-content: flex-start;
}
.pstat {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--mut);
  margin-top: 6px;
}
.pstat.tight {
  margin: 0;
  font-size: 13.5px;
  color: var(--fg);
  font-weight: 550;
}
.sdot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--faint);
  opacity: 0.55;
  flex: none;
  display: inline-block;
}
.sdot[data-on="true"] {
  background: #2f9e5b;
  opacity: 1;
}
.usedtag {
  font-size: 11px;
  font-weight: 550;
  color: var(--mut);
  padding: 1px 7px;
  border-radius: 99px;
  box-shadow: inset 0 0 0 1px var(--line);
  line-height: 1.5;
  letter-spacing: 0.01em;
}
.pbody {
  padding: 0 16px 14px;
}
.prov[data-connected="false"] .stt {
  color: var(--fg);
}
.connect,
.cform {
  display: grid;
  gap: 8px;
  justify-items: start;
  width: 100%;
}
.cform .fld {
  width: 100%;
}
.fld .in {
  min-width: 160px;
}
.geta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12.5px;
  color: var(--mut);
  text-underline-offset: 2px;
}
.geta svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.linkbtn {
  border: 0;
  background: none;
  padding: 0;
  font-size: 12.5px;
  color: var(--mut);
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: var(--faint);
  text-underline-offset: 3px;
}
@media (hover: hover) {
  .linkbtn:hover {
    color: var(--fg);
  }
}
.confirm {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
  font-size: 12.5px;
}
.btn.danger {
  background: var(--bad);
  color: #fff;
  box-shadow: none;
}
.btn.quiet.bad {
  color: var(--mut);
}
/* select */
.sel {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: 30px;
  padding: 0 8px 0 11px;
  border: 0;
  border-radius: 8px;
  background: var(--panel);
  color: var(--fg);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px var(--line);
  max-width: 100%;
  transition-property: background-color, box-shadow, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.sel.wide {
  width: 240px;
}
.sel > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sel svg {
  width: 12px;
  height: 12px;
  stroke: var(--mut);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.sel:active {
  scale: 0.98;
}
@media (hover: hover) {
  .sel:hover {
    background: var(--sub);
  }
}
.sel[aria-expanded="true"] {
  box-shadow: inset 0 0 0 1.5px var(--ring);
}
.selc {
  min-width: var(--anchor-width, 170px);
  max-height: min(340px, var(--available-height, 340px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.selc.big {
  width: min(320px, calc(100vw - 24px));
}
.selc [role="listbox"] {
  overflow-y: auto;
  min-height: 0;
  flex: 1;
}
.selc [role="option"] {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
}
.selc [role="option"] svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.selc [role="option"]:focus-visible {
  outline: 0;
}
.selc [role="option"][data-highlighted],
.selc [role="option"]:hover {
  background: var(--sub);
}
.selc [role="option"][data-selected] {
  font-weight: 550;
}
.selgl {
  font-size: 11.5px;
  font-weight: 550;
  color: var(--faint);
  padding: 6px 10px 3px;
}
.selsearch {
  margin: 2px 2px 6px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  padding: 0 10px;
  font: inherit;
  font-size: 13px;
  background: var(--bg);
  color: var(--fg);
  box-shadow: inset 0 0 0 1px var(--line);
  outline: 0;
}
.selsearch:focus {
  box-shadow: inset 0 0 0 1.5px var(--ring);
}
.selempty {
  padding: 8px 10px;
  color: var(--mut);
  font-size: 13px;
}
.selempty:empty,
.selempty[hidden] {
  display: none;
  padding: 0;
}
.selsearch:focus-visible {
  outline: 0;
}
/* switch */
.swl {
  display: inline-flex;
}
.sw {
  position: relative;
  width: 36px;
  height: 20px;
  border-radius: 99px;
  border: 0;
  padding: 0;
  background: var(--sub2);
  cursor: pointer;
  transition: background-color 0.15s var(--ease);
  box-shadow: inset 0 0 0 1px var(--line);
}
.sw[data-checked],
.sw[aria-checked="true"] {
  background: var(--btn);
}
.swt {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--panel);
  box-shadow: 0 1px 2px rgb(0 0 0/0.25);
  transition: translate 0.18s var(--ease);
}
.sw[data-checked] .swt,
.sw[aria-checked="true"] .swt {
  translate: 16px 0;
}
.sw::after {
  content: "";
  position: absolute;
  inset: -8px -4px;
}

/* First run */
.ob {
  margin: 0 auto;
  width: min(720px, 100%);
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: max(24px, 7vh) 20px 36px;
}
.hero {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 6px;
}
.faces {
  display: flex;
  gap: 14px;
  margin-bottom: 14px;
}
.hero h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 620;
  letter-spacing: -0.028em;
  line-height: 1.2;
}
.hero p {
  margin: 0;
  color: var(--mut);
  max-width: 440px;
}
.ob .steps2 {
  width: min(560px, 100%);
  margin: 0 auto;
  align-self: center;
}
.tiles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.tile {
  display: grid;
  gap: 1px;
  text-align: left;
  border: 0;
  background: var(--panel);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px var(--line);
  min-width: 0;
  transition-property: background-color, box-shadow, scale;
  transition-duration: 0.15s, 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.tile:active {
  scale: 0.98;
}
@media (hover: hover) {
  .tile:hover {
    background: var(--sub);
  }
}
.tile[aria-pressed="true"] {
  box-shadow: inset 0 0 0 1.5px var(--fg);
}
.tile .tn1 {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 550;
}
.tile small {
  margin: 0 !important;
  font-size: 12px !important;
  color: var(--mut);
  line-height: 1.35 !important;
  display: block;
}
.tile.more {
  background: transparent;
}
.tile .tick {
  margin-left: auto;
  display: grid;
  place-items: center;
}
.tile .tick svg {
  width: 14px;
  height: 14px;
  stroke: var(--fg);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.step > .tilepanel {
  padding: 12px;
  border-radius: 12px;
  background: var(--bg);
  box-shadow: inset 0 0 0 1px var(--line);
  margin-left: 24px;
}
.step .boatin {
  margin-left: 24px;
}
.startbtn {
  align-self: center;
  height: 36px;
  padding: 0 18px;
}
.does {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}
.dcard {
  display: grid;
  align-content: start;
  gap: 4px;
  justify-items: start;
  padding: 14px;
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px var(--line);
  background: var(--bg);
}
.dcard .face {
  margin-bottom: 6px;
}
.dcard b {
  font-weight: 600;
  font-size: 13.5px;
}
.dcard p {
  margin: 0;
  font-size: 12.5px;
  color: var(--mut);
  line-height: 1.45;
}
.trust {
  margin: 0;
  text-align: center;
  font-size: 12px;
  color: var(--faint);
}

/* Empty chat */
.empty {
  margin: auto;
  width: min(560px, 100%);
  text-align: center;
  color: var(--mut);
  padding: 28px 20px;
  display: grid;
  gap: 6px;
  justify-items: center;
}
.empty .face {
  margin-bottom: 8px;
}
.empty b {
  color: var(--fg);
  font-weight: 600;
  font-size: 18px;
  letter-spacing: -0.015em;
}
.empty p {
  margin: 0;
}
.caps {
  list-style: none;
  margin: 10px 0 2px;
  padding: 0;
  display: grid;
  gap: 6px;
  text-align: left;
}
.caps li {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--mut);
}
.caps li svg {
  width: 15px;
  height: 15px;
  stroke: var(--fg);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
  opacity: 0.7;
}
.sugg {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 16px;
  width: 100%;
}
.sug {
  display: grid;
  gap: 2px;
  align-content: start;
  text-align: left;
  border: 0;
  background: var(--bg);
  border-radius: 12px;
  padding: 11px 13px;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--fg);
  transition-property: background-color, scale;
  transition-duration: 0.15s, 0.12s;
  transition-timing-function: var(--ease);
}
.sug b {
  font-size: 13px;
  font-weight: 550;
  color: var(--fg);
}
.sug small {
  font-size: 12.5px;
  color: var(--mut);
  line-height: 1.4;
}
.sug:active {
  scale: 0.98;
}
@media (hover: hover) {
  .sug:hover {
    background: var(--sub);
  }
}
.setbtn {
  margin-left: -8px;
  gap: 6px;
}

@media (max-width: 760px) {
  .setw {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
  }
  .setnav {
    flex-direction: row;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 8px 12px;
    gap: 6px;
    scrollbar-width: none;
  }
  .setnav button {
    flex: none;
    height: 36px;
    border-radius: 99px;
    padding: 0 14px;
    box-shadow: inset 0 0 0 1px var(--line);
  }
  .setnav button[aria-current="page"] {
    box-shadow: none;
    background: var(--btn);
    color: var(--btnfg);
  }
  .setbody {
    padding: 16px 12px 40px;
  }
  .srow {
    flex-wrap: wrap;
    gap: 10px;
    padding: 12px 14px;
  }
  .sc {
    max-width: 100%;
    flex: 1 1 100%;
    justify-content: flex-start;
  }
  .sc .sel,
  .sc .sel.wide {
    width: 100% !important;
  }
  .sc .sw {
    margin-left: 0;
  }
  .sc .confirm {
    justify-content: flex-start;
  }
  .pbody {
    padding: 0 14px 14px;
  }
  .hero h1 {
    font-size: 24px;
  }
  .faces {
    gap: 10px;
  }
  .tiles {
    grid-template-columns: 1fr 1fr;
  }
  .does {
    grid-template-columns: 1fr;
  }
  .dcard {
    grid-template-columns: auto 1fr;
    column-gap: 12px;
    align-items: center;
  }
  .dcard .face {
    grid-row: span 2;
    margin: 0;
  }
  .sugg {
    grid-template-columns: 1fr;
  }
  .caps {
    justify-self: center;
  }
  .mchip {
    height: 36px;
  }
  .sel {
    height: 40px;
  }
  .ob {
    padding: 20px 16px 28px;
  }
  .step > :not(.h):not(small) {
    margin-left: 0;
  }
  .step small {
    margin-left: 0;
  }
  .fld .in {
    min-width: 0;
    flex: 1 1 100%;
  }
  .mi {
    min-height: 40px;
  }
  .compbar .send {
    width: 36px;
    height: 36px;
  }
}
@media (max-width: 760px) {
  .sc .btn.quiet {
    margin-left: -10px;
  }
}
.selsearch {
  flex: none;
}
/* the search match inside a model name: bold, not the browser's yellow highlighter */
.selc mark {
  background: none;
  color: var(--fg);
  font-weight: 650;
}

/* your own bots, dialogs, memory, skills */
.bot.newbot {
  color: var(--mut);
  margin-top: 2px;
}
.bot.newbot .plus {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  box-shadow: inset 0 0 0 1px var(--line);
  flex: none;
}
.bot.newbot .plus svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
}
.bot.newbot b {
  font-weight: 500;
  color: var(--mut);
}
@media (hover: hover) {
  .bot.newbot:hover b {
    color: var(--fg);
  }
}
.modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 16px;
  background: oklch(0 0 0/0.35);
}
.mbox {
  width: min(460px, 100%);
  max-height: calc(100dvh - 32px);
  overflow: auto;
  background: var(--panel);
  border-radius: 16px;
  box-shadow: var(--pop);
  padding: 18px;
  display: grid;
  gap: 12px;
  align-content: start;
}
.mbox h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.mform {
  display: grid;
  gap: 14px;
}
.mlab {
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 550;
}
.in.mta,
.in.memta {
  height: auto;
  padding: 8px 10px;
  resize: vertical;
  line-height: 1.5;
  font-weight: 400;
}
.in.mta {
  min-height: 96px;
}
.in.memta {
  min-height: 96px;
  width: 100%;
  font-size: 13px;
}
.mtools {
  border: 0;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  min-width: 0;
}
.mtools legend {
  font-size: 13px;
  font-weight: 550;
  padding: 0;
  margin-bottom: 8px;
}
.chk,
.fnd {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  cursor: pointer;
  font-size: 13px;
}
.chk input,
.fnd input {
  margin: 2px 0 0;
  width: 15px;
  height: 15px;
  accent-color: var(--btn);
  flex: none;
}
.chk span,
.fnd span {
  display: grid;
  gap: 1px;
  min-width: 0;
}
.chk b,
.fnd b {
  font-weight: 550;
  overflow-wrap: anywhere;
}
.chk small,
.fnd small {
  color: var(--mut);
  font-size: 12.5px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.mact {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}
.mp {
  margin: 0;
  color: var(--mut);
  font-size: 13px;
  line-height: 1.5;
}
.memed {
  width: 100%;
  display: grid;
  gap: 8px;
}
.memfoot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.skform {
  display: flex;
  gap: 6px;
  width: 100%;
}
.found {
  display: grid;
  gap: 12px;
  width: 100%;
  padding-top: 4px;
}
.fnd[data-off="true"] {
  opacity: 0.55;
  cursor: default;
}
.fndact {
  display: flex;
  gap: 8px;
}
.skfrom {
  display: block;
  color: var(--faint);
  font-size: 12px;
  overflow-wrap: anywhere;
  margin-top: 2px;
}
.empty p.job {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
}
@media (max-width: 760px) {
  .skform {
    flex-direction: column;
  }
  .mact .btn {
    flex: 1;
  }
  .bot.newbot {
    padding-right: 12px;
  }
  .modal {
    align-items: end;
    padding: 8px;
  }
}
.fnd small {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 760px) {
  .app {
    grid-template-columns: minmax(0, 1fr);
  } /* five or more bots must scroll inside their row, not widen the page */
  .side {
    min-width: 0;
  }
}
.skd {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
}
@media (max-width: 760px) {
  .skform .in {
    flex: none;
    height: 44px;
  }
}
