/* Publish, Accounts and Updates tabs and the notifications drawer (js/tabs/publish.js, accounts.js, updates.js, drawer.js) */

/* --- Publish */
.pb { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 39%) minmax(0, 1fr); gap: 12px; margin-top: 6px; }
.pb-left { display: flex; flex-direction: column; gap: 12px; min-height: 0; }
.pb-files { flex: 1; display: flex; flex-direction: column; min-height: 0; padding: 8px 10px; }
.pb-list { flex: 1; min-height: 0; margin-top: 6px; }
.pb-item { padding: 1px 8px 2px; cursor: pointer; }
.pb-item:hover { background: #141922; }
.pb-item.sel { background: #1d5e3d; }
.pb-name { color: var(--green); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pb-item.todo .pb-name { color: var(--bright); }
.pb-item.sel .pb-name { color: var(--bright); }
.pb-tick { display: inline-block; width: 10px; }
.pb-sub { padding-left: 18px; white-space: nowrap; overflow: hidden; }
.pb-sub b { margin-left: 8px; }
.pb-sub b.off { color: #3a4049; }
.pb-best { flex-shrink: 0; display: flex; flex-direction: column; gap: 1px; padding: 8px 10px; }
.pb-best .pb-bline:first-of-type { margin-top: 3px; }
.pb-bline { display: grid; grid-template-columns: 44px 84px 48px 70px minmax(0, 1fr); gap: 8px; white-space: nowrap; cursor: default; }
.pb-bline:hover { background: #141922; }
.pb-bline b:nth-child(3) { text-align: right; color: var(--bright); }
.pb-bline .text { color: var(--text); }

.pb-form { display: flex; flex-direction: column; gap: 5px; padding: 10px 14px 8px; min-height: 0; min-width: 0; }
.pb-form .rf-input { padding: 7px 12px; flex-shrink: 0; }
.pb-form > .rf-label { margin-top: 2px; }
.pb-preview { flex-shrink: 0; margin-top: 6px; padding: 6px 10px; }
.pb-lines { display: grid; grid-template-columns: 92px minmax(0, 1fr); column-gap: 6px; row-gap: 1px; margin-top: 2px; }
.pb-text { white-space: normal; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
.pb-posted { margin-top: 2px; flex-shrink: 0; }
.pb-btns { display: flex; gap: 6px; flex-shrink: 0; align-items: stretch; }
.pb-btns .rf-btn { padding: 7px 10px; }
.pb-btns .rf-btn.big { padding: 9px 16px; min-width: 0; }
.pb-copy .rf-btn { padding: 4px 9px; }
.pb-uploads { flex: 1; min-height: 0; display: flex; flex-direction: column; margin-top: 6px; }
.pb-utable { flex: 1; min-height: 0; }
.pb-utable .rf-table td:last-child { color: var(--text); }

/* --- Accounts */
.ac { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) minmax(0, 1fr); gap: 20px 14px; padding-top: 8px; }
.ac-box { display: flex; flex-direction: column; padding: 10px 14px 6px; min-height: 0; }
/* the platform class colours the border and title; the text inside stays the normal colour */
.rf .ac-box { color: var(--text); }
.ac-btns { display: flex; gap: 8px; margin: 8px 0 8px; flex-shrink: 0; }
.ac-btns .rf-btn { padding: 8px 16px; min-width: 96px; }
.ac-btns .rf-btn.on { min-width: 120px; }
.ac-note { white-space: normal; flex-shrink: 0; margin-bottom: 8px; }
.ac-fhead { flex-shrink: 0; }
.ac-chart { flex: 1; min-height: 0; margin-top: 2px; }

/* --- Updates */
.up-top { flex-shrink: 0; margin-top: 8px; padding: 10px 14px 12px; }
.up-btns { display: flex; gap: 8px; margin-top: 12px; }
.up-btns .rf-btn { padding: 10px 18px; min-width: 120px; text-decoration: none; }
.up-btns .rf-btn.on { color: var(--muted); }
.up-notes { flex: 1; min-height: 0; margin-top: 8px; padding: 10px 6px 10px 14px; }
.up-scroll { height: 100%; overflow-y: auto; padding-right: 14px; }
.up-head { font-weight: 700; margin-bottom: 4px; }
.up-notes p { margin: 0 0 12px; white-space: normal; }
.up-notes ul { margin: 0 0 12px; padding-left: 18px; }
.up-notes li { margin: 0 0 4px; white-space: normal; }
.up-notes li::marker { color: var(--text); }
.up-link { color: var(--green); text-decoration: underline; text-underline-offset: 3px; font-weight: 700; }
.up-link:hover { color: #7dffbd; }
.up-hr { height: 0; border-top: 2px solid var(--blue); opacity: .7; margin: 18px 0; }
.up-table { width: 100%; border-collapse: collapse; margin-bottom: 4px; }
.up-table th { text-align: left; color: var(--green); font-weight: 700; padding: 6px 10px; border: 1px solid var(--border); }
.up-table td { padding: 6px 10px; border: 1px solid var(--border); vertical-align: top; white-space: normal; word-break: break-word; }
.up-table td:first-child { width: 150px; }
.up-table td:nth-child(2) { width: 220px; }
.up-foot { flex-shrink: 0; color: var(--muted); }

/* --- the notifications drawer */
.dr-head { flex-shrink: 0; }
.dr-head .rf-btn { padding: 2px 10px; }
.dr-list { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 6px; padding-right: 2px; }
.dr-card { display: grid; grid-template-columns: 22px minmax(0, 1fr) 34px; gap: 8px; padding: 8px 4px 8px 8px; background: var(--panel); border-left: 3px solid transparent; cursor: pointer; flex-shrink: 0; transition: opacity 200ms, transform 200ms; }
.dr-card:hover { background: var(--panel-2); }
.dr-card.unread { border-left-color: var(--green); }
.dr-card.out { opacity: 0; transform: translateX(30px); }
.dr-icon { font-weight: 700; font-size: 15px; text-align: center; }
.dr-text { min-width: 0; }
.dr-title { color: var(--bright); font-weight: 700; white-space: normal; }
.dr-body { color: var(--muted); white-space: normal; }
.dr-time { color: var(--dim); font-size: 12px; }
.dr-dot { color: var(--red); margin-left: 8px; font-size: 10px; }
.dr-x { font-size: 26px; line-height: 28px; height: 30px; color: #6e7681; text-align: center; align-self: center; cursor: pointer; border-radius: 3px; }
.dr-x:hover { color: var(--red); background: rgba(255, 77, 94, .15); }
.dr-empty { padding: 18px 6px; white-space: normal; }
