Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

9.6 KB
Raw Blame
/*
 * The agent card's furniture — a champion card of the island, in the app's
 * own light.
 *
 * It first shipped in the island's daylight: parchment ground, ink text, the
 * same in both themes. The maintainer sent it back on 2026-09-03 — a bright
 * panel inside a near-black app reads as a foreign object, not as a card. So
 * the SHAPE stays (nameplate band, 56px hands, notched meters, the island's
 * display face) and the COLOUR goes back to the theme tokens, which is also
 * what makes it right in light mode without a second palette to maintain.
 *
 * The one hue that survives is the island's gold, on the meters: the world's
 * own signal, the same mark the HUD's pressed chips wear. It is declared per
 * theme below rather than as one literal that only works on one ground.
 * Everything else is `hsl(var(--token))`, so this file adds no colour
 * decisions to the system.
 */

.ac-card {
  --ac-gold: 42 88% 40%; /* the island's gold, darkened for a white ground */

  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: "Pixelify Sans", "Inter Variable", "Inter", ui-sans-serif, system-ui, sans-serif;
}
.dark .ac-card {
  --ac-gold: 42 100% 70%; /* #FFD166 — as the HUD wears it on the island */
}

/* Running text stays in the interface family: Pixelify is a display face, and
   a paragraph of standing instructions set in it is a wall of pixels. The
   card's own furniture (headings, nameplate, meters, plates) keeps it. */
.ac-prose {
  font-family: "Inter Variable", "Inter", ui-sans-serif, system-ui, sans-serif;
}

/* --- the nameplate band ------------------------------------------------- */

.ac-band {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px 13px;
  background: hsl(var(--secondary));
  box-shadow: inset 0 -2px 0 hsl(var(--border));
}
/* The lead is the only one the town has; its plate carries the gold. */
.ac-band[data-tier="lead"] {
  box-shadow: inset 0 -2px 0 hsl(var(--ac-gold));
}
.ac-band-name {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.01em;
  color: hsl(var(--foreground-strong));
}
.ac-band-title {
  font-size: 12px;
  line-height: 1.2;
  color: hsl(var(--muted-foreground));
}

/* The state dot is the island's nameplate dot, square-ish and pulsing while
   the agent works — the same mark it wears over its head in the world. */
.ac-dot {
  width: 9px;
  height: 9px;
  flex: none;
  border-radius: 2px;
}
.ac-dot[data-state="working"] {
  animation: ac-pulse 1.2s ease-in-out infinite;
}
@keyframes ac-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.35);
  }
}
@media (prefers-reduced-motion: reduce) {
  .ac-dot[data-state="working"] {
    animation: none;
  }
}

/* --- section headings --------------------------------------------------- */

.ac-head {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground));
}

/* --- the HANDS tiles ---------------------------------------------------- */

.ac-tile {
  position: relative;
  display: flex;
  width: 60px;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  text-align: center;
}
.ac-tile-mark {
  position: relative;
  display: flex;
  width: 56px;
  height: 56px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid hsl(var(--border));
  background: hsl(var(--secondary));
}
.ac-tile-mark img {
  width: 34px;
  height: 34px;
  object-fit: contain;
}
/* No bundled mark: the monogram sits on the agent's own identity colour.
   A grey disc with two letters is the one fallback the brand rules forbid
   (assets/brands/LOGOS.md), so the tile takes a hue instead of going flat. */
.ac-tile-monogram {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.ac-tile-label {
  width: 100%;
  font-size: 11px;
  line-height: 1.25;
  color: hsl(var(--foreground));
  overflow-wrap: anywhere;
}
/* The risk tier, as a corner notch: why this one stops and asks. */
.ac-tile-risk {
  position: absolute;
  right: 3px;
  bottom: 3px;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  border: 1px solid hsl(var(--background));
}
.ac-tile-risk[data-risk="safe"] {
  background: hsl(var(--success));
}
.ac-tile-risk[data-risk="monitor"] {
  background: hsl(var(--warning));
}
.ac-tile-risk[data-risk="ask"],
.ac-tile-risk[data-risk="block"] {
  background: hsl(var(--destructive));
}

/* --- meters ------------------------------------------------------------- */

.ac-meter {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
}
.ac-meter-label {
  width: 116px;
  flex: none;
  color: hsl(var(--muted-foreground));
}
.ac-meter-track {
  display: flex;
  flex: none;
  gap: 3px;
}
.ac-meter-seg {
  width: 16px;
  height: 10px;
  border-radius: 2px;
  background: hsl(var(--secondary));
  box-shadow: inset 0 0 0 1px hsl(var(--border));
}
.ac-meter-seg[data-on="1"] {
  background: hsl(var(--ac-gold));
  box-shadow: none;
}
/* Spent against a cap: a continuous bar, because money does not come in
   steps. It turns to the fault hue at the line the scheduler refuses at. */
.ac-meter-bar {
  position: relative;
  height: 10px;
  /* The same span as the six notches beside it, so the three meters read as
     one column rather than one bar stretching past the others. */
  width: 111px;
  flex: none;
  overflow: hidden;
  border-radius: 3px;
  background: hsl(var(--secondary));
  box-shadow: inset 0 0 0 1px hsl(var(--border));
}
.ac-meter-fill {
  height: 100%;
  background: hsl(var(--ac-gold));
  transition: width 400ms ease;
}
.ac-meter-bar[data-spent="1"] .ac-meter-fill {
  background: hsl(var(--destructive));
}
@media (prefers-reduced-motion: reduce) {
  .ac-meter-fill {
    transition: none;
  }
}
.ac-meter-value {
  flex: none;
  font-weight: 600;
}

/* --- small fact plates -------------------------------------------------- */

.ac-plate {
  min-width: 0;
  padding: 7px 9px 8px;
  border-radius: 6px;
  border: 1px solid hsl(var(--border));
  background: hsl(var(--secondary));
}
.ac-plate-label {
  font-size: 11px;
  line-height: 1.2;
  color: hsl(var(--muted-foreground));
}
.ac-plate-value {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  color: hsl(var(--foreground));
}

/* --- the activity log --------------------------------------------------- */

.ac-log {
  display: flex;
  flex-direction: column;
}
.ac-log-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 4px 0;
  font-size: 12px;
  border-bottom: 1px solid hsl(var(--border));
}
.ac-log-row:last-child {
  border-bottom: 0;
}
.ac-log-type {
  width: 78px;
  flex: none;
  font-weight: 600;
  color: hsl(var(--foreground));
}
.ac-log-what {
  min-width: 0;
  flex: 1;
  color: hsl(var(--muted-foreground));
}
.ac-log-when {
  flex: none;
  color: hsl(var(--muted-foreground));
  font-variant-numeric: tabular-nums;
}

/* --- the action bar ----------------------------------------------------- */

.ac-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid hsl(var(--border));
  background: hsl(var(--sidebar));
}
.ac-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px 7px;
  font: inherit;
  font-size: 13px;
  line-height: 1;
  color: hsl(var(--foreground));
  background: hsl(var(--secondary));
  border: 1px solid hsl(var(--border));
  border-radius: 6px;
  cursor: pointer;
  transition: transform 80ms ease, background-color 120ms ease;
}
.ac-btn:hover:not(:disabled) {
  background: hsl(var(--surface-raised));
}
.ac-btn:active:not(:disabled) {
  transform: translateY(1px);
}
.ac-btn:disabled {
  opacity: 0.45;
  cursor: default;
}
.ac-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px hsl(var(--ring));
}
@media (prefers-reduced-motion: reduce) {
  .ac-btn {
    transition: none;
  }
  .ac-btn:active:not(:disabled) {
    transform: none;
  }
}

/* Retiring an agent is the one action on the card that cannot be undone, so
   the second press is coloured like what it is. `--destructive` stays a real
   colour in both appearances (Ink & Paper keeps it), and the text token comes
   with it so the label survives light mode. */
.ac-btn[data-armed] {
  color: hsl(var(--destructive-foreground));
  background: hsl(var(--destructive));
  border-color: hsl(var(--destructive));
}
.ac-btn[data-armed]:hover:not(:disabled) {
  background: hsl(var(--destructive) / 0.88);
}
.ac-retire-error {
  margin-left: auto;
  font-size: 12px;
  color: hsl(var(--destructive));
}
/* Options-rail screen: the Grok-shaped preview, in theme tokens. */
.or-screen {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid hsl(var(--border));
  background:
    radial-gradient(120% 90% at 50% 0%, hsl(var(--secondary)) 0%, hsl(var(--background)) 62%);
  box-shadow: inset 0 1px 0 hsl(var(--foreground) / 0.04);
}
.or-screen-mark {
  color: hsl(var(--foreground));
  opacity: 0.92;
}
.or-screen[data-busy] .or-screen-mark {
  animation: or-breathe 1.8s ease-in-out infinite;
}
.or-screen-bar {
  position: absolute;
  right: 16px;
  bottom: 14px;
  left: 16px;
  height: 3px;
  overflow: hidden;
  border-radius: 99px;
  background: hsl(var(--foreground) / 0.08);
}
.or-screen-bar > span {
  display: block;
  height: 100%;
  background: hsl(var(--foreground) / 0.45);
}
@keyframes or-breathe {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.04);
  }
}
@media (prefers-reduced-motion: reduce) {
  .or-screen[data-busy] .or-screen-mark {
    animation: none;
  }
}

.ac-retire-error + .ac-btn {
  margin-left: 8px;
}