/* =====================================================================
   notifications.css — Badge cloche + dropdown notifications
   ===================================================================== */

/* -------  Bell container  ------- */
.notif-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    margin-right: 12px;
    z-index: 1000;
}

.notif-bell {
    position: relative;
    cursor: pointer;
    color: #c0c0e0;
    font-size: 1.25rem;
    padding: 6px 10px;
    border-radius: 50%;
    transition: color .2s, background .2s;
}

.notif-bell:hover {
    color: #a29bfe;
    background: rgba(162, 155, 254, .12);
}

/* -------  Badge counter  ------- */
.notif-badge {
    position: absolute;
    top: 0;
    right: 2px;
    background: #e74c3c;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    border-radius: 50%;
    padding: 0 4px;
    pointer-events: none;
    animation: notif-pulse 2s ease-in-out infinite;
}

@keyframes notif-pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.15);
    }
}

/* -------  Dropdown panel  ------- */
.notif-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 340px;
    max-height: 420px;
    overflow-y: auto;
    background: #151940;
    border: 1px solid rgba(162, 155, 254, .25);
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .45);
    z-index: 1100;
}

.notif-dropdown.open {
    display: block;
}

.notif-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.notif-dropdown-header h4 {
    margin: 0;
    color: #e0e0e0;
    font-size: .95rem;
}

.notif-mark-all {
    background: none;
    border: none;
    color: #a29bfe;
    font-size: .78rem;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    transition: background .2s;
}

.notif-mark-all:hover {
    background: rgba(162, 155, 254, .15);
}

/* -------  Individual notification item  ------- */
.notif-item {
    display: flex;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .04);
    transition: background .15s;
    text-decoration: none;
    color: inherit;
}

.notif-item:hover {
    background: rgba(162, 155, 254, .08);
}

.notif-item.unread {
    background: rgba(108, 92, 231, .08);
    border-left: 3px solid #6c5ce7;
}

.notif-icon {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(162, 155, 254, .15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a29bfe;
    font-size: .85rem;
}

.notif-item.unread .notif-icon {
    background: rgba(108, 92, 231, .25);
    color: #c0b6ff;
}

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

.notif-title {
    font-size: .82rem;
    font-weight: 600;
    color: #e0e0e0;
    margin: 0 0 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.notif-message {
    font-size: .75rem;
    color: #999;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    /* For non-webkit browsers a tester!!!!!!!!!!!!!!!!!!*/
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.notif-time {
    font-size: .68rem;
    color: #666;
    margin-top: 3px;
}

/* -------  Empty state  ------- */
.notif-empty {
    padding: 30px 16px;
    text-align: center;
    color: #666;
    font-size: .85rem;
}

.notif-empty i {
    font-size: 2rem;
    display: block;
    margin-bottom: 10px;
    color: #444;
}

/* -------  Scrollbar  ------- */
.notif-dropdown::-webkit-scrollbar {
    width: 5px;
}

.notif-dropdown::-webkit-scrollbar-track {
    background: transparent;
}

.notif-dropdown::-webkit-scrollbar-thumb {
    background: rgba(162, 155, 254, .3);
    border-radius: 3px;
}

/* -------  Responsive  ------- */
@media (max-width: 768px) {
    .notif-dropdown {
        position: fixed;
        top: 60px;
        right: 10px;
        left: 10px;
        width: auto;
        max-height: 70vh;
    }
}

@media (max-width: 480px) {
    .notif-dropdown {
        right: 5px;
        left: 5px;
        top: 55px;
    }

    .notif-item {
        gap: 8px;
        padding: 10px 12px;
    }
}