/* Today, pings, notifications and the field matrix (ADR-030..032). Plain, like the rest. */

/* Not shown to your role */
.masked {
    color: var(--text-3);
    cursor: help;
    border-bottom: 1px dotted var(--rule-strong);
}

/* The bell */
.app-sidebar__bell {
    margin: 0 var(--space-3) var(--space-2);
    display: flex;
    align-items: center;
    gap: var(--space-2);
    height: 34px;
    padding: 0 10px;
    border-radius: var(--radius-md);
    color: var(--text-2);
    font-size: var(--text-sm);
    text-decoration: none;
}
.app-sidebar__bell:hover { background: rgba(47, 50, 64, 0.06); color: var(--text); }
.app-sidebar__bell .icon { width: 16px; height: 16px; }
.app-topbar__bell { position: relative; text-decoration: none; }
.bell-count {
    margin-left: auto;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: var(--radius-full);
    background: var(--rose-600);
    color: var(--on-ink);
    font-size: var(--text-2xs);
    font-weight: 600;
    line-height: 20px;
    text-align: center;
}
.bell-count[hidden] { display: none; }
.app-topbar__bell .bell-count { position: absolute; top: 2px; right: 0; margin: 0; }

/* The slide-over */
.slide-over { position: fixed; inset: 0; z-index: 80; }
.slide-over[hidden] { display: none; }
.slide-over__scrim { position: absolute; inset: 0; background: rgba(21, 22, 28, 0.28); }
.slide-over__panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(440px, 100vw);
    display: flex;
    flex-direction: column;
    background: var(--paper);
    border-left: 1px solid var(--rule);
    box-shadow: var(--shadow-lg);
    transform: translateX(100%);
    transition: transform var(--dur-slow) var(--ease);
    outline: none;
}
.slide-over.is-open .slide-over__panel { transform: none; }
#slide-over-body { display: flex; flex-direction: column; min-height: 0; height: 100%; }
.slide-over__head {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-4);
    border-bottom: 1px solid var(--rule);
}
.slide-over__title { margin: 0; margin-right: auto; font-size: var(--text-md); }
.slide-over__close {
    width: 32px;
    height: 32px;
    border: 0;
    background: transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
}
.slide-over__close:hover { background: rgba(47, 50, 64, 0.06); }
.slide-over__scroll { flex: 1; overflow-y: auto; padding: var(--space-3) var(--space-4); }
.slide-over__foot {
    display: flex;
    justify-content: space-between;
    padding: var(--space-3) var(--space-4);
    border-top: 1px solid var(--rule);
}
body.has-slide-over { overflow: hidden; }

/* Notification rows */
.note-filters { padding: var(--space-2) var(--space-4); font-size: var(--text-sm); color: var(--text-3); }
.note-filter { color: var(--text-2); text-decoration: none; }
.note-filter.is-active { color: var(--text); font-weight: 600; text-decoration: underline; }
.note-group {
    margin: var(--space-3) 0 var(--space-1);
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.note-list { list-style: none; margin: 0; padding: 0; }
.note-list--page { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius-lg); }
.note-row + .note-row { border-top: 1px solid var(--rule); }
.note-row__link {
    display: flex;
    gap: var(--space-3);
    padding: var(--space-2) var(--space-3);
    color: var(--text);
    text-decoration: none;
}
.note-row__link:hover { background: var(--paper-2); }
.note-row__icon { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--text-3); }
.note-row__main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.note-row__title { font-size: var(--text-sm); }
.note-row--unread .note-row__title { font-weight: 600; }
.note-row__body { font-size: var(--text-xs); color: var(--text-2); }
.note-row__meta { font-size: var(--text-xs); color: var(--text-3); }
.note-row__unread { color: var(--rose-600); }
.note-settings__group { padding: var(--space-3) var(--space-4); margin-bottom: var(--space-4); }
.note-settings__title { margin: 0 0 var(--space-2); font-size: var(--text-md); }
.note-settings__group table { table-layout: fixed; }
.note-settings__group thead th:first-child { width: 55%; }

/* Pings */
.ping-marks { margin: 0 0 var(--space-1); display: flex; flex-wrap: wrap; gap: var(--space-1); }
.ping-mark {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 1px 8px;
    border-radius: var(--radius-full);
    border: 1px solid var(--rule);
    background: var(--paper-2);
    font-size: var(--text-xs);
    color: var(--text-2);
    text-decoration: none;
}
.ping-mark__tag {
    font-size: var(--text-2xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--sky-700);
}
.ping-mark--open { border-color: var(--sky-200); background: var(--sky-50); }
.ping-mark--answered { border-color: var(--leaf-200); background: var(--leaf-50); }
.ping-mark--answered .ping-mark__tag { color: var(--leaf-700); }
.ping-mark--closed, .ping-mark--cancelled { opacity: 0.75; }
/* An update written in the chat and recorded by the chat's bot. */
.chat-source-mark {
    display: inline-block;
    padding: 0 6px;
    border-radius: var(--radius-full);
    border: 1px solid var(--sky-200);
    background: var(--sky-50);
    font-size: var(--text-2xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--sky-700);
}
.ping__question { font-size: var(--text-md); margin: var(--space-2) 0; }
.ping__facts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); margin: 0 0 var(--space-3); }
.ping__facts dt { font-size: var(--text-xs); color: var(--text-3); }
.ping__facts dd { margin: 0; font-size: var(--text-sm); }
.ping__overdue { color: var(--rose-600); font-size: var(--text-xs); font-weight: 600; }
.ping__note { font-size: var(--text-sm); color: var(--text-2); }
.ping__answer { padding: var(--space-2) var(--space-3); background: var(--leaf-50); border-radius: var(--radius-md); margin-bottom: var(--space-3); }
.ping__answer h3 { margin: 0 0 var(--space-1); font-size: var(--text-sm); }
.ping__form { display: flex; flex-direction: column; gap: var(--space-1); margin: var(--space-3) 0; }
.ping__actions { display: flex; gap: var(--space-2); margin: var(--space-2) 0; }
.ping__history { margin-top: var(--space-3); font-size: var(--text-sm); }
.ping-page { max-width: 640px; }
.ping-hint { margin-top: var(--space-1); }
.checkbox-inline { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); margin: var(--space-1) 0; }

/* Today */
.today-section { margin-bottom: var(--space-5); }
.today-group { margin: var(--space-3) 0 var(--space-1); font-size: var(--text-sm); font-weight: 600; color: var(--text-2); }
.today-group--overdue { color: var(--rose-600); }
.today-week summary { cursor: pointer; }
.today-item { flex-wrap: wrap; }
.today-item__actions { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-left: auto; }
.today-flash { padding: var(--space-2) var(--space-3); background: var(--leaf-50); border-radius: var(--radius-md); }
.lookup { display: flex; flex-direction: column; gap: var(--space-1); }
.lookup-results { list-style: none; margin: var(--space-2) 0; padding: 0; border: 1px solid var(--rule); border-radius: var(--radius-md); background: var(--paper); }
.lookup-results li + li { border-top: 1px solid var(--rule); }
.lookup-results a { display: block; padding: var(--space-2) var(--space-3); text-decoration: none; color: var(--text); }
.lookup-results a:hover { background: var(--paper-2); }
.lookup-results__sub { font-size: var(--text-xs); color: var(--text-3); }
.client-card { margin-top: var(--space-3); padding: var(--space-3) var(--space-4); border: 1px solid var(--rule); border-radius: var(--radius-lg); background: var(--paper); }
.client-card__head { display: flex; align-items: center; gap: var(--space-2); }
.client-card__head h3 { margin: 0; margin-right: auto; font-size: var(--text-lg); }
.client-card__facts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); margin: var(--space-3) 0; }
.client-card__facts dt { font-size: var(--text-xs); color: var(--text-3); }
.client-card__facts dd { margin: 0; font-size: var(--text-sm); }
.client-card h4 { margin: var(--space-3) 0 var(--space-1); font-size: var(--text-sm); }
.client-card__list { margin: 0; padding-left: var(--space-4); font-size: var(--text-sm); }

/* The field matrix */
.field-access__role, .field-access__cell { text-align: center; }
.field-access__log { margin-top: var(--space-6); }

@media (max-width: 640px) {
    .ping__facts, .client-card__facts { grid-template-columns: 1fr; }
}

.ping__form button,
.ping__form .btn { align-self: flex-start; }
.today-item__actions { align-items: center; }
.today-item__actions form { display: inline-flex; margin: 0; }

/* "No colleague called Zed — send as plain text?" */
.ping-offer {
    flex-basis: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
    margin: var(--space-2) 0;
    padding-left: var(--space-6);
}
.ping-offer .field-error,
.ping-offer .task-composer__error { margin: 0; }
