/* =========================================================
   Notificações — Dropdown do sino + Página "Todas"
   ========================================================= */

/* ── Badge de contagem no sino ─────────────────────────── */
.notif-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 50px;
    background: #e53935;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    display: none;
    pointer-events: none;
}

.notif-badge.visible {
    display: inline-block;
}

/* Garante posição relativa no ícone de sino */
.topbar-item .nav-icon {
    position: relative;
}

/* ── Dropdown de notificações ──────────────────────────── */
.notif-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px 8px;
    border-bottom: 1px solid var(--bs-border-color, #e9ecef);
}

.notif-dropdown-header h6 {
    font-weight: 600;
    margin: 0;
    font-size: 14px;
}

.notif-dropdown-list {
    max-height: 320px;
    overflow-y: auto;
    padding: 4px 0;
}

.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 16px;
    border-bottom: 1px solid var(--bs-border-color-translucent, #f0f0f0);
    text-decoration: none;
    color: inherit;
    transition: background 0.15s;
    cursor: pointer;
}

.notif-item:last-child {
    border-bottom: none;
}

.notif-item:hover {
    background: var(--bs-tertiary-bg, #f8f9fa);
}

.notif-item.nao-lida {
    background: #eef4ff;
}

.notif-item.nao-lida:hover {
    background: #ddeeff;
}

.notif-item__icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bs-primary-bg-subtle, #cfe2ff);
    color: var(--bs-primary, #0d6efd);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.notif-item__body {
    flex: 1;
    min-width: 0;
}

.notif-item__title {
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.notif-item__msg {
    font-size: 12px;
    color: var(--bs-secondary-color, #6c757d);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.notif-item__time {
    font-size: 11px;
    color: var(--bs-secondary-color, #6c757d);
    white-space: nowrap;
    margin-top: 2px;
}

.notif-item__dismiss {
    flex-shrink: 0;
    background: none;
    border: none;
    padding: 0;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bs-secondary-color, #6c757d);
    opacity: 0.6;
    cursor: pointer;
    transition: opacity 0.15s, background 0.15s;
}

.notif-item__dismiss:hover {
    opacity: 1;
    background: var(--bs-danger-bg-subtle, #f8d7da);
    color: var(--bs-danger, #dc3545);
}

.notif-empty {
    padding: 24px 16px;
    text-align: center;
    color: var(--bs-secondary-color, #6c757d);
    font-size: 13px;
}

.notif-dropdown-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border-top: 1px solid var(--bs-border-color, #e9ecef);
    gap: 8px;
}

.notif-dropdown-footer .btn {
    font-size: 12px;
    padding: 4px 10px;
}

/* ── Página "Todas as Notificações" ───────────────────── */
.notificacoes-page .notif-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 18px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid var(--bs-border-color, #e9ecef);
    margin-bottom: 10px;
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.15s, border-color 0.15s;
    cursor: default;
}

.notificacoes-page .notif-card.nao-lida {
    border-left: 3px solid var(--bs-primary, #0d6efd);
    background: #f7faff;
}

.notificacoes-page .notif-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    border-color: #b6d0ff;
}

.notificacoes-page .notif-card__icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--bs-primary-bg-subtle, #cfe2ff);
    color: var(--bs-primary, #0d6efd);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.notificacoes-page .notif-card__body {
    flex: 1;
    min-width: 0;
}

.notificacoes-page .notif-card__title {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 3px;
}

.notificacoes-page .notif-card__msg {
    font-size: 13px;
    color: var(--bs-secondary-color, #6c757d);
    margin: 0 0 4px;
}

.notificacoes-page .notif-card__meta {
    font-size: 11px;
    color: var(--bs-secondary-color, #6c757d);
}

.notificacoes-page .notif-card__actions {
    flex-shrink: 0;
    display: flex;
    gap: 6px;
    align-items: center;
}
