/*
    notification-card.css — shared notification row primitives (prefix: nb-)

    Global (not scoped) on purpose: the same row markup renders in two different
    scope roots — inside NotificationBellComponent's dropdown and standalone
    inside a Blazored toast (ReminderNotificationCard). Keeping the rules here
    is what guarantees the two stay pixel-identical.

    Bell chrome (wrapper, button, badge, dropdown, header, list, dividers,
    inline actions) stays in NotificationBellComponent.razor.css.
*/

/* ── Item ── */
.nb-item {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
    padding: 12px 16px 12px 18px;
    border: none;
    background: transparent;
    appearance: none;
    color: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.13s ease;
    border-bottom: 1px solid #f5f3ff;
}
.nb-item:last-child {
    border-bottom: none;
}
.nb-item:hover {
    background: #faf8ff;
}
.nb-item:focus-visible {
    outline: none;
    background: #f5f3ff;
    box-shadow: inset 3px 0 0 rgba(107, 92, 231, 0.5);
}

/* unread: accent bar on left */
.nb-item-unread-dot {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 3px;
    border-radius: 0 2px 2px 0;
    background: #6b5ce7;
}

/* pending invitation — subtle tint */
.nb-item--pending {
    background: rgba(107, 92, 231, 0.03);
}
.nb-item--pending:hover {
    background: rgba(107, 92, 231, 0.07);
}

/* owner share hover */
.nb-item--owner-share:hover {
    background: #f5f3ff;
}

/* decline / removed hover */
.nb-item--decline-owner:hover {
    background: #fff7f7;
}

/* ── Item icon — circular ── */
.nb-item-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 1px;
}
.nb-item-icon--pending       { background: rgba(107, 92, 231, 0.12); color: #6b5ce7; }
.nb-item-icon--accepted      { background: rgba(16, 185, 129, 0.12); color: #059669; }
.nb-item-icon--revoked       { background: rgba(239, 68, 68, 0.12);  color: #dc2626; }
.nb-item-icon--declined      { background: rgba(100, 116, 139, 0.1); color: #64748b; }
.nb-item-icon--write-request { background: rgba(245, 158, 11, 0.12); color: #d97706; }
.nb-item-icon--edit          { background: rgba(5, 150, 105, 0.12);  color: #059669; }
.nb-item-icon--view          { background: rgba(29, 78, 216, 0.1);   color: #1d4ed8; }
.nb-item-icon i { font-size: 0.95rem; }

/* ── Item body ── */
.nb-item-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    flex: 1;
}

.nb-item-title-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.nb-item-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Meta row ── */
.nb-item-meta {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 0;
}
.nb-item-actor {
    font-size: 0.7rem;
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 1;
    min-width: 0;
}
.nb-item-date {
    font-size: 0.67rem;
    color: #94a3b8;
    white-space: nowrap;
    flex-shrink: 0;
}
.nb-item-meta .nb-item-date::before {
    content: ' · ';
    color: #cbd5e1;
}

/* ── Task pill ── */
.nb-item-task {
    display: inline-block;
    max-width: 100%;
    font-size: 0.68rem;
    font-weight: 500;
    color: #6b5ce7;
    background: rgba(107, 92, 231, 0.07);
    border: 1px solid rgba(107, 92, 231, 0.15);
    padding: 1px 8px;
    border-radius: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    align-self: flex-start;
}

/* ── Type chip ── */
.nb-type-chip {
    display: inline-block;
    font-size: 0.59rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 2px 7px;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}
.nb-type-chip--invite   { background: rgba(107, 92, 231, 0.1);  color: #6b5ce7; }
.nb-type-chip--shared   { background: rgba(16, 185, 129, 0.1);  color: #059669; }
.nb-type-chip--expired  { background: rgba(148, 163, 184, 0.1); color: #64748b; }
.nb-type-chip--revoked  { background: rgba(239, 68, 68, 0.1);   color: #dc2626; }
.nb-type-chip--sent     { background: rgba(107, 92, 231, 0.1);  color: #6b5ce7; }
.nb-type-chip--declined { background: rgba(100, 116, 139, 0.09);color: #64748b; }
.nb-type-chip--request  { background: rgba(245, 158, 11, 0.11); color: #b45309; }
.nb-type-chip--edit     { background: rgba(5, 150, 105, 0.1);   color: #059669; }
.nb-type-chip--view     { background: rgba(29, 78, 216, 0.09);  color: #1d4ed8; }

/* "removed" — distinct portocaliu */
.nb-type-chip--declined[class*="removed"],
.nb-type-chip--removed  { background: rgba(239, 68, 68, 0.09);  color: #dc2626; }

/* ── Reminder variant ── */
.nb-item--reminder {
    background: linear-gradient(180deg, rgba(245, 158, 11, 0.08), rgba(255, 255, 255, 0.98));
}

.nb-item--reminder:hover {
    background: rgba(245, 158, 11, 0.12);
}

.nb-item-icon--reminder {
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
}

.nb-type-chip--reminder {
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
}

/* ── Toast context ──
   The card renders as the whole toast body. Blazored's custom-component branch
   already zeroes the shell padding, so the card supplies its own rounding and
   leaves room on the right for the close button. */
.ags-reminder-toast.blazored-toast {
    padding: 0;
    width: 20rem;
    max-width: 22rem;
    overflow: hidden;
}

.nb-item--toast {
    padding-right: 34px;
    border-bottom: none;
    border-radius: 12px;
}

.nb-item-toast-close {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #cbd5e1;
    font-size: 0.75rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.13s ease, background 0.13s ease;
}
.nb-item-toast-close:hover {
    color: #64748b;
    background: #f1f5f9;
}
