/* bd-extras.css (built 29-30 Sep 2026). Styles for bd-extras.js only.
   Uses the inbox's own --bd-* tokens so light and dark both follow. */

/* ── list bar: Home / Settings ─────────────────────────────────────────── */
body.bd-im .bdx-nav { display: flex; gap: 12px; align-items: center; }
body.bd-im .bdx-nav a {
  color: var(--bd-blue); text-decoration: none; font-size: 14px; font-weight: 500;
  white-space: nowrap;
}

/* ── panel tabs ────────────────────────────────────────────────────────── */
body.bd-im .bdx-tabs {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px;
  margin: 10px 16px 6px; padding: 2px; border-radius: 9px; background: var(--bd-sunk);
  position: sticky; top: 45px; z-index: 2;
}
body.bd-im .bdx-tabs button {
  border: 0; background: transparent; color: var(--fg); font: inherit; font-size: 13px;
  font-weight: 500; padding: 6px 0; border-radius: 7px; cursor: pointer;
}
body.bd-im .bdx-tabs button.bdx-on {
  background: var(--bd-pane); box-shadow: 0 1px 3px rgba(0,0,0,.18); font-weight: 600;
}
body.bd-im .bd-info:not([data-bdx-tab="details"]) > .card-header,
body.bd-im .bd-info:not([data-bdx-tab="details"]) > .photo-row,
body.bd-im .bd-info:not([data-bdx-tab="details"]) > .bd-cust,
body.bd-im .bd-info:not([data-bdx-tab="details"]) > .bdx-card { display: none; }
body.bd-im .bd-info > .bdx-pane { display: none; }
body.bd-im .bd-info[data-bdx-tab="activity"] > .bdx-pane[data-p="activity"],
body.bd-im .bd-info[data-bdx-tab="overview"] > .bdx-pane[data-p="overview"],
body.bd-im .bd-info[data-bdx-tab="tasks"] > .bdx-pane[data-p="tasks"] { display: block; }
body.bd-im .bdx-pad { padding: 12px 16px; }

/* ── contact card ──────────────────────────────────────────────────────── */
body.bd-im .bdx-sechead { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
body.bd-im .bdx-saved { font-size: 11.5px; color: var(--bd-mute); }
body.bd-im .bdx-f { display: block; margin: 0 0 10px; }
body.bd-im .bdx-f > span {
  display: block; font-size: 12px; color: var(--bd-mute); margin-bottom: 4px; font-weight: 500;
}
body.bd-im .bdx-f input[type=text], body.bd-im .bdx-f input[type=email],
body.bd-im .bdx-f input[type=tel], body.bd-im .bdx-f input[type=date],
body.bd-im .bdx-f select, body.bd-im .bdx-f textarea,
body.bd-im .bdx-newtask input {
  width: 100%; box-sizing: border-box; background: var(--bd-sunk); color: var(--fg);
  border: .5px solid transparent; border-radius: 10px; padding: 8px 11px;
  font: inherit; font-size: 14px; outline: none; min-height: 36px;
  -webkit-appearance: none; appearance: none;
}
body.bd-im .bdx-f select {
  background-image: linear-gradient(45deg, transparent 50%, var(--bd-mute) 50%),
    linear-gradient(135deg, var(--bd-mute) 50%, transparent 50%);
  background-position: calc(100% - 16px) 50%, calc(100% - 11px) 50%;
  background-size: 5px 5px; background-repeat: no-repeat; padding-right: 28px;
}
body.bd-im .bdx-f textarea { resize: vertical; min-height: 60px; line-height: 1.4; }
body.bd-im .bdx-f input:focus, body.bd-im .bdx-f select:focus, body.bd-im .bdx-f textarea:focus,
body.bd-im .bdx-newtask input:focus { border-color: var(--bd-blue); }
body.bd-im .bdx-ro { font-size: 14px; padding: 8px 11px; border-radius: 10px; background: var(--bd-sunk); color: var(--fg); }
body.bd-im .bdx-row { display: flex; gap: 8px; align-items: center; }
body.bd-im .bdx-row input { flex: 1 1 auto; min-width: 0; }
body.bd-im .bdx-phone { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; flex-wrap: wrap; }
body.bd-im .bdx-phone input[type=tel] { flex: 1 1 150px; min-width: 0; width: auto; }
body.bd-im .bdx-chk { display: inline-flex; gap: 6px; align-items: center; font-size: 12.5px; color: var(--fg); cursor: pointer; }
body.bd-im .bdx-chk input { accent-color: var(--bd-blue); width: 16px; height: 16px; margin: 0; }
body.bd-im .bdx-rm, body.bd-im .bdx-tag button {
  border: 0; background: none; color: var(--bd-mute); font-size: 18px; line-height: 1; cursor: pointer; padding: 0 4px;
}
body.bd-im .bdx-mini {
  border: 0; background: none; color: var(--bd-blue); font: inherit; font-size: 13px;
  cursor: pointer; padding: 4px 0; white-space: nowrap;
}
body.bd-im .bdx-row .bdx-mini {
  padding: 8px 12px; border-radius: 10px; background: var(--bd-sunk); font-weight: 600;
}
body.bd-im .bdx-order { margin-top: 8px; }
body.bd-im .bdx-actions { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
body.bd-im .bdx-btn {
  border: 0; border-radius: 999px; background: var(--bd-blue); color: #fff; font: inherit;
  font-size: 14px; font-weight: 600; padding: 8px 16px; cursor: pointer;
}
body.bd-im .bdx-btn[disabled] { opacity: .55; cursor: default; }
body.bd-im .bdx-msg { font-size: 12.5px; color: var(--bd-mute); }
body.bd-im .bdx-err { color: var(--bd-red); font-size: 13px; margin: 8px 0 0; }

/* tags, shared by the card and the thread row */
body.bd-im .bdx-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
body.bd-im .bdx-tag {
  display: inline-flex; align-items: center; gap: 2px; font-size: 12.5px; font-weight: 500;
  padding: 3px 4px 3px 10px; border-radius: 999px;
  background: color-mix(in srgb, var(--bd-blue) 16%, transparent); color: var(--bd-blue);
}
body.bd-im .bdx-tag button { color: inherit; font-size: 15px; }
body.bd-im .bdx-tagadd input {
  border: .5px dashed var(--bd-sep); background: transparent; color: var(--fg);
  border-radius: 999px; padding: 4px 10px; font: inherit; font-size: 12.5px; width: 92px; outline: none;
}
body.bd-im .bdx-tagadd input:focus { border-color: var(--bd-blue); border-style: solid; width: 140px; }
body.bd-im .bdx-ttags {
  order: 0; display: flex; align-items: center; gap: 10px; padding: 7px 16px;
  border-bottom: .5px solid var(--bd-sep); background: var(--bd-bar);
}
body.bd-im .bdx-tlabel {
  font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--bd-mute);
}

/* ── activity feed ─────────────────────────────────────────────────────── */
body.bd-im .bdx-feed { list-style: none; margin: 0; padding: 12px 16px; }
body.bd-im .bdx-ev { display: flex; gap: 12px; padding: 0 0 14px; position: relative; }
body.bd-im .bdx-ev::before {
  content: ''; position: absolute; left: 4px; top: 12px; bottom: 0; width: 1px; background: var(--bd-sep);
}
body.bd-im .bdx-ev:last-child::before { display: none; }
body.bd-im .bdx-ev > i {
  flex: 0 0 9px; height: 9px; border-radius: 50%; margin-top: 4px; background: var(--bd-mute2);
}
body.bd-im .bdx-send > i { background: #30D158; }
body.bd-im .bdx-fail > i { background: var(--bd-red); }
body.bd-im .bdx-ai > i, body.bd-im .bdx-edit > i { background: var(--bd-blue); }
body.bd-im .bdx-done > i { background: #30D158; }
body.bd-im .bdx-ev b { font-size: 14px; font-weight: 600; display: block; }
body.bd-im .bdx-ev time { font-size: 12px; color: var(--bd-mute); }
body.bd-im .bdx-ev p {
  margin: 5px 0 0; font-size: 13px; color: var(--bd-mute); line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}

/* ── overview ──────────────────────────────────────────────────────────── */
body.bd-im .bdx-sum {
  font-size: 14px; line-height: 1.55; background: var(--bd-sunk); border-radius: 12px;
  padding: 12px 14px; margin-top: 4px;
}

/* ── tasks ─────────────────────────────────────────────────────────────── */
body.bd-im .bdx-tasks { list-style: none; margin: 6px 0 12px; padding: 0; }
body.bd-im .bdx-tasks li { padding: 9px 0; border-bottom: .5px solid var(--bd-sep); }
body.bd-im .bdx-tasks li > span { display: block; font-size: 12px; color: var(--bd-mute); margin: 3px 0 0 22px; }
body.bd-im .bdx-tasks li p { margin: 4px 0 0 22px; font-size: 13px; color: var(--bd-mute); }
body.bd-im .bdx-tasks li.bdx-done b { text-decoration: line-through; color: var(--bd-mute); }
body.bd-im .bdx-newtask { display: grid; gap: 8px; margin-top: 10px; }
body.bd-im .bdx-foot { margin-top: 12px; font-size: 12px; }

/* buttons never wrap to two lines (Add task was folding at 1440 with the panel open) */
body.bd-im .bdx-btn { white-space: nowrap; flex: 0 0 auto; }

body.bd-im [data-x="lookup"]{display:none!important}
body.bd-im .bd-list .bd-bar{justify-content:space-between}body.bd-im .bd-list .bd-bar-c{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);flex:none;width:auto;max-width:40%;white-space:nowrap;pointer-events:none}
body.bd-im .ib-top .tabs button.on{box-shadow:none!important}
