Skip to content

A tiny friend in your Mac's notch and on your iPhone that keeps an eye on your AI coding agents: Claude Code, Codex, Cursor, Gemini CLI, Antigravity and more. Approve from the notch or your Lock Screen.

61.0 KB
Raw Blame
/* Coucou for Windows — same palette, sizes and type scale as the macOS island.
   Every colour below is copied from the Swift views. */

:root {
  color-scheme: dark;

  /* After the Latin fonts: the scripts of the other interface languages —
     Devanagari and Bengali (Nirmala UI), Simplified Chinese (Microsoft YaHei)
     on Windows, the Noto families on Linux. Arabic and Cyrillic are in Segoe UI. */
  --font: system-ui, "Segoe UI Variable Text", "Segoe UI", "Segoe UI Emoji", "Nirmala UI",
    "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans", "Noto Sans Devanagari", "Noto Sans Bengali",
    "Noto Sans Arabic", "Noto Sans CJK SC", "Noto Sans SC", "Droid Sans Fallback", sans-serif;
  --mono: "Cascadia Mono", "Consolas", ui-monospace, monospace;

  --ink: #f5f6f8;        /* primary text */
  --ink-2: #f1f2f4;
  --dim: #9398a1;
  --dim-2: #8e939c;
  --dim-3: #6b7079;
  --dim-4: #5f646d;
  --dim-5: #4b5563;
  --card: #141518;
  --card-flat: #0e0f11;
  --tab-on: #1d1f23;
  --hairline: rgba(255, 255, 255, 0.035);
  --red: #f4505e;
  --red-text: #ff8d97;
  --green: #22c55e;
  --green-2: #34d399;
  --amber: #f5a524;
  --cyan: #22d3ee;
  --indigo: #6366f1;
  --pink: #f472b6;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  width: 100%;
  height: 100%;
  background: transparent;
  overflow: hidden;
  font-family: var(--font);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  user-select: none;
  cursor: default;
}

#root {
  position: fixed;
  inset: 0;
}

/* Invisible strip that wakes the island when it is hidden. */
#wake-strip {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 240px;
  height: 6px;
  background: transparent;
}

/* ── Island ─────────────────────────────────────────────────────────────── */

#island {
  position: absolute;
  top: 0;
  left: 50%;
  background: #000;
  border-radius: 0 0 14px 14px;
  overflow: visible;
  will-change: width, height, transform;
}

#island-clip {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
}

#bot-canvas,
#greeting-canvas {
  position: absolute;
  pointer-events: none;
}

/* The drop sequence. Sits under the header and takes over the island body; it
   cross-fades in and out, so the last frame stays up while the views return. */
#upload-layer {
  position: absolute;
  top: 0;
  width: 640px;
  height: 176px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease-in-out;
}

#upload-layer.on {
  opacity: 1;
}

#upload-canvas {
  position: absolute;
  inset: 0;
}

#upload-overlay {
  position: absolute;
  inset: 0;
  display: none;
}

/* Invisible hit areas over the buttons the canvas paints. */
.upload-hit {
  position: absolute;
  padding: 0;
  border: 0;
  border-radius: 13px;
  background: none;
  pointer-events: auto;
  cursor: pointer;
}

/* The ordinary views step aside while the sequence owns the body. The active
   view sets pointer-events back to auto, which beats the parent's none: it has
   to be switched off too, or its invisible card swallows the canvas buttons. */
#views.hidden-by-upload {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease-in-out;
}

#views.hidden-by-upload .view.on {
  pointer-events: none;
}

#bot-glow {
  position: absolute;
  pointer-events: none;
  border-radius: 50%;
  filter: blur(6px);
  transition: opacity 0.4s ease-in-out, background 0.4s ease-in-out;
}

#countdown {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  height: 2px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.35);
  width: 0;
}

/* Compact 2×2 mini grid, to the right of the notch. */
#mini-grid {
  position: absolute;
  width: 29px;
  height: 29px;
  display: grid;
  grid-template-columns: 13px 13px;
  grid-auto-rows: 13px;
  gap: 3px;
  pointer-events: none;
  transition: opacity 0.25s ease-in-out;
}

/* Compact Claude plan gauge, next to the agent dots in the compact island. */
#compact-plan {
  --plan: #6b7079;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px 7px;
  border: 1px solid color-mix(in srgb, var(--plan) 14%, transparent);
  border-radius: 999px;
  background: #0e0f11;
  color: var(--dim-3);
  font: 600 10px var(--font);
  font-variant-numeric: tabular-nums;
  line-height: 12px;
  white-space: nowrap;
  cursor: pointer;
  pointer-events: auto;
  opacity: 0;
  transition: opacity 0.25s ease-in-out, right 0.2s ease, background 0.18s, border-color 0.18s, color 0.18s;
  user-select: none;
  z-index: 2;
}

#compact-plan:hover {
  background: color-mix(in srgb, var(--plan) 18%, transparent);
  border-color: color-mix(in srgb, var(--plan) 55%, transparent);
  color: color-mix(in srgb, var(--plan) 70%, white);
}

#compact-plan .compact-plan-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--plan);
  flex-shrink: 0;
}

/* Date and time in the middle of the compact island, between Mochi and the grid. */
#island-clock {
  position: absolute;
  left: 50px;
  right: 56px;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.85);
  pointer-events: none;
  transition: opacity 0.25s ease-in-out;
}

/* A mini Mochi: the slot is the body, the canvas is larger and overflows it so
   hands, badges and particles are not cut off. */
.mini {
  position: relative;
  display: inline-block;
  flex: 0 0 auto;
}

.mini canvas {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

/* ── Content shell (expanded) ───────────────────────────────────────────── */

#content {
  position: absolute;
  inset: 0;
  padding: 8px 10px 10px;
  display: flex;
  flex-direction: column;
  transition: opacity 0.2s ease-in-out;
}

#header {
  height: 34px;
  flex: 0 0 34px;
  display: flex;
  align-items: center;
  margin: 0 -10px;
  transition: opacity 0.2s ease-in-out;
}

.tabs {
  display: flex;
  gap: 5px;
  padding-left: 14px;
}

.tab {
  width: 30px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  border-radius: 11px;
  color: var(--dim-2);
  cursor: default;
}

.tab:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #b0b5be;
}

.tab.on {
  background: var(--tab-on);
  color: var(--ink);
}

.header-actions {
  margin-left: auto;
  display: flex;
  gap: 14px;
  padding-right: 16px;
}

.header-actions button {
  border: 0;
  background: transparent;
  color: var(--dim-2);
  display: grid;
  place-items: center;
  cursor: default;
}

.header-actions button.on {
  color: var(--ink);
}

#views {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
}

.view {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(0.97);
  pointer-events: none;
  transition: opacity 0.16s ease-in;
}

.view.on {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
  transition: opacity 0.3s ease-out 0.16s, transform 0.3s cubic-bezier(0.3, 1.2, 0.4, 1) 0.16s;
}

/* A view that is not on is only transparent, not gone: an infinite animation
   inside it (the drop frame's marching dashes) would keep the webview
   repainting every frame for as long as the app runs, island hidden or not. */
.view:not(.on) * {
  animation-play-state: paused;
}

/* ── Cards ──────────────────────────────────────────────────────────────── */

.card {
  position: relative;
  height: 100%;
  border-radius: 20px;
  background: var(--card);
  border: 1px solid var(--hairline);
  overflow: hidden;
}

.card.wash::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    280px 280px at 50% 130%,
    var(--wash) 0%,
    rgba(0, 0, 0, 0) 70%
  );
  pointer-events: none;
}

.row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.dot {
  display: inline-block;
  border-radius: 50%;
  flex: 0 0 auto;
}

/* ── Buttons ────────────────────────────────────────────────────────────── */

.btn {
  font: 500 12.5px var(--font);
  padding: 7px 13px;
  border: 0;
  border-radius: 999px;
  cursor: default;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: transform 0.08s ease-out, background 0.12s ease-out;
}

.btn:active {
  transform: scale(0.94);
}

.btn.primary {
  background: var(--ink);
  color: #0b0c0e;
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.09);
  color: var(--ink-2);
}

.btn.secondary:hover {
  background: rgba(255, 255, 255, 0.15);
}

.btn .kbd {
  font-size: 10.5px;
  padding: 0 4px;
  border-radius: 4px;
  opacity: 0.55;
}

.btn.primary .kbd {
  border: 1px solid rgba(0, 0, 0, 0.4);
}

.btn.secondary .kbd {
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.link-btn {
  border: 0;
  background: transparent;
  font: 500 11px var(--font);
  cursor: default;
}

.icon-btn {
  width: 16px;
  height: 16px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
  color: var(--dim-4);
  display: grid;
  place-items: center;
  cursor: default;
}

/* ── Overview ───────────────────────────────────────────────────────────── */

.overview {
  display: flex;
  gap: 10px;
  height: 100%;
}

.overview > .left {
  flex: 0 0 322px;
  width: 322px;
}

.overview > .right {
  flex: 1 1 auto;
}

.card-body {
  position: relative;
  z-index: 1;
  padding-top: 10px;
}

.who {
  padding: 0 36px 0 108px;
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.who .name {
  font: 600 12px var(--font);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.who .tool {
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
}

.who .count {
  font: 400 11px var(--font);
  color: var(--dim-3);
  margin-left: auto;
  flex: 0 0 auto;
}

.jump {
  position: absolute;
  top: 8px;
  right: 10px;
  z-index: 2;
}

/* Folds a waiting permission card or question away without answering it. */
.fold {
  position: absolute;
  top: 8px;
  right: 10px;
  z-index: 2;
}

/* Ticker */

.ticker {
  position: relative;
  height: 44px;
  margin: 6px 12px 0 108px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(
    to bottom,
    transparent 0%,
    #000 12%,
    #000 85%,
    transparent 100%
  );
  mask-image: linear-gradient(to bottom, transparent 0%, #000 12%, #000 85%, transparent 100%);
}

.ticker-row {
  position: absolute;
  left: 0;
  right: 0;
  height: 22px;
  display: flex;
  align-items: center;
  gap: 6px;
  transform-origin: left center;
  will-change: transform, opacity;
}

.ticker-row .tick-icon {
  width: 12px;
  display: grid;
  place-items: center;
  flex: 0 0 12px;
  color: var(--dim-2);
}

.ticker-row .tick-text {
  font: 500 13px var(--font);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Live diff step: file name, then +N −M right after it (TickerRowView). */
.ticker-row .tick-count {
  flex: 0 0 auto;
  margin-left: -6px; /* no row gap: the counts sit right after the name */
  font: 500 10px var(--mono);
  white-space: pre;
}

.ticker-row .tick-count .plus {
  color: var(--green);
}

.ticker-row .tick-count .minus {
  color: var(--red);
}

/* ── Diff card (overview, left card) — DiffCardView ─────────────────────── */

.diff-card {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 4px 10px 4px 108px;
}

.diff-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0 3px;
  min-width: 0;
}

.diff-back {
  display: flex;
  align-items: center;
  gap: 3px;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: default;
}

.diff-back b {
  font: 600 12px var(--font);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.diff-head .grow {
  flex: 1 1 auto;
}

.diff-head .tick-count {
  flex: 0 0 auto;
  font: 500 10px var(--mono);
}

.diff-head .plus {
  color: var(--green);
}

.diff-head .minus {
  color: var(--red);
}

.diff-head .icon-btn {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}

.diff-note {
  font: 400 10.5px var(--font);
  color: var(--dim-3);
}

.diff-lines {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
  user-select: text;
}

.diff-lines::-webkit-scrollbar {
  display: none;
}

.diff-line {
  display: flex;
  min-height: 14px; /* an empty line still takes a row */
  font: 400 10.5px/1.35 var(--mono);
  color: var(--dim-3);
}

.diff-line .sym {
  flex: 0 0 12px;
  color: #454850;
}

.diff-line .txt {
  flex: 1 1 auto;
  min-width: 0;
  white-space: pre;
  overflow: hidden;
  text-overflow: ellipsis;
}

.diff-line.added {
  background: rgba(34, 197, 94, 0.12);
  color: #86efac;
}

.diff-line.added .sym {
  color: var(--green);
}

.diff-line.removed {
  background: rgba(244, 80, 94, 0.12);
  color: #fca5a5;
}

.diff-line.removed .sym {
  color: var(--red);
}

/* Shimmer sweep, 2.2 s — same as TickerShimmerText / ShimmeringText */
.shimmer {
  background: linear-gradient(
    90deg,
    #7c818a 0%,
    #f2f3f5 40%,
    #7c818a 70%
  );
  background-size: 260% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer 2.2s linear infinite;
}

@keyframes shimmer {
  from {
    background-position: 130% 0;
  }
  to {
    background-position: -130% 0;
  }
}

/* ── Agent pills ────────────────────────────────────────────────────────── */

.pills {
  position: relative;
  z-index: 1;
  height: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 28px;
  gap: 4px;
  align-content: center;
  padding: 0 8px;
}

.pill {
  position: relative;
  height: 28px;
  border-radius: 999px;
  background: var(--card-flat);
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  align-items: center;
  cursor: default;
  transition: transform 0.2s cubic-bezier(0.3, 1.2, 0.4, 1), background 0.18s, border-color 0.18s,
    box-shadow 0.18s, filter 0.18s;
}

.pill .mini {
  margin-left: 7px;
}

.pill .lbl {
  position: absolute;
  left: 0;
  right: 0;
  text-align: center;
  font: 600 10px var(--font);
  color: var(--dim-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 8px 0 34px;
  pointer-events: none;
}

.pill:hover {
  transform: scale(1.04);
  filter: brightness(1.06);
}

.pill-badge {
  position: absolute;
  top: -3px;
  right: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #0b0c0e;
  display: grid;
  place-items: center;
}

.pill-badge i {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #000;
}

.pill-badge svg {
  width: 6px;
  height: 6px;
}

/* ── Generic text blocks ────────────────────────────────────────────────── */

.title {
  font: 600 15px var(--font);
}

/* Claude's final message on the finished card: one line, never past the card. */
.title.one-line {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.sub {
  font: 400 13px var(--font);
  color: var(--dim);
}

.detail {
  font: 400 12px var(--font);
  color: var(--red-text);
}

.who-row {
  display: flex;
  align-items: center;
  gap: 7px;
  font: 400 12px var(--font);
  color: var(--dim-2);
}

.who-row .n {
  font: 600 12px var(--font);
  color: var(--ink);
}

.code {
  font: 400 12px var(--mono);
  color: #e8e9ec;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 5px 10px;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  user-select: text;
}

.stack {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}

.actions {
  display: flex;
  gap: 8px;
}

/* Options to pick from when Claude Code asks a question. */
.actions.options {
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.question-text {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn.off {
  opacity: 0.4;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font: 400 11px var(--font);
  color: var(--dim-2);
}

/* ── Settings view (in-island) ──────────────────────────────────────────── */

.settings-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.settings-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 400 12.5px var(--font);
  color: #c5c8cd;
}

.switch {
  position: relative;
  width: 32px;
  height: 18px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.15);
  flex: 0 0 32px;
  transition: background 0.18s;
  cursor: default;
  border: 0;
}

.switch.on {
  background: var(--green);
}

.switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.18s;
}

.switch.on::after {
  transform: translateX(14px);
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.2);
  width: 72px;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #fff;
}

.seg {
  display: flex;
  gap: 6px;
  margin-left: auto;
}

.seg button {
  font: 400 11px var(--font);
  padding: 3px 7px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--dim-3);
  cursor: default;
}

.seg button.on {
  background: #252830;
  color: var(--ink);
}

/* ── Utility ────────────────────────────────────────────────────────────── */

.grow {
  flex: 1 1 auto;
}

.nowrap {
  white-space: nowrap;
}

/* ── Chat (prompt view) ─────────────────────────────────────────────────── */

.chat-card {
  overflow: hidden;
}

.chat-body {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 16px 14px 84px;
}

.chip-row:empty {
  display: none;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  font: 400 11.5px var(--font);
  color: var(--ink-2);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  transform: scale(1.06);
  transition: border-color 0.3s ease-out 0.45s, transform 0.3s ease-out 0.45s;
}

.chip.settled {
  border-color: rgba(255, 255, 255, 0);
  transform: scale(1);
}

.chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff6b5b, #f7b32b, #2dd4a7, #38bdf8, #a78bfa);
}

.chat-log {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 2px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}

.chat-row {
  display: flex;
}

.chat-row.user {
  justify-content: flex-end;
  padding-left: 32px;
}

.bubble {
  background: rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  padding: 6px 10px;
  font: 400 12.5px var(--font);
  color: var(--ink-2);
  white-space: pre-wrap;
  user-select: text;
}

.reply {
  font: 400 12.5px var(--font);
  color: #b0b5be;
  white-space: pre-wrap;
  padding-right: 8px;
  user-select: text;
  /* Answers are Markdown blocks (views/markdown.ts), spaced as ChatMarkdownView. */
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

/* ── Markdown in the answers ─────────────────────────────────────────────── */

.md-p {
  font: 400 12.5px var(--font);
  color: #b0b5be;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.md-h {
  font: 600 13px var(--font);
  color: var(--ink-2);
  overflow-wrap: anywhere;
}

.md-h1 {
  font-weight: 700;
  font-size: 14px;
}

.reply strong {
  color: #e8e9ec;
  font-weight: 600;
}

.md-code {
  padding: 1px 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  font: 400 11.5px var(--mono);
  color: #c8cdd4;
}

.md-link {
  color: #60a5fa;
  text-decoration: underline;
  cursor: pointer;
}

.md-pre {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: #0d0e12;
}

.md-pre pre {
  flex: 1 1 auto;
  min-width: 0;
  font: 400 11px var(--mono);
  color: #c8cdd4;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.md-copy {
  flex: 0 0 22px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--dim-3);
  cursor: default;
}

.md-copy:hover {
  color: var(--dim);
}

.md-copy.done {
  color: var(--green);
}

.md-item {
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.md-bullet {
  flex: 0 0 auto;
  min-width: 10px;
  font: 400 12.5px var(--font);
  color: var(--dim-3);
}

.md-quote {
  display: flex;
  align-items: stretch;
  gap: 8px;
}

.md-quote i {
  flex: 0 0 2px;
  border-radius: 1px;
  background: var(--dim-5);
}

.md-quote .md-p {
  color: #8a8f98;
}

.md-rule {
  width: 100%;
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  opacity: 0.3;
}

.typing {
  display: flex;
  gap: 4px;
  padding: 4px 2px;
}

.typing i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--dim-3);
  animation: typing 0.9s ease-in-out infinite;
}

.typing i:nth-child(2) {
  animation-delay: 0.14s;
}

.typing i:nth-child(3) {
  animation-delay: 0.28s;
}

@keyframes typing {
  0%, 100% { transform: scale(0.6); }
  50% { transform: scale(1.2); }
}

/* ── Provider and model switcher (PromptView's model button) ─────────────── */

.model-row {
  display: flex;
  justify-content: flex-end;
  padding: 0 10px;
}

.model-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 4px 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #5c6370;
  cursor: default;
}

.model-btn:hover:not(:disabled),
.model-btn.open {
  background: rgba(255, 255, 255, 0.1);
}

.model-btn:disabled {
  opacity: 0.6;
}

.model-dot {
  flex: 0 0 6px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.model-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font: 500 10.5px var(--font);
  color: #7b8089;
}

.picker {
  display: none;
  flex: 1 1 auto;
  min-height: 0;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  border-radius: 12px;
  background: #16171b;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.chat-body.picking .picker {
  display: flex;
}

.chat-body.picking .chat-log,
.chat-body.picking .chip-row {
  display: none;
}

.picker-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.picker-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
  font: 400 11.5px var(--font);
  color: #c8cdd4;
  cursor: default;
}

.picker-chip.on {
  font-weight: 600;
  color: var(--ink-2);
  /* Plain fallbacks for WebKitGTK builds without color-mix(). */
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.12);
  border-color: color-mix(in srgb, var(--accent) 50%, transparent);
  background: color-mix(in srgb, var(--accent) 18%, transparent);
}

.picker-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.picker-rule {
  flex: 0 0 1px;
  background: rgba(255, 255, 255, 0.2);
  opacity: 0.4;
}

.picker-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}

.picker-model {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #c8cdd4;
  font: 400 12px var(--font);
  text-align: left;
  cursor: default;
}

.picker-model:hover {
  background: rgba(255, 255, 255, 0.05);
}

.picker-model.on {
  color: var(--accent);
  background: rgba(255, 255, 255, 0.06);
  background: color-mix(in srgb, var(--accent) 10%, transparent);
}

.picker-model-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.picker-status {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 4px 0;
  font: 400 11px var(--font);
  color: #8a8f98;
}

.picker-link {
  padding: 0;
  border: 0;
  background: none;
  color: #60a5fa;
  font: inherit;
  cursor: default;
}

.chat-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 12px;
}

.chat-input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: 400 13px var(--font);
  outline: none;
  cursor: text;
}

.chat-input::placeholder {
  color: var(--dim-3);
}

.send-btn {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border: 0;
  border-radius: 50%;
  background: var(--ink);
  color: #0b0c0e;
  display: grid;
  place-items: center;
  cursor: default;
  transition: transform 0.08s ease-out;
}

.send-btn:active {
  transform: scale(0.94);
}

/* ── Drop zone ──────────────────────────────────────────────────────────── */

.drop-card {
  background: var(--card-flat);
  border: 0;
}

.drop-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.drop-frame rect {
  stroke: rgba(255, 255, 255, 0.13);
  animation: dash-march 1.1s linear infinite, dash-breathe 7s ease-in-out infinite;
}

.drop-card.over {
  background: radial-gradient(200px 200px at 50% 100%, rgba(34, 197, 94, 0.13), transparent 70%),
    var(--card-flat);
}

.drop-card.over .drop-frame rect {
  stroke: rgba(34, 197, 94, 0.65);
  animation: dash-march 1.1s linear infinite;
}

@keyframes dash-march {
  to { stroke-dashoffset: -11; }
}

@keyframes dash-breathe {
  0%, 100% { stroke: rgba(255, 255, 255, 0.11); }
  50% { stroke: rgba(255, 255, 255, 0.15); }
}

.drop-body {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding-left: 196px;
}

.drop-title {
  font: 500 13px var(--font);
  color: #d5d7db;
  transition: color 0.2s;
}

.drop-card.over .drop-title {
  color: var(--green-2);
}

.drop-tags {
  display: flex;
  gap: 6px;
}

.drop-tags span {
  font: 400 11px var(--font);
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: #b9bdc4;
}

/* ── Uploading ──────────────────────────────────────────────────────────── */

.up-card {
  background: radial-gradient(260px 260px at 50% 140%, rgba(52, 211, 153, 0.14), transparent 70%),
    var(--card);
}

.up-card.done {
  background: radial-gradient(260px 260px at 50% 140%, rgba(52, 211, 153, 0.28), transparent 70%),
    var(--card);
}

.up-row {
  position: absolute;
  left: 26px;
  top: 36px;
  width: 526px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font: 400 12.5px var(--font);
  color: #a9adb5;
}

.up-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.up-name.done {
  color: var(--green-2);
  font-weight: 600;
}

.up-pct {
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  flex: 0 0 auto;
}

.up-track {
  position: absolute;
  left: 26px;
  top: 58px;
  width: 526px;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.09);
}

.up-fill {
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, #1fa87a, #34d399);
}

.up-glow {
  position: absolute;
  left: 0;
  top: -3px;
  width: 28px;
  height: 12px;
  border-radius: 50%;
  background: rgba(110, 231, 183, 0.45);
  filter: blur(5px);
  pointer-events: none;
}

/* ── Integration cards (overview, left card) ────────────────────────────── */

.left-body {
  position: relative;
  z-index: 1;
  height: 100%;
}

.int-card {
  padding: 10px 12px 0 108px;
  display: flex;
  flex-direction: column;
}

.int-head {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding-right: 24px;
}

.int-head b {
  font: 600 12px var(--font);
  color: var(--ink);
}

.int-head > span {
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
}

.int-total {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 2px;
}

.int-total span {
  font: 500 11px var(--font);
  color: #c5c8cd;
  font-variant-numeric: tabular-nums;
}

.pulse {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 1.8s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.2; }
  50% { opacity: 1; }
}

.int-status {
  display: flex;
  align-items: center;
  gap: 5px;
  padding-top: 4px;
  font: 400 11px var(--font);
  color: var(--dim-3);
}

.int-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 6px;
}

.int-rows {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding-top: 5px;
}

.int-rows.tight {
  gap: 2px;
  padding-top: 4px;
}

.int-row {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 5px;
  min-width: 0;
}

.int-name {
  font: 500 11px var(--font);
  color: #9398a1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.int-row.first .int-name {
  color: #c5c8cd;
}

.int-ago {
  font: 400 10px var(--font);
  color: var(--dim-3);
  flex: 0 0 auto;
}

.int-sub {
  font: 400 10px var(--font);
  color: #4d5159;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.int-amount {
  font: 500 11px var(--mono);
  margin-left: auto;
  flex: 0 0 auto;
}

.int-time {
  font: 500 10px var(--mono);
  color: #c9956a;
  flex: 0 0 auto;
}

.int-more,
.int-back {
  border: 0;
  background: transparent;
  color: var(--dim-3);
  display: grid;
  place-items: center;
  cursor: default;
  flex: 0 0 auto;
}

.int-more {
  width: 18px;
  height: 18px;
}

.int-back {
  width: 28px;
  height: 28px;
}

.int-stats {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-top: 8px;
  padding-right: 12px;
}

.int-stat {
  display: flex;
  align-items: center;
  gap: 7px;
}

.int-stat-icon {
  width: 14px;
  display: grid;
  place-items: center;
}

.int-stat-label {
  font: 400 11px var(--font);
  color: var(--dim-3);
}

.int-stat-value {
  margin-left: auto;
  font: 600 12px var(--font);
  color: #c5c8cd;
  font-variant-numeric: tabular-nums;
}

.int-balance {
  display: flex;
  align-items: baseline;
  gap: 3px;
  padding-top: 4px;
}

.int-balance span {
  font: 700 20px var(--mono);
  color: var(--ink);
}

.int-balance i {
  font: 600 9px var(--font);
  font-style: normal;
  color: var(--dim-3);
}

.int-page {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 6px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: default;
  min-width: 0;
}

.int-page:hover {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 5px;
}

.int-emoji {
  width: 14px;
  font-size: 10px;
  color: var(--dim-3);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  font-style: normal;
}

.int-empty {
  font: 400 11px var(--font);
  color: var(--dim-3);
  padding-left: 8px;
}

.int-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--dim-3);
  cursor: default;
  max-width: 100%;
  min-width: 0;
}

.int-detail-head {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.int-detail-head b {
  font: 600 11px var(--font);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.int-badge {
  font: 500 10px var(--font);
  padding: 2px 6px;
  border-radius: 999px;
  margin-left: auto;
  flex: 0 0 auto;
}

.int-detail-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 8px;
}

.int-commit {
  font: 400 10.5px var(--font);
  color: #c5c8cd;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.int-meta {
  display: flex;
  gap: 8px;
  font: 400 10px var(--font);
  color: var(--dim-3);
}

.int-link {
  border: 0;
  background: transparent;
  font: 400 10px var(--mono);
  color: #7c5cffd9;
  text-align: left;
  cursor: default;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.int-detail-text {
  font: 400 10.5px/1.5 var(--mono);
  color: var(--dim);
  margin-top: 8px;
  max-height: 88px;
  overflow: auto;
  white-space: pre-wrap;
  user-select: text;
}

.int-card.detail {
  padding-top: 8px;
}

/* ── Plan usage: the pills in the header and the card behind them ────────────
   ClaudePlanHeaderPill / ClaudePlanCardView / CodexPlanCardView on the Mac.
   Nothing here applies until a pill is turned on in Settings. */

/* Off: takes no room, so the header is exactly as it shipped. */
.plan-pills {
  display: none;
  align-items: center;
  gap: 5px;
  /* .header-actions spaces its items 14px apart; the Mac puts 8px between
     the pills and the gear. */
  margin-right: -6px;
}

.plan-pills.on {
  display: flex;
}

/* Both pills: the Mac tightens the right side (icons 10px apart, pills 5px
   from the gear, 8px from the edge). */
.header-actions.both-plans {
  gap: 10px;
  padding-right: 8px;
}

.header-actions.both-plans .plan-pills {
  margin-right: -5px;
}

.header-actions .plan-pill {
  --plan: #6b7079;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border: 1px solid color-mix(in srgb, var(--plan) 14%, transparent);
  border-radius: 999px;
  background: #0e0f11;
  color: var(--dim-3);
  font: 600 10px var(--font);
  line-height: 12px;
  white-space: nowrap;
  cursor: default;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
}

.header-actions .plan-pill:hover,
.header-actions .plan-pill.active {
  background: color-mix(in srgb, var(--plan) 18%, transparent);
  border-color: color-mix(in srgb, var(--plan) 55%, transparent);
  color: color-mix(in srgb, var(--plan) 70%, white);
}

.plan-pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.plan-card {
  position: relative;
  z-index: 1;
  padding-top: 10px;
}

.plan-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 36px 0 108px;
  white-space: nowrap;
}

.plan-head > * {
  flex: 0 0 auto;
}

.plan-title {
  font: 600 12px var(--font);
  color: var(--ink);
}

.plan-head > .plan-sub {
  flex: 0 1 auto; /* the one part that gives way, with an ellipsis */
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  font: 400 11px var(--font);
  color: var(--dim-2);
}

.plan-rows {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px 12px 0 108px;
}

.plan-row {
  display: flex;
  align-items: center;
  gap: 5px;
  font: 400 11px var(--font);
  white-space: nowrap;
}

.plan-label {
  flex: 0 0 40px;
  color: var(--dim-3);
}

.plan-bar {
  flex: 0 0 50px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.plan-fill {
  display: block;
  height: 100%;
  border-radius: 2px;
}

.plan-pct {
  flex: 0 0 30px;
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #c5c8cd;
}

.plan-reset-icon {
  display: inline-flex;
  color: var(--dim-3);
}

.plan-reset {
  font-size: 10px;
  color: var(--dim-3);
}

.plan-none {
  color: var(--dim-3);
}

.plan-credits {
  font-weight: 600;
  color: #c5c8cd;
}

/* ── GitHub pulse (GitHubPulseCardView / GitHubDetailView) ─────────────── */

.gh-spark {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 0;
  padding: 0;
  background: transparent;
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
  cursor: default;
  min-width: 0;
}

.gh-mini {
  display: inline-flex;
  gap: 2px;
}

.gh-mini i,
.gh-cell {
  width: 7px;
  height: 7px;
  border-radius: 1.5px;
  flex: 0 0 auto;
}

.int-stats.gh-rows {
  gap: 4px;
  padding-top: 6px;
}

.gh-stat {
  border: 0;
  padding: 0;
  background: transparent;
  width: 100%;
  text-align: left;
  cursor: default;
}

.gh-detail-head {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.gh-back {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 0;
  padding: 0;
  background: transparent;
  font: 600 12px var(--font);
  color: var(--ink);
  white-space: nowrap;
  cursor: default;
  flex: 0 0 auto;
}

.gh-head-right {
  margin-left: auto;
  border: 0;
  padding: 0;
  background: transparent;
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  cursor: default;
}

.gh-list {
  display: flex;
  flex-direction: column;
  max-height: 60px; /* three 20 px rows; the rest scrolls */
  overflow-y: auto;
  margin-top: 4px;
  scrollbar-width: none;
}

.gh-list::-webkit-scrollbar {
  display: none;
}

.gh-list.fade {
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 80%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0%, #000 80%, transparent 100%);
}

.gh-row {
  display: flex;
  align-items: center;
  gap: 5px;
  height: 20px;
  flex: 0 0 20px;
  padding: 0 4px 0 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  text-align: left;
  cursor: default;
  min-width: 0;
}

.gh-row:hover {
  background: rgba(255, 255, 255, 0.05);
}

/* Ctrl+↓ / Ctrl+↑: the highlighted row (GitHubPRRowView's `selected`, white 12 %). */
.gh-row.selected {
  background: rgba(255, 255, 255, 0.12);
}

.gh-gap {
  width: 5px;
  flex: 0 0 5px;
}

.gh-ref {
  font: 400 10.5px var(--font);
  color: #9398a1;
  white-space: nowrap;
  flex: 0 0 auto;
}

.gh-title {
  font: 400 11px var(--font);
  color: #c5c8cd;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.gh-draft {
  font: 400 9.5px var(--font);
  color: var(--dim-3);
  flex: 0 0 auto;
}

.gh-word {
  margin-left: auto;
  padding-left: 4px;
  font: 400 10px var(--font);
  white-space: nowrap;
  flex: 0 0 auto;
}

.gh-empty {
  font: 400 10.5px var(--font);
  color: var(--dim-3);
  padding-top: 8px;
}

.gh-grid {
  display: flex;
  gap: 1.5px;
  padding-top: 5px;
}

.gh-week {
  display: flex;
  flex-direction: column;
  gap: 1.5px;
}

.gh-cell.empty {
  background: transparent;
}

/* ── Weekly recap ───────────────────────────────────────────────────────── */
/* WeeklyRecapCardView: text from x = 116, indigo wash, chips of 17 px values. */

.recap-stack {
  padding: 4px 16px 4px 116px;
  gap: 4px;
}

.recap-head {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.recap-title {
  font: 600 11px var(--font);
  color: #818cf8;
}

.recap-range {
  font: 400 10px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
}

.recap-chips {
  display: flex;
  gap: 14px;
  white-space: nowrap;
}

.recap-chip .v {
  font: 700 17px var(--font);
  color: var(--ink-2);
}

.recap-chip .l {
  font: 400 9px var(--font);
  color: var(--dim-2);
}

.recap-meta {
  display: flex;
  gap: 5px;
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recap-meta .n {
  color: var(--ink-2);
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recap-meta .sep {
  color: var(--dim-4);
}

.recap-stack .actions {
  margin-top: 3px;
}

.recap-share {
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 16px;
  padding: 8px 16px 8px 116px;
}

.recap-thumb {
  flex: 0 0 64px;
  width: 64px;
  height: 114px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.recap-share-side {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.recap-status {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-height: 14px;
  font: 400 11px var(--font);
  color: var(--dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recap-link {
  color: #818cf8;
  padding: 0;
}

/* ── Wardrobe (right-click on Mochi) — WardrobeView on macOS ─────────────── */

.wardrobe-stack {
  padding: 12px 16px 12px 104px;
  gap: 10px;
}

.wardrobe-head {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
}

.wardrobe-title {
  font: 600 12px var(--font);
  color: var(--ink);
  flex: 0 0 auto;
}

.wardrobe-note {
  margin-left: auto;
  font: 400 11px var(--font);
  color: var(--dim-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wardrobe-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.wardrobe-item {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 7px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  display: grid;
  place-items: center;
  cursor: default;
  transition: background 0.12s ease-out, border-color 0.12s ease-out;
}

.wardrobe-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.wardrobe-item.on {
  border-color: rgba(255, 255, 255, 0.4);
}

.wardrobe-item canvas {
  width: 28px;
  height: 28px;
  pointer-events: none;
}

/* ── New version (views/update.ts) — UpdateCardView on macOS ────────────────── */

.update-line {
  font-size: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* The download's progress: the Mac's green, 260 px at most. */
.update-bar {
  width: 100%;
  max-width: 260px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}

.update-bar .fill {
  height: 100%;
  width: 0;
  background: #34d399;
  transition: width 0.25s linear;
}

/* ── What's new after an update (views/whatsnew.ts) ─────────────────────────
   Text from x = 116 like the other cards; the items in two columns, each an
   icon in the update's blue, a title and its line. */

.whatsnew-stack {
  padding: 4px 16px 4px 116px;
  gap: 7px;
}

.whatsnew-items {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
}

.whatsnew-item {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  min-width: 0;
}

.whatsnew-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.18);
}

.whatsnew-text {
  min-width: 0;
}

.whatsnew-item-title {
  font: 600 12px var(--font);
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.whatsnew-item-detail {
  font: 400 10.5px/1.3 var(--font);
  color: var(--dim-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.whatsnew-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
}

.whatsnew-stat {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  white-space: nowrap;
}

.whatsnew-stat-icon {
  color: #93c5fd;
  padding-top: 4px;
}

.whatsnew-stat .v {
  font: 700 16px var(--font);
  color: var(--ink-2);
}

.whatsnew-stat .l {
  font: 400 9px var(--font);
  color: var(--dim-2);
}

.whatsnew-thanks {
  font-size: 11.5px;
}

/* ── Spotify: the pill's controls and the now-playing card ──────────────────
   SpotifyPill, MusicControlButton and SpotifyCardView (SpotifyViews.swift,
   NowPlayingViews.swift): sizes and colours are the Mac's. */

.np-pill .lbl {
  transition: padding 0.2s cubic-bezier(0.3, 1.2, 0.4, 1);
}

.np-pill.controls .lbl {
  padding: 0 52px 0 34px;
}

.np-pill-controls {
  position: absolute;
  right: 4px;
  top: 50%;
  display: flex;
  gap: 2px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-50%) scale(0.85);
  transform-origin: right center;
  transition: opacity 0.18s, transform 0.2s cubic-bezier(0.3, 1.2, 0.4, 1);
}

.np-pill.controls .np-pill-controls {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(-50%) scale(1);
}

.np-pill-btn {
  width: 20px;
  height: 20px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid transparent;
  background: var(--card-flat);
  color: var(--dim-3);
  display: grid;
  place-items: center;
  cursor: default;
  transition: transform 0.2s cubic-bezier(0.3, 1.2, 0.4, 1), background 0.18s, border-color 0.18s,
    box-shadow 0.18s, color 0.18s;
}

.np-pill-btn:hover {
  transform: scale(1.1);
}

.np-root {
  height: 100%;
}

.np-card {
  padding: 10px 12px 0 108px;
  display: flex;
  flex-direction: column;
}

.np-head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding-right: 24px;
  min-width: 0;
}

.np-art {
  position: relative;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  overflow: hidden;
  cursor: default;
}

.np-art::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.np-art img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.25s ease-in-out;
}

.np-art.has-art img {
  opacity: 1;
}

.np-art.has-art svg {
  opacity: 0;
}

.np-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1 1 auto;
}

.np-title-row {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.np-title,
.np-sub {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.np-title {
  font: 600 12px var(--font);
  color: var(--ink);
}

.np-sub {
  font: 400 11px var(--font);
  color: var(--dim-2);
}

.np-progress {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-top: 7px;
  font: 400 9.5px var(--font);
  font-variant-numeric: tabular-nums;
  color: var(--dim-3);
}

.np-time.elapsed {
  min-width: 26px;
  text-align: right;
}

.np-time.remaining {
  min-width: 28px;
  text-align: left;
}

.np-bar {
  position: relative;
  flex: 1 1 auto;
  height: 10px;
  touch-action: none;
  cursor: default;
}

.np-track,
.np-fill {
  position: absolute;
  left: 0;
  top: 50%;
  height: 3px;
  transform: translateY(-50%);
  border-radius: 999px;
}

.np-track {
  width: 100%;
  background: rgba(255, 255, 255, 0.12);
}

.np-bar.active .np-track,
.np-bar.active .np-fill {
  height: 4px;
}

.np-knob {
  position: absolute;
  top: 50%;
  width: 9px;
  height: 9px;
  margin-top: -4.5px;
  border-radius: 50%;
  background: var(--ink);
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transition: opacity 0.12s ease-out;
}

.np-bar.active .np-knob {
  opacity: 1;
}

.np-controls {
  display: flex;
  align-items: center;
  padding-top: 4px;
}

.np-controls .grow {
  min-width: 8px;
}

.np-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
}

.np-icon,
.np-play {
  padding: 0;
  border: 0;
  display: grid;
  place-items: center;
  cursor: default;
  transition: transform 0.2s cubic-bezier(0.3, 1.2, 0.4, 1), filter 0.12s ease-out;
}

.np-icon {
  width: 16px;
  height: 18px;
  background: transparent;
}

.np-icon:hover {
  filter: brightness(1.3);
}

.np-play {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--card-flat);
}

.np-icon:active,
.np-play:active {
  transform: scale(0.9);
}

.np-volume {
  display: flex;
  align-items: center;
  gap: 5px;
}

.np-vol-icon {
  width: 13px;
  display: flex;
  justify-content: flex-end;
  color: var(--dim-3);
}

.np-volume .np-bar {
  flex: 0 0 44px;
  width: 44px;
}

/* ── WhatsApp (views/whatsapp.ts) — WhatsAppCardView on macOS ────────────────
   Nothing here applies to a view that already ships: every class is the card's own. */

.wa-card {
  height: 100%;
  box-sizing: border-box;
  padding-top: 10px;
}

.wa-list,
.wa-convo {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}

.wa-unread {
  font: 600 10px var(--font);
  color: #25d366;
  font-variant-numeric: tabular-nums;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(37, 211, 102, 0.14);
}

.wa-empty {
  font: 400 11px var(--font);
  color: var(--dim-3);
  padding: 8px 0 0 8px;
}

.wa-status-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.wa-settings {
  color: var(--dim-2);
  padding: 0;
}

.wa-rows {
  overflow-y: auto;
  min-height: 0;
  padding-right: 12px;
  scrollbar-width: none;
}

.wa-row {
  border: 0;
  background: transparent;
  text-align: start;
  width: 100%;
  gap: 6px;
  padding: 3px 6px;
  cursor: default;
  flex: 0 0 auto;
}

.wa-row:hover {
  background: rgba(255, 255, 255, 0.05);
}

.wa-row.unread {
  background: rgba(37, 211, 102, 0.08);
}

.wa-row.unread:hover {
  background: rgba(37, 211, 102, 0.14);
}

.wa-row-name {
  max-width: 92px;
  flex: 0 1 auto;
}

.wa-row.unread .wa-row-name {
  font-weight: 600;
  color: #e8e9ec;
}

.wa-row.unread .wa-preview {
  color: var(--dim-2);
}

.wa-spacer {
  flex: 1 1 0;
}

.wa-count {
  font: 700 9px var(--font);
  color: #0b0c0e;
  background: #25d366;
  border-radius: 999px;
  padding: 1px 5px;
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
}

.wa-ignore {
  color: #f4505e;
  padding: 0;
  flex: 0 0 auto;
}

.wa-avatar {
  flex: 0 0 auto;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(37, 211, 102, 0.22);
  color: #25d366;
  font-family: var(--font);
  font-weight: 700;
  line-height: 1;
}

.wa-head {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding-right: 36px;
  margin-left: -6px;
}

.wa-back {
  width: 20px;
  height: 20px;
}

.wa-name {
  font: 600 11px var(--font);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.wa-messages {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 4px 12px 4px 0;
  scrollbar-width: none;
}

.wa-line {
  display: flex;
  padding-right: 40px;
}

.wa-line.mine {
  justify-content: flex-end;
  padding-right: 0;
  padding-left: 40px;
}

.wa-bubble {
  padding: 3px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  min-width: 0;
  user-select: text;
}

.wa-bubble.mine {
  background: rgba(37, 211, 102, 0.16);
}

.wa-sender {
  font: 600 9px var(--font);
  color: rgba(37, 211, 102, 0.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wa-media {
  font: 500 10px var(--font);
  color: #9398a1;
}

.wa-text {
  font: 400 10.5px/1.35 var(--font);
  color: #c5c8cd;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.wa-bubble.mine .wa-text {
  color: #e8e9ec;
}

.wa-reply {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  padding: 4px 8px;
  margin-right: 12px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.06);
  flex: 0 0 auto;
}

.wa-field {
  flex: 1 1 auto;
  min-width: 0;
  resize: none;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--ink);
  font: 400 11px/1.35 var(--font);
  max-height: 44px;
  padding: 1px 0;
  field-sizing: content;
}

.wa-field::placeholder {
  color: var(--dim-3);
}

.wa-send {
  width: 16px;
  height: 16px;
  border: 0;
  border-radius: 50%;
  background: rgba(37, 211, 102, 0.3);
  display: grid;
  place-items: center;
  cursor: default;
  flex: 0 0 auto;
}

.wa-send.ready {
  background: #25d366;
}

.wa-note {
  font: 400 9.5px var(--font);
  min-height: 0;
  padding: 2px 0 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wa-note.warn {
  color: #f5b83d;
}

.wa-note.err {
  color: #f4505e;
}

html[data-dir="rtl"] #views :is(.wa-text, .wa-field, .wa-preview) {
  unicode-bidi: plaintext;
  text-align: start;
}

/* ── Arabic: right to left ─────────────────────────────────────────────────────
   i18n.ts sets <html data-dir="rtl">. The text of the cards reads and aligns
   right to left; Mochi, the pills, the header and the cards themselves keep
   their places, and code, commands and the contribution grid stay left to
   right. A chat message follows its own text's direction (an English answer
   stays left to right). */
html[data-dir="rtl"] #views :is(.stack, .int-card, .plan-card, .drop-body, .up-card) {
  direction: rtl;
}

html[data-dir="rtl"] #views :is(.code, .gh-grid, .diff-card, .md-pre) {
  direction: ltr;
}

html[data-dir="rtl"] #views :is(.np-title, .np-sub) {
  unicode-bidi: plaintext;
  text-align: start;
}

html[data-dir="rtl"] #views :is(.bubble, .reply .md-p, .reply .md-h, .reply .md-item, .reply .md-quote, .chat-input) {
  unicode-bidi: plaintext;
  text-align: start;
}

/* ── Mail (classic Outlook) — MailViews.swift ─────────────────────────────── */
.mail-card {
  height: 100%;
  box-sizing: border-box;
}

.mail-list,
.mail-detail {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}

.mail-card.detail-open .mail-list,
.mail-card:not(.detail-open) .mail-detail {
  display: none;
}

.mail-head {
  padding-right: 36px;
}

.mail-unread {
  font: 600 10px var(--font);
  color: #2f8cff;
  font-variant-numeric: tabular-nums;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(47, 140, 255, 0.14);
  white-space: nowrap;
  flex: 0 0 auto;
}

.mail-spacer {
  flex: 1 1 0;
}

.mail-icon {
  border: 0;
  background: transparent;
  color: #8e939c;
  width: 18px;
  height: 16px;
  display: grid;
  place-items: center;
  cursor: default;
  flex: 0 0 auto;
}

.mail-icon:hover {
  color: var(--ink);
}

.mail-search {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: 400 11px var(--font);
  color: #e8e9ec;
}

.mail-filters {
  display: flex;
  align-items: center;
  gap: 3px;
  padding-top: 4px;
  /* One line whatever the language: a longer set scrolls sideways, never wraps. */
  overflow-x: auto;
  scrollbar-width: none;
}

.mail-filters::-webkit-scrollbar {
  display: none;
}

.mail-chip {
  border: 0;
  border-radius: 999px;
  padding: 2px 6px;
  background: transparent;
  white-space: nowrap;
  flex: 0 0 auto;
  font: 400 9.5px var(--font);
  color: #6b7079;
  cursor: default;
}

.mail-chip:hover {
  color: #b0b5be;
  background: rgba(255, 255, 255, 0.06);
}

.mail-chip.on {
  font-weight: 600;
  color: #e8e9ec;
  background: rgba(47, 140, 255, 0.22);
}

/* A search in progress, in the header: the filters keep their line. */
.mail-spinner {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1.5px solid rgba(142, 147, 156, 0.35);
  border-top-color: #8e939c;
  animation: mail-spin 0.8s linear infinite;
}

@keyframes mail-spin {
  to {
    transform: rotate(360deg);
  }
}

.mail-rows {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 5px 12px 6px 0;
  overflow-y: auto;
  min-height: 0;
  scrollbar-width: none;
}

.mail-row {
  border: 0;
  background: transparent;
  text-align: start;
  width: 100%;
  cursor: default;
  flex: 0 0 auto;
}

.mail-row:hover {
  background: rgba(255, 255, 255, 0.05);
}

.mail-row.unread {
  background: rgba(47, 140, 255, 0.08);
}

.mail-row.unread:hover {
  background: rgba(47, 140, 255, 0.14);
}

.mail-row.unread .mail-name {
  font-weight: 600;
  color: #e8e9ec;
}

.mail-row.unread .mail-subject {
  color: #8e939c;
}

.mail-name {
  max-width: 82px;
  flex: 0 1 auto;
}

.mail-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  border: 1px solid #4d5159;
  box-sizing: border-box;
  flex: 0 0 auto;
}

.mail-dot.on {
  border: 0;
  background: #2f8cff;
}

.mail-flag {
  font-size: 8px;
  color: #f5a524;
  flex: 0 0 auto;
}

.mail-empty {
  font: 400 11px var(--font);
  color: var(--dim-3);
  padding: 8px 0 0 8px;
}

.mail-more {
  color: rgba(47, 140, 255, 0.9);
  align-self: flex-start;
  padding: 3px 8px;
}

.mail-detail {
  gap: 4px;
  padding-right: 12px;
}

.mail-detail-head {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding-right: 24px;
  margin-left: -6px;
}

.mail-back {
  width: 20px;
  height: 20px;
}

.mail-from {
  font: 600 11px var(--font);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.mail-detail-subject {
  font: 500 11px var(--font);
  color: #c5c8cd;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mail-detail-text {
  font: 400 10.5px var(--font);
  color: #9398a1;
  height: 28px;
  overflow-y: auto;
  white-space: pre-wrap;
  user-select: text;
  scrollbar-width: none;
}

.mail-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mail-actions .link-btn {
  padding: 0;
  color: #c5c8cd;
}

.mail-actions .link-btn.accent {
  color: rgba(47, 140, 255, 0.9);
}

.mail-actions .link-btn.amber {
  color: rgba(245, 165, 36, 0.9);
}

.mail-actions .link-btn.dim {
  color: #8e939c;
}

.mail-dots-wrap {
  position: relative;
}

.mail-more-menu {
  display: none;
  position: absolute;
  bottom: 18px;
  right: 0;
  flex-direction: column;
  background: #1d1f23;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 4px;
  z-index: 5;
  white-space: nowrap;
}

.mail-more-menu.on {
  display: flex;
}

.mail-more-menu button {
  border: 0;
  background: transparent;
  text-align: start;
  font: 400 11px var(--font);
  color: #e8e9ec;
  padding: 4px 8px;
  border-radius: 5px;
  cursor: default;
}

.mail-more-menu button:hover {
  background: rgba(47, 140, 255, 0.3);
}

/* The chat's Mail switch and a plan's card (MailAgentViews.swift). */
.model-row {
  gap: 6px;
}

.mail-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  font: 500 10.5px var(--font);
  color: #7b8089;
  cursor: default;
}

.mail-toggle.on {
  background: rgba(47, 140, 255, 0.85);
  color: #fff;
}

.plan-card {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 7px 9px;
  border-radius: 8px;
  background: rgba(47, 140, 255, 0.08);
  border: 1px solid rgba(47, 140, 255, 0.25);
}

.plan-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font: 600 11.5px var(--font);
  color: #f1f2f4;
}

.plan-icon {
  font-style: normal;
  color: #2f8cff;
}

.plan-line {
  display: flex;
  gap: 5px;
  font: 400 10.5px var(--font);
  color: #c5c8cd;
}

.plan-arrow {
  color: #2f8cff;
}

.plan-rows {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 90px;
  overflow-y: auto;
  scrollbar-width: none;
}

.plan-row {
  display: flex;
  gap: 6px;
  font: 400 10px var(--font);
  min-width: 0;
}

.plan-to {
  width: 150px;
  flex: 0 0 auto;
  color: #c5c8cd;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.plan-row.bad .plan-to,
.plan-problem {
  color: #f4505e;
}

.plan-subject {
  flex: 1 1 auto;
  min-width: 0;
  color: #8e939c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.plan-file {
  max-width: 150px;
  color: #8e939c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.plan-note {
  font: 400 10px var(--font);
  color: #f5a524;
}

.plan-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 2px;
}

.plan-btn {
  border: 0;
  border-radius: 999px;
  padding: 4px 9px;
  font: 600 10.5px var(--font);
  color: #c5c8cd;
  background: rgba(255, 255, 255, 0.08);
  cursor: default;
}

.plan-btn.primary {
  color: #fff;
  background: #2f8cff;
}

.plan-status {
  font: 400 10.5px var(--font);
  color: #8e939c;
  font-variant-numeric: tabular-nums;
}

.plan-status.ok {
  color: #34d399;
}

.plan-status.amber {
  color: #f5a524;
  font-weight: 600;
}

.plan-bar {
  width: 140px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.plan-bar i {
  display: block;
  height: 100%;
}