/* Chat (2 Dec 2026): laid out like Facebook Messenger, which the office already
   uses. One sheet for the dock, the page, the phone and Today's Notes tab, because
   one renderer draws all four (public/js/officechat.js). */

.oc-launch { gap: 7px; }
.oc-launch.open { background: var(--blue); }
.oc-launch-n {
  min-width: 19px; height: 19px; padding: 0 5px; border-radius: 999px; background: #ef4444; color: #fff;
  font-size: 11.5px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center;
}
.oc-launch-n[hidden] { display: none; }

/* ---- Avatars ---- */
.oc-av { position: relative; display: inline-flex; flex: none; }
.oc-av .avatar { width: 28px; height: 28px; font-size: 11px; }
.oc-av.lg .avatar { width: 40px; height: 40px; font-size: 14px; }
.oc-av .avatar.xs, .oc-seen .avatar, .oc-typing .avatar { width: 16px; height: 16px; font-size: 8px; }
.oc-on { position: absolute; right: -1px; bottom: -1px; width: 10px; height: 10px; border-radius: 50%; background: #22c55e; border: 2px solid #fff; }
.oc-av-self, .oc-av-office { width: 28px; height: 28px; border-radius: 50%; align-items: center; justify-content: center; color: #fff; }
.oc-av-self { background: #7c3aed; }
.oc-av-office { background: var(--navy); }
.oc-av-self.lg, .oc-av-office.lg { width: 40px; height: 40px; }
.oc-av-self svg, .oc-av-office svg { width: 15px; height: 15px; }
.oc-av-group { width: 28px; height: 28px; }
.oc-av-group .avatar { position: absolute; width: 19px; height: 19px; font-size: 8px; border: 2px solid #fff; }
.oc-av-group .avatar:first-child { left: 0; top: 0; }
.oc-av-group .avatar:nth-child(2) { right: 0; bottom: 0; }
.oc-av-group.lg { width: 40px; height: 40px; }
.oc-av-group.lg .avatar { width: 27px; height: 27px; font-size: 10px; }

/* ---- The list ---- */
.oc-pop-head { display: flex; align-items: center; gap: 4px; padding: 12px 14px 6px; }
.oc-pop-head h2, .oc-pop-head h3 { flex: 1; font-size: 22px; font-weight: 800; }
.oc-pop-head h3 { font-size: 20px; }
.oc-pop-head .icon-btn.on { background: #e0e7ff; color: var(--blue); }
.oc-search { margin: 4px 14px 8px; width: calc(100% - 28px); height: 36px; border: none; border-radius: 999px;
  background: #f0f2f5; padding: 0 14px; font-size: 14.5px; outline: none; }
.oc-filters { display: flex; gap: 6px; padding: 0 14px 8px; flex-wrap: wrap; }
.oc-filters button { border: none; background: #f0f2f5; color: var(--text); border-radius: 999px; padding: 6px 12px; font-weight: 600; font-size: 13.5px; }
.oc-filters button.on { background: #e7f0ff; color: var(--blue); }
.oc-list { overflow-y: auto; padding: 0 6px 8px; }
.oc-sec { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 10px 10px 4px; }
.oc-li { position: relative; display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.oc-li:hover, .oc-li:focus-visible { background: #f2f2f2; outline: none; }
.oc-li.on { background: #e7f0ff; }
.oc-li-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.oc-li-name { font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-li-last { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-li.unread .oc-li-name, .oc-li.unread .oc-li-last { font-weight: 700; color: var(--text); }
.oc-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--blue); flex: none; }
.oc-askpill { flex: none; background: #fef3c7; color: #92400e; font-weight: 800; font-size: 11.5px; border-radius: 999px; padding: 2px 7px; }
.oc-pinned svg { width: 13px; height: 13px; color: #f59e0b; fill: #f59e0b; }
.oc-li-pin { display: none; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 1px solid var(--border);
  background: #fff; border-radius: 50%; width: 30px; height: 30px; align-items: center; justify-content: center; color: var(--muted); }
.oc-li:hover .oc-li-pin { display: inline-flex; }
.oc-li:hover .oc-pinned, .oc-li:hover .oc-dot { visibility: hidden; }
.oc-hits { display: flex; flex-direction: column; gap: 2px; padding: 0 4px; }
.oc-hit { text-align: left; border: none; background: none; padding: 8px 10px; border-radius: 10px; display: flex; flex-direction: column; gap: 2px; }
.oc-hit:hover { background: #f2f2f2; }
.oc-hit-text { font-size: 13px; color: var(--text); }
.oc-hit mark { background: #fde68a; border-radius: 2px; }
.oc-empty { padding: 18px; text-align: center; font-size: 13.5px; }

/* ---- The popover above the Chat button ---- */
#oc-dock[hidden] { display: none; }
.oc-pop {
  position: fixed; right: 20px; bottom: 74px; z-index: 160; width: 360px; max-width: calc(100vw - 32px);
  height: min(560px, calc(100vh - 110px)); display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 18px 48px rgba(15, 23, 42, .28);
}
.oc-pop .oc-list { flex: 1; }

/* ---- Windows along the bottom ---- */
.oc-wins { position: fixed; right: 150px; bottom: 0; z-index: 155; display: flex; align-items: flex-end; gap: 10px; pointer-events: none; }
.oc-win { pointer-events: auto; width: 338px; height: 455px; max-height: calc(100vh - 80px); background: #fff;
  border-radius: 10px 10px 0 0; box-shadow: 0 10px 34px rgba(15, 23, 42, .3); display: flex; flex-direction: column; overflow: hidden; }
.oc-win.min { height: 44px; width: 220px; flex-direction: row; align-items: center; gap: 8px; padding: 0 8px; cursor: pointer; }
.oc-min-t { flex: 1; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-min-t.unread { font-weight: 800; color: var(--blue); }
.oc-toast-slot { position: fixed; right: 20px; bottom: 74px; z-index: 158; }
.oc-toast { display: flex; gap: 10px; align-items: flex-start; text-align: left; max-width: 320px; background: #fff;
  border: 1px solid var(--border); border-radius: 14px; padding: 10px 12px; box-shadow: 0 12px 34px rgba(15, 23, 42, .25);
  animation: oc-pop-in .18s ease-out; }
.oc-toast > span { display: flex; flex-direction: column; font-size: 13px; gap: 2px; }
@keyframes oc-pop-in { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---- A conversation ---- */
.oc-thread { display: flex; flex-direction: column; min-height: 0; background: #fff; position: relative; }
.oc-thread.oc-drop::after { content: 'Drop to attach'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(37, 99, 235, .08); border: 2px dashed var(--blue); font-weight: 700; color: var(--blue); z-index: 5; }
.oc-head { display: flex; align-items: center; gap: 9px; padding: 8px 8px 8px 12px; border-bottom: 1px solid var(--border); box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.oc-head-t { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.oc-head-t b { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-head-btns { display: flex; gap: 2px; }
.oc-head-btns .icon-btn { color: var(--blue); }
.oc-head-btns .icon-btn.on svg { fill: #f59e0b; color: #f59e0b; }
.oc-msgs { flex: 1; overflow-y: auto; padding: 10px 10px 4px; display: flex; flex-direction: column; gap: 2px; }
.oc-day { text-align: center; font-size: 11.5px; color: var(--muted); margin: 12px 0 6px; font-weight: 600; }
.oc-sys { text-align: center; font-size: 12px; color: var(--muted); margin: 6px 0; }
.oc-older { align-self: center; margin-bottom: 6px; }

.oc-row { display: flex; align-items: flex-end; gap: 6px; }
.oc-row.run-end { margin-bottom: 6px; }
.oc-row.mine { justify-content: flex-end; }
.oc-row-av { width: 28px; flex: none; }
.oc-col { display: flex; flex-direction: column; max-width: 74%; min-width: 0; }
.oc-row.mine .oc-col { align-items: flex-end; }
.oc-from { font-size: 12px; color: var(--muted); margin: 6px 12px 2px; }
.oc-bubble-wrap { display: flex; align-items: center; gap: 4px; }
.oc-row.mine .oc-bubble-wrap { flex-direction: row-reverse; }
.oc-bubble { background: #f0f2f5; color: var(--text); border-radius: 18px; padding: 8px 12px; font-size: 14.5px; line-height: 1.38;
  overflow-wrap: anywhere; min-width: 0; }
.oc-row.mine .oc-bubble { background: var(--blue); color: #fff; }
.oc-row.mine .oc-bubble a { color: #fff; text-decoration: underline; }
.oc-bubble.is-ask { box-shadow: 0 0 0 2px #f59e0b; }
.oc-bubble.is-gone { background: none; border: 1px solid var(--border); color: var(--muted); font-style: italic; }
.oc-text + .oc-lead, .oc-text + .oc-img, .oc-text + .oc-doc, .oc-text + .oc-voice, .oc-lead + .oc-lead { margin-top: 6px; }
.oc-img { display: block; margin-top: 4px; }
.oc-img img { display: block; max-width: 230px; max-height: 260px; border-radius: 12px; }
.oc-mode-page .oc-img img { max-width: 360px; max-height: 340px; }
.oc-video { max-width: 260px; border-radius: 12px; display: block; }
.oc-voice { display: flex; align-items: center; gap: 6px; }
.oc-voice svg { display: none; }
.oc-voice audio { height: 36px; max-width: 230px; }
.oc-doc, .oc-lead { display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,.92); color: var(--text) !important;
  text-decoration: none !important; border-radius: 10px; padding: 7px 10px; margin-top: 4px; border: 1px solid var(--border); }
.oc-doc span:first-of-type { flex: 1; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 190px; }
.oc-lead span { display: flex; flex-direction: column; line-height: 1.25; }
.oc-lead svg { color: var(--blue); }
.oc-tools { display: flex; gap: 0; opacity: 0; transition: opacity .1s; }
.oc-row:hover .oc-tools, .oc-note:hover .oc-tools, .oc-tools:focus-within { opacity: 1; }
.oc-tools button { border: none; background: none; width: 28px; height: 28px; border-radius: 50%; color: var(--muted); font-size: 15px;
  display: inline-flex; align-items: center; justify-content: center; }
.oc-tools button:hover { background: #f0f2f5; }
.oc-quote { display: flex; flex-direction: column; font-size: 12px; color: var(--muted); margin: 4px 0 -8px; cursor: pointer; }
.oc-quote-who { display: flex; align-items: center; gap: 4px; padding: 0 12px; }
.oc-quote-who svg { width: 12px; height: 12px; transform: rotate(-90deg); }
.oc-quote-text { background: #f6f7f9; border-radius: 16px; padding: 7px 12px 14px; color: #65676b; max-width: 100%;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
.oc-row.mine .oc-quote { align-items: flex-end; }
.oc-reacts { display: flex; gap: 2px; margin-top: -6px; z-index: 1; background: #fff; border-radius: 999px; padding: 1px 5px;
  box-shadow: 0 1px 3px rgba(0,0,0,.18); font-size: 12.5px; align-self: flex-start; }
.oc-row.mine .oc-reacts { align-self: flex-end; }
.oc-ask { display: flex; align-items: center; gap: 6px; font-size: 12px; color: #92400e; margin-top: 3px; }
.oc-ask svg { width: 13px; height: 13px; }
.oc-ask.done { color: var(--green); }
.oc-link { border: none; background: none; color: var(--muted); text-decoration: underline; font-size: 12px; padding: 0; }
.oc-edited { font-size: 11px; color: var(--muted); margin: 1px 12px 0; }
.oc-seen { align-self: flex-end; display: flex; gap: 2px; margin: 2px 4px 4px; }
.oc-flash .oc-bubble, .oc-flash.oc-note { animation: oc-flash 1.6s ease-out; }
@keyframes oc-flash { 0%, 40% { box-shadow: 0 0 0 3px #fbbf24; } 100% { box-shadow: none; } }
.oc-typing { min-height: 0; display: flex; align-items: center; gap: 6px; padding: 0 14px; }
.oc-typing:not(:empty) { min-height: 22px; padding-bottom: 4px; }
.oc-dots { display: inline-flex; gap: 3px; background: #f0f2f5; border-radius: 999px; padding: 6px 9px; }
.oc-dots i { width: 6px; height: 6px; border-radius: 50%; background: #8a8d91; animation: oc-bounce 1.2s infinite; }
.oc-dots i:nth-child(2) { animation-delay: .15s; }
.oc-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes oc-bounce { 0%, 60%, 100% { transform: none; opacity: .5; } 30% { transform: translateY(-3px); opacity: 1; } }

/* ---- Notes (your own chat) ---- */
.oc-note { display: flex; align-items: flex-start; gap: 10px; padding: 9px 10px; border: 1px solid var(--border); border-radius: 12px;
  background: #fff; margin-bottom: 6px; }
.oc-note.is-pinned { border-color: #fcd34d; background: #fffbeb; }
.oc-note.is-done .oc-text { text-decoration: line-through; color: var(--muted); }
.oc-tick input { width: 17px; height: 17px; margin-top: 2px; cursor: pointer; }
.oc-note-body { flex: 1; min-width: 0; font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.oc-note-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 4px; }
.oc-pinmark { display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; color: #b45309; font-weight: 700; }
.oc-pinmark svg { width: 12px; height: 12px; fill: #f59e0b; color: #f59e0b; }
.oc-tag { font-size: 11.5px; background: #ede9fe; color: #5b21b6; border-radius: 999px; padding: 1px 8px; cursor: pointer; }
.oc-notes-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.oc-notes-q { height: 34px; border: 1px solid var(--border); border-radius: 999px; padding: 0 12px; min-width: 200px; flex: 1 1 200px; }
.oc-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.oc-tagbtn { border: 1px solid var(--border); background: #fff; border-radius: 999px; padding: 3px 10px; font-size: 12.5px; }
.oc-tagbtn.on { background: #7c3aed; border-color: #7c3aed; color: #fff; }
.oc-done-fold summary { cursor: pointer; color: var(--muted); font-weight: 600; margin: 8px 0; }

/* ---- The composer ---- */
.oc-compose { position: relative; padding: 6px 10px 8px; border-top: 1px solid var(--border); }
.oc-mode-notes .oc-compose { border-top: none; border: 1px solid var(--border); border-radius: 12px; margin-bottom: 12px; }
.oc-row-in { display: flex; align-items: flex-end; gap: 6px; }
.oc-input { flex: 1; resize: none; border: none; outline: none; background: #f0f2f5; border-radius: 18px; padding: 9px 14px;
  font-size: 14.5px; line-height: 1.35; max-height: 160px; min-height: 38px; }
.oc-send { width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--blue); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; flex: none; }
.oc-send svg { width: 17px; height: 17px; }
.oc-toolrow { display: flex; align-items: center; gap: 2px; margin-top: 4px; flex-wrap: wrap; }
.oc-tool { border: none; background: none; color: var(--blue); height: 30px; min-width: 30px; border-radius: 15px;
  display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 0 6px; font-size: 12.5px; font-weight: 600; }
.oc-tool:hover { background: #f0f2f5; }
.oc-tool.on { background: #fef3c7; color: #92400e; }
.oc-tool span { display: none; }
.oc-tool.on span, .oc-mode-page .oc-tool span { display: inline; }
.oc-hint { margin-left: auto; }
.oc-mode-dock .oc-hint { display: none; }
.oc-replying { display: flex; align-items: center; gap: 6px; font-size: 12.5px; padding: 2px 0 6px; overflow: hidden; white-space: nowrap; }
.oc-replying .muted { overflow: hidden; text-overflow: ellipsis; flex: 1; }
.oc-pend { display: flex; flex-wrap: wrap; gap: 5px; }
.oc-pend:not(:empty) { padding-bottom: 6px; }
.oc-chip { display: inline-flex; align-items: center; gap: 5px; background: #f0f2f5; border-radius: 999px; padding: 3px 4px 3px 9px; font-size: 12.5px; max-width: 100%; }
.oc-chip img { width: 22px; height: 22px; object-fit: cover; border-radius: 4px; }
.oc-chip.busy { opacity: .6; }
.oc-chip button { border: none; background: #fff; width: 20px; height: 20px; border-radius: 50%; line-height: 1; }
.oc-at { position: absolute; left: 10px; right: 10px; bottom: 100%; background: #fff; border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .2); max-height: 260px; overflow-y: auto; z-index: 6; }
.oc-at button { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; border: none; background: none; padding: 8px 10px; }
.oc-at button:hover, .oc-at button.on { background: #f0f2f5; }
.oc-rec { display: flex; align-items: center; gap: 8px; padding-top: 6px; }
.oc-rec[hidden] { display: none; }
.oc-recdot { width: 10px; height: 10px; border-radius: 50%; background: #ef4444; animation: oc-bounce 1s infinite; }
.oc-rectime { font-variant-numeric: tabular-nums; font-weight: 700; }
.oc-readonly { padding: 10px 14px; border-top: 1px solid var(--border); }

.oc-menu { position: fixed; z-index: 10001; background: #fff; border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 12px 34px rgba(15, 23, 42, .25); padding: 4px; display: flex; flex-direction: column; min-width: 160px; }
.oc-menu button { border: none; background: none; text-align: left; padding: 8px 12px; border-radius: 7px; font-size: 13.5px; }
.oc-menu button:hover { background: #f0f2f5; }
.oc-pick { display: flex; flex-direction: column; gap: 2px; max-height: 300px; overflow-y: auto; }
.oc-pick-row { display: flex; align-items: center; gap: 8px; padding: 6px 4px; }
.oc-pick-row .btn { margin-left: auto; }
.oc-people { display: flex; flex-direction: column; gap: 2px; max-height: 60vh; overflow-y: auto; }
.oc-person { display: flex; align-items: center; gap: 10px; border: none; background: none; text-align: left; padding: 8px; border-radius: 10px; }
.oc-person:hover { background: #f0f2f5; }
.oc-ld-files { margin-top: 10px; display: flex; flex-direction: column; gap: 4px; max-height: 320px; overflow-y: auto; }
.oc-ld-row { display: flex; align-items: center; gap: 8px; padding: 6px; border-radius: 8px; }
.oc-ld-row:hover { background: #f8fafc; }

/* ---- The Chat page ---- */
.oc-page { display: grid; grid-template-columns: 360px 1fr; height: calc(100vh - 120px); min-height: 480px; background: #fff;
  border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.oc-side { display: flex; flex-direction: column; border-right: 1px solid var(--border); min-height: 0; }
.oc-side .oc-list { flex: 1; }
.oc-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.oc-main.oc-thread { height: 100%; }
.oc-pick-one { margin: auto; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.oc-pick-one svg { width: 42px; height: 42px; color: var(--blue); }

/* On the Chat page the page is the chat: the corner button and the phone's +
   button would only cover the Send button. */
body:has(.oc-page) .oc-launch, body:has(.oc-page) .m-fab { display: none !important; }

/* ---- Today > Notes ---- */
.oc-today-notes { max-width: 860px; }
.oc-notes-intro { margin-bottom: 10px; }
.oc-today-notes .oc-thread { background: transparent; }
.oc-mode-notes .oc-msgs { padding: 0; overflow: visible; }

@media (max-width: 1150px) {
  .oc-wins { right: 140px; }
}
/* Phones: no dock; Chat is a tab, list and conversation are two screens. */
@media (max-width: 860px) {
  #oc-dock { display: none !important; }
  .oc-page { display: flex; flex-direction: column; height: calc(100dvh - 140px); border: none; border-radius: 0; margin: -12px -12px 0; }
  .oc-page .oc-side { border-right: none; flex: 1; }
  .oc-page.has-thread .oc-main { flex: 1; }
  .oc-li { padding: 10px; }
  .oc-li-pin { display: none !important; }
  .oc-input { font-size: 16px; }
  .oc-col { max-width: 82%; }
  .oc-tools { opacity: 1; }
  .oc-tools button { width: 26px; height: 26px; }
  .oc-img img { max-width: 210px; }
  .oc-head { position: sticky; top: 0; background: #fff; z-index: 2; }
}

/* ---- Screenshot + highlight (officechat-markup.js) ---- */
.oc-mk { position: fixed; inset: 0; z-index: 10050; background: rgba(15, 18, 24, 0.92); display: flex; flex-direction: column; }
.oc-mk-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 10px 14px; background: var(--panel, #fff); border-bottom: 1px solid var(--line, #e5e7eb); }
.oc-mk-bar .spacer { flex: 1; }
.oc-mk-tool { border: 1px solid var(--line, #d1d5db); background: transparent; color: inherit; border-radius: 999px; padding: 5px 12px; font: inherit; font-size: 13px; cursor: pointer; }
.oc-mk-tool:hover { background: rgba(0, 0, 0, 0.05); }
.oc-mk-tool.on { background: #1f6feb; border-color: #1f6feb; color: #fff; }
.oc-mk-tool[data-mk="hl"].on { background: #f5c400; border-color: #f5c400; color: #111; }
.oc-mk-tool[data-mk="hide"].on { background: #111; border-color: #111; }
.oc-mk-sep { width: 1px; height: 22px; background: var(--line, #d1d5db); margin: 0 4px; }
.oc-mk-stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 16px; overflow: auto; color: #ddd; }
.oc-mk-canvas { max-width: 100%; max-height: 100%; touch-action: none; box-shadow: 0 6px 30px rgba(0, 0, 0, 0.5); background: #fff; cursor: crosshair; }
.oc-chip button[data-mkfile] { display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.oc-chip button[data-mkfile] svg { width: 13px; height: 13px; }
@media (max-width: 640px) {
  .oc-mk-bar { padding: 8px; gap: 4px; }
  .oc-mk-tool { padding: 5px 9px; font-size: 12px; }
  .oc-mk-stage { padding: 6px; }
}

/* ---- Joining a live call (callconf.js) ---- */
.cc-li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; }
.cc-li .oc-li-t { min-width: 0; flex: 1; }
.cc-li .oc-li-name svg { width: 13px; height: 13px; color: #16a34a; vertical-align: -2px; }
.cc-invite { background: rgba(22, 163, 74, 0.08); }
.cc-modes { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.cc-mode { border: 1px solid var(--line, #d1d5db); background: #fff; color: inherit; border-radius: 999px; padding: 3px 10px; font: inherit; font-size: 12px; cursor: pointer; }
.cc-mode:hover { border-color: #16a34a; }
.cc-mode.on { background: #16a34a; border-color: #16a34a; color: #fff; }
.cc-headbtn { display: inline-flex; align-items: center; gap: 4px; width: auto !important; padding: 0 8px; color: #16a34a; font-size: 12px; font-weight: 600; }
.cc-headbtn svg { width: 15px; height: 15px; }
#cc-bar-slot { position: fixed; top: 10px; left: 50%; transform: translateX(-50%); z-index: 170; max-width: calc(100vw - 20px); }
.cc-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: #fff; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18); border: 1px solid #bbf7d0; font-size: 13px; }
.cc-bar .cc-modes { margin-top: 0; }
.cc-what { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.cc-what .muted { margin-left: 4px; }
.cc-dot { width: 9px; height: 9px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.2); }
.cc-chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 4px 2px 2px; border-radius: 999px; background: #f0fdf4; border: 1px solid #bbf7d0; }
.cc-chip.listen { background: #fefce8; border-color: #fde68a; }
.cc-chip.whisper { background: #eff6ff; border-color: #bfdbfe; }
.cc-chip button { border: none; background: transparent; cursor: pointer; font-size: 15px; line-height: 1; padding: 0 4px; }
@media (max-width: 640px) { #cc-bar-slot { top: auto; bottom: 74px; } }

/* ---- Live screen share (public/js/screenshare.js) ---- */
#ss-slot { position: fixed; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 171; align-items: center; display: flex; flex-direction: column; gap: 8px; max-width: calc(100vw - 32px); }
.ss-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: #fff; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18); border: 1px solid #bfdbfe; font-size: 13px; }
.ss-bar.ss-sharing { border-color: #fecaca; }
.ss-rec { width: 9px; height: 9px; border-radius: 50%; background: #dc2626; box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.2); }
.cc-headbtn.ss-on { color: #1d4ed8; }
#ss-view { position: fixed; inset: 4vh 4vw; z-index: 180; display: flex; flex-direction: column; background: #0f172a; border-radius: 12px; box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45); overflow: hidden; }
#ss-view:fullscreen { inset: 0; border-radius: 0; }
.ss-view-head { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: #fff; }
.ss-grow { flex: 1; }
.ss-view-body { position: relative; flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
.ss-view-body video, .ss-view-body img { max-width: 100%; max-height: 100%; object-fit: contain; }
.ss-view-body video[hidden], .ss-view-body img[hidden] { display: none; }
.ss-view-note { position: absolute; left: 0; right: 0; bottom: 12px; text-align: center; color: #cbd5e1; font-size: 13px; padding: 0 16px; }
.ss-view-note:empty { display: none; }
@media (max-width: 640px) {
  #ss-slot { bottom: 130px; }
  #ss-view { inset: 0; border-radius: 0; }
  .ss-view-head .btn[data-ss="full"] { display: none; }
}

/* ---- Topics (officechat-topics.js) ----
   One row of tabs under the header, scrolling sideways rather than wrapping, so a
   dock window and a phone keep the messages tall. */
.oc-topics:empty { display: none; }
.oc-topics { border-bottom: 1px solid var(--border); background: #fafbfc; }
.oc-tp-row { display: flex; gap: 5px; padding: 6px 8px; overflow-x: auto; scrollbar-width: thin; }
.oc-tp { display: inline-flex; align-items: center; gap: 5px; flex: none; border: 1px solid var(--border); background: #fff;
  border-radius: 999px; padding: 3px 10px; font-size: 12.5px; max-width: 220px; color: inherit; cursor: pointer; }
.oc-tp span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-tp svg { width: 13px; height: 13px; flex: none; }
.oc-tp .oc-hash { color: var(--muted); font-weight: 600; flex: none; }
.oc-tp.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.oc-tp.on .oc-hash { color: #fff; }
.oc-tp.closed { opacity: .65; text-decoration: line-through; }
.oc-tp.closed.on { opacity: 1; text-decoration: none; }
.oc-tp .oc-dot { width: 8px; height: 8px; }
.oc-tp-fold, .oc-tp-add { color: var(--muted); border-style: dashed; }
.oc-tp-add { color: var(--blue); }
.oc-tp-strip { display: flex; align-items: center; gap: 10px; padding: 0 10px 6px; font-size: 12.5px; flex-wrap: wrap; }
.oc-tp-lead { display: inline-flex; align-items: center; gap: 4px; }
.oc-tp-lead svg { width: 13px; height: 13px; }
.oc-tp-offer { border: 1px dashed var(--blue); background: #eef5ff; color: var(--blue); padding: 3px 10px; cursor: pointer; }
.oc-tp-offer svg { width: 13px; height: 13px; }
.oc-hit-topic { font-size: 11.5px; background: #f0f2f5; border-radius: 999px; padding: 1px 7px; }
.oc-leadhead { display: inline-flex; gap: 12px; align-items: center; }
.oc-leadhead .oc-link { color: var(--blue); text-decoration: none; display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; }
.oc-leadhead .oc-link svg { width: 13px; height: 13px; }
.oc-leadhead .oc-dot { width: 8px; height: 8px; }
@media (max-width: 640px) {
  .oc-tp { padding: 5px 12px; font-size: 13.5px; }
}

/* @mentions in notes (public/js/mentions.js) */
.nm-pop { position: fixed; z-index: 10002; background: #fff; border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .2); max-height: 260px; overflow-y: auto; }
.nm-pop button { display: flex; align-items: baseline; gap: 6px; width: 100%; text-align: left; border: none; background: none; padding: 9px 12px; font: inherit; }
.nm-pop button:hover, .nm-pop button.on { background: #e7f0ff; }
.nm-chip { background: #dbeafe; color: #1d4ed8; border-radius: 6px; padding: 0 4px; font-weight: 600; }
.nm-av { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: #dbeafe; color: #1d4ed8; font-weight: 800; font-size: 18px; }
.cm-host { display: flex; flex-direction: column; min-height: 0; }
.cm-list { flex: 1; overflow-y: auto; padding: 10px 14px; display: flex; flex-direction: column; gap: 8px; }
.cm-item { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; background: #fff; }
.cm-item.unread { border-left: 4px solid #2563eb; background: #f5f9ff; }
.cm-top { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: baseline; }
.cm-when { margin-left: auto; }
.cm-text { margin: 6px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
