:root {
  color-scheme: dark;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 500;
  background: #000;
  color: #fff;
  --muted: #a1acb9;
  --line: #33404a;
  --mint: #94f4cf;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; display: grid; place-items: center; }
button, input { font: inherit; }
button { cursor: pointer; color: inherit; }
button:disabled { cursor: default; opacity: .64; }
button:focus-visible, input:focus-visible { outline: 3px solid var(--mint); outline-offset: 4px; }
.display {
  width: min(100%, 600px);
  min-height: min(100vh, 600px);
  padding: clamp(20px, 5.8vw, 38px) clamp(18px, 6.5vw, 44px);
  background: #000;
}
.masthead { display: flex; align-items: center; gap: 16px; }
.mark {
  display: grid;
  grid-template-columns: repeat(2, 7px);
  grid-template-rows: repeat(2, 7px);
  gap: 4px;
  align-content: center;
  justify-content: center;
  width: 45px;
  height: 45px;
  border: 1px solid #2d735d;
  border-radius: 14px;
  background: #0b211a;
  flex: 0 0 auto;
}
.mark span { background: var(--mint); border-radius: 2px; }
.mark span:last-child { opacity: .45; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(38px, 8vw, 52px); letter-spacing: -.055em; line-height: 1; }
#connection { color: var(--muted); font-size: 16px; margin-top: 9px; }
.overview-status { margin: 25px 0 14px; color: #c5cfdb; font-size: 17px; min-height: 1.3em; }
.cards { display: grid; gap: 16px; }
.agent {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  width: 100%;
  gap: clamp(9px, 2vw, 17px);
  text-align: left;
  padding: 18px clamp(12px, 3vw, 20px);
  min-height: 92px;
  background: #11171c;
  border: 1px solid var(--line);
  border-radius: 20px;
}
.agent:focus-visible { background: #122221; }
.agent-icon { display: grid; place-items: center; width: 42px; height: 42px; color: var(--mint); border-radius: 12px; background: #16352a; font-weight: 750; font-size: 23px; }
.grok .agent-icon { color: #d2c5ff; background: #2d2548; }
.agent-info { display: grid; gap: 5px; }
.agent-info strong { font-size: 22px; line-height: 1.08; }
.agent-info span { font-size: 15px; color: #b1bbc6; }
.chevron { color: #b1bbc6; font-size: 26px; }
.state { width: fit-content; font-size: 14px; line-height: 1.1; letter-spacing: .01em; padding: 7px 10px; border-radius: 999px; background: #29333e; color: #e0e9f5; white-space: nowrap; }
.state[data-state="done"], .state[data-state="ready"] { background: #16352a; color: #aff6d8; }
.state[data-state="running"], .state[data-state="starting"] { background: #2f2850; color: #e3d9ff; }
.state[data-state="unknown"], .state[data-state="failed"], .state[data-state="unavailable"] { background: #483419; color: #ffdc9e; }
.keys { color: #a1acb9; font-size: 15px; margin: 25px 1px 0; }
kbd { display: inline-block; min-width: 20px; border: 1px solid #43505c; border-radius: 5px; text-align: center; color: #d8e0e8; font-size: 15px; }
kbd:nth-child(3) { margin-left: 13px; }
.back { margin-top: 20px; padding: 7px 8px; border: 0; border-radius: 6px; background: transparent; color: var(--mint); font-size: 17px; }
.detail-status { border: 1px solid var(--line); border-radius: 17px; background: #11171c; padding: 16px 18px; margin: 13px 0 19px; }
.detail-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
h2 { font-size: 24px; }
#detail-summary, #detail-answer { font-size: 18px; line-height: 1.35; margin-top: 9px; overflow-wrap: anywhere; }
#detail-answer { color: #fff; white-space: pre-wrap; }
#detail-summary:has(+ #detail-answer:not([hidden])) { color: var(--muted); font-size: 15px; }
#detail-time { font-size: 14px; color: var(--muted); margin-top: 8px; }
label { display: block; font-size: 15px; color: #c5cfdb; margin-bottom: 7px; }
input { width: 100%; color: #fff; font-size: 17px; background: #11171c; border: 1px solid #62707c; border-radius: 12px; padding: 11px 13px; }
.action, .secondary { min-height: 46px; padding: 9px 15px; border-radius: 12px; font-weight: 700; font-size: 16px; }
.action { border: 1px solid transparent; background: var(--mint); color: #082017; }
.secondary { border: 1px solid #62707c; background: #121a20; color: #e7edf3; }
.detail-status .secondary { margin-top: 12px; }
.composer-actions { display: flex; gap: 12px; margin-top: 12px; }
.feedback { color: #ffdc9e; font-size: 15px; margin-top: 10px; }
@media (max-width: 400px) {
  .agent { grid-template-columns: auto minmax(0, 1fr) auto; }
  .chevron { display: none; }
  .agent-icon { width: 34px; height: 34px; }
}

.pairing { min-height: auto; }
.pairing > p { margin: 19px 0 24px; font-size: 18px; line-height: 1.45; color: #c5cfdb; }
.pairing > p:empty { margin: 0; }
.pairing .action { margin: 16px 0 0; }
.pairing .secondary { display: block; margin-top: 20px; }
.pair-code { display: block; margin-top: 20px; font: 700 38px/1.1 "Helvetica Neue", Arial, sans-serif; letter-spacing: .08em; }
