/* Engines & accounts (item #3777, views/accounts.js). Per-view stylesheet,
   the routed-view convention: loaded from index.html after mission.css so
   it inherits the entry's token palette. Everything here is .mm-accounts /
   .mm-acc-*; the meter rows the cards draw are chat.css's .mm-acct-*
   (components/usage.js's limitStack), the state dot is .mm-cx-dot from
   sessions.css. Tokens only — no colour here is not one of the entry's
   own, so both themes follow the app. */

.mm-accounts {
  display: flex; flex-direction: column; height: 100%; min-height: 0;
}

/* -- the header: back · title · Add account pinned right ------------------- */
.mm-acc-head {
  display: flex; align-items: center; gap: 10px; flex: none;
  height: 48px; padding: 0 16px 0 12px; box-sizing: border-box;
  border-bottom: 1px solid var(--border-soft); background: var(--panel);
}
.mm-acc-back {
  flex: none; width: 28px; height: 28px; border: 0; border-radius: 6px;
  background: none; color: var(--text-dim); font: inherit; font-size: 20px;
  line-height: 1; cursor: pointer;
}
.mm-acc-back:hover { background: var(--panel-2); color: var(--text); }
.mm-acc-title { flex: 1; margin: 0; font-size: 15px; font-weight: 600; }
.mm-acc-add { flex: none; }

/* -- the body ---------------------------------------------------------------- */
.mm-acc-body {
  flex: 1; min-height: 0; overflow: auto; padding: 18px 22px 28px;
  display: flex; flex-direction: column; gap: 16px; align-items: center;
}
.mm-acc-body > * { width: 100%; max-width: 680px; }
.mm-acc-empty { color: var(--text-dim); font-size: 12.5px; padding: 6px 2px; }

/* -- one engine ---------------------------------------------------------------- */
.mm-acc-engine { display: flex; flex-direction: column; gap: 8px; }
.mm-acc-engine-head {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 2px 0; font-size: 11px; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-dim);
}
.mm-acc-engine-name { font-weight: 650; }
.mm-acc-engine-state, .mm-acc-engine-meta { letter-spacing: 0; text-transform: none; }
.mm-acc-engine-state { color: var(--warn); }
.mm-acc-engine-state.ok { color: var(--ok); }
.mm-acc-engine-head .btn { margin-left: auto; letter-spacing: 0; text-transform: none; }

/* -- one account ---------------------------------------------------------------- */
.mm-acc-card {
  display: flex; flex-direction: column; gap: 10px;
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 10px; padding: 12px 14px;
}
.mm-acc-card.off { border-color: var(--border); }
.mm-acc-card-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mm-acc-card-who { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mm-acc-card-name {
  display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 13px;
}
.mm-acc-card-name > span:first-child {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mm-acc-chip {
  flex: none; font-size: 10px; color: var(--text-dim);
  border: 1px solid var(--border); border-radius: 5px; padding: 1px 6px;
}
.mm-acc-card-sub {
  font-size: 11px; color: var(--text-dim);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mm-acc-card-row .mm-acct-meters { flex: none; width: 200px; }
.mm-acc-card-row .mm-acct-line { font-size: 10.5px; }
.mm-acc-card-row .mm-acct-reset { display: none; }
.mm-acc-card-row .mm-acct-label { min-width: 60px; max-width: 50%; }

/* The signed-out block: the host's own line, the bare command, Copy,
   Open Terminal (the default account only), the paste note. */
.mm-acc-signin {
  display: flex; flex-direction: column; gap: 6px;
  border-top: 1px solid var(--border-soft); padding-top: 10px;
}
.mm-acc-signin-lead { font-size: 11.5px; color: var(--muted); }
.mm-acc-signin-fix { font-size: 11.5px; color: var(--warn); }
.mm-acc-signin-cmd {
  display: block; font-family: var(--mono); font-size: 10.5px; color: var(--accent-ink);
  background: var(--bg); border: 1px solid var(--border-soft); border-radius: 7px;
  padding: 8px 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mm-acc-signin-actions { display: flex; gap: 8px; }
.mm-acc-signin-note { font-size: 11px; color: var(--text-dim); }

/* -- the footer: the hint, Re-check ----------------------------------------------- */
.mm-acc-foot { display: flex; align-items: center; gap: 12px; }
.mm-acc-hint { flex: 1; font-size: 11px; color: var(--text-dim); }
.mm-acc-recheck { flex: none; }

/* -- the honest browser notice ----------------------------------------------------- */
.mm-acc-notice {
  max-width: 560px; margin: 60px auto; text-align: center;
  color: var(--text-dim); font-size: 13.5px;
}
.mm-acc-download {
  display: inline-block; margin-top: 10px; color: var(--accent);
  text-decoration: none; font-size: 13px;
}
.mm-acc-download:hover { text-decoration: underline; }
