/* Landing page only. Tokens (both themes) live in styles.css.
   Yellow = fills (highlighter, buttons, robot). Cobalt --ink = text accents. */

body { font-family: var(--sans); }

/* nav: theme toggle */
.theme-btn {
  display: grid; place-items: center; width: 36px; height: 36px; margin-left: 4px;
  border-radius: 9px; border: 1px solid var(--line); background: var(--panel); color: var(--text); cursor: pointer;
}
.theme-btn:hover { border-color: var(--text); }
.theme-btn:focus-visible, .h-cmd button:focus-visible, .btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.theme-btn .i-sun { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .theme-btn .i-sun { display: block; } :root:not([data-theme="light"]) .theme-btn .i-moon { display: none; } }
:root[data-theme="dark"] .theme-btn .i-sun { display: block; }
:root[data-theme="dark"] .theme-btn .i-moon { display: none; }
.logo { font-family: var(--mono); font-weight: 600; font-size: 15px; }
.nav .links a { font-size: 14px; }

/* hero */
.h-hero {
  display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.3fr); gap: 24px; align-items: center;
  padding-top: 72px; padding-bottom: 80px;
}
.h-copy { min-width: 0; display: grid; gap: 24px; justify-items: start; }
.h-copy h1 {
  margin: 0; font-family: var(--display); font-weight: 750; font-variation-settings: "opsz" 96;
  font-size: clamp(44px, 6.2vw, 82px); line-height: .95; letter-spacing: -0.045em;
}
.h-rest { display: block; margin-top: .06em; white-space: nowrap; }
/* the agent name sits on a yellow highlighter strip that wipes across on each change */
.rot {
  display: inline-block; padding: 0 .14em .04em; margin-left: -.06em; border-radius: .1em;
  background: var(--accent); color: var(--on-accent);
  clip-path: inset(0 0 0 0); transition: clip-path .32s cubic-bezier(.65,0,.35,1);
}
.rot.out { clip-path: inset(0 0 0 100%); }
.rot.in { clip-path: inset(0 100% 0 0); transition: none; }
.h-lead { margin: 0; font-size: 20px; line-height: 1.45; color: var(--muted); max-width: 32ch; }

.h-cmd {
  display: flex; align-items: center; gap: 12px; max-width: 100%;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 10px 10px 18px; font-family: var(--mono); font-size: 15px;
  box-shadow: 0 1px 0 var(--line), 0 12px 30px -18px rgba(0,0,0,.35);
}
.h-cmd .p { color: var(--muted); }
/* fixed width = "uvx bot-use add chatgpt" (the longest agent) + caret, so the Copy button never moves */
.h-cmd code { font-family: var(--mono); font-size: 15px; color: var(--text); white-space: nowrap; overflow: hidden; flex: none; width: 24.5ch; max-width: calc(100vw - 170px); }
#cmd-agent { color: var(--ink); font-weight: 600; }
.h-cmd button {
  margin-left: 10px; font: 500 13px var(--sans); color: var(--on-accent); background: var(--accent);
  border: 0; border-radius: 8px; padding: 8px 14px; cursor: pointer;
}
.h-cmd button:hover { filter: brightness(1.05); }
.caret { display: inline-block; width: .55em; height: 1.1em; margin-left: 2px; vertical-align: -0.2em; background: var(--ink); animation: h-blink 1s steps(1) infinite; }
@keyframes h-blink { 50% { opacity: 0; } }
.h-meta { font-family: var(--mono); font-size: 11px; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.btn { font-family: var(--sans); border-radius: 10px; padding: 12px 20px; }
.btn:not(.primary) { background: var(--panel); }

/* hero diagram: agent -> interface -> bridge -> robot. Wires are an SVG drawn by script under the boxes.
   On wide screens it runs past the page column on the right, and its panel fades in from behind the headline. */
main { overflow-x: clip; }
.h-copy { position: relative; z-index: 2; }
.h-flow {
  position: relative; z-index: 1; isolation: isolate; margin: 0 -130px 0 -40px; min-width: 0;
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .58fr) minmax(0, .78fr) minmax(0, 2.5fr); gap: 56px;
  padding: 34px 34px 38px 30px;
}
.h-flow::before {
  content: ""; position: absolute; inset: 0 0 0 -300px; z-index: -1; border-radius: 26px; border: 1px solid var(--line);
  background:
    radial-gradient(ellipse 34% 50% at 70% 55%, var(--stage-glow), transparent 70%),
    linear-gradient(var(--panel), var(--bg-2));
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 340px); mask-image: linear-gradient(to right, transparent 0, #000 340px);
}
.fl-wires { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.fl-wire { fill: none; stroke: var(--grid-a); stroke-width: 1.5; }
.fl-pulse { fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: 2 16; animation: fl-run 1.4s linear infinite; opacity: .75; }
.fl-hub { fill: var(--panel); stroke: var(--ink); stroke-width: 1.8; }
@keyframes fl-run { to { stroke-dashoffset: -18; } }

.fl-col { position: relative; z-index: 1; display: grid; grid-template-rows: auto 1fr; gap: 18px; min-width: 0; }
.fl-k { font: 11.5px var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; text-align: center; }
.fl-items { display: grid; gap: 14px; align-content: center; min-width: 0; }
.fl-box {
  min-width: 0; border-radius: 14px; border: 1px solid var(--line); background: var(--panel); color: var(--text);
  box-shadow: 0 10px 24px -18px rgba(0,0,0,.5);
}
.fl-agent { display: flex; align-items: center; gap: 10px; padding: 12px 13px; font: 500 15px var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fl-agent svg { flex: none; width: 24px; height: 24px; border-radius: 6px; }
.fl-if { display: grid; justify-items: center; gap: 2px; padding: 10px 6px; text-align: center; }
.fl-if svg { width: 19px; height: 19px; margin-bottom: 4px; color: var(--ink); }
.fl-pair { display: flex; gap: 6px; }
.fl-if b { font: 600 14px var(--mono); }
.fl-bridge {
  display: grid; justify-items: center; gap: 5px; padding: 20px 8px; text-align: center;
  background: var(--accent); color: var(--on-accent); border-color: transparent;
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 22%, transparent), 0 16px 34px -16px rgba(0,0,0,.5);
}
.fl-bridge b { white-space: nowrap; font-family: var(--display); font-weight: 750; font-size: clamp(16px, 1.5vw, 21px); letter-spacing: -0.03em; line-height: 1; }
.fl-bridge span { font: 500 12px/1.3 var(--sans); }
.fl-vid { aspect-ratio: 16 / 10; border-radius: 12px; box-shadow: 0 10px 24px -18px rgba(0,0,0,.5); }
.fl-vid .ph { gap: 7px; font-size: 10px; }
.fl-credit { position: absolute; right: 34px; bottom: 12px; z-index: 1; font: 10px var(--mono); color: var(--muted); text-decoration: none; }
.fl-credit:hover { color: var(--text); text-decoration: underline; }
.fl-vid .play { width: 46px; height: 46px; }
.fl-vid .play::after { left: 18px; top: 14px; border-left-width: 14px; border-top-width: 9px; border-bottom-width: 9px; }

/* section titles */
section { border-top: 1px solid var(--line); }
section h2 { font-family: var(--display); font-weight: 700; font-variation-settings: "opsz" 72; font-size: clamp(30px, 3.6vw, 42px); letter-spacing: -0.035em; margin: 0 0 28px; }

/* media placeholders (become <video> when the file exists) */
.media {
  position: relative; aspect-ratio: 16 / 10; max-width: 100%; border-radius: 14px; overflow: hidden;
  background:
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 28px 28px,
    var(--bg-2);
  border: 1px solid var(--line);
}
.media-xl { aspect-ratio: 16 / 9; border-radius: 20px; }
.media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.ph { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--muted); font: 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.play { width: 56px; height: 56px; border-radius: 50%; background: var(--accent); position: relative; box-shadow: 0 10px 30px -10px rgba(0,0,0,.4); }
.play::after { content: ""; position: absolute; left: 22px; top: 17px; border-left: 16px solid var(--on-accent); border-top: 11px solid transparent; border-bottom: 11px solid transparent; }
.media-xl .play { width: 84px; height: 84px; }
.media-xl .play::after { left: 33px; top: 26px; border-left-width: 24px; border-top-width: 16px; border-bottom-width: 16px; }

/* what it can do */
.gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.gallery figure { margin: 0; display: grid; gap: 12px; min-width: 0; }
.gallery figure .media { transition: transform .25s, box-shadow .25s; }
.gallery figure:hover .media { transform: translateY(-3px); box-shadow: 0 16px 34px -20px rgba(0,0,0,.45); }
.gallery figcaption { display: grid; gap: 3px; }
.gallery figcaption b { font-family: var(--display); font-weight: 650; font-size: 18px; letter-spacing: -0.01em; }
.gallery figcaption code { font-family: var(--mono); color: var(--muted); font-size: 11.5px; }

/* use cases */
.uc { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.uc article { background: var(--panel); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; display: grid; min-width: 0; }
.uc article .media { border: 0; border-radius: 0; border-bottom: 1px solid var(--line); }
.uc-body { padding: 20px 22px 24px; display: grid; gap: 8px; justify-items: start; }
.uc-body h3 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 26px; letter-spacing: -0.03em; }
.uc-body p { margin: 0; color: var(--muted); max-width: 46ch; }
.uc-k { font: 11px var(--mono); color: var(--ink); }
.tag { margin-top: 4px; font: 10.5px var(--mono); color: var(--on-accent); background: var(--accent); border-radius: 99px; padding: 3px 10px; }

/* app frame */
.app-frame { background: var(--bg-2); }
.app-bar { position: absolute; inset: 0 0 auto; height: 36px; display: flex; gap: 7px; align-items: center; padding: 0 16px; border-bottom: 1px solid var(--line); background: var(--panel); z-index: 1; }
.app-bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--line); display: block; }

/* no robot? sim / anywhere / rent */
.aw { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.aw-card {
  text-align: left; display: grid; gap: 8px; justify-items: start; align-content: start; min-width: 0;
  padding: 20px 22px 22px; border-radius: 18px; border: 1px solid var(--line); background: var(--panel);
  color: var(--text); font: inherit; cursor: pointer; position: relative; transition: border-color .2s, transform .2s;
}
.aw-card:hover { transform: translateY(-2px); }
.aw-card.on { border-color: var(--text); box-shadow: inset 0 -4px 0 var(--accent); }
.aw-card:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.aw-card h3 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 22px; letter-spacing: -0.025em; }
.aw-card p { margin: 0; color: var(--muted); font-size: 15px; }
.aw-k { font: 11px var(--mono); color: var(--ink); }
.aw-tag { margin-top: 4px; font: 10.5px var(--mono); border-radius: 99px; padding: 3px 10px; color: var(--on-accent); background: var(--accent); }
.aw-tag.live { background: transparent; color: var(--ok); border: 1px solid currentColor; }
.aw-code {
  margin-top: 16px; padding: 18px 22px; border-radius: 16px; border: 1px solid var(--line); background: var(--code);
  font: 13.5px/1.9 var(--mono); overflow-x: auto; white-space: nowrap;
}
.aw-code .dim { color: var(--muted); }
.aw-code .str { color: var(--ok); }
.aw-code b { font-weight: 600; color: var(--on-accent); background: var(--accent); padding: 1px 5px; border-radius: 4px; }
.aw-cmd { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }

/* pricing */
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; max-width: 860px; }
.plan { display: grid; gap: 14px; align-content: start; justify-items: start; min-width: 0;
        padding: 26px 26px 28px; border-radius: 20px; border: 1px solid var(--line); background: var(--panel); }
.plan.pro { border-color: var(--text); box-shadow: inset 0 -4px 0 var(--accent); }
.plan-k { font: 11px var(--mono); color: var(--ink); text-transform: uppercase; letter-spacing: .06em; }
.plan-price { font-family: var(--display); font-weight: 750; font-size: 48px; letter-spacing: -0.04em; line-height: 1; }
.plan-price small { font: 500 15px var(--sans); color: var(--muted); letter-spacing: 0; margin-left: 4px; }
.plan ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.plan li { padding-left: 22px; position: relative; }
.plan li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 9px; height: 5px;
                   border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: rotate(-45deg); }
.plan button.btn { font-family: var(--sans); cursor: pointer; }
.plan-note { font-size: 13px; color: var(--muted); }
.plan-shop { margin: 20px 0 0; color: var(--muted); }

/* closing */
.h-end .wrap { display: grid; gap: 22px; justify-items: start; }
.h-end h2 { margin: 0; font-size: clamp(34px, 5vw, 60px); }
.h-cmd-sm { padding: 12px 18px; }

/* not enough room to run past the page column */
@media (max-width: 1400px) { .h-flow { margin-right: -20px; } }
@media (max-width: 1180px) { .h-flow { margin-right: 0; } }
/* hero still two columns but narrow: tighten the diagram */
@media (min-width: 901px) and (max-width: 1140px) {
  .h-hero { grid-template-columns: minmax(0, .85fr) minmax(0, 1.25fr); }
  .h-flow { gap: 30px; padding: 24px 16px 26px; }
  .h-flow::before { left: -160px; -webkit-mask-image: linear-gradient(to right, transparent 0, #000 200px); mask-image: linear-gradient(to right, transparent 0, #000 200px); }
  .fl-agent { gap: 7px; padding: 10px 10px; font-size: 13.5px; }
  .fl-agent svg { width: 18px; height: 18px; }
  .fl-if b { font-size: 13px; }
  .fl-if svg { width: 17px; height: 17px; }
  .fl-bridge span { font-size: 11.5px; }
  .fl-k { font-size: 9.5px; letter-spacing: .02em; }
}
@media (max-width: 900px) {
  .h-flow { margin: 0; }
  .h-flow::before { inset: 0; -webkit-mask-image: none; mask-image: none; }
  .h-hero { grid-template-columns: minmax(0, 1fr); padding-top: 48px; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .gallery, .uc, .aw, .plans { grid-template-columns: minmax(0, 1fr); }
  .h-cmd, .h-cmd code { font-size: 13px; }
  /* diagram stacks: each column becomes a row, wires run downward */
  .h-flow { grid-template-columns: minmax(0, 1fr); gap: 30px; padding: 20px 16px 22px; }
  .fl-col { grid-template-rows: auto auto; gap: 10px; }
  .fl-k { justify-self: center; padding: 2px 9px; border-radius: 99px; border: 1px solid var(--line); background: var(--panel); }
  .fl-items { grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
  .fl-col:first-of-type .fl-items { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fl-bridge { justify-self: center; width: min(100%, 240px); padding: 16px 10px; }
  .fl-agent { padding: 10px 12px; font-size: 14px; }
  .fl-agent:last-child { grid-column: 1 / -1; justify-self: center; width: calc(50% - 4px); }
}
@media (prefers-reduced-motion: reduce) {
  .fl-pulse { animation: none; stroke-dasharray: none; opacity: .35; }
  .rot, .gallery figure .media { transition: none; }
  .caret { animation: none; }
}
.can-sub { margin: -14px 0 26px; color: var(--muted); }
.can-sub a { color: var(--ink); }
.gallery figcaption code { overflow-wrap: anywhere; }
.tag-link { text-decoration: none; }
.tag-link:hover { filter: brightness(1.05); text-decoration: underline; }

/* "let your AI install it": copies one sentence that points the agent at install.md */
.ai-copy { display: inline-flex; align-items: center; gap: 9px; margin-top: -10px; padding: 8px 12px; border-radius: 10px;
           border: 1px dashed var(--line); background: transparent; color: var(--muted); font: 14px var(--sans); cursor: pointer; }
.ai-copy b { color: var(--ink); font-weight: 600; }
.ai-copy svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ai-copy:hover { border-color: var(--ink); color: var(--text); }
.ai-copy:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

/* label chip on every playing video */
.vid-tag {
  position: absolute; left: 10px; bottom: 10px; z-index: 1; display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 9px; border-radius: 99px; background: rgba(10,10,10,.62); color: #f6f6f1;
  font: 500 10.5px var(--mono); letter-spacing: .03em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); pointer-events: none;
}
.vid-tag i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: vid-live 1.6s ease-in-out infinite; }
@keyframes vid-live { 50% { opacity: .3; } }
.fl-vid .vid-tag { left: 6px; bottom: 6px; padding: 3px 7px; font-size: 8.5px; }
.media-xl .vid-tag { left: 16px; top: 16px; bottom: auto; font-size: 12px; padding: 6px 12px; }
.gallery figcaption span { color: var(--muted); font-size: 14.5px; }

/* discord in the nav */
.nav-discord { display: inline-flex; align-items: center; gap: 6px; }
.nav-discord svg { flex: none; }

/* three plans: free, pro, custom */
.plans { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 1120px; }
.plan-price-sm { font-size: 38px; padding-top: 6px; }
.plan-shop a { color: var(--ink); }
@media (max-width: 900px) { .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* closing line rotates with the hero */
.h-end h2 .rot { margin-left: 0; }
.h-end .cta { display: flex; gap: 12px; flex-wrap: wrap; }

/* credits / terms / privacy in the footer */
.foot-legal { flex-basis: 100%; font-size: 13px; }
.foot-legal a { color: inherit; }
.foot-legal a:hover { color: var(--text); }

/* legal + credits pages */
.legal { max-width: 760px; padding: 56px 0 80px; }
.legal h1 { font-family: var(--display); font-weight: 750; font-size: clamp(34px, 5vw, 52px); letter-spacing: -0.04em; margin: 0 0 6px; }
.legal .updated { font: 11px var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin: 0 0 32px; }
.legal h2 { font-family: var(--display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; margin: 34px 0 10px; }
.legal p, .legal li { color: var(--text); line-height: 1.65; }
.legal ul { padding-left: 20px; display: grid; gap: 6px; }
.legal a { color: var(--ink); }
.legal .tbl { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.legal table { width: 100%; border-collapse: collapse; font-size: 14px; }
.legal th, .legal td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal th { font: 500 11px var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.legal tr:last-child td { border-bottom: 0; }
.legal td code { font: 12px var(--mono); word-break: break-all; }
