/* "Входящие" in the approved board concept: toolbar like the task toolbar, notifications as list rows. */
.workspace > .inbox-view { margin: 16px 24px 32px !important; padding: 0 !important; display: grid !important; gap: 16px !important; background: #fff !important; }

.inbox-view .inbox-toolbar { display: flex !important; flex-wrap: wrap !important; align-items: center !important; gap: 12px 18px !important; margin: 0 !important; padding: 0 !important; border: 0 !important; background: transparent !important; box-shadow: none !important; }
.inbox-view .inbox-toolbar-title { display: flex !important; align-items: baseline !important; gap: 10px !important; margin-right: auto !important; }
.inbox-view .inbox-toolbar-title strong { color: #24202c !important; font-size: 16px !important; font-weight: 600 !important; }
.inbox-view .inbox-toolbar-title span { color: #898397 !important; font-size: 14px !important; }
.inbox-view .segmented { display: inline-flex !important; gap: 4px !important; padding: 4px !important; border: 1px solid #ddd7e7 !important; border-radius: 8px !important; background: #fff !important; box-shadow: none !important; }
.inbox-view .segmented button { min-height: 34px !important; padding: 6px 14px !important; border: 0 !important; border-radius: 6px !important; background: transparent !important; box-shadow: none !important; color: #746c84 !important; font-size: 14px !important; font-weight: 450 !important; }
.inbox-view .segmented button.active { background: #eee8ff !important; color: #7047db !important; font-weight: 600 !important; }
.inbox-view .inbox-toolbar > button { min-height: 44px !important; padding: 8px 16px !important; border: 1px solid #ddd7e7 !important; border-radius: 7px !important; background: #fff !important; box-shadow: none !important; color: #514a60 !important; font-size: 14px !important; }
.inbox-view .inbox-toolbar > button:disabled { color: #b4adc0 !important; }

.inbox-view .inbox-stack { display: grid !important; gap: 0 !important; padding: 0 !important; border: 1px solid #eae5f3 !important; border-radius: 8px !important; background: #fff !important; box-shadow: none !important; overflow: hidden !important; }
.inbox-view .inbox-item { display: flex !important; align-items: center !important; gap: 16px !important; margin: 0 !important; padding: 14px 16px 14px 32px !important; border: 0 !important; border-bottom: 1px solid #f0edf5 !important; border-radius: 0 !important; background: #fff !important; box-shadow: none !important; position: relative !important; }
.inbox-view .inbox-item:last-child { border-bottom: 0 !important; }
.inbox-view .inbox-item:hover { background: #faf8fe !important; }
.inbox-view .inbox-item::before { content: '' !important; position: absolute !important; left: 14px !important; top: 21px !important; width: 8px !important; height: 8px !important; border-radius: 50% !important; background: transparent !important; }
.inbox-view .inbox-item.unread::before { background: #7954d6 !important; }
.inbox-view .inbox-item.unread { background: #fcfaff !important; }
.inbox-view .inbox-item > div:first-child { display: grid !important; gap: 4px !important; flex: 1 !important; min-width: 0 !important; }
.inbox-view .inbox-item strong { color: #24202c !important; font-size: 15px !important; font-weight: 600 !important; }
.inbox-view .inbox-item:not(.unread) strong { font-weight: 500 !important; }
.inbox-view .inbox-item p { margin: 0 !important; color: #5f586d !important; font-size: 14px !important; line-height: 1.45 !important; }
.inbox-view .inbox-item small { color: #9990aa !important; font-size: 12px !important; }
.inbox-view .inbox-actions { display: flex !important; gap: 8px !important; flex-shrink: 0 !important; }
.inbox-view .inbox-actions button { min-height: 34px !important; padding: 6px 12px !important; border: 1px solid #ddd7e7 !important; border-radius: 7px !important; background: #fff !important; box-shadow: none !important; color: #514a60 !important; font-size: 13px !important; }
.inbox-view .inbox-actions button[data-open-notification] { color: #7954d6 !important; }
.inbox-view .inbox-actions button:disabled { border-color: transparent !important; color: #b4adc0 !important; }

@media (max-width: 760px) {
  .workspace > .inbox-view { margin: 12px 14px 14px !important; }
  .inbox-view .inbox-toolbar-title { width: 100% !important; }
  .inbox-view .inbox-toolbar { flex-direction: row !important; flex-wrap: wrap !important; align-items: center !important; gap: 10px !important; }
  .inbox-view .segmented { flex: 1 1 auto !important; flex-direction: row !important; flex-wrap: nowrap !important; width: auto !important; margin: 0 !important; }
  .inbox-view .segmented button { flex: 1 1 auto !important; width: auto !important; padding: 6px 10px !important; }
  .inbox-view .inbox-toolbar > button { width: auto !important; flex: 0 0 auto !important; min-height: 44px !important; margin: 0 !important; }
  .inbox-view .inbox-item { flex-direction: column !important; align-items: stretch !important; gap: 10px !important; padding: 12px 12px 12px 28px !important; }
  .inbox-view .inbox-item::before { left: 11px !important; top: 19px !important; }
}

/* Pop-up about a new notification (appears on any page) */
.live-notice { position: fixed; top: 16px; right: 16px; z-index: 120; display: grid; grid-template-columns: 10px minmax(0, 1fr) auto auto; align-items: center; gap: 12px; width: min(420px, calc(100vw - 32px)); padding: 14px 14px 14px 16px; border: 1px solid #e3d9f7; border-radius: 12px; background: #fff; box-shadow: 0 18px 44px #2b20481f, 0 3px 10px #2b204814; font-family: var(--app-font); animation: live-notice-in .22s ease-out; }
.live-notice[hidden] { display: none; }
.live-notice-dot { width: 10px; height: 10px; border-radius: 50%; background: #7954d6; }
.live-notice strong { display: block; color: #24202c; font-size: 14px; font-weight: 600; }
.live-notice p { margin: 2px 0 0; color: #5f586d; font-size: 13px; line-height: 1.4; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.live-notice small { color: #898397; font-size: 12px; }
.live-notice button[data-live-notice-open] { min-height: 34px; padding: 6px 12px; border: 0; border-radius: 7px; background: #7954d6; color: #fff; font: 500 13px var(--app-font); cursor: pointer; }
.live-notice .live-notice-close { width: 28px; height: 28px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: #898397; font-size: 18px; cursor: pointer; }
.live-notice .live-notice-close:hover { background: #f4f1fa; }
@keyframes live-notice-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@media (max-width: 760px) { .live-notice { top: 10px; right: 10px; left: 10px; width: auto; } }
html[data-theme="dark"] .live-notice { border-color: #3d3358; background: #231f2d; }
html[data-theme="dark"] .live-notice strong { color: #ece9f3; }
html[data-theme="dark"] .live-notice p { color: #c4bed2; }
.inbox-view .inbox-toolbar > button.inbox-desktop-toggle { color: #7954d6 !important; }

/* Inbox rows: the whole row opens the task in the pane; «Отметить» shows on hover */
.inbox-view .inbox-stack { border-color: #e8e8eb !important; }
.inbox-view .inbox-item { align-items: flex-start !important; gap: 12px !important; padding: 14px 16px !important; border-bottom-color: #f0f0f2 !important; }
.inbox-view .inbox-item::before { content: none !important; }
.inbox-view .inbox-item.openable { cursor: pointer; }
.inbox-view .inbox-item.unread { background: #fff !important; }
.inbox-view .inbox-item:hover { background: #f8f8f9 !important; }
.inbox-view .inbox-item.active { background: #f3effc !important; box-shadow: inset 3px 0 0 #7954d6 !important; }
.inbox-view .inbox-item:focus-visible { outline: 2px solid #7954d6; outline-offset: -2px; }
.inbox-view .inbox-dot { flex: none; width: 8px; height: 8px; margin-top: 12px; border-radius: 50%; background: transparent; }
.inbox-view .inbox-item.unread .inbox-dot { background: #7954d6; }
.inbox-view .inbox-kind { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #f1eef9; }
.inbox-view .inbox-kind::before { content: ""; width: 16px; height: 16px; background: #6a45cc; -webkit-mask: var(--kind-icon, url("/icons/lucide/check.svg")) center / contain no-repeat; mask: var(--kind-icon, url("/icons/lucide/check.svg")) center / contain no-repeat; }
.inbox-view .inbox-kind.kind-comment, .inbox-view .inbox-kind.kind-mention { --kind-icon: url("/icons/lucide/message-circle.svg"); }
.inbox-view .inbox-kind.kind-assignment { --kind-icon: url("/icons/lucide/user.svg"); }
.inbox-view .inbox-kind.kind-due, .inbox-view .inbox-kind.kind-overdue { --kind-icon: url("/icons/lucide/clock.svg"); background: #fff1e6; }
.inbox-view .inbox-kind.kind-due::before, .inbox-view .inbox-kind.kind-overdue::before { background: #c46a12; }
.inbox-view .inbox-body { display: grid; gap: 3px; flex: 1; min-width: 0; }
.inbox-view .inbox-item strong { font-size: 14px !important; color: #1e1f21 !important; }
.inbox-view .inbox-item p { font-size: 13.5px !important; color: #3d3e40 !important; }
.inbox-view .inbox-item small { color: #6d6e6f !important; }
.inbox-view .inbox-actions button[data-read] { opacity: 0; }
.inbox-view .inbox-item:hover .inbox-actions button[data-read]:not(:disabled), .inbox-view .inbox-actions button[data-read]:focus-visible { opacity: 1; }
@media (hover: none) { .inbox-view .inbox-actions button[data-read]:not(:disabled) { opacity: 1; } }
html[data-theme="dark"] .inbox-view .inbox-item.active { background: var(--d-hover) !important; }
html[data-theme="dark"] .inbox-view .inbox-kind { background: var(--d-surface-2); }
html[data-theme="dark"] .inbox-view .inbox-item strong { color: var(--d-text) !important; }
html[data-theme="dark"] .inbox-view .inbox-item p { color: var(--d-text-2) !important; }
@media (max-width: 760px) {
  .inbox-view .inbox-item { flex-direction: row !important; flex-wrap: wrap !important; align-items: flex-start !important; gap: 10px !important; padding: 12px !important; }
  .inbox-view .inbox-item > .inbox-body { flex: 1 1 calc(100% - 60px) !important; }
  .inbox-view .inbox-item > .inbox-actions { flex: 1 0 100%; justify-content: flex-end; margin: 0 !important; }
  .inbox-view .inbox-item > .inbox-actions:has(button:disabled) { display: none !important; }
  .inbox-view .inbox-dot { margin-top: 12px; }
}
