/* STATION #7 / AGENT B #1 — Gizzy's second assistant (its own HQ tab) */
main.ab { max-width: 1100px; display: grid; grid-template-columns: 230px 1fr; gap: 16px; padding: 12px 16px; }
@media (max-width: 760px) { main.ab { grid-template-columns: 1fr; padding: 10px 12px; } } /* STATION #45: on the phone the chats slide in from ☰ (below) */
.ab-side { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ab-side h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 4px 0; }
.ab-convs { display: flex; flex-direction: column; gap: 4px; max-height: 60vh; overflow: auto; }
.ab-conv { text-align: left; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: var(--text); font: 14px/1.3 inherit; font-family: inherit; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ab-conv[aria-current="true"] { background: var(--panel); border-color: var(--gold-dim); }
.ab-conv small { display: block; color: var(--muted); font-size: 12px; }
.ab-new { padding: 9px 12px; border-radius: 10px; border: 1px solid var(--gold-dim); background: transparent; color: var(--gold); font: 700 14px/1 inherit; font-family: inherit; cursor: pointer; }
.ab-meter { font-size: 13px; color: var(--muted); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.ab-meter b { color: var(--text); font-variant-numeric: tabular-nums; }
.ab-meter .over { color: var(--down); font-weight: 700; }
.ab-main { display: flex; flex-direction: column; min-width: 0; min-height: 70vh; }
.ab-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.ab-head h1 { font-size: 18px; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ab-status { font-size: 13px; color: var(--muted); }
.ab-status.work::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); margin-right: 6px; animation: abblink 1s infinite; }
@keyframes abblink { 50% { opacity: .25; } }
.ab-stop { padding: 8px 14px; border-radius: 10px; border: 1px solid var(--down); background: transparent; color: var(--down); font: 700 14px/1 inherit; font-family: inherit; cursor: pointer; }
.ab-thread { flex: 1; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; padding: 4px 0 12px; }
.ab-msg { max-width: 92%; padding: 10px 12px; border-radius: 14px; white-space: pre-wrap; word-wrap: break-word; line-height: 1.45; }
.ab-msg.gizzy { align-self: flex-end; background: #1f4a33; }
.ab-msg.agent { align-self: flex-start; background: var(--panel); border: 1px solid var(--line); }
.ab-msg.note { align-self: center; color: var(--muted); font-size: 13px; background: none; }
.ab-msg .who { display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 2px; }
.ab-msg .ask { margin-top: 6px; background: none; border: 0; color: var(--gold); font: 600 12px/1 inherit; font-family: inherit; cursor: pointer; padding: 0; }
.ab-pair { align-self: stretch; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 760px) { .ab-pair { grid-template-columns: 1fr; } }
.ab-pair .ab-msg { max-width: none; }
.ab-msg.melissa { background: #2a2a1a; border: 1px solid var(--gold-dim); }
.ab-preview { align-self: stretch; border: 2px solid var(--gold); border-radius: 14px; padding: 10px 12px; background: rgba(232, 197, 90, .06); }
.ab-preview h3 { margin: 0 0 4px; font-size: 15px; }
.ab-preview pre { margin: 6px 0; max-height: 220px; overflow: auto; font-size: 12px; white-space: pre-wrap; color: var(--muted); }
.ab-preview .btns { display: flex; gap: 10px; margin-top: 6px; }
.ab-yes { padding: 10px 18px; border-radius: 10px; border: 0; background: var(--gold); color: #1b291f; font: 800 15px/1 inherit; font-family: inherit; cursor: pointer; }
.ab-no { padding: 10px 18px; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: var(--text); font: 700 15px/1 inherit; font-family: inherit; cursor: pointer; }
.ab-preview.done { border-color: var(--line); opacity: .8; }
.ab-acts { font-size: 12.5px; color: var(--muted); border-left: 2px solid var(--line); padding: 2px 0 2px 10px; display: flex; flex-direction: column; gap: 2px; }
.ab-acts summary { cursor: pointer; }
.ab-compose { position: sticky; bottom: 0; display: flex; gap: 8px; padding: 10px 0 calc(10px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) 80%, transparent); }
.ab-compose textarea { flex: 1; min-height: 46px; max-height: 40vh; resize: vertical; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); color: var(--text); padding: 10px 12px; font: 15px/1.4 inherit; font-family: inherit; }
.ab-compose button { padding: 0 18px; border-radius: 12px; border: 0; background: var(--gold); color: #1b291f; font: 800 15px/1 inherit; font-family: inherit; cursor: pointer; }
.ab-compose button:disabled { opacity: .5; }
.ab-lines { font-size: 12px; color: var(--muted); margin: 0 0 6px; }
.ab-news { display: flex; flex-direction: column; gap: 6px; }
@media (max-width: 480px) { .hq-top { gap: 8px; } .hq-top .hq-nav { flex-wrap: wrap; justify-content: flex-end; gap: 6px 12px; white-space: normal; } .hq-brand span { display: none; } }

/* STATION #15 voice: one 🎙 tap → hands-free */
.ab-compose .ab-mic { padding: 0 14px; background: var(--panel); color: var(--text); border: 1px solid var(--line); font-size: 20px; }
.ab-compose .ab-mic.on { background: var(--down, #c0392b); color: #fff; border-color: transparent; animation: abPulse 1.6s ease-in-out infinite; }
@keyframes abPulse { 50% { opacity: .75; } }
.ab-voice { position: sticky; bottom: 70px; margin: 0 0 6px; padding: 8px 12px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); font: 600 14px/1.3 inherit; font-family: inherit; }
/* STATION #21 his files: a real download button under his answer (big enough to tap on the phone) */
.ab-files { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.ab-dl { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 8px 14px; border-radius: 10px; background: var(--gold); color: #1b291f; font-weight: 800; text-decoration: none; max-width: 100%; overflow-wrap: anywhere; }
.ab-dl:active { opacity: .85; }
.ab-open { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--gold-dim); color: var(--gold); text-decoration: none; }
/* STATION #23 his job's banner */
.ab-work { margin: 0 0 10px; padding: 10px 12px; border-radius: 10px; background: var(--panel); border: 1px solid var(--gold-dim); }
.ab-work summary { cursor: pointer; font-weight: 700; color: var(--gold); }
.ab-work.done summary { color: var(--up); } .ab-work.stuck summary, .ab-work.needs_gizzy summary { color: var(--down); }
.ab-work ol { margin: 8px 0 0; padding-left: 20px; } .ab-work li.done { opacity: .75; }

/* STATION #25 Melissa · CEO handing work to a Cody */
.ab-msg.ceo { background: rgba(212, 175, 55, 0.12); border-left: 4px solid var(--gold, #d4af37); }
.ab-msg.ceo .who { color: var(--gold, #d4af37); }
/* STATION #28 delete / restore a chat */
.ab-row { display: flex; gap: 4px; align-items: stretch; }
.ab-row .ab-conv { flex: 1; min-width: 0; }
.ab-del, .ab-undo { flex: none; border: 1px solid var(--line); background: transparent; color: var(--muted); border-radius: 10px; padding: 0 10px; font: 14px inherit; cursor: pointer; }
.ab-del:hover { color: var(--text); border-color: var(--gold-dim); }
.ab-gone summary { cursor: pointer; color: var(--muted); font-size: 13px; padding: 6px 2px; }
.ab-dead { opacity: .7; cursor: default; }

/* STATION #45 one panel for every agent, each its own color: groups fold up; the open chat's department colors the chat area + the top bar */
.dc-ceo, body[data-dept="ceo"] { --dc: #e3b341; --dc-ink: #1b1608; --dc-tint: rgba(227, 179, 65, .10); }
.dc-agent_b, body[data-dept="agent_b"] { --dc: #4c9be8; --dc-ink: #07182a; --dc-tint: rgba(76, 155, 232, .10); }
.dc-accounting, body[data-dept="accounting"] { --dc: #2fbf71; --dc-ink: #062214; --dc-tint: rgba(47, 191, 113, .10); }
.dc-jamaica, body[data-dept="jamaica"] { --dc: #22c3c3; --dc-ink: #052323; --dc-tint: rgba(34, 195, 195, .10); }
.dc-fk_global, body[data-dept="fk_global"] { --dc: #b583e6; --dc-ink: #1d0d2c; --dc-tint: rgba(181, 131, 230, .10); }
.dc-sales_ops, body[data-dept="sales_ops"] { --dc: #f07f3c; --dc-ink: #2a1205; --dc-tint: rgba(240, 127, 60, .10); }
.dc-shipping, body[data-dept="shipping"] { --dc: #8d6e4f; --dc-ink: #1f140a; --dc-tint: rgba(141, 110, 79, .10); } /* STATION #76 Cody · Shipping */
.ab-tools { display: flex; flex-direction: column; gap: 6px; }
.ab-tools input { width: 100%; box-sizing: border-box; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); color: var(--text); font: 14px/1.3 inherit; font-family: inherit; }
.ab-news[hidden] { display: none; }
.ab-news .ab-new { border-color: var(--dc, var(--gold-dim)); color: var(--dc, var(--gold)); text-align: left; }
.ab-convs { max-height: calc(100vh - 260px); gap: 8px; }
.ab-group { display: flex; flex-direction: column; gap: 4px; border-left: 3px solid var(--dc); padding-left: 6px; }
.ab-gh { display: flex; align-items: baseline; gap: 6px; width: 100%; text-align: left; padding: 6px 4px; border: 0; background: none; color: var(--dc); font: 700 13px/1.2 inherit; font-family: inherit; cursor: pointer; }
.ab-gh small { color: var(--muted); font-weight: 600; white-space: nowrap; } .ab-gh .ab-caret { margin-left: auto; color: var(--muted); }
.ab-group .ab-conv { position: relative; }
.ab-group .ab-conv[aria-current="true"] { background: var(--dc-tint); border-color: var(--dc); }
.ab-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--dc); margin-right: 6px; vertical-align: middle; }
.ab-m { font-weight: 700; } .ab-m.work { color: var(--dc); } .ab-m.sub, .ab-m.ask { color: var(--gold); } .ab-m.ok { color: var(--up); }
body[data-dept] .hq-top { border-bottom: 2px solid var(--dc); }
body[data-dept] .ab-head { border-bottom: 2px solid var(--dc); padding-bottom: 6px; }
body[data-dept] .ab-head h1 { color: var(--dc); }
body[data-dept] .ab-msg.agent { border-left: 4px solid var(--dc); }
body[data-dept] .ab-msg.agent .who { color: var(--dc); }
body[data-dept] .ab-compose button:not(.ab-mic) { background: var(--dc); color: var(--dc-ink); }
body[data-dept] .ab-compose .ab-mic:not(.on) { border-color: var(--dc); }
.ab-menu { display: none; flex: none; padding: 6px 10px; border-radius: 10px; border: 1px solid var(--dc, var(--line)); background: transparent; color: var(--text); font: 18px/1 inherit; cursor: pointer; }
.ab-scrim { display: none; }
@media (max-width: 760px) {
  .ab-menu { display: inline-block; }
  .ab-head h1 { flex: 1; min-width: 0; }
  .ab-side { position: fixed; top: 0; left: 0; bottom: 0; z-index: 60; width: min(86vw, 330px); box-sizing: border-box; padding: 14px 12px calc(14px + env(safe-area-inset-bottom)); background: var(--bg); border-right: 2px solid var(--dc, var(--line)); overflow-y: auto; transform: translateX(-105%); transition: transform .2s ease; }
  .side-open .ab-side { transform: none; }
  .side-open .ab-scrim { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(0, 0, 0, .55); }
  .ab-convs { max-height: none; overflow: visible; }
}
/* STATION #59 the phone (Gizzy, Android 412 px: "Agent chats — still got that screen"): no tab strip (the one panel has every agent; ← Home
   and 🆘 stay), and the chat list is a full sheet in the bullseye's look — its colors (light / dark), big rounded rows, each agent's color */
@media (max-width: 760px) {
  .hq-top .hq-nav { flex-wrap: nowrap; justify-content: flex-end; }
  .hq-top .hq-nav > a:not([href="/home"]) { display: none; }
  .hq-top .hq-nav > a[href="/home"] { font-weight: 700; }
  .ab-side { --sb-bg: #f2f6ef; --sb-ink: #14301f; --sb-muted: #5d6f62; --sb-card: #ffffff; --sb-line: #d9e3d6; --sb-shadow: 0 4px 14px rgba(20, 48, 31, .10);
    width: calc(100vw - 44px); background: var(--sb-bg); color: var(--sb-ink); border-right: 0; font: 17px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; padding-top: max(16px, env(safe-area-inset-top)); gap: 12px; }
  .ab-side h2 { color: var(--sb-muted); }
  .ab-side .ab-tools input { background: var(--sb-card); color: var(--sb-ink); border-color: var(--sb-line); border-radius: 999px; padding: 12px 16px; font-size: 16px; }
  .ab-side .ab-new-btn { border-radius: 999px; padding: 12px 16px; font-size: 16px; }
  .ab-side .ab-meter { border-color: var(--sb-line); background: var(--sb-card); color: var(--sb-muted); border-radius: 14px; }
  .ab-side .ab-meter b { color: var(--sb-ink); }
  .ab-side .ab-group { border-left: 0; padding-left: 0; gap: 8px; }
  .ab-side .ab-gh { font-size: 15px; padding: 8px 2px 2px; color: var(--sb-ink); }
  .ab-side .ab-new-btn { background: #1f7a46; color: #ffffff; border: 0; font-weight: 700; }
  .ab-side .ab-row > button:not(.ab-conv) { background: var(--sb-card); border: 1px solid var(--sb-line); color: var(--sb-muted); border-radius: 14px; }
  .ab-side .ab-gh small { color: var(--sb-muted); }
  .ab-side .ab-conv { background: var(--sb-card); color: var(--sb-ink); border: 1px solid var(--sb-line); border-left: 6px solid var(--dc, var(--sb-line)); border-radius: 16px; padding: 14px 14px; font-size: 16px; box-shadow: var(--sb-shadow); }
  .ab-side .ab-conv small { color: var(--sb-muted); font-size: 13px; }
  .ab-side .ab-group .ab-conv[aria-current="true"] { background: var(--sb-card); outline: 2px solid var(--dc); }
}
@media (max-width: 760px) and (prefers-color-scheme: dark) {
  .ab-side { --sb-bg: #0d1611; --sb-ink: #e8efe9; --sb-muted: #9db0a3; --sb-card: #16231b; --sb-line: #26382c; --sb-shadow: 0 4px 14px rgba(0, 0, 0, .40); }
  .ab-side .ab-gh { color: var(--dc); }
  .ab-side .ab-new-btn { background: #36b36b; color: #06140b; }
}
