.notification-menu {
    position: relative;
}

.notification-bell {
    position: relative;
}

.notification-badge {
    top: 0.2rem;
    right: -0.15rem;
    min-width: 1.3rem;
    padding: 0.15rem 0.35rem;
    border-radius: 999px;
    background: var(--danger_button_background_color);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
}

.notification-dropdown {
    width: min(26rem, calc(100vw - 1.5rem));
    padding: 0;
    border: 1px solid color-mix(in srgb, var(--border_color), transparent 24%);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 22px 60px rgba(12, 16, 38, 0.18);
}

.notification-dropdown-header,
.notification-dropdown-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1rem;
}

.notification-dropdown-header {
    background: color-mix(in srgb, var(--main_area_background_color), white 8%);
}

.notification-dropdown-header h4 {
    margin: 0;
    font-size: 1rem;
}

.notification-dropdown-header p {
    margin: 0.15rem 0 0;
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 36%);
    font-size: 0.85rem;
}

.notification-dropdown-body {
    max-height: 26rem;
    overflow-y: auto;
}

.notification-item {
    display: block;
    padding: 0.95rem 1rem;
    border-bottom: 1px solid color-mix(in srgb, var(--border_color), transparent 30%);
    transition: background-color 140ms ease, transform 140ms ease;
}

.notification-item:hover {
    transform: translateY(-1px);
}

.notification-item-unread {
    background: color-mix(in srgb, var(--highlight_background_color), white 89%);
}

.notification-item-topline {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.notification-item-title {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    font-weight: 700;
    color: var(--main_area_foreground_color);
}

.notification-priority-dot {
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--highlight_background_color), var(--danger_button_background_color) 18%);
    flex: 0 0 auto;
}

.notification-priority-dot-important {
    background: var(--danger_button_background_color);
}

.notification-item-time {
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 44%);
    font-size: 0.8rem;
    white-space: nowrap;
}

.notification-item-summary,
.notification-item-sender {
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 34%);
}

.notification-item-sender {
    margin-top: 0.45rem;
    font-size: 0.82rem;
}

.notification-empty {
    padding: 1.1rem 1rem;
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 38%);
}

.notification-mark-all {
    color: var(--highlight_background_color);
    font-weight: 600;
}

.notification-detail-shell {
    min-height: auto !important;
    padding: 1.75rem 1.5rem 2.5rem;
}

.notification-detail-card {
    max-width: 58rem;
    margin: 0 auto;
    padding: 1.6rem;
}

.notification-detail-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.notification-detail-header p {
    margin: 0.65rem 0 0;
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 36%);
}

.notification-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin: 1rem 0 1.25rem;
    color: color-mix(in srgb, var(--main_area_foreground_color), transparent 34%);
}

.notification-detail-content {
    padding: 1.1rem 1.15rem 0.25rem;
    border: 1px solid color-mix(in srgb, var(--border_color), transparent 26%);
    border-radius: 1rem;
    background: color-mix(in srgb, var(--main_area_background_color), white 12%);
}

.notification-detail-actions {
    margin-top: 1.2rem;
}

@media (max-width: 767px) {
    .notification-detail-shell {
        padding: 1rem 0.85rem 1.6rem;
    }

    .notification-detail-card {
        padding: 1.1rem;
    }

    .notification-detail-header,
    .notification-dropdown-header,
    .notification-dropdown-footer {
        flex-direction: column;
        align-items: flex-start;
    }
}
